Version 2.10.0-0.0.dev

Merge commit '08663c20aba7f985bd839c330bd05bb1cff15196' into dev
diff --git a/.dart_tool/package_config.json b/.dart_tool/package_config.json
index 25d9592..6cfa6ab 100644
--- a/.dart_tool/package_config.json
+++ b/.dart_tool/package_config.json
@@ -11,7 +11,7 @@
     "constraint, update this by running tools/generate_package_config.dart."
   ],
   "configVersion": 2,
-  "generated": "2020-06-29T11:21:54.984521",
+  "generated": "2020-07-14T07:50:57.318843",
   "generator": "tools/generate_package_config.dart",
   "packages": [
     {
@@ -72,7 +72,7 @@
       "name": "async",
       "rootUri": "../third_party/pkg/async",
       "packageUri": "lib/",
-      "languageVersion": "2.2"
+      "languageVersion": "2.10"
     },
     {
       "name": "async_helper",
@@ -83,19 +83,19 @@
       "name": "bazel_worker",
       "rootUri": "../third_party/pkg/bazel_worker",
       "packageUri": "lib/",
-      "languageVersion": "2.1"
+      "languageVersion": "2.3"
     },
     {
       "name": "benchmark_harness",
       "rootUri": "../third_party/pkg/benchmark_harness",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "boolean_selector",
       "rootUri": "../third_party/pkg/boolean_selector",
       "packageUri": "lib/",
-      "languageVersion": "2.4"
+      "languageVersion": "2.10"
     },
     {
       "name": "build_integration",
@@ -107,7 +107,7 @@
       "name": "charcode",
       "rootUri": "../third_party/pkg/charcode",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
     },
     {
       "name": "cli_util",
@@ -119,7 +119,7 @@
       "name": "collection",
       "rootUri": "../third_party/pkg/collection",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "compiler",
@@ -225,7 +225,7 @@
       "name": "fixnum",
       "rootUri": "../third_party/pkg/fixnum",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "front_end",
@@ -327,7 +327,7 @@
       "name": "js",
       "rootUri": "../pkg/js",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "js_ast",
@@ -339,7 +339,7 @@
       "name": "js_runtime",
       "rootUri": "../sdk/lib/_internal/js_runtime",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "json_rpc_2",
@@ -375,13 +375,13 @@
       "name": "matcher",
       "rootUri": "../third_party/pkg/matcher",
       "packageUri": "lib/",
-      "languageVersion": "2.4"
+      "languageVersion": "2.10"
     },
     {
       "name": "meta",
       "rootUri": "../pkg/meta",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "mime",
@@ -446,19 +446,19 @@
       "name": "path",
       "rootUri": "../third_party/pkg/path",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
     },
     {
       "name": "pedantic",
       "rootUri": "../third_party/pkg/pedantic",
       "packageUri": "lib/",
-      "languageVersion": "2.1"
+      "languageVersion": "2.10"
     },
     {
       "name": "pool",
       "rootUri": "../third_party/pkg/pool",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
     },
     {
       "name": "protobuf",
@@ -494,7 +494,7 @@
       "name": "sdk_library_metadata",
       "rootUri": "../sdk/lib/_internal/sdk_library_metadata",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "shelf",
@@ -536,19 +536,19 @@
       "name": "source_map_stack_trace",
       "rootUri": "../third_party/pkg/source_map_stack_trace",
       "packageUri": "lib/",
-      "languageVersion": "2.7"
+      "languageVersion": "2.10"
     },
     {
       "name": "source_maps",
       "rootUri": "../third_party/pkg/source_maps",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
     },
     {
       "name": "source_span",
       "rootUri": "../third_party/pkg/source_span",
       "packageUri": "lib/",
-      "languageVersion": "2.6"
+      "languageVersion": "2.10"
     },
     {
       "name": "sourcemap_testing",
@@ -557,10 +557,16 @@
       "languageVersion": "2.1"
     },
     {
+      "name": "sse",
+      "rootUri": "../third_party/pkg/sse",
+      "packageUri": "lib/",
+      "languageVersion": "2.6"
+    },
+    {
       "name": "stack_trace",
       "rootUri": "../third_party/pkg/stack_trace",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
     },
     {
       "name": "stagehand",
@@ -578,13 +584,19 @@
       "name": "stream_channel",
       "rootUri": "../third_party/pkg/stream_channel",
       "packageUri": "lib/",
-      "languageVersion": "2.2"
+      "languageVersion": "2.10"
     },
     {
       "name": "string_scanner",
       "rootUri": "../third_party/pkg/string_scanner",
       "packageUri": "lib/",
-      "languageVersion": "2.0"
+      "languageVersion": "2.10"
+    },
+    {
+      "name": "sync_http",
+      "rootUri": "../third_party/pkg/sync_http",
+      "packageUri": "lib/",
+      "languageVersion": "2.6"
     },
     {
       "name": "telemetry",
@@ -596,25 +608,25 @@
       "name": "term_glyph",
       "rootUri": "../third_party/pkg/term_glyph",
       "packageUri": "lib/",
-      "languageVersion": "1.8"
+      "languageVersion": "2.10"
     },
     {
       "name": "test",
       "rootUri": "../third_party/pkg/test/pkgs/test",
       "packageUri": "lib/",
-      "languageVersion": "2.7"
+      "languageVersion": "2.10"
     },
     {
       "name": "test_api",
       "rootUri": "../third_party/pkg/test/pkgs/test_api",
       "packageUri": "lib/",
-      "languageVersion": "2.7"
+      "languageVersion": "2.10"
     },
     {
       "name": "test_core",
       "rootUri": "../third_party/pkg/test/pkgs/test_core",
       "packageUri": "lib/",
-      "languageVersion": "2.7"
+      "languageVersion": "2.10"
     },
     {
       "name": "test_descriptor",
@@ -656,7 +668,7 @@
       "name": "typed_data",
       "rootUri": "../third_party/pkg/typed_data",
       "packageUri": "lib/",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "usage",
@@ -665,6 +677,12 @@
       "languageVersion": "2.0"
     },
     {
+      "name": "vector_math",
+      "rootUri": "../third_party/pkg/vector_math",
+      "packageUri": "lib/",
+      "languageVersion": "2.10"
+    },
+    {
       "name": "vm",
       "rootUri": "../pkg/vm",
       "packageUri": "lib/",
@@ -689,6 +707,12 @@
       "languageVersion": "2.2"
     },
     {
+      "name": "webdriver",
+      "rootUri": "../third_party/pkg/webdriver",
+      "packageUri": "lib/",
+      "languageVersion": "2.6"
+    },
+    {
       "name": "web_components",
       "rootUri": "../third_party/pkg/web_components",
       "packageUri": "lib/",
diff --git a/.packages b/.packages
index 2b486aa..ee073a7 100644
--- a/.packages
+++ b/.packages
@@ -92,11 +92,13 @@
 sourcemap_testing:pkg/sourcemap_testing/lib
 source_maps:third_party/pkg/source_maps/lib
 source_span:third_party/pkg/source_span/lib
+sse:third_party/pkg/sse/lib
 stack_trace:third_party/pkg/stack_trace/lib
 stagehand:third_party/pkg/stagehand/lib
 status_file:pkg/status_file/lib
 stream_channel:third_party/pkg/stream_channel/lib
 string_scanner:third_party/pkg/string_scanner/lib
+sync_http:third_party/pkg/sync_http/lib
 telemetry:pkg/telemetry/lib
 term_glyph:third_party/pkg/term_glyph/lib
 test:third_party/pkg/test/pkgs/test/lib
@@ -110,10 +112,12 @@
 tflite_native:third_party/pkg/tflite_native/lib
 typed_data:third_party/pkg/typed_data/lib
 usage:third_party/pkg/usage/lib
+vector_math:third_party/pkg/vector_math/lib
 vm:pkg/vm/lib
 vm_service:pkg/vm_service/lib
 vm_snapshot_analysis:pkg/vm_snapshot_analysis/lib
 watcher:third_party/pkg/watcher/lib
+webdriver:third_party/pkg/webdriver/lib
 web_components:third_party/pkg/web_components/lib
 web_socket_channel:third_party/pkg/web_socket_channel/lib
 yaml:third_party/pkg/yaml/lib
diff --git a/BUILD.gn b/BUILD.gn
index c758c49..fe0376d 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -61,7 +61,10 @@
   # TODO(bkonyi): this dep causes a segfault on Android XARM_X64 builds.
   # See issue #41776.
   if (dart_target_arch != "arm") {
-    deps += [ "utils/dartdev:dartdev" ]
+    deps += [
+      "utils/dartdev:dartdev",
+      "utils/dds:dds",
+    ]
   }
 }
 
@@ -149,3 +152,58 @@
 group("compressed_observatory_archive") {
   deps = [ "runtime/observatory:copy_compressed_observatory_archive" ]
 }
+
+if (is_fuchsia) {
+  import("third_party/fuchsia/sdk/linux/build/component.gni")
+  import("third_party/fuchsia/sdk/linux/build/package.gni")
+
+  fuchsia_component("fuchsia_test_component") {
+    testonly = true
+    data_deps = [ "runtime/bin:dart" ]
+    manifest = "build/fuchsia/dart.cmx"
+
+    resource_files = [
+      ".packages",
+      "pkg/testing/test/hello_test.dart",
+    ]
+    resource_dirs = [
+      "tests/standalone",
+      "tests/language_2",
+      "pkg/async_helper",
+      "pkg/expect",
+      "pkg/meta",
+      "pkg/smith",
+      "third_party/pkg/args",
+      "third_party/pkg/async",
+      "third_party/pkg/collection",
+      "third_party/pkg/path",
+      "third_party/pkg/pool",
+      "third_party/pkg/stack_trace",
+    ]
+
+    resources = []
+    foreach(file, resource_files) {
+      resources += [
+        {
+          path = file
+          dest = "data/" + file
+        },
+      ]
+    }
+    resources +=
+        exec_script("tools/fuchsia/find_resources.py", resource_dirs, "json")
+  }
+
+  fuchsia_package("fuchsia_test_package") {
+    package_name = "dart_test_"
+    if (is_debug) {
+      package_name += "debug"
+    } else if (is_release) {
+      package_name += "release"
+    } else if (is_product) {
+      package_name += "product"
+    }
+    testonly = true
+    deps = [ ":fuchsia_test_component" ]
+  }
+}
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 3ebc479..c69d96a 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,5 @@
+## 2.10.0
+
 ## 2.9.0
 
 ### Language
@@ -58,6 +60,18 @@
 
 [#41653]: https://github.com/dart-lang/sdk/issues/41653
 
+#### `dart:mirrors`
+
+*   **Breaking Change** [#42714][]: web compilers (dart2js and DDC) now produce
+    a compile-time error if `dart:mirrors` is imported.
+
+    Most projects should not be affected. Since 2.0.0 this library was
+    unsupported and produced runtime errors on all its APIs. Since then several
+    tools already reject code that use `dart:mirrors` including webdev and
+    flutter tools, we expect few projects to run into this problem.
+
+[#42714]: https://github.com/dart-lang/sdk/issues/42714
+
 ### Tools
 
 #### dartfmt
@@ -104,19 +118,27 @@
 ### Pub
 * `pub run` and `pub global run` accepts a `--enable-experiment` flag enabling
   experiments in the Dart VM (and language).
+* Warn when publishing the first null-safe version of a package.
+* `pub outdated`:
+  * Introduce `--mode=null-safety` flag that will report which of your
+    dependencies you can upgrade to fully support null safety.
+  * If the current version of a dependency is a prerelease
+    version, use prereleases for latest if there is no newer stable.
+  * Don't require a `pubspec.lock` file. When the lockfile is missing, the
+    **Current** column is empty.
+* `pub upgrade`: Show summary count of outdated packages after running.
+  It will also only show newer packages if they are not prereleases or
+  the package is already a prerelease.
 * Publishing Flutter plugins using the old plugin format is no longer allowed.
   Plugins using the old plugin format can still be consumed.
-* Introduce `pub outdated --mode=null-safety` that will report which of your
-  dependencies you can upgrade to fully support null safety.
-* Fix `pub run` precompilation with relative `PUB_CACHE` paths (#2486)
-* Warn at publishing first time a package version opts in to null-safety.
-* Preserve Windows line endings in pubspec.lock if they are already there (#2489)
+* `pub run`: Fix precompilation with relative `PUB_CACHE` paths
+  ([#2486](https://github.com/dart-lang/pub/pull/2486)).
+* Preserve Windows line endings in `pubspec.lock` if they are already there
+  ([#2489](https://github.com/dart-lang/pub/pull/2489)).
 * Better terminal color-detection. Use colors in terminals on Windows.
-* `pub outdated`: If the current version of a dependency is a prerelease
-  version, use prereleases for latest if no newer stable.
-* `pub outdated` now works without a lockfile. In that case the 'Current'
-  column will be empty.
-* `pub upgrade`: Show summary count of outdated packages after running.
+* Fix git folder names in cache, allowing for ssh-style git 
+  dependencies.
+* Fix: Avoid precompilation of dependencies of global packages.
 
 ## 2.8.4 - 2020-06-04
 
diff --git a/DEPS b/DEPS
index de99bfd..842b0bd 100644
--- a/DEPS
+++ b/DEPS
@@ -39,16 +39,16 @@
 
   # Checked-in SDK version. The checked-in SDK is a Dart SDK distribution in a
   # cipd package used to run Dart scripts in the build and test infrastructure.
-  "sdk_tag": "version:2.9.0-18.0.dev",
+  "sdk_tag": "version:2.10.0-0.2-preview",
 
   # co19 is a cipd package. Use update.sh in tests/co19[_2] to update these
   # hashes. It requires access to the dart-build-access group, which EngProd
   # has.
-  "co19_rev": "4035c66f0cacb70064395473cb54d810c046c225",
+  "co19_rev": "d79951e06e443213243e54c2c32694b79a221b65",
   "co19_2_rev": "620c1148c8b7a3d7f74afacf348c46f109eb64f2",
 
   # The internal benchmarks to use. See go/dart-benchmarks-internal
-  "benchmarks_internal_rev": "88af52754f272e7a4c5737b7e003c2ed9e8a754f",
+  "benchmarks_internal_rev": "0e59a6bc3ee912273865b87709cdb698be358e30",
   "checkout_benchmarks_internal": False,
 
   # As Flutter does, we use Fuchsia's GN and Clang toolchain. These revision
@@ -66,17 +66,17 @@
 
   # Revisions of /third_party/* dependencies.
   "args_tag": "1.6.0",
-  "async_rev": "e0c41e0c1fb70ba606dc81335c981af7c00987c6",
+  "async_rev": "128c461a97dbdbd9336ba000ba5a5c02e79b8651",
   "bazel_worker_rev": "26680d5e249b249c7216ab2fed0ac8ed4ee285c5",
-  "benchmark_harness_rev": "81641290dea44c34138a109a37e215482f405f81",
-  "boolean_selector_rev": "1309eabed510cc3b7536fd4367d39b97ebee3d69",
+  "benchmark_harness_rev": "ec6b646f5443faa871e126ac1ba248c94ca06257",
+  "boolean_selector_rev": "665e6921ab246569420376f827bff4585dff0b14",
   "boringssl_gen_rev": "429ccb1877f7987a6f3988228bc2440e61293499",
   "boringssl_rev" : "4dfd5af70191b068aebe567b8e29ce108cee85ce",
   "browser-compat-data_tag": "v1.0.22",
-  "charcode_rev": "9085e6b6127f084d66c0a94810a808121459012a",
+  "charcode_rev": "af1e2d59a9c383da94f99ea51dac4b93fb0626c4",
   "chrome_rev" : "19997",
   "cli_util_tag" : "0.1.4",
-  "collection_rev": "80f5b6de8a8d8d584732a71bb59912da3e44883b",
+  "collection_rev": "583693680fc067e34ca5b72503df25e8b80579f9",
   "convert_rev": "49bde5b371eb5c2c8e721557cf762f17c75e49fc",
   "crypto_rev": "7422fb2f6584fe1839eb30bc4ca56e9f9760b801",
   "csslib_rev": "bf372d4fdc6dfa232ad93f77a0a3de0891edd04c",
@@ -96,16 +96,17 @@
   # For more details, see https://github.com/dart-lang/sdk/issues/30164
   "dart_style_tag": "1.3.6",  # Please see the note above before updating.
 
-  "dartdoc_tag" : "v0.32.1",
+  "chromedriver_tag": "83.0.4103.39",
+  "dartdoc_tag" : "v0.32.2",
   "ffi_rev": "454ab0f9ea6bd06942a983238d8a6818b1357edb",
-  "fixnum_rev": "9b38f49f6679654d66a363e69e48173cca07e882",
+  "fixnum_rev": "300c3f025e94a72b7b6770e15f76a4de15f77668",
   "glob_rev": "e9f4e6b7ae8abe5071461cf8f47191bb19cf7ef6",
   "html_rev": "083a36cd801a4b787ba156b7c6e4c8b2e2daed4a",
   "http_io_rev": "2fa188caf7937e313026557713f7feffedd4978b",
   "http_multi_server_rev" : "ea269f79321d659208402088f3297e8920a88ee6",
   "http_parser_rev": "6e63a97b5aaa2b4d1215fe01683e51fb73258e54",
   "http_retry_tag": "0.1.1",
-  "http_rev": "a131e563c09349f624d5421237183a06fb10552d",
+  "http_rev": "7b55a2c62a5f6fb680ad7a4607bab7281a235563",
   "http_throttle_tag" : "1.0.2",
   "icu_rev" : "79326efe26e5440f530963704c3c0ff965b3a4ac",
   "idl_parser_rev": "5fb1ebf49d235b5a70c9f49047e83b0654031eb7",
@@ -116,18 +117,18 @@
   "logging_rev": "9561ba016ae607747ae69b846c0e10958ca58ed4",
   "markupsafe_rev": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783",
   "markdown_rev": "dd150bb64c5f3b41d31f20f399ae2a855f7f8c00",
-  "matcher_rev": "af4fe7daf8e94a46981e4f072872be550a6969e9",
+  "matcher_rev": "9cae8faa7868bf3a88a7ba45eb0bd128e66ac515",
   "mime_rev": "179b5e6a88f4b63f36dc1b8fcbc1e83e5e0cd3a7",
   "mockito_rev": "d39ac507483b9891165e422ec98d9fb480037c8b",
   "mustache_rev": "664737ecad027e6b96d0d1e627257efa0e46fcb1",
   "oauth2_tag": "1.6.0",
   "package_config_rev": "9c586d04bd26fef01215fd10e7ab96a3050cfa64",
-  "path_rev": "4f3bb71843fe5493ba490828a1721821d7b33746",
-  "pedantic_tag": "v1.9.0",
+  "path_rev": "62ecd5a78ffe5734d14ed0df76d20309084cd04a",
+  "pedantic_rev": "24b38df72430d7e21cb4257828580becb9a39c72",
   "ply_rev": "604b32590ffad5cbb82e4afef1d305512d06ae93",
-  "pool_rev": "86fbb2cde9bbc66c8d159909d2f65a5981ea5b50",
+  "pool_rev": "eedbd5fde84f9a1a8da643b475305a81841da599",
   "protobuf_rev": "3746c8fd3f2b0147623a8e3db89c3ff4330de760",
-  "pub_rev": "6178cdf284baf2345d1ea578b7176a754aa576fe",
+  "pub_rev": "04b054b62cc437cf23451785fdc50e49cd9de139",
   "pub_semver_tag": "v1.4.4",
   "quiver-dart_tag": "246e754fe45cecb6aa5f3f13b4ed61037ff0d784",
   "resource_rev": "f8e37558a1c4f54550aa463b88a6a831e3e33cd6",
@@ -138,23 +139,27 @@
   "shelf_proxy_tag": "0.1.0+7",
   "shelf_tag": "0.7.3+3",
   "shelf_web_socket_tag": "0.2.2+3",
-  "source_map_stack_trace_tag": "2.0.0",
+  "source_map_stack_trace_rev": "1c3026f69d9771acf2f8c176a1ab750463309cce",
   "source_maps-0.9.4_rev": "38524",
-  "source_maps_rev": "87b4fd9027378bbd51b02e9d7df794eee8a82b7a",
-  "source_span_tag": "1.7.0",
-  "stack_trace_tag": "56811dbb2530d823b764fe167ec335879a4adb32",
+  "source_maps_rev": "53eb92ccfe6e64924054f83038a534b959b12b3e",
+  "source_span_rev": "94833d6cbf4552ebe5d2aa6714acecd93834e53a",
+  "sse_tag": "e5cf68975e8e87171a3dc297577aa073454a91dc",
+  "stack_trace_tag": "d3813ca0a77348e0faf0d6af0cc17913e36afa39",
   "stagehand_tag": "v3.3.9",
-  "stream_channel_tag": "70433d577be02c48cb16d72d65654f3b4d82c6ed",
-  "string_scanner_rev": "a918e7371af6b6e73bfd534ff9da6084741c1f99",
+  "stream_channel_tag": "c446774fd077c9bdbd6235a7aadc661ef60a9727",
+  "string_scanner_rev": "1b63e6e5db5933d7be0a45da6e1129fe00262734",
+  "sync_http_rev": "a85d7ec764ea485cbbc49f3f3e7f1b43f87a1c74",
   "test_descriptor_tag": "1.1.1",
   "test_process_tag": "1.0.3",
-  "term_glyph_rev": "b3da31e9684a99cfe5f192b89914492018b44da7",
+  "term_glyph_rev": "6a0f9b6fb645ba75e7a00a4e20072678327a0347",
   "test_reflective_loader_tag": "0.1.9",
-  "test_rev": "718fe6f93c4655208460f28e89d887c5ef4144c5",
+  "test_rev": "c6b3fe63eda87da1687580071cad1eefd575f851",
   "tflite_native_rev": "3c777c40608a2a9f1427bfe0028ab48e7116b4c1",
-  "typed_data_tag": "0c369b73a9b7ebf042c06512951bfe5b52b84a5f",
+  "typed_data_tag": "f94fc57b8e8c0e4fe4ff6cfd8290b94af52d3719",
   "usage_tag": "3.4.0",
+  "vector_math_rev": "0c9f5d68c047813a6dcdeb88ba7a42daddf25025",
   "watcher_rev": "fc3c9aae5d31d707b3013b42634dde8d8a1161b4",
+  "webdriver_rev": "5a8d6805d9cf8a3cbb4fcd64849b538b7491e50e",
   "web_components_rev": "8f57dac273412a7172c8ade6f361b407e2e4ed02",
   "web_socket_channel_rev": "490061ef0e22d3c8460ad2802f9948219365ad6b",
   "WebCore_rev": "fb11e887f77919450e497344da570d780e078bc8",
@@ -167,7 +172,7 @@
   # Pinned browser versions used by the testing infrastructure. These are not
   # meant to be downloaded by users for local testing.
   "download_chrome": False,
-  "chrome_tag": "81",
+  "chrome_tag": "84",
   "download_firefox": False,
   "firefox_tag": "67",
 
@@ -373,7 +378,7 @@
   Var("dart_root") + "/third_party/pkg/path":
       Var("dart_git") + "path.git" + "@" + Var("path_rev"),
   Var("dart_root") + "/third_party/pkg/pedantic":
-      Var("dart_git") + "pedantic.git" + "@" + Var("pedantic_tag"),
+      Var("dart_git") + "pedantic.git" + "@" + Var("pedantic_rev"),
   Var("dart_root") + "/third_party/pkg/pool":
       Var("dart_git") + "pool.git" + "@" + Var("pool_rev"),
   Var("dart_root") + "/third_party/pkg/protobuf":
@@ -403,10 +408,12 @@
   Var("dart_root") + "/third_party/pkg/source_maps":
       Var("dart_git") + "source_maps.git" + "@" + Var("source_maps_rev"),
   Var("dart_root") + "/third_party/pkg/source_span":
-      Var("dart_git") + "source_span.git" + "@" + Var("source_span_tag"),
+      Var("dart_git") + "source_span.git" + "@" + Var("source_span_rev"),
   Var("dart_root") + "/third_party/pkg/source_map_stack_trace":
       Var("dart_git") + "source_map_stack_trace.git" +
-      "@" + Var("source_map_stack_trace_tag"),
+      "@" + Var("source_map_stack_trace_rev"),
+  Var("dart_root") + "/third_party/pkg/sse":
+      Var("dart_git") + "sse.git" + "@" + Var("sse_tag"),
   Var("dart_root") + "/third_party/pkg/stack_trace":
       Var("dart_git") + "stack_trace.git" + "@" + Var("stack_trace_tag"),
   Var("dart_root") + "/third_party/pkg/stagehand":
@@ -417,6 +424,8 @@
   Var("dart_root") + "/third_party/pkg/string_scanner":
       Var("dart_git") + "string_scanner.git" +
       "@" + Var("string_scanner_rev"),
+  Var("dart_root") + "/third_party/pkg/sync_http":
+      Var("dart_git") + "sync_http.git" + "@" + Var("sync_http_rev"),
   Var("dart_root") + "/third_party/pkg/term_glyph":
       Var("dart_git") + "term_glyph.git" + "@" + Var("term_glyph_rev"),
   Var("dart_root") + "/third_party/pkg/test":
@@ -434,11 +443,18 @@
       Var("dart_git") + "typed_data.git" + "@" + Var("typed_data_tag"),
   Var("dart_root") + "/third_party/pkg/usage":
       Var("dart_git") + "usage.git" + "@" + Var("usage_tag"),
+  Var("dart_root") + "/third_party/pkg/vector_math":
+      Var("dart_git") + "external/github.com/google/vector_math.dart.git" +
+      "@" + Var("vector_math_rev"),
   Var("dart_root") + "/third_party/pkg/watcher":
       Var("dart_git") + "watcher.git" + "@" + Var("watcher_rev"),
   Var("dart_root") + "/third_party/pkg/web_components":
       Var("dart_git") + "web-components.git" +
       "@" + Var("web_components_rev"),
+  Var("dart_root") + "/third_party/pkg/webdriver":
+      Var("dart_git") + "external/github.com/google/webdriver.dart.git" +
+      "@" + Var("webdriver_rev"),
+
   Var("dart_root") + "/third_party/pkg/web_socket_channel":
       Var("dart_git") + "web_socket_channel.git" +
       "@" + Var("web_socket_channel_rev"),
@@ -456,6 +472,17 @@
       "dep_type": "cipd",
   },
 
+  Var("dart_root") + "/third_party/webdriver/chrome": {
+    "packages": [
+      {
+        "package": "dart/third_party/chromedriver/${{platform}}",
+        "version": "version:" + Var("chromedriver_tag"),
+      }
+    ],
+    "condition": "host_cpu == 'x64'",
+    "dep_type": "cipd",
+  },
+
   Var("dart_root") + "/pkg/analysis_server/language_model": {
     "packages": [
       {
diff --git a/build/config/BUILDCONFIG.gn b/build/config/BUILDCONFIG.gn
index 10a97c7..336445e 100644
--- a/build/config/BUILDCONFIG.gn
+++ b/build/config/BUILDCONFIG.gn
@@ -258,6 +258,12 @@
         [ "//build/config/gcc:symbol_visibility_hidden" ]
   }
 }
+if (is_fuchsia) {
+  _native_compiler_configs += [
+    "//third_party/fuchsia/sdk/linux/build/config:compiler",
+    "//third_party/fuchsia/sdk/linux/build/config:runtime_library",
+  ]
+}
 
 if (is_linux) {
   _native_compiler_configs += [ "//build/config/linux:sdk" ]
diff --git a/build/fuchsia/config/clang/BUILD.gn b/build/fuchsia/config/clang/BUILD.gn
new file mode 100644
index 0000000..be74d08
--- /dev/null
+++ b/build/fuchsia/config/clang/BUILD.gn
@@ -0,0 +1,31 @@
+# Copyright 2019 The Fuchsia Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import("//build/fuchsia/config/clang/clang.gni")
+
+# This adds the runtime deps for C++ for usage when cross compiling.
+group("c++-runtime-deps") {
+  data_deps = [
+    ":clang-runtime-libs",
+  ]
+}
+
+copy("clang-runtime-libs") {
+  if (target_cpu == "arm64") {
+    arch = "aarch64"
+  } else if (target_cpu == "x64") {
+    arch = "x86_64"
+  }
+  vendor = "unknown"
+
+  sys = target_os
+  sources = [
+    "${clang_base_path}/lib/${arch}-${vendor}-${sys}/c++/libc++.so.2.0",
+    "${clang_base_path}/lib/${arch}-${vendor}-${sys}/c++/libc++abi.so.1.0",
+    "${clang_base_path}/lib/${arch}-${vendor}-${sys}/c++/libunwind.so.1.0",
+  ]
+  outputs = [
+    "${root_out_dir}/lib/{{source_name_part}}",
+  ]
+}
diff --git a/build/fuchsia/config/clang/clang.gni b/build/fuchsia/config/clang/clang.gni
new file mode 100644
index 0000000..8617aa5
--- /dev/null
+++ b/build/fuchsia/config/clang/clang.gni
@@ -0,0 +1,7 @@
+# Copyright 2019 The Fuchsia Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+declare_args() {
+  clang_base_path = "//buildtools/linux-x64/clang"
+}
diff --git a/build/fuchsia/dart.cmx b/build/fuchsia/dart.cmx
new file mode 100644
index 0000000..b4546c1
--- /dev/null
+++ b/build/fuchsia/dart.cmx
@@ -0,0 +1,27 @@
+{
+  "program": {
+    "binary": "exe.stripped/dart"
+  },
+  "sandbox": {
+    "features": [
+      "config-data",
+      "deprecated-ambient-replace-as-executable",
+      "root-ssl-certificates",
+      "isolated-cache-storage",
+      "isolated-persistent-storage"
+    ],
+    "services": [
+      "fuchsia.deprecatedtimezone.Timezone",
+      "fuchsia.device.NameProvider",
+      "fuchsia.feedback.CrashReporter",
+      "fuchsia.intl.PropertyProvider",
+      "fuchsia.logger.LogSink",
+      "fuchsia.net.NameLookup",
+      "fuchsia.netstack.Netstack",
+      "fuchsia.posix.socket.Provider",
+      "fuchsia.sysmem.Allocator",
+      "fuchsia.timezone.Timezone",
+      "fuchsia.tracing.provider.Registry"
+    ]
+  }
+}
diff --git a/pkg/_fe_analyzer_shared/lib/src/flow_analysis/flow_analysis.dart b/pkg/_fe_analyzer_shared/lib/src/flow_analysis/flow_analysis.dart
index 6893a79..2dd17b7 100644
--- a/pkg/_fe_analyzer_shared/lib/src/flow_analysis/flow_analysis.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/flow_analysis/flow_analysis.dart
@@ -1512,24 +1512,32 @@
     }
 
     List<Type> newPromotedTypes = info.promotedTypes;
+    bool newReachable = reachable;
     if (promotedType != null) {
       newPromotedTypes =
           VariableModel._addToPromotedTypes(info.promotedTypes, promotedType);
+      if (typeOperations.isNever(promotedType)) {
+        newReachable = false;
+      }
     }
 
     return identical(newTested, info.tested) &&
-            identical(newPromotedTypes, info.promotedTypes)
+            identical(newPromotedTypes, info.promotedTypes) &&
+            newReachable == reachable
         ? this
         : _updateVariableInfo(
             variable,
             new VariableModel<Variable, Type>(newPromotedTypes, newTested,
-                info.assigned, info.unassigned, info.writeCaptured));
+                info.assigned, info.unassigned, info.writeCaptured),
+            reachable: newReachable);
   }
 
   /// Returns a new [FlowModel] where the information for [variable] is replaced
   /// with [model].
   FlowModel<Variable, Type> _updateVariableInfo(
-      Variable variable, VariableModel<Variable, Type> model) {
+      Variable variable, VariableModel<Variable, Type> model,
+      {bool reachable}) {
+    reachable ??= this.reachable;
     Map<Variable, VariableModel<Variable, Type>> newVariableInfo =
         new Map<Variable, VariableModel<Variable, Type>>.from(variableInfo);
     newVariableInfo[variable] = model;
@@ -1667,6 +1675,14 @@
   /// initializer).
   bool isLocalVariableWithoutDeclaredType(Variable variable);
 
+  /// Determines whether the given [type] is equivalent to the `Never` type.
+  ///
+  /// A type is equivalent to `Never` if it:
+  /// (a) is the `Never` type itself.
+  /// (b) is a type variable that extends `Never`, OR
+  /// (c) is a type variable that has been promoted to `Never`
+  bool isNever(Type type);
+
   /// Returns `true` if [type1] and [type2] are the same type.
   bool isSameType(Type type1, Type type2);
 
@@ -1804,7 +1820,10 @@
     bool newUnassigned = unassigned && otherModel.unassigned;
     bool newWriteCaptured = writeCaptured || otherModel.writeCaptured;
     List<Type> newPromotedTypes;
-    if (unsafe) {
+    if (newWriteCaptured) {
+      // Write-captured variables can't be promoted
+      newPromotedTypes = null;
+    } else if (unsafe) {
       // There was an assignment to the variable in the "this" path, so none of
       // the promotions from the "other" path can be used.
       newPromotedTypes = thisPromotedTypes;
diff --git a/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart b/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
index 309004e..0ebf75a 100644
--- a/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/messages/codes_generated.dart
@@ -46,6 +46,53 @@
         r"""Try removing the 'abstract' keyword. You can add the 'abstract' keyword before the class declaration.""");
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractExtensionField = messageAbstractExtensionField;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractExtensionField = const MessageCode(
+    "AbstractExtensionField",
+    message: r"""Extension fields can't be declared 'abstract'.""",
+    tip: r"""Try removing the 'abstract' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractExternalField = messageAbstractExternalField;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractExternalField = const MessageCode(
+    "AbstractExternalField",
+    message: r"""Fields can't be declared both 'abstract' and 'external'.""",
+    tip: r"""Try removing the 'abstract' or 'external' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractFieldConstructorInitializer =
+    messageAbstractFieldConstructorInitializer;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractFieldConstructorInitializer = const MessageCode(
+    "AbstractFieldConstructorInitializer",
+    message: r"""Abstract fields cannot have initializers.""",
+    tip:
+        r"""Try removing the field initializer or the 'abstract' keyword from the field declaration.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractFieldInitializer = messageAbstractFieldInitializer;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractFieldInitializer = const MessageCode(
+    "AbstractFieldInitializer",
+    message: r"""Abstract fields cannot have initializers.""",
+    tip: r"""Try removing the initializer or the 'abstract' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractLateField = messageAbstractLateField;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractLateField = const MessageCode(
+    "AbstractLateField",
+    message: r"""Abstract fields cannot be late.""",
+    tip: r"""Try removing the 'abstract' or 'late' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Code<Null> codeAbstractNotSync = messageAbstractNotSync;
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
@@ -82,6 +129,15 @@
 }
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeAbstractStaticField = messageAbstractStaticField;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageAbstractStaticField = const MessageCode(
+    "AbstractStaticField",
+    message: r"""Static fields can't be declared 'abstract'.""",
+    tip: r"""Try removing the 'abstract' or 'static' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<Message Function(String name)> templateAccessError =
     const Template<Message Function(String name)>(
         messageTemplate: r"""Access error: '#name'.""",
@@ -3271,6 +3327,35 @@
         r"""Try removing the keyword 'external', or replacing the field by an external getter and/or setter.""");
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeExternalFieldConstructorInitializer =
+    messageExternalFieldConstructorInitializer;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageExternalFieldConstructorInitializer = const MessageCode(
+    "ExternalFieldConstructorInitializer",
+    message: r"""External fields cannot have initializers.""",
+    tip:
+        r"""Try removing the field initializer or the 'external' keyword from the field declaration.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeExternalFieldInitializer = messageExternalFieldInitializer;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageExternalFieldInitializer = const MessageCode(
+    "ExternalFieldInitializer",
+    message: r"""External fields cannot have initializers.""",
+    tip: r"""Try removing the initializer or the 'external' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeExternalLateField = messageExternalLateField;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageExternalLateField = const MessageCode(
+    "ExternalLateField",
+    message: r"""External fields cannot be late.""",
+    tip: r"""Try removing the 'external' or 'late' keyword.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Code<Null> codeExternalMethodWithBody = messageExternalMethodWithBody;
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
@@ -5417,6 +5502,16 @@
     tip: r"""Try replacing with a normal method.""");
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Null> codeJsInteropNamedParameters = messageJsInteropNamedParameters;
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const MessageCode messageJsInteropNamedParameters = const MessageCode(
+    "JsInteropNamedParameters",
+    message:
+        r"""Named parameters for JS interop functions are only allowed in a factory constructor of an @anonymous JS class.""",
+    tip: r"""Try replacing them with normal or optional parameters.""");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Code<Null> codeJsInteropNonExternalConstructor =
     messageJsInteropNonExternalConstructor;
 
@@ -7873,6 +7968,46 @@
         r"""A library can't opt out of null safety by default, when using sound null safety.""");
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+    Message Function(
+        List<String>
+            _names)> templateStrongModeNNBDPackageOptOut = const Template<
+        Message Function(List<String> _names)>(
+    messageTemplate:
+        r"""Cannot run with sound null safety as one or more dependencies do not
+support null safety:
+
+#names
+
+Run 'pub outdated --mode=null-safety' to determine if versions of your
+dependencies supporting null safety are available.""",
+    withArguments: _withArgumentsStrongModeNNBDPackageOptOut);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(List<String> _names)>
+    codeStrongModeNNBDPackageOptOut =
+    const Code<Message Function(List<String> _names)>(
+  "StrongModeNNBDPackageOptOut",
+  templateStrongModeNNBDPackageOptOut,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsStrongModeNNBDPackageOptOut(List<String> _names) {
+  if (_names.isEmpty) throw 'No names provided';
+  String names = itemizeNames(_names);
+  return new Message(codeStrongModeNNBDPackageOptOut,
+      message:
+          """Cannot run with sound null safety as one or more dependencies do not
+support null safety:
+
+${names}
+
+Run 'pub outdated --mode=null-safety' to determine if versions of your
+dependencies supporting null safety are available.""",
+      arguments: {'names': _names});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Code<Null> codeSuperAsExpression = messageSuperAsExpression;
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart b/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart
index c738205..2a728d5 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/forwarding_listener.dart
@@ -535,6 +535,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -543,8 +544,16 @@
       int count,
       Token beginToken,
       Token endToken) {
-    listener?.endClassFields(externalToken, staticToken, covariantToken,
-        lateToken, varFinalOrConst, count, beginToken, endToken);
+    listener?.endClassFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
@@ -648,6 +657,7 @@
 
   @override
   void endExtensionFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -656,8 +666,16 @@
       int count,
       Token beginToken,
       Token endToken) {
-    listener?.endExtensionFields(externalToken, staticToken, covariantToken,
-        lateToken, varFinalOrConst, count, beginToken, endToken);
+    listener?.endExtensionFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
@@ -875,6 +893,7 @@
 
   @override
   void endMixinFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -883,8 +902,16 @@
       int count,
       Token beginToken,
       Token endToken) {
-    listener?.endMixinFields(externalToken, staticToken, covariantToken,
-        lateToken, varFinalOrConst, count, beginToken, endToken);
+    listener?.endMixinFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart b/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart
index 479289a..53906bc 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/listener.dart
@@ -367,6 +367,7 @@
   ///
   /// Doesn't have a corresponding begin event, use [beginMember] instead.
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -386,6 +387,7 @@
   ///
   /// Doesn't have a corresponding begin event, use [beginMember] instead.
   void endMixinFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -395,8 +397,8 @@
       Token beginToken,
       Token endToken) {
     // TODO(danrubel): push implementation into subclasses
-    endClassFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    endClassFields(abstractToken, externalToken, staticToken, covariantToken,
+        lateToken, varFinalOrConst, count, beginToken, endToken);
   }
 
   /// Handle the end of a extension field declaration.  Substructures:
@@ -407,6 +409,7 @@
   ///
   /// Doesn't have a corresponding begin event, use [beginMember] instead.
   void endExtensionFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -416,8 +419,8 @@
       Token beginToken,
       Token endToken) {
     // TODO(danrubel): push implementation into subclasses
-    endClassFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    endClassFields(abstractToken, externalToken, staticToken, covariantToken,
+        lateToken, varFinalOrConst, count, beginToken, endToken);
   }
 
   /// Marks that the grammar term `forInitializerStatement` has been parsed and
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/modifier_context.dart b/pkg/_fe_analyzer_shared/lib/src/parser/modifier_context.dart
index 1ab8699..904871b 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/modifier_context.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/modifier_context.dart
@@ -97,10 +97,6 @@
   /// Parse modifiers for class methods and fields.
   Token parseClassMemberModifiers(Token token) {
     token = parseModifiers(token);
-    if (abstractToken != null) {
-      parser.reportRecoverableError(
-          abstractToken, codes.messageAbstractClassMember);
-    }
     reportExtraneousModifier(requiredToken);
     return token;
   }
diff --git a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
index e994086..53e40dd 100644
--- a/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/parser/parser_impl.dart
@@ -2464,6 +2464,7 @@
     }
     return parseFields(
         beforeStart,
+        /* abstractToken = */ null,
         externalToken,
         /* staticToken = */ null,
         /* covariantToken = */ null,
@@ -2479,6 +2480,7 @@
 
   Token parseFields(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -2509,6 +2511,9 @@
         reportRecoverableError(varFinalOrConst, codes.messageTypeAfterVar);
       }
     }
+    if (abstractToken != null && externalToken != null) {
+      reportRecoverableError(abstractToken, codes.messageAbstractExternalField);
+    }
 
     Token token = typeInfo.parseType(beforeType, this);
     assert(token.next == name || token.next.isEof);
@@ -2532,12 +2537,12 @@
     }
 
     int fieldCount = 1;
-    token = parseFieldInitializerOpt(name, name, lateToken, externalToken,
-        varFinalOrConst, kind, enclosingDeclarationName);
+    token = parseFieldInitializerOpt(name, name, lateToken, abstractToken,
+        externalToken, varFinalOrConst, kind, enclosingDeclarationName);
     while (optional(',', token.next)) {
       name = ensureIdentifier(token.next, context);
-      token = parseFieldInitializerOpt(name, name, lateToken, externalToken,
-          varFinalOrConst, kind, enclosingDeclarationName);
+      token = parseFieldInitializerOpt(name, name, lateToken, abstractToken,
+          externalToken, varFinalOrConst, kind, enclosingDeclarationName);
       ++fieldCount;
     }
     Token semicolon = token.next;
@@ -2563,24 +2568,53 @@
     }
     switch (kind) {
       case DeclarationKind.TopLevel:
+        assert(abstractToken == null);
         listener.endTopLevelFields(externalToken, staticToken, covariantToken,
             lateToken, varFinalOrConst, fieldCount, beforeStart.next, token);
         break;
       case DeclarationKind.Class:
-        listener.endClassFields(externalToken, staticToken, covariantToken,
-            lateToken, varFinalOrConst, fieldCount, beforeStart.next, token);
+        listener.endClassFields(
+            abstractToken,
+            externalToken,
+            staticToken,
+            covariantToken,
+            lateToken,
+            varFinalOrConst,
+            fieldCount,
+            beforeStart.next,
+            token);
         break;
       case DeclarationKind.Mixin:
-        listener.endMixinFields(externalToken, staticToken, covariantToken,
-            lateToken, varFinalOrConst, fieldCount, beforeStart.next, token);
+        listener.endMixinFields(
+            abstractToken,
+            externalToken,
+            staticToken,
+            covariantToken,
+            lateToken,
+            varFinalOrConst,
+            fieldCount,
+            beforeStart.next,
+            token);
         break;
       case DeclarationKind.Extension:
+        if (abstractToken != null) {
+          reportRecoverableError(
+              firstName, codes.messageAbstractExtensionField);
+        }
         if (staticToken == null && externalToken == null) {
           reportRecoverableError(
               firstName, codes.messageExtensionDeclaresInstanceField);
         }
-        listener.endExtensionFields(externalToken, staticToken, covariantToken,
-            lateToken, varFinalOrConst, fieldCount, beforeStart.next, token);
+        listener.endExtensionFields(
+            abstractToken,
+            externalToken,
+            staticToken,
+            covariantToken,
+            lateToken,
+            varFinalOrConst,
+            fieldCount,
+            beforeStart.next,
+            token);
         break;
     }
     return token;
@@ -2655,6 +2689,7 @@
       Token token,
       Token name,
       Token lateToken,
+      Token abstractToken,
       Token externalToken,
       Token varFinalOrConst,
       DeclarationKind kind,
@@ -2678,6 +2713,7 @@
         } else if (kind == DeclarationKind.TopLevel &&
             optional("final", varFinalOrConst) &&
             lateToken == null &&
+            abstractToken == null &&
             externalToken == null) {
           reportRecoverableError(
               name,
@@ -2697,7 +2733,7 @@
       token = parseExpression(assignment);
       listener.endVariableInitializer(assignment);
     } else {
-      listener.handleNoVariableInitializer(token.next);
+      listener.handleNoVariableInitializer(token);
     }
     return token;
   }
@@ -3193,6 +3229,7 @@
     Token beforeStart = token = parseMetadataStar(token);
 
     Token covariantToken;
+    Token abstractToken;
     Token externalToken;
     Token lateToken;
     Token staticToken;
@@ -3203,6 +3240,9 @@
       if (optional('external', next)) {
         externalToken = token = next;
         next = token.next;
+      } else if (optional('abstract', next)) {
+        abstractToken = token = next;
+        next = token.next;
       }
       if (isModifier(next)) {
         if (optional('static', next)) {
@@ -3236,7 +3276,8 @@
               ..externalToken = externalToken
               ..lateToken = lateToken
               ..staticToken = staticToken
-              ..varFinalOrConst = varFinalOrConst;
+              ..varFinalOrConst = varFinalOrConst
+              ..abstractToken = abstractToken;
 
             token = context.parseClassMemberModifiers(token);
             next = token.next;
@@ -3246,6 +3287,7 @@
             lateToken = context.lateToken;
             staticToken = context.staticToken;
             varFinalOrConst = context.varFinalOrConst;
+            abstractToken = context.abstractToken;
 
             context = null;
           }
@@ -3285,6 +3327,10 @@
           if (beforeType != token) {
             reportRecoverableError(token, codes.messageTypeBeforeFactory);
           }
+          if (abstractToken != null) {
+            reportRecoverableError(
+                abstractToken, codes.messageAbstractClassMember);
+          }
           token = parseFactoryMethod(token, kind, beforeStart, externalToken,
               staticToken ?? covariantToken, varFinalOrConst);
           listener.endMember();
@@ -3299,6 +3345,7 @@
         if (next2.isUserDefinableOperator && typeParam == noTypeParamOrArg) {
           token = parseMethod(
               beforeStart,
+              abstractToken,
               externalToken,
               staticToken,
               covariantToken,
@@ -3321,6 +3368,7 @@
           // Recovery: Invalid operator
           return parseInvalidOperatorDeclaration(
               beforeStart,
+              abstractToken,
               externalToken,
               staticToken,
               covariantToken,
@@ -3333,6 +3381,7 @@
           // Recovery
           token = parseMethod(
               beforeStart,
+              abstractToken,
               externalToken,
               staticToken,
               covariantToken,
@@ -3353,10 +3402,15 @@
           (identical(value, 'typedef') &&
               token == beforeStart &&
               next.next.isIdentifier)) {
+        if (abstractToken != null) {
+          reportRecoverableError(
+              abstractToken, codes.messageAbstractClassMember);
+        }
         // Recovery
         return recoverFromInvalidMember(
             token,
             beforeStart,
+            abstractToken,
             externalToken,
             staticToken,
             covariantToken,
@@ -3378,6 +3432,7 @@
           // Recovery: Missing `operator` keyword
           return parseInvalidOperatorDeclaration(
               beforeStart,
+              abstractToken,
               externalToken,
               staticToken,
               covariantToken,
@@ -3411,6 +3466,7 @@
         identical(value, '=>')) {
       token = parseMethod(
           beforeStart,
+          abstractToken,
           externalToken,
           staticToken,
           covariantToken,
@@ -3430,6 +3486,7 @@
       }
       token = parseFields(
           beforeStart,
+          abstractToken,
           externalToken,
           staticToken,
           covariantToken,
@@ -3448,6 +3505,7 @@
 
   Token parseMethod(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -3460,6 +3518,9 @@
       DeclarationKind kind,
       String enclosingDeclarationName,
       bool nameIsRecovered) {
+    if (abstractToken != null) {
+      reportRecoverableError(abstractToken, codes.messageAbstractClassMember);
+    }
     if (lateToken != null) {
       reportRecoverableErrorWithToken(
           lateToken, codes.templateExtraneousModifier);
@@ -5655,7 +5716,7 @@
     if (typeInfo.isNullable) {
       Token next = typeInfo.skipType(token).next;
       if (!isOneOfOrEof(
-          next, const [')', '?', '??', ',', ';', ':', 'is', 'as'])) {
+          next, const [')', '?', '??', ',', ';', ':', 'is', 'as', '..'])) {
         // TODO(danrubel): investigate other situations
         // where `?` should be considered part of the type info
         // rather than the start of a conditional expression.
@@ -6898,6 +6959,7 @@
   /// (and events have already been generated).
   Token parseInvalidOperatorDeclaration(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -6945,6 +7007,7 @@
 
     Token token = parseMethod(
         beforeStart,
+        abstractToken,
         externalToken,
         staticToken,
         covariantToken,
@@ -6967,6 +7030,7 @@
   Token recoverFromInvalidMember(
       Token token,
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -6989,6 +7053,7 @@
     } else if (next.isOperator && next.endGroup == null) {
       return parseInvalidOperatorDeclaration(
           beforeStart,
+          abstractToken,
           externalToken,
           staticToken,
           covariantToken,
@@ -7005,6 +7070,7 @@
         identical(value, '{')) {
       token = parseMethod(
           beforeStart,
+          abstractToken,
           externalToken,
           staticToken,
           covariantToken,
@@ -7028,6 +7094,7 @@
     } else {
       token = parseFields(
           beforeStart,
+          abstractToken,
           externalToken,
           staticToken,
           covariantToken,
diff --git a/pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart b/pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart
index 79879cc..8b68c68 100644
--- a/pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart
+++ b/pkg/_fe_analyzer_shared/lib/src/testing/id_testing.dart
@@ -643,6 +643,20 @@
     Map<String, List<String>> skipMap,
     Uri nullUri});
 
+/// Compute the file: URI of the file located at `path`, where `path` is
+/// relative to the root of the SDK repository.
+///
+/// We find the root of the SDK repository by looking for the parent of the
+/// directory named `pkg`.
+Uri _fileUriFromSdkRoot(String path) {
+  Uri uri = Platform.script;
+  List<String> pathSegments = uri.pathSegments;
+  return uri.replace(pathSegments: [
+    ...pathSegments.sublist(0, pathSegments.lastIndexOf('pkg')),
+    ...path.split('/')
+  ]);
+}
+
 class MarkerOptions {
   final Map<String, Uri> markers;
 
@@ -669,7 +683,7 @@
       }
       String marker = line.substring(0, eqPos);
       String tester = line.substring(eqPos + 1);
-      File testerFile = new File(tester);
+      File testerFile = new File.fromUri(_fileUriFromSdkRoot(tester));
       if (!testerFile.existsSync()) {
         throw new ArgumentError(
             "Tester '$tester' does not exist for marker '$marker' in "
diff --git a/pkg/_fe_analyzer_shared/pubspec.yaml b/pkg/_fe_analyzer_shared/pubspec.yaml
index ac83ab7..f7c4d16 100644
--- a/pkg/_fe_analyzer_shared/pubspec.yaml
+++ b/pkg/_fe_analyzer_shared/pubspec.yaml
@@ -1,5 +1,5 @@
 name: _fe_analyzer_shared
-version: 5.0.0
+version: 6.0.0
 description: Logic that is shared between the front_end and analyzer packages.
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/_fe_analyzer_shared
 
diff --git a/pkg/_fe_analyzer_shared/test/flow_analysis/flow_analysis_test.dart b/pkg/_fe_analyzer_shared/test/flow_analysis/flow_analysis_test.dart
index 9a6e31b..a3c666f 100644
--- a/pkg/_fe_analyzer_shared/test/flow_analysis/flow_analysis_test.dart
+++ b/pkg/_fe_analyzer_shared/test/flow_analysis/flow_analysis_test.dart
@@ -1735,6 +1735,7 @@
     var intVar = _Var('x', _Type('int'));
     var intQVar = _Var('x', _Type('int?'));
     var objectQVar = _Var('x', _Type('Object?'));
+    var nullVar = _Var('x', _Type('Null'));
     group('setReachable', () {
       var unreachable = FlowModel<_Var, _Type>(false);
       var reachable = FlowModel<_Var, _Type>(true);
@@ -2368,6 +2369,15 @@
               _matchVariableModel(chain: ['int?', 'int'], ofInterest: ['int?'])
         });
       });
+
+      test('promote to Never', () {
+        var h = _Harness();
+        var s1 = FlowModel<_Var, _Type>(true);
+        var s2 = s1.tryMarkNonNullable(h, nullVar).ifTrue;
+        expect(s2.reachable, false);
+        expect(s2.infoFor(nullVar),
+            _matchVariableModel(chain: ['Never'], ofInterest: []));
+      });
     });
 
     group('joinUnassigned', () {
@@ -3160,6 +3170,7 @@
     'List <: Object': true,
     'Never <: int': true,
     'Never <: int?': true,
+    'Never <: Null': true,
     'Never? <: int': false,
     'Never? <: int?': true,
     'Never? <: num?': true,
@@ -3334,6 +3345,11 @@
     return variable.isLocalVariableWithoutDeclaredType;
   }
 
+  @override
+  bool isNever(_Type type) {
+    return type.type == 'Never';
+  }
+
   /// Creates a [LazyExpression] representing an `is!` check, checking whether
   /// [subExpression] has the given [type].
   LazyExpression isNotType(LazyExpression subExpression, String type) {
@@ -3428,6 +3444,8 @@
   _Type promoteToNonNull(_Type type) {
     if (type.type.endsWith('?')) {
       return _Type(type.type.substring(0, type.type.length - 1));
+    } else if (type.type == 'Null') {
+      return _Type('Never');
     } else {
       return type;
     }
diff --git a/pkg/_fe_analyzer_shared/test/flow_analysis/nullability/data/null_aware_access.dart b/pkg/_fe_analyzer_shared/test/flow_analysis/nullability/data/null_aware_access.dart
index 586dcd2..cd4bc48 100644
--- a/pkg/_fe_analyzer_shared/test/flow_analysis/nullability/data/null_aware_access.dart
+++ b/pkg/_fe_analyzer_shared/test/flow_analysis/nullability/data/null_aware_access.dart
@@ -35,68 +35,68 @@
 }
 
 void indexGetterCall(C? c) {
-  c?.[/*nonNullable*/ c];
+  c?[/*nonNullable*/ c];
 }
 
 void indexSetterCall(C? c) {
-  c?.[/*nonNullable*/ c] = /*nonNullable*/ c;
+  c?[/*nonNullable*/ c] = /*nonNullable*/ c;
 }
 
 void indexCompoundAssign(C? c) {
-  c?.[/*nonNullable*/ c] += /*nonNullable*/ c;
+  c?[/*nonNullable*/ c] += /*nonNullable*/ c;
 }
 
 void indexNullAwareAssign(C? c) {
-  c?.[/*nonNullable*/ c] ??= /*nonNullable*/ c;
+  c?[/*nonNullable*/ c] ??= /*nonNullable*/ c;
 }
 
 void setterCall_nullShorting(C? c, D? d) {
   c?.getterReturningC.setter = /*nonNullable*/ c;
   c?.getterReturningNullableC?.setter = /*nonNullable*/ c;
-  c?.[0].setter = /*nonNullable*/ c;
-  d?.[0]?.setter = /*nonNullable*/ d;
+  c?[0].setter = /*nonNullable*/ c;
+  d?[0]?.setter = /*nonNullable*/ d;
 }
 
 void compoundAssign_nullShorting(C? c, D? d) {
   c?.getterReturningC.getterSetter += /*nonNullable*/ c;
   c?.getterReturningNullableC?.getterSetter += /*nonNullable*/ c;
-  c?.[0].getterSetter += /*nonNullable*/ c;
-  d?.[0]?.getterSetter += /*nonNullable*/ d;
+  c?[0].getterSetter += /*nonNullable*/ c;
+  d?[0]?.getterSetter += /*nonNullable*/ d;
 }
 
 void nullAwareAssign_nullShorting(C? c, D? d) {
   c?.getterReturningC.getterSetter ??= /*nonNullable*/ c;
   c?.getterReturningNullableC?.getterSetter ??= /*nonNullable*/ c;
-  c?.[0].getterSetter ??= /*nonNullable*/ c;
-  d?.[0]?.getterSetter ??= /*nonNullable*/ d;
+  c?[0].getterSetter ??= /*nonNullable*/ c;
+  d?[0]?.getterSetter ??= /*nonNullable*/ d;
 }
 
 void indexGetterCall_nullShorting(C? c, D? d) {
   c?.getterReturningC[/*nonNullable*/ c];
-  c?.getterReturningNullableC?.[/*nonNullable*/ c];
-  c?.[0][/*nonNullable*/ c];
-  d?.[0]?.[/*nonNullable*/ d];
+  c?.getterReturningNullableC?[/*nonNullable*/ c];
+  c?[0][/*nonNullable*/ c];
+  d?[0]?[/*nonNullable*/ d];
 }
 
 void indexSetterCall_nullShorting(C? c, D? d) {
   c?.getterReturningC[/*nonNullable*/ c] = /*nonNullable*/ c;
-  c?.getterReturningNullableC?.[/*nonNullable*/ c] = /*nonNullable*/ c;
-  c?.[0][/*nonNullable*/ c] = /*nonNullable*/ c;
-  d?.[0]?.[/*nonNullable*/ d] = /*nonNullable*/ d;
+  c?.getterReturningNullableC?[/*nonNullable*/ c] = /*nonNullable*/ c;
+  c?[0][/*nonNullable*/ c] = /*nonNullable*/ c;
+  d?[0]?[/*nonNullable*/ d] = /*nonNullable*/ d;
 }
 
 void indexCompoundAssign_nullShorting(C? c, D? d) {
   c?.getterReturningC[/*nonNullable*/ c] += /*nonNullable*/ c;
-  c?.getterReturningNullableC?.[/*nonNullable*/ c] += /*nonNullable*/ c;
-  c?.[0][/*nonNullable*/ c] += /*nonNullable*/ c;
-  d?.[0]?.[/*nonNullable*/ d] += /*nonNullable*/ d;
+  c?.getterReturningNullableC?[/*nonNullable*/ c] += /*nonNullable*/ c;
+  c?[0][/*nonNullable*/ c] += /*nonNullable*/ c;
+  d?[0]?[/*nonNullable*/ d] += /*nonNullable*/ d;
 }
 
 void indexNullAwareAssign_nullShorting(C? c, D? d) {
   c?.getterReturningC[/*nonNullable*/ c] ??= /*nonNullable*/ c;
-  c?.getterReturningNullableC?.[/*nonNullable*/ c] ??= /*nonNullable*/ c;
-  c?.[0][/*nonNullable*/ c] ??= /*nonNullable*/ c;
-  d?.[0]?.[/*nonNullable*/ d] ??= /*nonNullable*/ d;
+  c?.getterReturningNullableC?[/*nonNullable*/ c] ??= /*nonNullable*/ c;
+  c?[0][/*nonNullable*/ c] ??= /*nonNullable*/ c;
+  d?[0]?[/*nonNullable*/ d] ??= /*nonNullable*/ d;
 }
 
 void null_aware_cascades_do_not_promote_target(C? c) {
diff --git a/pkg/_fe_analyzer_shared/test/flow_analysis/reachability/data/issue41981.dart b/pkg/_fe_analyzer_shared/test/flow_analysis/reachability/data/issue41981.dart
new file mode 100644
index 0000000..f7ce9d2
--- /dev/null
+++ b/pkg/_fe_analyzer_shared/test/flow_analysis/reachability/data/issue41981.dart
@@ -0,0 +1,36 @@
+// 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.
+
+void testNotNull(Null n) {
+  0;
+  if (n != null)
+    /*stmt: unreachable*/ 1;
+  2;
+}
+
+void testIsNullableNever(Object? n) {
+  0;
+  if (n is Never?) 1;
+  2;
+}
+
+void testIsNever(Object? n) {
+  0;
+  if (n is Never)
+    /*stmt: unreachable*/ 1;
+  2;
+}
+
+void testIsNullableNeverTypeVariable<T extends Never?>(Object? n) {
+  0;
+  if (n is T) 1;
+  2;
+}
+
+void testIsNeverTypeVariable<T extends Never>(Object? n) {
+  0;
+  if (n is T)
+    /*stmt: unreachable*/ 1;
+  2;
+}
diff --git a/pkg/_fe_analyzer_shared/test/flow_analysis/type_promotion/data/bug42066.dart b/pkg/_fe_analyzer_shared/test/flow_analysis/type_promotion/data/bug42066.dart
new file mode 100644
index 0000000..25956d5
--- /dev/null
+++ b/pkg/_fe_analyzer_shared/test/flow_analysis/type_promotion/data/bug42066.dart
@@ -0,0 +1,15 @@
+// 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.
+
+f() {
+  num par2;
+  par2 = 0;
+  if (par2 is! int) return;
+  try {} catch (exception) {
+    throw 'x';
+    () {
+      par2 = 1;
+    };
+  } finally {}
+}
diff --git a/pkg/dev_compiler/LICENSE.md b/pkg/_js_interop_checks/LICENSE
similarity index 83%
copy from pkg/dev_compiler/LICENSE.md
copy to pkg/_js_interop_checks/LICENSE
index bab6a8c..18daf2b 100644
--- a/pkg/dev_compiler/LICENSE.md
+++ b/pkg/_js_interop_checks/LICENSE
@@ -1,13 +1,4 @@
-This license applies to all files contained here with the following
-exceptions:
-
-- All code in test/js_test_tools is externally maintained with
-  corresponding licenses in those individual files and directories.
-
----
-
-Copyright 2015, the Dart project authors. All rights reserved.
-
+Copyright 2020, the Dart project authors. All rights reserved.
 Redistribution and use in source and binary forms, with or without
 modification, are permitted provided that the following conditions are
 met:
diff --git a/pkg/_js_interop_checks/lib/js_interop_checks.dart b/pkg/_js_interop_checks/lib/js_interop_checks.dart
index ef93efe..7005741 100644
--- a/pkg/_js_interop_checks/lib/js_interop_checks.dart
+++ b/pkg/_js_interop_checks/lib/js_interop_checks.dart
@@ -9,6 +9,7 @@
         Message,
         LocatedMessage,
         messageJsInteropIndexNotSupported,
+        messageJsInteropNamedParameters,
         messageJsInteropNonExternalConstructor;
 
 import 'src/js_interop.dart';
@@ -19,25 +20,29 @@
   JsInteropChecks(this._diagnosticsReporter);
 
   @override
-  void visitClass(Class c) {
-    if (!hasJSInteropAnnotation(c)) return;
-    super.visitClass(c);
-  }
-
-  @override
   void visitProcedure(Procedure procedure) {
-    if (procedure.isStatic) return;
-    if (procedure.name.name == '[]=' || procedure.name.name == '[]') {
+    if (!procedure.isExternal || !isJSInteropMember(procedure)) return;
+
+    if (!procedure.isStatic &&
+        (procedure.name.name == '[]=' || procedure.name.name == '[]')) {
       _diagnosticsReporter.report(
           messageJsInteropIndexNotSupported,
           procedure.fileOffset,
           procedure.name.name.length,
           procedure.location.file);
     }
+
+    if (!isAnonymousClassMember(procedure) || !procedure.isFactory) {
+      // Only factory constructors for anonymous classes are allowed to have
+      // named parameters.
+      _checkNoNamedParameters(procedure.function);
+    }
   }
 
   @override
   void visitConstructor(Constructor constructor) {
+    if (!isJSInteropMember(constructor)) return;
+
     if (!constructor.isExternal && !constructor.isSynthetic) {
       _diagnosticsReporter.report(
           messageJsInteropNonExternalConstructor,
@@ -45,5 +50,19 @@
           constructor.name.name.length,
           constructor.location.file);
     }
+
+    _checkNoNamedParameters(constructor.function);
+  }
+
+  /// Reports an error if [functionNode] has named parameters.
+  void _checkNoNamedParameters(FunctionNode functionNode) {
+    if (functionNode != null && !functionNode.namedParameters.isEmpty) {
+      var firstNameParam = functionNode.namedParameters[0];
+      _diagnosticsReporter.report(
+          messageJsInteropNamedParameters,
+          firstNameParam.fileOffset,
+          firstNameParam.name.length,
+          firstNameParam.location.file);
+    }
   }
 }
diff --git a/pkg/_js_interop_checks/lib/src/js_interop.dart b/pkg/_js_interop_checks/lib/src/js_interop.dart
index 24ceac4..f8ea46f 100644
--- a/pkg/_js_interop_checks/lib/src/js_interop.dart
+++ b/pkg/_js_interop_checks/lib/src/js_interop.dart
@@ -4,15 +4,34 @@
 
 import 'package:kernel/kernel.dart';
 
-/// Returns true iff the class has an `@JS(...)` annotation from `package:js`
-/// or from the internal `dart:_js_annotations`.
-bool hasJSInteropAnnotation(Class c) =>
-    c.annotations.any(_isPublicJSAnnotation);
+/// Returns true iff the node has an `@JS(...)` annotation from `package:js` or
+/// from the internal `dart:_js_annotations`.
+bool hasJSInteropAnnotation(Annotatable a) =>
+    a.annotations.any(_isPublicJSAnnotation);
+
+/// Returns true if [m] belongs to a JS interop context. Checks if either the
+/// member or the surrounding context has a JS interop annotation.
+bool isJSInteropMember(Member m) {
+  if (hasJSInteropAnnotation(m)) return true;
+  var enclosingClass = m.enclosingClass;
+  if (enclosingClass != null) return hasJSInteropAnnotation(enclosingClass);
+  var enclosingLibrary = m.enclosingLibrary;
+  if (enclosingLibrary != null) return hasJSInteropAnnotation(enclosingLibrary);
+  return false;
+}
+
+/// Returns true if [m] belongs to an anonymous class.
+bool isAnonymousClassMember(Member m) {
+  var enclosingClass = m.enclosingClass;
+  if (enclosingClass == null) return false;
+  return enclosingClass.annotations.any(_isAnonymousAnnotation);
+}
 
 final _packageJs = Uri.parse('package:js/js.dart');
 final _internalJs = Uri.parse('dart:_js_annotations');
 
-/// Returns [true] if [e] is the `JS` annotation from `package:js`.
+/// Returns true if [value] is the `JS` annotation from `package:js` or from
+/// `dart:_js_annotations`.
 bool _isPublicJSAnnotation(Expression value) {
   var c = _annotationClass(value);
   return c != null &&
@@ -21,6 +40,16 @@
           c.enclosingLibrary.importUri == _internalJs);
 }
 
+/// Returns true if [value] is the `anyonymous` annotation from `package:js` or
+/// from `dart:_js_annotations`.
+bool _isAnonymousAnnotation(Expression value) {
+  var c = _annotationClass(value);
+  return c != null &&
+      c.name == '_Anonymous' &&
+      (c.enclosingLibrary.importUri == _packageJs ||
+          c.enclosingLibrary.importUri == _internalJs);
+}
+
 /// Returns the class of the instance referred to by metadata annotation [node].
 ///
 /// For example:
diff --git a/pkg/analysis_server/doc/api.html b/pkg/analysis_server/doc/api.html
index 3f5c00c..7e5dc01 100644
--- a/pkg/analysis_server/doc/api.html
+++ b/pkg/analysis_server/doc/api.html
@@ -2083,6 +2083,7 @@
   
   
   
+  
 <h3>Requests</h3><dl><dt class="request"><a name="request_edit.format">edit.format</a></dt><dd><div class="box"><pre>request: {
   "id": String
   "method": "edit.format"
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
index b8f7eb1..8842cc5 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_custom_generated.dart
@@ -22,6 +22,7 @@
 import 'package:analysis_server/src/protocol/protocol_internal.dart'
     show listEqual, mapEqual;
 import 'package:analyzer/src/generated/utilities_general.dart';
+import 'package:meta/meta.dart';
 
 const jsonEncoder = JsonEncoder.withIndent('    ');
 
@@ -29,14 +30,14 @@
   static const jsonHandler = LspJsonHandler(
       AnalyzerStatusParams.canParse, AnalyzerStatusParams.fromJson);
 
-  AnalyzerStatusParams(this.isAnalyzing) {
+  AnalyzerStatusParams({@required this.isAnalyzing}) {
     if (isAnalyzing == null) {
       throw 'isAnalyzing is required but was not provided';
     }
   }
   static AnalyzerStatusParams fromJson(Map<String, dynamic> json) {
     final isAnalyzing = json['isAnalyzing'];
-    return AnalyzerStatusParams(isAnalyzing);
+    return AnalyzerStatusParams(isAnalyzing: isAnalyzing);
   }
 
   final bool isAnalyzing;
@@ -98,7 +99,7 @@
   static const jsonHandler =
       LspJsonHandler(ClosingLabel.canParse, ClosingLabel.fromJson);
 
-  ClosingLabel(this.range, this.label) {
+  ClosingLabel({@required this.range, @required this.label}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -109,7 +110,7 @@
   static ClosingLabel fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final label = json['label'];
-    return ClosingLabel(range, label);
+    return ClosingLabel(range: range, label: label);
   }
 
   final String label;
@@ -190,8 +191,13 @@
       CompletionItemResolutionInfo.canParse,
       CompletionItemResolutionInfo.fromJson);
 
-  CompletionItemResolutionInfo(this.file, this.offset, this.libId,
-      this.displayUri, this.rOffset, this.rLength) {
+  CompletionItemResolutionInfo(
+      {@required this.file,
+      @required this.offset,
+      @required this.libId,
+      @required this.displayUri,
+      @required this.rOffset,
+      @required this.rLength}) {
     if (file == null) {
       throw 'file is required but was not provided';
     }
@@ -219,7 +225,12 @@
     final rOffset = json['rOffset'];
     final rLength = json['rLength'];
     return CompletionItemResolutionInfo(
-        file, offset, libId, displayUri, rOffset, rLength);
+        file: file,
+        offset: offset,
+        libId: libId,
+        displayUri: displayUri,
+        rOffset: rOffset,
+        rLength: rLength);
   }
 
   final String displayUri;
@@ -389,14 +400,14 @@
   static const jsonHandler = LspJsonHandler(
       DartDiagnosticServer.canParse, DartDiagnosticServer.fromJson);
 
-  DartDiagnosticServer(this.port) {
+  DartDiagnosticServer({@required this.port}) {
     if (port == null) {
       throw 'port is required but was not provided';
     }
   }
   static DartDiagnosticServer fromJson(Map<String, dynamic> json) {
     final port = json['port'];
-    return DartDiagnosticServer(port);
+    return DartDiagnosticServer(port: port);
   }
 
   final num port;
@@ -456,8 +467,13 @@
 class Element implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Element.canParse, Element.fromJson);
 
-  Element(this.range, this.name, this.kind, this.parameters,
-      this.typeParameters, this.returnType) {
+  Element(
+      {this.range,
+      @required this.name,
+      @required this.kind,
+      this.parameters,
+      this.typeParameters,
+      this.returnType}) {
     if (name == null) {
       throw 'name is required but was not provided';
     }
@@ -472,7 +488,13 @@
     final parameters = json['parameters'];
     final typeParameters = json['typeParameters'];
     final returnType = json['returnType'];
-    return Element(range, name, kind, parameters, typeParameters, returnType);
+    return Element(
+        range: range,
+        name: name,
+        kind: kind,
+        parameters: parameters,
+        typeParameters: typeParameters,
+        returnType: returnType);
   }
 
   final String kind;
@@ -616,15 +638,15 @@
       LspJsonHandler(FlutterOutline.canParse, FlutterOutline.fromJson);
 
   FlutterOutline(
-      this.kind,
+      {@required this.kind,
       this.label,
       this.className,
       this.variableName,
       this.attributes,
       this.dartElement,
-      this.range,
-      this.codeRange,
-      this.children) {
+      @required this.range,
+      @required this.codeRange,
+      this.children}) {
     if (kind == null) {
       throw 'kind is required but was not provided';
     }
@@ -655,8 +677,16 @@
         ?.map((item) => item != null ? FlutterOutline.fromJson(item) : null)
         ?.cast<FlutterOutline>()
         ?.toList();
-    return FlutterOutline(kind, label, className, variableName, attributes,
-        dartElement, range, codeRange, children);
+    return FlutterOutline(
+        kind: kind,
+        label: label,
+        className: className,
+        variableName: variableName,
+        attributes: attributes,
+        dartElement: dartElement,
+        range: range,
+        codeRange: codeRange,
+        children: children);
   }
 
   final List<FlutterOutlineAttribute> attributes;
@@ -862,7 +892,8 @@
   static const jsonHandler = LspJsonHandler(
       FlutterOutlineAttribute.canParse, FlutterOutlineAttribute.fromJson);
 
-  FlutterOutlineAttribute(this.name, this.label, this.valueRange) {
+  FlutterOutlineAttribute(
+      {@required this.name, @required this.label, this.valueRange}) {
     if (name == null) {
       throw 'name is required but was not provided';
     }
@@ -875,7 +906,8 @@
     final label = json['label'];
     final valueRange =
         json['valueRange'] != null ? Range.fromJson(json['valueRange']) : null;
-    return FlutterOutlineAttribute(name, label, valueRange);
+    return FlutterOutlineAttribute(
+        name: name, label: label, valueRange: valueRange);
   }
 
   final String label;
@@ -973,7 +1005,11 @@
 class Outline implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Outline.canParse, Outline.fromJson);
 
-  Outline(this.element, this.range, this.codeRange, this.children) {
+  Outline(
+      {@required this.element,
+      @required this.range,
+      @required this.codeRange,
+      this.children}) {
     if (element == null) {
       throw 'element is required but was not provided';
     }
@@ -994,7 +1030,11 @@
         ?.map((item) => item != null ? Outline.fromJson(item) : null)
         ?.cast<Outline>()
         ?.toList();
-    return Outline(element, range, codeRange, children);
+    return Outline(
+        element: element,
+        range: range,
+        codeRange: codeRange,
+        children: children);
   }
 
   final List<Outline> children;
@@ -1118,7 +1158,7 @@
   static const jsonHandler = LspJsonHandler(
       PublishClosingLabelsParams.canParse, PublishClosingLabelsParams.fromJson);
 
-  PublishClosingLabelsParams(this.uri, this.labels) {
+  PublishClosingLabelsParams({@required this.uri, @required this.labels}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -1132,7 +1172,7 @@
         ?.map((item) => item != null ? ClosingLabel.fromJson(item) : null)
         ?.cast<ClosingLabel>()
         ?.toList();
-    return PublishClosingLabelsParams(uri, labels);
+    return PublishClosingLabelsParams(uri: uri, labels: labels);
   }
 
   final List<ClosingLabel> labels;
@@ -1219,7 +1259,7 @@
       PublishFlutterOutlineParams.canParse,
       PublishFlutterOutlineParams.fromJson);
 
-  PublishFlutterOutlineParams(this.uri, this.outline) {
+  PublishFlutterOutlineParams({@required this.uri, @required this.outline}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -1232,7 +1272,7 @@
     final outline = json['outline'] != null
         ? FlutterOutline.fromJson(json['outline'])
         : null;
-    return PublishFlutterOutlineParams(uri, outline);
+    return PublishFlutterOutlineParams(uri: uri, outline: outline);
   }
 
   final FlutterOutline outline;
@@ -1314,7 +1354,7 @@
   static const jsonHandler = LspJsonHandler(
       PublishOutlineParams.canParse, PublishOutlineParams.fromJson);
 
-  PublishOutlineParams(this.uri, this.outline) {
+  PublishOutlineParams({@required this.uri, @required this.outline}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -1326,7 +1366,7 @@
     final uri = json['uri'];
     final outline =
         json['outline'] != null ? Outline.fromJson(json['outline']) : null;
-    return PublishOutlineParams(uri, outline);
+    return PublishOutlineParams(uri: uri, outline: outline);
   }
 
   final Outline outline;
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
index 39e2e89..1a6a820 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_generated.dart
@@ -22,6 +22,7 @@
 import 'package:analysis_server/src/protocol/protocol_internal.dart'
     show listEqual, mapEqual;
 import 'package:analyzer/src/generated/utilities_general.dart';
+import 'package:meta/meta.dart';
 
 const jsonEncoder = JsonEncoder.withIndent('    ');
 
@@ -29,7 +30,7 @@
   static const jsonHandler = LspJsonHandler(
       ApplyWorkspaceEditParams.canParse, ApplyWorkspaceEditParams.fromJson);
 
-  ApplyWorkspaceEditParams(this.label, this.edit) {
+  ApplyWorkspaceEditParams({this.label, @required this.edit}) {
     if (edit == null) {
       throw 'edit is required but was not provided';
     }
@@ -38,7 +39,7 @@
     final label = json['label'];
     final edit =
         json['edit'] != null ? WorkspaceEdit.fromJson(json['edit']) : null;
-    return ApplyWorkspaceEditParams(label, edit);
+    return ApplyWorkspaceEditParams(label: label, edit: edit);
   }
 
   /// The edits to apply.
@@ -117,7 +118,7 @@
   static const jsonHandler = LspJsonHandler(
       ApplyWorkspaceEditResponse.canParse, ApplyWorkspaceEditResponse.fromJson);
 
-  ApplyWorkspaceEditResponse(this.applied, this.failureReason) {
+  ApplyWorkspaceEditResponse({@required this.applied, this.failureReason}) {
     if (applied == null) {
       throw 'applied is required but was not provided';
     }
@@ -125,7 +126,8 @@
   static ApplyWorkspaceEditResponse fromJson(Map<String, dynamic> json) {
     final applied = json['applied'];
     final failureReason = json['failureReason'];
-    return ApplyWorkspaceEditResponse(applied, failureReason);
+    return ApplyWorkspaceEditResponse(
+        applied: applied, failureReason: failureReason);
   }
 
   /// Indicates whether the edit was applied or not.
@@ -208,7 +210,7 @@
   static const jsonHandler =
       LspJsonHandler(CancelParams.canParse, CancelParams.fromJson);
 
-  CancelParams(this.id) {
+  CancelParams({@required this.id}) {
     if (id == null) {
       throw 'id is required but was not provided';
     }
@@ -219,7 +221,7 @@
         : (json['id'] is String
             ? Either2<num, String>.t2(json['id'])
             : (throw '''${json['id']} was not one of (num, String)'''));
-    return CancelParams(id);
+    return CancelParams(id: id);
   }
 
   /// The request id to cancel.
@@ -280,16 +282,24 @@
   static const jsonHandler =
       LspJsonHandler(ClientCapabilities.canParse, ClientCapabilities.fromJson);
 
-  ClientCapabilities(this.workspace, this.textDocument, this.experimental);
+  ClientCapabilities(
+      {this.workspace, this.textDocument, this.window, this.experimental});
   static ClientCapabilities fromJson(Map<String, dynamic> json) {
     final workspace = json['workspace'] != null
-        ? WorkspaceClientCapabilities.fromJson(json['workspace'])
+        ? ClientCapabilitiesWorkspace.fromJson(json['workspace'])
         : null;
     final textDocument = json['textDocument'] != null
         ? TextDocumentClientCapabilities.fromJson(json['textDocument'])
         : null;
+    final window = json['window'] != null
+        ? ClientCapabilitiesWindow.fromJson(json['window'])
+        : null;
     final experimental = json['experimental'];
-    return ClientCapabilities(workspace, textDocument, experimental);
+    return ClientCapabilities(
+        workspace: workspace,
+        textDocument: textDocument,
+        window: window,
+        experimental: experimental);
   }
 
   /// Experimental client capabilities.
@@ -298,8 +308,11 @@
   /// Text document specific client capabilities.
   final TextDocumentClientCapabilities textDocument;
 
+  /// Window specific client capabilities.
+  final ClientCapabilitiesWindow window;
+
   /// Workspace specific client capabilities.
-  final WorkspaceClientCapabilities workspace;
+  final ClientCapabilitiesWorkspace workspace;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
@@ -309,6 +322,9 @@
     if (textDocument != null) {
       __result['textDocument'] = textDocument;
     }
+    if (window != null) {
+      __result['window'] = window;
+    }
     if (experimental != null) {
       __result['experimental'] = experimental;
     }
@@ -320,9 +336,9 @@
       reporter.push('workspace');
       try {
         if (obj['workspace'] != null &&
-            !(WorkspaceClientCapabilities.canParse(
+            !(ClientCapabilitiesWorkspace.canParse(
                 obj['workspace'], reporter))) {
-          reporter.reportError('must be of type WorkspaceClientCapabilities');
+          reporter.reportError('must be of type ClientCapabilitiesWorkspace');
           return false;
         }
       } finally {
@@ -340,6 +356,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('window');
+      try {
+        if (obj['window'] != null &&
+            !(ClientCapabilitiesWindow.canParse(obj['window'], reporter))) {
+          reporter.reportError('must be of type ClientCapabilitiesWindow');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('experimental');
       try {
         if (obj['experimental'] != null && !(true)) {
@@ -362,6 +388,7 @@
         other.runtimeType == ClientCapabilities) {
       return workspace == other.workspace &&
           textDocument == other.textDocument &&
+          window == other.window &&
           experimental == other.experimental &&
           true;
     }
@@ -373,6 +400,7 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, workspace.hashCode);
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, window.hashCode);
     hash = JenkinsSmiHash.combine(hash, experimental.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
@@ -381,6 +409,308 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class ClientCapabilitiesWindow implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ClientCapabilitiesWindow.canParse, ClientCapabilitiesWindow.fromJson);
+
+  ClientCapabilitiesWindow({this.workDoneProgress});
+  static ClientCapabilitiesWindow fromJson(Map<String, dynamic> json) {
+    final workDoneProgress = json['workDoneProgress'];
+    return ClientCapabilitiesWindow(workDoneProgress: workDoneProgress);
+  }
+
+  /// Whether client supports handling progress notifications. If set servers
+  /// are allowed to report in `workDoneProgress` property in the request
+  /// specific server capabilities.
+  ///
+  /// Since 3.15.0
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ClientCapabilitiesWindow');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ClientCapabilitiesWindow &&
+        other.runtimeType == ClientCapabilitiesWindow) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ClientCapabilitiesWorkspace implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ClientCapabilitiesWorkspace.canParse,
+      ClientCapabilitiesWorkspace.fromJson);
+
+  ClientCapabilitiesWorkspace(
+      {this.applyEdit,
+      this.workspaceEdit,
+      this.didChangeConfiguration,
+      this.didChangeWatchedFiles,
+      this.symbol,
+      this.executeCommand,
+      this.workspaceFolders,
+      this.configuration});
+  static ClientCapabilitiesWorkspace fromJson(Map<String, dynamic> json) {
+    final applyEdit = json['applyEdit'];
+    final workspaceEdit = json['workspaceEdit'] != null
+        ? WorkspaceEditClientCapabilities.fromJson(json['workspaceEdit'])
+        : null;
+    final didChangeConfiguration = json['didChangeConfiguration'] != null
+        ? DidChangeConfigurationClientCapabilities.fromJson(
+            json['didChangeConfiguration'])
+        : null;
+    final didChangeWatchedFiles = json['didChangeWatchedFiles'] != null
+        ? DidChangeWatchedFilesClientCapabilities.fromJson(
+            json['didChangeWatchedFiles'])
+        : null;
+    final symbol = json['symbol'] != null
+        ? WorkspaceSymbolClientCapabilities.fromJson(json['symbol'])
+        : null;
+    final executeCommand = json['executeCommand'] != null
+        ? ExecuteCommandClientCapabilities.fromJson(json['executeCommand'])
+        : null;
+    final workspaceFolders = json['workspaceFolders'];
+    final configuration = json['configuration'];
+    return ClientCapabilitiesWorkspace(
+        applyEdit: applyEdit,
+        workspaceEdit: workspaceEdit,
+        didChangeConfiguration: didChangeConfiguration,
+        didChangeWatchedFiles: didChangeWatchedFiles,
+        symbol: symbol,
+        executeCommand: executeCommand,
+        workspaceFolders: workspaceFolders,
+        configuration: configuration);
+  }
+
+  /// The client supports applying batch edits to the workspace by supporting
+  /// the request 'workspace/applyEdit'
+  final bool applyEdit;
+
+  /// The client supports `workspace/configuration` requests.
+  ///
+  /// Since 3.6.0
+  final bool configuration;
+
+  /// Capabilities specific to the `workspace/didChangeConfiguration`
+  /// notification.
+  final DidChangeConfigurationClientCapabilities didChangeConfiguration;
+
+  /// Capabilities specific to the `workspace/didChangeWatchedFiles`
+  /// notification.
+  final DidChangeWatchedFilesClientCapabilities didChangeWatchedFiles;
+
+  /// Capabilities specific to the `workspace/executeCommand` request.
+  final ExecuteCommandClientCapabilities executeCommand;
+
+  /// Capabilities specific to the `workspace/symbol` request.
+  final WorkspaceSymbolClientCapabilities symbol;
+
+  /// Capabilities specific to `WorkspaceEdit`s
+  final WorkspaceEditClientCapabilities workspaceEdit;
+
+  /// The client has support for workspace folders.
+  ///
+  /// Since 3.6.0
+  final bool workspaceFolders;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (applyEdit != null) {
+      __result['applyEdit'] = applyEdit;
+    }
+    if (workspaceEdit != null) {
+      __result['workspaceEdit'] = workspaceEdit;
+    }
+    if (didChangeConfiguration != null) {
+      __result['didChangeConfiguration'] = didChangeConfiguration;
+    }
+    if (didChangeWatchedFiles != null) {
+      __result['didChangeWatchedFiles'] = didChangeWatchedFiles;
+    }
+    if (symbol != null) {
+      __result['symbol'] = symbol;
+    }
+    if (executeCommand != null) {
+      __result['executeCommand'] = executeCommand;
+    }
+    if (workspaceFolders != null) {
+      __result['workspaceFolders'] = workspaceFolders;
+    }
+    if (configuration != null) {
+      __result['configuration'] = configuration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('applyEdit');
+      try {
+        if (obj['applyEdit'] != null && !(obj['applyEdit'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workspaceEdit');
+      try {
+        if (obj['workspaceEdit'] != null &&
+            !(WorkspaceEditClientCapabilities.canParse(
+                obj['workspaceEdit'], reporter))) {
+          reporter
+              .reportError('must be of type WorkspaceEditClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('didChangeConfiguration');
+      try {
+        if (obj['didChangeConfiguration'] != null &&
+            !(DidChangeConfigurationClientCapabilities.canParse(
+                obj['didChangeConfiguration'], reporter))) {
+          reporter.reportError(
+              'must be of type DidChangeConfigurationClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('didChangeWatchedFiles');
+      try {
+        if (obj['didChangeWatchedFiles'] != null &&
+            !(DidChangeWatchedFilesClientCapabilities.canParse(
+                obj['didChangeWatchedFiles'], reporter))) {
+          reporter.reportError(
+              'must be of type DidChangeWatchedFilesClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('symbol');
+      try {
+        if (obj['symbol'] != null &&
+            !(WorkspaceSymbolClientCapabilities.canParse(
+                obj['symbol'], reporter))) {
+          reporter
+              .reportError('must be of type WorkspaceSymbolClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('executeCommand');
+      try {
+        if (obj['executeCommand'] != null &&
+            !(ExecuteCommandClientCapabilities.canParse(
+                obj['executeCommand'], reporter))) {
+          reporter
+              .reportError('must be of type ExecuteCommandClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workspaceFolders');
+      try {
+        if (obj['workspaceFolders'] != null &&
+            !(obj['workspaceFolders'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('configuration');
+      try {
+        if (obj['configuration'] != null && !(obj['configuration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ClientCapabilitiesWorkspace');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ClientCapabilitiesWorkspace &&
+        other.runtimeType == ClientCapabilitiesWorkspace) {
+      return applyEdit == other.applyEdit &&
+          workspaceEdit == other.workspaceEdit &&
+          didChangeConfiguration == other.didChangeConfiguration &&
+          didChangeWatchedFiles == other.didChangeWatchedFiles &&
+          symbol == other.symbol &&
+          executeCommand == other.executeCommand &&
+          workspaceFolders == other.workspaceFolders &&
+          configuration == other.configuration &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, applyEdit.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workspaceEdit.hashCode);
+    hash = JenkinsSmiHash.combine(hash, didChangeConfiguration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, didChangeWatchedFiles.hashCode);
+    hash = JenkinsSmiHash.combine(hash, symbol.hashCode);
+    hash = JenkinsSmiHash.combine(hash, executeCommand.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workspaceFolders.hashCode);
+    hash = JenkinsSmiHash.combine(hash, configuration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// A code action represents a change that can be performed in code, e.g. to fix
 /// a problem or to refactor code.
 ///
@@ -390,7 +720,13 @@
   static const jsonHandler =
       LspJsonHandler(CodeAction.canParse, CodeAction.fromJson);
 
-  CodeAction(this.title, this.kind, this.diagnostics, this.edit, this.command) {
+  CodeAction(
+      {@required this.title,
+      this.kind,
+      this.diagnostics,
+      this.isPreferred,
+      this.edit,
+      this.command}) {
     if (title == null) {
       throw 'title is required but was not provided';
     }
@@ -403,11 +739,18 @@
         ?.map((item) => item != null ? Diagnostic.fromJson(item) : null)
         ?.cast<Diagnostic>()
         ?.toList();
+    final isPreferred = json['isPreferred'];
     final edit =
         json['edit'] != null ? WorkspaceEdit.fromJson(json['edit']) : null;
     final command =
         json['command'] != null ? Command.fromJson(json['command']) : null;
-    return CodeAction(title, kind, diagnostics, edit, command);
+    return CodeAction(
+        title: title,
+        kind: kind,
+        diagnostics: diagnostics,
+        isPreferred: isPreferred,
+        edit: edit,
+        command: command);
   }
 
   /// A command this code action executes. If a code action provides an edit and
@@ -420,6 +763,15 @@
   /// The workspace edit this code action performs.
   final WorkspaceEdit edit;
 
+  /// Marks this as a preferred action. Preferred actions are used by the `auto
+  /// fix` command and can be targeted by keybindings.
+  ///
+  /// A quick fix should be marked preferred if it properly addresses the
+  /// underlying error. A refactoring should be marked preferred if it is the
+  /// most reasonable choice of actions to take.
+  ///  @since 3.15.0
+  final bool isPreferred;
+
   /// The kind of the code action.
   ///
   /// Used to filter code actions.
@@ -437,6 +789,9 @@
     if (diagnostics != null) {
       __result['diagnostics'] = diagnostics;
     }
+    if (isPreferred != null) {
+      __result['isPreferred'] = isPreferred;
+    }
     if (edit != null) {
       __result['edit'] = edit;
     }
@@ -487,6 +842,15 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('isPreferred');
+      try {
+        if (obj['isPreferred'] != null && !(obj['isPreferred'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('edit');
       try {
         if (obj['edit'] != null &&
@@ -521,6 +885,7 @@
           kind == other.kind &&
           listEqual(diagnostics, other.diagnostics,
               (Diagnostic a, Diagnostic b) => a == b) &&
+          isPreferred == other.isPreferred &&
           edit == other.edit &&
           command == other.command &&
           true;
@@ -534,6 +899,7 @@
     hash = JenkinsSmiHash.combine(hash, title.hashCode);
     hash = JenkinsSmiHash.combine(hash, kind.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(diagnostics));
+    hash = JenkinsSmiHash.combine(hash, isPreferred.hashCode);
     hash = JenkinsSmiHash.combine(hash, edit.hashCode);
     hash = JenkinsSmiHash.combine(hash, command.hashCode);
     return JenkinsSmiHash.finish(hash);
@@ -543,13 +909,291 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class CodeActionClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CodeActionClientCapabilities.canParse,
+      CodeActionClientCapabilities.fromJson);
+
+  CodeActionClientCapabilities(
+      {this.dynamicRegistration,
+      this.codeActionLiteralSupport,
+      this.isPreferredSupport});
+  static CodeActionClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final codeActionLiteralSupport = json['codeActionLiteralSupport'] != null
+        ? CodeActionClientCapabilitiesCodeActionLiteralSupport.fromJson(
+            json['codeActionLiteralSupport'])
+        : null;
+    final isPreferredSupport = json['isPreferredSupport'];
+    return CodeActionClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        codeActionLiteralSupport: codeActionLiteralSupport,
+        isPreferredSupport: isPreferredSupport);
+  }
+
+  /// The client supports code action literals as a valid response of the
+  /// `textDocument/codeAction` request.
+  ///  @since 3.8.0
+  final CodeActionClientCapabilitiesCodeActionLiteralSupport
+      codeActionLiteralSupport;
+
+  /// Whether code action supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// Whether code action supports the `isPreferred` property. @since 3.15.0
+  final bool isPreferredSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (codeActionLiteralSupport != null) {
+      __result['codeActionLiteralSupport'] = codeActionLiteralSupport;
+    }
+    if (isPreferredSupport != null) {
+      __result['isPreferredSupport'] = isPreferredSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('codeActionLiteralSupport');
+      try {
+        if (obj['codeActionLiteralSupport'] != null &&
+            !(CodeActionClientCapabilitiesCodeActionLiteralSupport.canParse(
+                obj['codeActionLiteralSupport'], reporter))) {
+          reporter.reportError(
+              'must be of type CodeActionClientCapabilitiesCodeActionLiteralSupport');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('isPreferredSupport');
+      try {
+        if (obj['isPreferredSupport'] != null &&
+            !(obj['isPreferredSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type CodeActionClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CodeActionClientCapabilities &&
+        other.runtimeType == CodeActionClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          codeActionLiteralSupport == other.codeActionLiteralSupport &&
+          isPreferredSupport == other.isPreferredSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, codeActionLiteralSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, isPreferredSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CodeActionClientCapabilitiesCodeActionKind implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CodeActionClientCapabilitiesCodeActionKind.canParse,
+      CodeActionClientCapabilitiesCodeActionKind.fromJson);
+
+  CodeActionClientCapabilitiesCodeActionKind({@required this.valueSet}) {
+    if (valueSet == null) {
+      throw 'valueSet is required but was not provided';
+    }
+  }
+  static CodeActionClientCapabilitiesCodeActionKind fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? CodeActionKind.fromJson(item) : null)
+        ?.cast<CodeActionKind>()
+        ?.toList();
+    return CodeActionClientCapabilitiesCodeActionKind(valueSet: valueSet);
+  }
+
+  /// The code action kind values the client supports. When this property exists
+  /// the client also guarantees that it will handle values outside its set
+  /// gracefully and falls back to a default value when unknown.
+  final List<CodeActionKind> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['valueSet'] =
+        valueSet ?? (throw 'valueSet is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (!obj.containsKey('valueSet')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['valueSet'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['valueSet'] is List &&
+            (obj['valueSet']
+                .every((item) => CodeActionKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<CodeActionKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type CodeActionClientCapabilitiesCodeActionKind');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CodeActionClientCapabilitiesCodeActionKind &&
+        other.runtimeType == CodeActionClientCapabilitiesCodeActionKind) {
+      return listEqual(valueSet, other.valueSet,
+              (CodeActionKind a, CodeActionKind b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CodeActionClientCapabilitiesCodeActionLiteralSupport
+    implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CodeActionClientCapabilitiesCodeActionLiteralSupport.canParse,
+      CodeActionClientCapabilitiesCodeActionLiteralSupport.fromJson);
+
+  CodeActionClientCapabilitiesCodeActionLiteralSupport(
+      {@required this.codeActionKind}) {
+    if (codeActionKind == null) {
+      throw 'codeActionKind is required but was not provided';
+    }
+  }
+  static CodeActionClientCapabilitiesCodeActionLiteralSupport fromJson(
+      Map<String, dynamic> json) {
+    final codeActionKind = json['codeActionKind'] != null
+        ? CodeActionClientCapabilitiesCodeActionKind.fromJson(
+            json['codeActionKind'])
+        : null;
+    return CodeActionClientCapabilitiesCodeActionLiteralSupport(
+        codeActionKind: codeActionKind);
+  }
+
+  /// The code action kind is supported with the following value set.
+  final CodeActionClientCapabilitiesCodeActionKind codeActionKind;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['codeActionKind'] =
+        codeActionKind ?? (throw 'codeActionKind is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('codeActionKind');
+      try {
+        if (!obj.containsKey('codeActionKind')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['codeActionKind'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(CodeActionClientCapabilitiesCodeActionKind.canParse(
+            obj['codeActionKind'], reporter))) {
+          reporter.reportError(
+              'must be of type CodeActionClientCapabilitiesCodeActionKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type CodeActionClientCapabilitiesCodeActionLiteralSupport');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CodeActionClientCapabilitiesCodeActionLiteralSupport &&
+        other.runtimeType ==
+            CodeActionClientCapabilitiesCodeActionLiteralSupport) {
+      return codeActionKind == other.codeActionKind && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, codeActionKind.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Contains additional diagnostic information about the context in which a code
 /// action is run.
 class CodeActionContext implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CodeActionContext.canParse, CodeActionContext.fromJson);
 
-  CodeActionContext(this.diagnostics, this.only) {
+  CodeActionContext({@required this.diagnostics, this.only}) {
     if (diagnostics == null) {
       throw 'diagnostics is required but was not provided';
     }
@@ -563,10 +1207,15 @@
         ?.map((item) => item != null ? CodeActionKind.fromJson(item) : null)
         ?.cast<CodeActionKind>()
         ?.toList();
-    return CodeActionContext(diagnostics, only);
+    return CodeActionContext(diagnostics: diagnostics, only: only);
   }
 
-  /// An array of diagnostics.
+  /// An array of diagnostics known on the client side overlapping the range
+  /// provided to the `textDocument/codeAction` request. They are provided so
+  /// that the server knows which errors are currently presented to the user for
+  /// the given range. There is no guarantee that these accurately reflect the
+  /// error state of the resource. The primary parameter to compute code actions
+  /// is the provided range.
   final List<Diagnostic> diagnostics;
 
   /// Requested kind of actions to return.
@@ -649,7 +1298,7 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// A set of predefined code action kinds
+/// A set of predefined code action kinds.
 class CodeActionKind {
   const CodeActionKind(this._value);
   const CodeActionKind.fromJson(this._value);
@@ -663,13 +1312,13 @@
   /// Empty kind.
   static const Empty = CodeActionKind('');
 
-  /// Base kind for quickfix actions: 'quickfix'
+  /// Base kind for quickfix actions: 'quickfix'.
   static const QuickFix = CodeActionKind('quickfix');
 
-  /// Base kind for refactoring actions: 'refactor'
+  /// Base kind for refactoring actions: 'refactor'.
   static const Refactor = CodeActionKind('refactor');
 
-  /// Base kind for refactoring extraction actions: 'refactor.extract'
+  /// Base kind for refactoring extraction actions: 'refactor.extract'.
   ///
   /// Example extract actions:
   ///
@@ -680,7 +1329,7 @@
   /// - ...
   static const RefactorExtract = CodeActionKind('refactor.extract');
 
-  /// Base kind for refactoring inline actions: 'refactor.inline'
+  /// Base kind for refactoring inline actions: 'refactor.inline'.
   ///
   /// Example inline actions:
   ///
@@ -690,7 +1339,7 @@
   /// - ...
   static const RefactorInline = CodeActionKind('refactor.inline');
 
-  /// Base kind for refactoring rewrite actions: 'refactor.rewrite'
+  /// Base kind for refactoring rewrite actions: 'refactor.rewrite'.
   ///
   /// Example rewrite actions:
   ///
@@ -702,12 +1351,12 @@
   /// - ...
   static const RefactorRewrite = CodeActionKind('refactor.rewrite');
 
-  /// Base kind for source actions: `source`
+  /// Base kind for source actions: `source`.
   ///
   /// Source code actions apply to the entire file.
   static const Source = CodeActionKind('source');
 
-  /// Base kind for an organize imports source action: `source.organizeImports`
+  /// Base kind for an organize imports source action: `source.organizeImports`.
   static const SourceOrganizeImports = CodeActionKind('source.organizeImports');
 
   Object toJson() => _value;
@@ -721,12 +1370,11 @@
   bool operator ==(Object o) => o is CodeActionKind && o._value == _value;
 }
 
-/// Code Action options.
-class CodeActionOptions implements ToJsonable {
+class CodeActionOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CodeActionOptions.canParse, CodeActionOptions.fromJson);
 
-  CodeActionOptions(this.codeActionKinds);
+  CodeActionOptions({this.codeActionKinds, this.workDoneProgress});
   static CodeActionOptions fromJson(Map<String, dynamic> json) {
     if (CodeActionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return CodeActionRegistrationOptions.fromJson(json);
@@ -735,7 +1383,9 @@
         ?.map((item) => item != null ? CodeActionKind.fromJson(item) : null)
         ?.cast<CodeActionKind>()
         ?.toList();
-    return CodeActionOptions(codeActionKinds);
+    final workDoneProgress = json['workDoneProgress'];
+    return CodeActionOptions(
+        codeActionKinds: codeActionKinds, workDoneProgress: workDoneProgress);
   }
 
   /// CodeActionKinds that this server may return.
@@ -743,12 +1393,16 @@
   /// The list of kinds may be generic, such as `CodeActionKind.Refactor`, or
   /// the server may list out every specific kind they provide.
   final List<CodeActionKind> codeActionKinds;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (codeActionKinds != null) {
       __result['codeActionKinds'] = codeActionKinds;
     }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -766,6 +1420,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeActionOptions');
@@ -778,6 +1442,7 @@
     if (other is CodeActionOptions && other.runtimeType == CodeActionOptions) {
       return listEqual(codeActionKinds, other.codeActionKinds,
               (CodeActionKind a, CodeActionKind b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -787,6 +1452,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, lspHashCode(codeActionKinds));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -795,11 +1461,17 @@
 }
 
 /// Params for the CodeActionRequest
-class CodeActionParams implements ToJsonable {
+class CodeActionParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CodeActionParams.canParse, CodeActionParams.fromJson);
 
-  CodeActionParams(this.textDocument, this.range, this.context) {
+  CodeActionParams(
+      {@required this.textDocument,
+      @required this.range,
+      @required this.context,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -818,18 +1490,44 @@
     final context = json['context'] != null
         ? CodeActionContext.fromJson(json['context'])
         : null;
-    return CodeActionParams(textDocument, range, context);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return CodeActionParams(
+        textDocument: textDocument,
+        range: range,
+        context: context,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
   /// Context carrying additional information.
   final CodeActionContext context;
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The range for which the command was invoked.
   final Range range;
 
   /// The document in which the command was invoked.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
@@ -837,6 +1535,12 @@
     __result['range'] = range ?? (throw 'range is required but was not set');
     __result['context'] =
         context ?? (throw 'context is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -893,6 +1597,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeActionParams');
@@ -906,6 +1632,8 @@
       return textDocument == other.textDocument &&
           range == other.range &&
           context == other.context &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
           true;
     }
     return false;
@@ -917,6 +1645,8 @@
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, range.hashCode);
     hash = JenkinsSmiHash.combine(hash, context.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -930,7 +1660,8 @@
       CodeActionRegistrationOptions.canParse,
       CodeActionRegistrationOptions.fromJson);
 
-  CodeActionRegistrationOptions(this.documentSelector, this.codeActionKinds);
+  CodeActionRegistrationOptions(
+      {this.documentSelector, this.codeActionKinds, this.workDoneProgress});
   static CodeActionRegistrationOptions fromJson(Map<String, dynamic> json) {
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
@@ -940,7 +1671,11 @@
         ?.map((item) => item != null ? CodeActionKind.fromJson(item) : null)
         ?.cast<CodeActionKind>()
         ?.toList();
-    return CodeActionRegistrationOptions(documentSelector, codeActionKinds);
+    final workDoneProgress = json['workDoneProgress'];
+    return CodeActionRegistrationOptions(
+        documentSelector: documentSelector,
+        codeActionKinds: codeActionKinds,
+        workDoneProgress: workDoneProgress);
   }
 
   /// CodeActionKinds that this server may return.
@@ -952,6 +1687,7 @@
   /// A document selector to identify the scope of the registration. If set to
   /// null the document selector provided on the client side will be used.
   final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
@@ -959,6 +1695,9 @@
     if (codeActionKinds != null) {
       __result['codeActionKinds'] = codeActionKinds;
     }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -992,6 +1731,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeActionRegistrationOptions');
@@ -1007,6 +1756,7 @@
               (DocumentFilter a, DocumentFilter b) => a == b) &&
           listEqual(codeActionKinds, other.codeActionKinds,
               (CodeActionKind a, CodeActionKind b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -1017,6 +1767,7 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
     hash = JenkinsSmiHash.combine(hash, lspHashCode(codeActionKinds));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -1034,7 +1785,7 @@
   static const jsonHandler =
       LspJsonHandler(CodeLens.canParse, CodeLens.fromJson);
 
-  CodeLens(this.range, this.command, this.data) {
+  CodeLens({@required this.range, this.command, this.data}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -1044,7 +1795,7 @@
     final command =
         json['command'] != null ? Command.fromJson(json['command']) : null;
     final data = json['data'];
-    return CodeLens(range, command, data);
+    return CodeLens(range: range, command: command, data: data);
   }
 
   /// The command this code lens represents.
@@ -1139,25 +1890,93 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Code Lens options.
-class CodeLensOptions implements ToJsonable {
+class CodeLensClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CodeLensClientCapabilities.canParse, CodeLensClientCapabilities.fromJson);
+
+  CodeLensClientCapabilities({this.dynamicRegistration});
+  static CodeLensClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return CodeLensClientCapabilities(dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether code lens supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type CodeLensClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CodeLensClientCapabilities &&
+        other.runtimeType == CodeLensClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CodeLensOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CodeLensOptions.canParse, CodeLensOptions.fromJson);
 
-  CodeLensOptions(this.resolveProvider);
+  CodeLensOptions({this.resolveProvider, this.workDoneProgress});
   static CodeLensOptions fromJson(Map<String, dynamic> json) {
+    if (CodeLensRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return CodeLensRegistrationOptions.fromJson(json);
+    }
     final resolveProvider = json['resolveProvider'];
-    return CodeLensOptions(resolveProvider);
+    final workDoneProgress = json['workDoneProgress'];
+    return CodeLensOptions(
+        resolveProvider: resolveProvider, workDoneProgress: workDoneProgress);
   }
 
   /// Code lens has a resolve provider as well.
   final bool resolveProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -1173,6 +1992,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeLensOptions');
@@ -1183,7 +2012,9 @@
   @override
   bool operator ==(Object other) {
     if (other is CodeLensOptions && other.runtimeType == CodeLensOptions) {
-      return resolveProvider == other.resolveProvider && true;
+      return resolveProvider == other.resolveProvider &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
     }
     return false;
   }
@@ -1192,6 +2023,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -1199,11 +2031,15 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class CodeLensParams implements ToJsonable {
+class CodeLensParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CodeLensParams.canParse, CodeLensParams.fromJson);
 
-  CodeLensParams(this.textDocument) {
+  CodeLensParams(
+      {@required this.textDocument,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -1212,16 +2048,46 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
-    return CodeLensParams(textDocument);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return CodeLensParams(
+        textDocument: textDocument,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The document to request code lens for.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -1244,6 +2110,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeLensParams');
@@ -1254,7 +2142,10 @@
   @override
   bool operator ==(Object other) {
     if (other is CodeLensParams && other.runtimeType == CodeLensParams) {
-      return textDocument == other.textDocument && true;
+      return textDocument == other.textDocument &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
     }
     return false;
   }
@@ -1263,6 +2154,8 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -1271,19 +2164,24 @@
 }
 
 class CodeLensRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements TextDocumentRegistrationOptions, CodeLensOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       CodeLensRegistrationOptions.canParse,
       CodeLensRegistrationOptions.fromJson);
 
-  CodeLensRegistrationOptions(this.resolveProvider, this.documentSelector);
+  CodeLensRegistrationOptions(
+      {this.documentSelector, this.resolveProvider, this.workDoneProgress});
   static CodeLensRegistrationOptions fromJson(Map<String, dynamic> json) {
-    final resolveProvider = json['resolveProvider'];
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return CodeLensRegistrationOptions(resolveProvider, documentSelector);
+    final resolveProvider = json['resolveProvider'];
+    final workDoneProgress = json['workDoneProgress'];
+    return CodeLensRegistrationOptions(
+        documentSelector: documentSelector,
+        resolveProvider: resolveProvider,
+        workDoneProgress: workDoneProgress);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -1292,28 +2190,22 @@
 
   /// Code lens has a resolve provider as well.
   final bool resolveProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
-    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('resolveProvider');
-      try {
-        if (obj['resolveProvider'] != null &&
-            !(obj['resolveProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('documentSelector');
       try {
         if (!obj.containsKey('documentSelector')) {
@@ -1330,6 +2222,26 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('resolveProvider');
+      try {
+        if (obj['resolveProvider'] != null &&
+            !(obj['resolveProvider'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CodeLensRegistrationOptions');
@@ -1341,9 +2253,10 @@
   bool operator ==(Object other) {
     if (other is CodeLensRegistrationOptions &&
         other.runtimeType == CodeLensRegistrationOptions) {
-      return resolveProvider == other.resolveProvider &&
-          listEqual(documentSelector, other.documentSelector,
+      return listEqual(documentSelector, other.documentSelector,
               (DocumentFilter a, DocumentFilter b) => a == b) &&
+          resolveProvider == other.resolveProvider &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -1352,8 +2265,9 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -1365,7 +2279,11 @@
 class Color implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Color.canParse, Color.fromJson);
 
-  Color(this.red, this.green, this.blue, this.alpha) {
+  Color(
+      {@required this.red,
+      @required this.green,
+      @required this.blue,
+      @required this.alpha}) {
     if (red == null) {
       throw 'red is required but was not provided';
     }
@@ -1384,7 +2302,7 @@
     final green = json['green'];
     final blue = json['blue'];
     final alpha = json['alpha'];
-    return Color(red, green, blue, alpha);
+    return Color(red: red, green: green, blue: blue, alpha: alpha);
   }
 
   /// The alpha component of this color in the range [0-1].
@@ -1515,7 +2433,7 @@
   static const jsonHandler =
       LspJsonHandler(ColorInformation.canParse, ColorInformation.fromJson);
 
-  ColorInformation(this.range, this.color) {
+  ColorInformation({@required this.range, @required this.color}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -1526,7 +2444,7 @@
   static ColorInformation fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final color = json['color'] != null ? Color.fromJson(json['color']) : null;
-    return ColorInformation(range, color);
+    return ColorInformation(range: range, color: color);
   }
 
   /// The actual color value for this color range.
@@ -1609,7 +2527,8 @@
   static const jsonHandler =
       LspJsonHandler(ColorPresentation.canParse, ColorPresentation.fromJson);
 
-  ColorPresentation(this.label, this.textEdit, this.additionalTextEdits) {
+  ColorPresentation(
+      {@required this.label, this.textEdit, this.additionalTextEdits}) {
     if (label == null) {
       throw 'label is required but was not provided';
     }
@@ -1622,7 +2541,10 @@
         ?.map((item) => item != null ? TextEdit.fromJson(item) : null)
         ?.cast<TextEdit>()
         ?.toList();
-    return ColorPresentation(label, textEdit, additionalTextEdits);
+    return ColorPresentation(
+        label: label,
+        textEdit: textEdit,
+        additionalTextEdits: additionalTextEdits);
   }
 
   /// An optional array of additional text edits ([TextEdit]) that are applied
@@ -1725,11 +2647,17 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class ColorPresentationParams implements ToJsonable {
+class ColorPresentationParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       ColorPresentationParams.canParse, ColorPresentationParams.fromJson);
 
-  ColorPresentationParams(this.textDocument, this.color, this.range) {
+  ColorPresentationParams(
+      {@required this.textDocument,
+      @required this.color,
+      @required this.range,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -1746,24 +2674,56 @@
         : null;
     final color = json['color'] != null ? Color.fromJson(json['color']) : null;
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
-    return ColorPresentationParams(textDocument, color, range);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return ColorPresentationParams(
+        textDocument: textDocument,
+        color: color,
+        range: range,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
   /// The color information to request presentations for.
   final Color color;
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The range where the color would be inserted. Serves as a context.
   final Range range;
 
   /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['color'] = color ?? (throw 'color is required but was not set');
     __result['range'] = range ?? (throw 'range is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -1820,6 +2780,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type ColorPresentationParams');
@@ -1834,6 +2816,8 @@
       return textDocument == other.textDocument &&
           color == other.color &&
           range == other.range &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
           true;
     }
     return false;
@@ -1845,48 +2829,8 @@
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, color.hashCode);
     hash = JenkinsSmiHash.combine(hash, range.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-/// Color provider options.
-class ColorProviderOptions implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      ColorProviderOptions.canParse, ColorProviderOptions.fromJson);
-
-  static ColorProviderOptions fromJson(Map<String, dynamic> json) {
-    return ColorProviderOptions();
-  }
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      return true;
-    } else {
-      reporter.reportError('must be of type ColorProviderOptions');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is ColorProviderOptions &&
-        other.runtimeType == ColorProviderOptions) {
-      return true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -1897,7 +2841,7 @@
 class Command implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Command.canParse, Command.fromJson);
 
-  Command(this.title, this.command, this.arguments) {
+  Command({@required this.title, @required this.command, this.arguments}) {
     if (title == null) {
       throw 'title is required but was not provided';
     }
@@ -1910,7 +2854,7 @@
     final command = json['command'];
     final arguments =
         json['arguments']?.map((item) => item)?.cast<dynamic>()?.toList();
-    return Command(title, command, arguments);
+    return Command(title: title, command: command, arguments: arguments);
   }
 
   /// Arguments that the command handler should be invoked with.
@@ -2012,13 +2956,494 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class CompletionClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CompletionClientCapabilities.canParse,
+      CompletionClientCapabilities.fromJson);
+
+  CompletionClientCapabilities(
+      {this.dynamicRegistration,
+      this.completionItem,
+      this.completionItemKind,
+      this.contextSupport});
+  static CompletionClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final completionItem = json['completionItem'] != null
+        ? CompletionClientCapabilitiesCompletionItem.fromJson(
+            json['completionItem'])
+        : null;
+    final completionItemKind = json['completionItemKind'] != null
+        ? CompletionClientCapabilitiesCompletionItemKind.fromJson(
+            json['completionItemKind'])
+        : null;
+    final contextSupport = json['contextSupport'];
+    return CompletionClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        completionItem: completionItem,
+        completionItemKind: completionItemKind,
+        contextSupport: contextSupport);
+  }
+
+  /// The client supports the following `CompletionItem` specific capabilities.
+  final CompletionClientCapabilitiesCompletionItem completionItem;
+  final CompletionClientCapabilitiesCompletionItemKind completionItemKind;
+
+  /// The client supports to send additional context information for a
+  /// `textDocument/completion` request.
+  final bool contextSupport;
+
+  /// Whether completion supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (completionItem != null) {
+      __result['completionItem'] = completionItem;
+    }
+    if (completionItemKind != null) {
+      __result['completionItemKind'] = completionItemKind;
+    }
+    if (contextSupport != null) {
+      __result['contextSupport'] = contextSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('completionItem');
+      try {
+        if (obj['completionItem'] != null &&
+            !(CompletionClientCapabilitiesCompletionItem.canParse(
+                obj['completionItem'], reporter))) {
+          reporter.reportError(
+              'must be of type CompletionClientCapabilitiesCompletionItem');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('completionItemKind');
+      try {
+        if (obj['completionItemKind'] != null &&
+            !(CompletionClientCapabilitiesCompletionItemKind.canParse(
+                obj['completionItemKind'], reporter))) {
+          reporter.reportError(
+              'must be of type CompletionClientCapabilitiesCompletionItemKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('contextSupport');
+      try {
+        if (obj['contextSupport'] != null && !(obj['contextSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type CompletionClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CompletionClientCapabilities &&
+        other.runtimeType == CompletionClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          completionItem == other.completionItem &&
+          completionItemKind == other.completionItemKind &&
+          contextSupport == other.contextSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, completionItem.hashCode);
+    hash = JenkinsSmiHash.combine(hash, completionItemKind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, contextSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CompletionClientCapabilitiesCompletionItem implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CompletionClientCapabilitiesCompletionItem.canParse,
+      CompletionClientCapabilitiesCompletionItem.fromJson);
+
+  CompletionClientCapabilitiesCompletionItem(
+      {this.snippetSupport,
+      this.commitCharactersSupport,
+      this.documentationFormat,
+      this.deprecatedSupport,
+      this.preselectSupport,
+      this.tagSupport});
+  static CompletionClientCapabilitiesCompletionItem fromJson(
+      Map<String, dynamic> json) {
+    final snippetSupport = json['snippetSupport'];
+    final commitCharactersSupport = json['commitCharactersSupport'];
+    final documentationFormat = json['documentationFormat']
+        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
+        ?.cast<MarkupKind>()
+        ?.toList();
+    final deprecatedSupport = json['deprecatedSupport'];
+    final preselectSupport = json['preselectSupport'];
+    final tagSupport = json['tagSupport'] != null
+        ? CompletionClientCapabilitiesTagSupport.fromJson(json['tagSupport'])
+        : null;
+    return CompletionClientCapabilitiesCompletionItem(
+        snippetSupport: snippetSupport,
+        commitCharactersSupport: commitCharactersSupport,
+        documentationFormat: documentationFormat,
+        deprecatedSupport: deprecatedSupport,
+        preselectSupport: preselectSupport,
+        tagSupport: tagSupport);
+  }
+
+  /// Client supports commit characters on a completion item.
+  final bool commitCharactersSupport;
+
+  /// Client supports the deprecated property on a completion item.
+  final bool deprecatedSupport;
+
+  /// Client supports the follow content formats for the documentation property.
+  /// The order describes the preferred format of the client.
+  final List<MarkupKind> documentationFormat;
+
+  /// Client supports the preselect property on a completion item.
+  final bool preselectSupport;
+
+  /// Client supports snippets as insert text.
+  ///
+  /// A snippet can define tab stops and placeholders with `$1`, `$2` and
+  /// `${3:foo}`. `$0` defines the final tab stop, it defaults to the end of the
+  /// snippet. Placeholders with equal identifiers are linked, that is typing in
+  /// one will update others too.
+  final bool snippetSupport;
+
+  /// Client supports the tag property on a completion item. Clients supporting
+  /// tags have to handle unknown tags gracefully. Clients especially need to
+  /// preserve unknown tags when sending a completion item back to the server in
+  /// a resolve call.
+  ///  @since 3.15.0
+  final CompletionClientCapabilitiesTagSupport tagSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (snippetSupport != null) {
+      __result['snippetSupport'] = snippetSupport;
+    }
+    if (commitCharactersSupport != null) {
+      __result['commitCharactersSupport'] = commitCharactersSupport;
+    }
+    if (documentationFormat != null) {
+      __result['documentationFormat'] = documentationFormat;
+    }
+    if (deprecatedSupport != null) {
+      __result['deprecatedSupport'] = deprecatedSupport;
+    }
+    if (preselectSupport != null) {
+      __result['preselectSupport'] = preselectSupport;
+    }
+    if (tagSupport != null) {
+      __result['tagSupport'] = tagSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('snippetSupport');
+      try {
+        if (obj['snippetSupport'] != null && !(obj['snippetSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('commitCharactersSupport');
+      try {
+        if (obj['commitCharactersSupport'] != null &&
+            !(obj['commitCharactersSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('documentationFormat');
+      try {
+        if (obj['documentationFormat'] != null &&
+            !((obj['documentationFormat'] is List &&
+                (obj['documentationFormat']
+                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<MarkupKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('deprecatedSupport');
+      try {
+        if (obj['deprecatedSupport'] != null &&
+            !(obj['deprecatedSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('preselectSupport');
+      try {
+        if (obj['preselectSupport'] != null &&
+            !(obj['preselectSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('tagSupport');
+      try {
+        if (obj['tagSupport'] != null &&
+            !(CompletionClientCapabilitiesTagSupport.canParse(
+                obj['tagSupport'], reporter))) {
+          reporter.reportError(
+              'must be of type CompletionClientCapabilitiesTagSupport');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type CompletionClientCapabilitiesCompletionItem');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CompletionClientCapabilitiesCompletionItem &&
+        other.runtimeType == CompletionClientCapabilitiesCompletionItem) {
+      return snippetSupport == other.snippetSupport &&
+          commitCharactersSupport == other.commitCharactersSupport &&
+          listEqual(documentationFormat, other.documentationFormat,
+              (MarkupKind a, MarkupKind b) => a == b) &&
+          deprecatedSupport == other.deprecatedSupport &&
+          preselectSupport == other.preselectSupport &&
+          tagSupport == other.tagSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, snippetSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, commitCharactersSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentationFormat));
+    hash = JenkinsSmiHash.combine(hash, deprecatedSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, preselectSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, tagSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CompletionClientCapabilitiesCompletionItemKind implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CompletionClientCapabilitiesCompletionItemKind.canParse,
+      CompletionClientCapabilitiesCompletionItemKind.fromJson);
+
+  CompletionClientCapabilitiesCompletionItemKind({this.valueSet});
+  static CompletionClientCapabilitiesCompletionItemKind fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? CompletionItemKind.fromJson(item) : null)
+        ?.cast<CompletionItemKind>()
+        ?.toList();
+    return CompletionClientCapabilitiesCompletionItemKind(valueSet: valueSet);
+  }
+
+  /// The completion item kind values the client supports. When this property
+  /// exists the client also guarantees that it will handle values outside its
+  /// set gracefully and falls back to a default value when unknown.
+  ///
+  /// If this property is not present the client only supports the completion
+  /// items kinds from `Text` to `Reference` as defined in the initial version
+  /// of the protocol.
+  final List<CompletionItemKind> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (valueSet != null) {
+      __result['valueSet'] = valueSet;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (obj['valueSet'] != null &&
+            !((obj['valueSet'] is List &&
+                (obj['valueSet'].every(
+                    (item) => CompletionItemKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<CompletionItemKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type CompletionClientCapabilitiesCompletionItemKind');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CompletionClientCapabilitiesCompletionItemKind &&
+        other.runtimeType == CompletionClientCapabilitiesCompletionItemKind) {
+      return listEqual(valueSet, other.valueSet,
+              (CompletionItemKind a, CompletionItemKind b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class CompletionClientCapabilitiesTagSupport implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      CompletionClientCapabilitiesTagSupport.canParse,
+      CompletionClientCapabilitiesTagSupport.fromJson);
+
+  CompletionClientCapabilitiesTagSupport({@required this.valueSet}) {
+    if (valueSet == null) {
+      throw 'valueSet is required but was not provided';
+    }
+  }
+  static CompletionClientCapabilitiesTagSupport fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? CompletionItemTag.fromJson(item) : null)
+        ?.cast<CompletionItemTag>()
+        ?.toList();
+    return CompletionClientCapabilitiesTagSupport(valueSet: valueSet);
+  }
+
+  /// The tags supported by the client.
+  final List<CompletionItemTag> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['valueSet'] =
+        valueSet ?? (throw 'valueSet is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (!obj.containsKey('valueSet')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['valueSet'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['valueSet'] is List &&
+            (obj['valueSet'].every(
+                (item) => CompletionItemTag.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<CompletionItemTag>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type CompletionClientCapabilitiesTagSupport');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is CompletionClientCapabilitiesTagSupport &&
+        other.runtimeType == CompletionClientCapabilitiesTagSupport) {
+      return listEqual(valueSet, other.valueSet,
+              (CompletionItemTag a, CompletionItemTag b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Contains additional information about the context in which a completion
 /// request is triggered.
 class CompletionContext implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CompletionContext.canParse, CompletionContext.fromJson);
 
-  CompletionContext(this.triggerKind, this.triggerCharacter) {
+  CompletionContext({@required this.triggerKind, this.triggerCharacter}) {
     if (triggerKind == null) {
       throw 'triggerKind is required but was not provided';
     }
@@ -2028,7 +3453,8 @@
         ? CompletionTriggerKind.fromJson(json['triggerKind'])
         : null;
     final triggerCharacter = json['triggerCharacter'];
-    return CompletionContext(triggerKind, triggerCharacter);
+    return CompletionContext(
+        triggerKind: triggerKind, triggerCharacter: triggerCharacter);
   }
 
   /// The trigger character (a single character) that has trigger code complete.
@@ -2111,8 +3537,9 @@
       LspJsonHandler(CompletionItem.canParse, CompletionItem.fromJson);
 
   CompletionItem(
-      this.label,
+      {@required this.label,
       this.kind,
+      this.tags,
       this.detail,
       this.documentation,
       this.deprecated,
@@ -2125,7 +3552,7 @@
       this.additionalTextEdits,
       this.commitCharacters,
       this.command,
-      this.data) {
+      this.data}) {
     if (label == null) {
       throw 'label is required but was not provided';
     }
@@ -2134,6 +3561,10 @@
     final label = json['label'];
     final kind =
         json['kind'] != null ? CompletionItemKind.fromJson(json['kind']) : null;
+    final tags = json['tags']
+        ?.map((item) => item != null ? CompletionItemTag.fromJson(item) : null)
+        ?.cast<CompletionItemTag>()
+        ?.toList();
     final detail = json['detail'];
     final documentation = json['documentation'] is String
         ? Either2<String, MarkupContent>.t1(json['documentation'])
@@ -2166,21 +3597,22 @@
         ? CompletionItemResolutionInfo.fromJson(json['data'])
         : null;
     return CompletionItem(
-        label,
-        kind,
-        detail,
-        documentation,
-        deprecated,
-        preselect,
-        sortText,
-        filterText,
-        insertText,
-        insertTextFormat,
-        textEdit,
-        additionalTextEdits,
-        commitCharacters,
-        command,
-        data);
+        label: label,
+        kind: kind,
+        tags: tags,
+        detail: detail,
+        documentation: documentation,
+        deprecated: deprecated,
+        preselect: preselect,
+        sortText: sortText,
+        filterText: filterText,
+        insertText: insertText,
+        insertTextFormat: insertTextFormat,
+        textEdit: textEdit,
+        additionalTextEdits: additionalTextEdits,
+        commitCharacters: commitCharacters,
+        command: command,
+        data: data);
   }
 
   /// An optional array of additional text edits that are applied when selecting
@@ -2208,6 +3640,8 @@
   final CompletionItemResolutionInfo data;
 
   /// Indicates if this item is deprecated.
+  ///  @deprecated Use `tags` instead if supported.
+  @core.deprecated
   final bool deprecated;
 
   /// A human-readable string with additional information about this item, like
@@ -2233,7 +3667,7 @@
   final String insertText;
 
   /// The format of the insert text. The format applies to both the `insertText`
-  /// property and the `newText` property of a provided `textEdit`. If ommitted
+  /// property and the `newText` property of a provided `textEdit`. If omitted
   /// defaults to `InsertTextFormat.PlainText`.
   final InsertTextFormat insertTextFormat;
 
@@ -2257,6 +3691,10 @@
   /// When `falsy` the label is used.
   final String sortText;
 
+  /// Tags for this completion item.
+  ///  @since 3.15.0
+  final List<CompletionItemTag> tags;
+
   /// An edit which is applied to a document when selecting this completion.
   /// When an edit is provided the value of `insertText` is ignored.
   ///
@@ -2270,6 +3708,9 @@
     if (kind != null) {
       __result['kind'] = kind;
     }
+    if (tags != null) {
+      __result['tags'] = tags;
+    }
     if (detail != null) {
       __result['detail'] = detail;
     }
@@ -2341,6 +3782,18 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('tags');
+      try {
+        if (obj['tags'] != null &&
+            !((obj['tags'] is List &&
+                (obj['tags'].every(
+                    (item) => CompletionItemTag.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<CompletionItemTag>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('detail');
       try {
         if (obj['detail'] != null && !(obj['detail'] is String)) {
@@ -2482,6 +3935,8 @@
     if (other is CompletionItem && other.runtimeType == CompletionItem) {
       return label == other.label &&
           kind == other.kind &&
+          listEqual(tags, other.tags,
+              (CompletionItemTag a, CompletionItemTag b) => a == b) &&
           detail == other.detail &&
           documentation == other.documentation &&
           deprecated == other.deprecated &&
@@ -2507,6 +3962,7 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, label.hashCode);
     hash = JenkinsSmiHash.combine(hash, kind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(tags));
     hash = JenkinsSmiHash.combine(hash, detail.hashCode);
     hash = JenkinsSmiHash.combine(hash, documentation.hashCode);
     hash = JenkinsSmiHash.combine(hash, deprecated.hashCode);
@@ -2575,13 +4031,40 @@
   bool operator ==(Object o) => o is CompletionItemKind && o._value == _value;
 }
 
+/// Completion item tags are extra annotations that tweak the rendering of a
+/// completion item.
+///  @since 3.15.0
+class CompletionItemTag {
+  const CompletionItemTag(this._value);
+  const CompletionItemTag.fromJson(this._value);
+
+  final num _value;
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    return obj is num;
+  }
+
+  /// Render a completion as obsolete, usually using a strike-out.
+  static const Deprecated = CompletionItemTag(1);
+
+  Object toJson() => _value;
+
+  @override
+  String toString() => _value.toString();
+
+  @override
+  int get hashCode => _value.hashCode;
+
+  bool operator ==(Object o) => o is CompletionItemTag && o._value == _value;
+}
+
 /// Represents a collection of completion items ([CompletionItem]) to be
 /// presented in the editor.
 class CompletionList implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CompletionList.canParse, CompletionList.fromJson);
 
-  CompletionList(this.isIncomplete, this.items) {
+  CompletionList({@required this.isIncomplete, @required this.items}) {
     if (isIncomplete == null) {
       throw 'isIncomplete is required but was not provided';
     }
@@ -2595,7 +4078,7 @@
         ?.map((item) => item != null ? CompletionItem.fromJson(item) : null)
         ?.cast<CompletionItem>()
         ?.toList();
-    return CompletionList(isIncomplete, items);
+    return CompletionList(isIncomplete: isIncomplete, items: items);
   }
 
   /// This list it not complete. Further typing should result in recomputing
@@ -2682,40 +4165,105 @@
 }
 
 /// Completion options.
-class CompletionOptions implements ToJsonable {
+class CompletionOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CompletionOptions.canParse, CompletionOptions.fromJson);
 
-  CompletionOptions(this.resolveProvider, this.triggerCharacters);
+  CompletionOptions(
+      {this.triggerCharacters,
+      this.allCommitCharacters,
+      this.resolveProvider,
+      this.workDoneProgress});
   static CompletionOptions fromJson(Map<String, dynamic> json) {
-    final resolveProvider = json['resolveProvider'];
+    if (CompletionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return CompletionRegistrationOptions.fromJson(json);
+    }
     final triggerCharacters = json['triggerCharacters']
         ?.map((item) => item)
         ?.cast<String>()
         ?.toList();
-    return CompletionOptions(resolveProvider, triggerCharacters);
+    final allCommitCharacters = json['allCommitCharacters']
+        ?.map((item) => item)
+        ?.cast<String>()
+        ?.toList();
+    final resolveProvider = json['resolveProvider'];
+    final workDoneProgress = json['workDoneProgress'];
+    return CompletionOptions(
+        triggerCharacters: triggerCharacters,
+        allCommitCharacters: allCommitCharacters,
+        resolveProvider: resolveProvider,
+        workDoneProgress: workDoneProgress);
   }
 
+  /// The list of all possible characters that commit a completion. This field
+  /// can be used if clients don't support individual commit characters per
+  /// completion item. See
+  /// `ClientCapabilities.textDocument.completion.completionItem.commitCharactersSupport`.
+  ///
+  /// If a server provides both `allCommitCharacters` and commit characters on
+  /// an individual completion item the ones on the completion item win.
+  ///  @since 3.2.0
+  final List<String> allCommitCharacters;
+
   /// The server provides support to resolve additional information for a
   /// completion item.
   final bool resolveProvider;
 
-  /// The characters that trigger completion automatically.
+  /// Most tools trigger completion request automatically without explicitly
+  /// requesting it using a keyboard shortcut (e.g. Ctrl+Space). Typically they
+  /// do so when the user starts to type an identifier. For example if the user
+  /// types `c` in a JavaScript file code complete will automatically pop up
+  /// present `console` besides others as a completion item. Characters that
+  /// make up identifiers don't need to be listed here.
+  ///
+  /// If code complete should automatically be trigger on characters not being
+  /// valid inside an identifier (for example `.` in JavaScript) list them in
+  /// `triggerCharacters`.
   final List<String> triggerCharacters;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    if (triggerCharacters != null) {
+      __result['triggerCharacters'] = triggerCharacters;
+    }
+    if (allCommitCharacters != null) {
+      __result['allCommitCharacters'] = allCommitCharacters;
+    }
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
-    if (triggerCharacters != null) {
-      __result['triggerCharacters'] = triggerCharacters;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
     }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
+      reporter.push('triggerCharacters');
+      try {
+        if (obj['triggerCharacters'] != null &&
+            !((obj['triggerCharacters'] is List &&
+                (obj['triggerCharacters'].every((item) => item is String))))) {
+          reporter.reportError('must be of type List<String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('allCommitCharacters');
+      try {
+        if (obj['allCommitCharacters'] != null &&
+            !((obj['allCommitCharacters'] is List &&
+                (obj['allCommitCharacters']
+                    .every((item) => item is String))))) {
+          reporter.reportError('must be of type List<String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('resolveProvider');
       try {
         if (obj['resolveProvider'] != null &&
@@ -2726,12 +4274,11 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('triggerCharacters');
+      reporter.push('workDoneProgress');
       try {
-        if (obj['triggerCharacters'] != null &&
-            !((obj['triggerCharacters'] is List &&
-                (obj['triggerCharacters'].every((item) => item is String))))) {
-          reporter.reportError('must be of type List<String>');
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
           return false;
         }
       } finally {
@@ -2747,9 +4294,12 @@
   @override
   bool operator ==(Object other) {
     if (other is CompletionOptions && other.runtimeType == CompletionOptions) {
-      return resolveProvider == other.resolveProvider &&
-          listEqual(triggerCharacters, other.triggerCharacters,
+      return listEqual(triggerCharacters, other.triggerCharacters,
               (String a, String b) => a == b) &&
+          listEqual(allCommitCharacters, other.allCommitCharacters,
+              (String a, String b) => a == b) &&
+          resolveProvider == other.resolveProvider &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -2758,8 +4308,10 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(triggerCharacters));
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(allCommitCharacters));
+    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -2767,11 +4319,21 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class CompletionParams implements TextDocumentPositionParams, ToJsonable {
+class CompletionParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
   static const jsonHandler =
       LspJsonHandler(CompletionParams.canParse, CompletionParams.fromJson);
 
-  CompletionParams(this.context, this.textDocument, this.position) {
+  CompletionParams(
+      {this.context,
+      @required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -2788,7 +4350,26 @@
         : null;
     final position =
         json['position'] != null ? Position.fromJson(json['position']) : null;
-    return CompletionParams(context, textDocument, position);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return CompletionParams(
+        context: context,
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
   /// The completion context. This is only available if the client specifies to
@@ -2796,12 +4377,19 @@
   /// === true`
   final CompletionContext context;
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The position inside the text document.
   final Position position;
 
   /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (context != null) {
@@ -2811,6 +4399,12 @@
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['position'] =
         position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -2860,6 +4454,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type CompletionParams');
@@ -2873,6 +4489,8 @@
       return context == other.context &&
           textDocument == other.textDocument &&
           position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
           true;
     }
     return false;
@@ -2884,6 +4502,8 @@
     hash = JenkinsSmiHash.combine(hash, context.hashCode);
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -2892,14 +4512,22 @@
 }
 
 class CompletionRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements TextDocumentRegistrationOptions, CompletionOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       CompletionRegistrationOptions.canParse,
       CompletionRegistrationOptions.fromJson);
 
-  CompletionRegistrationOptions(this.triggerCharacters,
-      this.allCommitCharacters, this.resolveProvider, this.documentSelector);
+  CompletionRegistrationOptions(
+      {this.documentSelector,
+      this.triggerCharacters,
+      this.allCommitCharacters,
+      this.resolveProvider,
+      this.workDoneProgress});
   static CompletionRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
     final triggerCharacters = json['triggerCharacters']
         ?.map((item) => item)
         ?.cast<String>()
@@ -2909,23 +4537,23 @@
         ?.cast<String>()
         ?.toList();
     final resolveProvider = json['resolveProvider'];
-    final documentSelector = json['documentSelector']
-        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
-        ?.cast<DocumentFilter>()
-        ?.toList();
-    return CompletionRegistrationOptions(triggerCharacters, allCommitCharacters,
-        resolveProvider, documentSelector);
+    final workDoneProgress = json['workDoneProgress'];
+    return CompletionRegistrationOptions(
+        documentSelector: documentSelector,
+        triggerCharacters: triggerCharacters,
+        allCommitCharacters: allCommitCharacters,
+        resolveProvider: resolveProvider,
+        workDoneProgress: workDoneProgress);
   }
 
   /// The list of all possible characters that commit a completion. This field
-  /// can be used if clients don't support individual commmit characters per
+  /// can be used if clients don't support individual commit characters per
   /// completion item. See
   /// `ClientCapabilities.textDocument.completion.completionItem.commitCharactersSupport`.
   ///
   /// If a server provides both `allCommitCharacters` and commit characters on
   /// an individual completion item the ones on the completion item win.
-  ///
-  /// Since 3.2.0
+  ///  @since 3.2.0
   final List<String> allCommitCharacters;
 
   /// A document selector to identify the scope of the registration. If set to
@@ -2947,9 +4575,11 @@
   /// valid inside an identifier (for example `.` in JavaScript) list them in
   /// `triggerCharacters`.
   final List<String> triggerCharacters;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     if (triggerCharacters != null) {
       __result['triggerCharacters'] = triggerCharacters;
     }
@@ -2959,12 +4589,30 @@
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
-    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('triggerCharacters');
       try {
         if (obj['triggerCharacters'] != null &&
@@ -2998,17 +4646,11 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('documentSelector');
+      reporter.push('workDoneProgress');
       try {
-        if (!obj.containsKey('documentSelector')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['documentSelector'] != null &&
-            !((obj['documentSelector'] is List &&
-                (obj['documentSelector'].every(
-                    (item) => DocumentFilter.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<DocumentFilter>');
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
           return false;
         }
       } finally {
@@ -3025,13 +4667,14 @@
   bool operator ==(Object other) {
     if (other is CompletionRegistrationOptions &&
         other.runtimeType == CompletionRegistrationOptions) {
-      return listEqual(triggerCharacters, other.triggerCharacters,
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          listEqual(triggerCharacters, other.triggerCharacters,
               (String a, String b) => a == b) &&
           listEqual(allCommitCharacters, other.allCommitCharacters,
               (String a, String b) => a == b) &&
           resolveProvider == other.resolveProvider &&
-          listEqual(documentSelector, other.documentSelector,
-              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -3040,10 +4683,11 @@
   @override
   int get hashCode {
     var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
     hash = JenkinsSmiHash.combine(hash, lspHashCode(triggerCharacters));
     hash = JenkinsSmiHash.combine(hash, lspHashCode(allCommitCharacters));
     hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -3095,11 +4739,11 @@
   static const jsonHandler =
       LspJsonHandler(ConfigurationItem.canParse, ConfigurationItem.fromJson);
 
-  ConfigurationItem(this.scopeUri, this.section);
+  ConfigurationItem({this.scopeUri, this.section});
   static ConfigurationItem fromJson(Map<String, dynamic> json) {
     final scopeUri = json['scopeUri'];
     final section = json['section'];
-    return ConfigurationItem(scopeUri, section);
+    return ConfigurationItem(scopeUri: scopeUri, section: section);
   }
 
   /// The scope to get the configuration section for.
@@ -3170,7 +4814,7 @@
   static const jsonHandler = LspJsonHandler(
       ConfigurationParams.canParse, ConfigurationParams.fromJson);
 
-  ConfigurationParams(this.items) {
+  ConfigurationParams({@required this.items}) {
     if (items == null) {
       throw 'items is required but was not provided';
     }
@@ -3180,7 +4824,7 @@
         ?.map((item) => item != null ? ConfigurationItem.fromJson(item) : null)
         ?.cast<ConfigurationItem>()
         ?.toList();
-    return ConfigurationParams(items);
+    return ConfigurationParams(items: items);
   }
 
   final List<ConfigurationItem> items;
@@ -3246,7 +4890,7 @@
   static const jsonHandler =
       LspJsonHandler(CreateFile.canParse, CreateFile.fromJson);
 
-  CreateFile(this.kind, this.uri, this.options) {
+  CreateFile({@required this.kind, @required this.uri, this.options}) {
     if (kind == null) {
       throw 'kind is required but was not provided';
     }
@@ -3260,7 +4904,7 @@
     final options = json['options'] != null
         ? CreateFileOptions.fromJson(json['options'])
         : null;
-    return CreateFile(kind, uri, options);
+    return CreateFile(kind: kind, uri: uri, options: options);
   }
 
   /// A create
@@ -3364,11 +5008,12 @@
   static const jsonHandler =
       LspJsonHandler(CreateFileOptions.canParse, CreateFileOptions.fromJson);
 
-  CreateFileOptions(this.overwrite, this.ignoreIfExists);
+  CreateFileOptions({this.overwrite, this.ignoreIfExists});
   static CreateFileOptions fromJson(Map<String, dynamic> json) {
     final overwrite = json['overwrite'];
     final ignoreIfExists = json['ignoreIfExists'];
-    return CreateFileOptions(overwrite, ignoreIfExists);
+    return CreateFileOptions(
+        overwrite: overwrite, ignoreIfExists: ignoreIfExists);
   }
 
   /// Ignore if exists.
@@ -3437,12 +5082,840 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class DeclarationClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DeclarationClientCapabilities.canParse,
+      DeclarationClientCapabilities.fromJson);
+
+  DeclarationClientCapabilities({this.dynamicRegistration, this.linkSupport});
+  static DeclarationClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final linkSupport = json['linkSupport'];
+    return DeclarationClientCapabilities(
+        dynamicRegistration: dynamicRegistration, linkSupport: linkSupport);
+  }
+
+  /// Whether declaration supports dynamic registration. If this is set to
+  /// `true` the client supports the new `DeclarationRegistrationOptions` return
+  /// value for the corresponding server capability as well.
+  final bool dynamicRegistration;
+
+  /// The client supports additional metadata in the form of declaration links.
+  final bool linkSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (linkSupport != null) {
+      __result['linkSupport'] = linkSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('linkSupport');
+      try {
+        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DeclarationClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DeclarationClientCapabilities &&
+        other.runtimeType == DeclarationClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          linkSupport == other.linkSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DeclarationOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(DeclarationOptions.canParse, DeclarationOptions.fromJson);
+
+  DeclarationOptions({this.workDoneProgress});
+  static DeclarationOptions fromJson(Map<String, dynamic> json) {
+    if (DeclarationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DeclarationRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DeclarationOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DeclarationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DeclarationOptions &&
+        other.runtimeType == DeclarationOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DeclarationParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(DeclarationParams.canParse, DeclarationParams.fromJson);
+
+  DeclarationParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static DeclarationParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DeclarationParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DeclarationParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DeclarationParams && other.runtimeType == DeclarationParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DeclarationRegistrationOptions
+    implements
+        DeclarationOptions,
+        TextDocumentRegistrationOptions,
+        StaticRegistrationOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DeclarationRegistrationOptions.canParse,
+      DeclarationRegistrationOptions.fromJson);
+
+  DeclarationRegistrationOptions(
+      {this.workDoneProgress, this.documentSelector, this.id});
+  static DeclarationRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final workDoneProgress = json['workDoneProgress'];
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final id = json['id'];
+    return DeclarationRegistrationOptions(
+        workDoneProgress: workDoneProgress,
+        documentSelector: documentSelector,
+        id: id);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    __result['documentSelector'] = documentSelector;
+    if (id != null) {
+      __result['id'] = id;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DeclarationRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DeclarationRegistrationOptions &&
+        other.runtimeType == DeclarationRegistrationOptions) {
+      return workDoneProgress == other.workDoneProgress &&
+          listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          id == other.id &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DefinitionClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DefinitionClientCapabilities.canParse,
+      DefinitionClientCapabilities.fromJson);
+
+  DefinitionClientCapabilities({this.dynamicRegistration, this.linkSupport});
+  static DefinitionClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final linkSupport = json['linkSupport'];
+    return DefinitionClientCapabilities(
+        dynamicRegistration: dynamicRegistration, linkSupport: linkSupport);
+  }
+
+  /// Whether definition supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// The client supports additional metadata in the form of definition links.
+  ///  @since 3.14.0
+  final bool linkSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (linkSupport != null) {
+      __result['linkSupport'] = linkSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('linkSupport');
+      try {
+        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DefinitionClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DefinitionClientCapabilities &&
+        other.runtimeType == DefinitionClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          linkSupport == other.linkSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DefinitionOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(DefinitionOptions.canParse, DefinitionOptions.fromJson);
+
+  DefinitionOptions({this.workDoneProgress});
+  static DefinitionOptions fromJson(Map<String, dynamic> json) {
+    if (DefinitionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DefinitionRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DefinitionOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DefinitionOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DefinitionOptions && other.runtimeType == DefinitionOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DefinitionParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(DefinitionParams.canParse, DefinitionParams.fromJson);
+
+  DefinitionParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static DefinitionParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DefinitionParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DefinitionParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DefinitionParams && other.runtimeType == DefinitionParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DefinitionRegistrationOptions
+    implements TextDocumentRegistrationOptions, DefinitionOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DefinitionRegistrationOptions.canParse,
+      DefinitionRegistrationOptions.fromJson);
+
+  DefinitionRegistrationOptions({this.documentSelector, this.workDoneProgress});
+  static DefinitionRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return DefinitionRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DefinitionRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DefinitionRegistrationOptions &&
+        other.runtimeType == DefinitionRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Delete file operation
 class DeleteFile implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(DeleteFile.canParse, DeleteFile.fromJson);
 
-  DeleteFile(this.kind, this.uri, this.options) {
+  DeleteFile({@required this.kind, @required this.uri, this.options}) {
     if (kind == null) {
       throw 'kind is required but was not provided';
     }
@@ -3456,7 +5929,7 @@
     final options = json['options'] != null
         ? DeleteFileOptions.fromJson(json['options'])
         : null;
-    return DeleteFile(kind, uri, options);
+    return DeleteFile(kind: kind, uri: uri, options: options);
   }
 
   /// A delete
@@ -3560,11 +6033,12 @@
   static const jsonHandler =
       LspJsonHandler(DeleteFileOptions.canParse, DeleteFileOptions.fromJson);
 
-  DeleteFileOptions(this.recursive, this.ignoreIfNotExists);
+  DeleteFileOptions({this.recursive, this.ignoreIfNotExists});
   static DeleteFileOptions fromJson(Map<String, dynamic> json) {
     final recursive = json['recursive'];
     final ignoreIfNotExists = json['ignoreIfNotExists'];
-    return DeleteFileOptions(recursive, ignoreIfNotExists);
+    return DeleteFileOptions(
+        recursive: recursive, ignoreIfNotExists: ignoreIfNotExists);
   }
 
   /// Ignore the operation if the file doesn't exist.
@@ -3638,8 +6112,14 @@
   static const jsonHandler =
       LspJsonHandler(Diagnostic.canParse, Diagnostic.fromJson);
 
-  Diagnostic(this.range, this.severity, this.code, this.source, this.message,
-      this.relatedInformation) {
+  Diagnostic(
+      {@required this.range,
+      this.severity,
+      this.code,
+      this.source,
+      @required this.message,
+      this.tags,
+      this.relatedInformation}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -3655,13 +6135,23 @@
     final code = json['code'];
     final source = json['source'];
     final message = json['message'];
+    final tags = json['tags']
+        ?.map((item) => item != null ? DiagnosticTag.fromJson(item) : null)
+        ?.cast<DiagnosticTag>()
+        ?.toList();
     final relatedInformation = json['relatedInformation']
         ?.map((item) =>
             item != null ? DiagnosticRelatedInformation.fromJson(item) : null)
         ?.cast<DiagnosticRelatedInformation>()
         ?.toList();
     return Diagnostic(
-        range, severity, code, source, message, relatedInformation);
+        range: range,
+        severity: severity,
+        code: code,
+        source: source,
+        message: message,
+        tags: tags,
+        relatedInformation: relatedInformation);
   }
 
   /// The diagnostic's code, which might appear in the user interface.
@@ -3685,6 +6175,10 @@
   /// 'typescript' or 'super lint'.
   final String source;
 
+  /// Additional metadata about the diagnostic.
+  ///  @since 3.15.0
+  final List<DiagnosticTag> tags;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['range'] = range ?? (throw 'range is required but was not set');
@@ -3699,6 +6193,9 @@
     }
     __result['message'] =
         message ?? (throw 'message is required but was not set');
+    if (tags != null) {
+      __result['tags'] = tags;
+    }
     if (relatedInformation != null) {
       __result['relatedInformation'] = relatedInformation;
     }
@@ -3769,6 +6266,18 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('tags');
+      try {
+        if (obj['tags'] != null &&
+            !((obj['tags'] is List &&
+                (obj['tags'].every(
+                    (item) => DiagnosticTag.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DiagnosticTag>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('relatedInformation');
       try {
         if (obj['relatedInformation'] != null &&
@@ -3798,6 +6307,8 @@
           source == other.source &&
           message == other.message &&
           listEqual(
+              tags, other.tags, (DiagnosticTag a, DiagnosticTag b) => a == b) &&
+          listEqual(
               relatedInformation,
               other.relatedInformation,
               (DiagnosticRelatedInformation a,
@@ -3816,6 +6327,7 @@
     hash = JenkinsSmiHash.combine(hash, code.hashCode);
     hash = JenkinsSmiHash.combine(hash, source.hashCode);
     hash = JenkinsSmiHash.combine(hash, message.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(tags));
     hash = JenkinsSmiHash.combine(hash, lspHashCode(relatedInformation));
     return JenkinsSmiHash.finish(hash);
   }
@@ -3825,14 +6337,15 @@
 }
 
 /// Represents a related message and source code location for a diagnostic. This
-/// should be used to point to code locations that cause or related to a
+/// should be used to point to code locations that cause or are related to a
 /// diagnostics, e.g when duplicating a symbol in a scope.
 class DiagnosticRelatedInformation implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DiagnosticRelatedInformation.canParse,
       DiagnosticRelatedInformation.fromJson);
 
-  DiagnosticRelatedInformation(this.location, this.message) {
+  DiagnosticRelatedInformation(
+      {@required this.location, @required this.message}) {
     if (location == null) {
       throw 'location is required but was not provided';
     }
@@ -3844,7 +6357,7 @@
     final location =
         json['location'] != null ? Location.fromJson(json['location']) : null;
     final message = json['message'];
-    return DiagnosticRelatedInformation(location, message);
+    return DiagnosticRelatedInformation(location: location, message: message);
   }
 
   /// The location of this related diagnostic information.
@@ -3959,15 +6472,113 @@
   bool operator ==(Object o) => o is DiagnosticSeverity && o._value == _value;
 }
 
+/// The diagnostic tags.
+///  @since 3.15.0
+class DiagnosticTag {
+  const DiagnosticTag(this._value);
+  const DiagnosticTag.fromJson(this._value);
+
+  final num _value;
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    return obj is num;
+  }
+
+  /// Unused or unnecessary code.
+  ///
+  /// Clients are allowed to render diagnostics with this tag faded out instead
+  /// of having an error squiggle.
+  static const Unnecessary = DiagnosticTag(1);
+
+  /// Deprecated or obsolete code.
+  ///
+  /// Clients are allowed to rendered diagnostics with this tag strike through.
+  static const Deprecated = DiagnosticTag(2);
+
+  Object toJson() => _value;
+
+  @override
+  String toString() => _value.toString();
+
+  @override
+  int get hashCode => _value.hashCode;
+
+  bool operator ==(Object o) => o is DiagnosticTag && o._value == _value;
+}
+
+class DidChangeConfigurationClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DidChangeConfigurationClientCapabilities.canParse,
+      DidChangeConfigurationClientCapabilities.fromJson);
+
+  DidChangeConfigurationClientCapabilities({this.dynamicRegistration});
+  static DidChangeConfigurationClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DidChangeConfigurationClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Did change configuration notification supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DidChangeConfigurationClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DidChangeConfigurationClientCapabilities &&
+        other.runtimeType == DidChangeConfigurationClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class DidChangeConfigurationParams implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DidChangeConfigurationParams.canParse,
       DidChangeConfigurationParams.fromJson);
 
-  DidChangeConfigurationParams(this.settings);
+  DidChangeConfigurationParams({this.settings});
   static DidChangeConfigurationParams fromJson(Map<String, dynamic> json) {
     final settings = json['settings'];
-    return DidChangeConfigurationParams(settings);
+    return DidChangeConfigurationParams(settings: settings);
   }
 
   /// The actual changed settings
@@ -4026,7 +6637,8 @@
       DidChangeTextDocumentParams.canParse,
       DidChangeTextDocumentParams.fromJson);
 
-  DidChangeTextDocumentParams(this.textDocument, this.contentChanges) {
+  DidChangeTextDocumentParams(
+      {@required this.textDocument, @required this.contentChanges}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -4039,17 +6651,42 @@
         ? VersionedTextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final contentChanges = json['contentChanges']
-        ?.map((item) =>
-            item != null ? TextDocumentContentChangeEvent.fromJson(item) : null)
-        ?.cast<TextDocumentContentChangeEvent>()
+        ?.map((item) => TextDocumentContentChangeEvent1.canParse(
+                item, nullLspJsonReporter)
+            ? Either2<TextDocumentContentChangeEvent1, TextDocumentContentChangeEvent2>.t1(
+                item != null
+                    ? TextDocumentContentChangeEvent1.fromJson(item)
+                    : null)
+            : (TextDocumentContentChangeEvent2.canParse(item, nullLspJsonReporter)
+                ? Either2<TextDocumentContentChangeEvent1,
+                        TextDocumentContentChangeEvent2>.t2(
+                    item != null
+                        ? TextDocumentContentChangeEvent2.fromJson(item)
+                        : null)
+                : (throw '''${item} was not one of (TextDocumentContentChangeEvent1, TextDocumentContentChangeEvent2)''')))
+        ?.cast<Either2<TextDocumentContentChangeEvent1, TextDocumentContentChangeEvent2>>()
         ?.toList();
-    return DidChangeTextDocumentParams(textDocument, contentChanges);
+    return DidChangeTextDocumentParams(
+        textDocument: textDocument, contentChanges: contentChanges);
   }
 
   /// The actual content changes. The content changes describe single state
-  /// changes to the document. So if there are two content changes c1 and c2 for
-  /// a document in state S then c1 move the document to S' and c2 to S''.
-  final List<TextDocumentContentChangeEvent> contentChanges;
+  /// changes to the document. So if there are two content changes c1 (at array
+  /// index 0) and c2 (at array index 1) for a document in state S then c1 moves
+  /// the document from S to S' and c2 from S' to S''. So c1 is computed on the
+  /// state S and c2 is computed on the state S'.
+  ///
+  /// To mirror the content of a document using change events use the following
+  /// approach:
+  /// - start with the same initial content
+  /// - apply the 'textDocument/didChange' notifications in the order you
+  /// recevie them.
+  /// - apply the `TextDocumentContentChangeEvent`s in a single notification in
+  /// the order
+  ///   you receive them.
+  final List<
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>> contentChanges;
 
   /// The document that did change. The version number points to the version
   /// after all provided content changes have been applied.
@@ -4097,9 +6734,11 @@
         }
         if (!((obj['contentChanges'] is List &&
             (obj['contentChanges'].every((item) =>
-                TextDocumentContentChangeEvent.canParse(item, reporter)))))) {
+                (TextDocumentContentChangeEvent1.canParse(item, reporter) ||
+                    TextDocumentContentChangeEvent2.canParse(
+                        item, reporter))))))) {
           reporter.reportError(
-              'must be of type List<TextDocumentContentChangeEvent>');
+              'must be of type List<Either2<TextDocumentContentChangeEvent1, TextDocumentContentChangeEvent2>>');
           return false;
         }
       } finally {
@@ -4120,8 +6759,12 @@
           listEqual(
               contentChanges,
               other.contentChanges,
-              (TextDocumentContentChangeEvent a,
-                      TextDocumentContentChangeEvent b) =>
+              (Either2<TextDocumentContentChangeEvent1,
+                              TextDocumentContentChangeEvent2>
+                          a,
+                      Either2<TextDocumentContentChangeEvent1,
+                              TextDocumentContentChangeEvent2>
+                          b) =>
                   a == b) &&
           true;
     }
@@ -4140,12 +6783,78 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class DidChangeWatchedFilesClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DidChangeWatchedFilesClientCapabilities.canParse,
+      DidChangeWatchedFilesClientCapabilities.fromJson);
+
+  DidChangeWatchedFilesClientCapabilities({this.dynamicRegistration});
+  static DidChangeWatchedFilesClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DidChangeWatchedFilesClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Did change watched files notification supports dynamic registration.
+  /// Please note that the current protocol doesn't support static configuration
+  /// for file changes from the server side.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DidChangeWatchedFilesClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DidChangeWatchedFilesClientCapabilities &&
+        other.runtimeType == DidChangeWatchedFilesClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class DidChangeWatchedFilesParams implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DidChangeWatchedFilesParams.canParse,
       DidChangeWatchedFilesParams.fromJson);
 
-  DidChangeWatchedFilesParams(this.changes) {
+  DidChangeWatchedFilesParams({@required this.changes}) {
     if (changes == null) {
       throw 'changes is required but was not provided';
     }
@@ -4155,7 +6864,7 @@
         ?.map((item) => item != null ? FileEvent.fromJson(item) : null)
         ?.cast<FileEvent>()
         ?.toList();
-    return DidChangeWatchedFilesParams(changes);
+    return DidChangeWatchedFilesParams(changes: changes);
   }
 
   /// The actual file events.
@@ -4224,7 +6933,7 @@
       DidChangeWatchedFilesRegistrationOptions.canParse,
       DidChangeWatchedFilesRegistrationOptions.fromJson);
 
-  DidChangeWatchedFilesRegistrationOptions(this.watchers) {
+  DidChangeWatchedFilesRegistrationOptions({@required this.watchers}) {
     if (watchers == null) {
       throw 'watchers is required but was not provided';
     }
@@ -4235,7 +6944,7 @@
         ?.map((item) => item != null ? FileSystemWatcher.fromJson(item) : null)
         ?.cast<FileSystemWatcher>()
         ?.toList();
-    return DidChangeWatchedFilesRegistrationOptions(watchers);
+    return DidChangeWatchedFilesRegistrationOptions(watchers: watchers);
   }
 
   /// The watchers to register.
@@ -4304,7 +7013,7 @@
       DidChangeWorkspaceFoldersParams.canParse,
       DidChangeWorkspaceFoldersParams.fromJson);
 
-  DidChangeWorkspaceFoldersParams(this.event) {
+  DidChangeWorkspaceFoldersParams({@required this.event}) {
     if (event == null) {
       throw 'event is required but was not provided';
     }
@@ -4313,7 +7022,7 @@
     final event = json['event'] != null
         ? WorkspaceFoldersChangeEvent.fromJson(json['event'])
         : null;
-    return DidChangeWorkspaceFoldersParams(event);
+    return DidChangeWorkspaceFoldersParams(event: event);
   }
 
   /// The actual workspace folder change event.
@@ -4375,7 +7084,7 @@
   static const jsonHandler = LspJsonHandler(
       DidCloseTextDocumentParams.canParse, DidCloseTextDocumentParams.fromJson);
 
-  DidCloseTextDocumentParams(this.textDocument) {
+  DidCloseTextDocumentParams({@required this.textDocument}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -4384,7 +7093,7 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
-    return DidCloseTextDocumentParams(textDocument);
+    return DidCloseTextDocumentParams(textDocument: textDocument);
   }
 
   /// The document that was closed.
@@ -4447,7 +7156,7 @@
   static const jsonHandler = LspJsonHandler(
       DidOpenTextDocumentParams.canParse, DidOpenTextDocumentParams.fromJson);
 
-  DidOpenTextDocumentParams(this.textDocument) {
+  DidOpenTextDocumentParams({@required this.textDocument}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -4456,7 +7165,7 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentItem.fromJson(json['textDocument'])
         : null;
-    return DidOpenTextDocumentParams(textDocument);
+    return DidOpenTextDocumentParams(textDocument: textDocument);
   }
 
   /// The document that was opened.
@@ -4519,7 +7228,7 @@
   static const jsonHandler = LspJsonHandler(
       DidSaveTextDocumentParams.canParse, DidSaveTextDocumentParams.fromJson);
 
-  DidSaveTextDocumentParams(this.textDocument, this.text) {
+  DidSaveTextDocumentParams({@required this.textDocument, this.text}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -4529,7 +7238,7 @@
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final text = json['text'];
-    return DidSaveTextDocumentParams(textDocument, text);
+    return DidSaveTextDocumentParams(textDocument: textDocument, text: text);
   }
 
   /// Optional the content when saved. Depends on the includeText value when the
@@ -4605,16 +7314,389 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class DocumentColorClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentColorClientCapabilities.canParse,
+      DocumentColorClientCapabilities.fromJson);
+
+  DocumentColorClientCapabilities({this.dynamicRegistration});
+  static DocumentColorClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DocumentColorClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether document color supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentColorClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentColorClientCapabilities &&
+        other.runtimeType == DocumentColorClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentColorOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentColorOptions.canParse, DocumentColorOptions.fromJson);
+
+  DocumentColorOptions({this.workDoneProgress});
+  static DocumentColorOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentColorRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentColorOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentColorOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentColorOptions &&
+        other.runtimeType == DocumentColorOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentColorParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentColorParams.canParse, DocumentColorParams.fromJson);
+
+  DocumentColorParams(
+      {@required this.textDocument,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+  }
+  static DocumentColorParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DocumentColorParams(
+        textDocument: textDocument,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentColorParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentColorParams &&
+        other.runtimeType == DocumentColorParams) {
+      return textDocument == other.textDocument &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentColorRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        StaticRegistrationOptions,
+        DocumentColorOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentColorRegistrationOptions.canParse,
+      DocumentColorRegistrationOptions.fromJson);
+
+  DocumentColorRegistrationOptions(
+      {this.documentSelector, this.id, this.workDoneProgress});
+  static DocumentColorRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final id = json['id'];
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentColorRegistrationOptions(
+        documentSelector: documentSelector,
+        id: id,
+        workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (id != null) {
+      __result['id'] = id;
+    }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentColorRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentColorRegistrationOptions &&
+        other.runtimeType == DocumentColorRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          id == other.id &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class DocumentFilter implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(DocumentFilter.canParse, DocumentFilter.fromJson);
 
-  DocumentFilter(this.language, this.scheme, this.pattern);
+  DocumentFilter({this.language, this.scheme, this.pattern});
   static DocumentFilter fromJson(Map<String, dynamic> json) {
     final language = json['language'];
     final scheme = json['scheme'];
     final pattern = json['pattern'];
-    return DocumentFilter(language, scheme, pattern);
+    return DocumentFilter(language: language, scheme: scheme, pattern: pattern);
   }
 
   /// A language id, like `typescript`.
@@ -4712,11 +7794,141 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class DocumentFormattingParams implements ToJsonable {
+class DocumentFormattingClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentFormattingClientCapabilities.canParse,
+      DocumentFormattingClientCapabilities.fromJson);
+
+  DocumentFormattingClientCapabilities({this.dynamicRegistration});
+  static DocumentFormattingClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DocumentFormattingClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether formatting supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type DocumentFormattingClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentFormattingClientCapabilities &&
+        other.runtimeType == DocumentFormattingClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentFormattingOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentFormattingOptions.canParse, DocumentFormattingOptions.fromJson);
+
+  DocumentFormattingOptions({this.workDoneProgress});
+  static DocumentFormattingOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentFormattingRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentFormattingRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentFormattingOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentFormattingOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentFormattingOptions &&
+        other.runtimeType == DocumentFormattingOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentFormattingParams implements WorkDoneProgressParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentFormattingParams.canParse, DocumentFormattingParams.fromJson);
 
-  DocumentFormattingParams(this.textDocument, this.options) {
+  DocumentFormattingParams(
+      {@required this.textDocument,
+      @required this.options,
+      this.workDoneToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -4731,7 +7943,17 @@
     final options = json['options'] != null
         ? FormattingOptions.fromJson(json['options'])
         : null;
-    return DocumentFormattingParams(textDocument, options);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return DocumentFormattingParams(
+        textDocument: textDocument,
+        options: options,
+        workDoneToken: workDoneToken);
   }
 
   /// The format options.
@@ -4740,12 +7962,18 @@
   /// The document to format.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['options'] =
         options ?? (throw 'options is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
     return __result;
   }
 
@@ -4785,6 +8013,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentFormattingParams');
@@ -4798,6 +8037,7 @@
         other.runtimeType == DocumentFormattingParams) {
       return textDocument == other.textDocument &&
           options == other.options &&
+          workDoneToken == other.workDoneToken &&
           true;
     }
     return false;
@@ -4808,6 +8048,103 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, options.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentFormattingRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentFormattingOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentFormattingRegistrationOptions.canParse,
+      DocumentFormattingRegistrationOptions.fromJson);
+
+  DocumentFormattingRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress});
+  static DocumentFormattingRegistrationOptions fromJson(
+      Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentFormattingRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type DocumentFormattingRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentFormattingRegistrationOptions &&
+        other.runtimeType == DocumentFormattingRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -4822,7 +8159,7 @@
   static const jsonHandler =
       LspJsonHandler(DocumentHighlight.canParse, DocumentHighlight.fromJson);
 
-  DocumentHighlight(this.range, this.kind) {
+  DocumentHighlight({@required this.range, this.kind}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -4832,7 +8169,7 @@
     final kind = json['kind'] != null
         ? DocumentHighlightKind.fromJson(json['kind'])
         : null;
-    return DocumentHighlight(range, kind);
+    return DocumentHighlight(range: range, kind: kind);
   }
 
   /// The highlight kind, default is DocumentHighlightKind.Text.
@@ -4906,6 +8243,70 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class DocumentHighlightClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentHighlightClientCapabilities.canParse,
+      DocumentHighlightClientCapabilities.fromJson);
+
+  DocumentHighlightClientCapabilities({this.dynamicRegistration});
+  static DocumentHighlightClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DocumentHighlightClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether document highlight supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type DocumentHighlightClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentHighlightClientCapabilities &&
+        other.runtimeType == DocumentHighlightClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// A document highlight kind.
 class DocumentHighlightKind {
   const DocumentHighlightKind(this._value);
@@ -4938,13 +8339,340 @@
       o is DocumentHighlightKind && o._value == _value;
 }
 
+class DocumentHighlightOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentHighlightOptions.canParse, DocumentHighlightOptions.fromJson);
+
+  DocumentHighlightOptions({this.workDoneProgress});
+  static DocumentHighlightOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentHighlightRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentHighlightRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentHighlightOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentHighlightOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentHighlightOptions &&
+        other.runtimeType == DocumentHighlightOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentHighlightParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentHighlightParams.canParse, DocumentHighlightParams.fromJson);
+
+  DocumentHighlightParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static DocumentHighlightParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DocumentHighlightParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentHighlightParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentHighlightParams &&
+        other.runtimeType == DocumentHighlightParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentHighlightRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentHighlightOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentHighlightRegistrationOptions.canParse,
+      DocumentHighlightRegistrationOptions.fromJson);
+
+  DocumentHighlightRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress});
+  static DocumentHighlightRegistrationOptions fromJson(
+      Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentHighlightRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type DocumentHighlightRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentHighlightRegistrationOptions &&
+        other.runtimeType == DocumentHighlightRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// A document link is a range in a text document that links to an internal or
 /// external resource, like another text document or a web site.
 class DocumentLink implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(DocumentLink.canParse, DocumentLink.fromJson);
 
-  DocumentLink(this.range, this.target, this.data) {
+  DocumentLink({@required this.range, this.target, this.tooltip, this.data}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -4952,8 +8680,10 @@
   static DocumentLink fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final target = json['target'];
+    final tooltip = json['tooltip'];
     final data = json['data'];
-    return DocumentLink(range, target, data);
+    return DocumentLink(
+        range: range, target: target, tooltip: tooltip, data: data);
   }
 
   /// A data entry field that is preserved on a document link between a
@@ -4966,12 +8696,24 @@
   /// The uri this link points to. If missing a resolve request is sent later.
   final String target;
 
+  /// The tooltip text when you hover over this link.
+  ///
+  /// If a tooltip is provided, is will be displayed in a string that includes
+  /// instructions on how to trigger the link, such as `{0} (ctrl + click)`. The
+  /// specific instructions vary depending on OS, user settings, and
+  /// localization.
+  ///  @since 3.15.0
+  final String tooltip;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['range'] = range ?? (throw 'range is required but was not set');
     if (target != null) {
       __result['target'] = target;
     }
+    if (tooltip != null) {
+      __result['tooltip'] = tooltip;
+    }
     if (data != null) {
       __result['data'] = data;
     }
@@ -5006,6 +8748,15 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('tooltip');
+      try {
+        if (obj['tooltip'] != null && !(obj['tooltip'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('data');
       try {
         if (obj['data'] != null && !(true)) {
@@ -5027,6 +8778,7 @@
     if (other is DocumentLink && other.runtimeType == DocumentLink) {
       return range == other.range &&
           target == other.target &&
+          tooltip == other.tooltip &&
           data == other.data &&
           true;
     }
@@ -5038,6 +8790,7 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, range.hashCode);
     hash = JenkinsSmiHash.combine(hash, target.hashCode);
+    hash = JenkinsSmiHash.combine(hash, tooltip.hashCode);
     hash = JenkinsSmiHash.combine(hash, data.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
@@ -5046,25 +8799,117 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Document link options.
-class DocumentLinkOptions implements ToJsonable {
+class DocumentLinkClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentLinkClientCapabilities.canParse,
+      DocumentLinkClientCapabilities.fromJson);
+
+  DocumentLinkClientCapabilities(
+      {this.dynamicRegistration, this.tooltipSupport});
+  static DocumentLinkClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final tooltipSupport = json['tooltipSupport'];
+    return DocumentLinkClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        tooltipSupport: tooltipSupport);
+  }
+
+  /// Whether document link supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// Whether the client supports the `tooltip` property on `DocumentLink`.
+  ///  @since 3.15.0
+  final bool tooltipSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (tooltipSupport != null) {
+      __result['tooltipSupport'] = tooltipSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('tooltipSupport');
+      try {
+        if (obj['tooltipSupport'] != null && !(obj['tooltipSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentLinkClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentLinkClientCapabilities &&
+        other.runtimeType == DocumentLinkClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          tooltipSupport == other.tooltipSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, tooltipSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentLinkOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentLinkOptions.canParse, DocumentLinkOptions.fromJson);
 
-  DocumentLinkOptions(this.resolveProvider);
+  DocumentLinkOptions({this.resolveProvider, this.workDoneProgress});
   static DocumentLinkOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentLinkRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentLinkRegistrationOptions.fromJson(json);
+    }
     final resolveProvider = json['resolveProvider'];
-    return DocumentLinkOptions(resolveProvider);
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentLinkOptions(
+        resolveProvider: resolveProvider, workDoneProgress: workDoneProgress);
   }
 
   /// Document links have a resolve provider as well.
   final bool resolveProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -5080,6 +8925,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentLinkOptions');
@@ -5091,7 +8946,9 @@
   bool operator ==(Object other) {
     if (other is DocumentLinkOptions &&
         other.runtimeType == DocumentLinkOptions) {
-      return resolveProvider == other.resolveProvider && true;
+      return resolveProvider == other.resolveProvider &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
     }
     return false;
   }
@@ -5100,6 +8957,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5107,11 +8965,15 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class DocumentLinkParams implements ToJsonable {
+class DocumentLinkParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(DocumentLinkParams.canParse, DocumentLinkParams.fromJson);
 
-  DocumentLinkParams(this.textDocument) {
+  DocumentLinkParams(
+      {@required this.textDocument,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -5120,16 +8982,46 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
-    return DocumentLinkParams(textDocument);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DocumentLinkParams(
+        textDocument: textDocument,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The document to provide document links for.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -5152,6 +9044,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentLinkParams');
@@ -5163,7 +9077,10 @@
   bool operator ==(Object other) {
     if (other is DocumentLinkParams &&
         other.runtimeType == DocumentLinkParams) {
-      return textDocument == other.textDocument && true;
+      return textDocument == other.textDocument &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
     }
     return false;
   }
@@ -5172,6 +9089,8 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5180,19 +9099,27 @@
 }
 
 class DocumentLinkRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentLinkOptions,
+        ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentLinkRegistrationOptions.canParse,
       DocumentLinkRegistrationOptions.fromJson);
 
-  DocumentLinkRegistrationOptions(this.resolveProvider, this.documentSelector);
+  DocumentLinkRegistrationOptions(
+      {this.documentSelector, this.resolveProvider, this.workDoneProgress});
   static DocumentLinkRegistrationOptions fromJson(Map<String, dynamic> json) {
-    final resolveProvider = json['resolveProvider'];
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return DocumentLinkRegistrationOptions(resolveProvider, documentSelector);
+    final resolveProvider = json['resolveProvider'];
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentLinkRegistrationOptions(
+        documentSelector: documentSelector,
+        resolveProvider: resolveProvider,
+        workDoneProgress: workDoneProgress);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -5201,28 +9128,22 @@
 
   /// Document links have a resolve provider as well.
   final bool resolveProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     if (resolveProvider != null) {
       __result['resolveProvider'] = resolveProvider;
     }
-    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('resolveProvider');
-      try {
-        if (obj['resolveProvider'] != null &&
-            !(obj['resolveProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('documentSelector');
       try {
         if (!obj.containsKey('documentSelector')) {
@@ -5239,6 +9160,26 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('resolveProvider');
+      try {
+        if (obj['resolveProvider'] != null &&
+            !(obj['resolveProvider'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentLinkRegistrationOptions');
@@ -5250,9 +9191,10 @@
   bool operator ==(Object other) {
     if (other is DocumentLinkRegistrationOptions &&
         other.runtimeType == DocumentLinkRegistrationOptions) {
-      return resolveProvider == other.resolveProvider &&
-          listEqual(documentSelector, other.documentSelector,
+      return listEqual(documentSelector, other.documentSelector,
               (DocumentFilter a, DocumentFilter b) => a == b) &&
+          resolveProvider == other.resolveProvider &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -5261,8 +9203,9 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, resolveProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5270,26 +9213,94 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Format document on type options.
+class DocumentOnTypeFormattingClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentOnTypeFormattingClientCapabilities.canParse,
+      DocumentOnTypeFormattingClientCapabilities.fromJson);
+
+  DocumentOnTypeFormattingClientCapabilities({this.dynamicRegistration});
+  static DocumentOnTypeFormattingClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DocumentOnTypeFormattingClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether on type formatting supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DocumentOnTypeFormattingClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentOnTypeFormattingClientCapabilities &&
+        other.runtimeType == DocumentOnTypeFormattingClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class DocumentOnTypeFormattingOptions implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentOnTypeFormattingOptions.canParse,
       DocumentOnTypeFormattingOptions.fromJson);
 
   DocumentOnTypeFormattingOptions(
-      this.firstTriggerCharacter, this.moreTriggerCharacter) {
+      {@required this.firstTriggerCharacter, this.moreTriggerCharacter}) {
     if (firstTriggerCharacter == null) {
       throw 'firstTriggerCharacter is required but was not provided';
     }
   }
   static DocumentOnTypeFormattingOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentOnTypeFormattingRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentOnTypeFormattingRegistrationOptions.fromJson(json);
+    }
     final firstTriggerCharacter = json['firstTriggerCharacter'];
     final moreTriggerCharacter = json['moreTriggerCharacter']
         ?.map((item) => item)
         ?.cast<String>()
         ?.toList();
     return DocumentOnTypeFormattingOptions(
-        firstTriggerCharacter, moreTriggerCharacter);
+        firstTriggerCharacter: firstTriggerCharacter,
+        moreTriggerCharacter: moreTriggerCharacter);
   }
 
   /// A character on which formatting should be triggered, like `}`.
@@ -5370,37 +9381,45 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class DocumentOnTypeFormattingParams implements ToJsonable {
+class DocumentOnTypeFormattingParams
+    implements TextDocumentPositionParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentOnTypeFormattingParams.canParse,
       DocumentOnTypeFormattingParams.fromJson);
 
   DocumentOnTypeFormattingParams(
-      this.textDocument, this.position, this.ch, this.options) {
-    if (textDocument == null) {
-      throw 'textDocument is required but was not provided';
-    }
-    if (position == null) {
-      throw 'position is required but was not provided';
-    }
+      {@required this.ch,
+      @required this.options,
+      @required this.textDocument,
+      @required this.position}) {
     if (ch == null) {
       throw 'ch is required but was not provided';
     }
     if (options == null) {
       throw 'options is required but was not provided';
     }
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
   }
   static DocumentOnTypeFormattingParams fromJson(Map<String, dynamic> json) {
+    final ch = json['ch'];
+    final options = json['options'] != null
+        ? FormattingOptions.fromJson(json['options'])
+        : null;
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final position =
         json['position'] != null ? Position.fromJson(json['position']) : null;
-    final ch = json['ch'];
-    final options = json['options'] != null
-        ? FormattingOptions.fromJson(json['options'])
-        : null;
-    return DocumentOnTypeFormattingParams(textDocument, position, ch, options);
+    return DocumentOnTypeFormattingParams(
+        ch: ch,
+        options: options,
+        textDocument: textDocument,
+        position: position);
   }
 
   /// The character that has been typed.
@@ -5409,60 +9428,26 @@
   /// The format options.
   final FormattingOptions options;
 
-  /// The position at which this request was sent.
+  /// The position inside the text document.
   final Position position;
 
-  /// The document to format.
+  /// The text document.
   final TextDocumentIdentifier textDocument;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['ch'] = ch ?? (throw 'ch is required but was not set');
+    __result['options'] =
+        options ?? (throw 'options is required but was not set');
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['position'] =
         position ?? (throw 'position is required but was not set');
-    __result['ch'] = ch ?? (throw 'ch is required but was not set');
-    __result['options'] =
-        options ?? (throw 'options is required but was not set');
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('textDocument');
-      try {
-        if (!obj.containsKey('textDocument')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['textDocument'] == null) {
-          reporter.reportError('must not be null');
-          return false;
-        }
-        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
-          reporter.reportError('must be of type TextDocumentIdentifier');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('position');
-      try {
-        if (!obj.containsKey('position')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['position'] == null) {
-          reporter.reportError('must not be null');
-          return false;
-        }
-        if (!(Position.canParse(obj['position'], reporter))) {
-          reporter.reportError('must be of type Position');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('ch');
       try {
         if (!obj.containsKey('ch')) {
@@ -5497,6 +9482,40 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentOnTypeFormattingParams');
@@ -5508,10 +9527,10 @@
   bool operator ==(Object other) {
     if (other is DocumentOnTypeFormattingParams &&
         other.runtimeType == DocumentOnTypeFormattingParams) {
-      return textDocument == other.textDocument &&
-          position == other.position &&
-          ch == other.ch &&
+      return ch == other.ch &&
           options == other.options &&
+          textDocument == other.textDocument &&
+          position == other.position &&
           true;
     }
     return false;
@@ -5520,10 +9539,10 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
-    hash = JenkinsSmiHash.combine(hash, position.hashCode);
     hash = JenkinsSmiHash.combine(hash, ch.hashCode);
     hash = JenkinsSmiHash.combine(hash, options.hashCode);
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5532,30 +9551,37 @@
 }
 
 class DocumentOnTypeFormattingRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentOnTypeFormattingOptions,
+        ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentOnTypeFormattingRegistrationOptions.canParse,
       DocumentOnTypeFormattingRegistrationOptions.fromJson);
 
-  DocumentOnTypeFormattingRegistrationOptions(this.firstTriggerCharacter,
-      this.moreTriggerCharacter, this.documentSelector) {
+  DocumentOnTypeFormattingRegistrationOptions(
+      {this.documentSelector,
+      @required this.firstTriggerCharacter,
+      this.moreTriggerCharacter}) {
     if (firstTriggerCharacter == null) {
       throw 'firstTriggerCharacter is required but was not provided';
     }
   }
   static DocumentOnTypeFormattingRegistrationOptions fromJson(
       Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
     final firstTriggerCharacter = json['firstTriggerCharacter'];
     final moreTriggerCharacter = json['moreTriggerCharacter']
         ?.map((item) => item)
         ?.cast<String>()
         ?.toList();
-    final documentSelector = json['documentSelector']
-        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
-        ?.cast<DocumentFilter>()
-        ?.toList();
     return DocumentOnTypeFormattingRegistrationOptions(
-        firstTriggerCharacter, moreTriggerCharacter, documentSelector);
+        documentSelector: documentSelector,
+        firstTriggerCharacter: firstTriggerCharacter,
+        moreTriggerCharacter: moreTriggerCharacter);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -5570,17 +9596,33 @@
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     __result['firstTriggerCharacter'] = firstTriggerCharacter ??
         (throw 'firstTriggerCharacter is required but was not set');
     if (moreTriggerCharacter != null) {
       __result['moreTriggerCharacter'] = moreTriggerCharacter;
     }
-    __result['documentSelector'] = documentSelector;
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('firstTriggerCharacter');
       try {
         if (!obj.containsKey('firstTriggerCharacter')) {
@@ -5610,22 +9652,6 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('documentSelector');
-      try {
-        if (!obj.containsKey('documentSelector')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['documentSelector'] != null &&
-            !((obj['documentSelector'] is List &&
-                (obj['documentSelector'].every(
-                    (item) => DocumentFilter.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<DocumentFilter>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       return true;
     } else {
       reporter.reportError(
@@ -5638,11 +9664,11 @@
   bool operator ==(Object other) {
     if (other is DocumentOnTypeFormattingRegistrationOptions &&
         other.runtimeType == DocumentOnTypeFormattingRegistrationOptions) {
-      return firstTriggerCharacter == other.firstTriggerCharacter &&
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          firstTriggerCharacter == other.firstTriggerCharacter &&
           listEqual(moreTriggerCharacter, other.moreTriggerCharacter,
               (String a, String b) => a == b) &&
-          listEqual(documentSelector, other.documentSelector,
-              (DocumentFilter a, DocumentFilter b) => a == b) &&
           true;
     }
     return false;
@@ -5651,9 +9677,9 @@
   @override
   int get hashCode {
     var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
     hash = JenkinsSmiHash.combine(hash, firstTriggerCharacter.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(moreTriggerCharacter));
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5661,12 +9687,146 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class DocumentRangeFormattingParams implements ToJsonable {
+class DocumentRangeFormattingClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentRangeFormattingClientCapabilities.canParse,
+      DocumentRangeFormattingClientCapabilities.fromJson);
+
+  DocumentRangeFormattingClientCapabilities({this.dynamicRegistration});
+  static DocumentRangeFormattingClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return DocumentRangeFormattingClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether formatting supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DocumentRangeFormattingClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentRangeFormattingClientCapabilities &&
+        other.runtimeType == DocumentRangeFormattingClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentRangeFormattingOptions
+    implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentRangeFormattingOptions.canParse,
+      DocumentRangeFormattingOptions.fromJson);
+
+  DocumentRangeFormattingOptions({this.workDoneProgress});
+  static DocumentRangeFormattingOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentRangeFormattingRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentRangeFormattingRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentRangeFormattingOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentRangeFormattingOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentRangeFormattingOptions &&
+        other.runtimeType == DocumentRangeFormattingOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentRangeFormattingParams
+    implements WorkDoneProgressParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentRangeFormattingParams.canParse,
       DocumentRangeFormattingParams.fromJson);
 
-  DocumentRangeFormattingParams(this.textDocument, this.range, this.options) {
+  DocumentRangeFormattingParams(
+      {@required this.textDocument,
+      @required this.range,
+      @required this.options,
+      this.workDoneToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -5685,7 +9845,18 @@
     final options = json['options'] != null
         ? FormattingOptions.fromJson(json['options'])
         : null;
-    return DocumentRangeFormattingParams(textDocument, range, options);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return DocumentRangeFormattingParams(
+        textDocument: textDocument,
+        range: range,
+        options: options,
+        workDoneToken: workDoneToken);
   }
 
   /// The format options
@@ -5697,6 +9868,9 @@
   /// The document to format.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
@@ -5704,6 +9878,9 @@
     __result['range'] = range ?? (throw 'range is required but was not set');
     __result['options'] =
         options ?? (throw 'options is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
     return __result;
   }
 
@@ -5760,6 +9937,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentRangeFormattingParams');
@@ -5774,6 +9962,7 @@
       return textDocument == other.textDocument &&
           range == other.range &&
           options == other.options &&
+          workDoneToken == other.workDoneToken &&
           true;
     }
     return false;
@@ -5785,6 +9974,103 @@
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, range.hashCode);
     hash = JenkinsSmiHash.combine(hash, options.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentRangeFormattingRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentRangeFormattingOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentRangeFormattingRegistrationOptions.canParse,
+      DocumentRangeFormattingRegistrationOptions.fromJson);
+
+  DocumentRangeFormattingRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress});
+  static DocumentRangeFormattingRegistrationOptions fromJson(
+      Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentRangeFormattingRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DocumentRangeFormattingRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentRangeFormattingRegistrationOptions &&
+        other.runtimeType == DocumentRangeFormattingRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -5800,8 +10086,14 @@
   static const jsonHandler =
       LspJsonHandler(DocumentSymbol.canParse, DocumentSymbol.fromJson);
 
-  DocumentSymbol(this.name, this.detail, this.kind, this.deprecated, this.range,
-      this.selectionRange, this.children) {
+  DocumentSymbol(
+      {@required this.name,
+      this.detail,
+      @required this.kind,
+      this.deprecated,
+      @required this.range,
+      @required this.selectionRange,
+      this.children}) {
     if (name == null) {
       throw 'name is required but was not provided';
     }
@@ -5830,7 +10122,13 @@
         ?.cast<DocumentSymbol>()
         ?.toList();
     return DocumentSymbol(
-        name, detail, kind, deprecated, range, selectionRange, children);
+        name: name,
+        detail: detail,
+        kind: kind,
+        deprecated: deprecated,
+        range: range,
+        selectionRange: selectionRange,
+        children: children);
   }
 
   /// Children of this symbol, e.g. properties of a class.
@@ -6019,11 +10317,268 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class DocumentSymbolParams implements ToJsonable {
+class DocumentSymbolClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentSymbolClientCapabilities.canParse,
+      DocumentSymbolClientCapabilities.fromJson);
+
+  DocumentSymbolClientCapabilities(
+      {this.dynamicRegistration,
+      this.symbolKind,
+      this.hierarchicalDocumentSymbolSupport});
+  static DocumentSymbolClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final symbolKind = json['symbolKind'] != null
+        ? DocumentSymbolClientCapabilitiesSymbolKind.fromJson(
+            json['symbolKind'])
+        : null;
+    final hierarchicalDocumentSymbolSupport =
+        json['hierarchicalDocumentSymbolSupport'];
+    return DocumentSymbolClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        symbolKind: symbolKind,
+        hierarchicalDocumentSymbolSupport: hierarchicalDocumentSymbolSupport);
+  }
+
+  /// Whether document symbol supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// The client supports hierarchical document symbols.
+  final bool hierarchicalDocumentSymbolSupport;
+
+  /// Specific capabilities for the `SymbolKind` in the
+  /// `textDocument/documentSymbol` request.
+  final DocumentSymbolClientCapabilitiesSymbolKind symbolKind;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (symbolKind != null) {
+      __result['symbolKind'] = symbolKind;
+    }
+    if (hierarchicalDocumentSymbolSupport != null) {
+      __result['hierarchicalDocumentSymbolSupport'] =
+          hierarchicalDocumentSymbolSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('symbolKind');
+      try {
+        if (obj['symbolKind'] != null &&
+            !(DocumentSymbolClientCapabilitiesSymbolKind.canParse(
+                obj['symbolKind'], reporter))) {
+          reporter.reportError(
+              'must be of type DocumentSymbolClientCapabilitiesSymbolKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('hierarchicalDocumentSymbolSupport');
+      try {
+        if (obj['hierarchicalDocumentSymbolSupport'] != null &&
+            !(obj['hierarchicalDocumentSymbolSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentSymbolClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentSymbolClientCapabilities &&
+        other.runtimeType == DocumentSymbolClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          symbolKind == other.symbolKind &&
+          hierarchicalDocumentSymbolSupport ==
+              other.hierarchicalDocumentSymbolSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, symbolKind.hashCode);
+    hash = JenkinsSmiHash.combine(
+        hash, hierarchicalDocumentSymbolSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentSymbolClientCapabilitiesSymbolKind implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentSymbolClientCapabilitiesSymbolKind.canParse,
+      DocumentSymbolClientCapabilitiesSymbolKind.fromJson);
+
+  DocumentSymbolClientCapabilitiesSymbolKind({this.valueSet});
+  static DocumentSymbolClientCapabilitiesSymbolKind fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? SymbolKind.fromJson(item) : null)
+        ?.cast<SymbolKind>()
+        ?.toList();
+    return DocumentSymbolClientCapabilitiesSymbolKind(valueSet: valueSet);
+  }
+
+  /// The symbol kind values the client supports. When this property exists the
+  /// client also guarantees that it will handle values outside its set
+  /// gracefully and falls back to a default value when unknown.
+  ///
+  /// If this property is not present the client only supports the symbol kinds
+  /// from `File` to `Array` as defined in the initial version of the protocol.
+  final List<SymbolKind> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (valueSet != null) {
+      __result['valueSet'] = valueSet;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (obj['valueSet'] != null &&
+            !((obj['valueSet'] is List &&
+                (obj['valueSet']
+                    .every((item) => SymbolKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<SymbolKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type DocumentSymbolClientCapabilitiesSymbolKind');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentSymbolClientCapabilitiesSymbolKind &&
+        other.runtimeType == DocumentSymbolClientCapabilitiesSymbolKind) {
+      return listEqual(valueSet, other.valueSet,
+              (SymbolKind a, SymbolKind b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentSymbolOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentSymbolOptions.canParse, DocumentSymbolOptions.fromJson);
+
+  DocumentSymbolOptions({this.workDoneProgress});
+  static DocumentSymbolOptions fromJson(Map<String, dynamic> json) {
+    if (DocumentSymbolRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentSymbolRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentSymbolOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentSymbolOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentSymbolOptions &&
+        other.runtimeType == DocumentSymbolOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentSymbolParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       DocumentSymbolParams.canParse, DocumentSymbolParams.fromJson);
 
-  DocumentSymbolParams(this.textDocument) {
+  DocumentSymbolParams(
+      {@required this.textDocument,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -6032,16 +10587,46 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
-    return DocumentSymbolParams(textDocument);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return DocumentSymbolParams(
+        textDocument: textDocument,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -6064,6 +10649,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type DocumentSymbolParams');
@@ -6075,7 +10682,10 @@
   bool operator ==(Object other) {
     if (other is DocumentSymbolParams &&
         other.runtimeType == DocumentSymbolParams) {
-      return textDocument == other.textDocument && true;
+      return textDocument == other.textDocument &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
     }
     return false;
   }
@@ -6084,6 +10694,102 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class DocumentSymbolRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        DocumentSymbolOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      DocumentSymbolRegistrationOptions.canParse,
+      DocumentSymbolRegistrationOptions.fromJson);
+
+  DocumentSymbolRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress});
+  static DocumentSymbolRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return DocumentSymbolRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type DocumentSymbolRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is DocumentSymbolRegistrationOptions &&
+        other.runtimeType == DocumentSymbolRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6127,29 +10833,99 @@
   bool operator ==(Object o) => o is ErrorCodes && o._value == _value;
 }
 
-/// Execute command options.
-class ExecuteCommandOptions implements ToJsonable {
+class ExecuteCommandClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ExecuteCommandClientCapabilities.canParse,
+      ExecuteCommandClientCapabilities.fromJson);
+
+  ExecuteCommandClientCapabilities({this.dynamicRegistration});
+  static ExecuteCommandClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return ExecuteCommandClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Execute command supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ExecuteCommandClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ExecuteCommandClientCapabilities &&
+        other.runtimeType == ExecuteCommandClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ExecuteCommandOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       ExecuteCommandOptions.canParse, ExecuteCommandOptions.fromJson);
 
-  ExecuteCommandOptions(this.commands) {
+  ExecuteCommandOptions({@required this.commands, this.workDoneProgress}) {
     if (commands == null) {
       throw 'commands is required but was not provided';
     }
   }
   static ExecuteCommandOptions fromJson(Map<String, dynamic> json) {
+    if (ExecuteCommandRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ExecuteCommandRegistrationOptions.fromJson(json);
+    }
     final commands =
         json['commands']?.map((item) => item)?.cast<String>()?.toList();
-    return ExecuteCommandOptions(commands);
+    final workDoneProgress = json['workDoneProgress'];
+    return ExecuteCommandOptions(
+        commands: commands, workDoneProgress: workDoneProgress);
   }
 
   /// The commands to be executed on the server
   final List<String> commands;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['commands'] =
         commands ?? (throw 'commands is required but was not set');
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -6173,6 +10949,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type ExecuteCommandOptions');
@@ -6186,6 +10972,7 @@
         other.runtimeType == ExecuteCommandOptions) {
       return listEqual(
               commands, other.commands, (String a, String b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -6195,6 +10982,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, lspHashCode(commands));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6202,11 +10990,12 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class ExecuteCommandParams implements ToJsonable {
+class ExecuteCommandParams implements WorkDoneProgressParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       ExecuteCommandParams.canParse, ExecuteCommandParams.fromJson);
 
-  ExecuteCommandParams(this.command, this.arguments) {
+  ExecuteCommandParams(
+      {@required this.command, this.arguments, this.workDoneToken}) {
     if (command == null) {
       throw 'command is required but was not provided';
     }
@@ -6215,7 +11004,15 @@
     final command = json['command'];
     final arguments =
         json['arguments']?.map((item) => item)?.cast<dynamic>()?.toList();
-    return ExecuteCommandParams(command, arguments);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return ExecuteCommandParams(
+        command: command, arguments: arguments, workDoneToken: workDoneToken);
   }
 
   /// Arguments that the command should be invoked with.
@@ -6224,6 +11021,9 @@
   /// The identifier of the actual command handler.
   final String command;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['command'] =
@@ -6231,6 +11031,9 @@
     if (arguments != null) {
       __result['arguments'] = arguments;
     }
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
     return __result;
   }
 
@@ -6264,6 +11067,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type ExecuteCommandParams');
@@ -6278,6 +11092,7 @@
       return command == other.command &&
           listEqual(
               arguments, other.arguments, (dynamic a, dynamic b) => a == b) &&
+          workDoneToken == other.workDoneToken &&
           true;
     }
     return false;
@@ -6288,6 +11103,7 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, command.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(arguments));
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6296,12 +11112,14 @@
 }
 
 /// Execute command registration options.
-class ExecuteCommandRegistrationOptions implements ToJsonable {
+class ExecuteCommandRegistrationOptions
+    implements ExecuteCommandOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       ExecuteCommandRegistrationOptions.canParse,
       ExecuteCommandRegistrationOptions.fromJson);
 
-  ExecuteCommandRegistrationOptions(this.commands) {
+  ExecuteCommandRegistrationOptions(
+      {@required this.commands, this.workDoneProgress}) {
     if (commands == null) {
       throw 'commands is required but was not provided';
     }
@@ -6309,16 +11127,22 @@
   static ExecuteCommandRegistrationOptions fromJson(Map<String, dynamic> json) {
     final commands =
         json['commands']?.map((item) => item)?.cast<String>()?.toList();
-    return ExecuteCommandRegistrationOptions(commands);
+    final workDoneProgress = json['workDoneProgress'];
+    return ExecuteCommandRegistrationOptions(
+        commands: commands, workDoneProgress: workDoneProgress);
   }
 
   /// The commands to be executed on the server
   final List<String> commands;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['commands'] =
         commands ?? (throw 'commands is required but was not set');
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -6342,6 +11166,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type ExecuteCommandRegistrationOptions');
@@ -6355,6 +11189,7 @@
         other.runtimeType == ExecuteCommandRegistrationOptions) {
       return listEqual(
               commands, other.commands, (String a, String b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -6364,6 +11199,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, lspHashCode(commands));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6393,18 +11229,18 @@
   /// executed.
   static const Abort = FailureHandlingKind._('abort');
 
-  /// All operations are executed transactionally. That means they either all
+  /// All operations are executed transactional. That means they either all
   /// succeed or no changes at all are applied to the workspace.
   static const Transactional = FailureHandlingKind._('transactional');
 
   /// If the workspace edit contains only textual file changes they are executed
-  /// transactionally. If resource changes (create, rename or delete file) are
+  /// transactional. If resource changes (create, rename or delete file) are
   /// part of the change the failure handling strategy is abort.
   static const TextOnlyTransactional =
       FailureHandlingKind._('textOnlyTransactional');
 
   /// The client tries to undo the operations already executed. But there is no
-  /// guarantee that this succeeds.
+  /// guarantee that this is succeeding.
   static const Undo = FailureHandlingKind._('undo');
 
   Object toJson() => _value;
@@ -6454,7 +11290,7 @@
   static const jsonHandler =
       LspJsonHandler(FileEvent.canParse, FileEvent.fromJson);
 
-  FileEvent(this.uri, this.type) {
+  FileEvent({@required this.uri, @required this.type}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -6465,7 +11301,7 @@
   static FileEvent fromJson(Map<String, dynamic> json) {
     final uri = json['uri'];
     final type = json['type'];
-    return FileEvent(uri, type);
+    return FileEvent(uri: uri, type: type);
   }
 
   /// The change type.
@@ -6548,7 +11384,7 @@
   static const jsonHandler =
       LspJsonHandler(FileSystemWatcher.canParse, FileSystemWatcher.fromJson);
 
-  FileSystemWatcher(this.globPattern, this.kind) {
+  FileSystemWatcher({@required this.globPattern, this.kind}) {
     if (globPattern == null) {
       throw 'globPattern is required but was not provided';
     }
@@ -6556,7 +11392,7 @@
   static FileSystemWatcher fromJson(Map<String, dynamic> json) {
     final globPattern = json['globPattern'];
     final kind = json['kind'] != null ? WatchKind.fromJson(json['kind']) : null;
-    return FileSystemWatcher(globPattern, kind);
+    return FileSystemWatcher(globPattern: globPattern, kind: kind);
   }
 
   /// The  glob pattern to watch.
@@ -6649,8 +11485,12 @@
   static const jsonHandler =
       LspJsonHandler(FoldingRange.canParse, FoldingRange.fromJson);
 
-  FoldingRange(this.startLine, this.startCharacter, this.endLine,
-      this.endCharacter, this.kind) {
+  FoldingRange(
+      {@required this.startLine,
+      this.startCharacter,
+      @required this.endLine,
+      this.endCharacter,
+      this.kind}) {
     if (startLine == null) {
       throw 'startLine is required but was not provided';
     }
@@ -6665,7 +11505,12 @@
     final endCharacter = json['endCharacter'];
     final kind =
         json['kind'] != null ? FoldingRangeKind.fromJson(json['kind']) : null;
-    return FoldingRange(startLine, startCharacter, endLine, endCharacter, kind);
+    return FoldingRange(
+        startLine: startLine,
+        startCharacter: startCharacter,
+        endLine: endLine,
+        endCharacter: endCharacter,
+        kind: kind);
   }
 
   /// The zero-based character offset before the folded range ends. If not
@@ -6805,6 +11650,116 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class FoldingRangeClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      FoldingRangeClientCapabilities.canParse,
+      FoldingRangeClientCapabilities.fromJson);
+
+  FoldingRangeClientCapabilities(
+      {this.dynamicRegistration, this.rangeLimit, this.lineFoldingOnly});
+  static FoldingRangeClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final rangeLimit = json['rangeLimit'];
+    final lineFoldingOnly = json['lineFoldingOnly'];
+    return FoldingRangeClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        rangeLimit: rangeLimit,
+        lineFoldingOnly: lineFoldingOnly);
+  }
+
+  /// Whether implementation supports dynamic registration for folding range
+  /// providers. If this is set to `true` the client supports the new
+  /// `FoldingRangeRegistrationOptions` return value for the corresponding
+  /// server capability as well.
+  final bool dynamicRegistration;
+
+  /// If set, the client signals that it only supports folding complete lines.
+  /// If set, client will ignore specified `startCharacter` and `endCharacter`
+  /// properties in a FoldingRange.
+  final bool lineFoldingOnly;
+
+  /// The maximum number of folding ranges that the client prefers to receive
+  /// per document. The value serves as a hint, servers are free to follow the
+  /// limit.
+  final num rangeLimit;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (rangeLimit != null) {
+      __result['rangeLimit'] = rangeLimit;
+    }
+    if (lineFoldingOnly != null) {
+      __result['lineFoldingOnly'] = lineFoldingOnly;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('rangeLimit');
+      try {
+        if (obj['rangeLimit'] != null && !(obj['rangeLimit'] is num)) {
+          reporter.reportError('must be of type num');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('lineFoldingOnly');
+      try {
+        if (obj['lineFoldingOnly'] != null &&
+            !(obj['lineFoldingOnly'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type FoldingRangeClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is FoldingRangeClientCapabilities &&
+        other.runtimeType == FoldingRangeClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          rangeLimit == other.rangeLimit &&
+          lineFoldingOnly == other.lineFoldingOnly &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, rangeLimit.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lineFoldingOnly.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Enum of known range kinds
 class FoldingRangeKind {
   const FoldingRangeKind(this._value);
@@ -6836,11 +11791,77 @@
   bool operator ==(Object o) => o is FoldingRangeKind && o._value == _value;
 }
 
-class FoldingRangeParams implements ToJsonable {
+class FoldingRangeOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      FoldingRangeOptions.canParse, FoldingRangeOptions.fromJson);
+
+  FoldingRangeOptions({this.workDoneProgress});
+  static FoldingRangeOptions fromJson(Map<String, dynamic> json) {
+    if (FoldingRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return FoldingRangeOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type FoldingRangeOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is FoldingRangeOptions &&
+        other.runtimeType == FoldingRangeOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class FoldingRangeParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(FoldingRangeParams.canParse, FoldingRangeParams.fromJson);
 
-  FoldingRangeParams(this.textDocument) {
+  FoldingRangeParams(
+      {@required this.textDocument,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -6849,16 +11870,46 @@
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
-    return FoldingRangeParams(textDocument);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return FoldingRangeParams(
+        textDocument: textDocument,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -6881,6 +11932,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type FoldingRangeParams');
@@ -6892,7 +11965,10 @@
   bool operator ==(Object other) {
     if (other is FoldingRangeParams &&
         other.runtimeType == FoldingRangeParams) {
-      return textDocument == other.textDocument && true;
+      return textDocument == other.textDocument &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
     }
     return false;
   }
@@ -6901,6 +11977,8 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6908,35 +11986,105 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Folding range provider options.
-class FoldingRangeProviderOptions implements ToJsonable {
+class FoldingRangeRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        FoldingRangeOptions,
+        StaticRegistrationOptions,
+        ToJsonable {
   static const jsonHandler = LspJsonHandler(
-      FoldingRangeProviderOptions.canParse,
-      FoldingRangeProviderOptions.fromJson);
+      FoldingRangeRegistrationOptions.canParse,
+      FoldingRangeRegistrationOptions.fromJson);
 
-  static FoldingRangeProviderOptions fromJson(Map<String, dynamic> json) {
-    return FoldingRangeProviderOptions();
+  FoldingRangeRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress, this.id});
+  static FoldingRangeRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    final id = json['id'];
+    return FoldingRangeRegistrationOptions(
+        documentSelector: documentSelector,
+        workDoneProgress: workDoneProgress,
+        id: id);
   }
 
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    if (id != null) {
+      __result['id'] = id;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
-      reporter.reportError('must be of type FoldingRangeProviderOptions');
+      reporter.reportError('must be of type FoldingRangeRegistrationOptions');
       return false;
     }
   }
 
   @override
   bool operator ==(Object other) {
-    if (other is FoldingRangeProviderOptions &&
-        other.runtimeType == FoldingRangeProviderOptions) {
-      return true;
+    if (other is FoldingRangeRegistrationOptions &&
+        other.runtimeType == FoldingRangeRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          id == other.id &&
+          true;
     }
     return false;
   }
@@ -6944,6 +12092,9 @@
   @override
   int get hashCode {
     var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -6956,7 +12107,12 @@
   static const jsonHandler =
       LspJsonHandler(FormattingOptions.canParse, FormattingOptions.fromJson);
 
-  FormattingOptions(this.tabSize, this.insertSpaces) {
+  FormattingOptions(
+      {@required this.tabSize,
+      @required this.insertSpaces,
+      this.trimTrailingWhitespace,
+      this.insertFinalNewline,
+      this.trimFinalNewlines}) {
     if (tabSize == null) {
       throw 'tabSize is required but was not provided';
     }
@@ -6967,21 +12123,50 @@
   static FormattingOptions fromJson(Map<String, dynamic> json) {
     final tabSize = json['tabSize'];
     final insertSpaces = json['insertSpaces'];
-    return FormattingOptions(tabSize, insertSpaces);
+    final trimTrailingWhitespace = json['trimTrailingWhitespace'];
+    final insertFinalNewline = json['insertFinalNewline'];
+    final trimFinalNewlines = json['trimFinalNewlines'];
+    return FormattingOptions(
+        tabSize: tabSize,
+        insertSpaces: insertSpaces,
+        trimTrailingWhitespace: trimTrailingWhitespace,
+        insertFinalNewline: insertFinalNewline,
+        trimFinalNewlines: trimFinalNewlines);
   }
 
+  /// Insert a newline character at the end of the file if one does not exist.
+  ///  @since 3.15.0
+  final bool insertFinalNewline;
+
   /// Prefer spaces over tabs.
   final bool insertSpaces;
 
   /// Size of a tab in spaces.
   final num tabSize;
 
+  /// Trim all newlines after the final newline at the end of the file.
+  ///  @since 3.15.0
+  final bool trimFinalNewlines;
+
+  /// Trim trailing whitespace on a line.
+  ///  @since 3.15.0
+  final bool trimTrailingWhitespace;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['tabSize'] =
         tabSize ?? (throw 'tabSize is required but was not set');
     __result['insertSpaces'] =
         insertSpaces ?? (throw 'insertSpaces is required but was not set');
+    if (trimTrailingWhitespace != null) {
+      __result['trimTrailingWhitespace'] = trimTrailingWhitespace;
+    }
+    if (insertFinalNewline != null) {
+      __result['insertFinalNewline'] = insertFinalNewline;
+    }
+    if (trimFinalNewlines != null) {
+      __result['trimFinalNewlines'] = trimFinalNewlines;
+    }
     return __result;
   }
 
@@ -7021,6 +12206,36 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('trimTrailingWhitespace');
+      try {
+        if (obj['trimTrailingWhitespace'] != null &&
+            !(obj['trimTrailingWhitespace'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('insertFinalNewline');
+      try {
+        if (obj['insertFinalNewline'] != null &&
+            !(obj['insertFinalNewline'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('trimFinalNewlines');
+      try {
+        if (obj['trimFinalNewlines'] != null &&
+            !(obj['trimFinalNewlines'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type FormattingOptions');
@@ -7033,6 +12248,9 @@
     if (other is FormattingOptions && other.runtimeType == FormattingOptions) {
       return tabSize == other.tabSize &&
           insertSpaces == other.insertSpaces &&
+          trimTrailingWhitespace == other.trimTrailingWhitespace &&
+          insertFinalNewline == other.insertFinalNewline &&
+          trimFinalNewlines == other.trimFinalNewlines &&
           true;
     }
     return false;
@@ -7043,6 +12261,9 @@
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, tabSize.hashCode);
     hash = JenkinsSmiHash.combine(hash, insertSpaces.hashCode);
+    hash = JenkinsSmiHash.combine(hash, trimTrailingWhitespace.hashCode);
+    hash = JenkinsSmiHash.combine(hash, insertFinalNewline.hashCode);
+    hash = JenkinsSmiHash.combine(hash, trimFinalNewlines.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -7054,7 +12275,7 @@
 class Hover implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Hover.canParse, Hover.fromJson);
 
-  Hover(this.contents, this.range) {
+  Hover({@required this.contents, this.range}) {
     if (contents == null) {
       throw 'contents is required but was not provided';
     }
@@ -7068,7 +12289,7 @@
                 : null)
             : (throw '''${json['contents']} was not one of (String, MarkupContent)'''));
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
-    return Hover(contents, range);
+    return Hover(contents: contents, range: range);
   }
 
   /// The hover's content
@@ -7145,24 +12366,832 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class InitializeParams implements ToJsonable {
+class HoverClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      HoverClientCapabilities.canParse, HoverClientCapabilities.fromJson);
+
+  HoverClientCapabilities({this.dynamicRegistration, this.contentFormat});
+  static HoverClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final contentFormat = json['contentFormat']
+        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
+        ?.cast<MarkupKind>()
+        ?.toList();
+    return HoverClientCapabilities(
+        dynamicRegistration: dynamicRegistration, contentFormat: contentFormat);
+  }
+
+  /// Client supports the follow content formats for the content property. The
+  /// order describes the preferred format of the client.
+  final List<MarkupKind> contentFormat;
+
+  /// Whether hover supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (contentFormat != null) {
+      __result['contentFormat'] = contentFormat;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('contentFormat');
+      try {
+        if (obj['contentFormat'] != null &&
+            !((obj['contentFormat'] is List &&
+                (obj['contentFormat']
+                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<MarkupKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type HoverClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is HoverClientCapabilities &&
+        other.runtimeType == HoverClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          listEqual(contentFormat, other.contentFormat,
+              (MarkupKind a, MarkupKind b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(contentFormat));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class HoverOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(HoverOptions.canParse, HoverOptions.fromJson);
+
+  HoverOptions({this.workDoneProgress});
+  static HoverOptions fromJson(Map<String, dynamic> json) {
+    if (HoverRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return HoverRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return HoverOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type HoverOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is HoverOptions && other.runtimeType == HoverOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class HoverParams
+    implements TextDocumentPositionParams, WorkDoneProgressParams, ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(HoverParams.canParse, HoverParams.fromJson);
+
+  HoverParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static HoverParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return HoverParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken);
+  }
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type HoverParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is HoverParams && other.runtimeType == HoverParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class HoverRegistrationOptions
+    implements TextDocumentRegistrationOptions, HoverOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      HoverRegistrationOptions.canParse, HoverRegistrationOptions.fromJson);
+
+  HoverRegistrationOptions({this.documentSelector, this.workDoneProgress});
+  static HoverRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return HoverRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type HoverRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is HoverRegistrationOptions &&
+        other.runtimeType == HoverRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ImplementationClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ImplementationClientCapabilities.canParse,
+      ImplementationClientCapabilities.fromJson);
+
+  ImplementationClientCapabilities(
+      {this.dynamicRegistration, this.linkSupport});
+  static ImplementationClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final linkSupport = json['linkSupport'];
+    return ImplementationClientCapabilities(
+        dynamicRegistration: dynamicRegistration, linkSupport: linkSupport);
+  }
+
+  /// Whether implementation supports dynamic registration. If this is set to
+  /// `true` the client supports the new `ImplementationRegistrationOptions`
+  /// return value for the corresponding server capability as well.
+  final bool dynamicRegistration;
+
+  /// The client supports additional metadata in the form of definition links.
+  ///  @since 3.14.0
+  final bool linkSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (linkSupport != null) {
+      __result['linkSupport'] = linkSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('linkSupport');
+      try {
+        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ImplementationClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ImplementationClientCapabilities &&
+        other.runtimeType == ImplementationClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          linkSupport == other.linkSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ImplementationOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ImplementationOptions.canParse, ImplementationOptions.fromJson);
+
+  ImplementationOptions({this.workDoneProgress});
+  static ImplementationOptions fromJson(Map<String, dynamic> json) {
+    if (ImplementationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ImplementationRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return ImplementationOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ImplementationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ImplementationOptions &&
+        other.runtimeType == ImplementationOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ImplementationParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ImplementationParams.canParse, ImplementationParams.fromJson);
+
+  ImplementationParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static ImplementationParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return ImplementationParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ImplementationParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ImplementationParams &&
+        other.runtimeType == ImplementationParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ImplementationRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        ImplementationOptions,
+        StaticRegistrationOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ImplementationRegistrationOptions.canParse,
+      ImplementationRegistrationOptions.fromJson);
+
+  ImplementationRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress, this.id});
+  static ImplementationRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    final id = json['id'];
+    return ImplementationRegistrationOptions(
+        documentSelector: documentSelector,
+        workDoneProgress: workDoneProgress,
+        id: id);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    if (id != null) {
+      __result['id'] = id;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ImplementationRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ImplementationRegistrationOptions &&
+        other.runtimeType == ImplementationRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          id == other.id &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class InitializeParams implements WorkDoneProgressParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(InitializeParams.canParse, InitializeParams.fromJson);
 
   InitializeParams(
-      this.processId,
+      {this.processId,
+      this.clientInfo,
       this.rootPath,
       this.rootUri,
       this.initializationOptions,
-      this.capabilities,
+      @required this.capabilities,
       this.trace,
-      this.workspaceFolders) {
+      this.workspaceFolders,
+      this.workDoneToken}) {
     if (capabilities == null) {
       throw 'capabilities is required but was not provided';
     }
   }
   static InitializeParams fromJson(Map<String, dynamic> json) {
     final processId = json['processId'];
+    final clientInfo = json['clientInfo'] != null
+        ? InitializeParamsClientInfo.fromJson(json['clientInfo'])
+        : null;
     final rootPath = json['rootPath'];
     final rootUri = json['rootUri'];
     final initializationOptions = json['initializationOptions'];
@@ -7174,13 +13203,32 @@
         ?.map((item) => item != null ? WorkspaceFolder.fromJson(item) : null)
         ?.cast<WorkspaceFolder>()
         ?.toList();
-    return InitializeParams(processId, rootPath, rootUri, initializationOptions,
-        capabilities, trace, workspaceFolders);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return InitializeParams(
+        processId: processId,
+        clientInfo: clientInfo,
+        rootPath: rootPath,
+        rootUri: rootUri,
+        initializationOptions: initializationOptions,
+        capabilities: capabilities,
+        trace: trace,
+        workspaceFolders: workspaceFolders,
+        workDoneToken: workDoneToken);
   }
 
   /// The capabilities provided by the client (editor or tool)
   final ClientCapabilities capabilities;
 
+  /// Information about the client
+  ///  @since 3.15.0
+  final InitializeParamsClientInfo clientInfo;
+
   /// User provided initialization options.
   final dynamic initializationOptions;
 
@@ -7202,17 +13250,22 @@
   /// The initial trace setting. If omitted trace is disabled ('off').
   final String trace;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   /// The workspace folders configured in the client when the server starts.
   /// This property is only available if the client supports workspace folders.
   /// It can be `null` if the client supports workspace folders but none are
   /// configured.
-  ///
-  /// Since 3.6.0
+  ///  @since 3.6.0
   final List<WorkspaceFolder> workspaceFolders;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['processId'] = processId;
+    if (clientInfo != null) {
+      __result['clientInfo'] = clientInfo;
+    }
     if (rootPath != null) {
       __result['rootPath'] = rootPath;
     }
@@ -7228,6 +13281,9 @@
     if (workspaceFolders != null) {
       __result['workspaceFolders'] = workspaceFolders;
     }
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
     return __result;
   }
 
@@ -7246,6 +13302,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('clientInfo');
+      try {
+        if (obj['clientInfo'] != null &&
+            !(InitializeParamsClientInfo.canParse(
+                obj['clientInfo'], reporter))) {
+          reporter.reportError('must be of type InitializeParamsClientInfo');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('rootPath');
       try {
         if (obj['rootPath'] != null && !(obj['rootPath'] is String)) {
@@ -7315,6 +13382,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type InitializeParams');
@@ -7326,6 +13404,7 @@
   bool operator ==(Object other) {
     if (other is InitializeParams && other.runtimeType == InitializeParams) {
       return processId == other.processId &&
+          clientInfo == other.clientInfo &&
           rootPath == other.rootPath &&
           rootUri == other.rootUri &&
           initializationOptions == other.initializationOptions &&
@@ -7333,6 +13412,7 @@
           trace == other.trace &&
           listEqual(workspaceFolders, other.workspaceFolders,
               (WorkspaceFolder a, WorkspaceFolder b) => a == b) &&
+          workDoneToken == other.workDoneToken &&
           true;
     }
     return false;
@@ -7342,12 +13422,100 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, processId.hashCode);
+    hash = JenkinsSmiHash.combine(hash, clientInfo.hashCode);
     hash = JenkinsSmiHash.combine(hash, rootPath.hashCode);
     hash = JenkinsSmiHash.combine(hash, rootUri.hashCode);
     hash = JenkinsSmiHash.combine(hash, initializationOptions.hashCode);
     hash = JenkinsSmiHash.combine(hash, capabilities.hashCode);
     hash = JenkinsSmiHash.combine(hash, trace.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(workspaceFolders));
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class InitializeParamsClientInfo implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      InitializeParamsClientInfo.canParse, InitializeParamsClientInfo.fromJson);
+
+  InitializeParamsClientInfo({@required this.name, this.version}) {
+    if (name == null) {
+      throw 'name is required but was not provided';
+    }
+  }
+  static InitializeParamsClientInfo fromJson(Map<String, dynamic> json) {
+    final name = json['name'];
+    final version = json['version'];
+    return InitializeParamsClientInfo(name: name, version: version);
+  }
+
+  /// The name of the client as defined by the client.
+  final String name;
+
+  /// The client's version as defined by the client.
+  final String version;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['name'] = name ?? (throw 'name is required but was not set');
+    if (version != null) {
+      __result['version'] = version;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('name');
+      try {
+        if (!obj.containsKey('name')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['name'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['name'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('version');
+      try {
+        if (obj['version'] != null && !(obj['version'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type InitializeParamsClientInfo');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is InitializeParamsClientInfo &&
+        other.runtimeType == InitializeParamsClientInfo) {
+      return name == other.name && version == other.version && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, name.hashCode);
+    hash = JenkinsSmiHash.combine(hash, version.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -7359,7 +13527,7 @@
   static const jsonHandler =
       LspJsonHandler(InitializeResult.canParse, InitializeResult.fromJson);
 
-  InitializeResult(this.capabilities) {
+  InitializeResult({@required this.capabilities, this.serverInfo}) {
     if (capabilities == null) {
       throw 'capabilities is required but was not provided';
     }
@@ -7368,16 +13536,26 @@
     final capabilities = json['capabilities'] != null
         ? ServerCapabilities.fromJson(json['capabilities'])
         : null;
-    return InitializeResult(capabilities);
+    final serverInfo = json['serverInfo'] != null
+        ? InitializeResultServerInfo.fromJson(json['serverInfo'])
+        : null;
+    return InitializeResult(capabilities: capabilities, serverInfo: serverInfo);
   }
 
   /// The capabilities the language server provides.
   final ServerCapabilities capabilities;
 
+  /// Information about the server.
+  ///  @since 3.15.0
+  final InitializeResultServerInfo serverInfo;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['capabilities'] =
         capabilities ?? (throw 'capabilities is required but was not set');
+    if (serverInfo != null) {
+      __result['serverInfo'] = serverInfo;
+    }
     return __result;
   }
 
@@ -7400,6 +13578,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('serverInfo');
+      try {
+        if (obj['serverInfo'] != null &&
+            !(InitializeResultServerInfo.canParse(
+                obj['serverInfo'], reporter))) {
+          reporter.reportError('must be of type InitializeResultServerInfo');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type InitializeResult');
@@ -7410,7 +13599,9 @@
   @override
   bool operator ==(Object other) {
     if (other is InitializeResult && other.runtimeType == InitializeResult) {
-      return capabilities == other.capabilities && true;
+      return capabilities == other.capabilities &&
+          serverInfo == other.serverInfo &&
+          true;
     }
     return false;
   }
@@ -7419,6 +13610,93 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, capabilities.hashCode);
+    hash = JenkinsSmiHash.combine(hash, serverInfo.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class InitializeResultServerInfo implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      InitializeResultServerInfo.canParse, InitializeResultServerInfo.fromJson);
+
+  InitializeResultServerInfo({@required this.name, this.version}) {
+    if (name == null) {
+      throw 'name is required but was not provided';
+    }
+  }
+  static InitializeResultServerInfo fromJson(Map<String, dynamic> json) {
+    final name = json['name'];
+    final version = json['version'];
+    return InitializeResultServerInfo(name: name, version: version);
+  }
+
+  /// The name of the server as defined by the server.
+  final String name;
+
+  /// The server's version as defined by the server.
+  final String version;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['name'] = name ?? (throw 'name is required but was not set');
+    if (version != null) {
+      __result['version'] = version;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('name');
+      try {
+        if (!obj.containsKey('name')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['name'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['name'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('version');
+      try {
+        if (obj['version'] != null && !(obj['version'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type InitializeResultServerInfo');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is InitializeResultServerInfo &&
+        other.runtimeType == InitializeResultServerInfo) {
+      return name == other.name && version == other.version && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, name.hashCode);
+    hash = JenkinsSmiHash.combine(hash, version.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -7509,7 +13787,7 @@
   static const jsonHandler =
       LspJsonHandler(Location.canParse, Location.fromJson);
 
-  Location(this.uri, this.range) {
+  Location({@required this.uri, @required this.range}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -7520,7 +13798,7 @@
   static Location fromJson(Map<String, dynamic> json) {
     final uri = json['uri'];
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
-    return Location(uri, range);
+    return Location(uri: uri, range: range);
   }
 
   final Range range;
@@ -7600,8 +13878,11 @@
   static const jsonHandler =
       LspJsonHandler(LocationLink.canParse, LocationLink.fromJson);
 
-  LocationLink(this.originSelectionRange, this.targetUri, this.targetRange,
-      this.targetSelectionRange) {
+  LocationLink(
+      {this.originSelectionRange,
+      @required this.targetUri,
+      @required this.targetRange,
+      @required this.targetSelectionRange}) {
     if (targetUri == null) {
       throw 'targetUri is required but was not provided';
     }
@@ -7624,7 +13905,10 @@
         ? Range.fromJson(json['targetSelectionRange'])
         : null;
     return LocationLink(
-        originSelectionRange, targetUri, targetRange, targetSelectionRange);
+        originSelectionRange: originSelectionRange,
+        targetUri: targetUri,
+        targetRange: targetRange,
+        targetSelectionRange: targetSelectionRange);
   }
 
   /// Span of the origin of this link.
@@ -7761,7 +14045,7 @@
   static const jsonHandler =
       LspJsonHandler(LogMessageParams.canParse, LogMessageParams.fromJson);
 
-  LogMessageParams(this.type, this.message) {
+  LogMessageParams({@required this.type, @required this.message}) {
     if (type == null) {
       throw 'type is required but was not provided';
     }
@@ -7773,7 +14057,7 @@
     final type =
         json['type'] != null ? MessageType.fromJson(json['type']) : null;
     final message = json['message'];
-    return LogMessageParams(type, message);
+    return LogMessageParams(type: type, message: message);
   }
 
   /// The actual message
@@ -7879,7 +14163,7 @@
   static const jsonHandler =
       LspJsonHandler(MarkupContent.canParse, MarkupContent.fromJson);
 
-  MarkupContent(this.kind, this.value) {
+  MarkupContent({@required this.kind, @required this.value}) {
     if (kind == null) {
       throw 'kind is required but was not provided';
     }
@@ -7891,7 +14175,7 @@
     final kind =
         json['kind'] != null ? MarkupKind.fromJson(json['kind']) : null;
     final value = json['value'];
-    return MarkupContent(kind, value);
+    return MarkupContent(kind: kind, value: value);
   }
 
   /// The type of the Markup
@@ -8010,7 +14294,7 @@
 class Message implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Message.canParse, Message.fromJson);
 
-  Message(this.jsonrpc) {
+  Message({@required this.jsonrpc}) {
     if (jsonrpc == null) {
       throw 'jsonrpc is required but was not provided';
     }
@@ -8026,7 +14310,7 @@
       return NotificationMessage.fromJson(json);
     }
     final jsonrpc = json['jsonrpc'];
-    return Message(jsonrpc);
+    return Message(jsonrpc: jsonrpc);
   }
 
   final String jsonrpc;
@@ -8087,14 +14371,14 @@
   static const jsonHandler =
       LspJsonHandler(MessageActionItem.canParse, MessageActionItem.fromJson);
 
-  MessageActionItem(this.title) {
+  MessageActionItem({@required this.title}) {
     if (title == null) {
       throw 'title is required but was not provided';
     }
   }
   static MessageActionItem fromJson(Map<String, dynamic> json) {
     final title = json['title'];
-    return MessageActionItem(title);
+    return MessageActionItem(title: title);
   }
 
   /// A short title like 'Retry', 'Open Log' etc.
@@ -8198,6 +14482,9 @@
   /// Constant for the '$/cancelRequest' method.
   static const cancelRequest = Method(r'$/cancelRequest');
 
+  /// Constant for the '$/progress' method.
+  static const progress = Method(r'$/progress');
+
   /// Constant for the 'initialize' method.
   static const initialize = Method(r'initialize');
 
@@ -8219,6 +14506,14 @@
   /// Constant for the 'window/logMessage' method.
   static const window_logMessage = Method(r'window/logMessage');
 
+  /// Constant for the 'window/workDoneProgress/create' method.
+  static const window_workDoneProgress_create =
+      Method(r'window/workDoneProgress/create');
+
+  /// Constant for the 'window/workDoneProgress/cancel' method.
+  static const window_workDoneProgress_cancel =
+      Method(r'window/workDoneProgress/cancel');
+
   /// Constant for the 'telemetry/event' method.
   static const telemetry_event = Method(r'telemetry/event');
 
@@ -8270,6 +14565,9 @@
   static const textDocument_willSaveWaitUntil =
       Method(r'textDocument/willSaveWaitUntil');
 
+  /// Constant for the 'textDocument/didSave' method.
+  static const textDocument_didSave = Method(r'textDocument/didSave');
+
   /// Constant for the 'textDocument/didClose' method.
   static const textDocument_didClose = Method(r'textDocument/didClose');
 
@@ -8359,6 +14657,10 @@
   /// Constant for the 'textDocument/foldingRange' method.
   static const textDocument_foldingRange = Method(r'textDocument/foldingRange');
 
+  /// Constant for the 'textDocument/selectionRange' method.
+  static const textDocument_selectionRange =
+      Method(r'textDocument/selectionRange');
+
   Object toJson() => _value;
 
   @override
@@ -8374,7 +14676,8 @@
   static const jsonHandler = LspJsonHandler(
       NotificationMessage.canParse, NotificationMessage.fromJson);
 
-  NotificationMessage(this.method, this.params, this.jsonrpc) {
+  NotificationMessage(
+      {@required this.method, this.params, @required this.jsonrpc}) {
     if (method == null) {
       throw 'method is required but was not provided';
     }
@@ -8387,7 +14690,8 @@
         json['method'] != null ? Method.fromJson(json['method']) : null;
     final params = json['params'];
     final jsonrpc = json['jsonrpc'];
-    return NotificationMessage(method, params, jsonrpc);
+    return NotificationMessage(
+        method: method, params: params, jsonrpc: jsonrpc);
   }
 
   final String jsonrpc;
@@ -8492,7 +14796,7 @@
   static const jsonHandler = LspJsonHandler(
       ParameterInformation.canParse, ParameterInformation.fromJson);
 
-  ParameterInformation(this.label, this.documentation) {
+  ParameterInformation({@required this.label, this.documentation}) {
     if (label == null) {
       throw 'label is required but was not provided';
     }
@@ -8508,7 +14812,7 @@
             : (json['documentation'] == null
                 ? null
                 : (throw '''${json['documentation']} was not one of (String, MarkupContent)''')));
-    return ParameterInformation(label, documentation);
+    return ParameterInformation(label: label, documentation: documentation);
   }
 
   /// The human-readable doc-comment of this parameter. Will be shown in the UI
@@ -8597,11 +14901,127 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class PartialResultParams implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      PartialResultParams.canParse, PartialResultParams.fromJson);
+
+  PartialResultParams({this.partialResultToken});
+  static PartialResultParams fromJson(Map<String, dynamic> json) {
+    if (WorkspaceSymbolParams.canParse(json, nullLspJsonReporter)) {
+      return WorkspaceSymbolParams.fromJson(json);
+    }
+    if (CompletionParams.canParse(json, nullLspJsonReporter)) {
+      return CompletionParams.fromJson(json);
+    }
+    if (DeclarationParams.canParse(json, nullLspJsonReporter)) {
+      return DeclarationParams.fromJson(json);
+    }
+    if (DefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return DefinitionParams.fromJson(json);
+    }
+    if (TypeDefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionParams.fromJson(json);
+    }
+    if (ImplementationParams.canParse(json, nullLspJsonReporter)) {
+      return ImplementationParams.fromJson(json);
+    }
+    if (ReferenceParams.canParse(json, nullLspJsonReporter)) {
+      return ReferenceParams.fromJson(json);
+    }
+    if (DocumentHighlightParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentHighlightParams.fromJson(json);
+    }
+    if (DocumentSymbolParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentSymbolParams.fromJson(json);
+    }
+    if (CodeActionParams.canParse(json, nullLspJsonReporter)) {
+      return CodeActionParams.fromJson(json);
+    }
+    if (CodeLensParams.canParse(json, nullLspJsonReporter)) {
+      return CodeLensParams.fromJson(json);
+    }
+    if (DocumentLinkParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentLinkParams.fromJson(json);
+    }
+    if (DocumentColorParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorParams.fromJson(json);
+    }
+    if (ColorPresentationParams.canParse(json, nullLspJsonReporter)) {
+      return ColorPresentationParams.fromJson(json);
+    }
+    if (FoldingRangeParams.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeParams.fromJson(json);
+    }
+    if (SelectionRangeParams.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeParams.fromJson(json);
+    }
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return PartialResultParams(partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type PartialResultParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is PartialResultParams &&
+        other.runtimeType == PartialResultParams) {
+      return partialResultToken == other.partialResultToken && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class Position implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(Position.canParse, Position.fromJson);
 
-  Position(this.line, this.character) {
+  Position({@required this.line, @required this.character}) {
     if (line == null) {
       throw 'line is required but was not provided';
     }
@@ -8612,7 +15032,7 @@
   static Position fromJson(Map<String, dynamic> json) {
     final line = json['line'];
     final character = json['character'];
-    return Position(line, character);
+    return Position(line: line, character: character);
   }
 
   /// Character offset on a line in a document (zero-based). Assuming that the
@@ -8697,11 +15117,406 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class PrepareRenameParams implements TextDocumentPositionParams, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      PrepareRenameParams.canParse, PrepareRenameParams.fromJson);
+
+  PrepareRenameParams({@required this.textDocument, @required this.position}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static PrepareRenameParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    return PrepareRenameParams(textDocument: textDocument, position: position);
+  }
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type PrepareRenameParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is PrepareRenameParams &&
+        other.runtimeType == PrepareRenameParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ProgressParams<T> implements ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(ProgressParams.canParse, ProgressParams.fromJson);
+
+  ProgressParams({@required this.token, @required this.value}) {
+    if (token == null) {
+      throw 'token is required but was not provided';
+    }
+    if (value == null) {
+      throw 'value is required but was not provided';
+    }
+  }
+  static ProgressParams<T> fromJson<T>(Map<String, dynamic> json) {
+    final token = json['token'] is num
+        ? Either2<num, String>.t1(json['token'])
+        : (json['token'] is String
+            ? Either2<num, String>.t2(json['token'])
+            : (throw '''${json['token']} was not one of (num, String)'''));
+    final value = json['value'];
+    return ProgressParams<T>(token: token, value: value);
+  }
+
+  /// The progress token provided by the client or server.
+  final Either2<num, String> token;
+
+  /// The progress data.
+  final T value;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['token'] = token ?? (throw 'token is required but was not set');
+    __result['value'] = value ?? (throw 'value is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('token');
+      try {
+        if (!obj.containsKey('token')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['token'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['token'] is num || obj['token'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('value');
+      try {
+        if (!obj.containsKey('value')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['value'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(true /* T.canParse(obj['value']) */)) {
+          reporter.reportError('must be of type T');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ProgressParams<T>');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ProgressParams && other.runtimeType == ProgressParams) {
+      return token == other.token && value == other.value && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, token.hashCode);
+    hash = JenkinsSmiHash.combine(hash, value.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class PublishDiagnosticsClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      PublishDiagnosticsClientCapabilities.canParse,
+      PublishDiagnosticsClientCapabilities.fromJson);
+
+  PublishDiagnosticsClientCapabilities(
+      {this.relatedInformation, this.tagSupport, this.versionSupport});
+  static PublishDiagnosticsClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final relatedInformation = json['relatedInformation'];
+    final tagSupport = json['tagSupport'] != null
+        ? PublishDiagnosticsClientCapabilitiesTagSupport.fromJson(
+            json['tagSupport'])
+        : null;
+    final versionSupport = json['versionSupport'];
+    return PublishDiagnosticsClientCapabilities(
+        relatedInformation: relatedInformation,
+        tagSupport: tagSupport,
+        versionSupport: versionSupport);
+  }
+
+  /// Whether the clients accepts diagnostics with related information.
+  final bool relatedInformation;
+
+  /// Client supports the tag property to provide meta data about a diagnostic.
+  /// Clients supporting tags have to handle unknown tags gracefully.
+  ///  @since 3.15.0
+  final PublishDiagnosticsClientCapabilitiesTagSupport tagSupport;
+
+  /// Whether the client interprets the version property of the
+  /// `textDocument/publishDiagnostics` notification's parameter.
+  ///  @since 3.15.0
+  final bool versionSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (relatedInformation != null) {
+      __result['relatedInformation'] = relatedInformation;
+    }
+    if (tagSupport != null) {
+      __result['tagSupport'] = tagSupport;
+    }
+    if (versionSupport != null) {
+      __result['versionSupport'] = versionSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('relatedInformation');
+      try {
+        if (obj['relatedInformation'] != null &&
+            !(obj['relatedInformation'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('tagSupport');
+      try {
+        if (obj['tagSupport'] != null &&
+            !(PublishDiagnosticsClientCapabilitiesTagSupport.canParse(
+                obj['tagSupport'], reporter))) {
+          reporter.reportError(
+              'must be of type PublishDiagnosticsClientCapabilitiesTagSupport');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('versionSupport');
+      try {
+        if (obj['versionSupport'] != null && !(obj['versionSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type PublishDiagnosticsClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is PublishDiagnosticsClientCapabilities &&
+        other.runtimeType == PublishDiagnosticsClientCapabilities) {
+      return relatedInformation == other.relatedInformation &&
+          tagSupport == other.tagSupport &&
+          versionSupport == other.versionSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, relatedInformation.hashCode);
+    hash = JenkinsSmiHash.combine(hash, tagSupport.hashCode);
+    hash = JenkinsSmiHash.combine(hash, versionSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class PublishDiagnosticsClientCapabilitiesTagSupport implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      PublishDiagnosticsClientCapabilitiesTagSupport.canParse,
+      PublishDiagnosticsClientCapabilitiesTagSupport.fromJson);
+
+  PublishDiagnosticsClientCapabilitiesTagSupport({@required this.valueSet}) {
+    if (valueSet == null) {
+      throw 'valueSet is required but was not provided';
+    }
+  }
+  static PublishDiagnosticsClientCapabilitiesTagSupport fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? DiagnosticTag.fromJson(item) : null)
+        ?.cast<DiagnosticTag>()
+        ?.toList();
+    return PublishDiagnosticsClientCapabilitiesTagSupport(valueSet: valueSet);
+  }
+
+  /// The tags supported by the client.
+  final List<DiagnosticTag> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['valueSet'] =
+        valueSet ?? (throw 'valueSet is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (!obj.containsKey('valueSet')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['valueSet'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['valueSet'] is List &&
+            (obj['valueSet']
+                .every((item) => DiagnosticTag.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DiagnosticTag>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type PublishDiagnosticsClientCapabilitiesTagSupport');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is PublishDiagnosticsClientCapabilitiesTagSupport &&
+        other.runtimeType == PublishDiagnosticsClientCapabilitiesTagSupport) {
+      return listEqual(valueSet, other.valueSet,
+              (DiagnosticTag a, DiagnosticTag b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class PublishDiagnosticsParams implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       PublishDiagnosticsParams.canParse, PublishDiagnosticsParams.fromJson);
 
-  PublishDiagnosticsParams(this.uri, this.diagnostics) {
+  PublishDiagnosticsParams(
+      {@required this.uri, this.version, @required this.diagnostics}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -8711,11 +15526,13 @@
   }
   static PublishDiagnosticsParams fromJson(Map<String, dynamic> json) {
     final uri = json['uri'];
+    final version = json['version'];
     final diagnostics = json['diagnostics']
         ?.map((item) => item != null ? Diagnostic.fromJson(item) : null)
         ?.cast<Diagnostic>()
         ?.toList();
-    return PublishDiagnosticsParams(uri, diagnostics);
+    return PublishDiagnosticsParams(
+        uri: uri, version: version, diagnostics: diagnostics);
   }
 
   /// An array of diagnostic information items.
@@ -8724,9 +15541,17 @@
   /// The URI for which diagnostic information is reported.
   final String uri;
 
+  /// Optional the version number of the document the diagnostics are published
+  /// for.
+  ///  @since 3.15.0
+  final num version;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['uri'] = uri ?? (throw 'uri is required but was not set');
+    if (version != null) {
+      __result['version'] = version;
+    }
     __result['diagnostics'] =
         diagnostics ?? (throw 'diagnostics is required but was not set');
     return __result;
@@ -8751,6 +15576,15 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('version');
+      try {
+        if (obj['version'] != null && !(obj['version'] is num)) {
+          reporter.reportError('must be of type num');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('diagnostics');
       try {
         if (!obj.containsKey('diagnostics')) {
@@ -8782,6 +15616,7 @@
     if (other is PublishDiagnosticsParams &&
         other.runtimeType == PublishDiagnosticsParams) {
       return uri == other.uri &&
+          version == other.version &&
           listEqual(diagnostics, other.diagnostics,
               (Diagnostic a, Diagnostic b) => a == b) &&
           true;
@@ -8793,6 +15628,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, uri.hashCode);
+    hash = JenkinsSmiHash.combine(hash, version.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(diagnostics));
     return JenkinsSmiHash.finish(hash);
   }
@@ -8804,7 +15640,7 @@
 class Range implements ToJsonable {
   static const jsonHandler = LspJsonHandler(Range.canParse, Range.fromJson);
 
-  Range(this.start, this.end) {
+  Range({@required this.start, @required this.end}) {
     if (start == null) {
       throw 'start is required but was not provided';
     }
@@ -8816,7 +15652,7 @@
     final start =
         json['start'] != null ? Position.fromJson(json['start']) : null;
     final end = json['end'] != null ? Position.fromJson(json['end']) : null;
-    return Range(start, end);
+    return Range(start: start, end: end);
   }
 
   /// The range's end position.
@@ -8899,7 +15735,7 @@
   static const jsonHandler = LspJsonHandler(
       RangeAndPlaceholder.canParse, RangeAndPlaceholder.fromJson);
 
-  RangeAndPlaceholder(this.range, this.placeholder) {
+  RangeAndPlaceholder({@required this.range, @required this.placeholder}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -8910,7 +15746,7 @@
   static RangeAndPlaceholder fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final placeholder = json['placeholder'];
-    return RangeAndPlaceholder(range, placeholder);
+    return RangeAndPlaceholder(range: range, placeholder: placeholder);
   }
 
   final String placeholder;
@@ -8988,18 +15824,80 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class ReferenceClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ReferenceClientCapabilities.canParse,
+      ReferenceClientCapabilities.fromJson);
+
+  ReferenceClientCapabilities({this.dynamicRegistration});
+  static ReferenceClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return ReferenceClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether references supports dynamic registration.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ReferenceClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ReferenceClientCapabilities &&
+        other.runtimeType == ReferenceClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class ReferenceContext implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(ReferenceContext.canParse, ReferenceContext.fromJson);
 
-  ReferenceContext(this.includeDeclaration) {
+  ReferenceContext({@required this.includeDeclaration}) {
     if (includeDeclaration == null) {
       throw 'includeDeclaration is required but was not provided';
     }
   }
   static ReferenceContext fromJson(Map<String, dynamic> json) {
     final includeDeclaration = json['includeDeclaration'];
-    return ReferenceContext(includeDeclaration);
+    return ReferenceContext(includeDeclaration: includeDeclaration);
   }
 
   /// Include the declaration of the current symbol.
@@ -9057,11 +15955,82 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class ReferenceParams implements TextDocumentPositionParams, ToJsonable {
+class ReferenceOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(ReferenceOptions.canParse, ReferenceOptions.fromJson);
+
+  ReferenceOptions({this.workDoneProgress});
+  static ReferenceOptions fromJson(Map<String, dynamic> json) {
+    if (ReferenceRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ReferenceRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return ReferenceOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ReferenceOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ReferenceOptions && other.runtimeType == ReferenceOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ReferenceParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
   static const jsonHandler =
       LspJsonHandler(ReferenceParams.canParse, ReferenceParams.fromJson);
 
-  ReferenceParams(this.context, this.textDocument, this.position) {
+  ReferenceParams(
+      {@required this.context,
+      @required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
     if (context == null) {
       throw 'context is required but was not provided';
     }
@@ -9081,17 +16050,43 @@
         : null;
     final position =
         json['position'] != null ? Position.fromJson(json['position']) : null;
-    return ReferenceParams(context, textDocument, position);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return ReferenceParams(
+        context: context,
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
   final ReferenceContext context;
 
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
   /// The position inside the text document.
   final Position position;
 
   /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['context'] =
@@ -9100,6 +16095,12 @@
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['position'] =
         position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -9156,6 +16157,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type ReferenceParams');
@@ -9169,6 +16192,8 @@
       return context == other.context &&
           textDocument == other.textDocument &&
           position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
           true;
     }
     return false;
@@ -9180,6 +16205,98 @@
     hash = JenkinsSmiHash.combine(hash, context.hashCode);
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class ReferenceRegistrationOptions
+    implements TextDocumentRegistrationOptions, ReferenceOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      ReferenceRegistrationOptions.canParse,
+      ReferenceRegistrationOptions.fromJson);
+
+  ReferenceRegistrationOptions({this.documentSelector, this.workDoneProgress});
+  static ReferenceRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return ReferenceRegistrationOptions(
+        documentSelector: documentSelector, workDoneProgress: workDoneProgress);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type ReferenceRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is ReferenceRegistrationOptions &&
+        other.runtimeType == ReferenceRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -9192,7 +16309,8 @@
   static const jsonHandler =
       LspJsonHandler(Registration.canParse, Registration.fromJson);
 
-  Registration(this.id, this.method, this.registerOptions) {
+  Registration(
+      {@required this.id, @required this.method, this.registerOptions}) {
     if (id == null) {
       throw 'id is required but was not provided';
     }
@@ -9204,7 +16322,8 @@
     final id = json['id'];
     final method = json['method'];
     final registerOptions = json['registerOptions'];
-    return Registration(id, method, registerOptions);
+    return Registration(
+        id: id, method: method, registerOptions: registerOptions);
   }
 
   /// The id used to register the request. The id can be used to deregister the
@@ -9307,7 +16426,7 @@
   static const jsonHandler =
       LspJsonHandler(RegistrationParams.canParse, RegistrationParams.fromJson);
 
-  RegistrationParams(this.registrations) {
+  RegistrationParams({@required this.registrations}) {
     if (registrations == null) {
       throw 'registrations is required but was not provided';
     }
@@ -9317,7 +16436,7 @@
         ?.map((item) => item != null ? Registration.fromJson(item) : null)
         ?.cast<Registration>()
         ?.toList();
-    return RegistrationParams(registrations);
+    return RegistrationParams(registrations: registrations);
   }
 
   final List<Registration> registrations;
@@ -9379,12 +16498,99 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class RenameClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      RenameClientCapabilities.canParse, RenameClientCapabilities.fromJson);
+
+  RenameClientCapabilities({this.dynamicRegistration, this.prepareSupport});
+  static RenameClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final prepareSupport = json['prepareSupport'];
+    return RenameClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        prepareSupport: prepareSupport);
+  }
+
+  /// Whether rename supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// Client supports testing for validity of rename operations before
+  /// execution.
+  ///  @since version 3.12.0
+  final bool prepareSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (prepareSupport != null) {
+      __result['prepareSupport'] = prepareSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('prepareSupport');
+      try {
+        if (obj['prepareSupport'] != null && !(obj['prepareSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type RenameClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is RenameClientCapabilities &&
+        other.runtimeType == RenameClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          prepareSupport == other.prepareSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, prepareSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Rename file operation
 class RenameFile implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(RenameFile.canParse, RenameFile.fromJson);
 
-  RenameFile(this.kind, this.oldUri, this.newUri, this.options) {
+  RenameFile(
+      {@required this.kind,
+      @required this.oldUri,
+      @required this.newUri,
+      this.options}) {
     if (kind == null) {
       throw 'kind is required but was not provided';
     }
@@ -9402,7 +16608,8 @@
     final options = json['options'] != null
         ? RenameFileOptions.fromJson(json['options'])
         : null;
-    return RenameFile(kind, oldUri, newUri, options);
+    return RenameFile(
+        kind: kind, oldUri: oldUri, newUri: newUri, options: options);
   }
 
   /// A rename
@@ -9529,11 +16736,12 @@
   static const jsonHandler =
       LspJsonHandler(RenameFileOptions.canParse, RenameFileOptions.fromJson);
 
-  RenameFileOptions(this.overwrite, this.ignoreIfExists);
+  RenameFileOptions({this.overwrite, this.ignoreIfExists});
   static RenameFileOptions fromJson(Map<String, dynamic> json) {
     final overwrite = json['overwrite'];
     final ignoreIfExists = json['ignoreIfExists'];
-    return RenameFileOptions(overwrite, ignoreIfExists);
+    return RenameFileOptions(
+        overwrite: overwrite, ignoreIfExists: ignoreIfExists);
   }
 
   /// Ignores if target exists.
@@ -9602,25 +16810,33 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Rename options
-class RenameOptions implements ToJsonable {
+class RenameOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(RenameOptions.canParse, RenameOptions.fromJson);
 
-  RenameOptions(this.prepareProvider);
+  RenameOptions({this.prepareProvider, this.workDoneProgress});
   static RenameOptions fromJson(Map<String, dynamic> json) {
+    if (RenameRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return RenameRegistrationOptions.fromJson(json);
+    }
     final prepareProvider = json['prepareProvider'];
-    return RenameOptions(prepareProvider);
+    final workDoneProgress = json['workDoneProgress'];
+    return RenameOptions(
+        prepareProvider: prepareProvider, workDoneProgress: workDoneProgress);
   }
 
   /// Renames should be checked and tested before being executed.
   final bool prepareProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (prepareProvider != null) {
       __result['prepareProvider'] = prepareProvider;
     }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -9636,6 +16852,16 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type RenameOptions');
@@ -9646,7 +16872,9 @@
   @override
   bool operator ==(Object other) {
     if (other is RenameOptions && other.runtimeType == RenameOptions) {
-      return prepareProvider == other.prepareProvider && true;
+      return prepareProvider == other.prepareProvider &&
+          workDoneProgress == other.workDoneProgress &&
+          true;
     }
     return false;
   }
@@ -9655,6 +16883,7 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, prepareProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -9662,54 +16891,93 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class RenameParams implements ToJsonable {
+class RenameParams
+    implements TextDocumentPositionParams, WorkDoneProgressParams, ToJsonable {
   static const jsonHandler =
       LspJsonHandler(RenameParams.canParse, RenameParams.fromJson);
 
-  RenameParams(this.textDocument, this.position, this.newName) {
+  RenameParams(
+      {@required this.newName,
+      @required this.textDocument,
+      @required this.position,
+      this.workDoneToken}) {
+    if (newName == null) {
+      throw 'newName is required but was not provided';
+    }
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
     if (position == null) {
       throw 'position is required but was not provided';
     }
-    if (newName == null) {
-      throw 'newName is required but was not provided';
-    }
   }
   static RenameParams fromJson(Map<String, dynamic> json) {
+    final newName = json['newName'];
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final position =
         json['position'] != null ? Position.fromJson(json['position']) : null;
-    final newName = json['newName'];
-    return RenameParams(textDocument, position, newName);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return RenameParams(
+        newName: newName,
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken);
   }
 
   /// The new name of the symbol. If the given name is not valid the request
   /// must return a [ResponseError] with an appropriate message set.
   final String newName;
 
-  /// The position at which this request was sent.
+  /// The position inside the text document.
   final Position position;
 
-  /// The document to rename.
+  /// The text document.
   final TextDocumentIdentifier textDocument;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['newName'] =
+        newName ?? (throw 'newName is required but was not set');
     __result['textDocument'] =
         textDocument ?? (throw 'textDocument is required but was not set');
     __result['position'] =
         position ?? (throw 'position is required but was not set');
-    __result['newName'] =
-        newName ?? (throw 'newName is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
+      reporter.push('newName');
+      try {
+        if (!obj.containsKey('newName')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['newName'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['newName'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('textDocument');
       try {
         if (!obj.containsKey('textDocument')) {
@@ -9744,18 +17012,12 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('newName');
+      reporter.push('workDoneToken');
       try {
-        if (!obj.containsKey('newName')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['newName'] == null) {
-          reporter.reportError('must not be null');
-          return false;
-        }
-        if (!(obj['newName'] is String)) {
-          reporter.reportError('must be of type String');
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
           return false;
         }
       } finally {
@@ -9771,9 +17033,10 @@
   @override
   bool operator ==(Object other) {
     if (other is RenameParams && other.runtimeType == RenameParams) {
-      return textDocument == other.textDocument &&
+      return newName == other.newName &&
+          textDocument == other.textDocument &&
           position == other.position &&
-          newName == other.newName &&
+          workDoneToken == other.workDoneToken &&
           true;
     }
     return false;
@@ -9782,9 +17045,10 @@
   @override
   int get hashCode {
     var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, newName.hashCode);
     hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
     hash = JenkinsSmiHash.combine(hash, position.hashCode);
-    hash = JenkinsSmiHash.combine(hash, newName.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -9793,48 +17057,47 @@
 }
 
 class RenameRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements TextDocumentRegistrationOptions, RenameOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       RenameRegistrationOptions.canParse, RenameRegistrationOptions.fromJson);
 
-  RenameRegistrationOptions(this.prepareProvider, this.documentSelector);
+  RenameRegistrationOptions(
+      {this.documentSelector, this.prepareProvider, this.workDoneProgress});
   static RenameRegistrationOptions fromJson(Map<String, dynamic> json) {
-    final prepareProvider = json['prepareProvider'];
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return RenameRegistrationOptions(prepareProvider, documentSelector);
+    final prepareProvider = json['prepareProvider'];
+    final workDoneProgress = json['workDoneProgress'];
+    return RenameRegistrationOptions(
+        documentSelector: documentSelector,
+        prepareProvider: prepareProvider,
+        workDoneProgress: workDoneProgress);
   }
 
   /// A document selector to identify the scope of the registration. If set to
   /// null the document selector provided on the client side will be used.
   final List<DocumentFilter> documentSelector;
 
-  /// Renames should be checked and tested for validity before being executed.
+  /// Renames should be checked and tested before being executed.
   final bool prepareProvider;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     if (prepareProvider != null) {
       __result['prepareProvider'] = prepareProvider;
     }
-    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('prepareProvider');
-      try {
-        if (obj['prepareProvider'] != null &&
-            !(obj['prepareProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('documentSelector');
       try {
         if (!obj.containsKey('documentSelector')) {
@@ -9851,6 +17114,26 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('prepareProvider');
+      try {
+        if (obj['prepareProvider'] != null &&
+            !(obj['prepareProvider'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type RenameRegistrationOptions');
@@ -9862,9 +17145,10 @@
   bool operator ==(Object other) {
     if (other is RenameRegistrationOptions &&
         other.runtimeType == RenameRegistrationOptions) {
-      return prepareProvider == other.prepareProvider &&
-          listEqual(documentSelector, other.documentSelector,
+      return listEqual(documentSelector, other.documentSelector,
               (DocumentFilter a, DocumentFilter b) => a == b) &&
+          prepareProvider == other.prepareProvider &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -9873,8 +17157,9 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, prepareProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, prepareProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -9886,7 +17171,11 @@
   static const jsonHandler =
       LspJsonHandler(RequestMessage.canParse, RequestMessage.fromJson);
 
-  RequestMessage(this.id, this.method, this.params, this.jsonrpc) {
+  RequestMessage(
+      {@required this.id,
+      @required this.method,
+      this.params,
+      @required this.jsonrpc}) {
     if (id == null) {
       throw 'id is required but was not provided';
     }
@@ -9907,7 +17196,8 @@
         json['method'] != null ? Method.fromJson(json['method']) : null;
     final params = json['params'];
     final jsonrpc = json['jsonrpc'];
-    return RequestMessage(id, method, params, jsonrpc);
+    return RequestMessage(
+        id: id, method: method, params: params, jsonrpc: jsonrpc);
   }
 
   /// The request id.
@@ -10064,11 +17354,11 @@
       o is ResourceOperationKind && o._value == _value;
 }
 
-class ResponseError<D> implements ToJsonable {
+class ResponseError implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(ResponseError.canParse, ResponseError.fromJson);
 
-  ResponseError(this.code, this.message, this.data) {
+  ResponseError({@required this.code, @required this.message, this.data}) {
     if (code == null) {
       throw 'code is required but was not provided';
     }
@@ -10076,12 +17366,12 @@
       throw 'message is required but was not provided';
     }
   }
-  static ResponseError<D> fromJson<D>(Map<String, dynamic> json) {
+  static ResponseError fromJson(Map<String, dynamic> json) {
     final code =
         json['code'] != null ? ErrorCodes.fromJson(json['code']) : null;
     final message = json['message'];
     final data = json['data'];
-    return ResponseError<D>(code, message, data);
+    return ResponseError(code: code, message: message, data: data);
   }
 
   /// A number indicating the error type that occurred.
@@ -10152,7 +17442,7 @@
       }
       return true;
     } else {
-      reporter.reportError('must be of type ResponseError<D>');
+      reporter.reportError('must be of type ResponseError');
       return false;
     }
   }
@@ -10185,7 +17475,7 @@
   static const jsonHandler =
       LspJsonHandler(ResponseMessage.canParse, ResponseMessage.fromJson);
 
-  ResponseMessage(this.id, this.result, this.error, this.jsonrpc) {
+  ResponseMessage({this.id, this.result, this.error, @required this.jsonrpc}) {
     if (jsonrpc == null) {
       throw 'jsonrpc is required but was not provided';
     }
@@ -10199,15 +17489,15 @@
                 ? null
                 : (throw '''${json['id']} was not one of (num, String)''')));
     final result = json['result'];
-    final error = json['error'] != null
-        ? ResponseError.fromJson<dynamic>(json['error'])
-        : null;
+    final error =
+        json['error'] != null ? ResponseError.fromJson(json['error']) : null;
     final jsonrpc = json['jsonrpc'];
-    return ResponseMessage(id, result, error, jsonrpc);
+    return ResponseMessage(
+        id: id, result: result, error: error, jsonrpc: jsonrpc);
   }
 
   /// The error object in case a request fails.
-  final ResponseError<dynamic> error;
+  final ResponseError error;
 
   /// The request id.
   final Either2<num, String> id;
@@ -10260,7 +17550,7 @@
       try {
         if (obj['error'] != null &&
             !(ResponseError.canParse(obj['error'], reporter))) {
-          reporter.reportError('must be of type ResponseError<dynamic>');
+          reporter.reportError('must be of type ResponseError');
           return false;
         }
       } finally {
@@ -10316,15 +17606,14 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Save options.
 class SaveOptions implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(SaveOptions.canParse, SaveOptions.fromJson);
 
-  SaveOptions(this.includeText);
+  SaveOptions({this.includeText});
   static SaveOptions fromJson(Map<String, dynamic> json) {
     final includeText = json['includeText'];
-    return SaveOptions(includeText);
+    return SaveOptions(includeText: includeText);
   }
 
   /// The client is supposed to include the content on save.
@@ -10375,35 +17664,536 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class SelectionRange implements ToJsonable {
+  static const jsonHandler =
+      LspJsonHandler(SelectionRange.canParse, SelectionRange.fromJson);
+
+  SelectionRange({@required this.range, this.parent}) {
+    if (range == null) {
+      throw 'range is required but was not provided';
+    }
+  }
+  static SelectionRange fromJson(Map<String, dynamic> json) {
+    final range = json['range'] != null ? Range.fromJson(json['range']) : null;
+    final parent =
+        json['parent'] != null ? SelectionRange.fromJson(json['parent']) : null;
+    return SelectionRange(range: range, parent: parent);
+  }
+
+  /// The parent selection range containing this range. Therefore `parent.range`
+  /// must contain `this.range`.
+  final SelectionRange parent;
+
+  /// The range ([Range]) of this selection range.
+  final Range range;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['range'] = range ?? (throw 'range is required but was not set');
+    if (parent != null) {
+      __result['parent'] = parent;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('range');
+      try {
+        if (!obj.containsKey('range')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['range'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Range.canParse(obj['range'], reporter))) {
+          reporter.reportError('must be of type Range');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('parent');
+      try {
+        if (obj['parent'] != null &&
+            !(SelectionRange.canParse(obj['parent'], reporter))) {
+          reporter.reportError('must be of type SelectionRange');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SelectionRange');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SelectionRange && other.runtimeType == SelectionRange) {
+      return range == other.range && parent == other.parent && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, range.hashCode);
+    hash = JenkinsSmiHash.combine(hash, parent.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SelectionRangeClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SelectionRangeClientCapabilities.canParse,
+      SelectionRangeClientCapabilities.fromJson);
+
+  SelectionRangeClientCapabilities({this.dynamicRegistration});
+  static SelectionRangeClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    return SelectionRangeClientCapabilities(
+        dynamicRegistration: dynamicRegistration);
+  }
+
+  /// Whether implementation supports dynamic registration for selection range
+  /// providers. If this is set to `true` the client supports the new
+  /// `SelectionRangeRegistrationOptions` return value for the corresponding
+  /// server capability as well.
+  final bool dynamicRegistration;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SelectionRangeClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SelectionRangeClientCapabilities &&
+        other.runtimeType == SelectionRangeClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SelectionRangeOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SelectionRangeOptions.canParse, SelectionRangeOptions.fromJson);
+
+  SelectionRangeOptions({this.workDoneProgress});
+  static SelectionRangeOptions fromJson(Map<String, dynamic> json) {
+    if (SelectionRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return SelectionRangeOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SelectionRangeOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SelectionRangeOptions &&
+        other.runtimeType == SelectionRangeOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SelectionRangeParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SelectionRangeParams.canParse, SelectionRangeParams.fromJson);
+
+  SelectionRangeParams(
+      {@required this.textDocument,
+      @required this.positions,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (positions == null) {
+      throw 'positions is required but was not provided';
+    }
+  }
+  static SelectionRangeParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final positions = json['positions']
+        ?.map((item) => item != null ? Position.fromJson(item) : null)
+        ?.cast<Position>()
+        ?.toList();
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return SelectionRangeParams(
+        textDocument: textDocument,
+        positions: positions,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The positions inside the text document.
+  final List<Position> positions;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['positions'] =
+        positions ?? (throw 'positions is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('positions');
+      try {
+        if (!obj.containsKey('positions')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['positions'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['positions'] is List &&
+            (obj['positions']
+                .every((item) => Position.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<Position>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SelectionRangeParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SelectionRangeParams &&
+        other.runtimeType == SelectionRangeParams) {
+      return textDocument == other.textDocument &&
+          listEqual(
+              positions, other.positions, (Position a, Position b) => a == b) &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(positions));
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SelectionRangeRegistrationOptions
+    implements
+        SelectionRangeOptions,
+        TextDocumentRegistrationOptions,
+        StaticRegistrationOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SelectionRangeRegistrationOptions.canParse,
+      SelectionRangeRegistrationOptions.fromJson);
+
+  SelectionRangeRegistrationOptions(
+      {this.workDoneProgress, this.documentSelector, this.id});
+  static SelectionRangeRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final workDoneProgress = json['workDoneProgress'];
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final id = json['id'];
+    return SelectionRangeRegistrationOptions(
+        workDoneProgress: workDoneProgress,
+        documentSelector: documentSelector,
+        id: id);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    __result['documentSelector'] = documentSelector;
+    if (id != null) {
+      __result['id'] = id;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SelectionRangeRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SelectionRangeRegistrationOptions &&
+        other.runtimeType == SelectionRangeRegistrationOptions) {
+      return workDoneProgress == other.workDoneProgress &&
+          listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          id == other.id &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class ServerCapabilities implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(ServerCapabilities.canParse, ServerCapabilities.fromJson);
 
   ServerCapabilities(
-      this.textDocumentSync,
-      this.hoverProvider,
+      {this.textDocumentSync,
       this.completionProvider,
+      this.hoverProvider,
       this.signatureHelpProvider,
+      this.declarationProvider,
       this.definitionProvider,
       this.typeDefinitionProvider,
       this.implementationProvider,
       this.referencesProvider,
       this.documentHighlightProvider,
       this.documentSymbolProvider,
-      this.workspaceSymbolProvider,
       this.codeActionProvider,
       this.codeLensProvider,
+      this.documentLinkProvider,
+      this.colorProvider,
       this.documentFormattingProvider,
       this.documentRangeFormattingProvider,
       this.documentOnTypeFormattingProvider,
       this.renameProvider,
-      this.documentLinkProvider,
-      this.colorProvider,
       this.foldingRangeProvider,
-      this.declarationProvider,
       this.executeCommandProvider,
+      this.selectionRangeProvider,
+      this.workspaceSymbolProvider,
       this.workspace,
-      this.experimental);
+      this.experimental});
   static ServerCapabilities fromJson(Map<String, dynamic> json) {
     final textDocumentSync = TextDocumentSyncOptions.canParse(
             json['textDocumentSync'], nullLspJsonReporter)
@@ -10416,20 +18206,124 @@
             : (json['textDocumentSync'] == null
                 ? null
                 : (throw '''${json['textDocumentSync']} was not one of (TextDocumentSyncOptions, num)''')));
-    final hoverProvider = json['hoverProvider'];
     final completionProvider = json['completionProvider'] != null
         ? CompletionOptions.fromJson(json['completionProvider'])
         : null;
+    final hoverProvider = json['hoverProvider'] is bool
+        ? Either2<bool, HoverOptions>.t1(json['hoverProvider'])
+        : (HoverOptions.canParse(json['hoverProvider'], nullLspJsonReporter)
+            ? Either2<bool, HoverOptions>.t2(json['hoverProvider'] != null
+                ? HoverOptions.fromJson(json['hoverProvider'])
+                : null)
+            : (json['hoverProvider'] == null
+                ? null
+                : (throw '''${json['hoverProvider']} was not one of (bool, HoverOptions)''')));
     final signatureHelpProvider = json['signatureHelpProvider'] != null
         ? SignatureHelpOptions.fromJson(json['signatureHelpProvider'])
         : null;
-    final definitionProvider = json['definitionProvider'];
-    final typeDefinitionProvider = json['typeDefinitionProvider'];
-    final implementationProvider = json['implementationProvider'];
-    final referencesProvider = json['referencesProvider'];
-    final documentHighlightProvider = json['documentHighlightProvider'];
-    final documentSymbolProvider = json['documentSymbolProvider'];
-    final workspaceSymbolProvider = json['workspaceSymbolProvider'];
+    final declarationProvider = json['declarationProvider'] is bool
+        ? Either3<bool, DeclarationOptions, DeclarationRegistrationOptions>.t1(
+            json['declarationProvider'])
+        : (DeclarationOptions.canParse(
+                json['declarationProvider'], nullLspJsonReporter)
+            ? Either3<bool, DeclarationOptions, DeclarationRegistrationOptions>.t2(
+                json['declarationProvider'] != null
+                    ? DeclarationOptions.fromJson(json['declarationProvider'])
+                    : null)
+            : (DeclarationRegistrationOptions.canParse(
+                    json['declarationProvider'], nullLspJsonReporter)
+                ? Either3<bool, DeclarationOptions, DeclarationRegistrationOptions>.t3(
+                    json['declarationProvider'] != null
+                        ? DeclarationRegistrationOptions.fromJson(
+                            json['declarationProvider'])
+                        : null)
+                : (json['declarationProvider'] == null
+                    ? null
+                    : (throw '''${json['declarationProvider']} was not one of (bool, DeclarationOptions, DeclarationRegistrationOptions)'''))));
+    final definitionProvider = json['definitionProvider'] is bool
+        ? Either2<bool, DefinitionOptions>.t1(json['definitionProvider'])
+        : (DefinitionOptions.canParse(
+                json['definitionProvider'], nullLspJsonReporter)
+            ? Either2<bool, DefinitionOptions>.t2(
+                json['definitionProvider'] != null
+                    ? DefinitionOptions.fromJson(json['definitionProvider'])
+                    : null)
+            : (json['definitionProvider'] == null
+                ? null
+                : (throw '''${json['definitionProvider']} was not one of (bool, DefinitionOptions)''')));
+    final typeDefinitionProvider = json['typeDefinitionProvider'] is bool
+        ? Either3<bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions>.t1(
+            json['typeDefinitionProvider'])
+        : (TypeDefinitionOptions.canParse(
+                json['typeDefinitionProvider'], nullLspJsonReporter)
+            ? Either3<bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions>.t2(json['typeDefinitionProvider'] != null
+                ? TypeDefinitionOptions.fromJson(json['typeDefinitionProvider'])
+                : null)
+            : (TypeDefinitionRegistrationOptions.canParse(
+                    json['typeDefinitionProvider'], nullLspJsonReporter)
+                ? Either3<bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions>.t3(
+                    json['typeDefinitionProvider'] != null
+                        ? TypeDefinitionRegistrationOptions.fromJson(
+                            json['typeDefinitionProvider'])
+                        : null)
+                : (json['typeDefinitionProvider'] == null
+                    ? null
+                    : (throw '''${json['typeDefinitionProvider']} was not one of (bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions)'''))));
+    final implementationProvider = json['implementationProvider'] is bool
+        ? Either3<bool, ImplementationOptions, ImplementationRegistrationOptions>.t1(
+            json['implementationProvider'])
+        : (ImplementationOptions.canParse(
+                json['implementationProvider'], nullLspJsonReporter)
+            ? Either3<bool, ImplementationOptions, ImplementationRegistrationOptions>.t2(json['implementationProvider'] != null
+                ? ImplementationOptions.fromJson(json['implementationProvider'])
+                : null)
+            : (ImplementationRegistrationOptions.canParse(
+                    json['implementationProvider'], nullLspJsonReporter)
+                ? Either3<bool, ImplementationOptions, ImplementationRegistrationOptions>.t3(
+                    json['implementationProvider'] != null
+                        ? ImplementationRegistrationOptions.fromJson(
+                            json['implementationProvider'])
+                        : null)
+                : (json['implementationProvider'] == null
+                    ? null
+                    : (throw '''${json['implementationProvider']} was not one of (bool, ImplementationOptions, ImplementationRegistrationOptions)'''))));
+    final referencesProvider = json['referencesProvider'] is bool
+        ? Either2<bool, ReferenceOptions>.t1(json['referencesProvider'])
+        : (ReferenceOptions.canParse(
+                json['referencesProvider'], nullLspJsonReporter)
+            ? Either2<bool, ReferenceOptions>.t2(
+                json['referencesProvider'] != null
+                    ? ReferenceOptions.fromJson(json['referencesProvider'])
+                    : null)
+            : (json['referencesProvider'] == null
+                ? null
+                : (throw '''${json['referencesProvider']} was not one of (bool, ReferenceOptions)''')));
+    final documentHighlightProvider = json['documentHighlightProvider'] is bool
+        ? Either2<bool, DocumentHighlightOptions>.t1(
+            json['documentHighlightProvider'])
+        : (DocumentHighlightOptions.canParse(
+                json['documentHighlightProvider'], nullLspJsonReporter)
+            ? Either2<bool, DocumentHighlightOptions>.t2(
+                json['documentHighlightProvider'] != null
+                    ? DocumentHighlightOptions.fromJson(
+                        json['documentHighlightProvider'])
+                    : null)
+            : (json['documentHighlightProvider'] == null
+                ? null
+                : (throw '''${json['documentHighlightProvider']} was not one of (bool, DocumentHighlightOptions)''')));
+    final documentSymbolProvider = json['documentSymbolProvider'] is bool
+        ? Either2<bool, DocumentSymbolOptions>.t1(
+            json['documentSymbolProvider'])
+        : (DocumentSymbolOptions.canParse(
+                json['documentSymbolProvider'], nullLspJsonReporter)
+            ? Either2<bool, DocumentSymbolOptions>.t2(
+                json['documentSymbolProvider'] != null
+                    ? DocumentSymbolOptions.fromJson(
+                        json['documentSymbolProvider'])
+                    : null)
+            : (json['documentSymbolProvider'] == null
+                ? null
+                : (throw '''${json['documentSymbolProvider']} was not one of (bool, DocumentSymbolOptions)''')));
     final codeActionProvider = json['codeActionProvider'] is bool
         ? Either2<bool, CodeActionOptions>.t1(json['codeActionProvider'])
         : (CodeActionOptions.canParse(
@@ -10444,9 +18338,56 @@
     final codeLensProvider = json['codeLensProvider'] != null
         ? CodeLensOptions.fromJson(json['codeLensProvider'])
         : null;
-    final documentFormattingProvider = json['documentFormattingProvider'];
-    final documentRangeFormattingProvider =
-        json['documentRangeFormattingProvider'];
+    final documentLinkProvider = json['documentLinkProvider'] != null
+        ? DocumentLinkOptions.fromJson(json['documentLinkProvider'])
+        : null;
+    final colorProvider = json['colorProvider'] is bool
+        ? Either3<bool, DocumentColorOptions, DocumentColorRegistrationOptions>.t1(
+            json['colorProvider'])
+        : (DocumentColorOptions.canParse(
+                json['colorProvider'], nullLspJsonReporter)
+            ? Either3<bool, DocumentColorOptions, DocumentColorRegistrationOptions>.t2(
+                json['colorProvider'] != null
+                    ? DocumentColorOptions.fromJson(json['colorProvider'])
+                    : null)
+            : (DocumentColorRegistrationOptions.canParse(
+                    json['colorProvider'], nullLspJsonReporter)
+                ? Either3<bool, DocumentColorOptions, DocumentColorRegistrationOptions>.t3(
+                    json['colorProvider'] != null
+                        ? DocumentColorRegistrationOptions.fromJson(
+                            json['colorProvider'])
+                        : null)
+                : (json['colorProvider'] == null
+                    ? null
+                    : (throw '''${json['colorProvider']} was not one of (bool, DocumentColorOptions, DocumentColorRegistrationOptions)'''))));
+    final documentFormattingProvider = json['documentFormattingProvider']
+            is bool
+        ? Either2<bool, DocumentFormattingOptions>.t1(
+            json['documentFormattingProvider'])
+        : (DocumentFormattingOptions.canParse(
+                json['documentFormattingProvider'], nullLspJsonReporter)
+            ? Either2<bool, DocumentFormattingOptions>.t2(
+                json['documentFormattingProvider'] != null
+                    ? DocumentFormattingOptions.fromJson(
+                        json['documentFormattingProvider'])
+                    : null)
+            : (json['documentFormattingProvider'] == null
+                ? null
+                : (throw '''${json['documentFormattingProvider']} was not one of (bool, DocumentFormattingOptions)''')));
+    final documentRangeFormattingProvider = json[
+            'documentRangeFormattingProvider'] is bool
+        ? Either2<bool, DocumentRangeFormattingOptions>.t1(
+            json['documentRangeFormattingProvider'])
+        : (DocumentRangeFormattingOptions.canParse(
+                json['documentRangeFormattingProvider'], nullLspJsonReporter)
+            ? Either2<bool, DocumentRangeFormattingOptions>.t2(
+                json['documentRangeFormattingProvider'] != null
+                    ? DocumentRangeFormattingOptions.fromJson(
+                        json['documentRangeFormattingProvider'])
+                    : null)
+            : (json['documentRangeFormattingProvider'] == null
+                ? null
+                : (throw '''${json['documentRangeFormattingProvider']} was not one of (bool, DocumentRangeFormattingOptions)''')));
     final documentOnTypeFormattingProvider =
         json['documentOnTypeFormattingProvider'] != null
             ? DocumentOnTypeFormattingOptions.fromJson(
@@ -10461,44 +18402,77 @@
             : (json['renameProvider'] == null
                 ? null
                 : (throw '''${json['renameProvider']} was not one of (bool, RenameOptions)''')));
-    final documentLinkProvider = json['documentLinkProvider'] != null
-        ? DocumentLinkOptions.fromJson(json['documentLinkProvider'])
-        : null;
-    final colorProvider = json['colorProvider'];
-    final foldingRangeProvider = json['foldingRangeProvider'];
-    final declarationProvider = json['declarationProvider'];
+    final foldingRangeProvider = json['foldingRangeProvider'] is bool
+        ? Either3<bool, FoldingRangeOptions, FoldingRangeRegistrationOptions>.t1(
+            json['foldingRangeProvider'])
+        : (FoldingRangeOptions.canParse(
+                json['foldingRangeProvider'], nullLspJsonReporter)
+            ? Either3<bool, FoldingRangeOptions, FoldingRangeRegistrationOptions>.t2(
+                json['foldingRangeProvider'] != null
+                    ? FoldingRangeOptions.fromJson(json['foldingRangeProvider'])
+                    : null)
+            : (FoldingRangeRegistrationOptions.canParse(
+                    json['foldingRangeProvider'], nullLspJsonReporter)
+                ? Either3<bool, FoldingRangeOptions, FoldingRangeRegistrationOptions>.t3(
+                    json['foldingRangeProvider'] != null
+                        ? FoldingRangeRegistrationOptions.fromJson(
+                            json['foldingRangeProvider'])
+                        : null)
+                : (json['foldingRangeProvider'] == null
+                    ? null
+                    : (throw '''${json['foldingRangeProvider']} was not one of (bool, FoldingRangeOptions, FoldingRangeRegistrationOptions)'''))));
     final executeCommandProvider = json['executeCommandProvider'] != null
         ? ExecuteCommandOptions.fromJson(json['executeCommandProvider'])
         : null;
+    final selectionRangeProvider = json['selectionRangeProvider'] is bool
+        ? Either3<bool, SelectionRangeOptions, SelectionRangeRegistrationOptions>.t1(
+            json['selectionRangeProvider'])
+        : (SelectionRangeOptions.canParse(
+                json['selectionRangeProvider'], nullLspJsonReporter)
+            ? Either3<bool, SelectionRangeOptions, SelectionRangeRegistrationOptions>.t2(json['selectionRangeProvider'] != null
+                ? SelectionRangeOptions.fromJson(json['selectionRangeProvider'])
+                : null)
+            : (SelectionRangeRegistrationOptions.canParse(
+                    json['selectionRangeProvider'], nullLspJsonReporter)
+                ? Either3<bool, SelectionRangeOptions, SelectionRangeRegistrationOptions>.t3(
+                    json['selectionRangeProvider'] != null
+                        ? SelectionRangeRegistrationOptions.fromJson(
+                            json['selectionRangeProvider'])
+                        : null)
+                : (json['selectionRangeProvider'] == null
+                    ? null
+                    : (throw '''${json['selectionRangeProvider']} was not one of (bool, SelectionRangeOptions, SelectionRangeRegistrationOptions)'''))));
+    final workspaceSymbolProvider = json['workspaceSymbolProvider'];
     final workspace = json['workspace'] != null
         ? ServerCapabilitiesWorkspace.fromJson(json['workspace'])
         : null;
     final experimental = json['experimental'];
     return ServerCapabilities(
-        textDocumentSync,
-        hoverProvider,
-        completionProvider,
-        signatureHelpProvider,
-        definitionProvider,
-        typeDefinitionProvider,
-        implementationProvider,
-        referencesProvider,
-        documentHighlightProvider,
-        documentSymbolProvider,
-        workspaceSymbolProvider,
-        codeActionProvider,
-        codeLensProvider,
-        documentFormattingProvider,
-        documentRangeFormattingProvider,
-        documentOnTypeFormattingProvider,
-        renameProvider,
-        documentLinkProvider,
-        colorProvider,
-        foldingRangeProvider,
-        declarationProvider,
-        executeCommandProvider,
-        workspace,
-        experimental);
+        textDocumentSync: textDocumentSync,
+        completionProvider: completionProvider,
+        hoverProvider: hoverProvider,
+        signatureHelpProvider: signatureHelpProvider,
+        declarationProvider: declarationProvider,
+        definitionProvider: definitionProvider,
+        typeDefinitionProvider: typeDefinitionProvider,
+        implementationProvider: implementationProvider,
+        referencesProvider: referencesProvider,
+        documentHighlightProvider: documentHighlightProvider,
+        documentSymbolProvider: documentSymbolProvider,
+        codeActionProvider: codeActionProvider,
+        codeLensProvider: codeLensProvider,
+        documentLinkProvider: documentLinkProvider,
+        colorProvider: colorProvider,
+        documentFormattingProvider: documentFormattingProvider,
+        documentRangeFormattingProvider: documentRangeFormattingProvider,
+        documentOnTypeFormattingProvider: documentOnTypeFormattingProvider,
+        renameProvider: renameProvider,
+        foldingRangeProvider: foldingRangeProvider,
+        executeCommandProvider: executeCommandProvider,
+        selectionRangeProvider: selectionRangeProvider,
+        workspaceSymbolProvider: workspaceSymbolProvider,
+        workspace: workspace,
+        experimental: experimental);
   }
 
   /// The server provides code actions. The `CodeActionOptions` return type is
@@ -10510,26 +18484,26 @@
   final CodeLensOptions codeLensProvider;
 
   /// The server provides color provider support.
-  ///
-  /// Since 3.6.0
-  final dynamic colorProvider;
+  ///  @since 3.6.0
+  final Either3<bool, DocumentColorOptions, DocumentColorRegistrationOptions>
+      colorProvider;
 
   /// The server provides completion support.
   final CompletionOptions completionProvider;
 
   /// The server provides go to declaration support.
-  ///
-  /// Since 3.14.0
-  final dynamic declarationProvider;
+  ///  @since 3.14.0
+  final Either3<bool, DeclarationOptions, DeclarationRegistrationOptions>
+      declarationProvider;
 
   /// The server provides goto definition support.
-  final bool definitionProvider;
+  final Either2<bool, DefinitionOptions> definitionProvider;
 
   /// The server provides document formatting.
-  final bool documentFormattingProvider;
+  final Either2<bool, DocumentFormattingOptions> documentFormattingProvider;
 
   /// The server provides document highlight support.
-  final bool documentHighlightProvider;
+  final Either2<bool, DocumentHighlightOptions> documentHighlightProvider;
 
   /// The server provides document link support.
   final DocumentLinkOptions documentLinkProvider;
@@ -10538,10 +18512,11 @@
   final DocumentOnTypeFormattingOptions documentOnTypeFormattingProvider;
 
   /// The server provides document range formatting.
-  final bool documentRangeFormattingProvider;
+  final Either2<bool, DocumentRangeFormattingOptions>
+      documentRangeFormattingProvider;
 
   /// The server provides document symbol support.
-  final bool documentSymbolProvider;
+  final Either2<bool, DocumentSymbolOptions> documentSymbolProvider;
 
   /// The server provides execute command support.
   final ExecuteCommandOptions executeCommandProvider;
@@ -10550,26 +18525,31 @@
   final dynamic experimental;
 
   /// The server provides folding provider support.
-  ///
-  /// Since 3.10.0
-  final dynamic foldingRangeProvider;
+  ///  @since 3.10.0
+  final Either3<bool, FoldingRangeOptions, FoldingRangeRegistrationOptions>
+      foldingRangeProvider;
 
   /// The server provides hover support.
-  final bool hoverProvider;
+  final Either2<bool, HoverOptions> hoverProvider;
 
-  /// The server provides Goto Implementation support.
-  ///
-  /// Since 3.6.0
-  final dynamic implementationProvider;
+  /// The server provides goto implementation support.
+  ///  @since 3.6.0
+  final Either3<bool, ImplementationOptions, ImplementationRegistrationOptions>
+      implementationProvider;
 
   /// The server provides find references support.
-  final bool referencesProvider;
+  final Either2<bool, ReferenceOptions> referencesProvider;
 
   /// The server provides rename support. RenameOptions may only be specified if
   /// the client states that it supports `prepareSupport` in its initial
   /// `initialize` request.
   final Either2<bool, RenameOptions> renameProvider;
 
+  /// The server provides selection range support.
+  ///  @since 3.15.0
+  final Either3<bool, SelectionRangeOptions, SelectionRangeRegistrationOptions>
+      selectionRangeProvider;
+
   /// The server provides signature help support.
   final SignatureHelpOptions signatureHelpProvider;
 
@@ -10579,10 +18559,10 @@
   /// `TextDocumentSyncKind.None`.
   final Either2<TextDocumentSyncOptions, num> textDocumentSync;
 
-  /// The server provides Goto Type Definition support.
-  ///
-  /// Since 3.6.0
-  final dynamic typeDefinitionProvider;
+  /// The server provides goto type definition support.
+  ///  @since 3.6.0
+  final Either3<bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions>
+      typeDefinitionProvider;
 
   /// Workspace specific server capabilities
   final ServerCapabilitiesWorkspace workspace;
@@ -10595,15 +18575,18 @@
     if (textDocumentSync != null) {
       __result['textDocumentSync'] = textDocumentSync;
     }
-    if (hoverProvider != null) {
-      __result['hoverProvider'] = hoverProvider;
-    }
     if (completionProvider != null) {
       __result['completionProvider'] = completionProvider;
     }
+    if (hoverProvider != null) {
+      __result['hoverProvider'] = hoverProvider;
+    }
     if (signatureHelpProvider != null) {
       __result['signatureHelpProvider'] = signatureHelpProvider;
     }
+    if (declarationProvider != null) {
+      __result['declarationProvider'] = declarationProvider;
+    }
     if (definitionProvider != null) {
       __result['definitionProvider'] = definitionProvider;
     }
@@ -10622,15 +18605,18 @@
     if (documentSymbolProvider != null) {
       __result['documentSymbolProvider'] = documentSymbolProvider;
     }
-    if (workspaceSymbolProvider != null) {
-      __result['workspaceSymbolProvider'] = workspaceSymbolProvider;
-    }
     if (codeActionProvider != null) {
       __result['codeActionProvider'] = codeActionProvider;
     }
     if (codeLensProvider != null) {
       __result['codeLensProvider'] = codeLensProvider;
     }
+    if (documentLinkProvider != null) {
+      __result['documentLinkProvider'] = documentLinkProvider;
+    }
+    if (colorProvider != null) {
+      __result['colorProvider'] = colorProvider;
+    }
     if (documentFormattingProvider != null) {
       __result['documentFormattingProvider'] = documentFormattingProvider;
     }
@@ -10645,21 +18631,18 @@
     if (renameProvider != null) {
       __result['renameProvider'] = renameProvider;
     }
-    if (documentLinkProvider != null) {
-      __result['documentLinkProvider'] = documentLinkProvider;
-    }
-    if (colorProvider != null) {
-      __result['colorProvider'] = colorProvider;
-    }
     if (foldingRangeProvider != null) {
       __result['foldingRangeProvider'] = foldingRangeProvider;
     }
-    if (declarationProvider != null) {
-      __result['declarationProvider'] = declarationProvider;
-    }
     if (executeCommandProvider != null) {
       __result['executeCommandProvider'] = executeCommandProvider;
     }
+    if (selectionRangeProvider != null) {
+      __result['selectionRangeProvider'] = selectionRangeProvider;
+    }
+    if (workspaceSymbolProvider != null) {
+      __result['workspaceSymbolProvider'] = workspaceSymbolProvider;
+    }
     if (workspace != null) {
       __result['workspace'] = workspace;
     }
@@ -10684,15 +18667,6 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('hoverProvider');
-      try {
-        if (obj['hoverProvider'] != null && !(obj['hoverProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('completionProvider');
       try {
         if (obj['completionProvider'] != null &&
@@ -10704,6 +18678,17 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('hoverProvider');
+      try {
+        if (obj['hoverProvider'] != null &&
+            !((obj['hoverProvider'] is bool ||
+                HoverOptions.canParse(obj['hoverProvider'], reporter)))) {
+          reporter.reportError('must be of type Either2<bool, HoverOptions>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('signatureHelpProvider');
       try {
         if (obj['signatureHelpProvider'] != null &&
@@ -10715,11 +18700,29 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('declarationProvider');
+      try {
+        if (obj['declarationProvider'] != null &&
+            !((obj['declarationProvider'] is bool ||
+                DeclarationOptions.canParse(
+                    obj['declarationProvider'], reporter) ||
+                DeclarationRegistrationOptions.canParse(
+                    obj['declarationProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, DeclarationOptions, DeclarationRegistrationOptions>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('definitionProvider');
       try {
         if (obj['definitionProvider'] != null &&
-            !(obj['definitionProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['definitionProvider'] is bool ||
+                DefinitionOptions.canParse(
+                    obj['definitionProvider'], reporter)))) {
+          reporter
+              .reportError('must be of type Either2<bool, DefinitionOptions>');
           return false;
         }
       } finally {
@@ -10727,8 +18730,14 @@
       }
       reporter.push('typeDefinitionProvider');
       try {
-        if (obj['typeDefinitionProvider'] != null && !(true)) {
-          reporter.reportError('must be of type dynamic');
+        if (obj['typeDefinitionProvider'] != null &&
+            !((obj['typeDefinitionProvider'] is bool ||
+                TypeDefinitionOptions.canParse(
+                    obj['typeDefinitionProvider'], reporter) ||
+                TypeDefinitionRegistrationOptions.canParse(
+                    obj['typeDefinitionProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, TypeDefinitionOptions, TypeDefinitionRegistrationOptions>');
           return false;
         }
       } finally {
@@ -10736,8 +18745,14 @@
       }
       reporter.push('implementationProvider');
       try {
-        if (obj['implementationProvider'] != null && !(true)) {
-          reporter.reportError('must be of type dynamic');
+        if (obj['implementationProvider'] != null &&
+            !((obj['implementationProvider'] is bool ||
+                ImplementationOptions.canParse(
+                    obj['implementationProvider'], reporter) ||
+                ImplementationRegistrationOptions.canParse(
+                    obj['implementationProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, ImplementationOptions, ImplementationRegistrationOptions>');
           return false;
         }
       } finally {
@@ -10746,8 +18761,11 @@
       reporter.push('referencesProvider');
       try {
         if (obj['referencesProvider'] != null &&
-            !(obj['referencesProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['referencesProvider'] is bool ||
+                ReferenceOptions.canParse(
+                    obj['referencesProvider'], reporter)))) {
+          reporter
+              .reportError('must be of type Either2<bool, ReferenceOptions>');
           return false;
         }
       } finally {
@@ -10756,8 +18774,11 @@
       reporter.push('documentHighlightProvider');
       try {
         if (obj['documentHighlightProvider'] != null &&
-            !(obj['documentHighlightProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['documentHighlightProvider'] is bool ||
+                DocumentHighlightOptions.canParse(
+                    obj['documentHighlightProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either2<bool, DocumentHighlightOptions>');
           return false;
         }
       } finally {
@@ -10766,18 +18787,11 @@
       reporter.push('documentSymbolProvider');
       try {
         if (obj['documentSymbolProvider'] != null &&
-            !(obj['documentSymbolProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('workspaceSymbolProvider');
-      try {
-        if (obj['workspaceSymbolProvider'] != null &&
-            !(obj['workspaceSymbolProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['documentSymbolProvider'] is bool ||
+                DocumentSymbolOptions.canParse(
+                    obj['documentSymbolProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either2<bool, DocumentSymbolOptions>');
           return false;
         }
       } finally {
@@ -10806,11 +18820,39 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('documentLinkProvider');
+      try {
+        if (obj['documentLinkProvider'] != null &&
+            !(DocumentLinkOptions.canParse(
+                obj['documentLinkProvider'], reporter))) {
+          reporter.reportError('must be of type DocumentLinkOptions');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('colorProvider');
+      try {
+        if (obj['colorProvider'] != null &&
+            !((obj['colorProvider'] is bool ||
+                DocumentColorOptions.canParse(obj['colorProvider'], reporter) ||
+                DocumentColorRegistrationOptions.canParse(
+                    obj['colorProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, DocumentColorOptions, DocumentColorRegistrationOptions>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('documentFormattingProvider');
       try {
         if (obj['documentFormattingProvider'] != null &&
-            !(obj['documentFormattingProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['documentFormattingProvider'] is bool ||
+                DocumentFormattingOptions.canParse(
+                    obj['documentFormattingProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either2<bool, DocumentFormattingOptions>');
           return false;
         }
       } finally {
@@ -10819,8 +18861,11 @@
       reporter.push('documentRangeFormattingProvider');
       try {
         if (obj['documentRangeFormattingProvider'] != null &&
-            !(obj['documentRangeFormattingProvider'] is bool)) {
-          reporter.reportError('must be of type bool');
+            !((obj['documentRangeFormattingProvider'] is bool ||
+                DocumentRangeFormattingOptions.canParse(
+                    obj['documentRangeFormattingProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either2<bool, DocumentRangeFormattingOptions>');
           return false;
         }
       } finally {
@@ -10849,39 +18894,16 @@
       } finally {
         reporter.pop();
       }
-      reporter.push('documentLinkProvider');
-      try {
-        if (obj['documentLinkProvider'] != null &&
-            !(DocumentLinkOptions.canParse(
-                obj['documentLinkProvider'], reporter))) {
-          reporter.reportError('must be of type DocumentLinkOptions');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('colorProvider');
-      try {
-        if (obj['colorProvider'] != null && !(true)) {
-          reporter.reportError('must be of type dynamic');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('foldingRangeProvider');
       try {
-        if (obj['foldingRangeProvider'] != null && !(true)) {
-          reporter.reportError('must be of type dynamic');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('declarationProvider');
-      try {
-        if (obj['declarationProvider'] != null && !(true)) {
-          reporter.reportError('must be of type dynamic');
+        if (obj['foldingRangeProvider'] != null &&
+            !((obj['foldingRangeProvider'] is bool ||
+                FoldingRangeOptions.canParse(
+                    obj['foldingRangeProvider'], reporter) ||
+                FoldingRangeRegistrationOptions.canParse(
+                    obj['foldingRangeProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, FoldingRangeOptions, FoldingRangeRegistrationOptions>');
           return false;
         }
       } finally {
@@ -10898,6 +18920,31 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('selectionRangeProvider');
+      try {
+        if (obj['selectionRangeProvider'] != null &&
+            !((obj['selectionRangeProvider'] is bool ||
+                SelectionRangeOptions.canParse(
+                    obj['selectionRangeProvider'], reporter) ||
+                SelectionRangeRegistrationOptions.canParse(
+                    obj['selectionRangeProvider'], reporter)))) {
+          reporter.reportError(
+              'must be of type Either3<bool, SelectionRangeOptions, SelectionRangeRegistrationOptions>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workspaceSymbolProvider');
+      try {
+        if (obj['workspaceSymbolProvider'] != null &&
+            !(obj['workspaceSymbolProvider'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       reporter.push('workspace');
       try {
         if (obj['workspace'] != null &&
@@ -10930,29 +18977,30 @@
     if (other is ServerCapabilities &&
         other.runtimeType == ServerCapabilities) {
       return textDocumentSync == other.textDocumentSync &&
-          hoverProvider == other.hoverProvider &&
           completionProvider == other.completionProvider &&
+          hoverProvider == other.hoverProvider &&
           signatureHelpProvider == other.signatureHelpProvider &&
+          declarationProvider == other.declarationProvider &&
           definitionProvider == other.definitionProvider &&
           typeDefinitionProvider == other.typeDefinitionProvider &&
           implementationProvider == other.implementationProvider &&
           referencesProvider == other.referencesProvider &&
           documentHighlightProvider == other.documentHighlightProvider &&
           documentSymbolProvider == other.documentSymbolProvider &&
-          workspaceSymbolProvider == other.workspaceSymbolProvider &&
           codeActionProvider == other.codeActionProvider &&
           codeLensProvider == other.codeLensProvider &&
+          documentLinkProvider == other.documentLinkProvider &&
+          colorProvider == other.colorProvider &&
           documentFormattingProvider == other.documentFormattingProvider &&
           documentRangeFormattingProvider ==
               other.documentRangeFormattingProvider &&
           documentOnTypeFormattingProvider ==
               other.documentOnTypeFormattingProvider &&
           renameProvider == other.renameProvider &&
-          documentLinkProvider == other.documentLinkProvider &&
-          colorProvider == other.colorProvider &&
           foldingRangeProvider == other.foldingRangeProvider &&
-          declarationProvider == other.declarationProvider &&
           executeCommandProvider == other.executeCommandProvider &&
+          selectionRangeProvider == other.selectionRangeProvider &&
+          workspaceSymbolProvider == other.workspaceSymbolProvider &&
           workspace == other.workspace &&
           experimental == other.experimental &&
           true;
@@ -10964,29 +19012,30 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, textDocumentSync.hashCode);
-    hash = JenkinsSmiHash.combine(hash, hoverProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, completionProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, hoverProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, signatureHelpProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, declarationProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, definitionProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, typeDefinitionProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, implementationProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, referencesProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, documentHighlightProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, documentSymbolProvider.hashCode);
-    hash = JenkinsSmiHash.combine(hash, workspaceSymbolProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, codeActionProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, codeLensProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, documentLinkProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, colorProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, documentFormattingProvider.hashCode);
     hash =
         JenkinsSmiHash.combine(hash, documentRangeFormattingProvider.hashCode);
     hash =
         JenkinsSmiHash.combine(hash, documentOnTypeFormattingProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, renameProvider.hashCode);
-    hash = JenkinsSmiHash.combine(hash, documentLinkProvider.hashCode);
-    hash = JenkinsSmiHash.combine(hash, colorProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, foldingRangeProvider.hashCode);
-    hash = JenkinsSmiHash.combine(hash, declarationProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, executeCommandProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, selectionRangeProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workspaceSymbolProvider.hashCode);
     hash = JenkinsSmiHash.combine(hash, workspace.hashCode);
     hash = JenkinsSmiHash.combine(hash, experimental.hashCode);
     return JenkinsSmiHash.finish(hash);
@@ -11001,18 +19050,17 @@
       ServerCapabilitiesWorkspace.canParse,
       ServerCapabilitiesWorkspace.fromJson);
 
-  ServerCapabilitiesWorkspace(this.workspaceFolders);
+  ServerCapabilitiesWorkspace({this.workspaceFolders});
   static ServerCapabilitiesWorkspace fromJson(Map<String, dynamic> json) {
     final workspaceFolders = json['workspaceFolders'] != null
-        ? ServerCapabilitiesWorkspaceFolders.fromJson(json['workspaceFolders'])
+        ? WorkspaceFoldersServerCapabilities.fromJson(json['workspaceFolders'])
         : null;
-    return ServerCapabilitiesWorkspace(workspaceFolders);
+    return ServerCapabilitiesWorkspace(workspaceFolders: workspaceFolders);
   }
 
   /// The server supports workspace folder.
-  ///
-  /// Since 3.6.0
-  final ServerCapabilitiesWorkspaceFolders workspaceFolders;
+  ///  @since 3.6.0
+  final WorkspaceFoldersServerCapabilities workspaceFolders;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
@@ -11027,10 +19075,10 @@
       reporter.push('workspaceFolders');
       try {
         if (obj['workspaceFolders'] != null &&
-            !(ServerCapabilitiesWorkspaceFolders.canParse(
+            !(WorkspaceFoldersServerCapabilities.canParse(
                 obj['workspaceFolders'], reporter))) {
           reporter.reportError(
-              'must be of type ServerCapabilitiesWorkspaceFolders');
+              'must be of type WorkspaceFoldersServerCapabilities');
           return false;
         }
       } finally {
@@ -11063,98 +19111,11 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class ServerCapabilitiesWorkspaceFolders implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      ServerCapabilitiesWorkspaceFolders.canParse,
-      ServerCapabilitiesWorkspaceFolders.fromJson);
-
-  ServerCapabilitiesWorkspaceFolders(this.supported, this.changeNotifications);
-  static ServerCapabilitiesWorkspaceFolders fromJson(
-      Map<String, dynamic> json) {
-    final supported = json['supported'];
-    final changeNotifications = json['changeNotifications'];
-    return ServerCapabilitiesWorkspaceFolders(supported, changeNotifications);
-  }
-
-  /// Whether the server wants to receive workspace folder change notifications.
-  ///
-  /// If a strings is provided the string is treated as a ID under which the
-  /// notification is registered on the client side. The ID can be used to
-  /// unregister for these events using the `client/unregisterCapability`
-  /// request.
-  final bool changeNotifications;
-
-  /// The server has support for workspace folders
-  final bool supported;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (supported != null) {
-      __result['supported'] = supported;
-    }
-    if (changeNotifications != null) {
-      __result['changeNotifications'] = changeNotifications;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('supported');
-      try {
-        if (obj['supported'] != null && !(obj['supported'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('changeNotifications');
-      try {
-        if (obj['changeNotifications'] != null &&
-            !(obj['changeNotifications'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter
-          .reportError('must be of type ServerCapabilitiesWorkspaceFolders');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is ServerCapabilitiesWorkspaceFolders &&
-        other.runtimeType == ServerCapabilitiesWorkspaceFolders) {
-      return supported == other.supported &&
-          changeNotifications == other.changeNotifications &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, supported.hashCode);
-    hash = JenkinsSmiHash.combine(hash, changeNotifications.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
 class ShowMessageParams implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(ShowMessageParams.canParse, ShowMessageParams.fromJson);
 
-  ShowMessageParams(this.type, this.message) {
+  ShowMessageParams({@required this.type, @required this.message}) {
     if (type == null) {
       throw 'type is required but was not provided';
     }
@@ -11166,7 +19127,7 @@
     final type =
         json['type'] != null ? MessageType.fromJson(json['type']) : null;
     final message = json['message'];
-    return ShowMessageParams(type, message);
+    return ShowMessageParams(type: type, message: message);
   }
 
   /// The actual message.
@@ -11250,7 +19211,8 @@
   static const jsonHandler = LspJsonHandler(
       ShowMessageRequestParams.canParse, ShowMessageRequestParams.fromJson);
 
-  ShowMessageRequestParams(this.type, this.message, this.actions) {
+  ShowMessageRequestParams(
+      {@required this.type, @required this.message, this.actions}) {
     if (type == null) {
       throw 'type is required but was not provided';
     }
@@ -11266,7 +19228,8 @@
         ?.map((item) => item != null ? MessageActionItem.fromJson(item) : null)
         ?.cast<MessageActionItem>()
         ?.toList();
-    return ShowMessageRequestParams(type, message, actions);
+    return ShowMessageRequestParams(
+        type: type, message: message, actions: actions);
   }
 
   /// The message action items to present.
@@ -11376,7 +19339,8 @@
   static const jsonHandler =
       LspJsonHandler(SignatureHelp.canParse, SignatureHelp.fromJson);
 
-  SignatureHelp(this.signatures, this.activeSignature, this.activeParameter) {
+  SignatureHelp(
+      {@required this.signatures, this.activeSignature, this.activeParameter}) {
     if (signatures == null) {
       throw 'signatures is required but was not provided';
     }
@@ -11389,7 +19353,10 @@
         ?.toList();
     final activeSignature = json['activeSignature'];
     final activeParameter = json['activeParameter'];
-    return SignatureHelp(signatures, activeSignature, activeParameter);
+    return SignatureHelp(
+        signatures: signatures,
+        activeSignature: activeSignature,
+        activeParameter: activeParameter);
   }
 
   /// The active parameter of the active signature. If omitted or the value lies
@@ -11401,14 +19368,18 @@
   final num activeParameter;
 
   /// The active signature. If omitted or the value lies outside the range of
-  /// `signatures` the value defaults to zero or is ignored if
-  /// `signatures.length === 0`. Whenever possible implementors should make an
-  /// active decision about the active signature and shouldn't rely on a default
-  /// value. In future version of the protocol this property might become
-  /// mandatory to better express this.
+  /// `signatures` the value defaults to zero or is ignore if the
+  /// `SignatureHelp` as no signatures.
+  ///
+  /// Whenever possible implementors should make an active decision about the
+  /// active signature and shouldn't rely on a default value.
+  ///
+  /// In future version of the protocol this property might become mandatory to
+  /// better express this.
   final num activeSignature;
 
-  /// One or more signatures.
+  /// One or more signatures. If no signaures are availabe the signature help
+  /// request should return `null`.
   final List<SignatureInformation> signatures;
 
   Map<String, dynamic> toJson() {
@@ -11497,28 +19468,504 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Signature help options.
-class SignatureHelpOptions implements ToJsonable {
+class SignatureHelpClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SignatureHelpClientCapabilities.canParse,
+      SignatureHelpClientCapabilities.fromJson);
+
+  SignatureHelpClientCapabilities(
+      {this.dynamicRegistration,
+      this.signatureInformation,
+      this.contextSupport});
+  static SignatureHelpClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final signatureInformation = json['signatureInformation'] != null
+        ? SignatureHelpClientCapabilitiesSignatureInformation.fromJson(
+            json['signatureInformation'])
+        : null;
+    final contextSupport = json['contextSupport'];
+    return SignatureHelpClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        signatureInformation: signatureInformation,
+        contextSupport: contextSupport);
+  }
+
+  /// The client supports to send additional context information for a
+  /// `textDocument/signatureHelp` request. A client that opts into
+  /// contextSupport will also support the `retriggerCharacters` on
+  /// `SignatureHelpOptions`.
+  ///  @since 3.15.0
+  final bool contextSupport;
+
+  /// Whether signature help supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// The client supports the following `SignatureInformation` specific
+  /// properties.
+  final SignatureHelpClientCapabilitiesSignatureInformation
+      signatureInformation;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (signatureInformation != null) {
+      __result['signatureInformation'] = signatureInformation;
+    }
+    if (contextSupport != null) {
+      __result['contextSupport'] = contextSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('signatureInformation');
+      try {
+        if (obj['signatureInformation'] != null &&
+            !(SignatureHelpClientCapabilitiesSignatureInformation.canParse(
+                obj['signatureInformation'], reporter))) {
+          reporter.reportError(
+              'must be of type SignatureHelpClientCapabilitiesSignatureInformation');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('contextSupport');
+      try {
+        if (obj['contextSupport'] != null && !(obj['contextSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SignatureHelpClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SignatureHelpClientCapabilities &&
+        other.runtimeType == SignatureHelpClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          signatureInformation == other.signatureInformation &&
+          contextSupport == other.contextSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, signatureInformation.hashCode);
+    hash = JenkinsSmiHash.combine(hash, contextSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SignatureHelpClientCapabilitiesParameterInformation
+    implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SignatureHelpClientCapabilitiesParameterInformation.canParse,
+      SignatureHelpClientCapabilitiesParameterInformation.fromJson);
+
+  SignatureHelpClientCapabilitiesParameterInformation(
+      {this.labelOffsetSupport});
+  static SignatureHelpClientCapabilitiesParameterInformation fromJson(
+      Map<String, dynamic> json) {
+    final labelOffsetSupport = json['labelOffsetSupport'];
+    return SignatureHelpClientCapabilitiesParameterInformation(
+        labelOffsetSupport: labelOffsetSupport);
+  }
+
+  /// The client supports processing label offsets instead of a simple label
+  /// string.
+  ///  @since 3.14.0
+  final bool labelOffsetSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (labelOffsetSupport != null) {
+      __result['labelOffsetSupport'] = labelOffsetSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('labelOffsetSupport');
+      try {
+        if (obj['labelOffsetSupport'] != null &&
+            !(obj['labelOffsetSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type SignatureHelpClientCapabilitiesParameterInformation');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SignatureHelpClientCapabilitiesParameterInformation &&
+        other.runtimeType ==
+            SignatureHelpClientCapabilitiesParameterInformation) {
+      return labelOffsetSupport == other.labelOffsetSupport && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, labelOffsetSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SignatureHelpClientCapabilitiesSignatureInformation
+    implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SignatureHelpClientCapabilitiesSignatureInformation.canParse,
+      SignatureHelpClientCapabilitiesSignatureInformation.fromJson);
+
+  SignatureHelpClientCapabilitiesSignatureInformation(
+      {this.documentationFormat, this.parameterInformation});
+  static SignatureHelpClientCapabilitiesSignatureInformation fromJson(
+      Map<String, dynamic> json) {
+    final documentationFormat = json['documentationFormat']
+        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
+        ?.cast<MarkupKind>()
+        ?.toList();
+    final parameterInformation = json['parameterInformation'] != null
+        ? SignatureHelpClientCapabilitiesParameterInformation.fromJson(
+            json['parameterInformation'])
+        : null;
+    return SignatureHelpClientCapabilitiesSignatureInformation(
+        documentationFormat: documentationFormat,
+        parameterInformation: parameterInformation);
+  }
+
+  /// Client supports the follow content formats for the documentation property.
+  /// The order describes the preferred format of the client.
+  final List<MarkupKind> documentationFormat;
+
+  /// Client capabilities specific to parameter information.
+  final SignatureHelpClientCapabilitiesParameterInformation
+      parameterInformation;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (documentationFormat != null) {
+      __result['documentationFormat'] = documentationFormat;
+    }
+    if (parameterInformation != null) {
+      __result['parameterInformation'] = parameterInformation;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentationFormat');
+      try {
+        if (obj['documentationFormat'] != null &&
+            !((obj['documentationFormat'] is List &&
+                (obj['documentationFormat']
+                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<MarkupKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('parameterInformation');
+      try {
+        if (obj['parameterInformation'] != null &&
+            !(SignatureHelpClientCapabilitiesParameterInformation.canParse(
+                obj['parameterInformation'], reporter))) {
+          reporter.reportError(
+              'must be of type SignatureHelpClientCapabilitiesParameterInformation');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type SignatureHelpClientCapabilitiesSignatureInformation');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SignatureHelpClientCapabilitiesSignatureInformation &&
+        other.runtimeType ==
+            SignatureHelpClientCapabilitiesSignatureInformation) {
+      return listEqual(documentationFormat, other.documentationFormat,
+              (MarkupKind a, MarkupKind b) => a == b) &&
+          parameterInformation == other.parameterInformation &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentationFormat));
+    hash = JenkinsSmiHash.combine(hash, parameterInformation.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+/// Additional information about the context in which a signature help request
+/// was triggered.
+///  @since 3.15.0
+class SignatureHelpContext implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SignatureHelpContext.canParse, SignatureHelpContext.fromJson);
+
+  SignatureHelpContext(
+      {@required this.triggerKind,
+      this.triggerCharacter,
+      @required this.isRetrigger,
+      this.activeSignatureHelp}) {
+    if (triggerKind == null) {
+      throw 'triggerKind is required but was not provided';
+    }
+    if (isRetrigger == null) {
+      throw 'isRetrigger is required but was not provided';
+    }
+  }
+  static SignatureHelpContext fromJson(Map<String, dynamic> json) {
+    final triggerKind = json['triggerKind'] != null
+        ? SignatureHelpTriggerKind.fromJson(json['triggerKind'])
+        : null;
+    final triggerCharacter = json['triggerCharacter'];
+    final isRetrigger = json['isRetrigger'];
+    final activeSignatureHelp = json['activeSignatureHelp'] != null
+        ? SignatureHelp.fromJson(json['activeSignatureHelp'])
+        : null;
+    return SignatureHelpContext(
+        triggerKind: triggerKind,
+        triggerCharacter: triggerCharacter,
+        isRetrigger: isRetrigger,
+        activeSignatureHelp: activeSignatureHelp);
+  }
+
+  /// The currently active `SignatureHelp`.
+  ///
+  /// The `activeSignatureHelp` has its `SignatureHelp.activeSignature` field
+  /// updated based on the user navigating through available signatures.
+  final SignatureHelp activeSignatureHelp;
+
+  /// `true` if signature help was already showing when it was triggered.
+  ///
+  /// Retriggers occur when the signature help is already active and can be
+  /// caused by actions such as typing a trigger character, a cursor move, or
+  /// document content changes.
+  final bool isRetrigger;
+
+  /// Character that caused signature help to be triggered.
+  ///
+  /// This is undefined when `triggerKind !==
+  /// SignatureHelpTriggerKind.TriggerCharacter`
+  final String triggerCharacter;
+
+  /// Action that caused signature help to be triggered.
+  final SignatureHelpTriggerKind triggerKind;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['triggerKind'] =
+        triggerKind ?? (throw 'triggerKind is required but was not set');
+    if (triggerCharacter != null) {
+      __result['triggerCharacter'] = triggerCharacter;
+    }
+    __result['isRetrigger'] =
+        isRetrigger ?? (throw 'isRetrigger is required but was not set');
+    if (activeSignatureHelp != null) {
+      __result['activeSignatureHelp'] = activeSignatureHelp;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('triggerKind');
+      try {
+        if (!obj.containsKey('triggerKind')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['triggerKind'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(SignatureHelpTriggerKind.canParse(
+            obj['triggerKind'], reporter))) {
+          reporter.reportError('must be of type SignatureHelpTriggerKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('triggerCharacter');
+      try {
+        if (obj['triggerCharacter'] != null &&
+            !(obj['triggerCharacter'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('isRetrigger');
+      try {
+        if (!obj.containsKey('isRetrigger')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['isRetrigger'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['isRetrigger'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('activeSignatureHelp');
+      try {
+        if (obj['activeSignatureHelp'] != null &&
+            !(SignatureHelp.canParse(obj['activeSignatureHelp'], reporter))) {
+          reporter.reportError('must be of type SignatureHelp');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SignatureHelpContext');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SignatureHelpContext &&
+        other.runtimeType == SignatureHelpContext) {
+      return triggerKind == other.triggerKind &&
+          triggerCharacter == other.triggerCharacter &&
+          isRetrigger == other.isRetrigger &&
+          activeSignatureHelp == other.activeSignatureHelp &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, triggerKind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, triggerCharacter.hashCode);
+    hash = JenkinsSmiHash.combine(hash, isRetrigger.hashCode);
+    hash = JenkinsSmiHash.combine(hash, activeSignatureHelp.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SignatureHelpOptions implements WorkDoneProgressOptions, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       SignatureHelpOptions.canParse, SignatureHelpOptions.fromJson);
 
-  SignatureHelpOptions(this.triggerCharacters);
+  SignatureHelpOptions(
+      {this.triggerCharacters,
+      this.retriggerCharacters,
+      this.workDoneProgress});
   static SignatureHelpOptions fromJson(Map<String, dynamic> json) {
+    if (SignatureHelpRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return SignatureHelpRegistrationOptions.fromJson(json);
+    }
     final triggerCharacters = json['triggerCharacters']
         ?.map((item) => item)
         ?.cast<String>()
         ?.toList();
-    return SignatureHelpOptions(triggerCharacters);
+    final retriggerCharacters = json['retriggerCharacters']
+        ?.map((item) => item)
+        ?.cast<String>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    return SignatureHelpOptions(
+        triggerCharacters: triggerCharacters,
+        retriggerCharacters: retriggerCharacters,
+        workDoneProgress: workDoneProgress);
   }
 
+  /// List of characters that re-trigger signature help.
+  ///
+  /// These trigger characters are only active when signature help is already
+  /// showing. All trigger characters are also counted as re-trigger characters.
+  ///  @since 3.15.0
+  final List<String> retriggerCharacters;
+
   /// The characters that trigger signature help automatically.
   final List<String> triggerCharacters;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     if (triggerCharacters != null) {
       __result['triggerCharacters'] = triggerCharacters;
     }
+    if (retriggerCharacters != null) {
+      __result['retriggerCharacters'] = retriggerCharacters;
+    }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
@@ -11535,6 +19982,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('retriggerCharacters');
+      try {
+        if (obj['retriggerCharacters'] != null &&
+            !((obj['retriggerCharacters'] is List &&
+                (obj['retriggerCharacters']
+                    .every((item) => item is String))))) {
+          reporter.reportError('must be of type List<String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type SignatureHelpOptions');
@@ -11548,6 +20017,9 @@
         other.runtimeType == SignatureHelpOptions) {
       return listEqual(triggerCharacters, other.triggerCharacters,
               (String a, String b) => a == b) &&
+          listEqual(retriggerCharacters, other.retriggerCharacters,
+              (String a, String b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -11557,6 +20029,169 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, lspHashCode(triggerCharacters));
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(retriggerCharacters));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class SignatureHelpParams
+    implements TextDocumentPositionParams, WorkDoneProgressParams, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      SignatureHelpParams.canParse, SignatureHelpParams.fromJson);
+
+  SignatureHelpParams(
+      {this.context,
+      @required this.textDocument,
+      @required this.position,
+      this.workDoneToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static SignatureHelpParams fromJson(Map<String, dynamic> json) {
+    final context = json['context'] != null
+        ? SignatureHelpContext.fromJson(json['context'])
+        : null;
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return SignatureHelpParams(
+        context: context,
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken);
+  }
+
+  /// The signature help context. This is only available if the client specifies
+  /// to send this using the client capability
+  /// `textDocument.signatureHelp.contextSupport === true`
+  ///  @since 3.15.0
+  final SignatureHelpContext context;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (context != null) {
+      __result['context'] = context;
+    }
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('context');
+      try {
+        if (obj['context'] != null &&
+            !(SignatureHelpContext.canParse(obj['context'], reporter))) {
+          reporter.reportError('must be of type SignatureHelpContext');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type SignatureHelpParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is SignatureHelpParams &&
+        other.runtimeType == SignatureHelpParams) {
+      return context == other.context &&
+          textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, context.hashCode);
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -11565,55 +20200,72 @@
 }
 
 class SignatureHelpRegistrationOptions
-    implements TextDocumentRegistrationOptions, ToJsonable {
+    implements
+        TextDocumentRegistrationOptions,
+        SignatureHelpOptions,
+        ToJsonable {
   static const jsonHandler = LspJsonHandler(
       SignatureHelpRegistrationOptions.canParse,
       SignatureHelpRegistrationOptions.fromJson);
 
   SignatureHelpRegistrationOptions(
-      this.triggerCharacters, this.documentSelector);
+      {this.documentSelector,
+      this.triggerCharacters,
+      this.retriggerCharacters,
+      this.workDoneProgress});
   static SignatureHelpRegistrationOptions fromJson(Map<String, dynamic> json) {
-    final triggerCharacters = json['triggerCharacters']
-        ?.map((item) => item)
-        ?.cast<String>()
-        ?.toList();
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
+    final triggerCharacters = json['triggerCharacters']
+        ?.map((item) => item)
+        ?.cast<String>()
+        ?.toList();
+    final retriggerCharacters = json['retriggerCharacters']
+        ?.map((item) => item)
+        ?.cast<String>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
     return SignatureHelpRegistrationOptions(
-        triggerCharacters, documentSelector);
+        documentSelector: documentSelector,
+        triggerCharacters: triggerCharacters,
+        retriggerCharacters: retriggerCharacters,
+        workDoneProgress: workDoneProgress);
   }
 
   /// A document selector to identify the scope of the registration. If set to
   /// null the document selector provided on the client side will be used.
   final List<DocumentFilter> documentSelector;
 
+  /// List of characters that re-trigger signature help.
+  ///
+  /// These trigger characters are only active when signature help is already
+  /// showing. All trigger characters are also counted as re-trigger characters.
+  ///  @since 3.15.0
+  final List<String> retriggerCharacters;
+
   /// The characters that trigger signature help automatically.
   final List<String> triggerCharacters;
+  final bool workDoneProgress;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
     if (triggerCharacters != null) {
       __result['triggerCharacters'] = triggerCharacters;
     }
-    __result['documentSelector'] = documentSelector;
+    if (retriggerCharacters != null) {
+      __result['retriggerCharacters'] = retriggerCharacters;
+    }
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('triggerCharacters');
-      try {
-        if (obj['triggerCharacters'] != null &&
-            !((obj['triggerCharacters'] is List &&
-                (obj['triggerCharacters'].every((item) => item is String))))) {
-          reporter.reportError('must be of type List<String>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
       reporter.push('documentSelector');
       try {
         if (!obj.containsKey('documentSelector')) {
@@ -11630,6 +20282,39 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('triggerCharacters');
+      try {
+        if (obj['triggerCharacters'] != null &&
+            !((obj['triggerCharacters'] is List &&
+                (obj['triggerCharacters'].every((item) => item is String))))) {
+          reporter.reportError('must be of type List<String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('retriggerCharacters');
+      try {
+        if (obj['retriggerCharacters'] != null &&
+            !((obj['retriggerCharacters'] is List &&
+                (obj['retriggerCharacters']
+                    .every((item) => item is String))))) {
+          reporter.reportError('must be of type List<String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type SignatureHelpRegistrationOptions');
@@ -11641,10 +20326,13 @@
   bool operator ==(Object other) {
     if (other is SignatureHelpRegistrationOptions &&
         other.runtimeType == SignatureHelpRegistrationOptions) {
-      return listEqual(triggerCharacters, other.triggerCharacters,
-              (String a, String b) => a == b) &&
-          listEqual(documentSelector, other.documentSelector,
+      return listEqual(documentSelector, other.documentSelector,
               (DocumentFilter a, DocumentFilter b) => a == b) &&
+          listEqual(triggerCharacters, other.triggerCharacters,
+              (String a, String b) => a == b) &&
+          listEqual(retriggerCharacters, other.retriggerCharacters,
+              (String a, String b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
           true;
     }
     return false;
@@ -11653,8 +20341,10 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(triggerCharacters));
     hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(triggerCharacters));
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(retriggerCharacters));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -11662,13 +20352,48 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+/// How a signature help was triggered.
+///  @since 3.15.0
+class SignatureHelpTriggerKind {
+  const SignatureHelpTriggerKind(this._value);
+  const SignatureHelpTriggerKind.fromJson(this._value);
+
+  final num _value;
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    return obj is num;
+  }
+
+  /// Signature help was invoked manually by the user or by a command.
+  static const Invoked = SignatureHelpTriggerKind(1);
+
+  /// Signature help was triggered by a trigger character.
+  static const TriggerCharacter = SignatureHelpTriggerKind(2);
+
+  /// Signature help was triggered by the cursor moving or by the document
+  /// content changing.
+  static const ContentChange = SignatureHelpTriggerKind(3);
+
+  Object toJson() => _value;
+
+  @override
+  String toString() => _value.toString();
+
+  @override
+  int get hashCode => _value.hashCode;
+
+  bool operator ==(Object o) =>
+      o is SignatureHelpTriggerKind && o._value == _value;
+}
+
 /// Represents the signature of something callable. A signature can have a
 /// label, like a function-name, a doc-comment, and a set of parameters.
 class SignatureInformation implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       SignatureInformation.canParse, SignatureInformation.fromJson);
 
-  SignatureInformation(this.label, this.documentation, this.parameters) {
+  SignatureInformation(
+      {@required this.label, this.documentation, this.parameters}) {
     if (label == null) {
       throw 'label is required but was not provided';
     }
@@ -11689,7 +20414,8 @@
             (item) => item != null ? ParameterInformation.fromJson(item) : null)
         ?.cast<ParameterInformation>()
         ?.toList();
-    return SignatureInformation(label, documentation, parameters);
+    return SignatureInformation(
+        label: label, documentation: documentation, parameters: parameters);
   }
 
   /// The human-readable doc-comment of this signature. Will be shown in the UI
@@ -11795,10 +20521,28 @@
   static const jsonHandler = LspJsonHandler(
       StaticRegistrationOptions.canParse, StaticRegistrationOptions.fromJson);
 
-  StaticRegistrationOptions(this.id);
+  StaticRegistrationOptions({this.id});
   static StaticRegistrationOptions fromJson(Map<String, dynamic> json) {
+    if (DeclarationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DeclarationRegistrationOptions.fromJson(json);
+    }
+    if (TypeDefinitionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionRegistrationOptions.fromJson(json);
+    }
+    if (ImplementationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ImplementationRegistrationOptions.fromJson(json);
+    }
+    if (DocumentColorRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorRegistrationOptions.fromJson(json);
+    }
+    if (FoldingRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeRegistrationOptions.fromJson(json);
+    }
+    if (SelectionRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeRegistrationOptions.fromJson(json);
+    }
     final id = json['id'];
-    return StaticRegistrationOptions(id);
+    return StaticRegistrationOptions(id: id);
   }
 
   /// The id used to register the request. The id can be used to deregister the
@@ -11857,8 +20601,12 @@
   static const jsonHandler =
       LspJsonHandler(SymbolInformation.canParse, SymbolInformation.fromJson);
 
-  SymbolInformation(this.name, this.kind, this.deprecated, this.location,
-      this.containerName) {
+  SymbolInformation(
+      {@required this.name,
+      @required this.kind,
+      this.deprecated,
+      @required this.location,
+      this.containerName}) {
     if (name == null) {
       throw 'name is required but was not provided';
     }
@@ -11877,7 +20625,12 @@
     final location =
         json['location'] != null ? Location.fromJson(json['location']) : null;
     final containerName = json['containerName'];
-    return SymbolInformation(name, kind, deprecated, location, containerName);
+    return SymbolInformation(
+        name: name,
+        kind: kind,
+        deprecated: deprecated,
+        location: location,
+        containerName: containerName);
   }
 
   /// The name of the symbol containing this symbol. This information is for
@@ -12084,7 +20837,8 @@
       TextDocumentChangeRegistrationOptions.canParse,
       TextDocumentChangeRegistrationOptions.fromJson);
 
-  TextDocumentChangeRegistrationOptions(this.syncKind, this.documentSelector) {
+  TextDocumentChangeRegistrationOptions(
+      {@required this.syncKind, this.documentSelector}) {
     if (syncKind == null) {
       throw 'syncKind is required but was not provided';
     }
@@ -12098,7 +20852,8 @@
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return TextDocumentChangeRegistrationOptions(syncKind, documentSelector);
+    return TextDocumentChangeRegistrationOptions(
+        syncKind: syncKind, documentSelector: documentSelector);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -12191,199 +20946,196 @@
       TextDocumentClientCapabilities.fromJson);
 
   TextDocumentClientCapabilities(
-      this.synchronization,
+      {this.synchronization,
       this.completion,
       this.hover,
       this.signatureHelp,
-      this.references,
-      this.documentHighlight,
-      this.documentSymbol,
-      this.formatting,
-      this.rangeFormatting,
-      this.onTypeFormatting,
       this.declaration,
       this.definition,
       this.typeDefinition,
       this.implementation,
+      this.references,
+      this.documentHighlight,
+      this.documentSymbol,
       this.codeAction,
       this.codeLens,
       this.documentLink,
       this.colorProvider,
+      this.formatting,
+      this.rangeFormatting,
+      this.onTypeFormatting,
       this.rename,
       this.publishDiagnostics,
-      this.foldingRange);
+      this.foldingRange,
+      this.selectionRange});
   static TextDocumentClientCapabilities fromJson(Map<String, dynamic> json) {
     final synchronization = json['synchronization'] != null
-        ? TextDocumentClientCapabilitiesSynchronization.fromJson(
-            json['synchronization'])
+        ? TextDocumentSyncClientCapabilities.fromJson(json['synchronization'])
         : null;
     final completion = json['completion'] != null
-        ? TextDocumentClientCapabilitiesCompletion.fromJson(json['completion'])
+        ? CompletionClientCapabilities.fromJson(json['completion'])
         : null;
     final hover = json['hover'] != null
-        ? TextDocumentClientCapabilitiesHover.fromJson(json['hover'])
+        ? HoverClientCapabilities.fromJson(json['hover'])
         : null;
     final signatureHelp = json['signatureHelp'] != null
-        ? TextDocumentClientCapabilitiesSignatureHelp.fromJson(
-            json['signatureHelp'])
+        ? SignatureHelpClientCapabilities.fromJson(json['signatureHelp'])
+        : null;
+    final declaration = json['declaration'] != null
+        ? DeclarationClientCapabilities.fromJson(json['declaration'])
+        : null;
+    final definition = json['definition'] != null
+        ? DefinitionClientCapabilities.fromJson(json['definition'])
+        : null;
+    final typeDefinition = json['typeDefinition'] != null
+        ? TypeDefinitionClientCapabilities.fromJson(json['typeDefinition'])
+        : null;
+    final implementation = json['implementation'] != null
+        ? ImplementationClientCapabilities.fromJson(json['implementation'])
         : null;
     final references = json['references'] != null
-        ? TextDocumentClientCapabilitiesReferences.fromJson(json['references'])
+        ? ReferenceClientCapabilities.fromJson(json['references'])
         : null;
     final documentHighlight = json['documentHighlight'] != null
-        ? TextDocumentClientCapabilitiesDocumentHighlight.fromJson(
+        ? DocumentHighlightClientCapabilities.fromJson(
             json['documentHighlight'])
         : null;
     final documentSymbol = json['documentSymbol'] != null
-        ? TextDocumentClientCapabilitiesDocumentSymbol.fromJson(
-            json['documentSymbol'])
+        ? DocumentSymbolClientCapabilities.fromJson(json['documentSymbol'])
+        : null;
+    final codeAction = json['codeAction'] != null
+        ? CodeActionClientCapabilities.fromJson(json['codeAction'])
+        : null;
+    final codeLens = json['codeLens'] != null
+        ? CodeLensClientCapabilities.fromJson(json['codeLens'])
+        : null;
+    final documentLink = json['documentLink'] != null
+        ? DocumentLinkClientCapabilities.fromJson(json['documentLink'])
+        : null;
+    final colorProvider = json['colorProvider'] != null
+        ? DocumentColorClientCapabilities.fromJson(json['colorProvider'])
         : null;
     final formatting = json['formatting'] != null
-        ? TextDocumentClientCapabilitiesFormatting.fromJson(json['formatting'])
+        ? DocumentFormattingClientCapabilities.fromJson(json['formatting'])
         : null;
     final rangeFormatting = json['rangeFormatting'] != null
-        ? TextDocumentClientCapabilitiesRangeFormatting.fromJson(
+        ? DocumentRangeFormattingClientCapabilities.fromJson(
             json['rangeFormatting'])
         : null;
     final onTypeFormatting = json['onTypeFormatting'] != null
-        ? TextDocumentClientCapabilitiesOnTypeFormatting.fromJson(
+        ? DocumentOnTypeFormattingClientCapabilities.fromJson(
             json['onTypeFormatting'])
         : null;
-    final declaration = json['declaration'] != null
-        ? TextDocumentClientCapabilitiesDeclaration.fromJson(
-            json['declaration'])
-        : null;
-    final definition = json['definition'] != null
-        ? TextDocumentClientCapabilitiesDefinition.fromJson(json['definition'])
-        : null;
-    final typeDefinition = json['typeDefinition'] != null
-        ? TextDocumentClientCapabilitiesTypeDefinition.fromJson(
-            json['typeDefinition'])
-        : null;
-    final implementation = json['implementation'] != null
-        ? TextDocumentClientCapabilitiesImplementation.fromJson(
-            json['implementation'])
-        : null;
-    final codeAction = json['codeAction'] != null
-        ? TextDocumentClientCapabilitiesCodeAction.fromJson(json['codeAction'])
-        : null;
-    final codeLens = json['codeLens'] != null
-        ? TextDocumentClientCapabilitiesCodeLens.fromJson(json['codeLens'])
-        : null;
-    final documentLink = json['documentLink'] != null
-        ? TextDocumentClientCapabilitiesDocumentLink.fromJson(
-            json['documentLink'])
-        : null;
-    final colorProvider = json['colorProvider'] != null
-        ? TextDocumentClientCapabilitiesColorProvider.fromJson(
-            json['colorProvider'])
-        : null;
     final rename = json['rename'] != null
-        ? TextDocumentClientCapabilitiesRename.fromJson(json['rename'])
+        ? RenameClientCapabilities.fromJson(json['rename'])
         : null;
     final publishDiagnostics = json['publishDiagnostics'] != null
-        ? TextDocumentClientCapabilitiesPublishDiagnostics.fromJson(
+        ? PublishDiagnosticsClientCapabilities.fromJson(
             json['publishDiagnostics'])
         : null;
     final foldingRange = json['foldingRange'] != null
-        ? TextDocumentClientCapabilitiesFoldingRange.fromJson(
-            json['foldingRange'])
+        ? FoldingRangeClientCapabilities.fromJson(json['foldingRange'])
+        : null;
+    final selectionRange = json['selectionRange'] != null
+        ? SelectionRangeClientCapabilities.fromJson(json['selectionRange'])
         : null;
     return TextDocumentClientCapabilities(
-        synchronization,
-        completion,
-        hover,
-        signatureHelp,
-        references,
-        documentHighlight,
-        documentSymbol,
-        formatting,
-        rangeFormatting,
-        onTypeFormatting,
-        declaration,
-        definition,
-        typeDefinition,
-        implementation,
-        codeAction,
-        codeLens,
-        documentLink,
-        colorProvider,
-        rename,
-        publishDiagnostics,
-        foldingRange);
+        synchronization: synchronization,
+        completion: completion,
+        hover: hover,
+        signatureHelp: signatureHelp,
+        declaration: declaration,
+        definition: definition,
+        typeDefinition: typeDefinition,
+        implementation: implementation,
+        references: references,
+        documentHighlight: documentHighlight,
+        documentSymbol: documentSymbol,
+        codeAction: codeAction,
+        codeLens: codeLens,
+        documentLink: documentLink,
+        colorProvider: colorProvider,
+        formatting: formatting,
+        rangeFormatting: rangeFormatting,
+        onTypeFormatting: onTypeFormatting,
+        rename: rename,
+        publishDiagnostics: publishDiagnostics,
+        foldingRange: foldingRange,
+        selectionRange: selectionRange);
   }
 
-  /// Capabilities specific to the `textDocument/codeAction`
-  final TextDocumentClientCapabilitiesCodeAction codeAction;
+  /// Capabilities specific to the `textDocument/codeAction` request.
+  final CodeActionClientCapabilities codeAction;
 
-  /// Capabilities specific to the `textDocument/codeLens`
-  final TextDocumentClientCapabilitiesCodeLens codeLens;
+  /// Capabilities specific to the `textDocument/codeLens` request.
+  final CodeLensClientCapabilities codeLens;
 
   /// Capabilities specific to the `textDocument/documentColor` and the
   /// `textDocument/colorPresentation` request.
-  ///
-  /// Since 3.6.0
-  final TextDocumentClientCapabilitiesColorProvider colorProvider;
+  ///  @since 3.6.0
+  final DocumentColorClientCapabilities colorProvider;
 
-  /// Capabilities specific to the `textDocument/completion`
-  final TextDocumentClientCapabilitiesCompletion completion;
+  /// Capabilities specific to the `textDocument/completion` request.
+  final CompletionClientCapabilities completion;
 
-  /// Capabilities specific to the `textDocument/declaration`
-  final TextDocumentClientCapabilitiesDeclaration declaration;
+  /// Capabilities specific to the `textDocument/declaration` request.
+  ///  @since 3.14.0
+  final DeclarationClientCapabilities declaration;
 
-  /// Capabilities specific to the `textDocument/definition`.
-  ///
-  /// Since 3.14.0
-  final TextDocumentClientCapabilitiesDefinition definition;
+  /// Capabilities specific to the `textDocument/definition` request.
+  final DefinitionClientCapabilities definition;
 
-  /// Capabilities specific to the `textDocument/documentHighlight`
-  final TextDocumentClientCapabilitiesDocumentHighlight documentHighlight;
+  /// Capabilities specific to the `textDocument/documentHighlight` request.
+  final DocumentHighlightClientCapabilities documentHighlight;
 
-  /// Capabilities specific to the `textDocument/documentLink`
-  final TextDocumentClientCapabilitiesDocumentLink documentLink;
+  /// Capabilities specific to the `textDocument/documentLink` request.
+  final DocumentLinkClientCapabilities documentLink;
 
-  /// Capabilities specific to the `textDocument/documentSymbol`
-  final TextDocumentClientCapabilitiesDocumentSymbol documentSymbol;
+  /// Capabilities specific to the `textDocument/documentSymbol` request.
+  final DocumentSymbolClientCapabilities documentSymbol;
 
-  /// Capabilities specific to `textDocument/foldingRange` requests.
-  ///
-  /// Since 3.10.0
-  final TextDocumentClientCapabilitiesFoldingRange foldingRange;
+  /// Capabilities specific to the `textDocument/foldingRange` request.
+  ///  @since 3.10.0
+  final FoldingRangeClientCapabilities foldingRange;
 
-  /// Capabilities specific to the `textDocument/formatting`
-  final TextDocumentClientCapabilitiesFormatting formatting;
+  /// Capabilities specific to the `textDocument/formatting` request.
+  final DocumentFormattingClientCapabilities formatting;
 
-  /// Capabilities specific to the `textDocument/hover`
-  final TextDocumentClientCapabilitiesHover hover;
+  /// Capabilities specific to the `textDocument/hover` request.
+  final HoverClientCapabilities hover;
 
-  /// Capabilities specific to the `textDocument/implementation`.
-  ///
-  /// Since 3.6.0
-  final TextDocumentClientCapabilitiesImplementation implementation;
+  /// Capabilities specific to the `textDocument/implementation` request.
+  ///  @since 3.6.0
+  final ImplementationClientCapabilities implementation;
 
-  /// Capabilities specific to the `textDocument/onTypeFormatting`
-  final TextDocumentClientCapabilitiesOnTypeFormatting onTypeFormatting;
+  /// request. Capabilities specific to the `textDocument/onTypeFormatting`
+  /// request.
+  final DocumentOnTypeFormattingClientCapabilities onTypeFormatting;
 
-  /// Capabilities specific to `textDocument/publishDiagnostics`.
-  final TextDocumentClientCapabilitiesPublishDiagnostics publishDiagnostics;
+  /// Capabilities specific to the `textDocument/publishDiagnostics`
+  /// notification.
+  final PublishDiagnosticsClientCapabilities publishDiagnostics;
 
-  /// Capabilities specific to the `textDocument/rangeFormatting`
-  final TextDocumentClientCapabilitiesRangeFormatting rangeFormatting;
+  /// Capabilities specific to the `textDocument/rangeFormatting` request.
+  final DocumentRangeFormattingClientCapabilities rangeFormatting;
 
-  /// Capabilities specific to the `textDocument/references`
-  final TextDocumentClientCapabilitiesReferences references;
+  /// Capabilities specific to the `textDocument/references` request.
+  final ReferenceClientCapabilities references;
 
-  /// Capabilities specific to the `textDocument/rename`
-  final TextDocumentClientCapabilitiesRename rename;
+  /// Capabilities specific to the `textDocument/rename` request.
+  final RenameClientCapabilities rename;
 
-  /// Capabilities specific to the `textDocument/signatureHelp`
-  final TextDocumentClientCapabilitiesSignatureHelp signatureHelp;
-  final TextDocumentClientCapabilitiesSynchronization synchronization;
+  /// Capabilities specific to the `textDocument/selectionRange` request.
+  ///  @since 3.15.0
+  final SelectionRangeClientCapabilities selectionRange;
 
-  /// Capabilities specific to the `textDocument/typeDefinition`
-  ///
-  /// Since 3.6.0
-  final TextDocumentClientCapabilitiesTypeDefinition typeDefinition;
+  /// Capabilities specific to the `textDocument/signatureHelp` request.
+  final SignatureHelpClientCapabilities signatureHelp;
+  final TextDocumentSyncClientCapabilities synchronization;
+
+  /// Capabilities specific to the `textDocument/typeDefinition` request.
+  ///  @since 3.6.0
+  final TypeDefinitionClientCapabilities typeDefinition;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
@@ -12399,24 +21151,6 @@
     if (signatureHelp != null) {
       __result['signatureHelp'] = signatureHelp;
     }
-    if (references != null) {
-      __result['references'] = references;
-    }
-    if (documentHighlight != null) {
-      __result['documentHighlight'] = documentHighlight;
-    }
-    if (documentSymbol != null) {
-      __result['documentSymbol'] = documentSymbol;
-    }
-    if (formatting != null) {
-      __result['formatting'] = formatting;
-    }
-    if (rangeFormatting != null) {
-      __result['rangeFormatting'] = rangeFormatting;
-    }
-    if (onTypeFormatting != null) {
-      __result['onTypeFormatting'] = onTypeFormatting;
-    }
     if (declaration != null) {
       __result['declaration'] = declaration;
     }
@@ -12429,6 +21163,15 @@
     if (implementation != null) {
       __result['implementation'] = implementation;
     }
+    if (references != null) {
+      __result['references'] = references;
+    }
+    if (documentHighlight != null) {
+      __result['documentHighlight'] = documentHighlight;
+    }
+    if (documentSymbol != null) {
+      __result['documentSymbol'] = documentSymbol;
+    }
     if (codeAction != null) {
       __result['codeAction'] = codeAction;
     }
@@ -12441,6 +21184,15 @@
     if (colorProvider != null) {
       __result['colorProvider'] = colorProvider;
     }
+    if (formatting != null) {
+      __result['formatting'] = formatting;
+    }
+    if (rangeFormatting != null) {
+      __result['rangeFormatting'] = rangeFormatting;
+    }
+    if (onTypeFormatting != null) {
+      __result['onTypeFormatting'] = onTypeFormatting;
+    }
     if (rename != null) {
       __result['rename'] = rename;
     }
@@ -12450,6 +21202,9 @@
     if (foldingRange != null) {
       __result['foldingRange'] = foldingRange;
     }
+    if (selectionRange != null) {
+      __result['selectionRange'] = selectionRange;
+    }
     return __result;
   }
 
@@ -12458,10 +21213,10 @@
       reporter.push('synchronization');
       try {
         if (obj['synchronization'] != null &&
-            !(TextDocumentClientCapabilitiesSynchronization.canParse(
+            !(TextDocumentSyncClientCapabilities.canParse(
                 obj['synchronization'], reporter))) {
           reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesSynchronization');
+              'must be of type TextDocumentSyncClientCapabilities');
           return false;
         }
       } finally {
@@ -12470,10 +21225,9 @@
       reporter.push('completion');
       try {
         if (obj['completion'] != null &&
-            !(TextDocumentClientCapabilitiesCompletion.canParse(
+            !(CompletionClientCapabilities.canParse(
                 obj['completion'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCompletion');
+          reporter.reportError('must be of type CompletionClientCapabilities');
           return false;
         }
       } finally {
@@ -12482,10 +21236,8 @@
       reporter.push('hover');
       try {
         if (obj['hover'] != null &&
-            !(TextDocumentClientCapabilitiesHover.canParse(
-                obj['hover'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesHover');
+            !(HoverClientCapabilities.canParse(obj['hover'], reporter))) {
+          reporter.reportError('must be of type HoverClientCapabilities');
           return false;
         }
       } finally {
@@ -12494,82 +21246,10 @@
       reporter.push('signatureHelp');
       try {
         if (obj['signatureHelp'] != null &&
-            !(TextDocumentClientCapabilitiesSignatureHelp.canParse(
+            !(SignatureHelpClientCapabilities.canParse(
                 obj['signatureHelp'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesSignatureHelp');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('references');
-      try {
-        if (obj['references'] != null &&
-            !(TextDocumentClientCapabilitiesReferences.canParse(
-                obj['references'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesReferences');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('documentHighlight');
-      try {
-        if (obj['documentHighlight'] != null &&
-            !(TextDocumentClientCapabilitiesDocumentHighlight.canParse(
-                obj['documentHighlight'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesDocumentHighlight');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('documentSymbol');
-      try {
-        if (obj['documentSymbol'] != null &&
-            !(TextDocumentClientCapabilitiesDocumentSymbol.canParse(
-                obj['documentSymbol'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesDocumentSymbol');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('formatting');
-      try {
-        if (obj['formatting'] != null &&
-            !(TextDocumentClientCapabilitiesFormatting.canParse(
-                obj['formatting'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesFormatting');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('rangeFormatting');
-      try {
-        if (obj['rangeFormatting'] != null &&
-            !(TextDocumentClientCapabilitiesRangeFormatting.canParse(
-                obj['rangeFormatting'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesRangeFormatting');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('onTypeFormatting');
-      try {
-        if (obj['onTypeFormatting'] != null &&
-            !(TextDocumentClientCapabilitiesOnTypeFormatting.canParse(
-                obj['onTypeFormatting'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesOnTypeFormatting');
+          reporter
+              .reportError('must be of type SignatureHelpClientCapabilities');
           return false;
         }
       } finally {
@@ -12578,10 +21258,9 @@
       reporter.push('declaration');
       try {
         if (obj['declaration'] != null &&
-            !(TextDocumentClientCapabilitiesDeclaration.canParse(
+            !(DeclarationClientCapabilities.canParse(
                 obj['declaration'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesDeclaration');
+          reporter.reportError('must be of type DeclarationClientCapabilities');
           return false;
         }
       } finally {
@@ -12590,10 +21269,9 @@
       reporter.push('definition');
       try {
         if (obj['definition'] != null &&
-            !(TextDocumentClientCapabilitiesDefinition.canParse(
+            !(DefinitionClientCapabilities.canParse(
                 obj['definition'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesDefinition');
+          reporter.reportError('must be of type DefinitionClientCapabilities');
           return false;
         }
       } finally {
@@ -12602,10 +21280,10 @@
       reporter.push('typeDefinition');
       try {
         if (obj['typeDefinition'] != null &&
-            !(TextDocumentClientCapabilitiesTypeDefinition.canParse(
+            !(TypeDefinitionClientCapabilities.canParse(
                 obj['typeDefinition'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesTypeDefinition');
+          reporter
+              .reportError('must be of type TypeDefinitionClientCapabilities');
           return false;
         }
       } finally {
@@ -12614,10 +21292,45 @@
       reporter.push('implementation');
       try {
         if (obj['implementation'] != null &&
-            !(TextDocumentClientCapabilitiesImplementation.canParse(
+            !(ImplementationClientCapabilities.canParse(
                 obj['implementation'], reporter))) {
+          reporter
+              .reportError('must be of type ImplementationClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('references');
+      try {
+        if (obj['references'] != null &&
+            !(ReferenceClientCapabilities.canParse(
+                obj['references'], reporter))) {
+          reporter.reportError('must be of type ReferenceClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('documentHighlight');
+      try {
+        if (obj['documentHighlight'] != null &&
+            !(DocumentHighlightClientCapabilities.canParse(
+                obj['documentHighlight'], reporter))) {
           reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesImplementation');
+              'must be of type DocumentHighlightClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('documentSymbol');
+      try {
+        if (obj['documentSymbol'] != null &&
+            !(DocumentSymbolClientCapabilities.canParse(
+                obj['documentSymbol'], reporter))) {
+          reporter
+              .reportError('must be of type DocumentSymbolClientCapabilities');
           return false;
         }
       } finally {
@@ -12626,10 +21339,9 @@
       reporter.push('codeAction');
       try {
         if (obj['codeAction'] != null &&
-            !(TextDocumentClientCapabilitiesCodeAction.canParse(
+            !(CodeActionClientCapabilities.canParse(
                 obj['codeAction'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCodeAction');
+          reporter.reportError('must be of type CodeActionClientCapabilities');
           return false;
         }
       } finally {
@@ -12638,10 +21350,8 @@
       reporter.push('codeLens');
       try {
         if (obj['codeLens'] != null &&
-            !(TextDocumentClientCapabilitiesCodeLens.canParse(
-                obj['codeLens'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCodeLens');
+            !(CodeLensClientCapabilities.canParse(obj['codeLens'], reporter))) {
+          reporter.reportError('must be of type CodeLensClientCapabilities');
           return false;
         }
       } finally {
@@ -12650,10 +21360,10 @@
       reporter.push('documentLink');
       try {
         if (obj['documentLink'] != null &&
-            !(TextDocumentClientCapabilitiesDocumentLink.canParse(
+            !(DocumentLinkClientCapabilities.canParse(
                 obj['documentLink'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesDocumentLink');
+          reporter
+              .reportError('must be of type DocumentLinkClientCapabilities');
           return false;
         }
       } finally {
@@ -12662,10 +21372,46 @@
       reporter.push('colorProvider');
       try {
         if (obj['colorProvider'] != null &&
-            !(TextDocumentClientCapabilitiesColorProvider.canParse(
+            !(DocumentColorClientCapabilities.canParse(
                 obj['colorProvider'], reporter))) {
+          reporter
+              .reportError('must be of type DocumentColorClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('formatting');
+      try {
+        if (obj['formatting'] != null &&
+            !(DocumentFormattingClientCapabilities.canParse(
+                obj['formatting'], reporter))) {
           reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesColorProvider');
+              'must be of type DocumentFormattingClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('rangeFormatting');
+      try {
+        if (obj['rangeFormatting'] != null &&
+            !(DocumentRangeFormattingClientCapabilities.canParse(
+                obj['rangeFormatting'], reporter))) {
+          reporter.reportError(
+              'must be of type DocumentRangeFormattingClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('onTypeFormatting');
+      try {
+        if (obj['onTypeFormatting'] != null &&
+            !(DocumentOnTypeFormattingClientCapabilities.canParse(
+                obj['onTypeFormatting'], reporter))) {
+          reporter.reportError(
+              'must be of type DocumentOnTypeFormattingClientCapabilities');
           return false;
         }
       } finally {
@@ -12674,10 +21420,8 @@
       reporter.push('rename');
       try {
         if (obj['rename'] != null &&
-            !(TextDocumentClientCapabilitiesRename.canParse(
-                obj['rename'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesRename');
+            !(RenameClientCapabilities.canParse(obj['rename'], reporter))) {
+          reporter.reportError('must be of type RenameClientCapabilities');
           return false;
         }
       } finally {
@@ -12686,10 +21430,10 @@
       reporter.push('publishDiagnostics');
       try {
         if (obj['publishDiagnostics'] != null &&
-            !(TextDocumentClientCapabilitiesPublishDiagnostics.canParse(
+            !(PublishDiagnosticsClientCapabilities.canParse(
                 obj['publishDiagnostics'], reporter))) {
           reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesPublishDiagnostics');
+              'must be of type PublishDiagnosticsClientCapabilities');
           return false;
         }
       } finally {
@@ -12698,10 +21442,22 @@
       reporter.push('foldingRange');
       try {
         if (obj['foldingRange'] != null &&
-            !(TextDocumentClientCapabilitiesFoldingRange.canParse(
+            !(FoldingRangeClientCapabilities.canParse(
                 obj['foldingRange'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesFoldingRange');
+          reporter
+              .reportError('must be of type FoldingRangeClientCapabilities');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('selectionRange');
+      try {
+        if (obj['selectionRange'] != null &&
+            !(SelectionRangeClientCapabilities.canParse(
+                obj['selectionRange'], reporter))) {
+          reporter
+              .reportError('must be of type SelectionRangeClientCapabilities');
           return false;
         }
       } finally {
@@ -12722,23 +21478,24 @@
           completion == other.completion &&
           hover == other.hover &&
           signatureHelp == other.signatureHelp &&
-          references == other.references &&
-          documentHighlight == other.documentHighlight &&
-          documentSymbol == other.documentSymbol &&
-          formatting == other.formatting &&
-          rangeFormatting == other.rangeFormatting &&
-          onTypeFormatting == other.onTypeFormatting &&
           declaration == other.declaration &&
           definition == other.definition &&
           typeDefinition == other.typeDefinition &&
           implementation == other.implementation &&
+          references == other.references &&
+          documentHighlight == other.documentHighlight &&
+          documentSymbol == other.documentSymbol &&
           codeAction == other.codeAction &&
           codeLens == other.codeLens &&
           documentLink == other.documentLink &&
           colorProvider == other.colorProvider &&
+          formatting == other.formatting &&
+          rangeFormatting == other.rangeFormatting &&
+          onTypeFormatting == other.onTypeFormatting &&
           rename == other.rename &&
           publishDiagnostics == other.publishDiagnostics &&
           foldingRange == other.foldingRange &&
+          selectionRange == other.selectionRange &&
           true;
     }
     return false;
@@ -12751,23 +21508,24 @@
     hash = JenkinsSmiHash.combine(hash, completion.hashCode);
     hash = JenkinsSmiHash.combine(hash, hover.hashCode);
     hash = JenkinsSmiHash.combine(hash, signatureHelp.hashCode);
-    hash = JenkinsSmiHash.combine(hash, references.hashCode);
-    hash = JenkinsSmiHash.combine(hash, documentHighlight.hashCode);
-    hash = JenkinsSmiHash.combine(hash, documentSymbol.hashCode);
-    hash = JenkinsSmiHash.combine(hash, formatting.hashCode);
-    hash = JenkinsSmiHash.combine(hash, rangeFormatting.hashCode);
-    hash = JenkinsSmiHash.combine(hash, onTypeFormatting.hashCode);
     hash = JenkinsSmiHash.combine(hash, declaration.hashCode);
     hash = JenkinsSmiHash.combine(hash, definition.hashCode);
     hash = JenkinsSmiHash.combine(hash, typeDefinition.hashCode);
     hash = JenkinsSmiHash.combine(hash, implementation.hashCode);
+    hash = JenkinsSmiHash.combine(hash, references.hashCode);
+    hash = JenkinsSmiHash.combine(hash, documentHighlight.hashCode);
+    hash = JenkinsSmiHash.combine(hash, documentSymbol.hashCode);
     hash = JenkinsSmiHash.combine(hash, codeAction.hashCode);
     hash = JenkinsSmiHash.combine(hash, codeLens.hashCode);
     hash = JenkinsSmiHash.combine(hash, documentLink.hashCode);
     hash = JenkinsSmiHash.combine(hash, colorProvider.hashCode);
+    hash = JenkinsSmiHash.combine(hash, formatting.hashCode);
+    hash = JenkinsSmiHash.combine(hash, rangeFormatting.hashCode);
+    hash = JenkinsSmiHash.combine(hash, onTypeFormatting.hashCode);
     hash = JenkinsSmiHash.combine(hash, rename.hashCode);
     hash = JenkinsSmiHash.combine(hash, publishDiagnostics.hashCode);
     hash = JenkinsSmiHash.combine(hash, foldingRange.hashCode);
+    hash = JenkinsSmiHash.combine(hash, selectionRange.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -12775,2441 +21533,42 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class TextDocumentClientCapabilitiesCodeAction implements ToJsonable {
+class TextDocumentContentChangeEvent1 implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCodeAction.canParse,
-      TextDocumentClientCapabilitiesCodeAction.fromJson);
+      TextDocumentContentChangeEvent1.canParse,
+      TextDocumentContentChangeEvent1.fromJson);
 
-  TextDocumentClientCapabilitiesCodeAction(
-      this.dynamicRegistration, this.codeActionLiteralSupport);
-  static TextDocumentClientCapabilitiesCodeAction fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final codeActionLiteralSupport = json['codeActionLiteralSupport'] != null
-        ? TextDocumentClientCapabilitiesCodeActionLiteralSupport.fromJson(
-            json['codeActionLiteralSupport'])
-        : null;
-    return TextDocumentClientCapabilitiesCodeAction(
-        dynamicRegistration, codeActionLiteralSupport);
-  }
-
-  /// The client support code action literals as a valid response of the
-  /// `textDocument/codeAction` request.
-  ///
-  /// Since 3.8.0
-  final TextDocumentClientCapabilitiesCodeActionLiteralSupport
-      codeActionLiteralSupport;
-
-  /// Whether code action supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (codeActionLiteralSupport != null) {
-      __result['codeActionLiteralSupport'] = codeActionLiteralSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('codeActionLiteralSupport');
-      try {
-        if (obj['codeActionLiteralSupport'] != null &&
-            !(TextDocumentClientCapabilitiesCodeActionLiteralSupport.canParse(
-                obj['codeActionLiteralSupport'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCodeActionLiteralSupport');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCodeAction');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCodeAction &&
-        other.runtimeType == TextDocumentClientCapabilitiesCodeAction) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          codeActionLiteralSupport == other.codeActionLiteralSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, codeActionLiteralSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCodeActionKind implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCodeActionKind.canParse,
-      TextDocumentClientCapabilitiesCodeActionKind.fromJson);
-
-  TextDocumentClientCapabilitiesCodeActionKind(this.valueSet) {
-    if (valueSet == null) {
-      throw 'valueSet is required but was not provided';
-    }
-  }
-  static TextDocumentClientCapabilitiesCodeActionKind fromJson(
-      Map<String, dynamic> json) {
-    final valueSet = json['valueSet']
-        ?.map((item) => item != null ? CodeActionKind.fromJson(item) : null)
-        ?.cast<CodeActionKind>()
-        ?.toList();
-    return TextDocumentClientCapabilitiesCodeActionKind(valueSet);
-  }
-
-  /// The code action kind values the client supports. When this property exists
-  /// the client also guarantees that it will handle values outside its set
-  /// gracefully and falls back to a default value when unknown.
-  final List<CodeActionKind> valueSet;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    __result['valueSet'] =
-        valueSet ?? (throw 'valueSet is required but was not set');
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('valueSet');
-      try {
-        if (!obj.containsKey('valueSet')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['valueSet'] == null) {
-          reporter.reportError('must not be null');
-          return false;
-        }
-        if (!((obj['valueSet'] is List &&
-            (obj['valueSet']
-                .every((item) => CodeActionKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<CodeActionKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCodeActionKind');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCodeActionKind &&
-        other.runtimeType == TextDocumentClientCapabilitiesCodeActionKind) {
-      return listEqual(valueSet, other.valueSet,
-              (CodeActionKind a, CodeActionKind b) => a == b) &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCodeActionLiteralSupport
-    implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCodeActionLiteralSupport.canParse,
-      TextDocumentClientCapabilitiesCodeActionLiteralSupport.fromJson);
-
-  TextDocumentClientCapabilitiesCodeActionLiteralSupport(this.codeActionKind) {
-    if (codeActionKind == null) {
-      throw 'codeActionKind is required but was not provided';
-    }
-  }
-  static TextDocumentClientCapabilitiesCodeActionLiteralSupport fromJson(
-      Map<String, dynamic> json) {
-    final codeActionKind = json['codeActionKind'] != null
-        ? TextDocumentClientCapabilitiesCodeActionKind.fromJson(
-            json['codeActionKind'])
-        : null;
-    return TextDocumentClientCapabilitiesCodeActionLiteralSupport(
-        codeActionKind);
-  }
-
-  /// The code action kind is support with the following value set.
-  final TextDocumentClientCapabilitiesCodeActionKind codeActionKind;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    __result['codeActionKind'] =
-        codeActionKind ?? (throw 'codeActionKind is required but was not set');
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('codeActionKind');
-      try {
-        if (!obj.containsKey('codeActionKind')) {
-          reporter.reportError('must not be undefined');
-          return false;
-        }
-        if (obj['codeActionKind'] == null) {
-          reporter.reportError('must not be null');
-          return false;
-        }
-        if (!(TextDocumentClientCapabilitiesCodeActionKind.canParse(
-            obj['codeActionKind'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCodeActionKind');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCodeActionLiteralSupport');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCodeActionLiteralSupport &&
-        other.runtimeType ==
-            TextDocumentClientCapabilitiesCodeActionLiteralSupport) {
-      return codeActionKind == other.codeActionKind && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, codeActionKind.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCodeLens implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCodeLens.canParse,
-      TextDocumentClientCapabilitiesCodeLens.fromJson);
-
-  TextDocumentClientCapabilitiesCodeLens(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesCodeLens fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesCodeLens(dynamicRegistration);
-  }
-
-  /// Whether code lens supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCodeLens');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCodeLens &&
-        other.runtimeType == TextDocumentClientCapabilitiesCodeLens) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesColorProvider implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesColorProvider.canParse,
-      TextDocumentClientCapabilitiesColorProvider.fromJson);
-
-  TextDocumentClientCapabilitiesColorProvider(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesColorProvider fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesColorProvider(dynamicRegistration);
-  }
-
-  /// Whether colorProvider supports dynamic registration. If this is set to
-  /// `true` the client supports the new `(ColorProviderOptions &
-  /// TextDocumentRegistrationOptions & StaticRegistrationOptions)` return value
-  /// for the corresponding server capability as well.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesColorProvider');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesColorProvider &&
-        other.runtimeType == TextDocumentClientCapabilitiesColorProvider) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCompletion implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCompletion.canParse,
-      TextDocumentClientCapabilitiesCompletion.fromJson);
-
-  TextDocumentClientCapabilitiesCompletion(this.dynamicRegistration,
-      this.completionItem, this.completionItemKind, this.contextSupport);
-  static TextDocumentClientCapabilitiesCompletion fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final completionItem = json['completionItem'] != null
-        ? TextDocumentClientCapabilitiesCompletionItem.fromJson(
-            json['completionItem'])
-        : null;
-    final completionItemKind = json['completionItemKind'] != null
-        ? TextDocumentClientCapabilitiesCompletionItemKind.fromJson(
-            json['completionItemKind'])
-        : null;
-    final contextSupport = json['contextSupport'];
-    return TextDocumentClientCapabilitiesCompletion(dynamicRegistration,
-        completionItem, completionItemKind, contextSupport);
-  }
-
-  /// The client supports the following `CompletionItem` specific capabilities.
-  final TextDocumentClientCapabilitiesCompletionItem completionItem;
-  final TextDocumentClientCapabilitiesCompletionItemKind completionItemKind;
-
-  /// The client supports to send additional context information for a
-  /// `textDocument/completion` request.
-  final bool contextSupport;
-
-  /// Whether completion supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (completionItem != null) {
-      __result['completionItem'] = completionItem;
-    }
-    if (completionItemKind != null) {
-      __result['completionItemKind'] = completionItemKind;
-    }
-    if (contextSupport != null) {
-      __result['contextSupport'] = contextSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('completionItem');
-      try {
-        if (obj['completionItem'] != null &&
-            !(TextDocumentClientCapabilitiesCompletionItem.canParse(
-                obj['completionItem'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCompletionItem');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('completionItemKind');
-      try {
-        if (obj['completionItemKind'] != null &&
-            !(TextDocumentClientCapabilitiesCompletionItemKind.canParse(
-                obj['completionItemKind'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesCompletionItemKind');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('contextSupport');
-      try {
-        if (obj['contextSupport'] != null && !(obj['contextSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCompletion');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCompletion &&
-        other.runtimeType == TextDocumentClientCapabilitiesCompletion) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          completionItem == other.completionItem &&
-          completionItemKind == other.completionItemKind &&
-          contextSupport == other.contextSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, completionItem.hashCode);
-    hash = JenkinsSmiHash.combine(hash, completionItemKind.hashCode);
-    hash = JenkinsSmiHash.combine(hash, contextSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCompletionItem implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCompletionItem.canParse,
-      TextDocumentClientCapabilitiesCompletionItem.fromJson);
-
-  TextDocumentClientCapabilitiesCompletionItem(
-      this.snippetSupport,
-      this.commitCharactersSupport,
-      this.documentationFormat,
-      this.deprecatedSupport,
-      this.preselectSupport);
-  static TextDocumentClientCapabilitiesCompletionItem fromJson(
-      Map<String, dynamic> json) {
-    final snippetSupport = json['snippetSupport'];
-    final commitCharactersSupport = json['commitCharactersSupport'];
-    final documentationFormat = json['documentationFormat']
-        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
-        ?.cast<MarkupKind>()
-        ?.toList();
-    final deprecatedSupport = json['deprecatedSupport'];
-    final preselectSupport = json['preselectSupport'];
-    return TextDocumentClientCapabilitiesCompletionItem(
-        snippetSupport,
-        commitCharactersSupport,
-        documentationFormat,
-        deprecatedSupport,
-        preselectSupport);
-  }
-
-  /// The client supports commit characters on a completion item.
-  final bool commitCharactersSupport;
-
-  /// The client supports the deprecated property on a completion item.
-  final bool deprecatedSupport;
-
-  /// The client supports the following content formats for the documentation
-  /// property. The order describes the preferred format of the client.
-  final List<MarkupKind> documentationFormat;
-
-  /// The client supports the preselect property on a completion item.
-  final bool preselectSupport;
-
-  /// The client supports snippets as insert text.
-  ///
-  /// A snippet can define tab stops and placeholders with `$1`, `$2` and
-  /// `${3:foo}`. `$0` defines the final tab stop, it defaults to the end of the
-  /// snippet. Placeholders with equal identifiers are linked, that is typing in
-  /// one will update others too.
-  final bool snippetSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (snippetSupport != null) {
-      __result['snippetSupport'] = snippetSupport;
-    }
-    if (commitCharactersSupport != null) {
-      __result['commitCharactersSupport'] = commitCharactersSupport;
-    }
-    if (documentationFormat != null) {
-      __result['documentationFormat'] = documentationFormat;
-    }
-    if (deprecatedSupport != null) {
-      __result['deprecatedSupport'] = deprecatedSupport;
-    }
-    if (preselectSupport != null) {
-      __result['preselectSupport'] = preselectSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('snippetSupport');
-      try {
-        if (obj['snippetSupport'] != null && !(obj['snippetSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('commitCharactersSupport');
-      try {
-        if (obj['commitCharactersSupport'] != null &&
-            !(obj['commitCharactersSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('documentationFormat');
-      try {
-        if (obj['documentationFormat'] != null &&
-            !((obj['documentationFormat'] is List &&
-                (obj['documentationFormat']
-                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<MarkupKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('deprecatedSupport');
-      try {
-        if (obj['deprecatedSupport'] != null &&
-            !(obj['deprecatedSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('preselectSupport');
-      try {
-        if (obj['preselectSupport'] != null &&
-            !(obj['preselectSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCompletionItem');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCompletionItem &&
-        other.runtimeType == TextDocumentClientCapabilitiesCompletionItem) {
-      return snippetSupport == other.snippetSupport &&
-          commitCharactersSupport == other.commitCharactersSupport &&
-          listEqual(documentationFormat, other.documentationFormat,
-              (MarkupKind a, MarkupKind b) => a == b) &&
-          deprecatedSupport == other.deprecatedSupport &&
-          preselectSupport == other.preselectSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, snippetSupport.hashCode);
-    hash = JenkinsSmiHash.combine(hash, commitCharactersSupport.hashCode);
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentationFormat));
-    hash = JenkinsSmiHash.combine(hash, deprecatedSupport.hashCode);
-    hash = JenkinsSmiHash.combine(hash, preselectSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesCompletionItemKind implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesCompletionItemKind.canParse,
-      TextDocumentClientCapabilitiesCompletionItemKind.fromJson);
-
-  TextDocumentClientCapabilitiesCompletionItemKind(this.valueSet);
-  static TextDocumentClientCapabilitiesCompletionItemKind fromJson(
-      Map<String, dynamic> json) {
-    final valueSet = json['valueSet']
-        ?.map((item) => item != null ? CompletionItemKind.fromJson(item) : null)
-        ?.cast<CompletionItemKind>()
-        ?.toList();
-    return TextDocumentClientCapabilitiesCompletionItemKind(valueSet);
-  }
-
-  /// The completion item kind values the client supports. When this property
-  /// exists the client also guarantees that it will handle values outside its
-  /// set gracefully and falls back to a default value when unknown.
-  ///
-  /// If this property is not present the client only supports the completion
-  /// items kinds from `Text` to `Reference` as defined in the initial version
-  /// of the protocol.
-  final List<CompletionItemKind> valueSet;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (valueSet != null) {
-      __result['valueSet'] = valueSet;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('valueSet');
-      try {
-        if (obj['valueSet'] != null &&
-            !((obj['valueSet'] is List &&
-                (obj['valueSet'].every(
-                    (item) => CompletionItemKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<CompletionItemKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesCompletionItemKind');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesCompletionItemKind &&
-        other.runtimeType == TextDocumentClientCapabilitiesCompletionItemKind) {
-      return listEqual(valueSet, other.valueSet,
-              (CompletionItemKind a, CompletionItemKind b) => a == b) &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesDeclaration implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesDeclaration.canParse,
-      TextDocumentClientCapabilitiesDeclaration.fromJson);
-
-  TextDocumentClientCapabilitiesDeclaration(
-      this.dynamicRegistration, this.linkSupport);
-  static TextDocumentClientCapabilitiesDeclaration fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final linkSupport = json['linkSupport'];
-    return TextDocumentClientCapabilitiesDeclaration(
-        dynamicRegistration, linkSupport);
-  }
-
-  /// Whether declaration supports dynamic registration. If this is set to
-  /// `true` the client supports the new `(TextDocumentRegistrationOptions &
-  /// StaticRegistrationOptions)` return value for the corresponding server
-  /// capability as well.
-  final bool dynamicRegistration;
-
-  /// The client supports additional metadata in the form of declaration links.
-  ///
-  /// Since 3.14.0
-  final bool linkSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (linkSupport != null) {
-      __result['linkSupport'] = linkSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('linkSupport');
-      try {
-        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesDeclaration');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesDeclaration &&
-        other.runtimeType == TextDocumentClientCapabilitiesDeclaration) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          linkSupport == other.linkSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesDefinition implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesDefinition.canParse,
-      TextDocumentClientCapabilitiesDefinition.fromJson);
-
-  TextDocumentClientCapabilitiesDefinition(
-      this.dynamicRegistration, this.linkSupport);
-  static TextDocumentClientCapabilitiesDefinition fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final linkSupport = json['linkSupport'];
-    return TextDocumentClientCapabilitiesDefinition(
-        dynamicRegistration, linkSupport);
-  }
-
-  /// Whether definition supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// The client supports additional metadata in the form of definition links.
-  final bool linkSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (linkSupport != null) {
-      __result['linkSupport'] = linkSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('linkSupport');
-      try {
-        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesDefinition');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesDefinition &&
-        other.runtimeType == TextDocumentClientCapabilitiesDefinition) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          linkSupport == other.linkSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesDocumentHighlight implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesDocumentHighlight.canParse,
-      TextDocumentClientCapabilitiesDocumentHighlight.fromJson);
-
-  TextDocumentClientCapabilitiesDocumentHighlight(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesDocumentHighlight fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesDocumentHighlight(dynamicRegistration);
-  }
-
-  /// Whether document highlight supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesDocumentHighlight');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesDocumentHighlight &&
-        other.runtimeType == TextDocumentClientCapabilitiesDocumentHighlight) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesDocumentLink implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesDocumentLink.canParse,
-      TextDocumentClientCapabilitiesDocumentLink.fromJson);
-
-  TextDocumentClientCapabilitiesDocumentLink(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesDocumentLink fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesDocumentLink(dynamicRegistration);
-  }
-
-  /// Whether document link supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesDocumentLink');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesDocumentLink &&
-        other.runtimeType == TextDocumentClientCapabilitiesDocumentLink) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesDocumentSymbol implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesDocumentSymbol.canParse,
-      TextDocumentClientCapabilitiesDocumentSymbol.fromJson);
-
-  TextDocumentClientCapabilitiesDocumentSymbol(this.dynamicRegistration,
-      this.symbolKind, this.hierarchicalDocumentSymbolSupport);
-  static TextDocumentClientCapabilitiesDocumentSymbol fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final symbolKind = json['symbolKind'] != null
-        ? TextDocumentClientCapabilitiesSymbolKind.fromJson(json['symbolKind'])
-        : null;
-    final hierarchicalDocumentSymbolSupport =
-        json['hierarchicalDocumentSymbolSupport'];
-    return TextDocumentClientCapabilitiesDocumentSymbol(
-        dynamicRegistration, symbolKind, hierarchicalDocumentSymbolSupport);
-  }
-
-  /// Whether document symbol supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// The client supports hierarchical document symbols.
-  final bool hierarchicalDocumentSymbolSupport;
-
-  /// Specific capabilities for the `SymbolKind`.
-  final TextDocumentClientCapabilitiesSymbolKind symbolKind;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (symbolKind != null) {
-      __result['symbolKind'] = symbolKind;
-    }
-    if (hierarchicalDocumentSymbolSupport != null) {
-      __result['hierarchicalDocumentSymbolSupport'] =
-          hierarchicalDocumentSymbolSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('symbolKind');
-      try {
-        if (obj['symbolKind'] != null &&
-            !(TextDocumentClientCapabilitiesSymbolKind.canParse(
-                obj['symbolKind'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesSymbolKind');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('hierarchicalDocumentSymbolSupport');
-      try {
-        if (obj['hierarchicalDocumentSymbolSupport'] != null &&
-            !(obj['hierarchicalDocumentSymbolSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesDocumentSymbol');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesDocumentSymbol &&
-        other.runtimeType == TextDocumentClientCapabilitiesDocumentSymbol) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          symbolKind == other.symbolKind &&
-          hierarchicalDocumentSymbolSupport ==
-              other.hierarchicalDocumentSymbolSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, symbolKind.hashCode);
-    hash = JenkinsSmiHash.combine(
-        hash, hierarchicalDocumentSymbolSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesFoldingRange implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesFoldingRange.canParse,
-      TextDocumentClientCapabilitiesFoldingRange.fromJson);
-
-  TextDocumentClientCapabilitiesFoldingRange(
-      this.dynamicRegistration, this.rangeLimit, this.lineFoldingOnly);
-  static TextDocumentClientCapabilitiesFoldingRange fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final rangeLimit = json['rangeLimit'];
-    final lineFoldingOnly = json['lineFoldingOnly'];
-    return TextDocumentClientCapabilitiesFoldingRange(
-        dynamicRegistration, rangeLimit, lineFoldingOnly);
-  }
-
-  /// Whether implementation supports dynamic registration for folding range
-  /// providers. If this is set to `true` the client supports the new
-  /// `(FoldingRangeProviderOptions & TextDocumentRegistrationOptions &
-  /// StaticRegistrationOptions)` return value for the corresponding server
-  /// capability as well.
-  final bool dynamicRegistration;
-
-  /// If set, the client signals that it only supports folding complete lines.
-  /// If set, client will ignore specified `startCharacter` and `endCharacter`
-  /// properties in a FoldingRange.
-  final bool lineFoldingOnly;
-
-  /// The maximum number of folding ranges that the client prefers to receive
-  /// per document. The value serves as a hint, servers are free to follow the
-  /// limit.
-  final num rangeLimit;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (rangeLimit != null) {
-      __result['rangeLimit'] = rangeLimit;
-    }
-    if (lineFoldingOnly != null) {
-      __result['lineFoldingOnly'] = lineFoldingOnly;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('rangeLimit');
-      try {
-        if (obj['rangeLimit'] != null && !(obj['rangeLimit'] is num)) {
-          reporter.reportError('must be of type num');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('lineFoldingOnly');
-      try {
-        if (obj['lineFoldingOnly'] != null &&
-            !(obj['lineFoldingOnly'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesFoldingRange');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesFoldingRange &&
-        other.runtimeType == TextDocumentClientCapabilitiesFoldingRange) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          rangeLimit == other.rangeLimit &&
-          lineFoldingOnly == other.lineFoldingOnly &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, rangeLimit.hashCode);
-    hash = JenkinsSmiHash.combine(hash, lineFoldingOnly.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesFormatting implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesFormatting.canParse,
-      TextDocumentClientCapabilitiesFormatting.fromJson);
-
-  TextDocumentClientCapabilitiesFormatting(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesFormatting fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesFormatting(dynamicRegistration);
-  }
-
-  /// Whether formatting supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesFormatting');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesFormatting &&
-        other.runtimeType == TextDocumentClientCapabilitiesFormatting) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesHover implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesHover.canParse,
-      TextDocumentClientCapabilitiesHover.fromJson);
-
-  TextDocumentClientCapabilitiesHover(
-      this.dynamicRegistration, this.contentFormat);
-  static TextDocumentClientCapabilitiesHover fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final contentFormat = json['contentFormat']
-        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
-        ?.cast<MarkupKind>()
-        ?.toList();
-    return TextDocumentClientCapabilitiesHover(
-        dynamicRegistration, contentFormat);
-  }
-
-  /// The client supports the follow content formats for the content property.
-  /// The order describes the preferred format of the client.
-  final List<MarkupKind> contentFormat;
-
-  /// Whether hover supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (contentFormat != null) {
-      __result['contentFormat'] = contentFormat;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('contentFormat');
-      try {
-        if (obj['contentFormat'] != null &&
-            !((obj['contentFormat'] is List &&
-                (obj['contentFormat']
-                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<MarkupKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter
-          .reportError('must be of type TextDocumentClientCapabilitiesHover');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesHover &&
-        other.runtimeType == TextDocumentClientCapabilitiesHover) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          listEqual(contentFormat, other.contentFormat,
-              (MarkupKind a, MarkupKind b) => a == b) &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(contentFormat));
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesImplementation implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesImplementation.canParse,
-      TextDocumentClientCapabilitiesImplementation.fromJson);
-
-  TextDocumentClientCapabilitiesImplementation(
-      this.dynamicRegistration, this.linkSupport);
-  static TextDocumentClientCapabilitiesImplementation fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final linkSupport = json['linkSupport'];
-    return TextDocumentClientCapabilitiesImplementation(
-        dynamicRegistration, linkSupport);
-  }
-
-  /// Whether implementation supports dynamic registration. If this is set to
-  /// `true` the client supports the new `(TextDocumentRegistrationOptions &
-  /// StaticRegistrationOptions)` return value for the corresponding server
-  /// capability as well.
-  final bool dynamicRegistration;
-
-  /// The client supports additional metadata in the form of definition links.
-  ///
-  /// Since 3.14.0
-  final bool linkSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (linkSupport != null) {
-      __result['linkSupport'] = linkSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('linkSupport');
-      try {
-        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesImplementation');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesImplementation &&
-        other.runtimeType == TextDocumentClientCapabilitiesImplementation) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          linkSupport == other.linkSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesOnTypeFormatting implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesOnTypeFormatting.canParse,
-      TextDocumentClientCapabilitiesOnTypeFormatting.fromJson);
-
-  TextDocumentClientCapabilitiesOnTypeFormatting(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesOnTypeFormatting fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesOnTypeFormatting(dynamicRegistration);
-  }
-
-  /// Whether on type formatting supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesOnTypeFormatting');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesOnTypeFormatting &&
-        other.runtimeType == TextDocumentClientCapabilitiesOnTypeFormatting) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesParameterInformation implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesParameterInformation.canParse,
-      TextDocumentClientCapabilitiesParameterInformation.fromJson);
-
-  TextDocumentClientCapabilitiesParameterInformation(this.labelOffsetSupport);
-  static TextDocumentClientCapabilitiesParameterInformation fromJson(
-      Map<String, dynamic> json) {
-    final labelOffsetSupport = json['labelOffsetSupport'];
-    return TextDocumentClientCapabilitiesParameterInformation(
-        labelOffsetSupport);
-  }
-
-  /// The client supports processing label offsets instead of a simple label
-  /// string.
-  ///
-  /// Since 3.14.0
-  final bool labelOffsetSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (labelOffsetSupport != null) {
-      __result['labelOffsetSupport'] = labelOffsetSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('labelOffsetSupport');
-      try {
-        if (obj['labelOffsetSupport'] != null &&
-            !(obj['labelOffsetSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesParameterInformation');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesParameterInformation &&
-        other.runtimeType ==
-            TextDocumentClientCapabilitiesParameterInformation) {
-      return labelOffsetSupport == other.labelOffsetSupport && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, labelOffsetSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesPublishDiagnostics implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesPublishDiagnostics.canParse,
-      TextDocumentClientCapabilitiesPublishDiagnostics.fromJson);
-
-  TextDocumentClientCapabilitiesPublishDiagnostics(this.relatedInformation);
-  static TextDocumentClientCapabilitiesPublishDiagnostics fromJson(
-      Map<String, dynamic> json) {
-    final relatedInformation = json['relatedInformation'];
-    return TextDocumentClientCapabilitiesPublishDiagnostics(relatedInformation);
-  }
-
-  /// Whether the clients accepts diagnostics with related information.
-  final bool relatedInformation;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (relatedInformation != null) {
-      __result['relatedInformation'] = relatedInformation;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('relatedInformation');
-      try {
-        if (obj['relatedInformation'] != null &&
-            !(obj['relatedInformation'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesPublishDiagnostics');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesPublishDiagnostics &&
-        other.runtimeType == TextDocumentClientCapabilitiesPublishDiagnostics) {
-      return relatedInformation == other.relatedInformation && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, relatedInformation.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesRangeFormatting implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesRangeFormatting.canParse,
-      TextDocumentClientCapabilitiesRangeFormatting.fromJson);
-
-  TextDocumentClientCapabilitiesRangeFormatting(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesRangeFormatting fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesRangeFormatting(dynamicRegistration);
-  }
-
-  /// Whether range formatting supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesRangeFormatting');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesRangeFormatting &&
-        other.runtimeType == TextDocumentClientCapabilitiesRangeFormatting) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesReferences implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesReferences.canParse,
-      TextDocumentClientCapabilitiesReferences.fromJson);
-
-  TextDocumentClientCapabilitiesReferences(this.dynamicRegistration);
-  static TextDocumentClientCapabilitiesReferences fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return TextDocumentClientCapabilitiesReferences(dynamicRegistration);
-  }
-
-  /// Whether references supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesReferences');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesReferences &&
-        other.runtimeType == TextDocumentClientCapabilitiesReferences) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesRename implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesRename.canParse,
-      TextDocumentClientCapabilitiesRename.fromJson);
-
-  TextDocumentClientCapabilitiesRename(
-      this.dynamicRegistration, this.prepareSupport);
-  static TextDocumentClientCapabilitiesRename fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final prepareSupport = json['prepareSupport'];
-    return TextDocumentClientCapabilitiesRename(
-        dynamicRegistration, prepareSupport);
-  }
-
-  /// Whether rename supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// The client supports testing for validity of rename operations before
-  /// execution.
-  final bool prepareSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (prepareSupport != null) {
-      __result['prepareSupport'] = prepareSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('prepareSupport');
-      try {
-        if (obj['prepareSupport'] != null && !(obj['prepareSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter
-          .reportError('must be of type TextDocumentClientCapabilitiesRename');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesRename &&
-        other.runtimeType == TextDocumentClientCapabilitiesRename) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          prepareSupport == other.prepareSupport &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, prepareSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesSignatureHelp implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesSignatureHelp.canParse,
-      TextDocumentClientCapabilitiesSignatureHelp.fromJson);
-
-  TextDocumentClientCapabilitiesSignatureHelp(
-      this.dynamicRegistration, this.signatureInformation);
-  static TextDocumentClientCapabilitiesSignatureHelp fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final signatureInformation = json['signatureInformation'] != null
-        ? TextDocumentClientCapabilitiesSignatureInformation.fromJson(
-            json['signatureInformation'])
-        : null;
-    return TextDocumentClientCapabilitiesSignatureHelp(
-        dynamicRegistration, signatureInformation);
-  }
-
-  /// Whether signature help supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// The client supports the following `SignatureInformation` specific
-  /// properties.
-  final TextDocumentClientCapabilitiesSignatureInformation signatureInformation;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (signatureInformation != null) {
-      __result['signatureInformation'] = signatureInformation;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('signatureInformation');
-      try {
-        if (obj['signatureInformation'] != null &&
-            !(TextDocumentClientCapabilitiesSignatureInformation.canParse(
-                obj['signatureInformation'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesSignatureInformation');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesSignatureHelp');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesSignatureHelp &&
-        other.runtimeType == TextDocumentClientCapabilitiesSignatureHelp) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          signatureInformation == other.signatureInformation &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, signatureInformation.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesSignatureInformation implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesSignatureInformation.canParse,
-      TextDocumentClientCapabilitiesSignatureInformation.fromJson);
-
-  TextDocumentClientCapabilitiesSignatureInformation(
-      this.documentationFormat, this.parameterInformation);
-  static TextDocumentClientCapabilitiesSignatureInformation fromJson(
-      Map<String, dynamic> json) {
-    final documentationFormat = json['documentationFormat']
-        ?.map((item) => item != null ? MarkupKind.fromJson(item) : null)
-        ?.cast<MarkupKind>()
-        ?.toList();
-    final parameterInformation = json['parameterInformation'] != null
-        ? TextDocumentClientCapabilitiesParameterInformation.fromJson(
-            json['parameterInformation'])
-        : null;
-    return TextDocumentClientCapabilitiesSignatureInformation(
-        documentationFormat, parameterInformation);
-  }
-
-  /// The client supports the follow content formats for the documentation
-  /// property. The order describes the preferred format of the client.
-  final List<MarkupKind> documentationFormat;
-
-  /// Client capabilities specific to parameter information.
-  final TextDocumentClientCapabilitiesParameterInformation parameterInformation;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (documentationFormat != null) {
-      __result['documentationFormat'] = documentationFormat;
-    }
-    if (parameterInformation != null) {
-      __result['parameterInformation'] = parameterInformation;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('documentationFormat');
-      try {
-        if (obj['documentationFormat'] != null &&
-            !((obj['documentationFormat'] is List &&
-                (obj['documentationFormat']
-                    .every((item) => MarkupKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<MarkupKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('parameterInformation');
-      try {
-        if (obj['parameterInformation'] != null &&
-            !(TextDocumentClientCapabilitiesParameterInformation.canParse(
-                obj['parameterInformation'], reporter))) {
-          reporter.reportError(
-              'must be of type TextDocumentClientCapabilitiesParameterInformation');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesSignatureInformation');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesSignatureInformation &&
-        other.runtimeType ==
-            TextDocumentClientCapabilitiesSignatureInformation) {
-      return listEqual(documentationFormat, other.documentationFormat,
-              (MarkupKind a, MarkupKind b) => a == b) &&
-          parameterInformation == other.parameterInformation &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentationFormat));
-    hash = JenkinsSmiHash.combine(hash, parameterInformation.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesSymbolKind implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesSymbolKind.canParse,
-      TextDocumentClientCapabilitiesSymbolKind.fromJson);
-
-  TextDocumentClientCapabilitiesSymbolKind(this.valueSet);
-  static TextDocumentClientCapabilitiesSymbolKind fromJson(
-      Map<String, dynamic> json) {
-    final valueSet = json['valueSet']
-        ?.map((item) => item != null ? SymbolKind.fromJson(item) : null)
-        ?.cast<SymbolKind>()
-        ?.toList();
-    return TextDocumentClientCapabilitiesSymbolKind(valueSet);
-  }
-
-  /// The symbol kind values the client supports. When this property exists the
-  /// client also guarantees that it will handle values outside its set
-  /// gracefully and falls back to a default value when unknown.
-  ///
-  /// If this property is not present the client only supports the symbol kinds
-  /// from `File` to `Array` as defined in the initial version of the protocol.
-  final List<SymbolKind> valueSet;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (valueSet != null) {
-      __result['valueSet'] = valueSet;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('valueSet');
-      try {
-        if (obj['valueSet'] != null &&
-            !((obj['valueSet'] is List &&
-                (obj['valueSet']
-                    .every((item) => SymbolKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<SymbolKind>');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesSymbolKind');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesSymbolKind &&
-        other.runtimeType == TextDocumentClientCapabilitiesSymbolKind) {
-      return listEqual(valueSet, other.valueSet,
-              (SymbolKind a, SymbolKind b) => a == b) &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesSynchronization implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesSynchronization.canParse,
-      TextDocumentClientCapabilitiesSynchronization.fromJson);
-
-  TextDocumentClientCapabilitiesSynchronization(this.dynamicRegistration,
-      this.willSave, this.willSaveWaitUntil, this.didSave);
-  static TextDocumentClientCapabilitiesSynchronization fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final willSave = json['willSave'];
-    final willSaveWaitUntil = json['willSaveWaitUntil'];
-    final didSave = json['didSave'];
-    return TextDocumentClientCapabilitiesSynchronization(
-        dynamicRegistration, willSave, willSaveWaitUntil, didSave);
-  }
-
-  /// The client supports did save notifications.
-  final bool didSave;
-
-  /// Whether text document synchronization supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// The client supports sending will save notifications.
-  final bool willSave;
-
-  /// The client supports sending a will save request and waits for a response
-  /// providing text edits which will be applied to the document before it is
-  /// saved.
-  final bool willSaveWaitUntil;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (willSave != null) {
-      __result['willSave'] = willSave;
-    }
-    if (willSaveWaitUntil != null) {
-      __result['willSaveWaitUntil'] = willSaveWaitUntil;
-    }
-    if (didSave != null) {
-      __result['didSave'] = didSave;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('willSave');
-      try {
-        if (obj['willSave'] != null && !(obj['willSave'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('willSaveWaitUntil');
-      try {
-        if (obj['willSaveWaitUntil'] != null &&
-            !(obj['willSaveWaitUntil'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('didSave');
-      try {
-        if (obj['didSave'] != null && !(obj['didSave'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesSynchronization');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesSynchronization &&
-        other.runtimeType == TextDocumentClientCapabilitiesSynchronization) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          willSave == other.willSave &&
-          willSaveWaitUntil == other.willSaveWaitUntil &&
-          didSave == other.didSave &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, willSave.hashCode);
-    hash = JenkinsSmiHash.combine(hash, willSaveWaitUntil.hashCode);
-    hash = JenkinsSmiHash.combine(hash, didSave.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class TextDocumentClientCapabilitiesTypeDefinition implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentClientCapabilitiesTypeDefinition.canParse,
-      TextDocumentClientCapabilitiesTypeDefinition.fromJson);
-
-  TextDocumentClientCapabilitiesTypeDefinition(
-      this.dynamicRegistration, this.linkSupport);
-  static TextDocumentClientCapabilitiesTypeDefinition fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final linkSupport = json['linkSupport'];
-    return TextDocumentClientCapabilitiesTypeDefinition(
-        dynamicRegistration, linkSupport);
-  }
-
-  /// Whether typeDefinition supports dynamic registration. If this is set to
-  /// `true` the client supports the new `(TextDocumentRegistrationOptions &
-  /// StaticRegistrationOptions)` return value for the corresponding server
-  /// capability as well.
-  final bool dynamicRegistration;
-
-  /// The client supports additional metadata in the form of definition links.
-  ///
-  /// Since 3.14.0
-  final bool linkSupport;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (linkSupport != null) {
-      __result['linkSupport'] = linkSupport;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('linkSupport');
-      try {
-        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type TextDocumentClientCapabilitiesTypeDefinition');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is TextDocumentClientCapabilitiesTypeDefinition &&
-        other.runtimeType == TextDocumentClientCapabilitiesTypeDefinition) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          linkSupport == other.linkSupport &&
-          true;
+  TextDocumentContentChangeEvent1(
+      {@required this.range, this.rangeLength, @required this.text}) {
+    if (range == null) {
+      throw 'range is required but was not provided';
     }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-/// An event describing a change to a text document. If range and rangeLength
-/// are omitted the new text is considered to be the full content of the
-/// document.
-class TextDocumentContentChangeEvent implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      TextDocumentContentChangeEvent.canParse,
-      TextDocumentContentChangeEvent.fromJson);
-
-  TextDocumentContentChangeEvent(this.range, this.rangeLength, this.text) {
     if (text == null) {
       throw 'text is required but was not provided';
     }
   }
-  static TextDocumentContentChangeEvent fromJson(Map<String, dynamic> json) {
+  static TextDocumentContentChangeEvent1 fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final rangeLength = json['rangeLength'];
     final text = json['text'];
-    return TextDocumentContentChangeEvent(range, rangeLength, text);
+    return TextDocumentContentChangeEvent1(
+        range: range, rangeLength: rangeLength, text: text);
   }
 
   /// The range of the document that changed.
   final Range range;
 
-  /// The length of the range that got replaced.
+  /// The optional length of the range that got replaced.
+  ///  @deprecated use range instead.
+  @core.deprecated
   final num rangeLength;
 
-  /// The new text of the range/document.
+  /// The new text for the provided range.
   final String text;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
-    if (range != null) {
-      __result['range'] = range;
-    }
+    __result['range'] = range ?? (throw 'range is required but was not set');
     if (rangeLength != null) {
       __result['rangeLength'] = rangeLength;
     }
@@ -15221,7 +21580,15 @@
     if (obj is Map<String, dynamic>) {
       reporter.push('range');
       try {
-        if (obj['range'] != null && !(Range.canParse(obj['range'], reporter))) {
+        if (!obj.containsKey('range')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['range'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Range.canParse(obj['range'], reporter))) {
           reporter.reportError('must be of type Range');
           return false;
         }
@@ -15256,15 +21623,15 @@
       }
       return true;
     } else {
-      reporter.reportError('must be of type TextDocumentContentChangeEvent');
+      reporter.reportError('must be of type TextDocumentContentChangeEvent1');
       return false;
     }
   }
 
   @override
   bool operator ==(Object other) {
-    if (other is TextDocumentContentChangeEvent &&
-        other.runtimeType == TextDocumentContentChangeEvent) {
+    if (other is TextDocumentContentChangeEvent1 &&
+        other.runtimeType == TextDocumentContentChangeEvent1) {
       return range == other.range &&
           rangeLength == other.rangeLength &&
           text == other.text &&
@@ -15286,11 +21653,81 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class TextDocumentContentChangeEvent2 implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TextDocumentContentChangeEvent2.canParse,
+      TextDocumentContentChangeEvent2.fromJson);
+
+  TextDocumentContentChangeEvent2({@required this.text}) {
+    if (text == null) {
+      throw 'text is required but was not provided';
+    }
+  }
+  static TextDocumentContentChangeEvent2 fromJson(Map<String, dynamic> json) {
+    final text = json['text'];
+    return TextDocumentContentChangeEvent2(text: text);
+  }
+
+  /// The new text of the whole document.
+  final String text;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['text'] = text ?? (throw 'text is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('text');
+      try {
+        if (!obj.containsKey('text')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['text'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['text'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type TextDocumentContentChangeEvent2');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TextDocumentContentChangeEvent2 &&
+        other.runtimeType == TextDocumentContentChangeEvent2) {
+      return text == other.text && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, text.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class TextDocumentEdit implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(TextDocumentEdit.canParse, TextDocumentEdit.fromJson);
 
-  TextDocumentEdit(this.textDocument, this.edits) {
+  TextDocumentEdit({@required this.textDocument, @required this.edits}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -15306,7 +21743,7 @@
         ?.map((item) => item != null ? TextEdit.fromJson(item) : null)
         ?.cast<TextEdit>()
         ?.toList();
-    return TextDocumentEdit(textDocument, edits);
+    return TextDocumentEdit(textDocument: textDocument, edits: edits);
   }
 
   /// The edits to be applied.
@@ -15396,7 +21833,7 @@
   static const jsonHandler = LspJsonHandler(
       TextDocumentIdentifier.canParse, TextDocumentIdentifier.fromJson);
 
-  TextDocumentIdentifier(this.uri) {
+  TextDocumentIdentifier({@required this.uri}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -15406,7 +21843,7 @@
       return VersionedTextDocumentIdentifier.fromJson(json);
     }
     final uri = json['uri'];
-    return TextDocumentIdentifier(uri);
+    return TextDocumentIdentifier(uri: uri);
   }
 
   /// The text document's URI.
@@ -15468,7 +21905,11 @@
   static const jsonHandler =
       LspJsonHandler(TextDocumentItem.canParse, TextDocumentItem.fromJson);
 
-  TextDocumentItem(this.uri, this.languageId, this.version, this.text) {
+  TextDocumentItem(
+      {@required this.uri,
+      @required this.languageId,
+      @required this.version,
+      @required this.text}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -15487,7 +21928,8 @@
     final languageId = json['languageId'];
     final version = json['version'];
     final text = json['text'];
-    return TextDocumentItem(uri, languageId, version, text);
+    return TextDocumentItem(
+        uri: uri, languageId: languageId, version: version, text: text);
   }
 
   /// The text document's language identifier.
@@ -15621,7 +22063,8 @@
   static const jsonHandler = LspJsonHandler(
       TextDocumentPositionParams.canParse, TextDocumentPositionParams.fromJson);
 
-  TextDocumentPositionParams(this.textDocument, this.position) {
+  TextDocumentPositionParams(
+      {@required this.textDocument, @required this.position}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -15633,15 +22076,46 @@
     if (CompletionParams.canParse(json, nullLspJsonReporter)) {
       return CompletionParams.fromJson(json);
     }
+    if (HoverParams.canParse(json, nullLspJsonReporter)) {
+      return HoverParams.fromJson(json);
+    }
+    if (SignatureHelpParams.canParse(json, nullLspJsonReporter)) {
+      return SignatureHelpParams.fromJson(json);
+    }
+    if (DeclarationParams.canParse(json, nullLspJsonReporter)) {
+      return DeclarationParams.fromJson(json);
+    }
+    if (DefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return DefinitionParams.fromJson(json);
+    }
+    if (TypeDefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionParams.fromJson(json);
+    }
+    if (ImplementationParams.canParse(json, nullLspJsonReporter)) {
+      return ImplementationParams.fromJson(json);
+    }
     if (ReferenceParams.canParse(json, nullLspJsonReporter)) {
       return ReferenceParams.fromJson(json);
     }
+    if (DocumentHighlightParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentHighlightParams.fromJson(json);
+    }
+    if (DocumentOnTypeFormattingParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentOnTypeFormattingParams.fromJson(json);
+    }
+    if (RenameParams.canParse(json, nullLspJsonReporter)) {
+      return RenameParams.fromJson(json);
+    }
+    if (PrepareRenameParams.canParse(json, nullLspJsonReporter)) {
+      return PrepareRenameParams.fromJson(json);
+    }
     final textDocument = json['textDocument'] != null
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final position =
         json['position'] != null ? Position.fromJson(json['position']) : null;
-    return TextDocumentPositionParams(textDocument, position);
+    return TextDocumentPositionParams(
+        textDocument: textDocument, position: position);
   }
 
   /// The position inside the text document.
@@ -15725,12 +22199,13 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+/// General text document registration options.
 class TextDocumentRegistrationOptions implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
       TextDocumentRegistrationOptions.canParse,
       TextDocumentRegistrationOptions.fromJson);
 
-  TextDocumentRegistrationOptions(this.documentSelector);
+  TextDocumentRegistrationOptions({this.documentSelector});
   static TextDocumentRegistrationOptions fromJson(Map<String, dynamic> json) {
     if (TextDocumentChangeRegistrationOptions.canParse(
         json, nullLspJsonReporter)) {
@@ -15743,9 +22218,34 @@
     if (CompletionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return CompletionRegistrationOptions.fromJson(json);
     }
+    if (HoverRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return HoverRegistrationOptions.fromJson(json);
+    }
     if (SignatureHelpRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return SignatureHelpRegistrationOptions.fromJson(json);
     }
+    if (DeclarationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DeclarationRegistrationOptions.fromJson(json);
+    }
+    if (DefinitionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DefinitionRegistrationOptions.fromJson(json);
+    }
+    if (TypeDefinitionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionRegistrationOptions.fromJson(json);
+    }
+    if (ImplementationRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ImplementationRegistrationOptions.fromJson(json);
+    }
+    if (ReferenceRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return ReferenceRegistrationOptions.fromJson(json);
+    }
+    if (DocumentHighlightRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentHighlightRegistrationOptions.fromJson(json);
+    }
+    if (DocumentSymbolRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentSymbolRegistrationOptions.fromJson(json);
+    }
     if (CodeActionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return CodeActionRegistrationOptions.fromJson(json);
     }
@@ -15755,6 +22255,17 @@
     if (DocumentLinkRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return DocumentLinkRegistrationOptions.fromJson(json);
     }
+    if (DocumentColorRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorRegistrationOptions.fromJson(json);
+    }
+    if (DocumentFormattingRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentFormattingRegistrationOptions.fromJson(json);
+    }
+    if (DocumentRangeFormattingRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return DocumentRangeFormattingRegistrationOptions.fromJson(json);
+    }
     if (DocumentOnTypeFormattingRegistrationOptions.canParse(
         json, nullLspJsonReporter)) {
       return DocumentOnTypeFormattingRegistrationOptions.fromJson(json);
@@ -15762,11 +22273,17 @@
     if (RenameRegistrationOptions.canParse(json, nullLspJsonReporter)) {
       return RenameRegistrationOptions.fromJson(json);
     }
+    if (FoldingRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeRegistrationOptions.fromJson(json);
+    }
+    if (SelectionRangeRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeRegistrationOptions.fromJson(json);
+    }
     final documentSelector = json['documentSelector']
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return TextDocumentRegistrationOptions(documentSelector);
+    return TextDocumentRegistrationOptions(documentSelector: documentSelector);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -15865,7 +22382,8 @@
       TextDocumentSaveRegistrationOptions.canParse,
       TextDocumentSaveRegistrationOptions.fromJson);
 
-  TextDocumentSaveRegistrationOptions(this.includeText, this.documentSelector);
+  TextDocumentSaveRegistrationOptions(
+      {this.includeText, this.documentSelector});
   static TextDocumentSaveRegistrationOptions fromJson(
       Map<String, dynamic> json) {
     final includeText = json['includeText'];
@@ -15873,7 +22391,8 @@
         ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
         ?.cast<DocumentFilter>()
         ?.toList();
-    return TextDocumentSaveRegistrationOptions(includeText, documentSelector);
+    return TextDocumentSaveRegistrationOptions(
+        includeText: includeText, documentSelector: documentSelector);
   }
 
   /// A document selector to identify the scope of the registration. If set to
@@ -15951,6 +22470,135 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class TextDocumentSyncClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TextDocumentSyncClientCapabilities.canParse,
+      TextDocumentSyncClientCapabilities.fromJson);
+
+  TextDocumentSyncClientCapabilities(
+      {this.dynamicRegistration,
+      this.willSave,
+      this.willSaveWaitUntil,
+      this.didSave});
+  static TextDocumentSyncClientCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final willSave = json['willSave'];
+    final willSaveWaitUntil = json['willSaveWaitUntil'];
+    final didSave = json['didSave'];
+    return TextDocumentSyncClientCapabilities(
+        dynamicRegistration: dynamicRegistration,
+        willSave: willSave,
+        willSaveWaitUntil: willSaveWaitUntil,
+        didSave: didSave);
+  }
+
+  /// The client supports did save notifications.
+  final bool didSave;
+
+  /// Whether text document synchronization supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// The client supports sending will save notifications.
+  final bool willSave;
+
+  /// The client supports sending a will save request and waits for a response
+  /// providing text edits which will be applied to the document before it is
+  /// saved.
+  final bool willSaveWaitUntil;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (willSave != null) {
+      __result['willSave'] = willSave;
+    }
+    if (willSaveWaitUntil != null) {
+      __result['willSaveWaitUntil'] = willSaveWaitUntil;
+    }
+    if (didSave != null) {
+      __result['didSave'] = didSave;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('willSave');
+      try {
+        if (obj['willSave'] != null && !(obj['willSave'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('willSaveWaitUntil');
+      try {
+        if (obj['willSaveWaitUntil'] != null &&
+            !(obj['willSaveWaitUntil'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('didSave');
+      try {
+        if (obj['didSave'] != null && !(obj['didSave'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type TextDocumentSyncClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TextDocumentSyncClientCapabilities &&
+        other.runtimeType == TextDocumentSyncClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          willSave == other.willSave &&
+          willSaveWaitUntil == other.willSaveWaitUntil &&
+          didSave == other.didSave &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, willSave.hashCode);
+    hash = JenkinsSmiHash.combine(hash, willSaveWaitUntil.hashCode);
+    hash = JenkinsSmiHash.combine(hash, didSave.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// Defines how the host (editor) should sync document changes to the language
 /// server.
 class TextDocumentSyncKind {
@@ -15988,8 +22636,12 @@
   static const jsonHandler = LspJsonHandler(
       TextDocumentSyncOptions.canParse, TextDocumentSyncOptions.fromJson);
 
-  TextDocumentSyncOptions(this.openClose, this.change, this.willSave,
-      this.willSaveWaitUntil, this.save);
+  TextDocumentSyncOptions(
+      {this.openClose,
+      this.change,
+      this.willSave,
+      this.willSaveWaitUntil,
+      this.save});
   static TextDocumentSyncOptions fromJson(Map<String, dynamic> json) {
     final openClose = json['openClose'];
     final change = json['change'] != null
@@ -15997,10 +22649,21 @@
         : null;
     final willSave = json['willSave'];
     final willSaveWaitUntil = json['willSaveWaitUntil'];
-    final save =
-        json['save'] != null ? SaveOptions.fromJson(json['save']) : null;
+    final save = json['save'] is bool
+        ? Either2<bool, SaveOptions>.t1(json['save'])
+        : (SaveOptions.canParse(json['save'], nullLspJsonReporter)
+            ? Either2<bool, SaveOptions>.t2(json['save'] != null
+                ? SaveOptions.fromJson(json['save'])
+                : null)
+            : (json['save'] == null
+                ? null
+                : (throw '''${json['save']} was not one of (bool, SaveOptions)''')));
     return TextDocumentSyncOptions(
-        openClose, change, willSave, willSaveWaitUntil, save);
+        openClose: openClose,
+        change: change,
+        willSave: willSave,
+        willSaveWaitUntil: willSaveWaitUntil,
+        save: save);
   }
 
   /// Change notifications are sent to the server. See
@@ -16015,7 +22678,7 @@
 
   /// If present save notifications are sent to the server. If omitted the
   /// notification should not be sent.
-  final SaveOptions save;
+  final Either2<bool, SaveOptions> save;
 
   /// If present will save notifications are sent to the server. If omitted the
   /// notification should not be sent.
@@ -16088,8 +22751,9 @@
       reporter.push('save');
       try {
         if (obj['save'] != null &&
-            !(SaveOptions.canParse(obj['save'], reporter))) {
-          reporter.reportError('must be of type SaveOptions');
+            !((obj['save'] is bool ||
+                SaveOptions.canParse(obj['save'], reporter)))) {
+          reporter.reportError('must be of type Either2<bool, SaveOptions>');
           return false;
         }
       } finally {
@@ -16135,7 +22799,7 @@
   static const jsonHandler =
       LspJsonHandler(TextEdit.canParse, TextEdit.fromJson);
 
-  TextEdit(this.range, this.newText) {
+  TextEdit({@required this.range, @required this.newText}) {
     if (range == null) {
       throw 'range is required but was not provided';
     }
@@ -16146,7 +22810,7 @@
   static TextEdit fromJson(Map<String, dynamic> json) {
     final range = json['range'] != null ? Range.fromJson(json['range']) : null;
     final newText = json['newText'];
-    return TextEdit(range, newText);
+    return TextEdit(range: range, newText: newText);
   }
 
   /// The string to be inserted. For delete operations use an empty string.
@@ -16227,12 +22891,443 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class TypeDefinitionClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TypeDefinitionClientCapabilities.canParse,
+      TypeDefinitionClientCapabilities.fromJson);
+
+  TypeDefinitionClientCapabilities(
+      {this.dynamicRegistration, this.linkSupport});
+  static TypeDefinitionClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final linkSupport = json['linkSupport'];
+    return TypeDefinitionClientCapabilities(
+        dynamicRegistration: dynamicRegistration, linkSupport: linkSupport);
+  }
+
+  /// Whether implementation supports dynamic registration. If this is set to
+  /// `true` the client supports the new `TypeDefinitionRegistrationOptions`
+  /// return value for the corresponding server capability as well.
+  final bool dynamicRegistration;
+
+  /// The client supports additional metadata in the form of definition links.
+  ///  @since 3.14.0
+  final bool linkSupport;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (linkSupport != null) {
+      __result['linkSupport'] = linkSupport;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('linkSupport');
+      try {
+        if (obj['linkSupport'] != null && !(obj['linkSupport'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type TypeDefinitionClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TypeDefinitionClientCapabilities &&
+        other.runtimeType == TypeDefinitionClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          linkSupport == other.linkSupport &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, linkSupport.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class TypeDefinitionOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TypeDefinitionOptions.canParse, TypeDefinitionOptions.fromJson);
+
+  TypeDefinitionOptions({this.workDoneProgress});
+  static TypeDefinitionOptions fromJson(Map<String, dynamic> json) {
+    if (TypeDefinitionRegistrationOptions.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return TypeDefinitionOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type TypeDefinitionOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TypeDefinitionOptions &&
+        other.runtimeType == TypeDefinitionOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class TypeDefinitionParams
+    implements
+        TextDocumentPositionParams,
+        WorkDoneProgressParams,
+        PartialResultParams,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TypeDefinitionParams.canParse, TypeDefinitionParams.fromJson);
+
+  TypeDefinitionParams(
+      {@required this.textDocument,
+      @required this.position,
+      this.workDoneToken,
+      this.partialResultToken}) {
+    if (textDocument == null) {
+      throw 'textDocument is required but was not provided';
+    }
+    if (position == null) {
+      throw 'position is required but was not provided';
+    }
+  }
+  static TypeDefinitionParams fromJson(Map<String, dynamic> json) {
+    final textDocument = json['textDocument'] != null
+        ? TextDocumentIdentifier.fromJson(json['textDocument'])
+        : null;
+    final position =
+        json['position'] != null ? Position.fromJson(json['position']) : null;
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return TypeDefinitionParams(
+        textDocument: textDocument,
+        position: position,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
+  }
+
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// The position inside the text document.
+  final Position position;
+
+  /// The text document.
+  final TextDocumentIdentifier textDocument;
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['textDocument'] =
+        textDocument ?? (throw 'textDocument is required but was not set');
+    __result['position'] =
+        position ?? (throw 'position is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('textDocument');
+      try {
+        if (!obj.containsKey('textDocument')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['textDocument'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(TextDocumentIdentifier.canParse(obj['textDocument'], reporter))) {
+          reporter.reportError('must be of type TextDocumentIdentifier');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('position');
+      try {
+        if (!obj.containsKey('position')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['position'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(Position.canParse(obj['position'], reporter))) {
+          reporter.reportError('must be of type Position');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type TypeDefinitionParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TypeDefinitionParams &&
+        other.runtimeType == TypeDefinitionParams) {
+      return textDocument == other.textDocument &&
+          position == other.position &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, textDocument.hashCode);
+    hash = JenkinsSmiHash.combine(hash, position.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class TypeDefinitionRegistrationOptions
+    implements
+        TextDocumentRegistrationOptions,
+        TypeDefinitionOptions,
+        StaticRegistrationOptions,
+        ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      TypeDefinitionRegistrationOptions.canParse,
+      TypeDefinitionRegistrationOptions.fromJson);
+
+  TypeDefinitionRegistrationOptions(
+      {this.documentSelector, this.workDoneProgress, this.id});
+  static TypeDefinitionRegistrationOptions fromJson(Map<String, dynamic> json) {
+    final documentSelector = json['documentSelector']
+        ?.map((item) => item != null ? DocumentFilter.fromJson(item) : null)
+        ?.cast<DocumentFilter>()
+        ?.toList();
+    final workDoneProgress = json['workDoneProgress'];
+    final id = json['id'];
+    return TypeDefinitionRegistrationOptions(
+        documentSelector: documentSelector,
+        workDoneProgress: workDoneProgress,
+        id: id);
+  }
+
+  /// A document selector to identify the scope of the registration. If set to
+  /// null the document selector provided on the client side will be used.
+  final List<DocumentFilter> documentSelector;
+
+  /// The id used to register the request. The id can be used to deregister the
+  /// request again. See also Registration#id.
+  final String id;
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['documentSelector'] = documentSelector;
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    if (id != null) {
+      __result['id'] = id;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentSelector');
+      try {
+        if (!obj.containsKey('documentSelector')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['documentSelector'] != null &&
+            !((obj['documentSelector'] is List &&
+                (obj['documentSelector'].every(
+                    (item) => DocumentFilter.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<DocumentFilter>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('id');
+      try {
+        if (obj['id'] != null && !(obj['id'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type TypeDefinitionRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is TypeDefinitionRegistrationOptions &&
+        other.runtimeType == TypeDefinitionRegistrationOptions) {
+      return listEqual(documentSelector, other.documentSelector,
+              (DocumentFilter a, DocumentFilter b) => a == b) &&
+          workDoneProgress == other.workDoneProgress &&
+          id == other.id &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(documentSelector));
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    hash = JenkinsSmiHash.combine(hash, id.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// General parameters to unregister a capability.
 class Unregistration implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(Unregistration.canParse, Unregistration.fromJson);
 
-  Unregistration(this.id, this.method) {
+  Unregistration({@required this.id, @required this.method}) {
     if (id == null) {
       throw 'id is required but was not provided';
     }
@@ -16243,7 +23338,7 @@
   static Unregistration fromJson(Map<String, dynamic> json) {
     final id = json['id'];
     final method = json['method'];
-    return Unregistration(id, method);
+    return Unregistration(id: id, method: method);
   }
 
   /// The id used to unregister the request or notification. Usually an id
@@ -16327,7 +23422,7 @@
   static const jsonHandler = LspJsonHandler(
       UnregistrationParams.canParse, UnregistrationParams.fromJson);
 
-  UnregistrationParams(this.unregisterations) {
+  UnregistrationParams({@required this.unregisterations}) {
     if (unregisterations == null) {
       throw 'unregisterations is required but was not provided';
     }
@@ -16337,9 +23432,12 @@
         ?.map((item) => item != null ? Unregistration.fromJson(item) : null)
         ?.cast<Unregistration>()
         ?.toList();
-    return UnregistrationParams(unregisterations);
+    return UnregistrationParams(unregisterations: unregisterations);
   }
 
+  /// This should correctly be named `unregistrations`. However changing this //
+  /// is a breaking change and needs to wait until we deliver a 4.x version //
+  /// of the specification.
   final List<Unregistration> unregisterations;
 
   Map<String, dynamic> toJson() {
@@ -16405,7 +23503,7 @@
       VersionedTextDocumentIdentifier.canParse,
       VersionedTextDocumentIdentifier.fromJson);
 
-  VersionedTextDocumentIdentifier(this.version, this.uri) {
+  VersionedTextDocumentIdentifier({this.version, @required this.uri}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -16413,7 +23511,7 @@
   static VersionedTextDocumentIdentifier fromJson(Map<String, dynamic> json) {
     final version = json['version'];
     final uri = json['uri'];
-    return VersionedTextDocumentIdentifier(version, uri);
+    return VersionedTextDocumentIdentifier(version: version, uri: uri);
   }
 
   /// The text document's URI.
@@ -16423,7 +23521,7 @@
   /// identifier is sent from the server to the client and the file is not open
   /// in the editor (the server has not received an open notification before)
   /// the server can send `null` to indicate that the version is known and the
-  /// content on disk is the truth (as speced with document content ownership).
+  /// content on disk is the master (as speced with document content ownership).
   ///
   /// The version number of a document will increase after each change,
   /// including undo/redo. The number doesn't need to be consecutive.
@@ -16531,7 +23629,8 @@
   static const jsonHandler = LspJsonHandler(
       WillSaveTextDocumentParams.canParse, WillSaveTextDocumentParams.fromJson);
 
-  WillSaveTextDocumentParams(this.textDocument, this.reason) {
+  WillSaveTextDocumentParams(
+      {@required this.textDocument, @required this.reason}) {
     if (textDocument == null) {
       throw 'textDocument is required but was not provided';
     }
@@ -16544,7 +23643,8 @@
         ? TextDocumentIdentifier.fromJson(json['textDocument'])
         : null;
     final reason = json['reason'];
-    return WillSaveTextDocumentParams(textDocument, reason);
+    return WillSaveTextDocumentParams(
+        textDocument: textDocument, reason: reason);
   }
 
   /// The 'TextDocumentSaveReason'.
@@ -16627,568 +23727,138 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-/// Workspace specific client capabilities.
-class WorkspaceClientCapabilities implements ToJsonable {
+class WorkDoneProgressBegin implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilities.canParse,
-      WorkspaceClientCapabilities.fromJson);
+      WorkDoneProgressBegin.canParse, WorkDoneProgressBegin.fromJson);
 
-  WorkspaceClientCapabilities(
-      this.applyEdit,
-      this.workspaceEdit,
-      this.didChangeConfiguration,
-      this.didChangeWatchedFiles,
-      this.symbol,
-      this.executeCommand,
-      this.workspaceFolders,
-      this.configuration);
-  static WorkspaceClientCapabilities fromJson(Map<String, dynamic> json) {
-    final applyEdit = json['applyEdit'];
-    final workspaceEdit = json['workspaceEdit'] != null
-        ? WorkspaceClientCapabilitiesWorkspaceEdit.fromJson(
-            json['workspaceEdit'])
-        : null;
-    final didChangeConfiguration = json['didChangeConfiguration'] != null
-        ? WorkspaceClientCapabilitiesDidChangeConfiguration.fromJson(
-            json['didChangeConfiguration'])
-        : null;
-    final didChangeWatchedFiles = json['didChangeWatchedFiles'] != null
-        ? WorkspaceClientCapabilitiesDidChangeWatchedFiles.fromJson(
-            json['didChangeWatchedFiles'])
-        : null;
-    final symbol = json['symbol'] != null
-        ? WorkspaceClientCapabilitiesSymbol.fromJson(json['symbol'])
-        : null;
-    final executeCommand = json['executeCommand'] != null
-        ? WorkspaceClientCapabilitiesExecuteCommand.fromJson(
-            json['executeCommand'])
-        : null;
-    final workspaceFolders = json['workspaceFolders'];
-    final configuration = json['configuration'];
-    return WorkspaceClientCapabilities(
-        applyEdit,
-        workspaceEdit,
-        didChangeConfiguration,
-        didChangeWatchedFiles,
-        symbol,
-        executeCommand,
-        workspaceFolders,
-        configuration);
+  WorkDoneProgressBegin(
+      {@required this.kind,
+      @required this.title,
+      this.cancellable,
+      this.message,
+      this.percentage}) {
+    if (kind == null) {
+      throw 'kind is required but was not provided';
+    }
+    if (title == null) {
+      throw 'title is required but was not provided';
+    }
+  }
+  static WorkDoneProgressBegin fromJson(Map<String, dynamic> json) {
+    final kind = json['kind'];
+    final title = json['title'];
+    final cancellable = json['cancellable'];
+    final message = json['message'];
+    final percentage = json['percentage'];
+    return WorkDoneProgressBegin(
+        kind: kind,
+        title: title,
+        cancellable: cancellable,
+        message: message,
+        percentage: percentage);
   }
 
-  /// The client supports applying batch edits to the workspace by supporting
-  /// the request 'workspace/applyEdit'
-  final bool applyEdit;
+  /// Controls if a cancel button should show to allow the user to cancel the
+  /// long running operation. Clients that don't support cancellation are
+  /// allowed to ignore the setting.
+  final bool cancellable;
+  final String kind;
 
-  /// The client supports `workspace/configuration` requests.
+  /// Optional, more detailed associated progress message. Contains
+  /// complementary information to the `title`.
   ///
-  /// Since 3.6.0
-  final bool configuration;
+  /// Examples: "3/25 files", "project/src/module2", "node_modules/some_dep". If
+  /// unset, the previous progress message (if any) is still valid.
+  final String message;
 
-  /// Capabilities specific to the `workspace/didChangeConfiguration`
-  /// notification.
-  final WorkspaceClientCapabilitiesDidChangeConfiguration
-      didChangeConfiguration;
-
-  /// Capabilities specific to the `workspace/didChangeWatchedFiles`
-  /// notification.
-  final WorkspaceClientCapabilitiesDidChangeWatchedFiles didChangeWatchedFiles;
-
-  /// Capabilities specific to the `workspace/executeCommand` request.
-  final WorkspaceClientCapabilitiesExecuteCommand executeCommand;
-
-  /// Capabilities specific to the `workspace/symbol` request.
-  final WorkspaceClientCapabilitiesSymbol symbol;
-
-  /// Capabilities specific to `WorkspaceEdit`s
-  final WorkspaceClientCapabilitiesWorkspaceEdit workspaceEdit;
-
-  /// The client has support for workspace folders.
+  /// Optional progress percentage to display (value 100 is considered 100%). If
+  /// not provided infinite progress is assumed and clients are allowed to
+  /// ignore the `percentage` value in subsequent in report notifications.
   ///
-  /// Since 3.6.0
-  final bool workspaceFolders;
+  /// The value should be steadily rising. Clients are free to ignore values
+  /// that are not following this rule.
+  final num percentage;
 
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (applyEdit != null) {
-      __result['applyEdit'] = applyEdit;
-    }
-    if (workspaceEdit != null) {
-      __result['workspaceEdit'] = workspaceEdit;
-    }
-    if (didChangeConfiguration != null) {
-      __result['didChangeConfiguration'] = didChangeConfiguration;
-    }
-    if (didChangeWatchedFiles != null) {
-      __result['didChangeWatchedFiles'] = didChangeWatchedFiles;
-    }
-    if (symbol != null) {
-      __result['symbol'] = symbol;
-    }
-    if (executeCommand != null) {
-      __result['executeCommand'] = executeCommand;
-    }
-    if (workspaceFolders != null) {
-      __result['workspaceFolders'] = workspaceFolders;
-    }
-    if (configuration != null) {
-      __result['configuration'] = configuration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('applyEdit');
-      try {
-        if (obj['applyEdit'] != null && !(obj['applyEdit'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('workspaceEdit');
-      try {
-        if (obj['workspaceEdit'] != null &&
-            !(WorkspaceClientCapabilitiesWorkspaceEdit.canParse(
-                obj['workspaceEdit'], reporter))) {
-          reporter.reportError(
-              'must be of type WorkspaceClientCapabilitiesWorkspaceEdit');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('didChangeConfiguration');
-      try {
-        if (obj['didChangeConfiguration'] != null &&
-            !(WorkspaceClientCapabilitiesDidChangeConfiguration.canParse(
-                obj['didChangeConfiguration'], reporter))) {
-          reporter.reportError(
-              'must be of type WorkspaceClientCapabilitiesDidChangeConfiguration');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('didChangeWatchedFiles');
-      try {
-        if (obj['didChangeWatchedFiles'] != null &&
-            !(WorkspaceClientCapabilitiesDidChangeWatchedFiles.canParse(
-                obj['didChangeWatchedFiles'], reporter))) {
-          reporter.reportError(
-              'must be of type WorkspaceClientCapabilitiesDidChangeWatchedFiles');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('symbol');
-      try {
-        if (obj['symbol'] != null &&
-            !(WorkspaceClientCapabilitiesSymbol.canParse(
-                obj['symbol'], reporter))) {
-          reporter
-              .reportError('must be of type WorkspaceClientCapabilitiesSymbol');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('executeCommand');
-      try {
-        if (obj['executeCommand'] != null &&
-            !(WorkspaceClientCapabilitiesExecuteCommand.canParse(
-                obj['executeCommand'], reporter))) {
-          reporter.reportError(
-              'must be of type WorkspaceClientCapabilitiesExecuteCommand');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('workspaceFolders');
-      try {
-        if (obj['workspaceFolders'] != null &&
-            !(obj['workspaceFolders'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('configuration');
-      try {
-        if (obj['configuration'] != null && !(obj['configuration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError('must be of type WorkspaceClientCapabilities');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilities &&
-        other.runtimeType == WorkspaceClientCapabilities) {
-      return applyEdit == other.applyEdit &&
-          workspaceEdit == other.workspaceEdit &&
-          didChangeConfiguration == other.didChangeConfiguration &&
-          didChangeWatchedFiles == other.didChangeWatchedFiles &&
-          symbol == other.symbol &&
-          executeCommand == other.executeCommand &&
-          workspaceFolders == other.workspaceFolders &&
-          configuration == other.configuration &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, applyEdit.hashCode);
-    hash = JenkinsSmiHash.combine(hash, workspaceEdit.hashCode);
-    hash = JenkinsSmiHash.combine(hash, didChangeConfiguration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, didChangeWatchedFiles.hashCode);
-    hash = JenkinsSmiHash.combine(hash, symbol.hashCode);
-    hash = JenkinsSmiHash.combine(hash, executeCommand.hashCode);
-    hash = JenkinsSmiHash.combine(hash, workspaceFolders.hashCode);
-    hash = JenkinsSmiHash.combine(hash, configuration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class WorkspaceClientCapabilitiesDidChangeConfiguration implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesDidChangeConfiguration.canParse,
-      WorkspaceClientCapabilitiesDidChangeConfiguration.fromJson);
-
-  WorkspaceClientCapabilitiesDidChangeConfiguration(this.dynamicRegistration);
-  static WorkspaceClientCapabilitiesDidChangeConfiguration fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return WorkspaceClientCapabilitiesDidChangeConfiguration(
-        dynamicRegistration);
-  }
-
-  /// Did change configuration notification supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type WorkspaceClientCapabilitiesDidChangeConfiguration');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesDidChangeConfiguration &&
-        other.runtimeType ==
-            WorkspaceClientCapabilitiesDidChangeConfiguration) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class WorkspaceClientCapabilitiesDidChangeWatchedFiles implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesDidChangeWatchedFiles.canParse,
-      WorkspaceClientCapabilitiesDidChangeWatchedFiles.fromJson);
-
-  WorkspaceClientCapabilitiesDidChangeWatchedFiles(this.dynamicRegistration);
-  static WorkspaceClientCapabilitiesDidChangeWatchedFiles fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return WorkspaceClientCapabilitiesDidChangeWatchedFiles(
-        dynamicRegistration);
-  }
-
-  /// Did change watched files notification supports dynamic registration.
-  /// Please note that the current protocol doesn't support static configuration
-  /// for file changes from the server side.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type WorkspaceClientCapabilitiesDidChangeWatchedFiles');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesDidChangeWatchedFiles &&
-        other.runtimeType == WorkspaceClientCapabilitiesDidChangeWatchedFiles) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class WorkspaceClientCapabilitiesExecuteCommand implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesExecuteCommand.canParse,
-      WorkspaceClientCapabilitiesExecuteCommand.fromJson);
-
-  WorkspaceClientCapabilitiesExecuteCommand(this.dynamicRegistration);
-  static WorkspaceClientCapabilitiesExecuteCommand fromJson(
-      Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    return WorkspaceClientCapabilitiesExecuteCommand(dynamicRegistration);
-  }
-
-  /// Execute command supports dynamic registration.
-  final bool dynamicRegistration;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError(
-          'must be of type WorkspaceClientCapabilitiesExecuteCommand');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesExecuteCommand &&
-        other.runtimeType == WorkspaceClientCapabilitiesExecuteCommand) {
-      return dynamicRegistration == other.dynamicRegistration && true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class WorkspaceClientCapabilitiesSymbol implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesSymbol.canParse,
-      WorkspaceClientCapabilitiesSymbol.fromJson);
-
-  WorkspaceClientCapabilitiesSymbol(this.dynamicRegistration, this.symbolKind);
-  static WorkspaceClientCapabilitiesSymbol fromJson(Map<String, dynamic> json) {
-    final dynamicRegistration = json['dynamicRegistration'];
-    final symbolKind = json['symbolKind'] != null
-        ? WorkspaceClientCapabilitiesSymbolKind.fromJson(json['symbolKind'])
-        : null;
-    return WorkspaceClientCapabilitiesSymbol(dynamicRegistration, symbolKind);
-  }
-
-  /// Symbol request supports dynamic registration.
-  final bool dynamicRegistration;
-
-  /// Specific capabilities for the `SymbolKind` in the `workspace/symbol`
-  /// request.
-  final WorkspaceClientCapabilitiesSymbolKind symbolKind;
-
-  Map<String, dynamic> toJson() {
-    var __result = <String, dynamic>{};
-    if (dynamicRegistration != null) {
-      __result['dynamicRegistration'] = dynamicRegistration;
-    }
-    if (symbolKind != null) {
-      __result['symbolKind'] = symbolKind;
-    }
-    return __result;
-  }
-
-  static bool canParse(Object obj, LspJsonReporter reporter) {
-    if (obj is Map<String, dynamic>) {
-      reporter.push('dynamicRegistration');
-      try {
-        if (obj['dynamicRegistration'] != null &&
-            !(obj['dynamicRegistration'] is bool)) {
-          reporter.reportError('must be of type bool');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('symbolKind');
-      try {
-        if (obj['symbolKind'] != null &&
-            !(WorkspaceClientCapabilitiesSymbolKind.canParse(
-                obj['symbolKind'], reporter))) {
-          reporter.reportError(
-              'must be of type WorkspaceClientCapabilitiesSymbolKind');
-          return false;
-        }
-      } finally {
-        reporter.pop();
-      }
-      return true;
-    } else {
-      reporter.reportError('must be of type WorkspaceClientCapabilitiesSymbol');
-      return false;
-    }
-  }
-
-  @override
-  bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesSymbol &&
-        other.runtimeType == WorkspaceClientCapabilitiesSymbol) {
-      return dynamicRegistration == other.dynamicRegistration &&
-          symbolKind == other.symbolKind &&
-          true;
-    }
-    return false;
-  }
-
-  @override
-  int get hashCode {
-    var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
-    hash = JenkinsSmiHash.combine(hash, symbolKind.hashCode);
-    return JenkinsSmiHash.finish(hash);
-  }
-
-  @override
-  String toString() => jsonEncoder.convert(toJson());
-}
-
-class WorkspaceClientCapabilitiesSymbolKind implements ToJsonable {
-  static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesSymbolKind.canParse,
-      WorkspaceClientCapabilitiesSymbolKind.fromJson);
-
-  WorkspaceClientCapabilitiesSymbolKind(this.valueSet);
-  static WorkspaceClientCapabilitiesSymbolKind fromJson(
-      Map<String, dynamic> json) {
-    final valueSet = json['valueSet']
-        ?.map((item) => item != null ? SymbolKind.fromJson(item) : null)
-        ?.cast<SymbolKind>()
-        ?.toList();
-    return WorkspaceClientCapabilitiesSymbolKind(valueSet);
-  }
-
-  /// The symbol kind values the client supports. When this property exists the
-  /// client also guarantees that it will handle values outside its set
-  /// gracefully and falls back to a default value when unknown.
+  /// Mandatory title of the progress operation. Used to briefly inform about
+  /// the kind of operation being performed.
   ///
-  /// If this property is not present the client only supports the symbol kinds
-  /// from `File` to `Array` as defined in the initial version of the protocol.
-  final List<SymbolKind> valueSet;
+  /// Examples: "Indexing" or "Linking dependencies".
+  final String title;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
-    if (valueSet != null) {
-      __result['valueSet'] = valueSet;
+    __result['kind'] = kind ?? (throw 'kind is required but was not set');
+    __result['title'] = title ?? (throw 'title is required but was not set');
+    if (cancellable != null) {
+      __result['cancellable'] = cancellable;
+    }
+    if (message != null) {
+      __result['message'] = message;
+    }
+    if (percentage != null) {
+      __result['percentage'] = percentage;
     }
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('valueSet');
+      reporter.push('kind');
       try {
-        if (obj['valueSet'] != null &&
-            !((obj['valueSet'] is List &&
-                (obj['valueSet']
-                    .every((item) => SymbolKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<SymbolKind>');
+        if (!obj.containsKey('kind')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['kind'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['kind'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('title');
+      try {
+        if (!obj.containsKey('title')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['title'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['title'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('cancellable');
+      try {
+        if (obj['cancellable'] != null && !(obj['cancellable'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('message');
+      try {
+        if (obj['message'] != null && !(obj['message'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('percentage');
+      try {
+        if (obj['percentage'] != null && !(obj['percentage'] is num)) {
+          reporter.reportError('must be of type num');
           return false;
         }
       } finally {
@@ -17196,18 +23866,20 @@
       }
       return true;
     } else {
-      reporter
-          .reportError('must be of type WorkspaceClientCapabilitiesSymbolKind');
+      reporter.reportError('must be of type WorkDoneProgressBegin');
       return false;
     }
   }
 
   @override
   bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesSymbolKind &&
-        other.runtimeType == WorkspaceClientCapabilitiesSymbolKind) {
-      return listEqual(valueSet, other.valueSet,
-              (SymbolKind a, SymbolKind b) => a == b) &&
+    if (other is WorkDoneProgressBegin &&
+        other.runtimeType == WorkDoneProgressBegin) {
+      return kind == other.kind &&
+          title == other.title &&
+          cancellable == other.cancellable &&
+          message == other.message &&
+          percentage == other.percentage &&
           true;
     }
     return false;
@@ -17216,7 +23888,11 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    hash = JenkinsSmiHash.combine(hash, kind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, title.hashCode);
+    hash = JenkinsSmiHash.combine(hash, cancellable.hashCode);
+    hash = JenkinsSmiHash.combine(hash, message.hashCode);
+    hash = JenkinsSmiHash.combine(hash, percentage.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -17224,82 +23900,48 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
-class WorkspaceClientCapabilitiesWorkspaceEdit implements ToJsonable {
+class WorkDoneProgressCancelParams implements ToJsonable {
   static const jsonHandler = LspJsonHandler(
-      WorkspaceClientCapabilitiesWorkspaceEdit.canParse,
-      WorkspaceClientCapabilitiesWorkspaceEdit.fromJson);
+      WorkDoneProgressCancelParams.canParse,
+      WorkDoneProgressCancelParams.fromJson);
 
-  WorkspaceClientCapabilitiesWorkspaceEdit(
-      this.documentChanges, this.resourceOperations, this.failureHandling);
-  static WorkspaceClientCapabilitiesWorkspaceEdit fromJson(
-      Map<String, dynamic> json) {
-    final documentChanges = json['documentChanges'];
-    final resourceOperations = json['resourceOperations']
-        ?.map((item) =>
-            item != null ? ResourceOperationKind.fromJson(item) : null)
-        ?.cast<ResourceOperationKind>()
-        ?.toList();
-    final failureHandling = json['failureHandling'] != null
-        ? FailureHandlingKind.fromJson(json['failureHandling'])
-        : null;
-    return WorkspaceClientCapabilitiesWorkspaceEdit(
-        documentChanges, resourceOperations, failureHandling);
+  WorkDoneProgressCancelParams({@required this.token}) {
+    if (token == null) {
+      throw 'token is required but was not provided';
+    }
+  }
+  static WorkDoneProgressCancelParams fromJson(Map<String, dynamic> json) {
+    final token = json['token'] is num
+        ? Either2<num, String>.t1(json['token'])
+        : (json['token'] is String
+            ? Either2<num, String>.t2(json['token'])
+            : (throw '''${json['token']} was not one of (num, String)'''));
+    return WorkDoneProgressCancelParams(token: token);
   }
 
-  /// The client supports versioned document changes in `WorkspaceEdit`s
-  final bool documentChanges;
-
-  /// The failure handling strategy of a client if applying the workspace edit
-  /// fails.
-  final FailureHandlingKind failureHandling;
-
-  /// The resource operations the client supports. Clients should at least
-  /// support 'create', 'rename' and 'delete' files and folders.
-  final List<ResourceOperationKind> resourceOperations;
+  /// The token to be used to report progress.
+  final Either2<num, String> token;
 
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
-    if (documentChanges != null) {
-      __result['documentChanges'] = documentChanges;
-    }
-    if (resourceOperations != null) {
-      __result['resourceOperations'] = resourceOperations;
-    }
-    if (failureHandling != null) {
-      __result['failureHandling'] = failureHandling;
-    }
+    __result['token'] = token ?? (throw 'token is required but was not set');
     return __result;
   }
 
   static bool canParse(Object obj, LspJsonReporter reporter) {
     if (obj is Map<String, dynamic>) {
-      reporter.push('documentChanges');
+      reporter.push('token');
       try {
-        if (obj['documentChanges'] != null &&
-            !(obj['documentChanges'] is bool)) {
-          reporter.reportError('must be of type bool');
+        if (!obj.containsKey('token')) {
+          reporter.reportError('must not be undefined');
           return false;
         }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('resourceOperations');
-      try {
-        if (obj['resourceOperations'] != null &&
-            !((obj['resourceOperations'] is List &&
-                (obj['resourceOperations'].every((item) =>
-                    ResourceOperationKind.canParse(item, reporter)))))) {
-          reporter.reportError('must be of type List<ResourceOperationKind>');
+        if (obj['token'] == null) {
+          reporter.reportError('must not be null');
           return false;
         }
-      } finally {
-        reporter.pop();
-      }
-      reporter.push('failureHandling');
-      try {
-        if (obj['failureHandling'] != null &&
-            !(FailureHandlingKind.canParse(obj['failureHandling'], reporter))) {
-          reporter.reportError('must be of type FailureHandlingKind');
+        if (!((obj['token'] is num || obj['token'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
           return false;
         }
       } finally {
@@ -17307,20 +23949,570 @@
       }
       return true;
     } else {
-      reporter.reportError(
-          'must be of type WorkspaceClientCapabilitiesWorkspaceEdit');
+      reporter.reportError('must be of type WorkDoneProgressCancelParams');
       return false;
     }
   }
 
   @override
   bool operator ==(Object other) {
-    if (other is WorkspaceClientCapabilitiesWorkspaceEdit &&
-        other.runtimeType == WorkspaceClientCapabilitiesWorkspaceEdit) {
-      return documentChanges == other.documentChanges &&
-          listEqual(resourceOperations, other.resourceOperations,
-              (ResourceOperationKind a, ResourceOperationKind b) => a == b) &&
-          failureHandling == other.failureHandling &&
+    if (other is WorkDoneProgressCancelParams &&
+        other.runtimeType == WorkDoneProgressCancelParams) {
+      return token == other.token && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, token.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkDoneProgressCreateParams implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkDoneProgressCreateParams.canParse,
+      WorkDoneProgressCreateParams.fromJson);
+
+  WorkDoneProgressCreateParams({@required this.token}) {
+    if (token == null) {
+      throw 'token is required but was not provided';
+    }
+  }
+  static WorkDoneProgressCreateParams fromJson(Map<String, dynamic> json) {
+    final token = json['token'] is num
+        ? Either2<num, String>.t1(json['token'])
+        : (json['token'] is String
+            ? Either2<num, String>.t2(json['token'])
+            : (throw '''${json['token']} was not one of (num, String)'''));
+    return WorkDoneProgressCreateParams(token: token);
+  }
+
+  /// The token to be used to report progress.
+  final Either2<num, String> token;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['token'] = token ?? (throw 'token is required but was not set');
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('token');
+      try {
+        if (!obj.containsKey('token')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['token'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!((obj['token'] is num || obj['token'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkDoneProgressCreateParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkDoneProgressCreateParams &&
+        other.runtimeType == WorkDoneProgressCreateParams) {
+      return token == other.token && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, token.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkDoneProgressEnd implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkDoneProgressEnd.canParse, WorkDoneProgressEnd.fromJson);
+
+  WorkDoneProgressEnd({@required this.kind, this.message}) {
+    if (kind == null) {
+      throw 'kind is required but was not provided';
+    }
+  }
+  static WorkDoneProgressEnd fromJson(Map<String, dynamic> json) {
+    final kind = json['kind'];
+    final message = json['message'];
+    return WorkDoneProgressEnd(kind: kind, message: message);
+  }
+
+  final String kind;
+
+  /// Optional, a final message indicating to for example indicate the outcome
+  /// of the operation.
+  final String message;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['kind'] = kind ?? (throw 'kind is required but was not set');
+    if (message != null) {
+      __result['message'] = message;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('kind');
+      try {
+        if (!obj.containsKey('kind')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['kind'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['kind'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('message');
+      try {
+        if (obj['message'] != null && !(obj['message'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkDoneProgressEnd');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkDoneProgressEnd &&
+        other.runtimeType == WorkDoneProgressEnd) {
+      return kind == other.kind && message == other.message && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, kind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, message.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkDoneProgressOptions implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkDoneProgressOptions.canParse, WorkDoneProgressOptions.fromJson);
+
+  WorkDoneProgressOptions({this.workDoneProgress});
+  static WorkDoneProgressOptions fromJson(Map<String, dynamic> json) {
+    if (WorkspaceSymbolOptions.canParse(json, nullLspJsonReporter)) {
+      return WorkspaceSymbolOptions.fromJson(json);
+    }
+    if (ExecuteCommandOptions.canParse(json, nullLspJsonReporter)) {
+      return ExecuteCommandOptions.fromJson(json);
+    }
+    if (CompletionOptions.canParse(json, nullLspJsonReporter)) {
+      return CompletionOptions.fromJson(json);
+    }
+    if (HoverOptions.canParse(json, nullLspJsonReporter)) {
+      return HoverOptions.fromJson(json);
+    }
+    if (SignatureHelpOptions.canParse(json, nullLspJsonReporter)) {
+      return SignatureHelpOptions.fromJson(json);
+    }
+    if (DeclarationOptions.canParse(json, nullLspJsonReporter)) {
+      return DeclarationOptions.fromJson(json);
+    }
+    if (DefinitionOptions.canParse(json, nullLspJsonReporter)) {
+      return DefinitionOptions.fromJson(json);
+    }
+    if (TypeDefinitionOptions.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionOptions.fromJson(json);
+    }
+    if (ImplementationOptions.canParse(json, nullLspJsonReporter)) {
+      return ImplementationOptions.fromJson(json);
+    }
+    if (ReferenceOptions.canParse(json, nullLspJsonReporter)) {
+      return ReferenceOptions.fromJson(json);
+    }
+    if (DocumentHighlightOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentHighlightOptions.fromJson(json);
+    }
+    if (DocumentSymbolOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentSymbolOptions.fromJson(json);
+    }
+    if (CodeActionOptions.canParse(json, nullLspJsonReporter)) {
+      return CodeActionOptions.fromJson(json);
+    }
+    if (CodeLensOptions.canParse(json, nullLspJsonReporter)) {
+      return CodeLensOptions.fromJson(json);
+    }
+    if (DocumentLinkOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentLinkOptions.fromJson(json);
+    }
+    if (DocumentColorOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorOptions.fromJson(json);
+    }
+    if (DocumentFormattingOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentFormattingOptions.fromJson(json);
+    }
+    if (DocumentRangeFormattingOptions.canParse(json, nullLspJsonReporter)) {
+      return DocumentRangeFormattingOptions.fromJson(json);
+    }
+    if (RenameOptions.canParse(json, nullLspJsonReporter)) {
+      return RenameOptions.fromJson(json);
+    }
+    if (FoldingRangeOptions.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeOptions.fromJson(json);
+    }
+    if (SelectionRangeOptions.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return WorkDoneProgressOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkDoneProgressOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkDoneProgressOptions &&
+        other.runtimeType == WorkDoneProgressOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkDoneProgressParams implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkDoneProgressParams.canParse, WorkDoneProgressParams.fromJson);
+
+  WorkDoneProgressParams({this.workDoneToken});
+  static WorkDoneProgressParams fromJson(Map<String, dynamic> json) {
+    if (InitializeParams.canParse(json, nullLspJsonReporter)) {
+      return InitializeParams.fromJson(json);
+    }
+    if (WorkspaceSymbolParams.canParse(json, nullLspJsonReporter)) {
+      return WorkspaceSymbolParams.fromJson(json);
+    }
+    if (ExecuteCommandParams.canParse(json, nullLspJsonReporter)) {
+      return ExecuteCommandParams.fromJson(json);
+    }
+    if (CompletionParams.canParse(json, nullLspJsonReporter)) {
+      return CompletionParams.fromJson(json);
+    }
+    if (HoverParams.canParse(json, nullLspJsonReporter)) {
+      return HoverParams.fromJson(json);
+    }
+    if (SignatureHelpParams.canParse(json, nullLspJsonReporter)) {
+      return SignatureHelpParams.fromJson(json);
+    }
+    if (DeclarationParams.canParse(json, nullLspJsonReporter)) {
+      return DeclarationParams.fromJson(json);
+    }
+    if (DefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return DefinitionParams.fromJson(json);
+    }
+    if (TypeDefinitionParams.canParse(json, nullLspJsonReporter)) {
+      return TypeDefinitionParams.fromJson(json);
+    }
+    if (ImplementationParams.canParse(json, nullLspJsonReporter)) {
+      return ImplementationParams.fromJson(json);
+    }
+    if (ReferenceParams.canParse(json, nullLspJsonReporter)) {
+      return ReferenceParams.fromJson(json);
+    }
+    if (DocumentHighlightParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentHighlightParams.fromJson(json);
+    }
+    if (DocumentSymbolParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentSymbolParams.fromJson(json);
+    }
+    if (CodeActionParams.canParse(json, nullLspJsonReporter)) {
+      return CodeActionParams.fromJson(json);
+    }
+    if (CodeLensParams.canParse(json, nullLspJsonReporter)) {
+      return CodeLensParams.fromJson(json);
+    }
+    if (DocumentLinkParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentLinkParams.fromJson(json);
+    }
+    if (DocumentColorParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentColorParams.fromJson(json);
+    }
+    if (ColorPresentationParams.canParse(json, nullLspJsonReporter)) {
+      return ColorPresentationParams.fromJson(json);
+    }
+    if (DocumentFormattingParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentFormattingParams.fromJson(json);
+    }
+    if (DocumentRangeFormattingParams.canParse(json, nullLspJsonReporter)) {
+      return DocumentRangeFormattingParams.fromJson(json);
+    }
+    if (RenameParams.canParse(json, nullLspJsonReporter)) {
+      return RenameParams.fromJson(json);
+    }
+    if (FoldingRangeParams.canParse(json, nullLspJsonReporter)) {
+      return FoldingRangeParams.fromJson(json);
+    }
+    if (SelectionRangeParams.canParse(json, nullLspJsonReporter)) {
+      return SelectionRangeParams.fromJson(json);
+    }
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    return WorkDoneProgressParams(workDoneToken: workDoneToken);
+  }
+
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkDoneProgressParams');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkDoneProgressParams &&
+        other.runtimeType == WorkDoneProgressParams) {
+      return workDoneToken == other.workDoneToken && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkDoneProgressReport implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkDoneProgressReport.canParse, WorkDoneProgressReport.fromJson);
+
+  WorkDoneProgressReport(
+      {@required this.kind, this.cancellable, this.message, this.percentage}) {
+    if (kind == null) {
+      throw 'kind is required but was not provided';
+    }
+  }
+  static WorkDoneProgressReport fromJson(Map<String, dynamic> json) {
+    final kind = json['kind'];
+    final cancellable = json['cancellable'];
+    final message = json['message'];
+    final percentage = json['percentage'];
+    return WorkDoneProgressReport(
+        kind: kind,
+        cancellable: cancellable,
+        message: message,
+        percentage: percentage);
+  }
+
+  /// Controls enablement state of a cancel button. This property is only valid
+  /// if a cancel button got requested in the `WorkDoneProgressStart` payload.
+  ///
+  /// Clients that don't support cancellation or don't support control the
+  /// button's enablement state are allowed to ignore the setting.
+  final bool cancellable;
+  final String kind;
+
+  /// Optional, more detailed associated progress message. Contains
+  /// complementary information to the `title`.
+  ///
+  /// Examples: "3/25 files", "project/src/module2", "node_modules/some_dep". If
+  /// unset, the previous progress message (if any) is still valid.
+  final String message;
+
+  /// Optional progress percentage to display (value 100 is considered 100%). If
+  /// not provided infinite progress is assumed and clients are allowed to
+  /// ignore the `percentage` value in subsequent in report notifications.
+  ///
+  /// The value should be steadily rising. Clients are free to ignore values
+  /// that are not following this rule.
+  final num percentage;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    __result['kind'] = kind ?? (throw 'kind is required but was not set');
+    if (cancellable != null) {
+      __result['cancellable'] = cancellable;
+    }
+    if (message != null) {
+      __result['message'] = message;
+    }
+    if (percentage != null) {
+      __result['percentage'] = percentage;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('kind');
+      try {
+        if (!obj.containsKey('kind')) {
+          reporter.reportError('must not be undefined');
+          return false;
+        }
+        if (obj['kind'] == null) {
+          reporter.reportError('must not be null');
+          return false;
+        }
+        if (!(obj['kind'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('cancellable');
+      try {
+        if (obj['cancellable'] != null && !(obj['cancellable'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('message');
+      try {
+        if (obj['message'] != null && !(obj['message'] is String)) {
+          reporter.reportError('must be of type String');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('percentage');
+      try {
+        if (obj['percentage'] != null && !(obj['percentage'] is num)) {
+          reporter.reportError('must be of type num');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkDoneProgressReport');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkDoneProgressReport &&
+        other.runtimeType == WorkDoneProgressReport) {
+      return kind == other.kind &&
+          cancellable == other.cancellable &&
+          message == other.message &&
+          percentage == other.percentage &&
           true;
     }
     return false;
@@ -17329,9 +24521,10 @@
   @override
   int get hashCode {
     var hash = 0;
-    hash = JenkinsSmiHash.combine(hash, documentChanges.hashCode);
-    hash = JenkinsSmiHash.combine(hash, lspHashCode(resourceOperations));
-    hash = JenkinsSmiHash.combine(hash, failureHandling.hashCode);
+    hash = JenkinsSmiHash.combine(hash, kind.hashCode);
+    hash = JenkinsSmiHash.combine(hash, cancellable.hashCode);
+    hash = JenkinsSmiHash.combine(hash, message.hashCode);
+    hash = JenkinsSmiHash.combine(hash, percentage.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
@@ -17343,7 +24536,7 @@
   static const jsonHandler =
       LspJsonHandler(WorkspaceEdit.canParse, WorkspaceEdit.fromJson);
 
-  WorkspaceEdit(this.changes, this.documentChanges);
+  WorkspaceEdit({this.changes, this.documentChanges});
   static WorkspaceEdit fromJson(Map<String, dynamic> json) {
     final changes = json['changes']
         ?.map((key, value) => MapEntry(
@@ -17371,7 +24564,7 @@
                 ?.cast<Either4<TextDocumentEdit, CreateFile, RenameFile, DeleteFile>>()
                 ?.toList())
             : (json['documentChanges'] == null ? null : (throw '''${json['documentChanges']} was not one of (List<TextDocumentEdit>, List<Either4<TextDocumentEdit, CreateFile, RenameFile, DeleteFile>>)''')));
-    return WorkspaceEdit(changes, documentChanges);
+    return WorkspaceEdit(changes: changes, documentChanges: documentChanges);
   }
 
   /// Holds changes to existing resources.
@@ -17474,11 +24667,128 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class WorkspaceEditClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceEditClientCapabilities.canParse,
+      WorkspaceEditClientCapabilities.fromJson);
+
+  WorkspaceEditClientCapabilities(
+      {this.documentChanges, this.resourceOperations, this.failureHandling});
+  static WorkspaceEditClientCapabilities fromJson(Map<String, dynamic> json) {
+    final documentChanges = json['documentChanges'];
+    final resourceOperations = json['resourceOperations']
+        ?.map((item) =>
+            item != null ? ResourceOperationKind.fromJson(item) : null)
+        ?.cast<ResourceOperationKind>()
+        ?.toList();
+    final failureHandling = json['failureHandling'] != null
+        ? FailureHandlingKind.fromJson(json['failureHandling'])
+        : null;
+    return WorkspaceEditClientCapabilities(
+        documentChanges: documentChanges,
+        resourceOperations: resourceOperations,
+        failureHandling: failureHandling);
+  }
+
+  /// The client supports versioned document changes in `WorkspaceEdit`s
+  final bool documentChanges;
+
+  /// The failure handling strategy of a client if applying the workspace edit
+  /// fails.
+  ///  @since 3.13.0
+  final FailureHandlingKind failureHandling;
+
+  /// The resource operations the client supports. Clients should at least
+  /// support 'create', 'rename' and 'delete' files and folders.
+  ///  @since 3.13.0
+  final List<ResourceOperationKind> resourceOperations;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (documentChanges != null) {
+      __result['documentChanges'] = documentChanges;
+    }
+    if (resourceOperations != null) {
+      __result['resourceOperations'] = resourceOperations;
+    }
+    if (failureHandling != null) {
+      __result['failureHandling'] = failureHandling;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('documentChanges');
+      try {
+        if (obj['documentChanges'] != null &&
+            !(obj['documentChanges'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('resourceOperations');
+      try {
+        if (obj['resourceOperations'] != null &&
+            !((obj['resourceOperations'] is List &&
+                (obj['resourceOperations'].every((item) =>
+                    ResourceOperationKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<ResourceOperationKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('failureHandling');
+      try {
+        if (obj['failureHandling'] != null &&
+            !(FailureHandlingKind.canParse(obj['failureHandling'], reporter))) {
+          reporter.reportError('must be of type FailureHandlingKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkspaceEditClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceEditClientCapabilities &&
+        other.runtimeType == WorkspaceEditClientCapabilities) {
+      return documentChanges == other.documentChanges &&
+          listEqual(resourceOperations, other.resourceOperations,
+              (ResourceOperationKind a, ResourceOperationKind b) => a == b) &&
+          failureHandling == other.failureHandling &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, documentChanges.hashCode);
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(resourceOperations));
+    hash = JenkinsSmiHash.combine(hash, failureHandling.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 class WorkspaceFolder implements ToJsonable {
   static const jsonHandler =
       LspJsonHandler(WorkspaceFolder.canParse, WorkspaceFolder.fromJson);
 
-  WorkspaceFolder(this.uri, this.name) {
+  WorkspaceFolder({@required this.uri, @required this.name}) {
     if (uri == null) {
       throw 'uri is required but was not provided';
     }
@@ -17489,7 +24799,7 @@
   static WorkspaceFolder fromJson(Map<String, dynamic> json) {
     final uri = json['uri'];
     final name = json['name'];
-    return WorkspaceFolder(uri, name);
+    return WorkspaceFolder(uri: uri, name: name);
   }
 
   /// The name of the workspace folder. Used to refer to this workspace folder
@@ -17575,7 +24885,7 @@
       WorkspaceFoldersChangeEvent.canParse,
       WorkspaceFoldersChangeEvent.fromJson);
 
-  WorkspaceFoldersChangeEvent(this.added, this.removed) {
+  WorkspaceFoldersChangeEvent({@required this.added, @required this.removed}) {
     if (added == null) {
       throw 'added is required but was not provided';
     }
@@ -17592,7 +24902,7 @@
         ?.map((item) => item != null ? WorkspaceFolder.fromJson(item) : null)
         ?.cast<WorkspaceFolder>()
         ?.toList();
-    return WorkspaceFoldersChangeEvent(added, removed);
+    return WorkspaceFoldersChangeEvent(added: added, removed: removed);
   }
 
   /// The array of added workspace folders
@@ -17681,27 +24991,383 @@
   String toString() => jsonEncoder.convert(toJson());
 }
 
+class WorkspaceFoldersServerCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceFoldersServerCapabilities.canParse,
+      WorkspaceFoldersServerCapabilities.fromJson);
+
+  WorkspaceFoldersServerCapabilities(
+      {this.supported, this.changeNotifications});
+  static WorkspaceFoldersServerCapabilities fromJson(
+      Map<String, dynamic> json) {
+    final supported = json['supported'];
+    final changeNotifications = json['changeNotifications'] is String
+        ? Either2<String, bool>.t1(json['changeNotifications'])
+        : (json['changeNotifications'] is bool
+            ? Either2<String, bool>.t2(json['changeNotifications'])
+            : (json['changeNotifications'] == null
+                ? null
+                : (throw '''${json['changeNotifications']} was not one of (String, bool)''')));
+    return WorkspaceFoldersServerCapabilities(
+        supported: supported, changeNotifications: changeNotifications);
+  }
+
+  /// Whether the server wants to receive workspace folder change notifications.
+  ///
+  /// If a string is provided, the string is treated as an ID under which the
+  /// notification is registered on the client side. The ID can be used to
+  /// unregister for these events using the `client/unregisterCapability`
+  /// request.
+  final Either2<String, bool> changeNotifications;
+
+  /// The server has support for workspace folders
+  final bool supported;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (supported != null) {
+      __result['supported'] = supported;
+    }
+    if (changeNotifications != null) {
+      __result['changeNotifications'] = changeNotifications;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('supported');
+      try {
+        if (obj['supported'] != null && !(obj['supported'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('changeNotifications');
+      try {
+        if (obj['changeNotifications'] != null &&
+            !((obj['changeNotifications'] is String ||
+                obj['changeNotifications'] is bool))) {
+          reporter.reportError('must be of type Either2<String, bool>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type WorkspaceFoldersServerCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceFoldersServerCapabilities &&
+        other.runtimeType == WorkspaceFoldersServerCapabilities) {
+      return supported == other.supported &&
+          changeNotifications == other.changeNotifications &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, supported.hashCode);
+    hash = JenkinsSmiHash.combine(hash, changeNotifications.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkspaceSymbolClientCapabilities implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceSymbolClientCapabilities.canParse,
+      WorkspaceSymbolClientCapabilities.fromJson);
+
+  WorkspaceSymbolClientCapabilities(
+      {this.dynamicRegistration, this.symbolKind});
+  static WorkspaceSymbolClientCapabilities fromJson(Map<String, dynamic> json) {
+    final dynamicRegistration = json['dynamicRegistration'];
+    final symbolKind = json['symbolKind'] != null
+        ? WorkspaceSymbolClientCapabilitiesSymbolKind.fromJson(
+            json['symbolKind'])
+        : null;
+    return WorkspaceSymbolClientCapabilities(
+        dynamicRegistration: dynamicRegistration, symbolKind: symbolKind);
+  }
+
+  /// Symbol request supports dynamic registration.
+  final bool dynamicRegistration;
+
+  /// Specific capabilities for the `SymbolKind` in the `workspace/symbol`
+  /// request.
+  final WorkspaceSymbolClientCapabilitiesSymbolKind symbolKind;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (dynamicRegistration != null) {
+      __result['dynamicRegistration'] = dynamicRegistration;
+    }
+    if (symbolKind != null) {
+      __result['symbolKind'] = symbolKind;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('dynamicRegistration');
+      try {
+        if (obj['dynamicRegistration'] != null &&
+            !(obj['dynamicRegistration'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('symbolKind');
+      try {
+        if (obj['symbolKind'] != null &&
+            !(WorkspaceSymbolClientCapabilitiesSymbolKind.canParse(
+                obj['symbolKind'], reporter))) {
+          reporter.reportError(
+              'must be of type WorkspaceSymbolClientCapabilitiesSymbolKind');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkspaceSymbolClientCapabilities');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceSymbolClientCapabilities &&
+        other.runtimeType == WorkspaceSymbolClientCapabilities) {
+      return dynamicRegistration == other.dynamicRegistration &&
+          symbolKind == other.symbolKind &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, dynamicRegistration.hashCode);
+    hash = JenkinsSmiHash.combine(hash, symbolKind.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkspaceSymbolClientCapabilitiesSymbolKind implements ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceSymbolClientCapabilitiesSymbolKind.canParse,
+      WorkspaceSymbolClientCapabilitiesSymbolKind.fromJson);
+
+  WorkspaceSymbolClientCapabilitiesSymbolKind({this.valueSet});
+  static WorkspaceSymbolClientCapabilitiesSymbolKind fromJson(
+      Map<String, dynamic> json) {
+    final valueSet = json['valueSet']
+        ?.map((item) => item != null ? SymbolKind.fromJson(item) : null)
+        ?.cast<SymbolKind>()
+        ?.toList();
+    return WorkspaceSymbolClientCapabilitiesSymbolKind(valueSet: valueSet);
+  }
+
+  /// The symbol kind values the client supports. When this property exists the
+  /// client also guarantees that it will handle values outside its set
+  /// gracefully and falls back to a default value when unknown.
+  ///
+  /// If this property is not present the client only supports the symbol kinds
+  /// from `File` to `Array` as defined in the initial version of the protocol.
+  final List<SymbolKind> valueSet;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (valueSet != null) {
+      __result['valueSet'] = valueSet;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('valueSet');
+      try {
+        if (obj['valueSet'] != null &&
+            !((obj['valueSet'] is List &&
+                (obj['valueSet']
+                    .every((item) => SymbolKind.canParse(item, reporter)))))) {
+          reporter.reportError('must be of type List<SymbolKind>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError(
+          'must be of type WorkspaceSymbolClientCapabilitiesSymbolKind');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceSymbolClientCapabilitiesSymbolKind &&
+        other.runtimeType == WorkspaceSymbolClientCapabilitiesSymbolKind) {
+      return listEqual(valueSet, other.valueSet,
+              (SymbolKind a, SymbolKind b) => a == b) &&
+          true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, lspHashCode(valueSet));
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkspaceSymbolOptions implements WorkDoneProgressOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceSymbolOptions.canParse, WorkspaceSymbolOptions.fromJson);
+
+  WorkspaceSymbolOptions({this.workDoneProgress});
+  static WorkspaceSymbolOptions fromJson(Map<String, dynamic> json) {
+    if (WorkspaceSymbolRegistrationOptions.canParse(
+        json, nullLspJsonReporter)) {
+      return WorkspaceSymbolRegistrationOptions.fromJson(json);
+    }
+    final workDoneProgress = json['workDoneProgress'];
+    return WorkspaceSymbolOptions(workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter.reportError('must be of type WorkspaceSymbolOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceSymbolOptions &&
+        other.runtimeType == WorkspaceSymbolOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
 /// The parameters of a Workspace Symbol Request.
-class WorkspaceSymbolParams implements ToJsonable {
+class WorkspaceSymbolParams
+    implements WorkDoneProgressParams, PartialResultParams, ToJsonable {
   static const jsonHandler = LspJsonHandler(
       WorkspaceSymbolParams.canParse, WorkspaceSymbolParams.fromJson);
 
-  WorkspaceSymbolParams(this.query) {
+  WorkspaceSymbolParams(
+      {@required this.query, this.workDoneToken, this.partialResultToken}) {
     if (query == null) {
       throw 'query is required but was not provided';
     }
   }
   static WorkspaceSymbolParams fromJson(Map<String, dynamic> json) {
     final query = json['query'];
-    return WorkspaceSymbolParams(query);
+    final workDoneToken = json['workDoneToken'] is num
+        ? Either2<num, String>.t1(json['workDoneToken'])
+        : (json['workDoneToken'] is String
+            ? Either2<num, String>.t2(json['workDoneToken'])
+            : (json['workDoneToken'] == null
+                ? null
+                : (throw '''${json['workDoneToken']} was not one of (num, String)''')));
+    final partialResultToken = json['partialResultToken'] is num
+        ? Either2<num, String>.t1(json['partialResultToken'])
+        : (json['partialResultToken'] is String
+            ? Either2<num, String>.t2(json['partialResultToken'])
+            : (json['partialResultToken'] == null
+                ? null
+                : (throw '''${json['partialResultToken']} was not one of (num, String)''')));
+    return WorkspaceSymbolParams(
+        query: query,
+        workDoneToken: workDoneToken,
+        partialResultToken: partialResultToken);
   }
 
-  /// A non-empty query string
+  /// An optional token that a server can use to report partial results (e.g.
+  /// streaming) to the client.
+  final Either2<num, String> partialResultToken;
+
+  /// A query string to filter symbols by. Clients may send an empty string here
+  /// to request all symbols.
   final String query;
 
+  /// An optional token that a server can use to report work done progress.
+  final Either2<num, String> workDoneToken;
+
   Map<String, dynamic> toJson() {
     var __result = <String, dynamic>{};
     __result['query'] = query ?? (throw 'query is required but was not set');
+    if (workDoneToken != null) {
+      __result['workDoneToken'] = workDoneToken;
+    }
+    if (partialResultToken != null) {
+      __result['partialResultToken'] = partialResultToken;
+    }
     return __result;
   }
 
@@ -17724,6 +25390,28 @@
       } finally {
         reporter.pop();
       }
+      reporter.push('workDoneToken');
+      try {
+        if (obj['workDoneToken'] != null &&
+            !((obj['workDoneToken'] is num ||
+                obj['workDoneToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      reporter.push('partialResultToken');
+      try {
+        if (obj['partialResultToken'] != null &&
+            !((obj['partialResultToken'] is num ||
+                obj['partialResultToken'] is String))) {
+          reporter.reportError('must be of type Either2<num, String>');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
       return true;
     } else {
       reporter.reportError('must be of type WorkspaceSymbolParams');
@@ -17735,7 +25423,10 @@
   bool operator ==(Object other) {
     if (other is WorkspaceSymbolParams &&
         other.runtimeType == WorkspaceSymbolParams) {
-      return query == other.query && true;
+      return query == other.query &&
+          workDoneToken == other.workDoneToken &&
+          partialResultToken == other.partialResultToken &&
+          true;
     }
     return false;
   }
@@ -17744,6 +25435,72 @@
   int get hashCode {
     var hash = 0;
     hash = JenkinsSmiHash.combine(hash, query.hashCode);
+    hash = JenkinsSmiHash.combine(hash, workDoneToken.hashCode);
+    hash = JenkinsSmiHash.combine(hash, partialResultToken.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+
+  @override
+  String toString() => jsonEncoder.convert(toJson());
+}
+
+class WorkspaceSymbolRegistrationOptions
+    implements WorkspaceSymbolOptions, ToJsonable {
+  static const jsonHandler = LspJsonHandler(
+      WorkspaceSymbolRegistrationOptions.canParse,
+      WorkspaceSymbolRegistrationOptions.fromJson);
+
+  WorkspaceSymbolRegistrationOptions({this.workDoneProgress});
+  static WorkspaceSymbolRegistrationOptions fromJson(
+      Map<String, dynamic> json) {
+    final workDoneProgress = json['workDoneProgress'];
+    return WorkspaceSymbolRegistrationOptions(
+        workDoneProgress: workDoneProgress);
+  }
+
+  final bool workDoneProgress;
+
+  Map<String, dynamic> toJson() {
+    var __result = <String, dynamic>{};
+    if (workDoneProgress != null) {
+      __result['workDoneProgress'] = workDoneProgress;
+    }
+    return __result;
+  }
+
+  static bool canParse(Object obj, LspJsonReporter reporter) {
+    if (obj is Map<String, dynamic>) {
+      reporter.push('workDoneProgress');
+      try {
+        if (obj['workDoneProgress'] != null &&
+            !(obj['workDoneProgress'] is bool)) {
+          reporter.reportError('must be of type bool');
+          return false;
+        }
+      } finally {
+        reporter.pop();
+      }
+      return true;
+    } else {
+      reporter
+          .reportError('must be of type WorkspaceSymbolRegistrationOptions');
+      return false;
+    }
+  }
+
+  @override
+  bool operator ==(Object other) {
+    if (other is WorkspaceSymbolRegistrationOptions &&
+        other.runtimeType == WorkspaceSymbolRegistrationOptions) {
+      return workDoneProgress == other.workDoneProgress && true;
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, workDoneProgress.hashCode);
     return JenkinsSmiHash.finish(hash);
   }
 
diff --git a/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart b/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
index 21a84d3..bd9b513 100644
--- a/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
+++ b/pkg/analysis_server/lib/lsp_protocol/protocol_special.dart
@@ -17,7 +17,7 @@
     error(ErrorCodes.RequestCancelled, 'Request was cancelled', null);
 
 ErrorOr<R> error<R>(ErrorCodes code, String message, [String data]) =>
-    ErrorOr<R>.error(ResponseError(code, message, data));
+    ErrorOr<R>.error(ResponseError(code: code, message: message, data: data));
 
 ErrorOr<R> failure<R>(ErrorOr<dynamic> error) => ErrorOr<R>.error(error.error);
 
diff --git a/pkg/analysis_server/lib/protocol/protocol_constants.dart b/pkg/analysis_server/lib/protocol/protocol_constants.dart
index 2a888ca..2ba9eea 100644
--- a/pkg/analysis_server/lib/protocol/protocol_constants.dart
+++ b/pkg/analysis_server/lib/protocol/protocol_constants.dart
@@ -164,6 +164,8 @@
 const String DIAGNOSTIC_REQUEST_GET_SERVER_PORT = 'diagnostic.getServerPort';
 const String DIAGNOSTIC_RESPONSE_GET_DIAGNOSTICS_CONTEXTS = 'contexts';
 const String DIAGNOSTIC_RESPONSE_GET_SERVER_PORT_PORT = 'port';
+const String EDIT_REQUEST_BULK_FIXES = 'edit.bulkFixes';
+const String EDIT_REQUEST_BULK_FIXES_INCLUDED = 'included';
 const String EDIT_REQUEST_DARTFIX = 'edit.dartfix';
 const String EDIT_REQUEST_DARTFIX_EXCLUDED_FIXES = 'excludedFixes';
 const String EDIT_REQUEST_DARTFIX_INCLUDED = 'included';
@@ -220,6 +222,7 @@
 const String EDIT_REQUEST_ORGANIZE_DIRECTIVES_FILE = 'file';
 const String EDIT_REQUEST_SORT_MEMBERS = 'edit.sortMembers';
 const String EDIT_REQUEST_SORT_MEMBERS_FILE = 'file';
+const String EDIT_RESPONSE_BULK_FIXES_EDITS = 'edits';
 const String EDIT_RESPONSE_DARTFIX_DETAILS = 'details';
 const String EDIT_RESPONSE_DARTFIX_EDITS = 'edits';
 const String EDIT_RESPONSE_DARTFIX_HAS_ERRORS = 'hasErrors';
diff --git a/pkg/analysis_server/lib/protocol/protocol_generated.dart b/pkg/analysis_server/lib/protocol/protocol_generated.dart
index c6fe18d..51ece87 100644
--- a/pkg/analysis_server/lib/protocol/protocol_generated.dart
+++ b/pkg/analysis_server/lib/protocol/protocol_generated.dart
@@ -7115,6 +7115,180 @@
   }
 }
 
+/// edit.bulkFixes params
+///
+/// {
+///   "included": List<FilePath>
+/// }
+///
+/// Clients may not extend, implement or mix-in this class.
+class EditBulkFixesParams implements RequestParams {
+  List<String> _included;
+
+  /// A list of the files and directories for which edits should be suggested.
+  ///
+  /// If a request is made with a path that is invalid, e.g. is not absolute
+  /// and normalized, an error of type INVALID_FILE_PATH_FORMAT will be
+  /// generated. If a request is made for a file which does not exist, or which
+  /// is not currently subject to analysis (e.g. because it is not associated
+  /// with any analysis root specified to analysis.setAnalysisRoots), an error
+  /// of type FILE_NOT_ANALYZED will be generated.
+  List<String> get included => _included;
+
+  /// A list of the files and directories for which edits should be suggested.
+  ///
+  /// If a request is made with a path that is invalid, e.g. is not absolute
+  /// and normalized, an error of type INVALID_FILE_PATH_FORMAT will be
+  /// generated. If a request is made for a file which does not exist, or which
+  /// is not currently subject to analysis (e.g. because it is not associated
+  /// with any analysis root specified to analysis.setAnalysisRoots), an error
+  /// of type FILE_NOT_ANALYZED will be generated.
+  set included(List<String> value) {
+    assert(value != null);
+    _included = value;
+  }
+
+  EditBulkFixesParams(List<String> included) {
+    this.included = included;
+  }
+
+  factory EditBulkFixesParams.fromJson(
+      JsonDecoder jsonDecoder, String jsonPath, Object json) {
+    json ??= {};
+    if (json is Map) {
+      List<String> included;
+      if (json.containsKey('included')) {
+        included = jsonDecoder.decodeList(
+            jsonPath + '.included', json['included'], jsonDecoder.decodeString);
+      } else {
+        throw jsonDecoder.mismatch(jsonPath, 'included');
+      }
+      return EditBulkFixesParams(included);
+    } else {
+      throw jsonDecoder.mismatch(jsonPath, 'edit.bulkFixes params', json);
+    }
+  }
+
+  factory EditBulkFixesParams.fromRequest(Request request) {
+    return EditBulkFixesParams.fromJson(
+        RequestDecoder(request), 'params', request.params);
+  }
+
+  @override
+  Map<String, dynamic> toJson() {
+    var result = <String, dynamic>{};
+    result['included'] = included;
+    return result;
+  }
+
+  @override
+  Request toRequest(String id) {
+    return Request(id, 'edit.bulkFixes', toJson());
+  }
+
+  @override
+  String toString() => json.encode(toJson());
+
+  @override
+  bool operator ==(other) {
+    if (other is EditBulkFixesParams) {
+      return listEqual(
+          included, other.included, (String a, String b) => a == b);
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, included.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+}
+
+/// edit.bulkFixes result
+///
+/// {
+///   "edits": List<SourceFileEdit>
+/// }
+///
+/// Clients may not extend, implement or mix-in this class.
+class EditBulkFixesResult implements ResponseResult {
+  List<SourceFileEdit> _edits;
+
+  /// A list of source edits to apply the recommended changes.
+  List<SourceFileEdit> get edits => _edits;
+
+  /// A list of source edits to apply the recommended changes.
+  set edits(List<SourceFileEdit> value) {
+    assert(value != null);
+    _edits = value;
+  }
+
+  EditBulkFixesResult(List<SourceFileEdit> edits) {
+    this.edits = edits;
+  }
+
+  factory EditBulkFixesResult.fromJson(
+      JsonDecoder jsonDecoder, String jsonPath, Object json) {
+    json ??= {};
+    if (json is Map) {
+      List<SourceFileEdit> edits;
+      if (json.containsKey('edits')) {
+        edits = jsonDecoder.decodeList(
+            jsonPath + '.edits',
+            json['edits'],
+            (String jsonPath, Object json) =>
+                SourceFileEdit.fromJson(jsonDecoder, jsonPath, json));
+      } else {
+        throw jsonDecoder.mismatch(jsonPath, 'edits');
+      }
+      return EditBulkFixesResult(edits);
+    } else {
+      throw jsonDecoder.mismatch(jsonPath, 'edit.bulkFixes result', json);
+    }
+  }
+
+  factory EditBulkFixesResult.fromResponse(Response response) {
+    return EditBulkFixesResult.fromJson(
+        ResponseDecoder(REQUEST_ID_REFACTORING_KINDS.remove(response.id)),
+        'result',
+        response.result);
+  }
+
+  @override
+  Map<String, dynamic> toJson() {
+    var result = <String, dynamic>{};
+    result['edits'] =
+        edits.map((SourceFileEdit value) => value.toJson()).toList();
+    return result;
+  }
+
+  @override
+  Response toResponse(String id) {
+    return Response(id, result: toJson());
+  }
+
+  @override
+  String toString() => json.encode(toJson());
+
+  @override
+  bool operator ==(other) {
+    if (other is EditBulkFixesResult) {
+      return listEqual(
+          edits, other.edits, (SourceFileEdit a, SourceFileEdit b) => a == b);
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, edits.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+}
+
 /// edit.dartfix params
 ///
 /// {
diff --git a/pkg/analysis_server/lib/src/analysis_server.dart b/pkg/analysis_server/lib/src/analysis_server.dart
index c4c69f8..309cbd8 100644
--- a/pkg/analysis_server/lib/src/analysis_server.dart
+++ b/pkg/analysis_server/lib/src/analysis_server.dart
@@ -480,7 +480,8 @@
     // during normal analysis (for example dot folders are skipped over in
     // _handleWatchEventImpl).
     return contextManager.isInAnalysisRoot(file) &&
-        !contextManager.isContainedInDotFolder(file);
+        !contextManager.isContainedInDotFolder(file) &&
+        !contextManager.isIgnored(file);
   }
 
   Future<void> shutdown() {
diff --git a/pkg/analysis_server/lib/src/cider/completion.dart b/pkg/analysis_server/lib/src/cider/completion.dart
index a3049d34..d9f2189 100644
--- a/pkg/analysis_server/lib/src/cider/completion.dart
+++ b/pkg/analysis_server/lib/src/cider/completion.dart
@@ -58,26 +58,18 @@
     @required int column,
   }) async {
     return _performanceRoot.runAsync('completion', (performance) async {
-      var fileContext = _logger.run('Get file $path', () {
-        return _fileResolver.getFileContext(
-          path: path,
-          performance: performance,
-        );
-      });
-
-      var file = fileContext.file;
-
-      var lineInfo = file.lineInfo;
-      var offset = lineInfo.getOffsetOfLine(line) + column;
-
       var resolvedUnit = performance.run('resolution', (performance) {
         return _fileResolver.resolve(
-          completionOffset: offset,
+          completionLine: line,
+          completionColumn: column,
           path: path,
           performance: performance,
         );
       });
 
+      var lineInfo = resolvedUnit.lineInfo;
+      var offset = lineInfo.getOffsetOfLine(line) + column;
+
       var completionRequest = CompletionRequestImpl(
         resolvedUnit,
         offset,
@@ -109,6 +101,7 @@
             );
           });
 
+          performance.getDataInt('count').add(result.length);
           return result;
         },
       );
@@ -139,14 +132,16 @@
 
       performance.run('filter', (performance) {
         _logger.run('Filter suggestions', () {
+          performance.getDataInt('count').add(suggestions.length);
           suggestions = filter.perform();
+          performance.getDataInt('matchCount').add(suggestions.length);
         });
       });
 
       var result = CiderCompletionResult._(
         suggestions: suggestions,
         performance: CiderCompletionPerformance._(
-          file: performance.getChild('fileContext').elapsed,
+          file: Duration.zero,
           imports: performance.getChild('imports').elapsed,
           resolution: performance.getChild('resolution').elapsed,
           suggestions: performance.getChild('suggestions').elapsed,
@@ -195,6 +190,7 @@
       );
       suggestions.addAll(importedSuggestions);
     }
+    performance.getDataInt('count').add(suggestions.length);
     return suggestions;
   }
 
@@ -239,15 +235,19 @@
 
 class CiderCompletionPerformance {
   /// The elapsed time for file access.
+  @Deprecated('This operation is not performed anymore')
   final Duration file;
 
   /// The elapsed time to compute import suggestions.
+  @Deprecated("Use 'operations' instead")
   final Duration imports;
 
   /// The elapsed time for resolution.
+  @Deprecated("Use 'operations' instead")
   final Duration resolution;
 
   /// The elapsed time to compute suggestions.
+  @Deprecated("Use 'operations' instead")
   final Duration suggestions;
 
   /// The tree of operation performances.
diff --git a/pkg/analysis_server/lib/src/computer/computer_hover.dart b/pkg/analysis_server/lib/src/computer/computer_hover.dart
index 506cab6..3207fbf 100644
--- a/pkg/analysis_server/lib/src/computer/computer_hover.dart
+++ b/pkg/analysis_server/lib/src/computer/computer_hover.dart
@@ -74,7 +74,7 @@
         if (element.enclosingElement is! ExecutableElement) {
           // containing class
           var containingClass = element.thisOrAncestorOfType<ClassElement>();
-          if (containingClass != null) {
+          if (containingClass != null && containingClass != element) {
             hover.containingClassDescription = containingClass.displayName;
           }
           // containing library
diff --git a/pkg/analysis_server/lib/src/computer/computer_outline.dart b/pkg/analysis_server/lib/src/computer/computer_outline.dart
index d2be4fc..b1abe78 100644
--- a/pkg/analysis_server/lib/src/computer/computer_outline.dart
+++ b/pkg/analysis_server/lib/src/computer/computer_outline.dart
@@ -16,10 +16,8 @@
 class DartUnitOutlineComputer {
   final ResolvedUnitResult resolvedUnit;
   final bool withBasicFlutter;
-  final Flutter flutter;
 
-  DartUnitOutlineComputer(this.resolvedUnit, {this.withBasicFlutter = false})
-      : flutter = Flutter.of(resolvedUnit);
+  DartUnitOutlineComputer(this.resolvedUnit, {this.withBasicFlutter = false});
 
   /// Returns the computed outline, not `null`.
   Outline compute() {
@@ -409,6 +407,8 @@
 
   _FunctionBodyOutlinesVisitor(this.outlineComputer, this.contents);
 
+  Flutter get _flutter => Flutter.instance;
+
   /// Return `true` if the given [element] is the method 'group' defined in the
   /// test package.
   bool isGroup(engine.ExecutableElement element) {
@@ -438,13 +438,12 @@
 
   @override
   void visitInstanceCreationExpression(InstanceCreationExpression node) {
-    if (outlineComputer.withBasicFlutter &&
-        outlineComputer.flutter.isWidgetCreation(node)) {
+    if (outlineComputer.withBasicFlutter && _flutter.isWidgetCreation(node)) {
       var children = <Outline>[];
       node.argumentList
           .accept(_FunctionBodyOutlinesVisitor(outlineComputer, children));
 
-      var text = outlineComputer.flutter.getWidgetPresentationText(node);
+      var text = _flutter.getWidgetPresentationText(node);
       var element = Element(ElementKind.CONSTRUCTOR_INVOCATION, text, 0,
           location: outlineComputer._getLocationOffsetLength(node.offset, 0));
 
diff --git a/pkg/analysis_server/lib/src/computer/import_elements_computer.dart b/pkg/analysis_server/lib/src/computer/import_elements_computer.dart
index 6383a22..f0a7bba 100644
--- a/pkg/analysis_server/lib/src/computer/import_elements_computer.dart
+++ b/pkg/analysis_server/lib/src/computer/import_elements_computer.dart
@@ -16,7 +16,7 @@
 import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart' hide Element;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 /// An object used to compute a set of edits to add imports to a given library
@@ -49,9 +49,8 @@
       }
     }
 
-    var builder = DartChangeBuilder(libraryResult.session);
-    await builder.addFileEdit(libraryResult.path,
-        (DartFileEditBuilder builder) {
+    var builder = ChangeBuilder(session: libraryResult.session);
+    await builder.addDartFileEdit(libraryResult.path, (builder) {
       for (var importedElements in filteredImportedElements) {
         var matchingImports =
             _findMatchingImports(existingImports, importedElements);
@@ -65,7 +64,7 @@
           var importedSource = importedFile.createSource(uri);
           var importUri = _getLibrarySourceUri(libraryElement, importedSource);
           var description = _getInsertionDescription(importUri);
-          builder.addInsertion(description.offset, (DartEditBuilder builder) {
+          builder.addInsertion(description.offset, (builder) {
             for (var i = 0; i < description.newLinesBefore; i++) {
               builder.writeln();
             }
@@ -154,8 +153,7 @@
               } else if (combinator is ShowCombinator &&
                   namesToShow.isNotEmpty) {
                 // TODO(brianwilkerson) Add the names in alphabetic order.
-                builder.addInsertion(combinator.shownNames.last.end,
-                    (DartEditBuilder builder) {
+                builder.addInsertion(combinator.shownNames.last.end, (builder) {
                   for (var nameToShow in namesToShow) {
                     builder.write(', ');
                     builder.write(nameToShow);
@@ -246,7 +244,7 @@
   List<ImportedElements> _filterImportedElements(
       List<ImportedElements> originalList) {
     var libraryElement = libraryResult.libraryElement;
-    var libraryScope = LibraryScope(libraryElement);
+    var libraryScope = libraryElement.scope;
     AstFactory factory = AstFactoryImpl();
     var filteredList = <ImportedElements>[];
     for (var elements in originalList) {
@@ -261,7 +259,7 @@
           Token period = SimpleToken(TokenType.PERIOD, -1);
           identifier = factory.prefixedIdentifier(prefix, period, identifier);
         }
-        var element = libraryScope.lookup(identifier, libraryElement);
+        var element = libraryScope.lookupIdentifier(identifier);
         if (element != null) {
           filteredElements.remove(name);
         }
diff --git a/pkg/analysis_server/lib/src/domain_completion.dart b/pkg/analysis_server/lib/src/domain_completion.dart
index cd9cb94..a9d146d 100644
--- a/pkg/analysis_server/lib/src/domain_completion.dart
+++ b/pkg/analysis_server/lib/src/domain_completion.dart
@@ -26,7 +26,7 @@
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/protocol/protocol_constants.dart' as plugin;
 import 'package:analyzer_plugin/protocol/protocol_generated.dart' as plugin;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 /// Instances of the class [CompletionDomainHandler] implement a
 /// [RequestHandler] that handles requests in the completion domain.
@@ -188,8 +188,8 @@
         var session = analysisDriver.currentSession;
 
         var completion = params.label;
-        var builder = DartChangeBuilder(session);
-        await builder.addFileEdit(file, (builder) {
+        var builder = ChangeBuilder(session: session);
+        await builder.addDartFileEdit(file, (builder) {
           var result = builder.importLibraryElement(library.uri);
           if (result.prefix != null) {
             completion = '${result.prefix}.$completion';
diff --git a/pkg/analysis_server/lib/src/domains/execution/completion.dart b/pkg/analysis_server/lib/src/domains/execution/completion.dart
index bf6d781..ead5ad2 100644
--- a/pkg/analysis_server/lib/src/domains/execution/completion.dart
+++ b/pkg/analysis_server/lib/src/domains/execution/completion.dart
@@ -17,7 +17,7 @@
 import 'package:analyzer/file_system/overlay_file_system.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class RuntimeCompletionComputer {
   final OverlayResourceProvider resourceProvider;
@@ -49,9 +49,9 @@
     const codeMarker = '__code_\_';
 
     // Insert the code being completed at the context offset.
-    var changeBuilder = DartChangeBuilder(session);
+    var changeBuilder = ChangeBuilder(session: session);
     var nextImportPrefixIndex = 0;
-    await changeBuilder.addFileEdit(contextPath, (builder) {
+    await changeBuilder.addDartFileEdit(contextPath, (builder) {
       builder.addInsertion(contextOffset, (builder) {
         builder.writeln('{');
 
diff --git a/pkg/analysis_server/lib/src/edit/edit_domain.dart b/pkg/analysis_server/lib/src/edit/edit_domain.dart
index 760da48..a175b2e 100644
--- a/pkg/analysis_server/lib/src/edit/edit_domain.dart
+++ b/pkg/analysis_server/lib/src/edit/edit_domain.dart
@@ -15,7 +15,8 @@
 import 'package:analysis_server/src/edit/fix/dartfix_info.dart' show allFixes;
 import 'package:analysis_server/src/plugin/plugin_manager.dart';
 import 'package:analysis_server/src/plugin/result_converter.dart';
-import 'package:analysis_server/src/protocol_server.dart' hide Element;
+import 'package:analysis_server/src/protocol_server.dart'
+    hide AnalysisError, Element;
 import 'package:analysis_server/src/services/completion/postfix/postfix_completion.dart';
 import 'package:analysis_server/src/services/completion/statement/statement_completion.dart';
 import 'package:analysis_server/src/services/correction/assist.dart';
@@ -36,17 +37,16 @@
 import 'package:analyzer/dart/analysis/session.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/error/error.dart' as engine;
+import 'package:analyzer/error/error.dart';
 import 'package:analyzer/exception/exception.dart';
 import 'package:analyzer/file_system/file_system.dart';
-// ignore: deprecated_member_use
-import 'package:analyzer/source/analysis_options_provider.dart';
 import 'package:analyzer/source/line_info.dart';
-import 'package:analyzer/src/dart/analysis/library_context.dart'
-    show LibraryCycleLinkException;
+import 'package:analyzer/src/analysis_options/analysis_options_provider.dart';
 import 'package:analyzer/src/dart/analysis/results.dart' as engine;
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/scanner/scanner.dart' as engine;
 import 'package:analyzer/src/error/codes.dart' as engine;
+import 'package:analyzer/src/exception/exception.dart';
 import 'package:analyzer/src/generated/engine.dart' as engine;
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/parser.dart' as engine;
@@ -93,6 +93,59 @@
     _newRefactoringManager();
   }
 
+  Future bulkFixes(Request request) async {
+    //
+    // Compute bulk fixes
+    //
+    try {
+      var params = EditBulkFixesParams.fromRequest(request);
+      for (var file in params.included) {
+        if (server.sendResponseErrorIfInvalidFilePath(request, file)) {
+          return;
+        }
+      }
+
+      var paths = <String>[];
+      for (var include in params.included) {
+        var resource = server.resourceProvider.getResource(include);
+        resource.collectDartFilePaths(paths);
+      }
+
+      var errors = await _getErrors(params.included);
+
+      var sourceChange = SourceChange('bulk_fix');
+
+      // todo (pq): push loop into a BulkFixProcessor
+      for (var error in errors) {
+        // todo (pq): filtering will happen in processor
+        List<AnalysisErrorFixes> fixes;
+        while (fixes == null) {
+          try {
+            fixes = await _computeServerErrorFixes(
+                request, error.source.fullName, error.offset);
+          } on InconsistentAnalysisException {
+            // Loop around to try again to compute the fixes.
+          }
+        }
+
+        // In the long run we'll want to support the case where the desired fix
+        // is the first one.  For now, we just assume that the first way is the
+        // only or best way.
+        var edits = fixes[0].fixes[0].edits;
+        for (var edit in edits) {
+          sourceChange.addFileEdit(edit);
+        }
+      }
+
+      var response =
+          EditBulkFixesResult(sourceChange.edits).toResponse(request.id);
+      server.sendResponse(response);
+    } catch (exception, stackTrace) {
+      server.sendServerErrorNotification('Exception while getting bulk fixes',
+          CaughtException(exception, stackTrace), stackTrace);
+    }
+  }
+
   Future dartfix(Request request) async {
     // TODO(danrubel): Add support for dartfix plugins
 
@@ -357,6 +410,9 @@
         return Response.DELAYED_RESPONSE;
       } else if (requestName == EDIT_REQUEST_GET_AVAILABLE_REFACTORINGS) {
         return _getAvailableRefactorings(request);
+      } else if (requestName == EDIT_REQUEST_BULK_FIXES) {
+        bulkFixes(request);
+        return Response.DELAYED_RESPONSE;
       } else if (requestName == EDIT_REQUEST_GET_DARTFIX_INFO) {
         return getDartfixInfo(request);
       } else if (requestName == EDIT_REQUEST_GET_FIXES) {
@@ -619,8 +675,7 @@
 error: $error
 error.errorCode: ${error.errorCode}
 ''';
-            // TODO(scheglov) Use CaughtExceptionWithFiles when patch changed.
-            throw LibraryCycleLinkException(exception, stackTrace, {
+            throw CaughtExceptionWithFiles(exception, stackTrace, {
               file: result.content,
               'parameters': parametersFile,
             });
@@ -804,6 +859,39 @@
     server.sendResponse(result.toResponse(request.id));
   }
 
+  /// todo (pq): (temporary) -> to be moved and redesigned in BulkFixesProcessor
+  Future<List<AnalysisError>> _getErrors(List<String> pathsToProcess) async {
+    var errors = <AnalysisError>[];
+
+    var pathsProcessed = <String>{};
+    for (var path in pathsToProcess) {
+      var driver = server.getAnalysisDriver(path);
+      switch (await driver.getSourceKind(path)) {
+        case SourceKind.PART:
+          // todo (pq): ensure parts are processed (see `edit_dartfix.dart`)
+          continue;
+          break;
+        case SourceKind.LIBRARY:
+          var result = await driver.getResolvedLibrary(path);
+          if (result != null) {
+            for (var unit in result.units) {
+              if (pathsToProcess.contains(unit.path) &&
+                  !pathsProcessed.contains(unit.path)) {
+                for (var error in unit.errors) {
+                  errors.add(error);
+                }
+                pathsProcessed.add(unit.path);
+              }
+            }
+          }
+          break;
+        default:
+          break;
+      }
+    }
+    return errors;
+  }
+
   YamlMap _getOptions(SourceFactory sourceFactory, String content) {
     var optionsProvider = AnalysisOptionsProvider(sourceFactory);
     try {
@@ -1277,3 +1365,15 @@
 /// [_RefactoringManager] throws instances of this class internally to stop
 /// processing in a manager that was reset.
 class _ResetError {}
+
+extension ResourceExtension on Resource {
+  void collectDartFilePaths(List<String> paths) {
+    if (this is File && AnalysisEngine.isDartFileName(path)) {
+      paths.add(path);
+    } else if (this is Folder) {
+      for (var child in (this as Folder).getChildren()) {
+        child.collectDartFilePaths(paths);
+      }
+    }
+  }
+}
diff --git a/pkg/analysis_server/lib/src/flutter/flutter_outline_computer.dart b/pkg/analysis_server/lib/src/flutter/flutter_outline_computer.dart
index 9e9990d..b2540c6 100644
--- a/pkg/analysis_server/lib/src/flutter/flutter_outline_computer.dart
+++ b/pkg/analysis_server/lib/src/flutter/flutter_outline_computer.dart
@@ -13,20 +13,19 @@
 /// Computer for Flutter specific outlines.
 class FlutterOutlineComputer {
   final ResolvedUnitResult resolvedUnit;
-  Flutter flutter;
 
   final List<protocol.FlutterOutline> _depthFirstOrder = [];
 
   FlutterOutlineComputer(this.resolvedUnit);
 
+  Flutter get _flutter => Flutter.instance;
+
   protocol.FlutterOutline compute() {
     var dartOutline = DartUnitOutlineComputer(
       resolvedUnit,
       withBasicFlutter: false,
     ).compute();
 
-    flutter = Flutter.of(resolvedUnit);
-
     // Convert Dart outlines into Flutter outlines.
     var flutterDartOutline = _convert(dartOutline);
 
@@ -131,7 +130,7 @@
   /// a widget reference outline item.
   protocol.FlutterOutline _createOutline(Expression node, bool withGeneric) {
     var type = node.staticType;
-    if (!flutter.isWidgetType(type)) {
+    if (!_flutter.isWidgetType(type)) {
       return null;
     }
     var className = type.element.displayName;
@@ -140,9 +139,9 @@
       var attributes = <protocol.FlutterOutlineAttribute>[];
       var children = <protocol.FlutterOutline>[];
       for (var argument in node.argumentList.arguments) {
-        var isWidgetArgument = flutter.isWidgetType(argument.staticType);
+        var isWidgetArgument = _flutter.isWidgetType(argument.staticType);
         var isWidgetListArgument =
-            flutter.isListOfWidgetsType(argument.staticType);
+            _flutter.isListOfWidgetsType(argument.staticType);
 
         String parentAssociationLabel;
         Expression childrenExpression;
diff --git a/pkg/analysis_server/lib/src/lsp/channel/lsp_byte_stream_channel.dart b/pkg/analysis_server/lib/src/lsp/channel/lsp_byte_stream_channel.dart
index 4fb256c..e05cec2 100644
--- a/pkg/analysis_server/lib/src/lsp/channel/lsp_byte_stream_channel.dart
+++ b/pkg/analysis_server/lib/src/lsp/channel/lsp_byte_stream_channel.dart
@@ -119,10 +119,9 @@
 
   void _sendParseError() {
     final error = ResponseMessage(
-        null,
-        null,
-        ResponseError(ErrorCodes.ParseError, 'Unable to parse message', null),
-        jsonRpcVersion);
+        error: ResponseError(
+            code: ErrorCodes.ParseError, message: 'Unable to parse message'),
+        jsonrpc: jsonRpcVersion);
     sendResponse(error);
   }
 
diff --git a/pkg/analysis_server/lib/src/lsp/client_configuration.dart b/pkg/analysis_server/lib/src/lsp/client_configuration.dart
index 9b554c7..fbca273 100644
--- a/pkg/analysis_server/lib/src/lsp/client_configuration.dart
+++ b/pkg/analysis_server/lib/src/lsp/client_configuration.dart
@@ -8,6 +8,7 @@
   final Map<String, dynamic> _settings = <String, dynamic>{};
 
   bool get enableSdkFormatter => _settings['enableSdkFormatter'] ?? true;
+  int get lineLength => _settings['lineLength'];
 
   void replace(Map<String, dynamic> newConfig) {
     _settings
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/organize_imports.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/organize_imports.dart
index 3bf5324..b7e4b62 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/organize_imports.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/organize_imports.dart
@@ -21,9 +21,9 @@
   Future<ErrorOr<void>> handle(List<dynamic> arguments) async {
     if (arguments == null || arguments.length != 1 || arguments[0] is! String) {
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.InvalidCommandArguments,
-        '$commandName requires a single String parameter containing the path of a Dart file',
-        null,
+        code: ServerErrorCodes.InvalidCommandArguments,
+        message:
+            '$commandName requires a single String parameter containing the path of a Dart file',
       ));
     }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
index 6b7fa5e..ec0df60 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/perform_refactor.dart
@@ -33,9 +33,9 @@
         (arguments[5] != null && arguments[5] is! Map<String, dynamic>)) {
       // length
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.InvalidCommandArguments,
-        '$commandName requires 6 parameters: RefactoringKind, docVersion, filePath, offset, length, options (optional)',
-        null,
+        code: ServerErrorCodes.InvalidCommandArguments,
+        message:
+            '$commandName requires 6 parameters: RefactoringKind, docVersion, filePath, offset, length, options (optional)',
       ));
     }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/send_workspace_edit.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/send_workspace_edit.dart
index 2d33f52..9cdb105 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/send_workspace_edit.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/send_workspace_edit.dart
@@ -29,9 +29,9 @@
         arguments.length != 1 ||
         arguments[0] is! Map<String, dynamic>) {
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.InvalidCommandArguments,
-        '$commandName requires a single List argument of WorkspaceEdit',
-        null,
+        code: ServerErrorCodes.InvalidCommandArguments,
+        message:
+            '$commandName requires a single List argument of WorkspaceEdit',
       ));
     }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/simple_edit_handler.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/simple_edit_handler.dart
index a5a96b2..1dd999b 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/simple_edit_handler.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/simple_edit_handler.dart
@@ -52,7 +52,7 @@
     // Send the edit to the client via a applyEdit request (this is a request
     // from server -> client and the client will provide a response).
     final editResponse = await server.sendRequest(Method.workspace_applyEdit,
-        ApplyWorkspaceEditParams(commandName, workspaceEdit));
+        ApplyWorkspaceEditParams(label: commandName, edit: workspaceEdit));
 
     if (editResponse.error != null) {
       return error(
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/commands/sort_members.dart b/pkg/analysis_server/lib/src/lsp/handlers/commands/sort_members.dart
index a632440..06de050 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/commands/sort_members.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/commands/sort_members.dart
@@ -21,9 +21,9 @@
   Future<ErrorOr<void>> handle(List<dynamic> arguments) async {
     if (arguments == null || arguments.length != 1 || arguments[0] is! String) {
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.InvalidCommandArguments,
-        '$commandName requires a single String parameter containing the path of a Dart file',
-        null,
+        code: ServerErrorCodes.InvalidCommandArguments,
+        message:
+            '$commandName requires a single String parameter containing the path of a Dart file',
       ));
     }
 
@@ -37,9 +37,8 @@
     final result = await driver?.parseFile(path);
     if (result == null) {
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.FileNotAnalyzed,
-        '$commandName is only available for analyzed files',
-        null,
+        code: ServerErrorCodes.FileNotAnalyzed,
+        message: '$commandName is only available for analyzed files',
       ));
     }
     final code = result.content;
@@ -47,9 +46,10 @@
 
     if (hasScanParseErrors(result.errors)) {
       return ErrorOr.error(ResponseError(
-        ServerErrorCodes.FileHasErrors,
-        'Unable to $commandName because the file contains parse errors',
-        path,
+        code: ServerErrorCodes.FileHasErrors,
+        message:
+            'Unable to $commandName because the file contains parse errors',
+        data: path,
       ));
     }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/custom/handler_diagnostic_server.dart b/pkg/analysis_server/lib/src/lsp/handlers/custom/handler_diagnostic_server.dart
index 28fbb76..facc544 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/custom/handler_diagnostic_server.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/custom/handler_diagnostic_server.dart
@@ -24,6 +24,6 @@
   Future<ErrorOr<DartDiagnosticServer>> handle(
       void _, CancellationToken token) async {
     final port = await server.diagnosticServer.getServerPort();
-    return success(DartDiagnosticServer(port));
+    return success(DartDiagnosticServer(port: port));
   }
 }
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_code_actions.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_code_actions.dart
index da57ee1..2358cee 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_code_actions.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_code_actions.dart
@@ -45,16 +45,21 @@
       return success(const []);
     }
 
-    final capabilities = server?.clientCapabilities?.textDocument?.codeAction;
+    final capabilities = server?.clientCapabilities?.textDocument;
 
     final clientSupportsWorkspaceApplyEdit =
         server?.clientCapabilities?.workspace?.applyEdit == true;
 
     final clientSupportsLiteralCodeActions =
-        capabilities?.codeActionLiteralSupport != null;
+        capabilities?.codeAction?.codeActionLiteralSupport != null;
 
     final clientSupportedCodeActionKinds = HashSet<CodeActionKind>.of(
-        capabilities?.codeActionLiteralSupport?.codeActionKind?.valueSet ?? []);
+        capabilities?.codeAction?.codeActionLiteralSupport?.codeActionKind
+                ?.valueSet ??
+            []);
+
+    final clientSupportedDiagnosticTags = HashSet<DiagnosticTag>.of(
+        capabilities?.publishDiagnostics?.tagSupport?.valueSet ?? []);
 
     final path = pathOfDoc(params.textDocument);
     final unit = await path.mapResult(requireResolvedUnit);
@@ -70,6 +75,7 @@
               clientSupportedCodeActionKinds,
               clientSupportsLiteralCodeActions,
               clientSupportsWorkspaceApplyEdit,
+              clientSupportedDiagnosticTags,
               path.result,
               params.range,
               offset,
@@ -89,7 +95,7 @@
   ) {
     return clientSupportsLiteralCodeActions
         ? Either2<Command, CodeAction>.t2(
-            CodeAction(command.title, kind, null, null, command),
+            CodeAction(title: command.title, kind: kind, command: command),
           )
         : Either2<Command, CodeAction>.t1(command);
   }
@@ -100,11 +106,10 @@
   /// before the version number is read.
   CodeAction _createAssistAction(Assist assist) {
     return CodeAction(
-      assist.change.message,
-      toCodeActionKind(assist.change.id, CodeActionKind.Refactor),
-      const [],
-      createWorkspaceEdit(server, assist.change.edits),
-      null,
+      title: assist.change.message,
+      kind: toCodeActionKind(assist.change.id, CodeActionKind.Refactor),
+      diagnostics: const [],
+      edit: createWorkspaceEdit(server, assist.change.edits),
     );
   }
 
@@ -114,11 +119,10 @@
   /// before the version number is read.
   CodeAction _createFixAction(Fix fix, Diagnostic diagnostic) {
     return CodeAction(
-      fix.change.message,
-      toCodeActionKind(fix.change.id, CodeActionKind.QuickFix),
-      [diagnostic],
-      createWorkspaceEdit(server, fix.change.edits),
-      null,
+      title: fix.change.message,
+      kind: toCodeActionKind(fix.change.id, CodeActionKind.QuickFix),
+      diagnostics: [diagnostic],
+      edit: createWorkspaceEdit(server, fix.change.edits),
     );
   }
 
@@ -137,12 +141,12 @@
       // Build a new CodeAction that merges the diagnostics from each same
       // code action onto a single one.
       return CodeAction(
-          first.title,
-          first.kind,
+          title: first.title,
+          kind: first.kind,
           // Merge diagnostics from all of the CodeActions.
-          groups[edit].expand((r) => r.diagnostics).toList(),
-          first.edit,
-          first.command);
+          diagnostics: groups[edit].expand((r) => r.diagnostics).toList(),
+          edit: first.edit,
+          command: first.command);
     }).toList();
   }
 
@@ -187,6 +191,7 @@
     HashSet<CodeActionKind> kinds,
     bool supportsLiterals,
     bool supportsWorkspaceApplyEdit,
+    HashSet<DiagnosticTag> supportedDiagnosticTags,
     String path,
     Range range,
     int offset,
@@ -198,7 +203,8 @@
           kinds, supportsLiterals, supportsWorkspaceApplyEdit, path),
       _getAssistActions(kinds, supportsLiterals, offset, length, unit),
       _getRefactorActions(kinds, supportsLiterals, path, offset, length, unit),
-      _getFixActions(kinds, supportsLiterals, range, unit),
+      _getFixActions(
+          kinds, supportsLiterals, supportedDiagnosticTags, range, unit),
     ]);
     final flatResults = results.expand((x) => x).toList();
 
@@ -208,6 +214,7 @@
   Future<List<Either2<Command, CodeAction>>> _getFixActions(
     HashSet<CodeActionKind> clientSupportedCodeActionKinds,
     bool clientSupportsLiteralCodeActions,
+    HashSet<DiagnosticTag> supportedDiagnosticTags,
     Range range,
     ResolvedUnitResult unit,
   ) async {
@@ -239,7 +246,11 @@
           if (fixes.isNotEmpty) {
             fixes.sort(Fix.SORT_BY_RELEVANCE);
 
-            final diagnostic = toDiagnostic(unit, error);
+            final diagnostic = toDiagnostic(
+              unit,
+              error,
+              supportedTags: supportedDiagnosticTags,
+            );
             codeActions.addAll(
               fixes.map((fix) => _createFixAction(fix, diagnostic)),
             );
@@ -291,14 +302,18 @@
       return _commandOrCodeAction(
           clientSupportsLiteralCodeActions,
           actionKind,
-          Command(name, Commands.performRefactor, [
-            refactorKind.toJson(),
-            path,
-            server.getVersionedDocumentIdentifier(path).version,
-            offset,
-            length,
-            options,
-          ]));
+          Command(
+            title: name,
+            command: Commands.performRefactor,
+            arguments: [
+              refactorKind.toJson(),
+              path,
+              server.getVersionedDocumentIdentifier(path).version,
+              offset,
+              length,
+              options,
+            ],
+          ));
     }
 
     try {
@@ -357,12 +372,18 @@
       _commandOrCodeAction(
         clientSupportsLiteralCodeActions,
         DartCodeActionKind.SortMembers,
-        Command('Sort Members', Commands.sortMembers, [path]),
+        Command(
+            title: 'Sort Members',
+            command: Commands.sortMembers,
+            arguments: [path]),
       ),
       _commandOrCodeAction(
         clientSupportsLiteralCodeActions,
         CodeActionKind.SourceOrganizeImports,
-        Command('Organize Imports', Commands.organizeImports, [path]),
+        Command(
+            title: 'Organize Imports',
+            command: Commands.organizeImports,
+            arguments: [path]),
       ),
     ];
   }
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_completion.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_completion.dart
index cc4b415..e96b54a 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_completion.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_completion.dart
@@ -154,7 +154,7 @@
       '$name/$declaringUri';
 
   Future<ErrorOr<List<CompletionItem>>> _getPluginResults(
-    TextDocumentClientCapabilitiesCompletion completionCapabilities,
+    CompletionClientCapabilities completionCapabilities,
     HashSet<CompletionItemKind> clientSupportedCompletionKinds,
     LineInfo lineInfo,
     String path,
@@ -177,7 +177,7 @@
   }
 
   Future<ErrorOr<List<CompletionItem>>> _getServerItems(
-    TextDocumentClientCapabilitiesCompletion completionCapabilities,
+    CompletionClientCapabilities completionCapabilities,
     HashSet<CompletionItemKind> clientSupportedCompletionKinds,
     bool includeSuggestionSets,
     ResolvedUnitResult unit,
@@ -340,7 +340,7 @@
   }
 
   Iterable<CompletionItem> _pluginResultsToItems(
-    TextDocumentClientCapabilitiesCompletion completionCapabilities,
+    CompletionClientCapabilities completionCapabilities,
     HashSet<CompletionItemKind> clientSupportedCompletionKinds,
     LineInfo lineInfo,
     List<plugin.CompletionGetSuggestionsResult> pluginResults,
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_completion_resolve.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_completion_resolve.dart
index e6a8cfe..63ce7d0 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_completion_resolve.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_completion_resolve.dart
@@ -13,7 +13,7 @@
 import 'package:analyzer/dart/analysis/session.dart';
 import 'package:analyzer/dart/element/element.dart' as analyzer;
 import 'package:analyzer/src/util/comment.dart' as analyzer;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class CompletionResolveHandler
     extends MessageHandler<CompletionItem, CompletionItem> {
@@ -111,8 +111,8 @@
         }
 
         var newInsertText = item.insertText ?? item.label;
-        final builder = DartChangeBuilder(session);
-        await builder.addFileEdit(data.file, (builder) {
+        final builder = ChangeBuilder(session: session);
+        await builder.addDartFileEdit(data.file, (builder) {
           final result = builder.importLibraryElement(library.uri);
           if (result.prefix != null) {
             newInsertText = '${result.prefix}.$newInsertText';
@@ -135,7 +135,9 @@
         if (otherFilesChanges.isNotEmpty) {
           final workspaceEdit = createWorkspaceEdit(server, otherFilesChanges);
           command = Command(
-              'Add import', Commands.sendWorkspaceEdit, [workspaceEdit]);
+              title: 'Add import',
+              command: Commands.sendWorkspaceEdit,
+              arguments: [workspaceEdit]);
         }
 
         // Documentation is added on during resolve for LSP.
@@ -146,32 +148,36 @@
         final documentation = asStringOrMarkupContent(formats, dartDoc);
 
         return success(CompletionItem(
-          item.label,
-          item.kind,
-          data.displayUri != null && thisFilesChanges.isNotEmpty
+          label: item.label,
+          kind: item.kind,
+          tags: item.tags,
+          detail: data.displayUri != null && thisFilesChanges.isNotEmpty
               ? "Auto import from '${data.displayUri}'\n\n${item.detail ?? ''}"
                   .trim()
               : item.detail,
-          documentation,
-          item.deprecated,
-          item.preselect,
-          item.sortText,
-          item.filterText,
-          newInsertText,
-          item.insertTextFormat,
-          TextEdit(
+          documentation: documentation,
+          // The deprecated field is deprecated, but we should still supply it
+          // for clients that have not adopted CompletionItemTags.
+          // ignore: deprecated_member_use_from_same_package
+          deprecated: item.deprecated,
+          preselect: item.preselect,
+          sortText: item.sortText,
+          filterText: item.filterText,
+          insertText: newInsertText,
+          insertTextFormat: item.insertTextFormat,
+          textEdit: TextEdit(
             // TODO(dantup): If `clientSupportsSnippets == true` then we should map
             // `selection` in to a snippet (see how Dart Code does this).
-            toRange(lineInfo, item.data.rOffset, item.data.rLength),
-            newInsertText,
+            range: toRange(lineInfo, item.data.rOffset, item.data.rLength),
+            newText: newInsertText,
           ),
-          thisFilesChanges
+          additionalTextEdits: thisFilesChanges
               .expand((change) =>
                   change.edits.map((edit) => toTextEdit(lineInfo, edit)))
               .toList(),
-          item.commitCharacters,
-          command ?? item.command,
-          item.data,
+          commitCharacters: item.commitCharacters,
+          command: command ?? item.command,
+          data: item.data,
         ));
       } on InconsistentAnalysisException {
         // Loop around to try again.
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_document_symbols.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_document_symbols.dart
index f4f8968..eaba645 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_document_symbols.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_document_symbols.dart
@@ -80,14 +80,15 @@
     Outline outline,
   ) {
     return DocumentSymbol(
-      toElementName(outline.element),
-      outline.element.parameters,
-      elementKindToSymbolKind(clientSupportedSymbolKinds, outline.element.kind),
-      outline.element.isDeprecated,
-      toRange(lineInfo, outline.codeOffset, outline.codeLength),
-      toRange(lineInfo, outline.element.location.offset,
+      name: toElementName(outline.element),
+      detail: outline.element.parameters,
+      kind: elementKindToSymbolKind(
+          clientSupportedSymbolKinds, outline.element.kind),
+      deprecated: outline.element.isDeprecated,
+      range: toRange(lineInfo, outline.codeOffset, outline.codeLength),
+      selectionRange: toRange(lineInfo, outline.element.location.offset,
           outline.element.location.length),
-      outline.children
+      children: outline.children
           ?.map((child) =>
               _asDocumentSymbol(clientSupportedSymbolKinds, lineInfo, child))
           ?.toList(),
@@ -102,15 +103,16 @@
     Outline outline,
   ) {
     return SymbolInformation(
-      toElementName(outline.element),
-      elementKindToSymbolKind(clientSupportedSymbolKinds, outline.element.kind),
-      outline.element.isDeprecated,
-      Location(
-        documentUri,
-        toRange(lineInfo, outline.element.location.offset,
+      name: toElementName(outline.element),
+      kind: elementKindToSymbolKind(
+          clientSupportedSymbolKinds, outline.element.kind),
+      deprecated: outline.element.isDeprecated,
+      location: Location(
+        uri: documentUri,
+        range: toRange(lineInfo, outline.element.location.offset,
             outline.element.location.length),
       ),
-      containerName,
+      containerName: containerName,
     );
   }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_format_on_type.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_format_on_type.dart
index 1ec00e8..22e60af 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_format_on_type.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_format_on_type.dart
@@ -29,7 +29,8 @@
     }
 
     final unformattedSource = file.readAsStringSync();
-    return success(generateEditsForFormatting(unformattedSource));
+    return success(generateEditsForFormatting(
+        unformattedSource, server.clientConfiguration.lineLength));
   }
 
   @override
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_formatting.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_formatting.dart
index f159056..2ca27ef 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_formatting.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_formatting.dart
@@ -29,7 +29,8 @@
     }
 
     final unformattedSource = file.readAsStringSync();
-    return success(generateEditsForFormatting(unformattedSource));
+    return success(generateEditsForFormatting(
+        unformattedSource, server.clientConfiguration.lineLength));
   }
 
   @override
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_hover.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_hover.dart
index 00941d4..72bc4d6 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_hover.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_hover.dart
@@ -78,8 +78,9 @@
     final formats =
         server?.clientCapabilities?.textDocument?.hover?.contentFormat;
     return Hover(
-      asStringOrMarkupContent(formats, content.toString().trimRight()),
-      toRange(lineInfo, hover.offset, hover.length),
+      contents:
+          asStringOrMarkupContent(formats, content.toString().trimRight()),
+      range: toRange(lineInfo, hover.offset, hover.length),
     );
   }
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_implementation.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_implementation.dart
index 235abff..ee143e7 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_implementation.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_implementation.dart
@@ -82,8 +82,9 @@
           item.memberElement?.location ?? item.classElement?.location;
       final lineInfo = server.getLineInfo(elementLocation.file);
       return Location(
-        Uri.file(elementLocation.file).toString(),
-        toRange(lineInfo, elementLocation.offset, elementLocation.length),
+        uri: Uri.file(elementLocation.file).toString(),
+        range:
+            toRange(lineInfo, elementLocation.offset, elementLocation.length),
       );
     }).toList();
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_initialize.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_initialize.dart
index 7df227a..4ee1e1a 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_initialize.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_initialize.dart
@@ -2,6 +2,8 @@
 // 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:io';
+
 import 'package:analysis_server/lsp_protocol/protocol_generated.dart';
 import 'package:analysis_server/lsp_protocol/protocol_special.dart';
 import 'package:analysis_server/src/lsp/handlers/handler_states.dart';
@@ -55,6 +57,18 @@
 
     server.capabilities = server.capabilitiesComputer
         .computeServerCapabilities(params.capabilities);
-    return success(InitializeResult(server.capabilities));
+
+    var sdkVersion = Platform.version;
+    if (sdkVersion.contains(' ')) {
+      sdkVersion = sdkVersion.substring(0, sdkVersion.indexOf(' '));
+    }
+
+    return success(InitializeResult(
+      capabilities: server.capabilities,
+      serverInfo: InitializeResultServerInfo(
+        name: 'Dart SDK LSP Analysis Server',
+        version: sdkVersion,
+      ),
+    ));
   }
 }
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_rename.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_rename.dart
index 44b8c85..a0daa67 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_rename.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_rename.dart
@@ -55,7 +55,7 @@
       }
 
       return success(RangeAndPlaceholder(
-        toRange(
+        range: toRange(
           unit.result.lineInfo,
           // If the offset is set to -1 it means there is no location for the
           // old name. However since we must provide a range for LSP, we'll use
@@ -64,7 +64,7 @@
           refactorDetails.offset == -1 ? offset : refactorDetails.offset,
           refactorDetails.length,
         ),
-        refactoring.oldName,
+        placeholder: refactoring.oldName,
       ));
     });
   }
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_text_document_changes.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_text_document_changes.dart
index 0c3a3a8..6a4b026 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_text_document_changes.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_text_document_changes.dart
@@ -149,8 +149,8 @@
       // We don't get a VersionedTextDocumentIdentifier with a didOpen but we
       // do get the necessary info to create one.
       server.documentVersions[path] = VersionedTextDocumentIdentifier(
-        params.textDocument.version,
-        params.textDocument.uri,
+        version: params.textDocument.version,
+        uri: params.textDocument.uri,
       );
       server.onOverlayCreated(path, doc.text);
 
diff --git a/pkg/analysis_server/lib/src/lsp/handlers/handler_workspace_symbols.dart b/pkg/analysis_server/lib/src/lsp/handlers/handler_workspace_symbols.dart
index 4ad092f..c1cce0a 100644
--- a/pkg/analysis_server/lib/src/lsp/handlers/handler_workspace_symbols.dart
+++ b/pkg/analysis_server/lib/src/lsp/handlers/handler_workspace_symbols.dart
@@ -93,8 +93,8 @@
       declaration.codeLength,
     );
     final location = Location(
-      Uri.file(filePath).toString(),
-      range,
+      uri: Uri.file(filePath).toString(),
+      range: range,
     );
 
     final hasParameters =
@@ -103,10 +103,10 @@
         hasParameters ? (declaration.parameters == '()' ? '()' : '(…)') : '';
 
     return SymbolInformation(
-        '${declaration.name}$nameSuffix',
-        kind,
-        null, // We don't have easy access to isDeprecated here.
-        location,
-        declaration.className ?? declaration.mixinName);
+        name: '${declaration.name}$nameSuffix',
+        kind: kind,
+        deprecated: null, // We don't have easy access to isDeprecated here.
+        location: location,
+        containerName: declaration.className ?? declaration.mixinName);
   }
 }
diff --git a/pkg/analysis_server/lib/src/lsp/lsp_analysis_server.dart b/pkg/analysis_server/lib/src/lsp/lsp_analysis_server.dart
index 64bb954..e875cfa 100644
--- a/pkg/analysis_server/lib/src/lsp/lsp_analysis_server.dart
+++ b/pkg/analysis_server/lib/src/lsp/lsp_analysis_server.dart
@@ -182,8 +182,8 @@
       // others (for example "flutter").
       final response = await sendRequest(
           Method.workspace_configuration,
-          ConfigurationParams([
-            ConfigurationItem(null, 'dart'),
+          ConfigurationParams(items: [
+            ConfigurationItem(section: 'dart'),
           ]));
 
       final result = response.result;
@@ -218,7 +218,7 @@
   /// version is not known.
   VersionedTextDocumentIdentifier getVersionedDocumentIdentifier(String path) {
     return documentVersions[path] ??
-        VersionedTextDocumentIdentifier(null, Uri.file(path).toString());
+        VersionedTextDocumentIdentifier(uri: Uri.file(path).toString());
   }
 
   void handleClientConnection(
@@ -269,7 +269,9 @@
               sendErrorResponse(message, result.error);
             } else {
               channel.sendResponse(ResponseMessage(
-                  message.id, result.result, null, jsonRpcVersion));
+                  id: message.id,
+                  result: result.result,
+                  jsonrpc: jsonRpcVersion));
             }
           } else if (message is NotificationMessage) {
             final result = await messageHandler.handleMessage(message);
@@ -290,9 +292,8 @@
           sendErrorResponse(
               message,
               ResponseError(
-                ServerErrorCodes.UnhandledError,
-                errorMessage,
-                null,
+                code: ServerErrorCodes.UnhandledError,
+                message: errorMessage,
               ));
           logException(errorMessage, error, stackTrace);
         }
@@ -303,9 +304,9 @@
   /// Logs the error on the client using window/logMessage.
   void logErrorToClient(String message) {
     channel.sendNotification(NotificationMessage(
-      Method.window_logMessage,
-      LogMessageParams(MessageType.Error, message),
-      jsonRpcVersion,
+      method: Method.window_logMessage,
+      params: LogMessageParams(type: MessageType.Error, message: message),
+      jsonrpc: jsonRpcVersion,
     ));
   }
 
@@ -335,7 +336,8 @@
   }
 
   void onOverlayCreated(String path, String content) {
-    resourceProvider.setOverlay(path, content: content, modificationStamp: 0);
+    resourceProvider.setOverlay(path,
+        content: content, modificationStamp: overlayModificationStamp++);
 
     _afterOverlayChanged(path, plugin.AddContentOverlay(content));
   }
@@ -360,49 +362,51 @@
     }
 
     resourceProvider.setOverlay(path,
-        content: newContent, modificationStamp: 0);
+        content: newContent, modificationStamp: overlayModificationStamp++);
 
     _afterOverlayChanged(path, plugin.ChangeContentOverlay(edits));
   }
 
   void publishClosingLabels(String path, List<ClosingLabel> labels) {
-    final params =
-        PublishClosingLabelsParams(Uri.file(path).toString(), labels);
+    final params = PublishClosingLabelsParams(
+        uri: Uri.file(path).toString(), labels: labels);
     final message = NotificationMessage(
-      CustomMethods.PublishClosingLabels,
-      params,
-      jsonRpcVersion,
+      method: CustomMethods.PublishClosingLabels,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     sendNotification(message);
   }
 
   void publishDiagnostics(String path, List<Diagnostic> errors) {
-    final params = PublishDiagnosticsParams(Uri.file(path).toString(), errors);
+    final params = PublishDiagnosticsParams(
+        uri: Uri.file(path).toString(), diagnostics: errors);
     final message = NotificationMessage(
-      Method.textDocument_publishDiagnostics,
-      params,
-      jsonRpcVersion,
+      method: Method.textDocument_publishDiagnostics,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     sendNotification(message);
   }
 
   void publishFlutterOutline(String path, FlutterOutline outline) {
-    final params =
-        PublishFlutterOutlineParams(Uri.file(path).toString(), outline);
+    final params = PublishFlutterOutlineParams(
+        uri: Uri.file(path).toString(), outline: outline);
     final message = NotificationMessage(
-      CustomMethods.PublishFlutterOutline,
-      params,
-      jsonRpcVersion,
+      method: CustomMethods.PublishFlutterOutline,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     sendNotification(message);
   }
 
   void publishOutline(String path, Outline outline) {
-    final params = PublishOutlineParams(Uri.file(path).toString(), outline);
+    final params =
+        PublishOutlineParams(uri: Uri.file(path).toString(), outline: outline);
     final message = NotificationMessage(
-      CustomMethods.PublishOutline,
-      params,
-      jsonRpcVersion,
+      method: CustomMethods.PublishOutline,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     sendNotification(message);
   }
@@ -417,8 +421,8 @@
 
   void sendErrorResponse(Message message, ResponseError error) {
     if (message is RequestMessage) {
-      channel.sendResponse(
-          ResponseMessage(message.id, null, error, jsonRpcVersion));
+      channel.sendResponse(ResponseMessage(
+          id: message.id, error: error, jsonrpc: jsonRpcVersion));
     } else if (message is ResponseMessage) {
       // For bad response messages where we can't respond with an error, send it
       // as show instead of log.
@@ -455,10 +459,10 @@
     completers[requestId] = completer;
 
     channel.sendRequest(RequestMessage(
-      Either2<num, String>.t1(requestId),
-      method,
-      params,
-      jsonRpcVersion,
+      id: Either2<num, String>.t1(requestId),
+      method: method,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     ));
 
     return completer.future;
@@ -484,9 +488,9 @@
   /// the [status] information.
   void sendStatusNotification(nd.AnalysisStatus status) {
     channel.sendNotification(NotificationMessage(
-      CustomMethods.AnalyzerStatus,
-      AnalyzerStatusParams(status.isAnalyzing),
-      jsonRpcVersion,
+      method: CustomMethods.AnalyzerStatus,
+      params: AnalyzerStatusParams(isAnalyzing: status.isAnalyzing),
+      jsonrpc: jsonRpcVersion,
     ));
   }
 
@@ -515,7 +519,8 @@
     // during normal analysis (for example dot folders are skipped over in
     // _handleWatchEventImpl).
     return contextManager.isInAnalysisRoot(file) &&
-        !contextManager.isContainedInDotFolder(file);
+        !contextManager.isContainedInDotFolder(file) &&
+        !contextManager.isIgnored(file);
   }
 
   /// Returns `true` if Flutter outlines should be sent for [file] with the
@@ -538,9 +543,9 @@
 
   void showMessageToUser(MessageType type, String message) {
     channel.sendNotification(NotificationMessage(
-      Method.window_showMessage,
-      ShowMessageParams(type, message),
-      jsonRpcVersion,
+      method: Method.window_showMessage,
+      params: ShowMessageParams(type: type, message: message),
+      jsonrpc: jsonRpcVersion,
     ));
   }
 
@@ -657,6 +662,11 @@
       Folder folder, ContextRoot contextRoot, AnalysisOptions options) {
     var builder = createContextBuilder(folder, options);
     var analysisDriver = builder.buildDriver(contextRoot);
+    final textDocumentCapabilities =
+        analysisServer.clientCapabilities?.textDocument;
+    final supportedDiagnosticTags = HashSet<DiagnosticTag>.of(
+        textDocumentCapabilities?.publishDiagnostics?.tagSupport?.valueSet ??
+            []);
     analysisDriver.results.listen((result) {
       var path = result.path;
       if (analysisServer.shouldSendErrorsNotificationFor(path)) {
@@ -665,7 +675,12 @@
             result.errors
                 .where((e) => e.errorCode.type != ErrorType.TODO)
                 .toList(),
-            toDiagnostic);
+            (result, error, [severity]) => toDiagnostic(
+                  result,
+                  error,
+                  supportedTags: supportedDiagnosticTags,
+                  errorSeverity: severity,
+                ));
 
         analysisServer.publishDiagnostics(result.path, serverErrors);
       }
diff --git a/pkg/analysis_server/lib/src/lsp/lsp_socket_server.dart b/pkg/analysis_server/lib/src/lsp/lsp_socket_server.dart
index 3c49e8a..ae00fb8 100644
--- a/pkg/analysis_server/lib/src/lsp/lsp_socket_server.dart
+++ b/pkg/analysis_server/lib/src/lsp/lsp_socket_server.dart
@@ -45,19 +45,20 @@
   /// given serverChannel.
   void createAnalysisServer(LspServerCommunicationChannel serverChannel) {
     if (analysisServer != null) {
-      ResponseError error = ResponseError<void>(
-          ServerErrorCodes.ServerAlreadyStarted,
-          'Server already started',
-          null);
+      final error = ResponseError(
+        code: ServerErrorCodes.ServerAlreadyStarted,
+        message: 'Server already started',
+      );
       serverChannel.sendNotification(NotificationMessage(
-        Method.window_showMessage,
-        ShowMessageParams(MessageType.Error, error.message),
-        jsonRpcVersion,
+        method: Method.window_showMessage,
+        params:
+            ShowMessageParams(type: MessageType.Error, message: error.message),
+        jsonrpc: jsonRpcVersion,
       ));
       serverChannel.listen((Message message) {
         if (message is RequestMessage) {
-          serverChannel.sendResponse(
-              ResponseMessage(message.id, null, error, jsonRpcVersion));
+          serverChannel.sendResponse(ResponseMessage(
+              id: message.id, error: error, jsonrpc: jsonRpcVersion));
         }
       });
       return;
diff --git a/pkg/analysis_server/lib/src/lsp/mapping.dart b/pkg/analysis_server/lib/src/lsp/mapping.dart
index 198f463..6249c90 100644
--- a/pkg/analysis_server/lib/src/lsp/mapping.dart
+++ b/pkg/analysis_server/lib/src/lsp/mapping.dart
@@ -28,11 +28,25 @@
 import 'package:analyzer/diagnostic/diagnostic.dart' as analyzer;
 import 'package:analyzer/error/error.dart' as server;
 import 'package:analyzer/source/line_info.dart' as server;
+import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/source.dart' as server;
 import 'package:analyzer/src/services/available_declarations.dart';
 import 'package:analyzer/src/services/available_declarations.dart' as dec;
 import 'package:analyzer_plugin/protocol/protocol_common.dart' as plugin;
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart' as server;
+import 'package:meta/meta.dart';
+
+const diagnosticTagsForErrorCode = <server.ErrorCode, List<lsp.DiagnosticTag>>{
+  HintCode.DEAD_CODE: [lsp.DiagnosticTag.Unnecessary],
+  HintCode.DEPRECATED_MEMBER_USE: [lsp.DiagnosticTag.Deprecated],
+  HintCode.DEPRECATED_MEMBER_USE_FROM_SAME_PACKAGE: [
+    lsp.DiagnosticTag.Deprecated
+  ],
+  HintCode.DEPRECATED_MEMBER_USE_FROM_SAME_PACKAGE_WITH_MESSAGE: [
+    lsp.DiagnosticTag.Deprecated
+  ],
+  HintCode.DEPRECATED_MEMBER_USE_WITH_MESSAGE: [lsp.DiagnosticTag.Deprecated],
+};
 
 const languageSourceName = 'dart';
 
@@ -175,7 +189,7 @@
 }
 
 lsp.CompletionItem declarationToCompletionItem(
-  lsp.TextDocumentClientCapabilitiesCompletion completionCapabilities,
+  lsp.CompletionClientCapabilities completionCapabilities,
   HashSet<lsp.CompletionItemKind> supportedCompletionItemKinds,
   String file,
   int offset,
@@ -224,8 +238,12 @@
       label = declaration.name;
   }
 
-  final useDeprecated =
+  final supportsDeprecatedFlag =
       completionCapabilities?.completionItem?.deprecatedSupport == true;
+  final supportedTags =
+      completionCapabilities?.completionItem?.tagSupport?.valueSet ?? const [];
+  final supportsDeprecatedTag =
+      supportedTags.contains(lsp.CompletionItemTag.Deprecated);
 
   final completionKind = declarationKindToCompletionItemKind(
       supportedCompletionItemKinds, declaration.kind);
@@ -241,33 +259,38 @@
   // the generated JSON as much as possible - for example using nulls in place
   // of empty lists/false where possible.
   return lsp.CompletionItem(
-    label,
-    completionKind,
-    getDeclarationCompletionDetail(declaration, completionKind, useDeprecated),
-    null, // documentation - will be added during resolve.
-    useDeprecated && declaration.isDeprecated ? true : null,
-    null, // preselect
+    label: label,
+    kind: completionKind,
+    tags: supportedTags.isNotEmpty
+        ? [
+            if (supportsDeprecatedTag && declaration.isDeprecated)
+              lsp.CompletionItemTag.Deprecated
+          ]
+        : null,
+    detail: getDeclarationCompletionDetail(declaration, completionKind,
+        supportsDeprecatedFlag || supportsDeprecatedTag),
+    deprecated:
+        supportsDeprecatedFlag && declaration.isDeprecated ? true : null,
     // Relevance is a number, highest being best. LSP does text sort so subtract
     // from a large number so that a text sort will result in the correct order.
     // 555 -> 999455
     //  10 -> 999990
     //   1 -> 999999
-    (1000000 - itemRelevance).toString(),
-    filterText != label ? filterText : null, // filterText uses label if not set
-    insertText != label ? insertText : null, // insertText uses label if not set
-    null, // insertTextFormat (we always use plain text so can ommit this)
-    null, // textEdit - added on during resolve
-    null, // additionalTextEdits, used for adding imports, etc.
-    null, // commitCharacters
-    null, // command
+    sortText: (1000000 - itemRelevance).toString(),
+    filterText: filterText != label
+        ? filterText
+        : null, // filterText uses label if not set
+    insertText: insertText != label
+        ? insertText
+        : null, // insertText uses label if not set
     // data, used for completionItem/resolve.
-    lsp.CompletionItemResolutionInfo(
-        file,
-        offset,
-        includedSuggestionSet.id,
-        includedSuggestionSet.displayUri ?? library.uri?.toString(),
-        replacementOffset,
-        replacementLength),
+    data: lsp.CompletionItemResolutionInfo(
+        file: file,
+        offset: offset,
+        libId: includedSuggestionSet.id,
+        displayUri: includedSuggestionSet.displayUri ?? library.uri?.toString(),
+        rOffset: replacementOffset,
+        rLength: replacementLength),
   );
 }
 
@@ -499,6 +522,19 @@
   }
 }
 
+List<lsp.DiagnosticTag> getDiagnosticTags(
+    HashSet<lsp.DiagnosticTag> supportedTags, server.AnalysisError error) {
+  if (supportedTags == null) {
+    return null;
+  }
+
+  final tags = diagnosticTagsForErrorCode[error.errorCode]
+      ?.where(supportedTags.contains)
+      ?.toList();
+
+  return tags != null && tags.isNotEmpty ? tags : null;
+}
+
 bool isDartDocument(lsp.TextDocumentIdentifier doc) =>
     doc?.uri?.endsWith('.dart');
 
@@ -509,8 +545,8 @@
   }
 
   return lsp.Location(
-    Uri.file(targetFilePath).toString(),
-    toRange(lineInfo, target.offset, target.length),
+    uri: Uri.file(targetFilePath).toString(),
+    range: toRange(lineInfo, target.offset, target.length),
   );
 }
 
@@ -526,16 +562,17 @@
 ErrorOr<String> pathOfUri(Uri uri) {
   if (uri == null) {
     return ErrorOr<String>.error(ResponseError(
-        lsp.ServerErrorCodes.InvalidFilePath,
-        'Document URI was not supplied',
-        null));
+      code: lsp.ServerErrorCodes.InvalidFilePath,
+      message: 'Document URI was not supplied',
+    ));
   }
   final isValidFileUri = (uri?.isScheme('file') ?? false);
   if (!isValidFileUri) {
     return ErrorOr<String>.error(ResponseError(
-        lsp.ServerErrorCodes.InvalidFilePath,
-        'URI was not a valid file:// URI',
-        uri.toString()));
+      code: lsp.ServerErrorCodes.InvalidFilePath,
+      message: 'URI was not a valid file:// URI',
+      data: uri.toString(),
+    ));
   }
   try {
     return ErrorOr<String>.success(uri.toFilePath());
@@ -543,9 +580,9 @@
     // Even if tryParse() works and file == scheme, toFilePath() can throw on
     // Windows if there are invalid characters.
     return ErrorOr<String>.error(ResponseError(
-        lsp.ServerErrorCodes.InvalidFilePath,
-        'File URI did not contain a valid file path',
-        uri.toString()));
+        code: lsp.ServerErrorCodes.InvalidFilePath,
+        message: 'File URI did not contain a valid file path',
+        data: uri.toString()));
   }
 }
 
@@ -568,12 +605,12 @@
 
   var lineInfo = getLineInfo(error.location.file);
   return lsp.Diagnostic(
-    toRange(lineInfo, error.location.offset, error.location.length),
-    pluginToDiagnosticSeverity(error.severity),
-    error.code,
-    languageSourceName,
-    message,
-    relatedInformation,
+    range: toRange(lineInfo, error.location.offset, error.location.length),
+    severity: pluginToDiagnosticSeverity(error.severity),
+    code: error.code,
+    source: languageSourceName,
+    message: message,
+    relatedInformation: relatedInformation,
   );
 }
 
@@ -583,15 +620,15 @@
   var file = message.location.file;
   var lineInfo = getLineInfo(file);
   return lsp.DiagnosticRelatedInformation(
-      lsp.Location(
-        Uri.file(file).toString(),
-        toRange(
+      location: lsp.Location(
+        uri: Uri.file(file).toString(),
+        range: toRange(
           lineInfo,
           message.location.offset,
           message.location.length,
         ),
       ),
-      message.message);
+      message: message.message);
 }
 
 lsp.DiagnosticSeverity pluginToDiagnosticSeverity(
@@ -621,8 +658,8 @@
   }
 
   return lsp.Location(
-    Uri.file(result.location.file).toString(),
-    toRange(lineInfo, location.offset, location.length),
+    uri: Uri.file(result.location.file).toString(),
+    range: toRange(lineInfo, location.offset, location.length),
   );
 }
 
@@ -675,7 +712,8 @@
 lsp.ClosingLabel toClosingLabel(
         server.LineInfo lineInfo, server.ClosingLabel label) =>
     lsp.ClosingLabel(
-        toRange(lineInfo, label.offset, label.length), label.label);
+        range: toRange(lineInfo, label.offset, label.length),
+        label: label.label);
 
 CodeActionKind toCodeActionKind(String id, lsp.CodeActionKind fallback) {
   if (id == null) {
@@ -692,7 +730,7 @@
 }
 
 lsp.CompletionItem toCompletionItem(
-  lsp.TextDocumentClientCapabilitiesCompletion completionCapabilities,
+  lsp.CompletionClientCapabilities completionCapabilities,
   HashSet<lsp.CompletionItemKind> supportedCompletionItemKinds,
   server.LineInfo lineInfo,
   server.CompletionSuggestion suggestion,
@@ -721,8 +759,12 @@
     }
   }
 
-  final useDeprecated =
+  final supportsDeprecatedFlag =
       completionCapabilities?.completionItem?.deprecatedSupport == true;
+  final supportedTags =
+      completionCapabilities?.completionItem?.tagSupport?.valueSet ?? const [];
+  final supportsDeprecatedTag =
+      supportedTags.contains(lsp.CompletionItemTag.Deprecated);
   final formats = completionCapabilities?.completionItem?.documentationFormat;
   final supportsSnippets =
       completionCapabilities?.completionItem?.snippetSupport == true;
@@ -747,37 +789,47 @@
   // the generated JSON as much as possible - for example using nulls in place
   // of empty lists/false where possible.
   return lsp.CompletionItem(
-    label,
-    completionKind,
-    getCompletionDetail(suggestion, completionKind, useDeprecated),
-    asStringOrMarkupContent(formats, cleanDartdoc(suggestion.docComplete)),
-    useDeprecated && suggestion.isDeprecated ? true : null,
-    null, // preselect
+    label: label,
+    kind: completionKind,
+    tags: supportedTags.isNotEmpty
+        ? [
+            if (supportsDeprecatedTag && suggestion.isDeprecated)
+              lsp.CompletionItemTag.Deprecated
+          ]
+        : null,
+    detail: getCompletionDetail(suggestion, completionKind,
+        supportsDeprecatedFlag || supportsDeprecatedTag),
+    documentation:
+        asStringOrMarkupContent(formats, cleanDartdoc(suggestion.docComplete)),
+    deprecated: supportsDeprecatedFlag && suggestion.isDeprecated ? true : null,
     // Relevance is a number, highest being best. LSP does text sort so subtract
     // from a large number so that a text sort will result in the correct order.
     // 555 -> 999455
     //  10 -> 999990
     //   1 -> 999999
-    (1000000 - suggestion.relevance).toString(),
-    filterText != label ? filterText : null, // filterText uses label if not set
-    insertText != label ? insertText : null, // insertText uses label if not set
-    insertTextFormat != lsp.InsertTextFormat.PlainText
+    sortText: (1000000 - suggestion.relevance).toString(),
+    filterText: filterText != label
+        ? filterText
+        : null, // filterText uses label if not set
+    insertText: insertText != label
+        ? insertText
+        : null, // insertText uses label if not set
+    insertTextFormat: insertTextFormat != lsp.InsertTextFormat.PlainText
         ? insertTextFormat
         : null, // Defaults to PlainText if not supplied
-    lsp.TextEdit(
-      toRange(lineInfo, replacementOffset, replacementLength),
-      insertText,
+    textEdit: lsp.TextEdit(
+      range: toRange(lineInfo, replacementOffset, replacementLength),
+      newText: insertText,
     ),
-    null, // additionalTextEdits, used for adding imports, etc.
-    null, // commitCharacters
-    null, // command
-    null, // data, useful for if using lazy resolve, this comes back to us
   );
 }
 
 lsp.Diagnostic toDiagnostic(
-    server.ResolvedUnitResult result, server.AnalysisError error,
-    [server.ErrorSeverity errorSeverity]) {
+  server.ResolvedUnitResult result,
+  server.AnalysisError error, {
+  @required HashSet<lsp.DiagnosticTag> supportedTags,
+  server.ErrorSeverity errorSeverity,
+}) {
   var errorCode = error.errorCode;
 
   // Default to the error's severity if none is specified.
@@ -796,12 +848,13 @@
   }
 
   return lsp.Diagnostic(
-    toRange(result.lineInfo, error.offset, error.length),
-    toDiagnosticSeverity(errorSeverity),
-    errorCode.name.toLowerCase(),
-    languageSourceName,
-    message,
-    relatedInformation,
+    range: toRange(result.lineInfo, error.offset, error.length),
+    severity: toDiagnosticSeverity(errorSeverity),
+    code: errorCode.name.toLowerCase(),
+    source: languageSourceName,
+    message: message,
+    tags: getDiagnosticTags(supportedTags, error),
+    relatedInformation: relatedInformation,
   );
 }
 
@@ -810,15 +863,15 @@
   var file = message.filePath;
   var lineInfo = result.session.getFile(file).lineInfo;
   return lsp.DiagnosticRelatedInformation(
-      lsp.Location(
-        Uri.file(file).toString(),
-        toRange(
+      location: lsp.Location(
+        uri: Uri.file(file).toString(),
+        range: toRange(
           lineInfo,
           message.offset,
           message.length,
         ),
       ),
-      message.message);
+      message: message.message);
 }
 
 lsp.DiagnosticSeverity toDiagnosticSeverity(server.ErrorSeverity severity) {
@@ -840,14 +893,14 @@
 
 lsp.Element toElement(server.LineInfo lineInfo, server.Element element) =>
     lsp.Element(
-      element.location != null
+      range: element.location != null
           ? toRange(lineInfo, element.location.offset, element.location.length)
           : null,
-      toElementName(element),
-      element.kind.name,
-      element.parameters,
-      element.typeParameters,
-      element.returnType,
+      name: toElementName(element),
+      kind: element.kind.name,
+      parameters: element.parameters,
+      typeParameters: element.typeParameters,
+      returnType: element.returnType,
     );
 
 String toElementName(server.Element element) {
@@ -861,22 +914,22 @@
 lsp.FlutterOutline toFlutterOutline(
         server.LineInfo lineInfo, server.FlutterOutline outline) =>
     lsp.FlutterOutline(
-      outline.kind.name,
-      outline.label,
-      outline.className,
-      outline.variableName,
-      outline.attributes != null
+      kind: outline.kind.name,
+      label: outline.label,
+      className: outline.className,
+      variableName: outline.variableName,
+      attributes: outline.attributes != null
           ? outline.attributes
               .map(
                   (attribute) => toFlutterOutlineAttribute(lineInfo, attribute))
               .toList()
           : null,
-      outline.dartElement != null
+      dartElement: outline.dartElement != null
           ? toElement(lineInfo, outline.dartElement)
           : null,
-      toRange(lineInfo, outline.offset, outline.length),
-      toRange(lineInfo, outline.codeOffset, outline.codeLength),
-      outline.children != null
+      range: toRange(lineInfo, outline.offset, outline.length),
+      codeRange: toRange(lineInfo, outline.codeOffset, outline.codeLength),
+      children: outline.children != null
           ? outline.children.map((c) => toFlutterOutline(lineInfo, c)).toList()
           : null,
     );
@@ -884,9 +937,9 @@
 lsp.FlutterOutlineAttribute toFlutterOutlineAttribute(
         server.LineInfo lineInfo, server.FlutterOutlineAttribute attribute) =>
     lsp.FlutterOutlineAttribute(
-        attribute.name,
-        attribute.label,
-        attribute.valueLocation != null
+        name: attribute.name,
+        label: attribute.label,
+        valueRange: attribute.valueLocation != null
             ? toRange(lineInfo, attribute.valueLocation.offset,
                 attribute.valueLocation.length)
             : null);
@@ -894,8 +947,12 @@
 lsp.FoldingRange toFoldingRange(
     server.LineInfo lineInfo, server.FoldingRegion region) {
   final range = toRange(lineInfo, region.offset, region.length);
-  return lsp.FoldingRange(range.start.line, range.start.character,
-      range.end.line, range.end.character, toFoldingRangeKind(region.kind));
+  return lsp.FoldingRange(
+      startLine: range.start.line,
+      startCharacter: range.start.character,
+      endLine: range.end.line,
+      endCharacter: range.end.character,
+      kind: toFoldingRangeKind(region.kind));
 }
 
 lsp.FoldingRangeKind toFoldingRangeKind(server.FoldingKind kind) {
@@ -917,14 +974,14 @@
     server.LineInfo lineInfo, server.Occurrences occurrences) {
   return occurrences.offsets
       .map((offset) => lsp.DocumentHighlight(
-          toRange(lineInfo, offset, occurrences.length), null))
+          range: toRange(lineInfo, offset, occurrences.length)))
       .toList();
 }
 
 lsp.Location toLocation(server.Location location, server.LineInfo lineInfo) =>
     lsp.Location(
-      Uri.file(location.file).toString(),
-      toRange(
+      uri: Uri.file(location.file).toString(),
+      range: toRange(
         lineInfo,
         location.offset,
         location.length,
@@ -938,11 +995,11 @@
 }) {
   if (pos.line > lineInfo.lineCount) {
     return ErrorOr<int>.error(lsp.ResponseError(
-        failureIsCritial
+        code: failureIsCritial
             ? lsp.ServerErrorCodes.ClientServerInconsistentState
             : lsp.ServerErrorCodes.InvalidFileLineCol,
-        'Invalid line number',
-        pos.line.toString()));
+        message: 'Invalid line number',
+        data: pos.line.toString()));
   }
   // TODO(dantup): Is there any way to validate the character? We could ensure
   // it's less than the offset of the next line, but that would only work for
@@ -953,17 +1010,18 @@
 
 lsp.Outline toOutline(server.LineInfo lineInfo, server.Outline outline) =>
     lsp.Outline(
-      toElement(lineInfo, outline.element),
-      toRange(lineInfo, outline.offset, outline.length),
-      toRange(lineInfo, outline.codeOffset, outline.codeLength),
-      outline.children != null
+      element: toElement(lineInfo, outline.element),
+      range: toRange(lineInfo, outline.offset, outline.length),
+      codeRange: toRange(lineInfo, outline.codeOffset, outline.codeLength),
+      children: outline.children != null
           ? outline.children.map((c) => toOutline(lineInfo, c)).toList()
           : null,
     );
 
 lsp.Position toPosition(server.CharacterLocation location) {
   // LSP is zero-based, but analysis server is 1-based.
-  return lsp.Position(location.lineNumber - 1, location.columnNumber - 1);
+  return lsp.Position(
+      line: location.lineNumber - 1, character: location.columnNumber - 1);
 }
 
 lsp.Range toRange(server.LineInfo lineInfo, int offset, int length) {
@@ -971,8 +1029,8 @@
   server.CharacterLocation end = lineInfo.getLocation(offset + length);
 
   return lsp.Range(
-    toPosition(start),
-    toPosition(end),
+    start: toPosition(start),
+    end: toPosition(end),
   );
 }
 
@@ -1019,20 +1077,20 @@
     // to guess based on substrings). We should check the
     // signatureHelp.signatureInformation.parameterInformation.labelOffsetSupport
     // capability when deciding to send that.
-    return lsp.ParameterInformation(getParamLabel(param), null);
+    return lsp.ParameterInformation(label: getParamLabel(param));
   }
 
   final cleanDoc = cleanDartdoc(signature.dartdoc);
 
   return lsp.SignatureHelp(
-    [
+    signatures: [
       lsp.SignatureInformation(
-        getSignatureLabel(signature),
-        asStringOrMarkupContent(preferredFormats, cleanDoc),
-        signature.parameters.map(toParameterInfo).toList(),
+        label: getSignatureLabel(signature),
+        documentation: asStringOrMarkupContent(preferredFormats, cleanDoc),
+        parameters: signature.parameters.map(toParameterInfo).toList(),
       ),
     ],
-    0, // activeSignature
+    activeSignature: 0, // activeSignature
     // TODO(dantup): The LSP spec says this value will default to 0 if it's
     // not supplied or outside of the value range. However, setting -1 results
     // in no parameters being selected in VS Code, whereas null/0 will select the first.
@@ -1041,42 +1099,41 @@
     // (because you could also be on param 5 of an invalid call to a function
     // taking only 3 arguments) here:
     // https://github.com/Microsoft/language-server-protocol/issues/456#issuecomment-452318297
-    -1, // activeParameter
+    activeParameter: -1, // activeParameter
   );
 }
 
 lsp.TextDocumentEdit toTextDocumentEdit(FileEditInformation edit) {
   return lsp.TextDocumentEdit(
-    edit.doc,
-    edit.edits.map((e) => toTextEdit(edit.lineInfo, e)).toList(),
+    textDocument: edit.doc,
+    edits: edit.edits.map((e) => toTextEdit(edit.lineInfo, e)).toList(),
   );
 }
 
 lsp.TextEdit toTextEdit(server.LineInfo lineInfo, server.SourceEdit edit) {
   return lsp.TextEdit(
-    toRange(lineInfo, edit.offset, edit.length),
-    edit.replacement,
+    range: toRange(lineInfo, edit.offset, edit.length),
+    newText: edit.replacement,
   );
 }
 
 lsp.WorkspaceEdit toWorkspaceEdit(
-  lsp.WorkspaceClientCapabilities capabilities,
+  lsp.ClientCapabilitiesWorkspace capabilities,
   List<FileEditInformation> edits,
 ) {
   final clientSupportsTextDocumentEdits =
       capabilities?.workspaceEdit?.documentChanges == true;
   if (clientSupportsTextDocumentEdits) {
     return lsp.WorkspaceEdit(
-        null,
-        Either2<
+        documentChanges: Either2<
             List<lsp.TextDocumentEdit>,
             List<
                 Either4<lsp.TextDocumentEdit, lsp.CreateFile, lsp.RenameFile,
                     lsp.DeleteFile>>>.t1(
-          edits.map(toTextDocumentEdit).toList(),
-        ));
+      edits.map(toTextDocumentEdit).toList(),
+    ));
   } else {
-    return lsp.WorkspaceEdit(toWorkspaceEditChanges(edits), null);
+    return lsp.WorkspaceEdit(changes: toWorkspaceEditChanges(edits));
   }
 }
 
@@ -1114,5 +1171,5 @@
       ? lsp.MarkupKind.PlainText
       : lsp.MarkupKind.Markdown;
 
-  return lsp.MarkupContent(format, content);
+  return lsp.MarkupContent(kind: format, value: content);
 }
diff --git a/pkg/analysis_server/lib/src/lsp/notification_manager.dart b/pkg/analysis_server/lib/src/lsp/notification_manager.dart
index 242cba5..068b5ef 100644
--- a/pkg/analysis_server/lib/src/lsp/notification_manager.dart
+++ b/pkg/analysis_server/lib/src/lsp/notification_manager.dart
@@ -32,12 +32,12 @@
         .map((error) => pluginToDiagnostic(server.getLineInfo, error))
         .toList();
 
-    final params =
-        PublishDiagnosticsParams(Uri.file(filePath).toString(), diagnostics);
+    final params = PublishDiagnosticsParams(
+        uri: Uri.file(filePath).toString(), diagnostics: diagnostics);
     final message = NotificationMessage(
-      Method.textDocument_publishDiagnostics,
-      params,
-      jsonRpcVersion,
+      method: Method.textDocument_publishDiagnostics,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
 
     channel.sendNotification(message);
diff --git a/pkg/analysis_server/lib/src/lsp/server_capabilities_computer.dart b/pkg/analysis_server/lib/src/lsp/server_capabilities_computer.dart
index fd345d1..617a6f6 100644
--- a/pkg/analysis_server/lib/src/lsp/server_capabilities_computer.dart
+++ b/pkg/analysis_server/lib/src/lsp/server_capabilities_computer.dart
@@ -116,77 +116,93 @@
     // list of what files types we support (and allows them to avoid sending
     // requests where we have only partial support for some types).
     return ServerCapabilities(
-        dynamicRegistrations.textSync
-            ? null
-            : Either2<TextDocumentSyncOptions, num>.t1(TextDocumentSyncOptions(
-                // The open/close and sync kind flags are registered dynamically if the
-                // client supports them, so these static registrations are based on whether
-                // the client supports dynamic registration.
-                true,
-                TextDocumentSyncKind.Incremental,
-                false,
-                false,
-                null,
-              )),
-        dynamicRegistrations.hover ? null : true, // hoverProvider
-        dynamicRegistrations.completion
-            ? null
-            : CompletionOptions(
-                true, // resolveProvider
-                dartCompletionTriggerCharacters,
-              ),
-        dynamicRegistrations.signatureHelp
-            ? null
-            : SignatureHelpOptions(
-                dartSignatureHelpTriggerCharacters,
-              ),
-        dynamicRegistrations.definition ? null : true, // definitionProvider
-        null,
-        dynamicRegistrations.implementation
-            ? null
-            : true, // implementationProvider
-        dynamicRegistrations.references ? null : true, // referencesProvider
-        dynamicRegistrations.documentHighlights
-            ? null
-            : true, // documentHighlightProvider
-        dynamicRegistrations.documentSymbol
-            ? null
-            : true, // documentSymbolProvider
-        true, // workspaceSymbolProvider
-        // "The `CodeActionOptions` return type is only valid if the client
-        // signals code action literal support via the property
-        // `textDocument.codeAction.codeActionLiteralSupport`."
-        dynamicRegistrations.codeActions
-            ? null
-            : codeActionLiteralSupport != null
-                ? Either2<bool, CodeActionOptions>.t2(
-                    CodeActionOptions(DartCodeActionKind.serverSupportedKinds))
-                : Either2<bool, CodeActionOptions>.t1(true),
-        null,
-        dynamicRegistrations.formatting
-            ? null
-            : enableFormatter, // documentFormattingProvider
-        false, // documentRangeFormattingProvider
-        dynamicRegistrations.typeFormatting
-            ? null
-            : enableFormatter
-                ? DocumentOnTypeFormattingOptions(
-                    dartTypeFormattingCharacters.first,
-                    dartTypeFormattingCharacters.skip(1).toList())
-                : null,
-        dynamicRegistrations.rename
-            ? null
-            : renameOptionsSupport
-                ? Either2<bool, RenameOptions>.t2(RenameOptions(true))
-                : Either2<bool, RenameOptions>.t1(true),
-        null,
-        null,
-        dynamicRegistrations.folding ? null : true, // foldingRangeProvider
-        null, // declarationProvider
-        ExecuteCommandOptions(Commands.serverSupportedCommands),
-        ServerCapabilitiesWorkspace(
-            ServerCapabilitiesWorkspaceFolders(true, true)),
-        null);
+      textDocumentSync: dynamicRegistrations.textSync
+          ? null
+          : Either2<TextDocumentSyncOptions, num>.t1(TextDocumentSyncOptions(
+              // The open/close and sync kind flags are registered dynamically if the
+              // client supports them, so these static registrations are based on whether
+              // the client supports dynamic registration.
+              openClose: true,
+              change: TextDocumentSyncKind.Incremental,
+              willSave: false,
+              willSaveWaitUntil: false,
+              save: null,
+            )),
+      completionProvider: dynamicRegistrations.completion
+          ? null
+          : CompletionOptions(
+              triggerCharacters: dartCompletionTriggerCharacters,
+              resolveProvider: true,
+            ),
+      hoverProvider: dynamicRegistrations.hover
+          ? null
+          : Either2<bool, HoverOptions>.t1(true),
+      signatureHelpProvider: dynamicRegistrations.signatureHelp
+          ? null
+          : SignatureHelpOptions(
+              triggerCharacters: dartSignatureHelpTriggerCharacters,
+            ),
+      definitionProvider: dynamicRegistrations.definition
+          ? null
+          : Either2<bool, DefinitionOptions>.t1(true),
+      implementationProvider: dynamicRegistrations.implementation
+          ? null
+          : Either3<bool, ImplementationOptions,
+              ImplementationRegistrationOptions>.t1(
+              true,
+            ),
+      referencesProvider: dynamicRegistrations.references
+          ? null
+          : Either2<bool, ReferenceOptions>.t1(true),
+      documentHighlightProvider: dynamicRegistrations.documentHighlights
+          ? null
+          : Either2<bool, DocumentHighlightOptions>.t1(true),
+      documentSymbolProvider: dynamicRegistrations.documentSymbol
+          ? null
+          : Either2<bool, DocumentSymbolOptions>.t1(true),
+      // "The `CodeActionOptions` return type is only valid if the client
+      // signals code action literal support via the property
+      // `textDocument.codeAction.codeActionLiteralSupport`."
+      codeActionProvider: dynamicRegistrations.codeActions
+          ? null
+          : codeActionLiteralSupport != null
+              ? Either2<bool, CodeActionOptions>.t2(CodeActionOptions(
+                  codeActionKinds: DartCodeActionKind.serverSupportedKinds,
+                ))
+              : Either2<bool, CodeActionOptions>.t1(true),
+      documentFormattingProvider: dynamicRegistrations.formatting
+          ? null
+          : Either2<bool, DocumentFormattingOptions>.t1(enableFormatter),
+      documentOnTypeFormattingProvider: dynamicRegistrations.typeFormatting
+          ? null
+          : enableFormatter
+              ? DocumentOnTypeFormattingOptions(
+                  firstTriggerCharacter: dartTypeFormattingCharacters.first,
+                  moreTriggerCharacter:
+                      dartTypeFormattingCharacters.skip(1).toList())
+              : null,
+      renameProvider: dynamicRegistrations.rename
+          ? null
+          : renameOptionsSupport
+              ? Either2<bool, RenameOptions>.t2(
+                  RenameOptions(prepareProvider: true))
+              : Either2<bool, RenameOptions>.t1(true),
+      foldingRangeProvider: dynamicRegistrations.folding
+          ? null
+          : Either3<bool, FoldingRangeOptions,
+              FoldingRangeRegistrationOptions>.t1(
+              true,
+            ),
+      executeCommandProvider: ExecuteCommandOptions(
+        commands: Commands.serverSupportedCommands,
+      ),
+      workspaceSymbolProvider: true,
+      workspace: ServerCapabilitiesWorkspace(
+          workspaceFolders: WorkspaceFoldersServerCapabilities(
+        supported: true,
+        changeNotifications: Either2<String, bool>.t2(true),
+      )),
+    );
   }
 
   /// If the client supports dynamic registrations we can tell it what methods
@@ -197,17 +213,18 @@
   /// support and it will be up to them to decide which file types they will
   /// send requests for.
   Future<void> performDynamicRegistration() async {
-    final dartFiles = DocumentFilter('dart', 'file', null);
-    final pubspecFile = DocumentFilter('yaml', 'file', '**/pubspec.yaml');
-    final analysisOptionsFile =
-        DocumentFilter('yaml', 'file', '**/analysis_options.yaml');
+    final dartFiles = DocumentFilter(language: 'dart', scheme: 'file');
+    final pubspecFile = DocumentFilter(
+        language: 'yaml', scheme: 'file', pattern: '**/pubspec.yaml');
+    final analysisOptionsFile = DocumentFilter(
+        language: 'yaml', scheme: 'file', pattern: '**/analysis_options.yaml');
 
     final pluginTypes = _server.pluginManager.plugins
         .expand((plugin) => plugin.currentSession?.interestingFiles ?? const [])
         // All published plugins use something like `*.extension` as
         // interestingFiles. Prefix a `**/` so that the glob matches nested
         // folders as well.
-        .map((glob) => DocumentFilter(null, 'file', '**/$glob'));
+        .map((glob) => DocumentFilter(scheme: 'file', pattern: '**/$glob'));
 
     final allTypes = {dartFiles, ...pluginTypes}.toList();
 
@@ -230,7 +247,9 @@
     void register(bool condition, Method method, [ToJsonable options]) {
       if (condition == true) {
         registrations.add(Registration(
-            (_lastRegistrationId++).toString(), method.toJson(), options));
+            id: (_lastRegistrationId++).toString(),
+            method: method.toJson(),
+            registerOptions: options));
       }
     }
 
@@ -240,94 +259,99 @@
     register(
       dynamicRegistrations.textSync,
       Method.textDocument_didOpen,
-      TextDocumentRegistrationOptions(allSynchronisedTypes),
+      TextDocumentRegistrationOptions(documentSelector: allSynchronisedTypes),
     );
     register(
       dynamicRegistrations.textSync,
       Method.textDocument_didClose,
-      TextDocumentRegistrationOptions(allSynchronisedTypes),
+      TextDocumentRegistrationOptions(documentSelector: allSynchronisedTypes),
     );
     register(
       dynamicRegistrations.textSync,
       Method.textDocument_didChange,
       TextDocumentChangeRegistrationOptions(
-          TextDocumentSyncKind.Incremental, allSynchronisedTypes),
+          syncKind: TextDocumentSyncKind.Incremental,
+          documentSelector: allSynchronisedTypes),
     );
     register(
       dynamicRegistrations.completion,
       Method.textDocument_completion,
       CompletionRegistrationOptions(
-        dartCompletionTriggerCharacters,
-        null,
-        true,
-        allTypes,
+        documentSelector: allTypes,
+        triggerCharacters: dartCompletionTriggerCharacters,
+        resolveProvider: true,
       ),
     );
     register(
       dynamicRegistrations.hover,
       Method.textDocument_hover,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.signatureHelp,
       Method.textDocument_signatureHelp,
       SignatureHelpRegistrationOptions(
-          dartSignatureHelpTriggerCharacters, allTypes),
+        documentSelector: allTypes,
+        triggerCharacters: dartSignatureHelpTriggerCharacters,
+      ),
     );
     register(
       dynamicRegistrations.references,
       Method.textDocument_references,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.documentHighlights,
       Method.textDocument_documentHighlight,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.documentSymbol,
       Method.textDocument_documentSymbol,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       enableFormatter && dynamicRegistrations.formatting,
       Method.textDocument_formatting,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       enableFormatter && dynamicRegistrations.typeFormatting,
       Method.textDocument_onTypeFormatting,
       DocumentOnTypeFormattingRegistrationOptions(
-        dartTypeFormattingCharacters.first,
-        dartTypeFormattingCharacters.skip(1).toList(),
-        [dartFiles], // This one is currently Dart-specific
+        documentSelector: [dartFiles], // This one is currently Dart-specific
+        firstTriggerCharacter: dartTypeFormattingCharacters.first,
+        moreTriggerCharacter: dartTypeFormattingCharacters.skip(1).toList(),
       ),
     );
     register(
       dynamicRegistrations.definition,
       Method.textDocument_definition,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.implementation,
       Method.textDocument_implementation,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.codeActions,
       Method.textDocument_codeAction,
       CodeActionRegistrationOptions(
-          allTypes, DartCodeActionKind.serverSupportedKinds),
+        documentSelector: allTypes,
+        codeActionKinds: DartCodeActionKind.serverSupportedKinds,
+      ),
     );
     register(
       dynamicRegistrations.rename,
       Method.textDocument_rename,
-      RenameRegistrationOptions(true, allTypes),
+      RenameRegistrationOptions(
+          documentSelector: allTypes, prepareProvider: true),
     );
     register(
       dynamicRegistrations.folding,
       Method.textDocument_foldingRange,
-      TextDocumentRegistrationOptions(allTypes),
+      TextDocumentRegistrationOptions(documentSelector: allTypes),
     );
     register(
       dynamicRegistrations.didChangeConfiguration,
@@ -358,8 +382,8 @@
           registration.registerOptions;
 
       if (entryRemovedOrChanged) {
-        removedRegistrations
-            .add(Unregistration(registration.id, registration.method));
+        removedRegistrations.add(
+            Unregistration(id: registration.id, method: registration.method));
       } else {
         // Replace the registration in our new set with the original registration
         // so that we retain the original ID sent to the client (otherwise we
@@ -373,7 +397,7 @@
 
     if (removedRegistrations.isNotEmpty) {
       await _server.sendRequest(Method.client_unregisterCapability,
-          UnregistrationParams(removedRegistrations));
+          UnregistrationParams(unregisterations: removedRegistrations));
     }
 
     // Only send the registration request if we have at least one (since
@@ -381,7 +405,7 @@
     if (additionalRegistrations.isNotEmpty) {
       final registrationResponse = await _server.sendRequest(
         Method.client_registerCapability,
-        RegistrationParams(additionalRegistrations),
+        RegistrationParams(registrations: additionalRegistrations),
       );
 
       if (registrationResponse.error != null) {
diff --git a/pkg/analysis_server/lib/src/lsp/source_edits.dart b/pkg/analysis_server/lib/src/lsp/source_edits.dart
index e3bfb8a..167fc49 100644
--- a/pkg/analysis_server/lib/src/lsp/source_edits.dart
+++ b/pkg/analysis_server/lib/src/lsp/source_edits.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer_plugin/utilities/pair.dart';
 import 'package:dart_style/dart_style.dart';
 
-final DartFormatter formatter = DartFormatter();
+DartFormatter formatter = DartFormatter();
 
 /// Transforms a sequence of LSP document change events to a sequence of source
 /// edits used by analysis plugins.
@@ -17,45 +17,66 @@
 /// changes into account, this will also apply the edits to [oldContent].
 ErrorOr<Pair<String, List<plugin.SourceEdit>>> applyAndConvertEditsToServer(
   String oldContent,
-  List<TextDocumentContentChangeEvent> changes, {
+  List<
+          Either2<TextDocumentContentChangeEvent1,
+              TextDocumentContentChangeEvent2>>
+      changes, {
   failureIsCritical = false,
 }) {
   var newContent = oldContent;
   final serverEdits = <server.SourceEdit>[];
 
   for (var change in changes) {
-    if (change.range == null && change.rangeLength == null) {
-      serverEdits
-        ..clear()
-        ..add(server.SourceEdit(0, newContent.length, change.text));
-      newContent = change.text;
-    } else {
-      final lines = LineInfo.fromContent(newContent);
-      final offsetStart = toOffset(lines, change.range.start,
-          failureIsCritial: failureIsCritical);
-      final offsetEnd = toOffset(lines, change.range.end,
-          failureIsCritial: failureIsCritical);
-      if (offsetStart.isError) {
-        return ErrorOr.error(offsetStart.error);
-      }
-      if (offsetEnd.isError) {
-        return ErrorOr.error(offsetEnd.error);
-      }
-      newContent = newContent.replaceRange(
-          offsetStart.result, offsetEnd.result, change.text);
-      serverEdits.add(server.SourceEdit(offsetStart.result,
-          offsetEnd.result - offsetStart.result, change.text));
+    // Change is a union that may/may not include a range. If no range
+    // is provided (t2 of the union) the whole document should be replaced.
+    final result = change.map(
+      // TextDocumentContentChangeEvent1
+      // {range, text}
+      (change) {
+        final lines = LineInfo.fromContent(newContent);
+        final offsetStart = toOffset(lines, change.range.start,
+            failureIsCritial: failureIsCritical);
+        final offsetEnd = toOffset(lines, change.range.end,
+            failureIsCritial: failureIsCritical);
+        if (offsetStart.isError) {
+          return ErrorOr.error(offsetStart.error);
+        }
+        if (offsetEnd.isError) {
+          return ErrorOr.error(offsetEnd.error);
+        }
+        newContent = newContent.replaceRange(
+            offsetStart.result, offsetEnd.result, change.text);
+        serverEdits.add(server.SourceEdit(offsetStart.result,
+            offsetEnd.result - offsetStart.result, change.text));
+      },
+      // TextDocumentContentChangeEvent2
+      // {text}
+      (change) {
+        serverEdits
+          ..clear()
+          ..add(server.SourceEdit(0, newContent.length, change.text));
+        newContent = change.text;
+      },
+    );
+    // If any change fails, immediately return the error.
+    if (result?.isError ?? false) {
+      return ErrorOr.error(result.error);
     }
   }
   return ErrorOr.success(Pair(newContent, serverEdits));
 }
 
-List<TextEdit> generateEditsForFormatting(String unformattedSource) {
+List<TextEdit> generateEditsForFormatting(
+    String unformattedSource, int lineLength) {
   final lineInfo = LineInfo.fromContent(unformattedSource);
   final code =
       SourceCode(unformattedSource, uri: null, isCompilationUnit: true);
   SourceCode formattedResult;
   try {
+    // If the lineLength has changed, recreate the formatter with the new setting.
+    if (lineLength != formatter.pageWidth) {
+      formatter = DartFormatter(pageWidth: lineLength);
+    }
     formattedResult = formatter.formatSource(code);
   } on FormatterException {
     // If the document fails to parse, just return no edits to avoid the the
@@ -75,8 +96,9 @@
   final end = lineInfo.getLocation(unformattedSource.length);
   return [
     TextEdit(
-      Range(Position(0, 0), toPosition(end)),
-      formattedSource,
+      range:
+          Range(start: Position(line: 0, character: 0), end: toPosition(end)),
+      newText: formattedSource,
     )
   ];
 }
diff --git a/pkg/analysis_server/lib/src/plugin/plugin_manager.dart b/pkg/analysis_server/lib/src/plugin/plugin_manager.dart
index 50456a7..2b23663 100644
--- a/pkg/analysis_server/lib/src/plugin/plugin_manager.dart
+++ b/pkg/analysis_server/lib/src/plugin/plugin_manager.dart
@@ -122,10 +122,7 @@
   /// currently being executed.
   PluginSession currentSession;
 
-  /// The exception that occurred that prevented the plugin from being started,
-  /// or `null` if there was no exception (possibly because no attempt has yet
-  /// been made to start the plugin).
-  CaughtException exception;
+  CaughtException _exception;
 
   /// Initialize the newly created information about a plugin.
   PluginInfo(this.notificationManager, this.instrumentationService);
@@ -140,6 +137,11 @@
   PluginData get data =>
       PluginData(pluginId, currentSession?.name, currentSession?.version);
 
+  /// The exception that occurred that prevented the plugin from being started,
+  /// or `null` if there was no exception (possibly because no attempt has yet
+  /// been made to start the plugin).
+  CaughtException get exception => _exception;
+
   /// Return the id of this plugin, used to identify the plugin to users.
   String get pluginId;
 
@@ -184,6 +186,12 @@
     }
   }
 
+  void reportException(CaughtException exception) {
+    _exception = exception;
+    instrumentationService.logPluginException(
+        data, exception.exception, exception.stackTrace);
+  }
+
   /// If the plugin is currently running, send a request based on the given
   /// [params] to the plugin. If the plugin is not running, the request will
   /// silently be dropped.
@@ -209,6 +217,10 @@
   /// Request that the plugin shutdown.
   Future<void> stop() {
     if (currentSession == null) {
+      if (_exception != null) {
+        // Plugin crashed, nothing to do.
+        return Future<void>.value(null);
+      }
       throw StateError('Cannot stop a plugin that is not running.');
     }
     var doneFuture = currentSession.stop();
@@ -306,7 +318,7 @@
       } catch (exception, stackTrace) {
         plugin = DiscoveredPluginInfo(
             path, null, null, notificationManager, instrumentationService);
-        plugin.exception = CaughtException(exception, stackTrace);
+        plugin.reportException(CaughtException(exception, stackTrace));
         _pluginMap[path] = plugin;
         return;
       }
@@ -323,7 +335,7 @@
         } catch (exception, stackTrace) {
           // Record the exception (for debugging purposes) and record the fact
           // that we should not try to communicate with the plugin.
-          plugin.exception = CaughtException(exception, stackTrace);
+          plugin.reportException(CaughtException(exception, stackTrace));
           isNew = false;
         }
       }
@@ -459,7 +471,7 @@
       var pluginPath = path.join(hostPackageName, 'tools', 'analyzer_plugin');
       var plugin = DiscoveredPluginInfo(
           pluginPath, null, null, notificationManager, instrumentationService);
-      plugin.exception = CaughtException(exception, stackTrace);
+      plugin.reportException(CaughtException(exception, stackTrace));
       _pluginMap[pluginPath] = plugin;
     }
   }
@@ -843,9 +855,8 @@
   void handleOnError(dynamic error) {
     var errorPair = (error as List).cast<String>();
     var stackTrace = StackTrace.fromString(errorPair[1]);
-    info.exception = CaughtException(PluginException(errorPair[0]), stackTrace);
-    info.instrumentationService
-        .logPluginException(info.data, errorPair[0], stackTrace);
+    info.reportException(
+        CaughtException(PluginException(errorPair[0]), stackTrace));
   }
 
   /// Handle a [response] from the plugin by completing the future that was
@@ -903,13 +914,13 @@
       throw StateError('Missing byte store path');
     }
     if (!isCompatible) {
-      info.exception =
-          CaughtException(PluginException('Plugin is not compatible.'), null);
+      info.reportException(
+          CaughtException(PluginException('Plugin is not compatible.'), null));
       return false;
     }
     if (!info.canBeStarted) {
-      info.exception =
-          CaughtException(PluginException('Plugin cannot be started.'), null);
+      info.reportException(
+          CaughtException(PluginException('Plugin cannot be started.'), null));
       return false;
     }
     channel = info._createChannel();
@@ -920,8 +931,9 @@
     if (channel == null) {
       // If there is an error when starting the isolate, the channel will invoke
       // handleOnDone, which will cause `channel` to be set to `null`.
-      info.exception ??= CaughtException(
-          PluginException('Unrecorded error while starting the plugin.'), null);
+      info.reportException(CaughtException(
+          PluginException('Unrecorded error while starting the plugin.'),
+          null));
       return false;
     }
     var response = await sendRequest(PluginVersionCheckParams(
@@ -934,8 +946,8 @@
     version = result.version;
     if (!isCompatible) {
       sendRequest(PluginShutdownParams());
-      info.exception =
-          CaughtException(PluginException('Plugin is not compatible.'), null);
+      info.reportException(
+          CaughtException(PluginException('Plugin is not compatible.'), null));
       return false;
     }
     return true;
diff --git a/pkg/analysis_server/lib/src/server/driver.dart b/pkg/analysis_server/lib/src/server/driver.dart
index cc0f406..78a4734 100644
--- a/pkg/analysis_server/lib/src/server/driver.dart
+++ b/pkg/analysis_server/lib/src/server/driver.dart
@@ -38,6 +38,7 @@
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:args/args.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:linter/src/rules.dart' as linter;
 import 'package:path/path.dart' as path;
 import 'package:telemetry/crash_reporting.dart';
@@ -844,11 +845,7 @@
     if (args[SDK_OPTION] != null) {
       return args[SDK_OPTION];
     } else {
-      // No path to the SDK was provided.
-      // Use FolderBasedDartSdk.defaultSdkDirectory, which will make a guess.
-      return FolderBasedDartSdk.defaultSdkDirectory(
-        PhysicalResourceProvider.INSTANCE,
-      ).path;
+      return getSdkPath();
     }
   }
 
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/arglist_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/arglist_contributor.dart
index 14fbe05..cc88ab0 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/arglist_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/arglist_contributor.dart
@@ -163,7 +163,7 @@
   }
 
   bool _isInFlutterCreation() {
-    var flutter = Flutter.of(request.result);
+    var flutter = Flutter.instance;
     var containingNode = request.target?.containingNode;
     var newExpr = containingNode != null
         ? flutter.identifyNewExpression(containingNode.parent)
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/completion_manager.dart b/pkg/analysis_server/lib/src/services/completion/dart/completion_manager.dart
index 1118ce0..2d677c2 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/completion_manager.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/completion_manager.dart
@@ -27,6 +27,7 @@
 import 'package:analysis_server/src/services/completion/dart/local_reference_contributor.dart';
 import 'package:analysis_server/src/services/completion/dart/named_constructor_contributor.dart';
 import 'package:analysis_server/src/services/completion/dart/override_contributor.dart';
+import 'package:analysis_server/src/services/completion/dart/relevance_tables.g.dart';
 import 'package:analysis_server/src/services/completion/dart/static_member_contributor.dart';
 import 'package:analysis_server/src/services/completion/dart/suggestion_builder.dart';
 import 'package:analysis_server/src/services/completion/dart/type_member_contributor.dart';
@@ -242,9 +243,25 @@
   }
 
   void _addIncludedSuggestionRelevanceTags(DartCompletionRequestImpl request) {
-    if (request.inConstantContext && request.useNewRelevance) {
-      includedSuggestionRelevanceTags.add(IncludedSuggestionRelevanceTag(
-          'isConst', RelevanceBoost.constInConstantContext));
+    if (request.useNewRelevance) {
+      var location = request.opType.completionLocation;
+      if (location != null) {
+        var locationTable = elementKindRelevance[location];
+        if (locationTable != null) {
+          var inConstantContext = request.inConstantContext;
+          for (var entry in locationTable.entries) {
+            var kind = entry.key.toString();
+            var elementBoost = (entry.value.upper * 100).floor();
+            includedSuggestionRelevanceTags
+                .add(IncludedSuggestionRelevanceTag(kind, elementBoost));
+            if (inConstantContext) {
+              includedSuggestionRelevanceTags.add(
+                  IncludedSuggestionRelevanceTag(
+                      '$kind+const', elementBoost + 100));
+            }
+          }
+        }
+      }
     }
 
     var type = request.contextType;
@@ -262,6 +279,12 @@
           ),
         );
       } else {
+        // TODO(brianwilkerson) This was previously used to boost exact type
+        //  matches. For example, if the context type was `Foo`, then the class
+        //  `Foo` and it's constructors would be given this boost. Now this
+        //  boost will almost always be ignored because the element boost will
+        //  be bigger. Find a way to use this boost without negating the element
+        //  boost, which is how we get constructors to come before classes.
         var relevance = request.useNewRelevance
             ? RelevanceBoost.availableDeclaration
             : DART_RELEVANCE_BOOST_AVAILABLE_DECLARATION;
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/extension_member_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/extension_member_contributor.dart
index 3ad8d5b..001ef8d 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/extension_member_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/extension_member_contributor.dart
@@ -98,7 +98,7 @@
 
   void _addExtensionMembers(LibraryElement containingLibrary, DartType type) {
     var typeSystem = containingLibrary.typeSystem;
-    var nameScope = LibraryScope(containingLibrary);
+    var nameScope = containingLibrary.scope;
     for (var extension in nameScope.extensions) {
       var extendedType =
           _resolveExtendedType(containingLibrary, extension, type);
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/suggestion_builder.dart b/pkg/analysis_server/lib/src/services/completion/dart/suggestion_builder.dart
index 6e3ebea..6583dcd 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/suggestion_builder.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/suggestion_builder.dart
@@ -23,7 +23,7 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/util/comment.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 import 'package:meta/meta.dart';
 
@@ -164,17 +164,12 @@
   /// computed. In the latter case, [_hasContainingMemberName] will be `false`.
   String _cachedContainingMemberName;
 
-  /// The cached instance of the flutter utilities, or `null` if it hasn't been
-  /// created yet.
-  Flutter _flutter;
-
   /// Initialize a newly created suggestion builder to build suggestions for the
   /// given [request].
   SuggestionBuilder(this.request, {this.listener});
 
-  /// Return an object that can answer questions about Flutter code based on the
-  /// flavor of Flutter being used.
-  Flutter get flutter => _flutter ??= Flutter.of(request.result);
+  /// Return an object that can answer questions about Flutter code.
+  Flutter get flutter => Flutter.instance;
 
   /// Return an iterable that can be used to access the completion suggestions
   /// that have been built.
@@ -803,8 +798,7 @@
     // todo (pq): revisit this special casing; likely it can be generalized away
     var element = parameter.enclosingElement;
     if (element is ConstructorElement) {
-      var flutter = Flutter.of(request.result);
-      if (flutter.isWidget(element.enclosingElement)) {
+      if (Flutter.instance.isWidget(element.enclosingElement)) {
         var defaultValue = getDefaultStringParameterValue(parameter);
         // TODO(devoncarew): Should we remove the check here? We would then
         // suggest values for param types like closures.
@@ -856,8 +850,8 @@
   Future<void> suggestOverride(SimpleIdentifier targetId,
       ExecutableElement element, bool invokeSuper) async {
     var displayTextBuffer = StringBuffer();
-    var builder = DartChangeBuilder(request.result.session);
-    await builder.addFileEdit(request.result.path, (builder) {
+    var builder = ChangeBuilder(session: request.result.session);
+    await builder.addDartFileEdit(request.result.path, (builder) {
       builder.addReplacement(range.node(targetId), (builder) {
         builder.writeOverride(
           element,
diff --git a/pkg/analysis_server/lib/src/services/completion/postfix/postfix_completion.dart b/pkg/analysis_server/lib/src/services/completion/postfix/postfix_completion.dart
index 4d2409c..b743ff3 100644
--- a/pkg/analysis_server/lib/src/services/completion/postfix/postfix_completion.dart
+++ b/pkg/analysis_server/lib/src/services/completion/postfix/postfix_completion.dart
@@ -16,7 +16,7 @@
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/generated/java_core.dart';
 import 'package:analyzer/src/generated/source.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 /// An enumeration of possible postfix completion kinds.
@@ -288,9 +288,9 @@
       return null;
     }
 
-    var changeBuilder = DartChangeBuilder(session);
-    await changeBuilder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(expr), (DartEditBuilder builder) {
+    var changeBuilder = ChangeBuilder(session: session);
+    await changeBuilder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(expr), (builder) {
         String newSrc = sourcer(expr);
         if (newSrc == null) {
           return null;
@@ -322,8 +322,8 @@
     if (stmt == null) {
       return null;
     }
-    var changeBuilder = DartChangeBuilder(session);
-    await changeBuilder.addFileEdit(file, (DartFileEditBuilder builder) {
+    var changeBuilder = ChangeBuilder(session: session);
+    await changeBuilder.addDartFileEdit(file, (builder) {
       // Embed the full line(s) of the statement in the try block.
       var startLine = lineInfo.getLocation(stmt.offset).lineNumber - 1;
       var endLine = lineInfo.getLocation(stmt.end).lineNumber - 1;
@@ -335,7 +335,7 @@
       var src = utils.getText(startOffset, endOffset - startOffset);
       var indent = utils.getLinePrefix(stmt.offset);
       builder.addReplacement(range.startOffsetEndOffset(startOffset, endOffset),
-          (DartEditBuilder builder) {
+          (builder) {
         builder.write(indent);
         builder.write('try {');
         builder.write(eol);
@@ -500,7 +500,7 @@
       .searchWithin(completionContext.resolveResult.unit);
 
   void _setCompletionFromBuilder(
-      DartChangeBuilder builder, PostfixCompletionKind kind,
+      ChangeBuilder builder, PostfixCompletionKind kind,
       [List args]) {
     var change = builder.sourceChange;
     if (change.edits.isEmpty) {
diff --git a/pkg/analysis_server/lib/src/services/correction/assist_internal.dart b/pkg/analysis_server/lib/src/services/correction/assist_internal.dart
index f0074a511..2f3c330 100644
--- a/pkg/analysis_server/lib/src/services/correction/assist_internal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/assist_internal.dart
@@ -72,10 +72,9 @@
 import 'package:analysis_server/src/services/correction/dart/use_curly_braces.dart';
 import 'package:analysis_server/src/services/correction/fix_internal.dart';
 import 'package:analyzer/src/generated/java_core.dart';
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart'
     hide AssistContributor;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 /// The computer for Dart assists.
 class AssistProcessor extends BaseProcessor {
@@ -195,7 +194,7 @@
     Future<void> compute(CorrectionProducer producer) async {
       producer.configure(context);
 
-      var builder = DartChangeBuilderImpl.forWorkspace(context.workspace);
+      var builder = ChangeBuilder(workspace: context.workspace);
       await producer.compute(builder);
 
       _addAssistFromBuilder(builder, producer.assistKind,
@@ -217,7 +216,7 @@
     return assists;
   }
 
-  void _addAssistFromBuilder(DartChangeBuilder builder, AssistKind kind,
+  void _addAssistFromBuilder(ChangeBuilder builder, AssistKind kind,
       {List<Object> args}) {
     if (builder == null) {
       return;
@@ -249,7 +248,7 @@
         var producer = generator();
         producer.configure(context);
 
-        var builder = DartChangeBuilderImpl.forWorkspace(context.workspace);
+        var builder = ChangeBuilder(workspace: context.workspace);
         await producer.compute(builder);
         _addAssistFromBuilder(builder, producer.assistKind,
             args: producer.assistArguments);
@@ -259,7 +258,7 @@
       var multiProducer = multiGenerator();
       multiProducer.configure(context);
       for (var producer in multiProducer.producers) {
-        var builder = DartChangeBuilderImpl.forWorkspace(context.workspace);
+        var builder = ChangeBuilder(workspace: context.workspace);
         producer.configure(context);
         await producer.compute(builder);
         _addAssistFromBuilder(builder, producer.assistKind,
diff --git a/pkg/analysis_server/lib/src/services/correction/base_processor.dart b/pkg/analysis_server/lib/src/services/correction/base_processor.dart
index 0bb0cff..836467a 100644
--- a/pkg/analysis_server/lib/src/services/correction/base_processor.dart
+++ b/pkg/analysis_server/lib/src/services/correction/base_processor.dart
@@ -23,7 +23,6 @@
   final String file;
 
   final TypeProvider typeProvider;
-  final Flutter flutter;
 
   final AnalysisSession session;
   final AnalysisSessionHelper sessionHelper;
@@ -38,13 +37,14 @@
     @required this.resolvedResult,
     @required this.workspace,
   })  : file = resolvedResult.path,
-        flutter = Flutter.of(resolvedResult),
         session = resolvedResult.session,
         sessionHelper = AnalysisSessionHelper(resolvedResult.session),
         typeProvider = resolvedResult.typeProvider,
         selectionEnd = (selectionOffset ?? 0) + (selectionLength ?? 0),
         utils = CorrectionUtils(resolvedResult);
 
+  Flutter get flutter => Flutter.instance;
+
   @protected
   bool setupCompute() {
     final locator = NodeLocator(selectionOffset, selectionEnd);
diff --git a/pkg/analysis_server/lib/src/services/correction/bulk_fix_processor.dart b/pkg/analysis_server/lib/src/services/correction/bulk_fix_processor.dart
new file mode 100644
index 0000000..4c83d54
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/bulk_fix_processor.dart
@@ -0,0 +1,111 @@
+// 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:core';
+
+import 'package:analysis_server/plugin/edit/fix/fix_dart.dart';
+import 'package:analysis_server/src/services/correction/change_workspace.dart';
+import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
+import 'package:analysis_server/src/services/correction/dart/convert_documentation_into_line.dart';
+import 'package:analysis_server/src/services/correction/dart/remove_const.dart';
+import 'package:analysis_server/src/services/correction/dart/remove_unnecessary_new.dart';
+import 'package:analysis_server/src/services/correction/dart/replace_cascade_with_dot.dart';
+import 'package:analysis_server/src/services/correction/dart/replace_colon_with_equals.dart';
+import 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analysis_server/src/services/correction/fix_internal.dart';
+import 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:analyzer/dart/analysis/results.dart';
+import 'package:analyzer/error/error.dart';
+import 'package:analyzer/src/error/codes.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
+
+/// A fix producer that produces changes to fix multiple diagnostics.
+class BulkFixProcessor {
+  /// A map from the name of a lint rule to a generator used to create the
+  /// correction producer used to build a fix for that diagnostic. The
+  /// generators used for non-lint diagnostics are in the [nonLintProducerMap].
+  static const Map<String, ProducerGenerator> lintProducerMap = {
+    LintNames.avoid_single_cascade_in_expression_statements:
+        ReplaceCascadeWithDot.newInstance,
+    LintNames.prefer_equal_for_default_values:
+        ReplaceColonWithEquals.newInstance,
+    LintNames.slash_for_doc_comments: ConvertDocumentationIntoLine.newInstance,
+    LintNames.unnecessary_const: RemoveUnnecessaryConst.newInstance,
+    LintNames.unnecessary_new: RemoveUnnecessaryNew.newInstance,
+  };
+
+  /// A map from an error code to a generator used to create the correction
+  /// producer used to build a fix for that diagnostic. The generators used for
+  /// lint rules are in the [lintProducerMap].
+  static const Map<ErrorCode, ProducerGenerator> nonLintProducerMap = {};
+
+  final DartChangeWorkspace workspace;
+
+  /// The change builder used to build the changes required to fix the
+  /// diagnostics.
+  ChangeBuilder builder;
+
+  BulkFixProcessor(this.workspace) {
+    builder = ChangeBuilder(workspace: workspace);
+  }
+
+  Future<ChangeBuilder> fixErrorsInLibraries(List<String> libraryPaths) async {
+    for (var path in libraryPaths) {
+      var session = workspace.getSession(path);
+      var libraryResult = await session.getResolvedLibrary(path);
+      await _fixErrorsInLibrary(libraryResult);
+    }
+    return builder;
+  }
+
+  Future<void> _fixErrorsInLibrary(ResolvedLibraryResult libraryResult) async {
+    for (var unitResult in libraryResult.units) {
+      final fixContext = DartFixContextImpl(
+        workspace,
+        unitResult,
+        null,
+        (name) => [],
+      );
+      for (var error in unitResult.errors) {
+        await _fixSingleError(fixContext, unitResult, error);
+      }
+    }
+  }
+
+  Future<void> _fixSingleError(DartFixContext fixContext,
+      ResolvedUnitResult unitResult, AnalysisError error) async {
+    var context = CorrectionProducerContext(
+      dartFixContext: fixContext,
+      diagnostic: error,
+      resolvedResult: unitResult,
+      selectionOffset: error.offset,
+      selectionLength: error.length,
+      workspace: workspace,
+    );
+
+    var setupSuccess = context.setupCompute();
+    if (!setupSuccess) {
+      return;
+    }
+
+    Future<void> compute(CorrectionProducer producer) async {
+      producer.configure(context);
+      await producer.compute(builder);
+    }
+
+    var errorCode = error.errorCode;
+    if (errorCode is LintCode) {
+      var generator = lintProducerMap[errorCode.name];
+      if (generator != null) {
+        await compute(generator());
+      }
+    } else {
+      var generator = nonLintProducerMap[errorCode];
+      if (generator != null) {
+        await compute(generator());
+      }
+    }
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/abstract_producer.dart b/pkg/analysis_server/lib/src/services/correction/dart/abstract_producer.dart
index bf2c9f2..8b24ec7 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/abstract_producer.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/abstract_producer.dart
@@ -24,47 +24,18 @@
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_workspace.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 import 'package:meta/meta.dart';
 
-/// An object that can compute a correction (fix or assist).
-abstract class CorrectionProducer extends _AbstractCorrectionProducer {
-  /// Return the arguments that should be used when composing the message for an
-  /// assist, or `null` if the assist message has no parameters or if this
-  /// producer doesn't support assists.
-  List<Object> get assistArguments => null;
-
-  /// Return the assist kind that should be used to build an assist, or `null`
-  /// if this producer doesn't support assists.
-  AssistKind get assistKind => null;
-
+/// An object that can compute a correction (fix or assist) in a Dart file.
+abstract class CorrectionProducer extends SingleCorrectionProducer {
   /// Return the type for the class `bool` from `dart:core`.
   DartType get coreTypeBool => resolvedResult.typeProvider.boolType;
 
-  /// Return the length of the error message being fixed, or `null` if there is
-  /// no diagnostic.
-  int get errorLength => diagnostic?.problemMessage?.length;
-
-  /// Return the text of the error message being fixed, or `null` if there is
-  /// no diagnostic.
-  String get errorMessage => diagnostic?.problemMessage?.message;
-
-  /// Return the offset of the error message being fixed, or `null` if there is
-  /// no diagnostic.
-  int get errorOffset => diagnostic?.problemMessage?.offset;
-
-  /// Return the arguments that should be used when composing the message for a
-  /// fix, or `null` if the fix message has no parameters or if this producer
-  /// doesn't support fixes.
-  List<Object> get fixArguments => null;
-
-  /// Return the fix kind that should be used to build a fix, or `null` if this
-  /// producer doesn't support fixes.
-  FixKind get fixKind => null;
-
   /// Returns `true` if [node] is in a static context.
   bool get inStaticContext {
     // constructor initializer cannot reference "this"
@@ -80,7 +51,7 @@
     return method != null && method.isStatic;
   }
 
-  Future<void> compute(DartChangeBuilder builder);
+  Future<void> compute(ChangeBuilder builder);
 
   /// Return the class, enum or mixin declaration for the given [element].
   Future<ClassOrMixinDeclaration> getClassOrMixinDeclaration(
@@ -252,7 +223,6 @@
   final String file;
 
   final TypeProvider typeProvider;
-  final Flutter flutter;
 
   final AnalysisSession session;
   final AnalysisSessionHelper sessionHelper;
@@ -272,7 +242,6 @@
     this.selectionOffset = -1,
     this.selectionLength = 0,
   })  : file = resolvedResult.path,
-        flutter = Flutter.of(resolvedResult),
         session = resolvedResult.session,
         sessionHelper = AnalysisSessionHelper(resolvedResult.session),
         typeProvider = resolvedResult.typeProvider,
@@ -302,6 +271,39 @@
   Iterable<CorrectionProducer> get producers;
 }
 
+/// An object that can compute a correction (fix or assist) in a Dart file.
+abstract class SingleCorrectionProducer extends _AbstractCorrectionProducer {
+  /// Return the arguments that should be used when composing the message for an
+  /// assist, or `null` if the assist message has no parameters or if this
+  /// producer doesn't support assists.
+  List<Object> get assistArguments => null;
+
+  /// Return the assist kind that should be used to build an assist, or `null`
+  /// if this producer doesn't support assists.
+  AssistKind get assistKind => null;
+
+  /// Return the length of the error message being fixed, or `null` if there is
+  /// no diagnostic.
+  int get errorLength => diagnostic?.problemMessage?.length;
+
+  /// Return the text of the error message being fixed, or `null` if there is
+  /// no diagnostic.
+  String get errorMessage => diagnostic?.problemMessage?.message;
+
+  /// Return the offset of the error message being fixed, or `null` if there is
+  /// no diagnostic.
+  int get errorOffset => diagnostic?.problemMessage?.offset;
+
+  /// Return the arguments that should be used when composing the message for a
+  /// fix, or `null` if the fix message has no parameters or if this producer
+  /// doesn't support fixes.
+  List<Object> get fixArguments => null;
+
+  /// Return the fix kind that should be used to build a fix, or `null` if this
+  /// producer doesn't support fixes.
+  FixKind get fixKind => null;
+}
+
 /// The behavior shared by [CorrectionProducer] and [MultiCorrectionProducer].
 abstract class _AbstractCorrectionProducer {
   /// The context used to produce corrections.
@@ -344,7 +346,7 @@
 
   String get file => _context.file;
 
-  Flutter get flutter => _context.flutter;
+  Flutter get flutter => Flutter.instance;
 
   /// Return the library element for the library in which a correction is being
   /// produced.
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_async.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_async.dart
index 69dd645..ef18db3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_async.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_async.dart
@@ -5,24 +5,24 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
-class AddSync extends CorrectionProducer {
+class AddAsync extends CorrectionProducer {
   @override
   FixKind get fixKind => DartFixKind.ADD_ASYNC;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var body = node.thisOrAncestorOfType<FunctionBody>();
     if (body != null && body.keyword == null) {
       var typeProvider = this.typeProvider;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.convertFunctionFromSyncToAsync(body, typeProvider);
       });
     }
   }
 
   /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
-  static AddSync newInstance() => AddSync();
+  static AddAsync newInstance() => AddAsync();
 }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_await.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_await.dart
index aa4fa5c..3089665 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_await.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_await.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddAwait extends CorrectionProducer {
@@ -12,8 +12,8 @@
   FixKind get fixKind => DartFixKind.ADD_AWAIT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(node.offset, 'await ');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_const.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_const.dart
index 05fb681..170cdef 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_const.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_const.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddConst extends CorrectionProducer {
@@ -13,13 +13,13 @@
   FixKind get fixKind => DartFixKind.ADD_CONST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier) {
       node = node.parent;
     }
     if (node is ConstructorDeclaration) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         final offset = (node as ConstructorDeclaration)
             .firstTokenAfterCommentAndMetadata
             .offset;
@@ -35,7 +35,7 @@
     }
     if (node is InstanceCreationExpression) {
       if ((node as InstanceCreationExpression).keyword == null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleInsertion(node.offset, 'const ');
         });
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_diagnostic_property_reference.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_diagnostic_property_reference.dart
index 2451a7c..fb8c61b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_diagnostic_property_reference.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_diagnostic_property_reference.dart
@@ -9,6 +9,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:meta/meta.dart';
@@ -21,7 +22,7 @@
   FixKind get fixKind => DartFixKind.ADD_DIAGNOSTIC_PROPERTY_REFERENCE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final node = this.node;
     if (node is! SimpleIdentifier) {
       return;
@@ -98,14 +99,16 @@
     }
 
     final classDeclaration = parent.thisOrAncestorOfType<ClassDeclaration>();
+    if (classDeclaration == null) {
+      return;
+    }
     final debugFillProperties =
         classDeclaration.getMethod('debugFillProperties');
     if (debugFillProperties == null) {
       final insertOffset =
           utils.prepareNewMethodLocation(classDeclaration).offset;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(utils.getLineNext(insertOffset),
-            (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(utils.getLineNext(insertOffset), (builder) {
           final declPrefix =
               utils.getLinePrefix(classDeclaration.offset) + utils.getIndent(1);
           final bodyPrefix = declPrefix + utils.getIndent(1);
@@ -154,9 +157,8 @@
         return null;
       }
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(utils.getLineNext(offset),
-            (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(utils.getLineNext(offset), (builder) {
           writePropertyReference(builder,
               prefix: prefix, builderName: propertiesBuilderName);
         });
@@ -188,25 +190,7 @@
   }
 
   bool _isIterable(DartType type) {
-    if (type is! InterfaceType) {
-      return false;
-    }
-
-    ClassElement element = type.element;
-
-    bool isExactIterable(ClassElement element) {
-      return element?.name == 'Iterable' && element.library.isDartCore;
-    }
-
-    if (isExactIterable(element)) {
-      return true;
-    }
-    for (var type in element.allSupertypes) {
-      if (isExactIterable(type.element)) {
-        return true;
-      }
-    }
-    return false;
+    return type.asInstanceOf(typeProvider.iterableElement) != null;
   }
 
   /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_explicit_cast.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_explicit_cast.dart
index 5793f60..f04a6c3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_explicit_cast.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_explicit_cast.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/precedence.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddExplicitCast extends CorrectionProducer {
@@ -16,7 +16,7 @@
   FixKind get fixKind => DartFixKind.ADD_EXPLICIT_CAST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     Expression target;
     if (coveredNode is Expression) {
       target = coveredNode;
@@ -62,11 +62,11 @@
         // `cast` invocation.
         return;
       }
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (needsParentheses) {
           builder.addSimpleInsertion(target.offset, '(');
         }
-        builder.addInsertion(target.end, (DartEditBuilder builder) {
+        builder.addInsertion(target.end, (builder) {
           if (needsParentheses) {
             builder.write(')');
           }
@@ -81,11 +81,11 @@
         // `cast` invocation.
         return;
       }
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (needsParentheses) {
           builder.addSimpleInsertion(target.offset, '(');
         }
-        builder.addInsertion(target.end, (DartEditBuilder builder) {
+        builder.addInsertion(target.end, (builder) {
           if (needsParentheses) {
             builder.write(')');
           }
@@ -97,11 +97,11 @@
         });
       });
     } else {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (needsParentheses) {
           builder.addSimpleInsertion(target.offset, '(');
         }
-        builder.addInsertion(target.end, (DartEditBuilder builder) {
+        builder.addInsertion(target.end, (builder) {
           if (needsParentheses) {
             builder.write(')');
           }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_field_formal_parameters.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_field_formal_parameters.dart
index 133873f..6a23e04 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_field_formal_parameters.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_field_formal_parameters.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/generated/error_verifier.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddFieldFormalParameters extends CorrectionProducer {
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.ADD_FIELD_FORMAL_PARAMETERS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier || node.parent is! ConstructorDeclaration) {
       return;
     }
@@ -38,7 +38,7 @@
     if (flutter.isExactlyStatelessWidgetType(superType) ||
         flutter.isExactlyStatefulWidgetType(superType)) {
       if (parameters.isNotEmpty && parameters.last.isNamed) {
-        await builder.addFileEdit(file, (builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleInsertion(
             parameters.last.end,
             ', $fieldParametersCode',
@@ -56,7 +56,7 @@
       }
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       if (lastRequiredParameter != null) {
         builder.addSimpleInsertion(
           lastRequiredParameter.end,
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_late.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_late.dart
index c1de45b..a8ec84f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_late.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_late.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddLate extends CorrectionProducer {
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.ADD_LATE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (!libraryElement.isNonNullableByDefault) {
       return;
     }
@@ -44,8 +44,8 @@
     }
   }
 
-  void _insertAt(DartChangeBuilder builder, int offset) async {
-    await builder.addFileEdit(file, (builder) {
+  void _insertAt(ChangeBuilder builder, int offset) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(offset, 'late ');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_enum_case_clauses.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_enum_case_clauses.dart
index 678e8a8..77d58d78 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_enum_case_clauses.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_enum_case_clauses.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddMissingEnumCaseClauses extends CorrectionProducer {
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.ADD_MISSING_ENUM_CASE_CLAUSES;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var statement = node as SwitchStatement;
     String enumName;
     var enumConstantNames = <String>[];
@@ -52,7 +52,7 @@
     var statementIndent = utils.getLinePrefix(statement.offset);
     var singleIndent = utils.getIndent(1);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addInsertion(utils.getLineThis(statement.end), (builder) {
         for (var constantName in enumConstantNames) {
           builder.write(statementIndent);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter.dart
index 7638459..5c29355 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/executable_parameters.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddMissingParameter extends MultiCorrectionProducer {
@@ -43,7 +43,7 @@
   FixKind get fixKind => DartFixKind.ADD_MISSING_PARAMETER_POSITIONAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var prefix = context.required.isNotEmpty ? ', [' : '[';
     if (context.required.isNotEmpty) {
       var prevNode = await context.getParameterNode(context.required.last);
@@ -63,8 +63,8 @@
 
   _AddMissingParameter(this.context);
 
-  Future<void> _addParameter(DartChangeBuilder builder, int offset,
-      String prefix, String suffix) async {
+  Future<void> _addParameter(
+      ChangeBuilder builder, int offset, String prefix, String suffix) async {
     ArgumentList argumentList = node;
     List<Expression> arguments = argumentList.arguments;
     var numRequired = context.required.length;
@@ -73,7 +73,7 @@
     }
     var argument = arguments[numRequired];
     if (offset != null) {
-      await builder.addFileEdit(context.file, (builder) {
+      await builder.addDartFileEdit(context.file, (builder) {
         builder.addInsertion(offset, (builder) {
           builder.write(prefix);
           builder.writeParameterMatchingArgument(
@@ -95,7 +95,7 @@
   FixKind get fixKind => DartFixKind.ADD_MISSING_PARAMETER_REQUIRED;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (context.required.isNotEmpty) {
       var prevNode = await context.getParameterNode(context.required.last);
       await _addParameter(builder, prevNode?.end, ', ', '');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter_named.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter_named.dart
index fa835e8..93ab6ad 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter_named.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_parameter_named.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/executable_parameters.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddMissingParameterNamed extends CorrectionProducer {
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.ADD_MISSING_PARAMETER_NAMED;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // Prepare the name of the missing parameter.
     if (this.node is! SimpleIdentifier) {
       return;
@@ -52,7 +52,7 @@
 
     Future<void> addParameter(int offset, String prefix, String suffix) async {
       if (offset != null) {
-        await builder.addFileEdit(context.file, (builder) {
+        await builder.addDartFileEdit(context.file, (builder) {
           builder.addInsertion(offset, (builder) {
             builder.write(prefix);
             builder
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_required_argument.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_required_argument.dart
index 21e2950..2474392 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_missing_required_argument.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_missing_required_argument.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddMissingRequiredArgument extends CorrectionProducer {
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.ADD_MISSING_REQUIRED_ARGUMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     InstanceCreationExpression creation;
     Element targetElement;
     ArgumentList argumentList;
@@ -79,8 +79,8 @@
         }
       }
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(offset, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(offset, (builder) {
           if (arguments.isNotEmpty && !insertBetweenParams) {
             builder.write(', ');
           }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_ne_null.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_ne_null.dart
index b75fd4f0..69ba3a9 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_ne_null.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_ne_null.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddNeNull extends CorrectionProducer {
@@ -12,9 +12,9 @@
   FixKind get fixKind => DartFixKind.ADD_NE_NULL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var problemMessage = diagnostic.problemMessage;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(
           problemMessage.offset + problemMessage.length, ' != null');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_not_null_assert.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_not_null_assert.dart
index 05c17eb..7ce7207 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_not_null_assert.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_not_null_assert.dart
@@ -9,14 +9,14 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class AddNotNullAssert extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.ADD_NOT_NULL_ASSERT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final identifier = node;
     if (identifier is SimpleIdentifier) {
       if (identifier.parent is FormalParameter) {
@@ -47,7 +47,7 @@
             }
           }
 
-          await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(file, (builder) {
             final id = identifier.name;
             final prefix = utils.getNodePrefix(exp);
             final indent = utils.getIndent(1);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_override.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_override.dart
index 2faac70..8dfac60 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_override.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_override.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -16,7 +16,7 @@
   FixKind get fixKind => DartFixKind.ADD_OVERRIDE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var member = node.thisOrAncestorOfType<ClassMember>();
     if (member == null) {
       return;
@@ -32,7 +32,7 @@
 
     var exitPosition = Position(file, token.offset - 1);
     var indent = utils.getIndent(1);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           range.startLength(token, 0), '@override$eol$indent');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_required.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_required.dart
index 3ccea52..ed474b4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_required.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_required.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddRequired extends CorrectionProducer {
@@ -12,8 +12,8 @@
   FixKind get fixKind => DartFixKind.ADD_REQUIRED;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(node.parent.offset, '@required ');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_required_keyword.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_required_keyword.dart
index ca26be2..bc71685 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_required_keyword.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_required_keyword.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddRequiredKeyword extends CorrectionProducer {
@@ -12,8 +12,8 @@
   FixKind get fixKind => DartFixKind.ADD_REQUIRED2;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(node.parent.offset, 'required ');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_return_type.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_return_type.dart
index 7ff6f15..b4d5d8d 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_return_type.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_return_type.dart
@@ -12,7 +12,7 @@
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_system.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddReturnType extends CorrectionProducer {
@@ -23,7 +23,7 @@
   FixKind get fixKind => DartFixKind.ADD_RETURN_TYPE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     SyntacticEntity insertBeforeEntity;
     FunctionBody body;
     if (node is SimpleIdentifier) {
@@ -58,7 +58,7 @@
       return null;
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addInsertion(insertBeforeEntity.offset, (builder) {
         if (returnType.isDynamic) {
           builder.write('dynamic');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_static.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_static.dart
index 27b7abf..6f3fa92 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_static.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_static.dart
@@ -5,17 +5,17 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddStatic extends CorrectionProducer {
   @override
-  FixKind get fixKind => DartFixKind.ADD_STATIC; // TODO
+  FixKind get fixKind => DartFixKind.ADD_STATIC;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var declaration = node.thisOrAncestorOfType<FieldDeclaration>();
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var offset = declaration.firstTokenAfterCommentAndMetadata.offset;
       builder.addSimpleInsertion(offset, 'static ');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_super_constructor_invocation.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_super_constructor_invocation.dart
index f191214..3911cf4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_super_constructor_invocation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_super_constructor_invocation.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/src/utilities/string_utilities.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class AddSuperConstructorInvocation extends MultiCorrectionProducer {
@@ -77,10 +77,10 @@
   FixKind get fixKind => DartFixKind.ADD_SUPER_CONSTRUCTOR_INVOCATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var constructorName = _constructor.displayName;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(_insertOffset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(_insertOffset, (builder) {
         builder.write(_prefix);
         // add super constructor name
         builder.write('super');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/add_type_annotation.dart b/pkg/analysis_server/lib/src/services/correction/dart/add_type_annotation.dart
index 5361b82..98e2195 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/add_type_annotation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/add_type_annotation.dart
@@ -8,9 +8,9 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.ADD_TYPE_ANNOTATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier) {
       var parent = node.parent;
@@ -68,7 +68,7 @@
   }
 
   Future<void> _forDeclaredIdentifier(
-      DartChangeBuilder builder, DeclaredIdentifier declaredIdentifier) async {
+      ChangeBuilder builder, DeclaredIdentifier declaredIdentifier) async {
     // Ensure that there isn't already a type annotation.
     if (declaredIdentifier.type != null) {
       return;
@@ -79,18 +79,16 @@
     }
     _configureTargetLocation(node);
 
-    Future<bool> applyChange(DartChangeBuilder builder) async {
+    Future<bool> applyChange(ChangeBuilder builder) async {
       var validChange = true;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         var keyword = declaredIdentifier.keyword;
         if (keyword.keyword == Keyword.VAR) {
-          builder.addReplacement(range.token(keyword),
-              (DartEditBuilder builder) {
+          builder.addReplacement(range.token(keyword), (builder) {
             validChange = builder.writeType(type);
           });
         } else {
-          builder.addInsertion(declaredIdentifier.identifier.offset,
-              (DartEditBuilder builder) {
+          builder.addInsertion(declaredIdentifier.identifier.offset, (builder) {
             validChange = builder.writeType(type);
             builder.write(' ');
           });
@@ -104,7 +102,7 @@
     }
   }
 
-  Future<void> _forSimpleFormalParameter(DartChangeBuilder builder,
+  Future<void> _forSimpleFormalParameter(ChangeBuilder builder,
       SimpleIdentifier name, SimpleFormalParameter parameter) async {
     // Ensure that there isn't already a type annotation.
     if (parameter.type != null) {
@@ -121,10 +119,10 @@
     }
     _configureTargetLocation(node);
 
-    Future<bool> applyChange(DartChangeBuilder builder) async {
+    Future<bool> applyChange(ChangeBuilder builder) async {
       var validChange = true;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(name.offset, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(name.offset, (builder) {
           validChange = builder.writeType(type);
           if (validChange) {
             builder.write(' ');
@@ -139,8 +137,8 @@
     }
   }
 
-  Future<void> _forVariableDeclaration(DartChangeBuilder builder,
-      VariableDeclarationList declarationList) async {
+  Future<void> _forVariableDeclaration(
+      ChangeBuilder builder, VariableDeclarationList declarationList) async {
     // Ensure that there isn't already a type annotation.
     if (declarationList.type != null) {
       return;
@@ -168,17 +166,16 @@
     }
     _configureTargetLocation(node);
 
-    Future<bool> applyChange(DartChangeBuilder builder) async {
+    Future<bool> applyChange(ChangeBuilder builder) async {
       var validChange = true;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         var keyword = declarationList.keyword;
         if (keyword?.keyword == Keyword.VAR) {
-          builder.addReplacement(range.token(keyword),
-              (DartEditBuilder builder) {
+          builder.addReplacement(range.token(keyword), (builder) {
             validChange = builder.writeType(type);
           });
         } else {
-          builder.addInsertion(variable.offset, (DartEditBuilder builder) {
+          builder.addInsertion(variable.offset, (builder) {
             validChange = builder.writeType(type);
             builder.write(' ');
           });
@@ -192,9 +189,8 @@
     }
   }
 
-  DartChangeBuilder _temporaryBuilder(DartChangeBuilder builder) =>
-      DartChangeBuilderImpl.forWorkspace(
-          (builder as DartChangeBuilderImpl).workspace);
+  ChangeBuilder _temporaryBuilder(ChangeBuilder builder) =>
+      ChangeBuilder(workspace: (builder as ChangeBuilderImpl).workspace);
 
   /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
   static AddTypeAnnotation newInstance() => AddTypeAnnotation();
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/assign_to_local_variable.dart b/pkg/analysis_server/lib/src/services/correction/dart/assign_to_local_variable.dart
index 956a58c..4ecdfcf 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/assign_to_local_variable.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/assign_to_local_variable.dart
@@ -9,14 +9,14 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class AssignToLocalVariable extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.ASSIGN_TO_LOCAL_VARIABLE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare enclosing ExpressionStatement
     ExpressionStatement expressionStatement;
     // ignore: unnecessary_this
@@ -32,7 +32,8 @@
         return;
       }
     }
-    if (expressionStatement == null) {
+    if (expressionStatement == null ||
+        _hasPrecedingStatementRecovery(expressionStatement)) {
       return;
     }
     // prepare expression
@@ -52,7 +53,7 @@
         getVariableNameSuggestionsForExpression(type, expression, excluded);
 
     if (suggestions.isNotEmpty) {
-      await builder.addFileEdit(file, (builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addInsertion(offset, (builder) {
           builder.write('var ');
           builder.addSimpleLinkedEdit('NAME', suggestions[0],
@@ -66,4 +67,25 @@
 
   /// Return an instance of this class. Used as a tear-off in `AssistProcessor`.
   static AssignToLocalVariable newInstance() => AssignToLocalVariable();
+
+  /// Return `true` if the given [statement] resulted from a recovery case that
+  /// would make the change create even worse errors than the original code.
+  static bool _hasPrecedingStatementRecovery(Statement statement) {
+    var parent = statement.parent;
+    if (parent is Block) {
+      var statements = parent.statements;
+      var index = statements.indexOf(statement);
+      if (index > 0) {
+        var precedingStatement = statements[index - 1];
+        if (precedingStatement is ExpressionStatement &&
+            precedingStatement.semicolon.isSynthetic) {
+          return true;
+        } else if (precedingStatement is VariableDeclarationStatement &&
+            precedingStatement.semicolon.isSynthetic) {
+          return true;
+        }
+      }
+    }
+    return false;
+  }
 }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/change_argument_name.dart b/pkg/analysis_server/lib/src/services/correction/dart/change_argument_name.dart
index 005278e..34f81c7 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/change_argument_name.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/change_argument_name.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analysis_server/src/services/correction/levenshtein.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -82,8 +82,8 @@
   FixKind get fixKind => DartFixKind.CHANGE_ARGUMENT_NAME;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(_argumentName), _proposedName);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/change_to.dart b/pkg/analysis_server/lib/src/services/correction/dart/change_to.dart
index 048191c..b4a176f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/change_to.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/change_to.dart
@@ -9,7 +9,7 @@
 import 'package:analysis_server/src/services/search/hierarchy.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -34,7 +34,7 @@
   FixKind get fixKind => DartFixKind.CHANGE_TO;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // TODO(brianwilkerson) Unify these separate methods as much as is
     //  reasonably possible.
     // TODO(brianwilkerson) Consider proposing all of the names within a
@@ -52,7 +52,7 @@
     }
   }
 
-  Future<void> _proposeAnnotation(DartChangeBuilder builder) async {
+  Future<void> _proposeAnnotation(ChangeBuilder builder) async {
     var node = this.node;
     if (node is Annotation) {
       var name = node.name;
@@ -64,8 +64,7 @@
     }
   }
 
-  Future<void> _proposeClassOrMixin(
-      DartChangeBuilder builder, AstNode node) async {
+  Future<void> _proposeClassOrMixin(ChangeBuilder builder, AstNode node) async {
     // Prepare the optional import prefix name.
     String prefixName;
     if (node is PrefixedIdentifier &&
@@ -97,7 +96,7 @@
       if (finder._element != null) {
         _proposedName = finder._element.name;
         if (_proposedName != null) {
-          await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(file, (builder) {
             builder.addSimpleReplacement(range.node(node), _proposedName);
           });
         }
@@ -105,7 +104,7 @@
     }
   }
 
-  Future<void> _proposeClassOrMixinMember(DartChangeBuilder builder,
+  Future<void> _proposeClassOrMixinMember(ChangeBuilder builder,
       Expression target, _ElementPredicate predicate) async {
     if (node is SimpleIdentifier) {
       var name = (node as SimpleIdentifier).name;
@@ -131,14 +130,14 @@
       // if we have close enough element, suggest to use it
       if (finder._element != null) {
         _proposedName = finder._element.displayName;
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(range.node(node), _proposedName);
         });
       }
     }
   }
 
-  Future<void> _proposeFunction(DartChangeBuilder builder) async {
+  Future<void> _proposeFunction(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier) {
       // Prepare the optional import prefix name.
@@ -172,14 +171,14 @@
       // If we have a close enough element, suggest to use it.
       if (finder._element != null) {
         _proposedName = finder._element.name;
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(range.node(node), _proposedName);
         });
       }
     }
   }
 
-  Future<void> _proposeGetterOrSetter(DartChangeBuilder builder) async {
+  Future<void> _proposeGetterOrSetter(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier) {
       // prepare target
@@ -206,7 +205,7 @@
     }
   }
 
-  Future<void> _proposeMethod(DartChangeBuilder builder) async {
+  Future<void> _proposeMethod(ChangeBuilder builder) async {
     if (node.parent is MethodInvocation) {
       var invocation = node.parent as MethodInvocation;
       await _proposeClassOrMixinMember(builder, invocation.realTarget,
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/change_to_nearest_precise_value.dart b/pkg/analysis_server/lib/src/services/correction/dart/change_to_nearest_precise_value.dart
index fc5559c..5caea4e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/change_to_nearest_precise_value.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/change_to_nearest_precise_value.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,14 +21,14 @@
   FixKind get fixKind => DartFixKind.CHANGE_TO_NEAREST_PRECISE_VALUE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     IntegerLiteral integer = node;
     var lexeme = integer.literal.lexeme;
     var precise = BigInt.from(IntegerLiteralImpl.nearestValidDouble(lexeme));
     _correction = lexeme.toLowerCase().contains('x')
         ? '0x${precise.toRadixString(16).toUpperCase()}'
         : precise.toString();
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(integer), _correction);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/change_to_static_access.dart b/pkg/analysis_server/lib/src/services/correction/dart/change_to_static_access.dart
index bf0ba1d..02b291f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/change_to_static_access.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/change_to_static_access.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CHANGE_TO_STATIC_ACCESS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     Expression target;
     Element invokedElement;
     if (node is SimpleIdentifier && node.parent is MethodInvocation) {
@@ -40,8 +40,8 @@
       return;
     }
     var declaringElement = invokedElement.enclosingElement;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(target), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(target), (builder) {
         builder.writeReference(declaringElement);
       });
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/change_type_annotation.dart b/pkg/analysis_server/lib/src/services/correction/dart/change_type_annotation.dart
index 712ed76..480f825 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/change_type_annotation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/change_type_annotation.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.CHANGE_TYPE_ANNOTATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var declaration = coveredNode?.parent;
     if (declaration is VariableDeclaration &&
         declaration.initializer == coveredNode) {
@@ -37,9 +37,8 @@
             _oldAnnotation =
                 typeNode.type.getDisplayString(withNullability: false);
             _newAnnotation = newType.getDisplayString(withNullability: false);
-            await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-              builder.addReplacement(range.node(typeNode),
-                  (DartEditBuilder builder) {
+            await builder.addDartFileEdit(file, (builder) {
+              builder.addReplacement(range.node(typeNode), (builder) {
                 builder.writeType(newType);
               });
             });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_add_all_to_spread.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_add_all_to_spread.dart
index f123391..d4269d4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_add_all_to_spread.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_add_all_to_spread.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -37,7 +37,7 @@
       : DartFixKind.CONVERT_TO_SPREAD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is! SimpleIdentifier || node.parent is! MethodInvocation) {
       return;
@@ -98,7 +98,7 @@
     }
     elementText ??= '...${utils.getNodeText(argument)}';
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       if (list.elements.isNotEmpty) {
         // ['a']..addAll(['b', 'c']);
         builder.addSimpleInsertion(list.elements.last.end, ', $elementText');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_class_to_mixin.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_class_to_mixin.dart
index 52e5f04..00a5ef9 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_class_to_mixin.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_class_to_mixin.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertClassToMixin extends CorrectionProducer {
@@ -17,7 +17,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_CLASS_TO_MIXIN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var classDeclaration = node.thisOrAncestorOfType<ClassDeclaration>();
     if (classDeclaration == null) {
       return;
@@ -54,7 +54,7 @@
     }
     interfaces.addAll(classElement.interfaces);
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(
           range.startStart(
               classDeclaration.abstractKeyword ?? classDeclaration.classKeyword,
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_conditional_expression_to_if_element.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_conditional_expression_to_if_element.dart
index b545497..6fc0b90 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_conditional_expression_to_if_element.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_conditional_expression_to_if_element.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_IF_ELEMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     AstNode node = this.node.thisOrAncestorOfType<ConditionalExpression>();
     if (node == null) {
       return null;
@@ -36,9 +36,8 @@
       var thenExpression = conditional.thenExpression.unParenthesized;
       var elseExpression = conditional.elseExpression.unParenthesized;
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addReplacement(range.node(nodeToReplace),
-            (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(range.node(nodeToReplace), (builder) {
           builder.write('if (');
           builder.write(utils.getNodeText(condition));
           builder.write(') ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_block.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_block.dart
index c24612c..7068e136 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_block.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_block.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertDocumentationIntoBlock extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_DOCUMENTATION_INTO_BLOCK;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var comment = node.thisOrAncestorOfType<Comment>();
     if (comment == null || !comment.isDocumentation) {
       return;
@@ -29,8 +29,8 @@
     }
     var prefix = utils.getNodePrefix(comment);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(comment), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(comment), (builder) {
         builder.writeln('/**');
         for (var token in comment.tokens) {
           builder.write(prefix);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_line.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_line.dart
index 3288b0c..7459fdb 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_line.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_documentation_into_line.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_LINE_COMMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var comment = node.thisOrAncestorOfType<Comment>();
     if (comment == null ||
         !comment.isDocumentation ||
@@ -67,8 +67,8 @@
       }
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(comment), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(comment), (builder) {
         for (var newLine in newLines) {
           builder.write(newLine);
         }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_child.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_child.dart
index a6029d6..3556de0 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_child.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_child.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_FLUTTER_CHILD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var named = flutter.findNamedExpression(node, 'child');
     if (named == null) {
       return;
@@ -23,7 +23,7 @@
     // child: widget
     var expression = named.expression;
     if (flutter.isWidgetExpression(expression)) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         flutter.convertChildToChildren2(
             builder,
             expression,
@@ -41,7 +41,7 @@
     // child: [widget1, widget2]
     if (expression is ListLiteral &&
         expression.elements.every(flutter.isWidgetExpression)) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(range.node(named.name), 'children:');
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_children.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_children.dart
index df8469f..29fd8d0 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_children.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_flutter_children.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_FLUTTER_CHILDREN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier &&
         node.name == 'children' &&
@@ -29,7 +29,7 @@
           var indentNew = utils.getLinePrefix(named.offset);
           widgetText = _replaceSourceIndent(widgetText, indentOld, indentNew);
 
-          await builder.addFileEdit(file, (builder) {
+          await builder.addDartFileEdit(file, (builder) {
             builder.addReplacement(range.node(named), (builder) {
               builder.write('child: ');
               builder.write(widgetText);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_async_body.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_async_body.dart
index 5b5dffb..1ccaff4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_async_body.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_async_body.dart
@@ -6,14 +6,14 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class ConvertIntoAsyncBody extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_ASYNC_BODY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var body = getEnclosingFunctionBody();
     if (body == null ||
         body is EmptyFunctionBody ||
@@ -38,7 +38,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.convertFunctionFromSyncToAsync(body, typeProvider);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_block_body.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_block_body.dart
index 5a64e75..629db9d 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_block_body.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_block_body.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoBlockBody extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_BLOCK_BODY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var body = getEnclosingFunctionBody();
     // prepare expression body
     if (body is! ExpressionFunctionBody || body.isGenerator) {
@@ -35,8 +35,8 @@
     var prefix = utils.getNodePrefix(body.parent);
     var indent = utils.getIndent(1);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(body), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(body), (builder) {
         if (body.isAsynchronous) {
           builder.write('async ');
         }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_final_field.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_final_field.dart
index 10162a1..9523790 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_final_field.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_final_field.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoFinalField extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_FINAL_FIELD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // Find the enclosing getter.
     MethodDeclaration getter;
     for (var n = node; n != null; n = n.parent) {
@@ -75,7 +75,7 @@
       code += ';';
       var replacementRange =
           range.startEnd(getter.returnType ?? getter.propertyKeyword, getter);
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(replacementRange, code);
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_for_index.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_for_index.dart
index 8859bcb..eee7b51 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_for_index.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_for_index.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoForIndex extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_FOR_INDEX;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // find enclosing ForEachStatement
     var forEachStatement = node.thisOrAncestorMatching(
             (node) => node is ForStatement && node.forLoopParts is ForEachParts)
@@ -78,7 +78,7 @@
     var indent = utils.getIndent(1);
     var firstBlockLine = utils.getLineContentEnd(body.leftBracket.end);
     // add change
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       // TODO(brianwilkerson) Create linked positions for the loop variable.
       builder.addSimpleReplacement(
           range.startEnd(forEachStatement, forEachStatement.rightParenthesis),
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_getter.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_getter.dart
index ac1a37d..437bb0b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_getter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_getter.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoGetter extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_GETTER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // Find the enclosing field declaration.
     FieldDeclaration fieldDeclaration;
     for (var n = node; n != null; n = n.parent) {
@@ -55,7 +55,7 @@
     code += ' => ' + utils.getNodeText(initializer);
     code += ';';
     var replacementRange = range.startEnd(fieldList.keyword, fieldDeclaration);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(replacementRange, code);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not.dart
index 8a2fd09..114f8d8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/ast/precedence.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoIsNot extends CorrectionProducer {
@@ -17,7 +17,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_IS_NOT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // Find the is expression
     var isExpression = node.thisOrAncestorOfType<IsExpression>();
     if (isExpression == null) {
@@ -55,7 +55,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       if (getExpressionParentPrecedence(prefExpression) >=
           Precedence.relational) {
         builder.addDeletion(range.token(prefExpression.operator));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not_empty.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not_empty.dart
index 2b82a89..98edb9b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not_empty.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_into_is_not_empty.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/services/search/hierarchy.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertIntoIsNotEmpty extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_INTO_IS_NOT_EMPTY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare "expr.isEmpty"
     AstNode isEmptyAccess;
     SimpleIdentifier isEmptyIdentifier;
@@ -58,7 +58,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(
           range.startStart(prefixExpression, prefixExpression.operand));
       builder.addSimpleReplacement(range.node(isEmptyIdentifier), 'isNotEmpty');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_map_from_iterable_to_for_literal.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_map_from_iterable_to_for_literal.dart
index dcfa395..fd31707 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_map_from_iterable_to_for_literal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_map_from_iterable_to_for_literal.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_FOR_ELEMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Ensure that the selection is inside an invocation of Map.fromIterable.
     //
@@ -155,8 +155,8 @@
     //
     // Construct the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(creation), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(creation), (builder) {
         builder.write('{ for (var ');
         builder.write(loopVariableName);
         builder.write(' in ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_part_of_to_uri.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_part_of_to_uri.dart
index 22a647e..246a7e3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_part_of_to_uri.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_part_of_to_uri.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 import 'package:path/path.dart';
 
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_PART_OF_TO_URI;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var directive = node.thisOrAncestorOfType<PartOfDirective>();
     if (directive == null || directive.libraryName == null) {
       return;
@@ -25,7 +25,7 @@
     var relativePath = relative(libraryPath, from: dirname(partPath));
     var uri = Uri.file(relativePath).toString();
     var replacementRange = range.node(directive.libraryName);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(replacementRange, "'$uri'");
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_quotes.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_quotes.dart
index b9ee86a..b9db2b2 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_quotes.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_quotes.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 abstract class ConvertQuotes extends CorrectionProducer {
@@ -19,7 +19,7 @@
   bool get _fromDouble;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleStringLiteral) {
       SimpleStringLiteral literal = node;
       if (_fromDouble ? !literal.isSingleQuoted : literal.isSingleQuoted) {
@@ -29,7 +29,7 @@
         var quoteLength = literal.isMultiline ? 3 : 1;
         var lexeme = literal.literal.lexeme;
         if (!lexeme.contains(newQuote)) {
-          await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(file, (builder) {
             builder.addSimpleReplacement(
                 SourceRange(
                     literal.offset + (literal.isRaw ? 1 : 0), quoteLength),
@@ -56,7 +56,7 @@
             }
           }
         }
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(
               SourceRange(parent.offset + (parent.isRaw ? 1 : 0), quoteLength),
               newQuote);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_contains.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_contains.dart
index 8f52fed..b4699fe 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_contains.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_contains.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_CONTAINS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var comparison = node.thisOrAncestorOfType<BinaryExpression>();
     if (comparison == null) {
       return;
@@ -34,7 +34,7 @@
         notOffset = leftOperand.offset;
       }
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (notOffset > 0) {
           builder.addSimpleInsertion(notOffset, '!');
         }
@@ -54,7 +54,7 @@
         notOffset = rightOperand.offset;
       }
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(deletionRange);
         if (notOffset > 0) {
           builder.addSimpleInsertion(notOffset, '!');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_expression_function_body.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_expression_function_body.dart
index 0e4b2c9..767c412 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_expression_function_body.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_expression_function_body.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_INTO_EXPRESSION_BODY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare current body
     var body = getEnclosingFunctionBody();
     if (body is! BlockFunctionBody || body.isGenerator) {
@@ -48,8 +48,8 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(body), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(body), (builder) {
         if (body.isAsynchronous) {
           builder.write('async ');
         }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_field_parameter.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_field_parameter.dart
index 0223626..886c599 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_field_parameter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_field_parameter.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertToFieldParameter extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_TO_FIELD_PARAMETER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node == null) {
       return;
     }
@@ -75,7 +75,7 @@
       }
       var fieldName = parameterInitializer.fieldName.name;
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         // replace parameter
         builder.addSimpleReplacement(range.node(parameter), 'this.$fieldName');
         // remove initializer
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_generic_function_syntax.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_generic_function_syntax.dart
index d62d9eb..ed860a2 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_generic_function_syntax.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_generic_function_syntax.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_GENERIC_FUNCTION_SYNTAX;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     while (node != null) {
       if (node is FunctionTypeAlias) {
@@ -55,7 +55,7 @@
   }
 
   Future<void> _convertFunctionTypeAlias(
-      DartChangeBuilder builder, FunctionTypeAlias node) async {
+      ChangeBuilder builder, FunctionTypeAlias node) async {
     if (!_allParametersHaveTypes(node.parameters)) {
       return;
     }
@@ -73,7 +73,7 @@
       replacement = '$functionName = $returnType Function$parameters';
     }
     // add change
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           range.startStart(node.typedefKeyword.next, node.semicolon),
           replacement);
@@ -81,7 +81,7 @@
   }
 
   Future<void> _convertFunctionTypedFormalParameter(
-      DartChangeBuilder builder, FunctionTypedFormalParameter node) async {
+      ChangeBuilder builder, FunctionTypedFormalParameter node) async {
     if (!_allParametersHaveTypes(node.parameters)) {
       return;
     }
@@ -99,7 +99,7 @@
       replacement = '$returnType Function$parameters $functionName';
     }
     // add change
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(node), replacement);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_if_null.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_if_null.dart
index e18304d..8455340 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_if_null.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_if_null.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_IF_NULL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var conditional = node.thisOrAncestorOfType<ConditionalExpression>();
     if (conditional == null) {
       return;
@@ -30,7 +30,7 @@
       nullableExpression = conditional.thenExpression;
       defaultExpression = conditional.elseExpression;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(range.node(conditional), (builder) {
         builder.write(utils.getNodeText(nullableExpression));
         builder.write(' ?? ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_int_literal.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_int_literal.dart
index 72d1338..7682a76 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_int_literal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_int_literal.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class ConvertToIntLiteral extends CorrectionProducer {
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_INT_LITERAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! DoubleLiteral) {
       return;
     }
@@ -34,9 +34,9 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(SourceRange(literal.offset, literal.length),
-          (DartEditBuilder builder) {
+          (builder) {
         builder.write('$intValue');
       });
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_list_literal.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_list_literal.dart
index c3ecab5..acd756c 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_list_literal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_list_literal.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_LIST_LITERAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Ensure that this is the default constructor defined on `List`.
     //
@@ -38,8 +38,8 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(creation), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(creation), (builder) {
         if (constructorTypeArguments != null) {
           builder.write(utils.getNodeText(constructorTypeArguments));
         }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_map_literal.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_map_literal.dart
index daccb53..5db3377 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_map_literal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_map_literal.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_MAP_LITERAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Ensure that this is the default constructor defined on either `Map` or
     // `LinkedHashMap`.
@@ -40,8 +40,8 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(creation), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(creation), (builder) {
         if (constructorTypeArguments != null) {
           builder.write(utils.getNodeText(constructorTypeArguments));
         }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_multiline_string.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_multiline_string.dart
index bf43b16..15a289f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_multiline_string.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_multiline_string.dart
@@ -7,14 +7,14 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class ConvertToMutilineString extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.CONVERT_TO_MULTILINE_STRING;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is InterpolationElement) {
       node = (node as InterpolationElement).parent;
@@ -22,7 +22,7 @@
     if (node is SingleStringLiteral) {
       var literal = node;
       if (!literal.isMultiline) {
-        await builder.addFileEdit(file, (builder) {
+        await builder.addDartFileEdit(file, (builder) {
           var newQuote = literal.isSingleQuoted ? "'''" : '"""';
           builder.addReplacement(
             SourceRange(literal.offset + (literal.isRaw ? 1 : 0), 1),
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_named_arguments.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_named_arguments.dart
index b7ce175..ce315d9 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_named_arguments.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_named_arguments.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class ConvertToNamedArguments extends CorrectionProducer {
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_NAMED_ARGUMENTS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var argumentList = node;
     if (argumentList is ArgumentList) {
       // Prepare parameters.
@@ -80,7 +80,7 @@
         return;
       }
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         for (var argument in argumentToParameter.keys) {
           var parameter = argumentToParameter[argument];
           builder.addSimpleInsertion(argument.offset, '${parameter.name}: ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_normal_parameter.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_normal_parameter.dart
index d3c13e5..9e488f2 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_normal_parameter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_normal_parameter.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ConvertToNormalParameter extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.CONVERT_TO_NORMAL_PARAMETER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleIdentifier &&
         node.parent is FieldFormalParameter &&
         node.parent.parent is FormalParameterList &&
@@ -27,13 +27,12 @@
       // prepare type
       var type = parameterElement.type;
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         // replace parameter
         if (type.isDynamic) {
           builder.addSimpleReplacement(range.node(parameter), name);
         } else {
-          builder.addReplacement(range.node(parameter),
-              (DartEditBuilder builder) {
+          builder.addReplacement(range.node(parameter), (builder) {
             builder.writeType(type);
             builder.write(' ');
             builder.write(name);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_null_aware.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_null_aware.dart
index 18604d3..403a6c4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_null_aware.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_null_aware.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_NULL_AWARE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node.parent is BinaryExpression &&
         node.parent.parent is ConditionalExpression) {
@@ -95,7 +95,7 @@
       }
       periodOffset = operator.offset;
 
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(node, nonNullExpression));
         builder.addSimpleInsertion(periodOffset, '?');
         builder.addDeletion(range.endEnd(nonNullExpression, node));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_on_type.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_on_type.dart
index 2df2ee0..470c614 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_on_type.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_on_type.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -17,7 +17,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_ON_TYPE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var exceptionParameter = node;
     if (exceptionParameter is SimpleIdentifier) {
       var catchClause = exceptionParameter.parent;
@@ -26,7 +26,7 @@
           catchClause.exceptionParameter == exceptionParameter) {
         var exceptionTypeName = exceptionParameter.name;
         fixArguments.add(exceptionTypeName);
-        await builder.addFileEdit(file, (builder) {
+        await builder.addDartFileEdit(file, (builder) {
           if (catchClause.stackTraceParameter != null) {
             builder.addSimpleReplacement(
               range.startStart(
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_package_import.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_package_import.dart
index 7856391..28bbe9e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_package_import.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_package_import.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_PACKAGE_IMPORT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is StringLiteral) {
       node = node.parent;
@@ -47,7 +47,7 @@
         return;
       }
 
-      await builder.addFileEdit(file, (builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(
           range.node(importDirective.uri),
           "'$importUri'",
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_relative_import.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_relative_import.dart
index eea6658..d927238 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_relative_import.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_relative_import.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 import 'package:path/path.dart' as path;
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_RELATIVE_IMPORT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is StringLiteral) {
       node = node.parent;
@@ -70,7 +70,7 @@
       from: path.dirname(sourceUri.path),
     );
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
         range.node(importDirective.uri).getExpanded(-1),
         relativePath,
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_set_literal.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_set_literal.dart
index dde8458..f374346 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_set_literal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_set_literal.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_SET_LITERAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Check whether this is an invocation of `toSet` on a list literal.
     //
@@ -36,7 +36,7 @@
       //
       // Build the change and return the assist.
       //
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (hasTypeArgs || _listHasUnambiguousElement(target)) {
           builder.addSimpleReplacement(openRange, '{');
         } else {
@@ -85,8 +85,8 @@
       //
       // Build the edit.
       //
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addReplacement(range.node(creation), (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(range.node(creation), (builder) {
           if (constructorTypeArguments != null) {
             builder.write(utils.getNodeText(constructorTypeArguments));
           } else if (elementTypeArguments != null) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_where_type.dart b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_where_type.dart
index 7d66b0e..2753a81 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/convert_to_where_type.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/convert_to_where_type.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.CONVERT_TO_WHERE_TYPE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is! SimpleIdentifier || node.parent is! MethodInvocation) {
       return;
@@ -47,7 +47,7 @@
     }
     var targetType = isExpression.type;
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(range.startEnd(methodName, invocation), (builder) {
         builder.write('whereType<');
         builder.write(utils.getNodeText(targetType));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_class.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_class.dart
index 0a91c00..90624ae 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_class.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_class.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/file_system/file_system.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_CLASS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     Element prefixElement;
     SimpleIdentifier nameNode;
@@ -92,8 +92,8 @@
     if (offset < 0) {
       return;
     }
-    await builder.addFileEdit(filePath, (DartFileEditBuilder builder) {
-      builder.addInsertion(offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(filePath, (builder) {
+      builder.addInsertion(offset, (builder) {
         builder.write(prefix);
         if (arguments == null) {
           builder.writeClassDeclaration(className, nameGroupName: 'NAME');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor.dart
index 95bd4ba..3c8f0c8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -23,7 +23,7 @@
   FixKind get fixKind => DartFixKind.CREATE_CONSTRUCTOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is ArgumentList && node.parent is InstanceCreationExpression) {
       await _proposeFromInstanceCreation(builder);
     } else {
@@ -31,7 +31,7 @@
     }
   }
 
-  Future<void> _proposeFromConstructorName(DartChangeBuilder builder) async {
+  Future<void> _proposeFromConstructorName(ChangeBuilder builder) async {
     SimpleIdentifier name;
     InstanceCreationExpression instanceCreation;
     if (node is SimpleIdentifier) {
@@ -75,8 +75,8 @@
         .prepareNewConstructorLocation(targetNode);
 
     var targetFile = targetElement.source.fullName;
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         builder.write(targetLocation.prefix);
         builder.writeConstructorDeclaration(targetElement.name,
             argumentList: instanceCreation.argumentList,
@@ -90,7 +90,7 @@
     });
   }
 
-  Future<void> _proposeFromInstanceCreation(DartChangeBuilder builder) async {
+  Future<void> _proposeFromInstanceCreation(ChangeBuilder builder) async {
     InstanceCreationExpression instanceCreation = node.parent;
     _constructorName = instanceCreation.constructorName;
     // should be synthetic default constructor
@@ -119,8 +119,8 @@
 
     var targetSource = targetElement.source;
     var targetFile = targetSource.fullName;
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         builder.write(targetLocation.prefix);
         builder.writeConstructorDeclaration(targetElement.name,
             argumentList: instanceCreation.argumentList);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_for_final_fields.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_for_final_fields.dart
index 56e71e2..07a9f44 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_for_final_fields.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_for_final_fields.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateConstructorForFinalFields extends CorrectionProducer {
@@ -17,7 +17,7 @@
   bool get _isNonNullable => unit.featureSet.isEnabled(Feature.non_nullable);
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier || node.parent is! VariableDeclaration) {
       return;
     }
@@ -48,8 +48,8 @@
         flutter.isExactlyStatefulWidgetType(superType)) {
       // Specialize for Flutter widgets.
       var keyClass = await sessionHelper.getClass(flutter.widgetsUri, 'Key');
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(targetLocation.offset, (builder) {
           builder.write(targetLocation.prefix);
           builder.write('const ');
           builder.write(className);
@@ -83,8 +83,8 @@
         });
       });
     } else {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(targetLocation.offset, (builder) {
           builder.write(targetLocation.prefix);
           builder.writeConstructorDeclaration(className,
               fieldNames: fieldNames);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_super.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_super.dart
index 53c642c..23223ba 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_super.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_constructor_super.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/util.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateConstructorSuper extends MultiCorrectionProducer {
@@ -64,12 +64,12 @@
   FixKind get fixKind => DartFixKind.CREATE_CONSTRUCTOR_SUPER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var constructorName = _constructor.name;
     var requiredParameters = _constructor.parameters
         .where((parameter) => parameter.isRequiredPositional);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(_targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(_targetLocation.offset, (builder) {
         void writeParameters(bool includeType) {
           var firstParameter = true;
           for (var parameter in requiredParameters) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_field.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_field.dart
index c9bee55..1a72275 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_field.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_field.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/util.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateField extends CorrectionProducer {
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_FIELD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var parameter = node.thisOrAncestorOfType<FieldFormalParameter>();
     if (parameter != null) {
       await _proposeFromFieldFormalParameter(builder, parameter);
@@ -31,7 +31,7 @@
   }
 
   Future<void> _proposeFromFieldFormalParameter(
-      DartChangeBuilder builder, FieldFormalParameter parameter) async {
+      ChangeBuilder builder, FieldFormalParameter parameter) async {
     var targetClassNode = parameter.thisOrAncestorOfType<ClassDeclaration>();
     if (targetClassNode == null) {
       return;
@@ -42,9 +42,9 @@
     //
     // Add proposal.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var fieldType = parameter.type?.type;
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         builder.write(targetLocation.prefix);
         builder.writeFieldDeclaration(_fieldName,
             nameGroupName: 'NAME', type: fieldType, typeGroupName: 'TYPE');
@@ -53,7 +53,7 @@
     });
   }
 
-  Future<void> _proposeFromIdentifier(DartChangeBuilder builder) async {
+  Future<void> _proposeFromIdentifier(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -110,10 +110,10 @@
     // build field source
     var targetSource = targetClassElement.source;
     var targetFile = targetSource.fullName;
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
       var fieldTypeNode = climbPropertyAccess(nameNode);
       var fieldType = inferUndefinedExpressionType(fieldTypeNode);
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         builder.write(targetLocation.prefix);
         builder.writeFieldDeclaration(_fieldName,
             isStatic: staticModifier,
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_file.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_file.dart
index 5b5f3f4..e4d15a2 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_file.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_file.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/generated/engine.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateFile extends CorrectionProducer {
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CREATE_FILE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // TODO(brianwilkerson) Generalize this to allow other valid string literals.
     if (node is SimpleStringLiteral) {
       var parent = node.parent;
@@ -31,7 +31,7 @@
           var fullName = source.fullName;
           if (resourceProvider.pathContext.isAbsolute(fullName) &&
               AnalysisEngine.isDartFileName(fullName)) {
-            await builder.addFileEdit(fullName, (builder) {
+            await builder.addDartFileEdit(fullName, (builder) {
               builder.addSimpleInsertion(0, '// TODO Implement this library.');
             });
             _fileName = source.shortName;
@@ -41,8 +41,7 @@
         var source = parent.uriSource;
         if (source != null) {
           var libName = resolvedResult.libraryElement.name;
-          await builder.addFileEdit(source.fullName,
-              (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(source.fullName, (builder) {
             // TODO(brianwilkerson) Consider using the URI rather than name.
             builder.addSimpleInsertion(0, 'part of $libName;$eol$eol');
           });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_function.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_function.dart
index e5a3616..05a71da 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_function.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_function.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.CREATE_FUNCTION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // should be the name of the invocation
     if (node is SimpleIdentifier && node.parent is MethodInvocation) {
     } else {
@@ -41,8 +41,8 @@
     sourcePrefix = '$eol$eol';
     utils.targetClassElement = null;
     // build method source
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(insertOffset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(insertOffset, (builder) {
         builder.write(sourcePrefix);
         // append return type
         {
@@ -52,7 +52,7 @@
           }
         }
         // append name
-        builder.addLinkedEdit('NAME', (DartLinkedEditBuilder builder) {
+        builder.addLinkedEdit('NAME', (builder) {
           builder.write(_functionName);
         });
         builder.write('(');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_getter.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_getter.dart
index 8947281..5b38e57 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_getter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_getter.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateGetter extends CorrectionProducer {
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_GETTER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -90,8 +90,8 @@
     // build method source
     var targetSource = targetElement.source;
     var targetFile = targetSource.fullName;
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         var fieldTypeNode = climbPropertyAccess(nameNode);
         var fieldType = inferUndefinedExpressionType(fieldTypeNode);
         builder.write(targetLocation.prefix);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_local_variable.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_local_variable.dart
index 8a809bf..08cb4f8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_local_variable.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_local_variable.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_LOCAL_VARIABLE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -33,7 +33,7 @@
       if (assignment.leftHandSide == node &&
           assignment.operator.type == TokenType.EQ &&
           assignment.parent is ExpressionStatement) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleInsertion(node.offset, 'var ');
         });
         return;
@@ -51,8 +51,8 @@
       return;
     }
     // build variable declaration source
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(target.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(target.offset, (builder) {
         builder.writeLocalVariableDeclaration(_variableName,
             nameGroupName: 'NAME', type: type, typeGroupName: 'TYPE');
         builder.write(eol);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_method.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_method.dart
index 20b80bb..4cf4b5c 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_method.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_method.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart' show Position;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -27,7 +27,7 @@
   FixKind get fixKind => DartFixKind.CREATE_METHOD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (_kind == _MethodKind.equalsOrHashCode) {
       await createEqualsOrHashCode(builder);
     } else if (_kind == _MethodKind.method) {
@@ -35,7 +35,7 @@
     }
   }
 
-  Future<void> createEqualsOrHashCode(DartChangeBuilder builder) async {
+  Future<void> createEqualsOrHashCode(ChangeBuilder builder) async {
     final methodDecl = node.thisOrAncestorOfType<MethodDeclaration>();
     final classDecl = methodDecl.thisOrAncestorOfType<ClassDeclaration>();
     if (methodDecl != null && classDecl != null) {
@@ -55,7 +55,7 @@
       final location =
           utils.prepareNewClassMemberLocation(classDecl, (_) => true);
 
-      await builder.addFileEdit(file, (fileBuilder) {
+      await builder.addDartFileEdit(file, (fileBuilder) {
         fileBuilder.addInsertion(location.offset, (builder) {
           builder.write(location.prefix);
           builder.writeOverride(element, invokeSuper: true);
@@ -67,7 +67,7 @@
     }
   }
 
-  Future<void> createMethod(DartChangeBuilder builder) async {
+  Future<void> createMethod(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier || node.parent is! MethodInvocation) {
       return;
     }
@@ -131,8 +131,8 @@
     var targetLocation = utils.prepareNewMethodLocation(targetNode);
     var targetFile = targetElement.source.fullName;
     // build method source
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         builder.write(targetLocation.prefix);
         // maybe "static"
         if (staticModifier) {
@@ -146,7 +146,7 @@
           }
         }
         // append name
-        builder.addLinkedEdit('NAME', (DartLinkedEditBuilder builder) {
+        builder.addLinkedEdit('NAME', (builder) {
           builder.write(_memberName);
         });
         builder.write('(');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_method_or_function.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_method_or_function.dart
index 97160ba..c92e700 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_method_or_function.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_method_or_function.dart
@@ -10,7 +10,7 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -26,7 +26,7 @@
   FixKind get fixKind => _fixKind;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleIdentifier) {
       var nameNode = node as SimpleIdentifier;
       // prepare argument expression (to get parameter)
@@ -81,7 +81,7 @@
   /// Prepares proposal for creating function corresponding to the given
   /// [FunctionType].
   Future<void> _createExecutable(
-      DartChangeBuilder builder,
+      ChangeBuilder builder,
       FunctionType functionType,
       String name,
       String targetFile,
@@ -92,8 +92,8 @@
       String sourceSuffix,
       Element target) async {
     // build method source
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(insertOffset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(insertOffset, (builder) {
         builder.write(sourcePrefix);
         builder.write(prefix);
         // may be static
@@ -106,7 +106,7 @@
           builder.write(' ');
         }
         // append name
-        builder.addLinkedEdit('NAME', (DartLinkedEditBuilder builder) {
+        builder.addLinkedEdit('NAME', (builder) {
           builder.write(name);
         });
         // append parameters
@@ -124,7 +124,7 @@
   /// Adds proposal for creating method corresponding to the given
   /// [FunctionType] in the given [ClassElement].
   Future<void> _createFunction(
-      DartChangeBuilder builder, FunctionType functionType) async {
+      ChangeBuilder builder, FunctionType functionType) async {
     var name = (node as SimpleIdentifier).name;
     // prepare environment
     var insertOffset = unit.end;
@@ -140,7 +140,7 @@
 
   /// Adds proposal for creating method corresponding to the given
   /// [FunctionType] in the given [ClassElement].
-  Future<void> _createMethod(DartChangeBuilder builder,
+  Future<void> _createMethod(ChangeBuilder builder,
       ClassElement targetClassElement, FunctionType functionType) async {
     var name = (node as SimpleIdentifier).name;
     // prepare environment
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_missing_overrides.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_missing_overrides.dart
index c6d5e59..d0fac46 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_missing_overrides.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_missing_overrides.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/error/inheritance_override.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart' show Position;
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateMissingOverrides extends CorrectionProducer {
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.CREATE_MISSING_OVERRIDES;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node.parent is! ClassDeclaration) {
       return;
     }
@@ -48,8 +48,8 @@
         utils.prepareNewClassMemberLocation(targetClass, (_) => true);
 
     var prefix = utils.getIndent(1);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(location.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(location.offset, (builder) {
         // Separator management.
         var numOfMembersWritten = 0;
         void addSeparatorBetweenDeclarations() {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_mixin.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_mixin.dart
index 78d9e6a..c4a8131 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_mixin.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_mixin.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/file_system/file_system.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_MIXIN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     Element prefixElement;
     SimpleIdentifier nameNode;
     if (node is SimpleIdentifier) {
@@ -91,8 +91,8 @@
     if (offset < 0) {
       return;
     }
-    await builder.addFileEdit(filePath, (DartFileEditBuilder builder) {
-      builder.addInsertion(offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(filePath, (builder) {
+      builder.addInsertion(offset, (builder) {
         builder.write(prefix);
         builder.writeMixinDeclaration(_mixinName, nameGroupName: 'NAME');
         builder.write(suffix);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart
index 53174e0..aa62503 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_no_such_method.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateNoSuchMethod extends CorrectionProducer {
@@ -13,7 +13,7 @@
   FixKind get fixKind => DartFixKind.CREATE_NO_SUCH_METHOD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node.parent is! ClassDeclaration) {
       return;
     }
@@ -21,8 +21,8 @@
     // prepare environment
     var prefix = utils.getIndent(1);
     var insertOffset = targetClass.end - 1;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addInsertion(insertOffset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addInsertion(insertOffset, (builder) {
         builder.selectHere();
         // insert empty line before existing member
         if (targetClass.members.isNotEmpty) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/create_setter.dart b/pkg/analysis_server/lib/src/services/correction/dart/create_setter.dart
index be6d0bf..c89701f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/create_setter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/create_setter.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class CreateSetter extends CorrectionProducer {
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.CREATE_SETTER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -90,8 +90,8 @@
     var targetSource = targetElement.source;
     var targetFile = targetSource.fullName;
     _setterName = nameNode.name;
-    await builder.addFileEdit(targetFile, (DartFileEditBuilder builder) {
-      builder.addInsertion(targetLocation.offset, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(targetFile, (builder) {
+      builder.addInsertion(targetLocation.offset, (builder) {
         var parameterTypeNode = climbPropertyAccess(nameNode);
         var parameterType = inferUndefinedExpressionType(parameterTypeNode);
         builder.write(targetLocation.prefix);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/data_driven.dart b/pkg/analysis_server/lib/src/services/correction/dart/data_driven.dart
new file mode 100644
index 0000000..62ff87c
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/dart/data_driven.dart
@@ -0,0 +1,91 @@
+// 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 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
+import 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform_set.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
+import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
+import 'package:meta/meta.dart';
+
+class DataDriven extends MultiCorrectionProducer {
+  /// The transform sets used by the current test.
+  @visibleForTesting
+  static List<TransformSet> transformSetsForTests;
+
+  @override
+  Iterable<CorrectionProducer> get producers sync* {
+    var name = _name;
+    var importedUris = <String>[];
+    var library = resolvedResult.libraryElement;
+    for (var importElement in library.imports) {
+      // TODO(brianwilkerson) Filter based on combinators to help avoid making
+      //  invalid suggestions.
+      importedUris.add(importElement.uri);
+    }
+    for (var set in _availableTransformSets) {
+      for (var transform in set.transformsFor(name, importedUris)) {
+        yield DataDrivenFix(transform);
+      }
+    }
+  }
+
+  List<TransformSet> get _availableTransformSets {
+    if (transformSetsForTests != null) {
+      return transformSetsForTests;
+    }
+    // TODO(brianwilkerson) This data needs to be cached somewhere and updated
+    //  when the `package_config.json` file for an analysis context is modified.
+    return <TransformSet>[];
+  }
+
+  /// Return the name that was changed.
+  String get _name {
+    var node = this.node;
+    if (node is SimpleIdentifier) {
+      return node.name;
+    } else if (node is ConstructorName) {
+      return node.name.name;
+    }
+    return null;
+  }
+
+  /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
+  static DataDriven newInstance() => DataDriven();
+}
+
+/// A correction processor that can make one of the possible change computed by
+/// the [DataDriven] producer.
+class DataDrivenFix extends CorrectionProducer {
+  /// The transform being applied to implement this fix.
+  final Transform _transform;
+
+  DataDrivenFix(this._transform);
+
+  @override
+  List<Object> get fixArguments => [_transform.title];
+
+  @override
+  FixKind get fixKind => DartFixKind.DATA_DRIVEN;
+
+  @override
+  Future<void> compute(ChangeBuilder builder) async {
+    var changes = _transform.changes;
+    var data = <Object>[];
+    for (var change in changes) {
+      var result = change.validate(this);
+      if (result == null) {
+        return;
+      }
+      data.add(result);
+    }
+    await builder.addDartFileEdit(file, (builder) {
+      for (var i = 0; i < changes.length; i++) {
+        changes[i].apply(builder, this, data[i]);
+      }
+    });
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/encapsulate_field.dart b/pkg/analysis_server/lib/src/services/correction/dart/encapsulate_field.dart
index 3c7106d..6f1065a 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/encapsulate_field.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/encapsulate_field.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class EncapsulateField extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.ENCAPSULATE_FIELD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // find FieldDeclaration
     var fieldDeclaration = node.thisOrAncestorOfType<FieldDeclaration>();
     if (fieldDeclaration == null) {
@@ -51,7 +51,7 @@
     if (nameNode != node) {
       return;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       // rename field
       builder.addSimpleReplacement(range.node(nameNode), '_$name');
       // update references in constructors
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/exchange_operands.dart b/pkg/analysis_server/lib/src/services/correction/dart/exchange_operands.dart
index 7c6a269..54bbe13 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/exchange_operands.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/exchange_operands.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ExchangeOperands extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.EXCHANGE_OPERANDS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // check that user invokes quick assist on binary expression
     if (node is! BinaryExpression) {
       return;
@@ -54,7 +54,7 @@
       newOperator = '<=';
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(leftRange, getRangeText(rightRange));
       builder.addSimpleReplacement(rightRange, getRangeText(leftRange));
       // Optionally replace the operator.
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/extend_class_for_mixin.dart b/pkg/analysis_server/lib/src/services/correction/dart/extend_class_for_mixin.dart
index 78a4869..a2233818 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/extend_class_for_mixin.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/extend_class_for_mixin.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class ExtendClassForMixin extends CorrectionProducer {
@@ -18,7 +18,7 @@
   FixKind get fixKind => DartFixKind.EXTEND_CLASS_FOR_MIXIN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var declaration = node.thisOrAncestorOfType<ClassDeclaration>();
     if (declaration != null && declaration.extendsClause == null) {
       // TODO(brianwilkerson) Find a way to pass in the name of the class
@@ -27,7 +27,7 @@
       var endIndex = message.lastIndexOf("'");
       var startIndex = message.lastIndexOf("'", endIndex - 1) + 1;
       _typeName = message.substring(startIndex, endIndex);
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleInsertion(
             declaration.typeParameters?.end ?? declaration.name.end,
             ' extends $_typeName');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_children.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_children.dart
index 08e28d1..2025838 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_children.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_children.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterConvertToChildren extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_CONVERT_TO_CHILDREN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // Find "child: widget" under selection.
     NamedExpression namedExp;
     {
@@ -33,7 +33,7 @@
       }
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       _convertFlutterChildToChildren(namedExp, eol, utils.getNodeText,
           utils.getLinePrefix, utils.getIndent, utils.getText, builder);
     });
@@ -46,7 +46,7 @@
       Function getLinePrefix,
       Function getIndent,
       Function getText,
-      DartFileEditBuilder builder) {
+      FileEditBuilder builder) {
     var childArg = namedExp.expression;
     var childLoc = namedExp.offset + 'child'.length;
     builder.addSimpleInsertion(childLoc, 'ren');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_stateful_widget.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_stateful_widget.dart
index b535b69..21325d1 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_stateful_widget.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_convert_to_stateful_widget.dart
@@ -11,7 +11,7 @@
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart' hide Element;
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterConvertToStatefulWidget extends CorrectionProducer {
@@ -20,7 +20,7 @@
       DartAssistKind.FLUTTER_CONVERT_TO_STATEFUL_WIDGET;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widgetClass = node.thisOrAncestorOfType<ClassDeclaration>();
     var superclass = widgetClass?.extendsClause?.superclass;
     if (widgetClass == null || superclass == null) {
@@ -116,7 +116,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(range.node(superclass), (builder) {
         builder.writeReference(statefulWidgetClass);
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_down.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_down.dart
index dd16b00..1e2fa0f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_down.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_down.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterMoveDown extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_MOVE_DOWN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widget = flutter.identifyWidgetExpression(node);
     if (widget == null) {
       return;
@@ -26,7 +26,7 @@
       List<CollectionElement> parentElements = parentList.elements;
       var index = parentElements.indexOf(widget);
       if (index != parentElements.length - 1) {
-        await builder.addFileEdit(file, (fileBuilder) {
+        await builder.addDartFileEdit(file, (fileBuilder) {
           var nextWidget = parentElements[index + 1];
           var nextRange = range.node(nextWidget);
           var nextText = utils.getRangeText(nextRange);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_up.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_up.dart
index eabb367..8513af7 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_up.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_move_up.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterMoveUp extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_MOVE_UP;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widget = flutter.identifyWidgetExpression(node);
     if (widget == null) {
       return;
@@ -26,7 +26,7 @@
       List<CollectionElement> parentElements = parentList.elements;
       var index = parentElements.indexOf(widget);
       if (index > 0) {
-        await builder.addFileEdit(file, (fileBuilder) {
+        await builder.addDartFileEdit(file, (fileBuilder) {
           var previousWidget = parentElements[index - 1];
           var previousRange = range.node(previousWidget);
           var previousText = utils.getRangeText(previousRange);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_remove_widget.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_remove_widget.dart
index 4e9ea67..c260fac 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_remove_widget.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_remove_widget.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterRemoveWidget extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_REMOVE_WIDGET;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widgetCreation = flutter.identifyNewExpression(node);
     if (widgetCreation == null) {
       return;
@@ -38,12 +38,12 @@
   }
 
   Future<void> _removeChild(
-      DartChangeBuilder builder,
+      ChangeBuilder builder,
       InstanceCreationExpression widgetCreation,
       NamedExpression childArgument) async {
     // child: ThisWidget(child: ourChild)
     // children: [foo, ThisWidget(child: ourChild), bar]
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var childExpression = childArgument.expression;
       var childText = utils.getNodeText(childExpression);
       var indentOld = utils.getLinePrefix(childExpression.offset);
@@ -54,7 +54,7 @@
   }
 
   Future<void> _removeChildren(
-      DartChangeBuilder builder,
+      ChangeBuilder builder,
       InstanceCreationExpression widgetCreation,
       List<CollectionElement> childrenExpressions) async {
     // We can inline the list of our children only into another list.
@@ -63,7 +63,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var firstChild = childrenExpressions.first;
       var lastChild = childrenExpressions.last;
       var childText = utils.getRangeText(range.startEnd(firstChild, lastChild));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_child.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_child.dart
index af9c47b..c5442e8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_child.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_child.dart
@@ -6,12 +6,12 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 abstract class FlutterParentAndChild extends CorrectionProducer {
   Future<void> swapParentAndChild(
-      DartChangeBuilder builder,
+      ChangeBuilder builder,
       InstanceCreationExpression parent,
       InstanceCreationExpression child) async {
     // The child must have its own child.
@@ -19,7 +19,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(range.node(parent), (builder) {
         var childArgs = child.argumentList;
         var parentArgs = parent.argumentList;
@@ -96,7 +96,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_SWAP_WITH_CHILD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var parent = flutter.identifyNewExpression(node);
     if (!flutter.isWidgetCreation(parent)) {
       return;
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_parent.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_parent.dart
index e385a15..cfb62b0 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_parent.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_swap_with_parent.dart
@@ -6,14 +6,14 @@
 import 'package:analysis_server/src/services/correction/dart/flutter_swap_with_child.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class FlutterSwapWithParent extends FlutterParentAndChild {
   @override
   AssistKind get assistKind => DartAssistKind.FLUTTER_SWAP_WITH_PARENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var child = flutter.identifyNewExpression(node);
     if (!flutter.isWidgetCreation(child)) {
       return;
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap.dart
index f03127c..389ad42 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap.dart
@@ -8,8 +8,9 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/source/source_range.dart';
+import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterWrap extends MultiCorrectionProducer {
@@ -138,7 +139,11 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_WRAP_PADDING;
 
   @override
-  List<String> get _leadingLines => ['padding: const EdgeInsets.all(8.0),'];
+  List<String> get _leadingLines {
+    var keyword =
+        (widgetExpr as ExpressionImpl).inConstantContext ? '' : ' const';
+    return ['padding:$keyword EdgeInsets.all(8.0),'];
+  }
 
   @override
   String get _parentClassName => 'Padding';
@@ -174,7 +179,7 @@
   String get _parentLibraryUri => flutter.widgetsUri;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var selectedRange = range.startEnd(firstWidget, lastWidget);
     var src = utils.getRangeText(selectedRange);
     var parentClassElement =
@@ -185,8 +190,8 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(selectedRange, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(selectedRange, (builder) {
         builder.writeReference(parentClassElement);
         builder.write('(');
 
@@ -231,7 +236,7 @@
   String get _parentLibraryUri => null;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widgetSrc = utils.getNodeText(widgetExpr);
 
     // If the wrapper class is specified, find its element.
@@ -246,8 +251,8 @@
       }
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(widgetExpr), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(widgetExpr), (builder) {
         if (parentClassElement == null) {
           builder.addSimpleLinkedEdit('WIDGET', 'widget');
         } else {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_generic.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_generic.dart
index 3eaec41..6b0ac1a 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_generic.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_generic.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterWrapGeneric extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_WRAP_GENERIC;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! ListLiteral) {
       return;
     }
@@ -32,8 +32,8 @@
     var indentArg = '$indentOld${utils.getIndent(1)}';
     var indentList = '$indentOld${utils.getIndent(2)}';
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(range.node(node), (DartEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(range.node(node), (builder) {
         builder.write('[');
         builder.write(eol);
         builder.write(indentArg);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_stream_builder.dart b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_stream_builder.dart
index aad39af..4e5535a 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_stream_builder.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/flutter_wrap_stream_builder.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/assist.dart';
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class FlutterWrapStreamBuilder extends CorrectionProducer {
@@ -13,7 +13,7 @@
   AssistKind get assistKind => DartAssistKind.FLUTTER_WRAP_STREAM_BUILDER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var widgetExpr = flutter.identifyWidgetExpression(node);
     if (widgetExpr == null) {
       return;
@@ -31,7 +31,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addReplacement(range.node(widgetExpr), (builder) {
         builder.writeReference(streamBuilderElement);
 
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/import_add_show.dart b/pkg/analysis_server/lib/src/services/correction/dart/import_add_show.dart
index c820844..b667ed8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/import_add_show.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/import_add_show.dart
@@ -11,14 +11,14 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class ImportAddShow extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.IMPORT_ADD_SHOW;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare ImportDirective
     var importDirective = node.thisOrAncestorOfType<ImportDirective>();
     if (importDirective == null) {
@@ -42,7 +42,7 @@
     if (referencedNames.isEmpty) {
       return;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var showCombinator = ' show ${referencedNames.join(', ')}';
       builder.addSimpleInsertion(importDirective.end - 1, showCombinator);
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/import_library.dart b/pkg/analysis_server/lib/src/services/correction/dart/import_library.dart
index 3f8754c..da36857 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/import_library.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/import_library.dart
@@ -12,7 +12,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -274,8 +274,8 @@
   FixKind get fixKind => _fixKind;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       _uriText = builder.importLibrary(_library);
     });
   }
@@ -307,12 +307,12 @@
   FixKind get fixKind => DartFixKind.IMPORT_LIBRARY_PREFIX;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var libraryElement = _importElement.importedLibrary;
     var prefix = _importElement.prefix;
     _libraryName = libraryElement.displayName;
     _prefixName = prefix.displayName;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.startLength(node, 0), '$_prefixName.');
     });
   }
@@ -336,12 +336,12 @@
   FixKind get fixKind => DartFixKind.IMPORT_LIBRARY_SHOW;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var newShowCode = 'show ${_showNames.join(', ')}';
     var offset = _showCombinator.offset;
     var length = _showCombinator.end - offset;
     var libraryFile = resolvedResult.libraryElement.source.fullName;
-    await builder.addFileEdit(libraryFile, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(libraryFile, (builder) {
       builder.addSimpleReplacement(SourceRange(offset, length), newShowCode);
     });
   }
@@ -363,8 +363,8 @@
   FixKind get fixKind => _fixKind;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       if (builder is DartFileEditBuilderImpl) {
         builder.importLibraryWithRelativeUri(_relativeURI);
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/inline_invocation.dart b/pkg/analysis_server/lib/src/services/correction/dart/inline_invocation.dart
index 1788e09..7e57e93 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/inline_invocation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/inline_invocation.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -25,7 +25,7 @@
   FixKind get fixKind => DartFixKind.INLINE_INVOCATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is! SimpleIdentifier || node.parent is! MethodInvocation) {
       return;
@@ -49,7 +49,7 @@
     var argument = invocation.argumentList.arguments[0];
     var elementText = utils.getNodeText(argument);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       if (list.elements.isNotEmpty) {
         // ['a']..add(e);
         builder.addSimpleInsertion(list.elements.last.end, ', $elementText');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/inline_typedef.dart b/pkg/analysis_server/lib/src/services/correction/dart/inline_typedef.dart
index 5d83225..b310414 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/inline_typedef.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/inline_typedef.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.INLINE_TYPEDEF;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Extract the information needed to build the edit.
     //
@@ -55,10 +55,9 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(utils.getLinesRange(range.node(parent)));
-      builder.addReplacement(range.node(finder.reference),
-          (DartEditBuilder builder) {
+      builder.addReplacement(range.node(finder.reference), (builder) {
         if (returnType != null) {
           builder.write(utils.getNodeText(returnType));
           builder.write(' ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/insert_semicolon.dart b/pkg/analysis_server/lib/src/services/correction/dart/insert_semicolon.dart
index caa2555..04ba0b4 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/insert_semicolon.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/insert_semicolon.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class InsertSemicolon extends CorrectionProducer {
@@ -13,14 +13,14 @@
   FixKind get fixKind => DartFixKind.INSERT_SEMICOLON;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var message = diagnostic.problemMessage;
     if (message.message.contains("';'")) {
       if (_isAwaitNode()) {
         return;
       }
       var insertOffset = message.offset + message.length;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleInsertion(insertOffset, ';');
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/introduce_local_cast_type.dart b/pkg/analysis_server/lib/src/services/correction/dart/introduce_local_cast_type.dart
index 30bf94a..af8eb02 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/introduce_local_cast_type.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/introduce_local_cast_type.dart
@@ -9,14 +9,14 @@
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class IntroduceLocalCastType extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.INTRODUCE_LOCAL_CAST_TYPE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is IfStatement) {
       node = (node as IfStatement).condition;
@@ -65,8 +65,8 @@
         getVariableNameSuggestionsForExpression(castType, null, excluded);
 
     if (suggestions.isNotEmpty) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addInsertion(offset, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addInsertion(offset, (builder) {
           builder.write(eol + prefix + statementPrefix);
           builder.write(castTypeCode);
           builder.write(' ');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/invert_if_statement.dart b/pkg/analysis_server/lib/src/services/correction/dart/invert_if_statement.dart
index b632c3d..38e35f2 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/invert_if_statement.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/invert_if_statement.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class InvertIfStatement extends CorrectionProducer {
@@ -14,7 +14,7 @@
   AssistKind get assistKind => DartAssistKind.INVERT_IF_STATEMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! IfStatement) {
       return;
     }
@@ -31,7 +31,7 @@
     var thenSource = utils.getNodeText(thenStatement);
     var elseSource = utils.getNodeText(elseStatement);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(condition), invertedCondition);
       builder.addSimpleReplacement(range.node(thenStatement), elseSource);
       builder.addSimpleReplacement(range.node(elseStatement), thenSource);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_inner.dart b/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_inner.dart
index 82f33e7..0c55e56 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_inner.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_inner.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/util.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class JoinIfWithInner extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.JOIN_IF_WITH_INNER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // climb up condition to the (supposedly) "if" statement
     var node = this.node;
     while (node is Expression) {
@@ -60,7 +60,7 @@
     var oldSource = utils.getRangeText(lineRanges);
     var newSource = utils.indentSourceLeftRight(oldSource);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(targetIfStatement),
           'if ($condition) {$eol$newSource$prefix}');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_outer.dart b/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_outer.dart
index 5f61bae..1e5ca88 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_outer.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/join_if_with_outer.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/util.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class JoinIfWithOuter extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.JOIN_IF_WITH_OUTER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // climb up condition to the (supposedly) "if" statement
     var node = this.node;
     while (node is Expression) {
@@ -65,7 +65,7 @@
     var oldSource = utils.getRangeText(lineRanges);
     var newSource = utils.indentSourceLeftRight(oldSource);
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(outerIfStatement),
           'if ($condition) {$eol$newSource$prefix}');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/join_variable_declaration.dart b/pkg/analysis_server/lib/src/services/correction/dart/join_variable_declaration.dart
index bba3f14..dfa9305 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/join_variable_declaration.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/join_variable_declaration.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class JoinVariableDeclaration extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.JOIN_VARIABLE_DECLARATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleIdentifier) {
       var parent = node.parent;
       if (parent is AssignmentExpression &&
@@ -35,7 +35,7 @@
   /// Join the declaration when the variable is on the left-hand side of an
   /// assignment.
   Future<void> _joinOnAssignment(
-      DartChangeBuilder builder, AssignmentExpression assignExpression) async {
+      ChangeBuilder builder, AssignmentExpression assignExpression) async {
     // Check that assignment is not a compound assignment.
     if (assignExpression.operator.type != TokenType.EQ) {
       return;
@@ -83,7 +83,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           range.endStart(declNode, assignExpression.operator), ' ');
     });
@@ -92,7 +92,7 @@
   /// Join the declaration when the variable is on the left-hand side of an
   /// assignment.
   Future<void> _joinOnDeclaration(
-      DartChangeBuilder builder, VariableDeclarationList declList) async {
+      ChangeBuilder builder, VariableDeclarationList declList) async {
     // prepare enclosing VariableDeclarationList
     var decl = declList.variables[0];
     // already initialized
@@ -134,7 +134,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           range.endStart(decl.name, assignExpression.operator), ' ');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/make_class_abstract.dart b/pkg/analysis_server/lib/src/services/correction/dart/make_class_abstract.dart
index d94a50a..c585b2e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/make_class_abstract.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/make_class_abstract.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class MakeClassAbstract extends CorrectionProducer {
@@ -18,13 +18,13 @@
   FixKind get fixKind => DartFixKind.MAKE_CLASS_ABSTRACT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var enclosingClass = node.thisOrAncestorOfType<ClassDeclaration>();
     if (enclosingClass == null) {
       return;
     }
     _className = enclosingClass.name.name;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(
           enclosingClass.classKeyword.offset, 'abstract ');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/make_field_not_final.dart b/pkg/analysis_server/lib/src/services/correction/dart/make_field_not_final.dart
index 168e961..59e8499 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/make_field_not_final.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/make_field_not_final.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -21,7 +21,7 @@
   FixKind get fixKind => DartFixKind.MAKE_FIELD_NOT_FINAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier &&
         node.staticElement is PropertyAccessorElement) {
@@ -41,14 +41,13 @@
           var keywordToken = declarationList.keyword;
           if (declarationList.variables.length == 1 &&
               keywordToken.keyword == Keyword.FINAL) {
-            await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+            await builder.addDartFileEdit(file, (builder) {
               if (declarationList.type != null) {
-                builder.addReplacement(
-                    range.startStart(keywordToken, declarationList.type),
-                    (DartEditBuilder builder) {});
+                builder.addDeletion(
+                    range.startStart(keywordToken, declarationList.type));
               } else {
                 builder.addReplacement(range.startStart(keywordToken, variable),
-                    (DartEditBuilder builder) {
+                    (builder) {
                   builder.write('var ');
                 });
               }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/make_final.dart b/pkg/analysis_server/lib/src/services/correction/dart/make_final.dart
index 33d3b0f..6db5457 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/make_final.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/make_final.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,13 +15,13 @@
   FixKind get fixKind => DartFixKind.MAKE_FINAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier &&
         node.parent is DeclaredIdentifier &&
         node.parent.parent is ForEachPartsWithDeclaration) {
       var declaration = node.parent as DeclaredIdentifier;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (declaration.keyword?.keyword == Keyword.VAR) {
           builder.addSimpleReplacement(
               range.token(declaration.keyword), 'final');
@@ -42,7 +42,7 @@
     }
     if (list != null) {
       if (list.variables.length == 1) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           if (list.keyword?.keyword == Keyword.VAR) {
             builder.addSimpleReplacement(range.token(list.keyword), 'final');
           } else if (list.lateKeyword != null) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/make_variable_not_final.dart b/pkg/analysis_server/lib/src/services/correction/dart/make_variable_not_final.dart
index 7679185..276549b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/make_variable_not_final.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/make_variable_not_final.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.MAKE_VARIABLE_NOT_FINAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is SimpleIdentifier &&
         node.staticElement is LocalVariableElement) {
@@ -35,7 +35,7 @@
         var keywordToken = declarationList.keyword;
         if (declarationList.variables.length == 1 &&
             keywordToken.keyword == Keyword.FINAL) {
-          await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(file, (builder) {
             if (declarationList.type != null) {
               builder.addDeletion(
                   range.startStart(keywordToken, declarationList.type));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/move_type_arguments_to_class.dart b/pkg/analysis_server/lib/src/services/correction/dart/move_type_arguments_to_class.dart
index 05a35e3..8381a75 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/move_type_arguments_to_class.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/move_type_arguments_to_class.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.MOVE_TYPE_ARGUMENTS_TO_CLASS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is TypeArgumentList) {
       TypeArgumentList typeArguments = coveredNode;
       if (typeArguments.parent is! InstanceCreationExpression) {
@@ -30,7 +30,7 @@
       if (element is ClassElement &&
           element.typeParameters != null &&
           element.typeParameters.length == typeArguments.arguments.length) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           var argumentText = utils.getNodeText(typeArguments);
           builder.addSimpleInsertion(typeName.end, argumentText);
           builder.addDeletion(range.node(typeArguments));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/organize_imports.dart b/pkg/analysis_server/lib/src/services/correction/dart/organize_imports.dart
index bb09e08..4c17e69 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/organize_imports.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/organize_imports.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analysis_server/src/services/correction/organize_imports.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class OrganizeImports extends CorrectionProducer {
@@ -14,13 +14,13 @@
   FixKind get fixKind => DartFixKind.ORGANIZE_IMPORTS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var organizer =
         ImportOrganizer(resolvedResult.content, unit, resolvedResult.errors);
     // todo (pq): consider restructuring organizer to allow a passed-in change
     //  builder
     for (var edit in organizer.organize()) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(
             SourceRange(edit.offset, edit.length), edit.replacement);
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/qualify_reference.dart b/pkg/analysis_server/lib/src/services/correction/dart/qualify_reference.dart
index 5cb54ce..fd81e75 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/qualify_reference.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/qualify_reference.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class QualifyReference extends CorrectionProducer {
@@ -18,7 +18,7 @@
   FixKind get fixKind => DartFixKind.QUALIFY_REFERENCE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -42,7 +42,7 @@
       return;
     }
     var containerName = enclosingElement.name;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(node.offset, '$containerName.');
     });
     _qualifiedName = '$containerName.${memberName.name}';
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_annotation.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_annotation.dart
index c6e79ef..d40a8a5 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_annotation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_annotation.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,14 +20,14 @@
   FixKind get fixKind => DartFixKind.REMOVE_ANNOTATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     void addFix(Annotation node) async {
       if (node == null) {
         return;
       }
       var followingToken = node.endToken.next;
       followingToken = followingToken.precedingComments ?? followingToken;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(node, followingToken));
       });
       _annotationName = node.name.name;
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_argument.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_argument.dart
index 4ae3553..807a069 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_argument.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_argument.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,14 +14,14 @@
   FixKind get fixKind => DartFixKind.REMOVE_ARGUMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var arg = node;
     if (arg.parent is NamedExpression) {
       arg = arg.parent;
     }
     var argumentList = arg.parent.thisOrAncestorOfType<ArgumentList>();
     if (argumentList != null) {
-      await builder.addFileEdit(file, (builder) {
+      await builder.addDartFileEdit(file, (builder) {
         final sourceRange = range.nodeInList(argumentList.arguments, arg);
         builder.addDeletion(sourceRange);
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_await.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_await.dart
index ddde92d..1ba9eed 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_await.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_await.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,11 +14,11 @@
   FixKind get fixKind => DartFixKind.REMOVE_AWAIT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final awaitExpression = node;
     if (awaitExpression is AwaitExpression) {
       final awaitToken = awaitExpression.awaitKeyword;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(awaitToken, awaitToken.next));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_const.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_const.dart
index 9a4baf9..b51dcef 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_const.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_const.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,17 +19,17 @@
   static RemoveConst newInstance() => RemoveConst();
 }
 
-class RemoveUnnecesaryConst extends _RemoveConst {
+class RemoveUnnecessaryConst extends _RemoveConst {
   @override
   FixKind get fixKind => DartFixKind.REMOVE_UNNECESSARY_CONST;
 
   /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
-  static RemoveUnnecesaryConst newInstance() => RemoveUnnecesaryConst();
+  static RemoveUnnecessaryConst newInstance() => RemoveUnnecessaryConst();
 }
 
 abstract class _RemoveConst extends CorrectionProducer {
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final expression = node;
 
     Token constToken;
@@ -44,7 +44,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(range.startStart(constToken, constToken.next));
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_code.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_code.dart
index 94cc3a2..bf9b3f1 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_code.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_code.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,13 +15,13 @@
   FixKind get fixKind => DartFixKind.REMOVE_DEAD_CODE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var coveringNode = coveredNode;
     if (coveringNode is Expression) {
       var parent = coveredNode.parent;
       if (parent is BinaryExpression) {
         if (parent.rightOperand == coveredNode) {
-          await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+          await builder.addDartFileEdit(file, (builder) {
             builder.addDeletion(range.endEnd(parent.leftOperand, coveredNode));
           });
         }
@@ -39,14 +39,14 @@
       }
       if (statementsToRemove.isNotEmpty) {
         var rangeToRemove = utils.getLinesRangeStatements(statementsToRemove);
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addDeletion(rangeToRemove);
         });
       }
     } else if (coveringNode is Statement) {
       var rangeToRemove =
           utils.getLinesRangeStatements(<Statement>[coveringNode]);
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(rangeToRemove);
       });
     } else if (coveringNode is CatchClause) {
@@ -54,7 +54,7 @@
       var catchClauses = tryStatement.catchClauses;
       var index = catchClauses.indexOf(coveringNode);
       var previous = index == 0 ? tryStatement.body : catchClauses[index - 1];
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.endEnd(previous, coveringNode));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_if_null.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_if_null.dart
index 830007a..bf576ec 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_if_null.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_dead_if_null.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_IF_NULL_OPERATOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Find the dead if-null expression.
     //
@@ -46,7 +46,7 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(sourceRange);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_duplicate_case.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_duplicate_case.dart
index ee6d03e..049461d 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_duplicate_case.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_duplicate_case.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.REMOVE_DUPLICATE_CASE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is SwitchCase) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(utils.getLinesRange(range.node(coveredNode)));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_catch.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_catch.dart
index ae79f6c..5118cc8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_catch.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_catch.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_EMPTY_CATCH;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node.parent is! CatchClause) {
       return;
     }
@@ -29,7 +29,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(utils.getLinesRange(range.node(catchClause)));
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_constructor_body.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_constructor_body.dart
index 67fa65a..bbcf86e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_constructor_body.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_constructor_body.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -13,8 +13,8 @@
   FixKind get fixKind => DartFixKind.REMOVE_EMPTY_CONSTRUCTOR_BODY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           utils.getLinesRange(range.node(node.parent)), ';');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_else.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_else.dart
index d915e1f..d3acc75 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_else.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_else.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REMOVE_EMPTY_ELSE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var parent = node.parent;
     if (parent is IfStatement) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(utils.getLinesRange(
             range.startEnd(parent.elseKeyword, parent.elseStatement)));
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_statement.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_statement.dart
index 0a1f98e..321f447 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_statement.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_empty_statement.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.REMOVE_EMPTY_STATEMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is EmptyStatement && node.parent is Block) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(utils.getLinesRange(range.node(node)));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_if_null_operator.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_if_null_operator.dart
index 4491682..ebf5ded 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_if_null_operator.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_if_null_operator.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_IF_NULL_OPERATOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var expression = node.thisOrAncestorOfType<BinaryExpression>();
     if (expression == null) {
       return;
@@ -30,7 +30,7 @@
     } else {
       return;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(sourceRange);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_initializer.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_initializer.dart
index 809a5fe..142a418 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_initializer.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_initializer.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,11 +14,11 @@
   FixKind get fixKind => DartFixKind.REMOVE_INITIALIZER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var parameter = node.thisOrAncestorOfType<DefaultFormalParameter>();
     if (parameter != null) {
       // Handle formal parameters with default values.
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(
             range.endEnd(parameter.identifier, parameter.defaultValue));
       });
@@ -26,7 +26,7 @@
       // Handle variable declarations with default values.
       var variable = node.thisOrAncestorOfType<VariableDeclaration>();
       if (variable != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder
               .addDeletion(range.endEnd(variable.name, variable.initializer));
         });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_interpolation_braces.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_interpolation_braces.dart
index 1420230..0364c14 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_interpolation_braces.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_interpolation_braces.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,12 +14,12 @@
   FixKind get fixKind => DartFixKind.REMOVE_INTERPOLATION_BRACES;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is InterpolationExpression) {
       var right = node.rightBracket;
       if (node.expression != null && right != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(
               range.startStart(node, node.expression), r'$');
           builder.addDeletion(range.token(right));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_method_declaration.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_method_declaration.dart
index 675d2ca..c4e3c2d 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_method_declaration.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_method_declaration.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REMOVE_METHOD_DECLARATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var declaration = node.thisOrAncestorOfType<MethodDeclaration>();
     if (declaration != null) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(utils.getLinesRange(range.node(declaration)));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_name_from_combinator.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_name_from_combinator.dart
index 0b44db3..e0cde53 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_name_from_combinator.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_name_from_combinator.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_NAME_FROM_COMBINATOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     SourceRange rangeForCombinator(Combinator combinator) {
       var parent = combinator.parent;
       if (parent is NamespaceDirective) {
@@ -74,7 +74,7 @@
         if (rangeToRemove == null) {
           return;
         }
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addDeletion(rangeToRemove);
         });
         _combinatorKind = parent is HideCombinator ? 'hide' : 'show';
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_operator.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_operator.dart
index 256b063..5d0053a 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_operator.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_operator.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,12 +14,12 @@
   FixKind get fixKind => DartFixKind.REMOVE_OPERATOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is BinaryExpression) {
       var expression = node as BinaryExpression;
       var operator = expression.operator;
       var rightOperand = expression.rightOperand;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(operator, rightOperand));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_parameters_in_getter_declaration.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_parameters_in_getter_declaration.dart
index 8112a2e..281e9a6 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_parameters_in_getter_declaration.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_parameters_in_getter_declaration.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,20 +14,20 @@
   FixKind get fixKind => DartFixKind.REMOVE_PARAMETERS_IN_GETTER_DECLARATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is MethodDeclaration) {
       // Support for the analyzer error.
       var method = node as MethodDeclaration;
       var name = method.name;
       var body = method.body;
       if (name != null && body != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(range.endStart(name, body), ' ');
         });
       }
     } else if (node is FormalParameterList) {
       // Support for the fasta error.
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.node(node));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_parentheses_in_getter_invocation.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_parentheses_in_getter_invocation.dart
index 20ec8de..97e5d0f8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_parentheses_in_getter_invocation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_parentheses_in_getter_invocation.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REMOVE_PARENTHESIS_IN_GETTER_INVOCATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var invocation = coveredNode?.parent;
     if (invocation is FunctionExpressionInvocation) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.node(invocation.argumentList));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_question_mark.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_question_mark.dart
index 860f571..18acf3d 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_question_mark.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_question_mark.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_QUESTION_MARK;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! TypeName) {
       return;
     }
@@ -23,7 +23,7 @@
     if (questionMark == null) {
       return;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(range.token(questionMark));
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_this_expression.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_this_expression.dart
index 3b82f5c..4ce4ad0 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_this_expression.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_this_expression.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,23 +14,23 @@
   FixKind get fixKind => DartFixKind.REMOVE_THIS_EXPRESSION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is ConstructorFieldInitializer) {
       var thisKeyword = node.thisKeyword;
       if (thisKeyword != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           var fieldName = node.fieldName;
           builder.addDeletion(range.startStart(thisKeyword, fieldName));
         });
       }
       return;
     } else if (node is PropertyAccess && node.target is ThisExpression) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startEnd(node, node.operator));
       });
     } else if (node is MethodInvocation && node.target is ThisExpression) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startEnd(node, node.operator));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_type_annotation.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_type_annotation.dart
index aa4f045..cd84ee6 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_type_annotation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_type_annotation.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_TYPE_ANNOTATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     for (var node = this.node; node != null; node = node.parent) {
       if (node is DeclaredIdentifier) {
         return _removeFromDeclaredIdentifier(builder, node);
@@ -36,8 +36,8 @@
     }
   }
 
-  Future<void> _removeFromDeclarationList(DartChangeBuilder builder,
-      VariableDeclarationList declarationList) async {
+  Future<void> _removeFromDeclarationList(
+      ChangeBuilder builder, VariableDeclarationList declarationList) async {
     // we need a type
     var typeNode = declarationList.type;
     if (typeNode == null) {
@@ -59,7 +59,7 @@
       return;
     }
     var keyword = declarationList.keyword;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var typeRange = range.startStart(typeNode, firstVariable);
       if (keyword != null && keyword.lexeme != 'var') {
         builder.addSimpleReplacement(typeRange, '');
@@ -70,14 +70,14 @@
   }
 
   Future<void> _removeFromDeclaredIdentifier(
-      DartChangeBuilder builder, DeclaredIdentifier declaration) async {
+      ChangeBuilder builder, DeclaredIdentifier declaration) async {
     var typeNode = declaration.type;
     if (typeNode == null) {
       return;
     }
     var keyword = declaration.keyword;
     var variableName = declaration.identifier;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var typeRange = range.startStart(typeNode, variableName);
       if (keyword != null && keyword.lexeme != 'var') {
         builder.addSimpleReplacement(typeRange, '');
@@ -88,12 +88,12 @@
   }
 
   Future<void> _removeTypeAnnotation(
-      DartChangeBuilder builder, TypeAnnotation type) async {
+      ChangeBuilder builder, TypeAnnotation type) async {
     if (type == null) {
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(range.startStart(type, type.endToken.next));
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_type_arguments.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_type_arguments.dart
index e47e502..815154e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_type_arguments.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_type_arguments.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REMOVE_TYPE_ARGUMENTS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is TypeArgumentList) {
       TypeArgumentList typeArguments = coveredNode;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.node(typeArguments));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_cast.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_cast.dart
index c3a26c0..009e950 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_cast.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_cast.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,14 +14,14 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNNECESSARY_CAST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is! AsExpression) {
       return;
     }
     var asExpression = coveredNode as AsExpression;
     var expression = asExpression.expression;
     // remove 'as T' from 'e as T'
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(range.endEnd(expression, asExpression));
       builder.removeEnclosingParentheses(asExpression);
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_new.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_new.dart
index a5aca38..a2654d3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_new.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unnecessary_new.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,11 +14,11 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNNECESSARY_NEW;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final instanceCreationExpression = node;
     if (instanceCreationExpression is InstanceCreationExpression) {
       final newToken = instanceCreationExpression.keyword;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(newToken, newToken.next));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused.dart
index 9559f6d..d90106e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused.dart
@@ -9,7 +9,7 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -18,7 +18,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_ELEMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final sourceRanges = <SourceRange>[];
     final referencedNode = node.parent;
     if (referencedNode is ClassDeclaration ||
@@ -48,7 +48,7 @@
       }
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       for (var sourceRange in sourceRanges) {
         builder.addDeletion(sourceRange);
       }
@@ -64,7 +64,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_FIELD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final declaration = node.parent;
     if (declaration is! VariableDeclaration) {
       return;
@@ -100,7 +100,7 @@
       sourceRanges.add(sourceRange);
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       for (var sourceRange in sourceRanges) {
         builder.addDeletion(sourceRange);
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_clause.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_clause.dart
index f783e62..078124e 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_clause.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_clause.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,12 +14,12 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_CATCH_CLAUSE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleIdentifier) {
       var catchClause = node.parent;
       if (catchClause is CatchClause &&
           catchClause.exceptionParameter == node) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addDeletion(
               range.startStart(catchClause.catchKeyword, catchClause.body));
         });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_stack.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_stack.dart
index 0f43ef3..a757788 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_stack.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_catch_stack.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,13 +14,13 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_CATCH_STACK;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is SimpleIdentifier) {
       var catchClause = node.parent;
       if (catchClause is CatchClause &&
           catchClause.stackTraceParameter == node &&
           catchClause.exceptionParameter != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder
               .addDeletion(range.endEnd(catchClause.exceptionParameter, node));
         });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_import.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_import.dart
index 7a007a9..bb5bf5a 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_import.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_import.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,14 +14,14 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_IMPORT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare ImportDirective
     var importDirective = node.thisOrAncestorOfType<ImportDirective>();
     if (importDirective == null) {
       return;
     }
     // remove the whole line with import
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(utils.getLinesRange(range.node(importDirective)));
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_label.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_label.dart
index 69675fd..86e508c 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_label.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_label.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_LABEL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is Label) {
       var nextToken = node.endToken.next;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addDeletion(range.startStart(node, nextToken));
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_local_variable.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_local_variable.dart
index c6b654c..5120c45 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_local_variable.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_local_variable.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/source/source_range.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -17,7 +17,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_LOCAL_VARIABLE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     final declaration = node.parent;
     if (!(declaration is VariableDeclaration && declaration.name == node)) {
       return;
@@ -53,7 +53,7 @@
       sourceRanges.add(sourceRange);
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       for (var sourceRange in sourceRanges) {
         builder.addDeletion(sourceRange);
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_parameter.dart b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_parameter.dart
index 00a254b..ca557b5 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_parameter.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/remove_unused_parameter.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.REMOVE_UNUSED_PARAMETER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is FormalParameter) {
       var parameter = node as FormalParameter;
       if (parameter.parent is DefaultFormalParameter) {
@@ -25,7 +25,7 @@
       var parameterList = parameter.parent as FormalParameterList;
       var parameters = parameterList.parameters;
       var index = parameters.indexOf(parameter);
-      await builder.addFileEdit(file, (builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (index == 0) {
           // Remove the first parameter in the list.
           if (parameters.length == 1) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/rename_to_camel_case.dart b/pkg/analysis_server/lib/src/services/correction/dart/rename_to_camel_case.dart
index afb6973..acb1201 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/rename_to_camel_case.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/rename_to_camel_case.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/utilities/strings.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -23,7 +23,7 @@
   FixKind get fixKind => DartFixKind.RENAME_TO_CAMEL_CASE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -55,7 +55,7 @@
     }
 
     // Compute the change.
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       for (var reference in references) {
         builder.addSimpleReplacement(range.node(reference), _newName);
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_boolean_with_bool.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_boolean_with_bool.dart
index 68c0905..0e8935f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_boolean_with_bool.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_boolean_with_bool.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -13,8 +13,8 @@
   FixKind get fixKind => DartFixKind.REPLACE_BOOLEAN_WITH_BOOL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.error(diagnostic), 'bool');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_cascade_with_dot.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_cascade_with_dot.dart
new file mode 100644
index 0000000..d37ce1e
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_cascade_with_dot.dart
@@ -0,0 +1,75 @@
+// 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 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
+import 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/token.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
+import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
+import 'package:analyzer_plugin/utilities/range_factory.dart';
+
+class ReplaceCascadeWithDot extends CorrectionProducer {
+  @override
+  FixKind get fixKind => DartFixKind.REPLACE_CASCADE_WITH_DOT;
+
+  @override
+  Future<void> compute(ChangeBuilder builder) async {
+    var node = this.node;
+    if (node is CascadeExpression) {
+      var sections = node.cascadeSections;
+      if (sections.length == 1) {
+        var section = sections[0];
+        Token cascadeOperator;
+        if (section is MethodInvocation) {
+          cascadeOperator = section.operator;
+        } else if (section is PropertyAccess) {
+          cascadeOperator = section.operator;
+        } else if (section is IndexExpression) {
+          await _handleIndexExpression(builder, section);
+          return;
+        } else if (section is AssignmentExpression) {
+          var leftHandSide = section.leftHandSide;
+          if (leftHandSide is PropertyAccess) {
+            cascadeOperator = leftHandSide.operator;
+          } else if (leftHandSide is IndexExpression) {
+            await _handleIndexExpression(builder, leftHandSide);
+            return;
+          } else {
+            return;
+          }
+        } else {
+          return;
+        }
+        var type = cascadeOperator.type;
+        if (type == TokenType.PERIOD_PERIOD ||
+            type == TokenType.QUESTION_PERIOD_PERIOD) {
+          await builder.addDartFileEdit(file, (builder) {
+            var end = cascadeOperator.end;
+            builder.addDeletion(range.startOffsetEndOffset(end - 1, end));
+          });
+        }
+      }
+    }
+  }
+
+  void _handleIndexExpression(
+      ChangeBuilder builder, IndexExpression section) async {
+    var cascadeOperator = section.period;
+    var type = cascadeOperator.type;
+    if (type == TokenType.PERIOD_PERIOD) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addDeletion(
+            range.startStart(cascadeOperator, section.leftBracket));
+      });
+    } else if (type == TokenType.QUESTION_PERIOD_PERIOD) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addSimpleReplacement(range.token(cascadeOperator), '?');
+      });
+    }
+  }
+
+  /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
+  static ReplaceCascadeWithDot newInstance() => ReplaceCascadeWithDot();
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_colon_with_equals.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_colon_with_equals.dart
index 49973fb..92076a5 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_colon_with_equals.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_colon_with_equals.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.REPLACE_COLON_WITH_EQUALS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is DefaultFormalParameter) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(
             range.token((node as DefaultFormalParameter).separator), ' =');
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_conditional_with_if_else.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_conditional_with_if_else.dart
index 1ee5fb7..ea19bac 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_conditional_with_if_else.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_conditional_with_if_else.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ReplaceConditionalWithIfElse extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.REPLACE_CONDITIONAL_WITH_IF_ELSE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     ConditionalExpression conditional;
     // may be on Statement with Conditional
     var statement = node.thisOrAncestorOfType<Statement>();
@@ -61,7 +61,7 @@
     var prefix = utils.getNodePrefix(statement);
 
     if (inVariable || inAssignment || inReturn) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         // Type v = Conditional;
         if (inVariable) {
           var variable = conditional.parent as VariableDeclaration;
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_final_with_const.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_final_with_const.dart
index 5043c39..3204819 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_final_with_const.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_final_with_const.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.REPLACE_FINAL_WITH_CONST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is VariableDeclarationList) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(
             range.token((node as VariableDeclarationList).keyword), 'const');
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_if_else_with_conditional.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_if_else_with_conditional.dart
index afeaf2d..da0961c 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_if_else_with_conditional.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_if_else_with_conditional.dart
@@ -8,7 +8,7 @@
 import 'package:analysis_server/src/services/correction/util.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class ReplaceIfElseWithConditional extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.REPLACE_IF_ELSE_WITH_CONDITIONAL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // should be "if"
     if (node is! IfStatement) {
       return;
@@ -48,7 +48,7 @@
     }
 
     if (hasReturnStatements || hasExpressionStatements) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         // returns
         if (hasReturnStatements) {
           var conditionSrc = utils.getNodeText(ifStatement.condition);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_new_with_const.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_new_with_const.dart
index c7ebaf9..56bb894 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_new_with_const.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_new_with_const.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_NEW_WITH_CONST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = this.node;
     if (node is ConstructorName) {
       node = node.parent;
@@ -22,7 +22,7 @@
     if (node is InstanceCreationExpression) {
       final keyword = node.keyword;
       if (keyword != null) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           builder.addSimpleReplacement(range.token(keyword), 'const');
         });
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_null_with_closure.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_null_with_closure.dart
index f9a6020..7adfbe7 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_null_with_closure.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_null_with_closure.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -16,7 +16,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_NULL_WITH_CLOSURE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var nodeToFix;
     var parameters = const <ParameterElement>[];
     if (coveredNode is NamedExpression) {
@@ -37,9 +37,8 @@
     }
 
     if (nodeToFix != null) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addReplacement(range.node(nodeToFix),
-            (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(range.node(nodeToFix), (builder) {
           builder.writeParameters(parameters);
           builder.write(' => null');
         });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_return_type_future.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_return_type_future.dart
index a133a81..6af3d1f 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_return_type_future.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_return_type_future.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class ReplaceReturnTypeFuture extends CorrectionProducer {
@@ -13,11 +13,11 @@
   FixKind get fixKind => DartFixKind.REPLACE_RETURN_TYPE_FUTURE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // prepare the existing type
     var typeName = node.thisOrAncestorOfType<TypeAnnotation>();
     var typeProvider = this.typeProvider;
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.replaceTypeWithFuture(typeName, typeProvider);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_var_with_dynamic.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_var_with_dynamic.dart
index e29ca07..d0176ed 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_var_with_dynamic.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_var_with_dynamic.dart
@@ -4,7 +4,7 @@
 
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -13,8 +13,8 @@
   FixKind get fixKind => DartFixKind.REPLACE_VAR_WITH_DYNAMIC;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.error(diagnostic), 'dynamic');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_brackets.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_brackets.dart
index d2e6840..0b7daad 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_brackets.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_brackets.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_BRACKETS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is EmptyStatement && node.parent is! Block) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         var previous = node.findPrevious(node.beginToken);
         if (previous != null) {
           builder.addSimpleReplacement(range.endEnd(previous, node), ' {}');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_conditional_assignment.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_conditional_assignment.dart
index bd6f0c1..83ff3ba 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_conditional_assignment.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_conditional_assignment.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_CONDITIONAL_ASSIGNMENT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     IfStatement ifStatement =
         node is IfStatement ? node : node.thisOrAncestorOfType<IfStatement>();
     if (ifStatement == null) {
@@ -32,9 +32,8 @@
     if (thenStatement is ExpressionStatement) {
       final expression = thenStatement.expression.unParenthesized;
       if (expression is AssignmentExpression) {
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-          builder.addReplacement(range.node(ifStatement),
-              (DartEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
+          builder.addReplacement(range.node(ifStatement), (builder) {
             builder.write(utils.getNodeText(expression.leftHandSide));
             builder.write(' ??= ');
             builder.write(utils.getNodeText(expression.rightHandSide));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_eight_digit_hex.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_eight_digit_hex.dart
index 171639b..863bc23 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_eight_digit_hex.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_eight_digit_hex.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_EIGHT_DIGIT_HEX;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Extract the information needed to build the edit.
     //
@@ -32,7 +32,7 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(node), _replacement);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_extension_name.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_extension_name.dart
index a52370f..5ebc324 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_extension_name.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_extension_name.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,13 +19,13 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_EXTENSION_NAME;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
     var target = _getTarget(node.parent);
     if (target is ExtensionOverride) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(
             range.node(target), utils.getNodeText(target.extensionName));
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_filled.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_filled.dart
index c369441..860e620 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_filled.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_filled.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class ReplaceWithFilled extends CorrectionProducer {
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_FILLED;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var typeName = node is SimpleIdentifier ? node.parent : node;
     var creation = typeName?.parent?.parent;
     if (typeName is TypeName && creation is InstanceCreationExpression) {
@@ -22,7 +22,7 @@
       if (typeSystem.isNullable(elementType)) {
         var argumentList = creation.argumentList;
         if (argumentList.arguments.length == 1) {
-          await builder.addFileEdit(file, (builder) {
+          await builder.addDartFileEdit(file, (builder) {
             builder.addSimpleInsertion(argumentList.offset, '.filled');
             builder.addSimpleInsertion(
                 argumentList.arguments[0].end, ', null, growable: false');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_identifier.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_identifier.dart
index 2b810b2..bacc3b3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_identifier.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_identifier.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,11 +14,11 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_IDENTIFIER;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var functionTyped =
         node.thisOrAncestorOfType<FunctionTypedFormalParameter>();
     if (functionTyped != null) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(range.node(functionTyped),
             utils.getNodeText(functionTyped.identifier));
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_interpolation.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_interpolation.dart
index 6842ebb..aaafcb8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_interpolation.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_interpolation.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 import 'package:meta/meta.dart';
@@ -16,7 +16,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_INTERPOLATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Validate the fix.
     //
@@ -41,7 +41,7 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(binary), interpolation);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_is_empty.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_is_empty.dart
index f32b089..5abb0e9 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_is_empty.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_is_empty.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind fixKind;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     /// Return the value of an integer literal or prefix expression with a
     /// minus and then an integer literal. For anything else, returns `null`.
     int getIntValue(Expression expressions) {
@@ -101,7 +101,7 @@
       return;
     }
     var target = utils.getNodeText(lengthTarget);
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(range.node(binary), '$target.$getter');
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_null_aware.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_null_aware.dart
index 2699b40..20aeeb9 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_null_aware.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_null_aware.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_NULL_AWARE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var node = coveredNode;
     if (node is Expression) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         var parent = node.parent;
         while (parent != null) {
           if (parent is MethodInvocation && parent.target == node) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_tear_off.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_tear_off.dart
index da55b5e..d638789 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_tear_off.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_tear_off.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,14 +14,14 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_TEAR_OFF;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var ancestor = node.thisOrAncestorOfType<FunctionExpression>();
     if (ancestor == null) {
       return;
     }
     Future<void> addFixOfExpression(InvocationExpression expression) async {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addReplacement(range.node(ancestor), (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(range.node(ancestor), (builder) {
           if (expression is MethodInvocation && expression.target != null) {
             builder.write(utils.getNodeText(expression.target));
             builder.write('.');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_var.dart b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_var.dart
index 7f034c3..270bb86 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/replace_with_var.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/replace_with_var.dart
@@ -6,9 +6,8 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +19,7 @@
   FixKind get fixKind => DartFixKind.REPLACE_WITH_VAR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var type = _findType(node);
     if (type == null) {
       return;
@@ -63,7 +62,7 @@
         //  this in more places by examining the elements of the collection.
         return;
       }
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (parent.isConst || parent.isFinal) {
           builder.addDeletion(range.startStart(type, variables[0]));
         } else {
@@ -84,7 +83,7 @@
           typeArgumentsOffset = iterable.offset;
         }
       }
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (parent.isConst || parent.isFinal) {
           builder.addDeletion(range.startStart(type, parent.identifier));
         } else {
@@ -127,12 +126,10 @@
           return false;
         }
         final iterableType = parent.iterable.staticType;
-        if (iterableType is InterfaceTypeImpl) {
-          var instantiatedType =
-              iterableType.asInstanceOf(typeProvider.iterableElement);
-          if (instantiatedType?.typeArguments?.first == staticType) {
-            return true;
-          }
+        var instantiatedType =
+            iterableType.asInstanceOf(typeProvider.iterableElement);
+        if (instantiatedType?.typeArguments?.first == staticType) {
+          return true;
         }
         return false;
       }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/shadow_field.dart b/pkg/analysis_server/lib/src/services/correction/dart/shadow_field.dart
index 21070b4..07a33dc 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/shadow_field.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/shadow_field.dart
@@ -9,14 +9,14 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class ShadowField extends CorrectionProducer {
   @override
   AssistKind get assistKind => DartAssistKind.SHADOW_FIELD;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! SimpleIdentifier) {
       return;
     }
@@ -51,7 +51,7 @@
     //
     // Build the change.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addInsertion(offset, (builder) {
         // TODO(brianwilkerson) Conditionally write a type annotation instead of
         //  'var' when we're able to discover user preferences.
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/sort_child_property_last.dart b/pkg/analysis_server/lib/src/services/correction/dart/sort_child_property_last.dart
index 1ce35bc..bbf8d3b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/sort_child_property_last.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/sort_child_property_last.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -20,7 +20,7 @@
   FixKind get fixKind => DartFixKind.SORT_CHILD_PROPERTY_LAST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var childProp = _findNamedExpression(node);
     if (childProp == null) {
       return;
@@ -41,7 +41,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (DartFileEditBuilder fileEditBuilder) {
+    await builder.addDartFileEdit(file, (fileEditBuilder) {
       var start = childProp.beginToken.previous.end;
       var end = childProp.endToken.next.end;
       var childRange = range.startOffsetEndOffset(start, end);
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/split_and_condition.dart b/pkg/analysis_server/lib/src/services/correction/dart/split_and_condition.dart
index c4fa305..1f38c26 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/split_and_condition.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/split_and_condition.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class SplitAndCondition extends CorrectionProducer {
@@ -16,7 +16,7 @@
   AssistKind get assistKind => DartAssistKind.SPLIT_AND_CONDITION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     // check that user invokes quick assist on binary expression
     if (node is! BinaryExpression) {
       return;
@@ -61,7 +61,7 @@
       rightConditionSource = getRangeText(rightConditionRange);
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       // remove "&& rightCondition"
       builder
           .addDeletion(range.endEnd(binaryExpression.leftOperand, condition));
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/split_variable_declaration.dart b/pkg/analysis_server/lib/src/services/correction/dart/split_variable_declaration.dart
index 088e644..faac0be 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/split_variable_declaration.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/split_variable_declaration.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
 class SplitVariableDeclaration extends CorrectionProducer {
@@ -15,7 +15,7 @@
   AssistKind get assistKind => DartAssistKind.SPLIT_VARIABLE_DECLARATION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var variableList = node?.thisOrAncestorOfType<VariableDeclarationList>();
 
     // Must be a local variable declaration.
@@ -46,7 +46,7 @@
       return;
     }
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       if (variableList.type == null) {
         final type = variable.declaredElement.type;
         if (!type.isDynamic) {
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/surround_with.dart b/pkg/analysis_server/lib/src/services/correction/dart/surround_with.dart
index a66877f..90a50c5 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/surround_with.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/surround_with.dart
@@ -8,7 +8,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 
 class SurroundWith extends MultiCorrectionProducer {
   @override
@@ -93,8 +93,8 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_BLOCK;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleInsertion(statementsRange.offset, '$indentOld{$eol');
       builder.addSimpleReplacement(
           statementsRange,
@@ -116,9 +116,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_DO_WHILE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('do {');
         builder.write(eol);
@@ -145,9 +145,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_FOR;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('for (var ');
         builder.addSimpleLinkedEdit('VAR', 'v');
@@ -180,9 +180,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_FOR_IN;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('for (var ');
         builder.addSimpleLinkedEdit('NAME', 'item');
@@ -211,9 +211,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_IF;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('if (');
         builder.addSimpleLinkedEdit('CONDITION', 'condition');
@@ -240,12 +240,12 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_SET_STATE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var classDeclaration = node.parent.thisOrAncestorOfType<ClassDeclaration>();
     if (classDeclaration != null &&
         flutter.isState(classDeclaration.declaredElement)) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(statementsRange, (builder) {
           builder.write(indentOld);
           builder.writeln('setState(() {');
           builder.write(indentedCode);
@@ -269,9 +269,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_TRY_CATCH;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('try {');
         builder.write(eol);
@@ -308,9 +308,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_TRY_FINALLY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('try {');
         builder.write(eol);
@@ -345,9 +345,9 @@
   AssistKind get assistKind => DartAssistKind.SURROUND_WITH_WHILE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-      builder.addReplacement(statementsRange, (DartEditBuilder builder) {
+  Future<void> compute(ChangeBuilder builder) async {
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addReplacement(statementsRange, (builder) {
         builder.write(indentOld);
         builder.write('while (');
         builder.addSimpleLinkedEdit('CONDITION', 'condition');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/update_sdk_constraints.dart b/pkg/analysis_server/lib/src/services/correction/dart/update_sdk_constraints.dart
index a5522c5..dcf3765 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/update_sdk_constraints.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/update_sdk_constraints.dart
@@ -7,7 +7,7 @@
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer/src/hint/sdk_constraint_extractor.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 
 class UpdateSdkConstraints extends CorrectionProducer {
@@ -22,7 +22,7 @@
   FixKind get fixKind => DartFixKind.UPDATE_SDK_CONSTRAINTS;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var context = resourceProvider.pathContext;
     File pubspecFile;
     var folder = resourceProvider.getFolder(context.dirname(file));
@@ -61,7 +61,7 @@
     if (newText == null) {
       return;
     }
-    await builder.addFileEdit(pubspecFile.path, (builder) {
+    await builder.addGenericFileEdit(pubspecFile.path, (builder) {
       builder.addSimpleReplacement(SourceRange(offset, length), newText);
     });
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_const.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_const.dart
index c73a6e6..4ac0dfc 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_const.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_const.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,10 +14,10 @@
   FixKind get fixKind => DartFixKind.USE_CONST;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is InstanceCreationExpression) {
       var instanceCreation = coveredNode as InstanceCreationExpression;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         if (instanceCreation.keyword == null) {
           builder.addSimpleInsertion(
               instanceCreation.constructorName.offset, 'const');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_curly_braces.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_curly_braces.dart
index 620e21e..e6fead3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_curly_braces.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_curly_braces.dart
@@ -7,7 +7,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer_plugin/utilities/assist/assist.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -19,7 +19,7 @@
   FixKind get fixKind => DartFixKind.ADD_CURLY_BRACES;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     var statement = node.thisOrAncestorOfType<Statement>();
     var parent = statement?.parent;
 
@@ -47,14 +47,14 @@
     }
   }
 
-  Future<void> _doStatement(DartChangeBuilder builder, DoStatement node) async {
+  Future<void> _doStatement(ChangeBuilder builder, DoStatement node) async {
     var body = node.body;
     if (body is Block) return null;
 
     var prefix = utils.getLinePrefix(node.offset);
     var indent = prefix + utils.getIndent(1);
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
         range.endStart(node.doKeyword, body),
         ' {$eol$indent',
@@ -66,15 +66,14 @@
     });
   }
 
-  Future<void> _forStatement(
-      DartChangeBuilder builder, ForStatement node) async {
+  Future<void> _forStatement(ChangeBuilder builder, ForStatement node) async {
     var body = node.body;
     if (body is Block) return null;
 
     var prefix = utils.getLinePrefix(node.offset);
     var indent = prefix + utils.getIndent(1);
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
         range.endStart(node.rightParenthesis, body),
         ' {$eol$indent',
@@ -84,11 +83,11 @@
   }
 
   Future<void> _ifStatement(
-      DartChangeBuilder builder, IfStatement node, Statement thenOrElse) async {
+      ChangeBuilder builder, IfStatement node, Statement thenOrElse) async {
     var prefix = utils.getLinePrefix(node.offset);
     var indent = prefix + utils.getIndent(1);
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       var thenStatement = node.thenStatement;
       if (thenStatement is! Block &&
           (thenOrElse == null || thenOrElse == thenStatement)) {
@@ -120,14 +119,14 @@
   }
 
   Future<void> _whileStatement(
-      DartChangeBuilder builder, WhileStatement node) async {
+      ChangeBuilder builder, WhileStatement node) async {
     var body = node.body;
     if (body is Block) return null;
 
     var prefix = utils.getLinePrefix(node.offset);
     var indent = prefix + utils.getIndent(1);
 
-    await builder.addFileEdit(file, (builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
         range.endStart(node.rightParenthesis, body),
         ' {$eol$indent',
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_effective_integer_division.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_effective_integer_division.dart
index 97a1d2a..7c086e3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_effective_integer_division.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_effective_integer_division.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,13 +14,13 @@
   FixKind get fixKind => DartFixKind.USE_EFFECTIVE_INTEGER_DIVISION;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     for (var n = node; n != null; n = n.parent) {
       if (n is MethodInvocation &&
           n.offset == errorOffset &&
           n.length == errorLength) {
         var target = (n as MethodInvocation).target.unParenthesized;
-        await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+        await builder.addDartFileEdit(file, (builder) {
           // replace "/" with "~/"
           var binary = target as BinaryExpression;
           builder.addSimpleReplacement(range.token(binary.operator), '~/');
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_eq_eq_null.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_eq_eq_null.dart
index c51598e..58fa8e6 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_eq_eq_null.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_eq_eq_null.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,13 +14,12 @@
   FixKind get fixKind => DartFixKind.USE_EQ_EQ_NULL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is IsExpression) {
       var isExpression = coveredNode as IsExpression;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder
-            .addReplacement(range.endEnd(isExpression.expression, isExpression),
-                (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(
+            range.endEnd(isExpression.expression, isExpression), (builder) {
           builder.write(' == null');
         });
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_is_not_empty.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_is_not_empty.dart
index ec1506f..39ee83b 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_is_not_empty.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_is_not_empty.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/token.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -15,7 +15,7 @@
   FixKind get fixKind => DartFixKind.USE_IS_NOT_EMPTY;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (node is! PrefixExpression) {
       return;
     }
@@ -33,7 +33,7 @@
     } else {
       return;
     }
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addDeletion(range.token(negation));
       builder.addSimpleReplacement(range.node(identifier), 'isNotEmpty');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_not_eq_null.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_not_eq_null.dart
index f699074..12ef5a8 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_not_eq_null.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_not_eq_null.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,13 +14,12 @@
   FixKind get fixKind => DartFixKind.USE_NOT_EQ_NULL;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is IsExpression) {
       var isExpression = coveredNode as IsExpression;
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
-        builder
-            .addReplacement(range.endEnd(isExpression.expression, isExpression),
-                (DartEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addReplacement(
+            range.endEnd(isExpression.expression, isExpression), (builder) {
           builder.write(' != null');
         });
       });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/use_rethrow.dart b/pkg/analysis_server/lib/src/services/correction/dart/use_rethrow.dart
index 03861e3..2afd4ed 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/use_rethrow.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/use_rethrow.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,9 +14,9 @@
   FixKind get fixKind => DartFixKind.USE_RETHROW;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     if (coveredNode is ThrowExpression) {
-      await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+      await builder.addDartFileEdit(file, (builder) {
         builder.addSimpleReplacement(range.node(coveredNode), 'rethrow');
       });
     }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_future.dart b/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_future.dart
index 62da5e5..1ccd887 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_future.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_future.dart
@@ -5,7 +5,7 @@
 import 'package:analysis_server/src/services/correction/dart/abstract_producer.dart';
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -14,7 +14,7 @@
   FixKind get fixKind => DartFixKind.WRAP_IN_FUTURE;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Extract the information needed to build the edit.
     //
@@ -30,7 +30,7 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
           range.node(expression), 'Future.value($value)');
     });
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_text.dart b/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_text.dart
index fbfc65e..53776c3 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_text.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/wrap_in_text.dart
@@ -6,7 +6,7 @@
 import 'package:analysis_server/src/services/correction/fix.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -18,7 +18,7 @@
   FixKind get fixKind => DartFixKind.WRAP_IN_TEXT;
 
   @override
-  Future<void> compute(DartChangeBuilder builder) async {
+  Future<void> compute(ChangeBuilder builder) async {
     //
     // Extract the information needed to build the edit.
     //
@@ -38,7 +38,7 @@
     //
     // Build the edit.
     //
-    await builder.addFileEdit(file, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(file, (builder) {
       builder.addSimpleReplacement(
         range.node(_stringExpression),
         'Text($stringExpressionCode)',
diff --git a/pkg/analysis_server/lib/src/services/correction/fix.dart b/pkg/analysis_server/lib/src/services/correction/fix.dart
index 3b11ecc..ee5e519 100644
--- a/pkg/analysis_server/lib/src/services/correction/fix.dart
+++ b/pkg/analysis_server/lib/src/services/correction/fix.dart
@@ -283,6 +283,7 @@
       'dart.fix.create.noSuchMethod', 49, "Create 'noSuchMethod' method");
   static const CREATE_SETTER =
       FixKind('dart.fix.create.setter', 50, "Create setter '{0}'");
+  static const DATA_DRIVEN = FixKind('dart.fix.dataDriven', 50, '{0}');
   static const EXTEND_CLASS_FOR_MIXIN =
       FixKind('dart.fix.extendClassForMixin', 50, "Extend the class '{0}'");
   static const IMPORT_ASYNC =
@@ -407,6 +408,8 @@
   static const REPLACE_BOOLEAN_WITH_BOOL = FixKind(
       'dart.fix.replace.booleanWithBool', 50, "Replace 'boolean' with 'bool'",
       appliedTogetherMessage: "Replace all 'boolean' with 'bool' in file");
+  static const REPLACE_CASCADE_WITH_DOT =
+      FixKind('dart.fix.replace.cascadeWithDot', 50, "Replace '..' with '.'");
   static const REPLACE_COLON_WITH_EQUALS =
       FixKind('dart.fix.replace.colonWithEquals', 50, "Replace ':' with '='");
   static const REPLACE_WITH_FILLED = FixKind(
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/analysis_options/fix_generator.dart b/pkg/analysis_server/lib/src/services/correction/fix/analysis_options/fix_generator.dart
index c6e25e8..32381fa 100644
--- a/pkg/analysis_server/lib/src/services/correction/fix/analysis_options/fix_generator.dart
+++ b/pkg/analysis_server/lib/src/services/correction/fix/analysis_options/fix_generator.dart
@@ -135,7 +135,7 @@
       deletionRange ??=
           _lines(nodeToDelete.span.start.offset, nodeToDelete.span.end.offset);
       var builder = ChangeBuilder();
-      await builder.addFileEdit(file, (builder) {
+      await builder.addGenericFileEdit(file, (builder) {
         builder.addDeletion(deletionRange);
       });
       _addFixFromBuilder(builder, AnalysisOptionsFixKind.REMOVE_SETTING,
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/change.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/change.dart
new file mode 100644
index 0000000..f73f6ae
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/change.dart
@@ -0,0 +1,18 @@
+// 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 'package:analysis_server/src/services/correction/dart/data_driven.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+
+/// The behavior common to all of the changes used to construct a transform.
+abstract class Change<D> {
+  /// Use the [builder] to create a change that is part or all of the fix being
+  /// made by the data-driven [fix]. The [data] is the data returned by the
+  /// [validate] method.
+  void apply(DartFileEditBuilder builder, DataDrivenFix fix, D data);
+
+  /// Validate that this change can be applied. Return the data to be passed to
+  /// [apply] if the change can be applied, or `null` if it can't be applied.
+  D validate(DataDrivenFix fix);
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change.dart
new file mode 100644
index 0000000..80649d4
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change.dart
@@ -0,0 +1,97 @@
+// 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 'package:analysis_server/src/services/correction/dart/data_driven.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/change.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/parameter_reference.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/range_factory.dart';
+import 'package:meta/meta.dart';
+
+/// The data related to a function for which one of the `Type` valued arguments
+/// has been converted into a type argument.
+class ConvertArgumentToTypeArgumentChange extends Change<_Data> {
+  /// The index of the argument that was transformed.
+  final ParameterReference parameterReference;
+
+  /// The index of the type argument into which the argument was transformed.
+  final int typeArgumentIndex;
+
+  /// Initialize a newly created transform to describe a conversion of the
+  /// argument at the [argumentIndex] to the type parameter at the
+  /// [typeArgumentIndex] for the function [element].
+  ConvertArgumentToTypeArgumentChange(
+      {@required this.parameterReference, @required this.typeArgumentIndex})
+      : assert(parameterReference != null),
+        assert(typeArgumentIndex >= 0);
+
+  @override
+  void apply(DartFileEditBuilder builder, DataDrivenFix fix, _Data data) {
+    var typeArguments = data.typeArguments;
+    var typeName = data.argumentValue;
+    if (typeArguments == null) {
+      // Adding the first type argument.
+      builder.addSimpleInsertion(
+          data.argumentList.offset, '<${typeName.name}>');
+    } else {
+      if (typeArgumentIndex == 0) {
+        // Inserting the type argument at the beginning of the list.
+        builder.addSimpleInsertion(
+            typeArguments.leftBracket.end, '${typeName.name}, ');
+      } else {
+        // Inserting the type argument after an existing type argument.
+        var previous = typeArguments.arguments[typeArgumentIndex - 1];
+        builder.addSimpleInsertion(previous.end, ', ${typeName.name}');
+      }
+    }
+    builder.addDeletion(range.nodeInList(data.arguments, data.argument));
+  }
+
+  @override
+  _Data validate(DataDrivenFix fix) {
+    var parent = fix.node.parent;
+    if (parent is MethodInvocation) {
+      var argumentList = parent.argumentList;
+      var argument = parameterReference.argumentFrom(argumentList);
+      if (argument is! SimpleIdentifier) {
+        return null;
+      }
+      var typeArguments = parent.typeArguments;
+      var typeArgumentLength =
+          typeArguments == null ? 0 : typeArguments.arguments.length;
+      if (typeArgumentIndex > typeArgumentLength) {
+        return null;
+      }
+      return _Data(argumentList, argument, typeArguments);
+    }
+    return null;
+  }
+}
+
+class _Data {
+  /// The argument list of the invocation.
+  final ArgumentList argumentList;
+
+  /// The value of the argument being moved to the list of type arguments.
+  final Identifier argumentValue;
+
+  /// The list of type arguments for the invocation, or `null` if the invocation
+  /// does not have any type arguments.
+  final TypeArgumentList typeArguments;
+
+  _Data(this.argumentList, this.argumentValue, this.typeArguments);
+
+  /// Return the argument being moved to the list of type arguments.
+  Expression get argument {
+    var parent = argumentValue.parent;
+    if (parent is NamedExpression) {
+      return parent;
+    }
+    return argumentValue;
+  }
+
+  /// The list of invocation arguments.
+  NodeList<Expression> get arguments => argumentList.arguments;
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/element_descriptor.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/element_descriptor.dart
new file mode 100644
index 0000000..b8f0b84
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/element_descriptor.dart
@@ -0,0 +1,33 @@
+// 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 'package:meta/meta.dart';
+
+/// The path to an element.
+class ElementDescriptor {
+  /// The URIs of the library in which the element is defined.
+  final List<String> libraryUris;
+
+  /// The components that uniquely identify the element within its library.
+  final List<String> components;
+
+  /// Initialize a newly created element descriptor to describe an element
+  /// accessible via any of the [libraryUris] where the path to the element
+  /// within the library is given by the list of [components].
+  ElementDescriptor({@required this.libraryUris, @required this.components});
+
+  /// Return `true` if this descriptor matches an element with the given [name]
+  /// in a library that imports the [importedUris].
+  bool matches(String name, List<String> importedUris) {
+    if (components.last != name) {
+      return false;
+    }
+    for (var importedUri in importedUris) {
+      if (libraryUris.contains(importedUri)) {
+        return true;
+      }
+    }
+    return false;
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/parameter_reference.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/parameter_reference.dart
new file mode 100644
index 0000000..e67f425
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/parameter_reference.dart
@@ -0,0 +1,57 @@
+// 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 'package:analyzer/dart/ast/ast.dart';
+
+/// A reference to a named parameter.
+class NamedParameterReference extends ParameterReference {
+  /// The name of the named parameter.
+  final String name;
+
+  /// Initialize a newly created reference to refer to the named parameter with
+  /// the given [name].
+  NamedParameterReference(this.name) : assert(name.isNotEmpty);
+
+  @override
+  Expression argumentFrom(ArgumentList argumentList) {
+    for (var argument in argumentList.arguments) {
+      if (argument is NamedExpression && argument.name.label.name == name) {
+        return argument.expression;
+      }
+    }
+    return null;
+  }
+}
+
+/// A reference to a formal parameter.
+abstract class ParameterReference {
+  /// Return the expression used to compute the value of the referenced
+  /// parameter, or `null` if there is no argument corresponding to the
+  /// parameter. Note that for named parameters this will be an expression whose
+  /// parent is a named expression.
+  Expression argumentFrom(ArgumentList argumentList);
+}
+
+/// A reference to a positional parameter.
+class PositionalParameterReference extends ParameterReference {
+  /// The index of the positional parameter.
+  final int index;
+
+  /// Initialize a newly created reference to refer to the positional parameter
+  /// with the given [index].
+  PositionalParameterReference(this.index) : assert(index >= 0);
+
+  @override
+  Expression argumentFrom(ArgumentList argumentList) {
+    var arguments = argumentList.arguments;
+    if (index >= arguments.length) {
+      return null;
+    }
+    var argument = arguments[index];
+    if (argument is NamedExpression) {
+      return null;
+    }
+    return argument;
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/rename_change.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/rename_change.dart
new file mode 100644
index 0000000..9f761fd
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/rename_change.dart
@@ -0,0 +1,37 @@
+// 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 'package:analysis_server/src/services/correction/dart/data_driven.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/change.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/range_factory.dart';
+import 'package:meta/meta.dart';
+
+/// The data related to an element that has been renamed.
+class RenameChange extends Change<SimpleIdentifier> {
+  /// The new name of the element.
+  final String newName;
+
+  /// Initialize a newly created transform to describe a renaming of an element
+  /// to the [newName].
+  RenameChange({@required this.newName});
+
+  @override
+  void apply(DartFileEditBuilder builder, DataDrivenFix fix,
+      SimpleIdentifier nameNode) {
+    builder.addSimpleReplacement(range.node(nameNode), newName);
+  }
+
+  @override
+  SimpleIdentifier validate(DataDrivenFix fix) {
+    var node = fix.node;
+    if (node is SimpleIdentifier) {
+      return node;
+    } else if (node is ConstructorName) {
+      return node.name;
+    }
+    return null;
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform.dart
new file mode 100644
index 0000000..251dcb3
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform.dart
@@ -0,0 +1,31 @@
+// 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 'package:analysis_server/src/services/correction/fix/data_driven/change.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/element_descriptor.dart';
+import 'package:meta/meta.dart';
+
+/// The behavior common to all of the data used to construct fixes.
+class Transform {
+  /// The human-readable title describing the transform.
+  final String title;
+
+  /// The element being transformed.
+  final ElementDescriptor element;
+
+  /// A list containing the changes to be applied to affect the transform.
+  final List<Change> changes;
+
+  /// Initialize a newly created transform to describe a transformation of the
+  /// [element].
+  Transform(
+      {@required this.title, @required this.element, @required this.changes});
+
+  /// Return `true` if this transform can be applied to fix an issue related to
+  /// an element with the given [name] in a library that imports the
+  /// [importedUris].
+  bool appliesTo(String name, List<String> importedUris) {
+    return element.matches(name, importedUris);
+  }
+}
diff --git a/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform_set.dart b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform_set.dart
new file mode 100644
index 0000000..e5c7445
--- /dev/null
+++ b/pkg/analysis_server/lib/src/services/correction/fix/data_driven/transform_set.dart
@@ -0,0 +1,30 @@
+// 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 'package:analysis_server/src/services/correction/fix/data_driven/transform.dart';
+
+/// A set of transforms used to aid in the construction of fixes for issues
+/// related to some body of code. Typically there is one set of transforms for
+/// each version of each package used by the code being analyzed.
+class TransformSet {
+  /// The transforms in this set.
+  final List<Transform> _transforms = [];
+
+  /// Add the given [transform] to this set.
+  void addTransform(Transform transform) {
+    _transforms.add(transform);
+  }
+
+  /// Return a list of the transforms that apply for a reference to the given
+  /// [name] in a library that imports the [importedUris].
+  List<Transform> transformsFor(String name, List<String> importedUris) {
+    var result = <Transform>[];
+    for (var transform in _transforms) {
+      if (transform.appliesTo(name, importedUris)) {
+        result.add(transform);
+      }
+    }
+    return result;
+  }
+}
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 6b83c92..c7dca1e 100644
--- a/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
@@ -69,6 +69,7 @@
 import 'package:analysis_server/src/services/correction/dart/create_mixin.dart';
 import 'package:analysis_server/src/services/correction/dart/create_no_such_method.dart';
 import 'package:analysis_server/src/services/correction/dart/create_setter.dart';
+import 'package:analysis_server/src/services/correction/dart/data_driven.dart';
 import 'package:analysis_server/src/services/correction/dart/extend_class_for_mixin.dart';
 import 'package:analysis_server/src/services/correction/dart/import_library.dart';
 import 'package:analysis_server/src/services/correction/dart/inline_invocation.dart';
@@ -115,6 +116,7 @@
 import 'package:analysis_server/src/services/correction/dart/remove_unused_parameter.dart';
 import 'package:analysis_server/src/services/correction/dart/rename_to_camel_case.dart';
 import 'package:analysis_server/src/services/correction/dart/replace_boolean_with_bool.dart';
+import 'package:analysis_server/src/services/correction/dart/replace_cascade_with_dot.dart';
 import 'package:analysis_server/src/services/correction/dart/replace_colon_with_equals.dart';
 import 'package:analysis_server/src/services/correction/dart/replace_final_with_const.dart';
 import 'package:analysis_server/src/services/correction/dart/replace_new_with_const.dart';
@@ -152,7 +154,6 @@
 import 'package:analyzer/src/generated/parser.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart'
     hide AnalysisError, Element, ElementKind;
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/fixes/fixes.dart' hide FixContributor;
 
@@ -300,9 +301,14 @@
       RemoveTypeAnnotation.newInstance,
     ],
     LintNames.avoid_returning_null_for_future: [
-      AddSync.newInstance,
+      AddAsync.newInstance,
       WrapInFuture.newInstance,
     ],
+    LintNames.avoid_single_cascade_in_expression_statements: [
+      // TODO(brianwilkerson) This fix should be applied to some non-lint
+      //  diagnostics and should also be available as an assist.
+      ReplaceCascadeWithDot.newInstance,
+    ],
     LintNames.avoid_types_as_parameter_names: [
       ConvertToOnType.newInstance,
     ],
@@ -451,7 +457,7 @@
       RemoveInterpolationBraces.newInstance,
     ],
     LintNames.unnecessary_const: [
-      RemoveUnnecesaryConst.newInstance,
+      RemoveUnnecessaryConst.newInstance,
     ],
     LintNames.unnecessary_lambdas: [
       ReplaceWithTearOff.newInstance,
@@ -526,6 +532,12 @@
     CompileTimeErrorCode.UNDEFINED_NAMED_PARAMETER: [
       ChangeArgumentName.newInstance,
     ],
+    HintCode.DEPRECATED_MEMBER_USE: [
+      DataDriven.newInstance,
+    ],
+    HintCode.DEPRECATED_MEMBER_USE_WITH_MESSAGE: [
+      DataDriven.newInstance,
+    ],
     HintCode.SDK_VERSION_ASYNC_EXPORTED_FROM_CORE: [
       ImportLibrary.dartAsync,
     ],
@@ -573,10 +585,10 @@
   /// generators used for lint rules are in the [lintProducerMap].
   static const Map<ErrorCode, List<ProducerGenerator>> nonLintProducerMap = {
     CompileTimeErrorCode.ASYNC_FOR_IN_WRONG_CONTEXT: [
-      AddSync.newInstance,
+      AddAsync.newInstance,
     ],
     CompileTimeErrorCode.AWAIT_IN_WRONG_CONTEXT: [
-      AddSync.newInstance,
+      AddAsync.newInstance,
     ],
     CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE: [
       UseConst.newInstance,
@@ -989,7 +1001,7 @@
       CreateSetter.newInstance,
     ],
     StaticWarningCode.UNDEFINED_IDENTIFIER_AWAIT: [
-      AddSync.newInstance,
+      AddAsync.newInstance,
     ],
   };
 
@@ -1044,7 +1056,7 @@
 
     Future<void> compute(CorrectionProducer producer) async {
       producer.configure(context);
-      var builder = DartChangeBuilderImpl.forWorkspace(context.workspace);
+      var builder = ChangeBuilder(workspace: context.workspace);
       await producer.compute(builder);
       _addFixFromBuilder(builder, producer.fixKind,
           args: producer.fixArguments);
diff --git a/pkg/analysis_server/lib/src/services/correction/name_suggestion.dart b/pkg/analysis_server/lib/src/services/correction/name_suggestion.dart
index 8d134df..a06b069 100644
--- a/pkg/analysis_server/lib/src/services/correction/name_suggestion.dart
+++ b/pkg/analysis_server/lib/src/services/correction/name_suggestion.dart
@@ -198,7 +198,7 @@
     }
   } else if (expression is IndexExpression) {
     name = _getBaseNameFromExpression(expression.realTarget);
-    if (name.endsWith('s')) {
+    if (name != null && name.endsWith('s')) {
       name = name.substring(0, name.length - 1);
     }
   }
diff --git a/pkg/analysis_server/lib/src/services/flutter/property.dart b/pkg/analysis_server/lib/src/services/flutter/property.dart
index 427141a..740ff85 100644
--- a/pkg/analysis_server/lib/src/services/flutter/property.dart
+++ b/pkg/analysis_server/lib/src/services/flutter/property.dart
@@ -13,6 +13,7 @@
 import 'package:analyzer/source/source_range.dart';
 import 'package:analyzer/src/dart/analysis/session_helper.dart';
 import 'package:analyzer/src/util/comment.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -105,7 +106,7 @@
       return parent._edgeInsetsProperty.changeValue(this, value);
     }
 
-    var changeBuilder = DartChangeBuilder(resolvedUnit.session);
+    var builder = ChangeBuilder(session: resolvedUnit.session);
 
     ClassElement enumClassElement;
     var enumValue = value.enumValue;
@@ -117,7 +118,7 @@
       );
     }
 
-    await changeBuilder.addFileEdit(resolvedUnit.path, (builder) {
+    await builder.addDartFileEdit(resolvedUnit.path, (builder) {
       _changeCode(builder, (builder) {
         if (value.expression != null) {
           builder.write(value.expression);
@@ -133,11 +134,11 @@
       _formatEnclosingFunctionBody(builder);
     });
 
-    return changeBuilder.sourceChange;
+    return builder.sourceChange;
   }
 
   Future<protocol.SourceChange> removeValue() async {
-    var changeBuilder = DartChangeBuilder(resolvedUnit.session);
+    var builder = ChangeBuilder(session: resolvedUnit.session);
 
     if (argumentExpression != null) {
       int endOffset;
@@ -151,14 +152,14 @@
       }
 
       var beginOffset = argumentExpression.offset;
-      await changeBuilder.addFileEdit(resolvedUnit.path, (builder) {
+      await builder.addDartFileEdit(resolvedUnit.path, (builder) {
         builder.addDeletion(
           SourceRange(beginOffset, endOffset - beginOffset),
         );
       });
     }
 
-    return changeBuilder.sourceChange;
+    return builder.sourceChange;
   }
 
   void replaceChild(String name, PropertyDescription newChild) {
@@ -526,9 +527,9 @@
       return property.removeValue();
     }
 
-    var changeBuilder = DartChangeBuilder(property.resolvedUnit.session);
+    var builder = ChangeBuilder(session: property.resolvedUnit.session);
 
-    await changeBuilder.addFileEdit(property.resolvedUnit.path, (builder) {
+    await builder.addDartFileEdit(property.resolvedUnit.path, (builder) {
       property._changeCode(builder, (builder) {
         if (leftCode == rightCode && topCode == bottomCode) {
           builder.writeReference(classEdgeInsets);
@@ -592,7 +593,7 @@
       property._formatEnclosingFunctionBody(builder);
     });
 
-    return changeBuilder.sourceChange;
+    return builder.sourceChange;
   }
 
   PropertyDescription _addNestedProperty({
diff --git a/pkg/analysis_server/lib/src/services/flutter/widget_descriptions.dart b/pkg/analysis_server/lib/src/services/flutter/widget_descriptions.dart
index 174a9a2..6476f46 100644
--- a/pkg/analysis_server/lib/src/services/flutter/widget_descriptions.dart
+++ b/pkg/analysis_server/lib/src/services/flutter/widget_descriptions.dart
@@ -131,9 +131,6 @@
   /// The offset of the widget expression.
   final int widgetOffset;
 
-  /// The instance of [Flutter] support.
-  final Flutter flutter;
-
   ClassElement _classAlignment;
   ClassElement _classAlignmentDirectional;
   ClassElement _classContainer;
@@ -143,11 +140,13 @@
     this.classRegistry,
     this.resolvedUnit,
     this.widgetOffset,
-  ) : flutter = Flutter.of(resolvedUnit);
+  );
+
+  Flutter get _flutter => Flutter.instance;
 
   Future<_WidgetDescription> compute() async {
     var node = NodeLocator2(widgetOffset).searchWithin(resolvedUnit.unit);
-    var instanceCreation = flutter.identifyNewExpression(node);
+    var instanceCreation = _flutter.identifyNewExpression(node);
     if (instanceCreation == null) {
       return null;
     }
@@ -173,7 +172,7 @@
     List<PropertyDescription> properties,
     InstanceCreationExpression widgetCreation,
   ) {
-    if (!flutter.isWidgetCreation(widgetCreation)) {
+    if (!_flutter.isWidgetCreation(widgetCreation)) {
       return;
     }
 
@@ -190,7 +189,7 @@
     }
 
     PropertyDescription containerProperty;
-    if (flutter.isExactlyContainerCreation(parentCreation)) {
+    if (_flutter.isExactlyContainerCreation(parentCreation)) {
       containerProperty = PropertyDescription(
         resolvedUnit: resolvedUnit,
         instanceCreation: parentCreation,
@@ -236,9 +235,9 @@
         classDescription: containerDescription,
       );
 
-      if (flutter.isExactlyAlignCreation(parentCreation) &&
-          flutter.findNamedArgument(parentCreation, 'widthFactor') == null &&
-          flutter.findNamedArgument(parentCreation, 'heightFactor') == null) {
+      if (_flutter.isExactlyAlignCreation(parentCreation) &&
+          _flutter.findNamedArgument(parentCreation, 'widthFactor') == null &&
+          _flutter.findNamedArgument(parentCreation, 'heightFactor') == null) {
         _replaceNestedContainerProperty(
           containerProperty,
           parentCreation,
@@ -246,7 +245,7 @@
         );
       }
 
-      if (flutter.isExactlyPaddingCreation(parentCreation)) {
+      if (_flutter.isExactlyPaddingCreation(parentCreation)) {
         _replaceNestedContainerProperty(
           containerProperty,
           parentCreation,
@@ -347,7 +346,7 @@
     var propertyDescription = PropertyDescription(
       parent: parent,
       resolvedUnit: resolvedUnit,
-      flutter: flutter,
+      flutter: _flutter,
       classDescription: classDescription,
       instanceCreation: instanceCreation,
       argumentExpression: argumentExpression,
@@ -366,7 +365,7 @@
     );
     properties.add(propertyDescription);
 
-    if (flutter.isExactEdgeInsetsGeometryType(parameter.type)) {
+    if (_flutter.isExactEdgeInsetsGeometryType(parameter.type)) {
       propertyDescription.addEdgeInsetsNestedProperties(_classEdgeInsets);
     } else if (valueExpression is InstanceCreationExpression) {
       var type = valueExpression.staticType;
@@ -414,19 +413,19 @@
   Future<void> _fetchClassElements() async {
     var sessionHelper = AnalysisSessionHelper(resolvedUnit.session);
     _classAlignment = await sessionHelper.getClass(
-      flutter.widgetsUri,
+      _flutter.widgetsUri,
       'Alignment',
     );
     _classAlignmentDirectional = await sessionHelper.getClass(
-      flutter.widgetsUri,
+      _flutter.widgetsUri,
       'AlignmentDirectional',
     );
     _classContainer = await sessionHelper.getClass(
-      flutter.widgetsUri,
+      _flutter.widgetsUri,
       'Container',
     );
     _classEdgeInsets = await sessionHelper.getClass(
-      flutter.widgetsUri,
+      _flutter.widgetsUri,
       'EdgeInsets',
     );
   }
@@ -460,7 +459,7 @@
           enumItems: _enumItemsForEnum(classElement),
         );
       }
-      if (flutter.isExactAlignmentGeometry(classElement)) {
+      if (_flutter.isExactAlignmentGeometry(classElement)) {
         var items = <protocol.FlutterWidgetPropertyValueEnumItem>[];
         items.addAll(
           _enumItemsForStaticFields(_classAlignment),
@@ -484,7 +483,7 @@
     InstanceCreationExpression parentCreation,
     String name,
   ) {
-    var argument = flutter.findNamedArgument(parentCreation, name);
+    var argument = _flutter.findNamedArgument(parentCreation, name);
     if (argument != null) {
       var replacements = <PropertyDescription>[];
       _addProperty(
@@ -536,8 +535,8 @@
         if (field is FieldElement && field.isStatic) {
           var enclosingClass = field.enclosingElement as ClassElement;
           if (field.isEnumConstant ||
-              flutter.isExactAlignment(enclosingClass) ||
-              flutter.isExactAlignmentDirectional(enclosingClass)) {
+              _flutter.isExactAlignment(enclosingClass) ||
+              _flutter.isExactAlignmentDirectional(enclosingClass)) {
             return protocol.FlutterWidgetPropertyValue(
               enumValue: _toEnumItem(field),
             );
diff --git a/pkg/analysis_server/lib/src/services/linter/lint_names.dart b/pkg/analysis_server/lib/src/services/linter/lint_names.dart
index 4b2883f..c291cc2 100644
--- a/pkg/analysis_server/lib/src/services/linter/lint_names.dart
+++ b/pkg/analysis_server/lib/src/services/linter/lint_names.dart
@@ -23,6 +23,8 @@
       'avoid_return_types_on_setters';
   static const String avoid_returning_null_for_future =
       'avoid_returning_null_for_future';
+  static const String avoid_single_cascade_in_expression_statements =
+      'avoid_single_cascade_in_expression_statements';
   static const String avoid_types_as_parameter_names =
       'avoid_types_as_parameter_names';
   static const String avoid_types_on_closure_parameters =
diff --git a/pkg/analysis_server/lib/src/services/refactoring/extract_widget.dart b/pkg/analysis_server/lib/src/services/refactoring/extract_widget.dart
index 6726707..d608269 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/extract_widget.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/extract_widget.dart
@@ -24,6 +24,7 @@
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/generated/java_core.dart';
 import 'package:analyzer/src/generated/source.dart' show SourceRange;
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/range_factory.dart';
 
@@ -37,7 +38,6 @@
   final int length;
 
   CorrectionUtils utils;
-  Flutter flutter;
 
   ClassElement classBuildContext;
   ClassElement classKey;
@@ -78,7 +78,6 @@
       this.searchEngine, this.resolveResult, this.offset, this.length)
       : sessionHelper = AnalysisSessionHelper(resolveResult.session) {
     utils = CorrectionUtils(resolveResult);
-    flutter = Flutter.of(resolveResult);
   }
 
   @override
@@ -90,6 +89,8 @@
     return resolveResult.unit.featureSet;
   }
 
+  Flutter get _flutter => Flutter.instance;
+
   bool get _isNonNullable => _featureSet.isEnabled(Feature.non_nullable);
 
   @override
@@ -142,8 +143,8 @@
 
   @override
   Future<SourceChange> createChange() async {
-    var changeBuilder = DartChangeBuilder(sessionHelper.session);
-    await changeBuilder.addFileEdit(resolveResult.path, (builder) {
+    var builder = ChangeBuilder(session: sessionHelper.session);
+    await builder.addDartFileEdit(resolveResult.path, (builder) {
       if (_expression != null) {
         builder.addReplacement(range.node(_expression), (builder) {
           _writeWidgetInstantiation(builder);
@@ -161,7 +162,7 @@
 
       _writeWidgetDeclaration(builder);
     });
-    return changeBuilder.sourceChange;
+    return builder.sourceChange;
   }
 
   @override
@@ -184,8 +185,8 @@
     _enclosingClassElement = _enclosingClassNode?.declaredElement;
 
     // new MyWidget(...)
-    var newExpression = flutter.identifyNewExpression(node);
-    if (flutter.isWidgetCreation(newExpression)) {
+    var newExpression = _flutter.identifyNewExpression(node);
+    if (_flutter.isWidgetCreation(newExpression)) {
       _expression = newExpression;
       return RefactoringStatus();
     }
@@ -203,7 +204,7 @@
       if (statements.isNotEmpty) {
         var lastStatement = statements.last;
         if (lastStatement is ReturnStatement &&
-            flutter.isWidgetExpression(lastStatement.expression)) {
+            _flutter.isWidgetExpression(lastStatement.expression)) {
           _statements = statements;
           _statementsRange = range.startEnd(statements.first, statements.last);
           return RefactoringStatus();
@@ -221,7 +222,7 @@
       }
       if (node is MethodDeclaration) {
         var returnType = node.returnType?.type;
-        if (flutter.isWidgetType(returnType) && node.body != null) {
+        if (_flutter.isWidgetType(returnType) && node.body != null) {
           _method = node;
           return RefactoringStatus();
         }
@@ -238,10 +239,10 @@
     var result = RefactoringStatus();
 
     Future<ClassElement> getClass(String name) async {
-      var element = await sessionHelper.getClass(flutter.widgetsUri, name);
+      var element = await sessionHelper.getClass(_flutter.widgetsUri, name);
       if (element == null) {
         result.addFatalError(
-          "Unable to find '$name' in ${flutter.widgetsUri}",
+          "Unable to find '$name' in ${_flutter.widgetsUri}",
         );
       }
       return element;
diff --git a/pkg/analysis_server/lib/src/services/refactoring/move_file.dart b/pkg/analysis_server/lib/src/services/refactoring/move_file.dart
index 5de7725..614cc5d 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/move_file.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/move_file.dart
@@ -66,7 +66,7 @@
 
   @override
   Future<SourceChange> createChange() async {
-    var changeBuilder = ChangeBuilder();
+    var changeBuilder = ChangeBuilder(session: resolvedUnit.session);
     var element = resolvedUnit.unit.declaredElement;
     if (element == null) {
       return changeBuilder.sourceChange;
@@ -88,7 +88,7 @@
               .where(
                   (po) => po.uri != null && _isRelativeUri(po.uri.stringValue));
           if (partOfs.isNotEmpty) {
-            await changeBuilder.addFileEdit(
+            await changeBuilder.addDartFileEdit(
                 result.unit.declaredElement.source.fullName, (builder) {
               partOfs.forEach((po) {
                 final oldDir = pathContext.dirname(oldFile);
@@ -107,7 +107,7 @@
         }
       }
 
-      await changeBuilder.addFileEdit(definingUnitResult.path, (builder) {
+      await changeBuilder.addDartFileEdit(definingUnitResult.path, (builder) {
         var oldDir = pathContext.dirname(oldFile);
         var newDir = pathContext.dirname(newFile);
         for (var directive in definingUnitResult.unit.directives) {
@@ -123,7 +123,7 @@
           .where((po) => po.uri != null && _isRelativeUri(po.uri.stringValue));
 
       if (partOfs.isNotEmpty) {
-        await changeBuilder.addFileEdit(element.source.fullName, (builder) {
+        await changeBuilder.addDartFileEdit(element.source.fullName, (builder) {
           partOfs.forEach((po) {
             final oldDir = pathContext.dirname(oldFile);
             final newDir = pathContext.dirname(newFile);
@@ -141,7 +141,7 @@
         await refactoringWorkspace.searchEngine.searchReferences(element);
     var references = getSourceReferences(matches);
     for (var reference in references) {
-      await changeBuilder.addFileEdit(reference.file, (builder) {
+      await changeBuilder.addDartFileEdit(reference.file, (builder) {
         var newUri = _computeNewUri(reference);
         builder.addSimpleReplacement(reference.range, "'$newUri'");
       });
diff --git a/pkg/analysis_server/lib/src/services/refactoring/rename_unit_member.dart b/pkg/analysis_server/lib/src/services/refactoring/rename_unit_member.dart
index b3c18ef..b8d9705 100644
--- a/pkg/analysis_server/lib/src/services/refactoring/rename_unit_member.dart
+++ b/pkg/analysis_server/lib/src/services/refactoring/rename_unit_member.dart
@@ -141,8 +141,7 @@
   }
 
   void _findFlutterStateClass() {
-    var flutter = Flutter.of(resolvedUnit);
-    if (flutter.isStatefulWidgetDeclaration(element)) {
+    if (Flutter.instance.isStatefulWidgetDeclaration(element)) {
       var oldStateName = oldName + 'State';
       _flutterWidgetState = element.library.getType(oldStateName) ??
           element.library.getType('_' + oldStateName);
diff --git a/pkg/analysis_server/lib/src/status/diagnostics.dart b/pkg/analysis_server/lib/src/status/diagnostics.dart
index 38470ac..39e8891 100644
--- a/pkg/analysis_server/lib/src/status/diagnostics.dart
+++ b/pkg/analysis_server/lib/src/status/diagnostics.dart
@@ -1357,7 +1357,7 @@
         var firstTime = lintRegistry.getTimer(first).elapsedMilliseconds;
         var secondTime = lintRegistry.getTimer(second).elapsedMilliseconds;
         if (firstTime == secondTime) {
-          return first.lintCode.name.compareTo(second.lintCode.name);
+          return first.name.compareTo(second.name);
         }
         return secondTime - firstTime;
       });
@@ -1365,7 +1365,7 @@
       _writeRow(['Lint code', 'Time (in ms)'], header: true);
       for (var rule in rules) {
         var time = lintRegistry.getTimer(rule).elapsedMilliseconds;
-        _writeRow([rule.lintCode.name, printMilliseconds(time)]);
+        _writeRow([rule.name, printMilliseconds(time)]);
       }
       buf.write('</table>');
     }
diff --git a/pkg/analysis_server/lib/src/utilities/flutter.dart b/pkg/analysis_server/lib/src/utilities/flutter.dart
index 0a9b690..d8cc17b 100644
--- a/pkg/analysis_server/lib/src/utilities/flutter.dart
+++ b/pkg/analysis_server/lib/src/utilities/flutter.dart
@@ -3,15 +3,15 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analysis_server/src/utilities/strings.dart';
-import 'package:analyzer/dart/analysis/results.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
 
 class Flutter {
+  static final Flutter instance = Flutter();
+
   static const _nameAlign = 'Align';
   static const _nameCenter = 'Center';
   static const _nameContainer = 'Container';
@@ -22,60 +22,32 @@
   static const _nameStreamBuilder = 'StreamBuilder';
   static const _nameWidget = 'Widget';
 
-  static final mobile = Flutter._('flutter', 'package:flutter');
-  static final web = Flutter._('flutter_web', 'package:flutter_web');
+  final String widgetsUri = 'package:flutter/widgets.dart';
 
-  static final _uriFlutterMobileWidgets =
-      Uri.parse('package:flutter/widgets.dart');
-
-  static final _uriFlutterWebWidgets =
-      Uri.parse('package:flutter_web/widgets.dart');
-
-  final String packageName;
-  final String widgetsUri;
-
-  final Uri _uriAlignment;
-  final Uri _uriAsync;
-  final Uri _uriBasic;
-  final Uri _uriContainer;
-  final Uri _uriEdgeInsets;
-  final Uri _uriFramework;
-  final Uri _uriWidgetsIcon;
-  final Uri _uriWidgetsText;
-
-  factory Flutter.of(ResolvedUnitResult resolvedUnit) {
-    var uriConverter = resolvedUnit.session.uriConverter;
-    var isMobile = uriConverter.uriToPath(_uriFlutterMobileWidgets) != null;
-    var isWeb = uriConverter.uriToPath(_uriFlutterWebWidgets) != null;
-
-    if (isMobile && isWeb) {
-      var visitor = _IdentifyMobileOrWeb();
-      resolvedUnit.unit.accept(visitor);
-      isMobile = visitor.isMobile;
-      isWeb = visitor.isWeb;
-    }
-
-    if (isMobile) {
-      return mobile;
-    }
-
-    if (isWeb) {
-      return web;
-    }
-
-    return mobile;
-  }
-
-  Flutter._(this.packageName, String uriPrefix)
-      : widgetsUri = '$uriPrefix/widgets.dart',
-        _uriAlignment = Uri.parse('$uriPrefix/src/painting/alignment.dart'),
-        _uriAsync = Uri.parse('$uriPrefix/src/widgets/async.dart'),
-        _uriBasic = Uri.parse('$uriPrefix/src/widgets/basic.dart'),
-        _uriContainer = Uri.parse('$uriPrefix/src/widgets/container.dart'),
-        _uriEdgeInsets = Uri.parse('$uriPrefix/src/painting/edge_insets.dart'),
-        _uriFramework = Uri.parse('$uriPrefix/src/widgets/framework.dart'),
-        _uriWidgetsIcon = Uri.parse('$uriPrefix/src/widgets/icon.dart'),
-        _uriWidgetsText = Uri.parse('$uriPrefix/src/widgets/text.dart');
+  final Uri _uriAlignment = Uri.parse(
+    'package:flutter/src/painting/alignment.dart',
+  );
+  final Uri _uriAsync = Uri.parse(
+    'package:flutter/src/widgets/async.dart',
+  );
+  final Uri _uriBasic = Uri.parse(
+    'package:flutter/src/widgets/basic.dart',
+  );
+  final Uri _uriContainer = Uri.parse(
+    'package:flutter/src/widgets/container.dart',
+  );
+  final Uri _uriEdgeInsets = Uri.parse(
+    'package:flutter/src/painting/edge_insets.dart',
+  );
+  final Uri _uriFramework = Uri.parse(
+    'package:flutter/src/widgets/framework.dart',
+  );
+  final Uri _uriWidgetsIcon = Uri.parse(
+    'package:flutter/src/widgets/icon.dart',
+  );
+  final Uri _uriWidgetsText = Uri.parse(
+    'package:flutter/src/widgets/text.dart',
+  );
 
   /// Return the argument with the given [index], or `null` if none.
   Expression argumentByIndex(List<Expression> arguments, int index) {
@@ -579,27 +551,3 @@
     return element != null && element.name == type && element.source.uri == uri;
   }
 }
-
-class _IdentifyMobileOrWeb extends GeneralizingAstVisitor<void> {
-  bool isMobile = false;
-  bool isWeb = false;
-
-  @override
-  void visitExpression(Expression node) {
-    if (isMobile || isWeb) {
-      return;
-    }
-
-    if (Flutter.mobile.isWidgetExpression(node)) {
-      isMobile = true;
-      return;
-    }
-
-    if (Flutter.web.isWidgetExpression(node)) {
-      isWeb = true;
-      return;
-    }
-
-    super.visitExpression(node);
-  }
-}
diff --git a/pkg/analysis_server/test/analysis/get_hover_test.dart b/pkg/analysis_server/test/analysis/get_hover_test.dart
index edcae43..c214da5 100644
--- a/pkg/analysis_server/test/analysis/get_hover_test.dart
+++ b/pkg/analysis_server/test/analysis/get_hover_test.dart
@@ -49,6 +49,7 @@
 class B<T> extends A<T> with M1, M2<int> implements I1<int, String>, I2 {}
 ''');
     var hover = await prepareHover('B<T>');
+    expect(hover.containingClassDescription, null);
     expect(
         hover.elementDescription,
         'class B<T> extends A<T> with M1, M2<int> '
@@ -63,6 +64,7 @@
 abstract class B extends A {}
 ''');
     var hover = await prepareHover('B extends');
+    expect(hover.containingClassDescription, null);
     expect(hover.elementDescription, 'abstract class B extends A');
     expect(hover.staticType, isNull);
     expect(hover.propagatedType, isNull);
@@ -313,6 +315,7 @@
 enum MyEnum {AAA, BBB, CCC}
 ''');
     var hover = await prepareHover('MyEnum');
+    expect(hover.containingClassDescription, null);
     expect(hover.elementDescription, 'enum MyEnum');
     expect(hover.staticType, isNull);
     expect(hover.propagatedType, isNull);
@@ -325,6 +328,7 @@
 extension E on A {}
 ''');
     var hover = await prepareHover('E');
+    expect(hover.containingClassDescription, null);
     expect(hover.elementDescription, 'extension E on A');
     expect(hover.dartdoc, 'Comment');
     expect(hover.staticType, isNull);
diff --git a/pkg/analysis_server/test/analysis/notification_errors_test.dart b/pkg/analysis_server/test/analysis/notification_errors_test.dart
index db65a09..f003fd6 100644
--- a/pkg/analysis_server/test/analysis/notification_errors_test.dart
+++ b/pkg/analysis_server/test/analysis/notification_errors_test.dart
@@ -176,6 +176,35 @@
     expect(filesErrors[brokenFile], isNull);
   }
 
+  Future<void> test_excludedFolder() async {
+    addAnalysisOptionsFile('''
+analyzer:
+  exclude:
+    - excluded/**
+''');
+    createProject();
+    var excludedFile =
+        newFile(join(projectPath, 'excluded/broken.dart'), content: 'err').path;
+
+    // There should be no errors initially.
+    await waitForTasksFinished();
+    await pumpEventQueue(times: 5000);
+    expect(filesErrors[excludedFile], isNull);
+
+    // Triggering the file to be processed should still generate no errors.
+    await waitResponse(AnalysisGetHoverParams(excludedFile, 0).toRequest('0'));
+    await waitForTasksFinished();
+    await pumpEventQueue(times: 5000);
+    expect(filesErrors[excludedFile], isNull);
+
+    // Opening the file should still generate no errors.
+    await waitResponse(
+        AnalysisSetPriorityFilesParams([excludedFile]).toRequest('0'));
+    await waitForTasksFinished();
+    await pumpEventQueue(times: 5000);
+    expect(filesErrors[excludedFile], isNull);
+  }
+
   Future<void> test_importError() async {
     createProject();
 
diff --git a/pkg/analysis_server/test/edit/bulk_fixes_test.dart b/pkg/analysis_server/test/edit/bulk_fixes_test.dart
new file mode 100644
index 0000000..52fd967
--- /dev/null
+++ b/pkg/analysis_server/test/edit/bulk_fixes_test.dart
@@ -0,0 +1,72 @@
+// 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 'package:analysis_server/protocol/protocol_generated.dart';
+import 'package:analysis_server/src/edit/edit_domain.dart';
+import 'package:analyzer_plugin/protocol/protocol_common.dart';
+import 'package:linter/src/rules.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../analysis_abstract.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(BulkFixesTest);
+  });
+}
+
+@reflectiveTest
+class BulkFixesTest extends AbstractAnalysisTest {
+  Future<void> assertEditEquals(String expectedSource) async {
+    await waitForTasksFinished();
+    var edits = await _getBulkEdits();
+    expect(edits, hasLength(1));
+    var editedSource = SourceEdit.applySequence(testCode, edits[0].edits);
+    expect(editedSource, expectedSource);
+  }
+
+  @override
+  void setUp() {
+    super.setUp();
+    registerLintRules();
+    handler = EditDomainHandler(server);
+  }
+
+  Future<void> test_missingOverride() async {
+    createProject();
+    addAnalysisOptionsFile('''
+linter:
+  rules:
+    - annotate_overrides
+''');
+    addTestFile('''
+class A {
+  void f() {}
+}
+class B extends A {
+  void f() { }
+}
+''');
+
+    await assertEditEquals('''
+class A {
+  void f() {}
+}
+class B extends A {
+  @override
+  void f() { }
+}
+''');
+  }
+
+  Future<List<SourceFileEdit>> _getBulkEdits() async {
+    var request = EditBulkFixesParams([testFile]).toRequest('0');
+    var response = await waitResponse(request);
+    var result = EditBulkFixesResult.fromResponse(response);
+    return result.edits;
+  }
+}
diff --git a/pkg/analysis_server/test/edit/postfix_completion_test.dart b/pkg/analysis_server/test/edit/postfix_completion_test.dart
index fdd4948..9f55b0f 100644
--- a/pkg/analysis_server/test/edit/postfix_completion_test.dart
+++ b/pkg/analysis_server/test/edit/postfix_completion_test.dart
@@ -36,7 +36,7 @@
 }
 ''');
     await waitForTasksFinished();
-    await _prepareCompletion('.for', atStart: true);
+    await _prepareCompletion('.for');
     _assertHasChange('Expand .for', '''
 main() {
   for (var value in []) {
@@ -88,8 +88,7 @@
     fail('Expected to find |$message| but got: ' + change.message);
   }
 
-  Future<void> _prepareCompletion(String key,
-      {bool atStart = false, bool atEnd = false, int delta = 0}) async {
+  Future<void> _prepareCompletion(String key) async {
     var offset = findOffset(key);
     var src = testCode.replaceFirst(key, '', offset);
     modifyTestFile(src);
diff --git a/pkg/analysis_server/test/edit/test_all.dart b/pkg/analysis_server/test/edit/test_all.dart
index 4f7fa7d..7950e43 100644
--- a/pkg/analysis_server/test/edit/test_all.dart
+++ b/pkg/analysis_server/test/edit/test_all.dart
@@ -5,6 +5,7 @@
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'assists_test.dart' as assists;
+import 'bulk_fixes_test.dart' as bulk_fixes;
 import 'fixes_test.dart' as fixes;
 import 'format_test.dart' as format;
 import 'organize_directives_test.dart' as organize_directives;
@@ -17,6 +18,7 @@
 void main() {
   defineReflectiveSuite(() {
     assists.main();
+    bulk_fixes.main();
     fixes.main();
     format.main();
     organize_directives.main();
diff --git a/pkg/analysis_server/test/integration/coverage.md b/pkg/analysis_server/test/integration/coverage.md
index 20ee12c..06b628a 100644
--- a/pkg/analysis_server/test/integration/coverage.md
+++ b/pkg/analysis_server/test/integration/coverage.md
@@ -44,6 +44,7 @@
 - [x] diagnostic.getServerPort
 
 ## edit domain
+- [x] edit.bulkFixes
 - [x] edit.dartfix
 - [x] edit.format
 - [x] edit.getAssists
diff --git a/pkg/analysis_server/test/integration/edit/bulk_fixes_test.dart b/pkg/analysis_server/test/integration/edit/bulk_fixes_test.dart
new file mode 100644
index 0000000..922c0c8
--- /dev/null
+++ b/pkg/analysis_server/test/integration/edit/bulk_fixes_test.dart
@@ -0,0 +1,37 @@
+// 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 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../support/integration_tests.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(BulkFixesTest);
+  });
+}
+
+@reflectiveTest
+class BulkFixesTest extends AbstractAnalysisServerIntegrationTest {
+  void setupTarget() {
+    writeFile(sourcePath('test.dart'), '''
+class A {
+  void f() {}
+}
+class B extends A {
+  void f() { }
+}
+''');
+    standardAnalysisSetup();
+  }
+
+  @failingTest
+  Future<void> test_bulk_fix_override() async {
+    setupTarget();
+
+    var result = await sendEditBulkFixes([sourceDirectory.path]);
+    expect(result.edits.length, 1);
+  }
+}
diff --git a/pkg/analysis_server/test/integration/edit/import_elements_test.dart b/pkg/analysis_server/test/integration/edit/import_elements_test.dart
index 790173e..f717356 100644
--- a/pkg/analysis_server/test/integration/edit/import_elements_test.dart
+++ b/pkg/analysis_server/test/integration/edit/import_elements_test.dart
@@ -6,8 +6,8 @@
 
 import 'package:analysis_server/protocol/protocol_generated.dart';
 import 'package:analyzer/file_system/physical_file_system.dart';
-import 'package:analyzer/src/dart/sdk/sdk.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -85,7 +85,7 @@
     standardAnalysisSetup();
     await analysisFinished;
     var provider = PhysicalResourceProvider.INSTANCE;
-    var sdkPath = FolderBasedDartSdk.defaultSdkDirectory(provider).path;
+    var sdkPath = getSdkPath();
     var mathPath =
         provider.pathContext.join(sdkPath, 'lib', 'math', 'math.dart');
 
@@ -118,7 +118,7 @@
     standardAnalysisSetup();
     await analysisFinished;
     var provider = PhysicalResourceProvider.INSTANCE;
-    var sdkPath = FolderBasedDartSdk.defaultSdkDirectory(provider).path;
+    var sdkPath = getSdkPath();
     var mathPath =
         provider.pathContext.join(sdkPath, 'lib', 'math', 'math.dart');
 
diff --git a/pkg/analysis_server/test/integration/edit/test_all.dart b/pkg/analysis_server/test/integration/edit/test_all.dart
index 3ac606c..5c3a653 100644
--- a/pkg/analysis_server/test/integration/edit/test_all.dart
+++ b/pkg/analysis_server/test/integration/edit/test_all.dart
@@ -4,6 +4,7 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
+import 'bulk_fixes_test.dart' as bulk_fixes_test;
 import 'dartfix_test.dart' as dartfix_test;
 import 'format_test.dart' as format_test;
 import 'get_assists_test.dart' as get_assists_test;
@@ -24,6 +25,7 @@
 
 void main() {
   defineReflectiveSuite(() {
+    bulk_fixes_test.main();
     dartfix_test.main();
     format_test.main();
     get_assists_test.main();
diff --git a/pkg/analysis_server/test/integration/lsp_server/initialization_test.dart b/pkg/analysis_server/test/integration/lsp_server/initialization_test.dart
index 7a23822..1759e58 100644
--- a/pkg/analysis_server/test/integration/lsp_server/initialization_test.dart
+++ b/pkg/analysis_server/test/integration/lsp_server/initialization_test.dart
@@ -20,10 +20,10 @@
   Future<void> test_initialize_invalidParams() async {
     final params = {'processId': 'invalid'};
     final request = RequestMessage(
-      Either2<num, String>.t1(1),
-      Method.initialize,
-      params,
-      jsonRpcVersion,
+      id: Either2<num, String>.t1(1),
+      method: Method.initialize,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     final response = await sendRequestToServer(request);
     expect(response.id, equals(request.id));
diff --git a/pkg/analysis_server/test/integration/support/integration_test_methods.dart b/pkg/analysis_server/test/integration/support/integration_test_methods.dart
index 744785a..9799790 100644
--- a/pkg/analysis_server/test/integration/support/integration_test_methods.dart
+++ b/pkg/analysis_server/test/integration/support/integration_test_methods.dart
@@ -1562,6 +1562,38 @@
     return EditGetDartfixInfoResult.fromJson(decoder, 'result', result);
   }
 
+  /// Analyze the specified sources for fixes that can be applied in bulk and
+  /// return a set of suggested edits for those sources. These edits may
+  /// include changes to sources outside the set of specified sources if a
+  /// change in a specified source requires it.
+  ///
+  /// Parameters
+  ///
+  /// included: List<FilePath>
+  ///
+  ///   A list of the files and directories for which edits should be
+  ///   suggested.
+  ///
+  ///   If a request is made with a path that is invalid, e.g. is not absolute
+  ///   and normalized, an error of type INVALID_FILE_PATH_FORMAT will be
+  ///   generated. If a request is made for a file which does not exist, or
+  ///   which is not currently subject to analysis (e.g. because it is not
+  ///   associated with any analysis root specified to
+  ///   analysis.setAnalysisRoots), an error of type FILE_NOT_ANALYZED will be
+  ///   generated.
+  ///
+  /// Returns
+  ///
+  /// edits: List<SourceFileEdit>
+  ///
+  ///   A list of source edits to apply the recommended changes.
+  Future<EditBulkFixesResult> sendEditBulkFixes(List<String> included) async {
+    var params = EditBulkFixesParams(included).toJson();
+    var result = await server.send('edit.bulkFixes', params);
+    var decoder = ResponseDecoder(null);
+    return EditBulkFixesResult.fromJson(decoder, 'result', result);
+  }
+
   /// Analyze the specified sources for recommended changes and return a set of
   /// suggested edits for those sources. These edits may include changes to
   /// sources outside the set of specified sources if a change in a specified
diff --git a/pkg/analysis_server/test/integration/support/protocol_matchers.dart b/pkg/analysis_server/test/integration/support/protocol_matchers.dart
index 6764831..f4736c1 100644
--- a/pkg/analysis_server/test/integration/support/protocol_matchers.dart
+++ b/pkg/analysis_server/test/integration/support/protocol_matchers.dart
@@ -2205,6 +2205,22 @@
 final Matcher isDiagnosticGetServerPortResult = LazyMatcher(() =>
     MatchesJsonObject('diagnostic.getServerPort result', {'port': isInt}));
 
+/// edit.bulkFixes params
+///
+/// {
+///   "included": List<FilePath>
+/// }
+final Matcher isEditBulkFixesParams = LazyMatcher(() => MatchesJsonObject(
+    'edit.bulkFixes params', {'included': isListOf(isFilePath)}));
+
+/// edit.bulkFixes result
+///
+/// {
+///   "edits": List<SourceFileEdit>
+/// }
+final Matcher isEditBulkFixesResult = LazyMatcher(() => MatchesJsonObject(
+    'edit.bulkFixes result', {'edits': isListOf(isSourceFileEdit)}));
+
 /// edit.dartfix params
 ///
 /// {
diff --git a/pkg/analysis_server/test/lsp/cancel_request_test.dart b/pkg/analysis_server/test/lsp/cancel_request_test.dart
index 6e065b9..f39dff9 100644
--- a/pkg/analysis_server/test/lsp/cancel_request_test.dart
+++ b/pkg/analysis_server/test/lsp/cancel_request_test.dart
@@ -33,14 +33,13 @@
     final completionRequest = makeRequest(
       Method.textDocument_completion,
       CompletionParams(
-        null,
-        TextDocumentIdentifier(mainFileUri.toString()),
-        positionFromMarker(content),
+        textDocument: TextDocumentIdentifier(uri: mainFileUri.toString()),
+        position: positionFromMarker(content),
       ),
     );
     // And a request to cancel it.
     final cancelNotification = makeNotification(
-        Method.cancelRequest, CancelParams(completionRequest.id));
+        Method.cancelRequest, CancelParams(id: completionRequest.id));
 
     // Send both (without waiting for the results of the first).
     final completionRequestFuture = sendRequestToServer(completionRequest);
diff --git a/pkg/analysis_server/test/lsp/code_actions_abstract.dart b/pkg/analysis_server/test/lsp/code_actions_abstract.dart
index a9b288c..5c3cd8c 100644
--- a/pkg/analysis_server/test/lsp/code_actions_abstract.dart
+++ b/pkg/analysis_server/test/lsp/code_actions_abstract.dart
@@ -105,7 +105,7 @@
         // When the server sends the edit back, just keep a copy and say we
         // applied successfully (it'll be verified below).
         editParams = edit;
-        return ApplyWorkspaceEditResponse(true, null);
+        return ApplyWorkspaceEditResponse(applied: true);
       },
     );
     // Successful edits return an empty success() response.
diff --git a/pkg/analysis_server/test/lsp/code_actions_source_test.dart b/pkg/analysis_server/test/lsp/code_actions_source_test.dart
index 08f227c..d5529b4 100644
--- a/pkg/analysis_server/test/lsp/code_actions_source_test.dart
+++ b/pkg/analysis_server/test/lsp/code_actions_source_test.dart
@@ -281,7 +281,8 @@
       // Claim that we failed tpo apply the edits. This is what the client
       // would do if the edits provided were for an old version of the
       // document.
-      handler: (edit) => ApplyWorkspaceEditResponse(false, 'Document changed'),
+      handler: (edit) => ApplyWorkspaceEditResponse(
+          applied: false, failureReason: 'Document changed'),
     );
 
     // Ensure the request returned an error (error repsonses are thrown by
diff --git a/pkg/analysis_server/test/lsp/completion_test.dart b/pkg/analysis_server/test/lsp/completion_test.dart
index 52cad68..eb61712 100644
--- a/pkg/analysis_server/test/lsp/completion_test.dart
+++ b/pkg/analysis_server/test/lsp/completion_test.dart
@@ -108,8 +108,9 @@
     final invalidTriggerKind = CompletionTriggerKind.fromJson(-1);
     final request = getCompletion(
       mainFileUri,
-      Position(0, 0),
-      context: CompletionContext(invalidTriggerKind, 'A'),
+      Position(line: 0, character: 0),
+      context: CompletionContext(
+          triggerKind: invalidTriggerKind, triggerCharacter: 'A'),
     );
 
     await expectLater(
@@ -292,13 +293,14 @@
     await openFile(mainFileUri, withoutMarkers(content));
     final res = await getCompletion(mainFileUri, positionFromMarker(content));
     final item = res.singleWhere((c) => c.label == 'abcdefghij');
+    // ignore: deprecated_member_use_from_same_package
     expect(item.deprecated, isNull);
     // If the does not say it supports the deprecated flag, we should show
     // '(deprecated)' in the details.
     expect(item.detail.toLowerCase(), contains('deprecated'));
   }
 
-  Future<void> test_isDeprecated_supported() async {
+  Future<void> test_isDeprecated_supportedFlag() async {
     final content = '''
     class MyClass {
       @deprecated
@@ -312,17 +314,44 @@
     ''';
 
     await initialize(
-        textDocumentCapabilities: withCompletionItemDeprecatedSupport(
+        textDocumentCapabilities: withCompletionItemDeprecatedFlagSupport(
             emptyTextDocumentClientCapabilities));
     await openFile(mainFileUri, withoutMarkers(content));
     final res = await getCompletion(mainFileUri, positionFromMarker(content));
     final item = res.singleWhere((c) => c.label == 'abcdefghij');
+    // ignore: deprecated_member_use_from_same_package
     expect(item.deprecated, isTrue);
     // If the client says it supports the deprecated flag, we should not show
     // deprecated in the details.
     expect(item.detail, isNot(contains('deprecated')));
   }
 
+  Future<void> test_isDeprecated_supportedTag() async {
+    final content = '''
+    class MyClass {
+      @deprecated
+      String abcdefghij;
+    }
+
+    main() {
+      MyClass a;
+      a.abc^
+    }
+    ''';
+
+    await initialize(
+        textDocumentCapabilities: withCompletionItemTagSupport(
+            emptyTextDocumentClientCapabilities,
+            [CompletionItemTag.Deprecated]));
+    await openFile(mainFileUri, withoutMarkers(content));
+    final res = await getCompletion(mainFileUri, positionFromMarker(content));
+    final item = res.singleWhere((c) => c.label == 'abcdefghij');
+    expect(item.tags, contains(CompletionItemTag.Deprecated));
+    // If the client says it supports the deprecated tag, we should not show
+    // deprecated in the details.
+    expect(item.detail, isNot(contains('deprecated')));
+  }
+
   Future<void> test_namedArg_plainText() async {
     final content = '''
     class A { const A({int one}); }
@@ -363,7 +392,9 @@
     expect(item.textEdit.newText, equals(r'one: ${1:}'));
     expect(
       item.textEdit.range,
-      equals(Range(positionFromMarker(content), positionFromMarker(content))),
+      equals(Range(
+          start: positionFromMarker(content),
+          end: positionFromMarker(content))),
     );
   }
 
@@ -850,7 +881,7 @@
         // When the server sends the edit back, just keep a copy and say we
         // applied successfully (it'll be verified below).
         editParams = edit;
-        return ApplyWorkspaceEditResponse(true, null);
+        return ApplyWorkspaceEditResponse(applied: true);
       },
     );
     // Successful edits return an empty success() response.
@@ -945,6 +976,41 @@
     '''));
   }
 
+  /// This test reproduces a bug where the pathKey hash used in
+  /// available_declarations.dart would not change with the contents of the file
+  /// (as it always used 0 as the modification stamp) which would prevent
+  /// completion including items from files that were open (had overlays).
+  /// https://github.com/Dart-Code/Dart-Code/issues/2286#issuecomment-658597532
+  Future<void> test_suggestionSets_modifiedFiles() async {
+    final otherFilePath = join(projectFolderPath, 'lib', 'other_file.dart');
+    final otherFileUri = Uri.file(otherFilePath);
+
+    final mainFileContent = 'MyOtherClass^';
+    final initialAnalysis = waitForAnalysisComplete();
+    await initialize(
+        workspaceCapabilities:
+            withApplyEditSupport(emptyWorkspaceClientCapabilities));
+    await openFile(mainFileUri, withoutMarkers(mainFileContent));
+    await initialAnalysis;
+
+    // Start with a blank file.
+    newFile(otherFilePath, content: '');
+    await openFile(otherFileUri, '');
+    await pumpEventQueue(times: 5000);
+
+    // Reopen the file with a class definition.
+    await closeFile(otherFileUri);
+    await openFile(otherFileUri, 'class MyOtherClass {}');
+    await pumpEventQueue(times: 5000);
+
+    // Ensure the class appears in completion.
+    final completions =
+        await getCompletion(mainFileUri, positionFromMarker(mainFileContent));
+    final matching =
+        completions.where((c) => c.label == 'MyOtherClass').toList();
+    expect(matching, hasLength(1));
+  }
+
   Future<void> test_suggestionSets_namedConstructors() async {
     newFile(
       join(projectFolderPath, 'other_file.dart'),
diff --git a/pkg/analysis_server/test/lsp/definition_test.dart b/pkg/analysis_server/test/lsp/definition_test.dart
index 3e3e414..a70f005 100644
--- a/pkg/analysis_server/test/lsp/definition_test.dart
+++ b/pkg/analysis_server/test/lsp/definition_test.dart
@@ -69,12 +69,16 @@
 
     newFile(pluginAnalyzedFilePath);
     await initialize();
-    final res = await getDefinition(pluginAnalyzedFileUri, lsp.Position(0, 0));
+    final res = await getDefinition(
+        pluginAnalyzedFileUri, lsp.Position(line: 0, character: 0));
 
     expect(res, hasLength(1));
     var loc = res.single;
     expect(
-        loc.range, equals(lsp.Range(lsp.Position(0, 0), lsp.Position(0, 5))));
+        loc.range,
+        equals(lsp.Range(
+            start: lsp.Position(line: 0, character: 0),
+            end: lsp.Position(line: 0, character: 5))));
     expect(loc.uri, equals(pluginAnalyzedFileUri.toString()));
   }
 
diff --git a/pkg/analysis_server/test/lsp/diagnostic_test.dart b/pkg/analysis_server/test/lsp/diagnostic_test.dart
index fac84a9..2716301 100644
--- a/pkg/analysis_server/test/lsp/diagnostic_test.dart
+++ b/pkg/analysis_server/test/lsp/diagnostic_test.dart
@@ -127,6 +127,61 @@
     expect(updatedDiagnostics, hasLength(0));
   }
 
+  Future<void> test_diagnosticTag_deprecated() async {
+    newFile(mainFilePath, content: '''
+    @deprecated
+    int dep;
+
+    void main() => print(dep);
+    ''');
+
+    final diagnosticsUpdate = waitForDiagnostics(mainFileUri);
+    await initialize(
+        textDocumentCapabilities: withDiagnosticTagSupport(
+            emptyTextDocumentClientCapabilities, [DiagnosticTag.Deprecated]));
+    final diagnostics = await diagnosticsUpdate;
+    expect(diagnostics, hasLength(1));
+    final diagnostic = diagnostics.first;
+    expect(diagnostic.code, equals('deprecated_member_use_from_same_package'));
+    expect(diagnostic.tags, contains(DiagnosticTag.Deprecated));
+  }
+
+  Future<void> test_diagnosticTag_notSupported() async {
+    newFile(mainFilePath, content: '''
+    @deprecated
+    int dep;
+
+    void main() => print(dep);
+    ''');
+
+    final diagnosticsUpdate = waitForDiagnostics(mainFileUri);
+    await initialize();
+    final diagnostics = await diagnosticsUpdate;
+    expect(diagnostics, hasLength(1));
+    final diagnostic = diagnostics.first;
+    expect(diagnostic.code, equals('deprecated_member_use_from_same_package'));
+    expect(diagnostic.tags, isNull);
+  }
+
+  Future<void> test_diagnosticTag_unnecessary() async {
+    newFile(mainFilePath, content: '''
+    void main() {
+      return;
+      print('unreachable');
+    }
+    ''');
+
+    final diagnosticsUpdate = waitForDiagnostics(mainFileUri);
+    await initialize(
+        textDocumentCapabilities: withDiagnosticTagSupport(
+            emptyTextDocumentClientCapabilities, [DiagnosticTag.Unnecessary]));
+    final diagnostics = await diagnosticsUpdate;
+    expect(diagnostics, hasLength(1));
+    final diagnostic = diagnostics.first;
+    expect(diagnostic.code, equals('dead_code'));
+    expect(diagnostic.tags, contains(DiagnosticTag.Unnecessary));
+  }
+
   Future<void> test_dotFilesExcluded() async {
     var dotFolderFilePath =
         join(projectFolderPath, '.dart_tool', 'tool_file.dart');
@@ -139,7 +194,7 @@
 
     // Send a request for a hover.
     await initialize();
-    await getHover(dotFolderFileUri, Position(0, 0));
+    await getHover(dotFolderFileUri, Position(line: 0, character: 0));
 
     // Ensure that as part of responding to getHover, diagnostics were not
     // transmitted.
diff --git a/pkg/analysis_server/test/lsp/document_changes_test.dart b/pkg/analysis_server/test/lsp/document_changes_test.dart
index b2f6368..7994ae0 100644
--- a/pkg/analysis_server/test/lsp/document_changes_test.dart
+++ b/pkg/analysis_server/test/lsp/document_changes_test.dart
@@ -1,4 +1,5 @@
 import 'package:analysis_server/lsp_protocol/protocol_generated.dart';
+import 'package:analysis_server/lsp_protocol/protocol_special.dart';
 import 'package:analysis_server/src/protocol/protocol_internal.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart' hide Position;
 import 'package:test/test.dart';
@@ -29,16 +30,20 @@
   Future<void> test_documentChange_notifiesPlugins() async {
     await _initializeAndOpen();
     await changeFile(2, mainFileUri, [
-      TextDocumentContentChangeEvent(
-        Range(Position(0, 6), Position(0, 9)),
-        0,
-        'Bar',
-      ),
-      TextDocumentContentChangeEvent(
-        Range(Position(1, 21), Position(1, 24)),
-        0,
-        'updated',
-      ),
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+        range: Range(
+            start: Position(line: 0, character: 6),
+            end: Position(line: 0, character: 9)),
+        text: 'Bar',
+      )),
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+        range: Range(
+            start: Position(line: 1, character: 21),
+            end: Position(line: 1, character: 24)),
+        text: 'updated',
+      )),
     ]);
 
     final notifiedChanges = pluginManager.analysisUpdateContentParams
@@ -53,16 +58,20 @@
   Future<void> test_documentChange_updatesOverlay() async {
     await _initializeAndOpen();
     await changeFile(2, mainFileUri, [
-      TextDocumentContentChangeEvent(
-        Range(Position(0, 6), Position(0, 9)),
-        0,
-        'Bar',
-      ),
-      TextDocumentContentChangeEvent(
-        Range(Position(1, 21), Position(1, 24)),
-        0,
-        'updated',
-      ),
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+        range: Range(
+            start: Position(line: 0, character: 6),
+            end: Position(line: 0, character: 9)),
+        text: 'Bar',
+      )),
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+        range: Range(
+            start: Position(line: 1, character: 21),
+            end: Position(line: 1, character: 24)),
+        text: 'updated',
+      )),
     ]);
 
     expect(server.resourceProvider.hasOverlay(mainFilePath), isTrue);
diff --git a/pkg/analysis_server/test/lsp/file_modification_test.dart b/pkg/analysis_server/test/lsp/file_modification_test.dart
index 6063bfd..9afc443 100644
--- a/pkg/analysis_server/test/lsp/file_modification_test.dart
+++ b/pkg/analysis_server/test/lsp/file_modification_test.dart
@@ -3,6 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analysis_server/lsp_protocol/protocol_generated.dart';
+import 'package:analysis_server/lsp_protocol/protocol_special.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -26,11 +27,13 @@
     // to alert the user to something failing.
     final error = await expectErrorNotification<ShowMessageParams>(() async {
       await changeFile(222, mainFileUri, [
-        TextDocumentContentChangeEvent(
-          Range(Position(999, 999), Position(999, 999)),
-          null,
-          '   ',
-        )
+        Either2<TextDocumentContentChangeEvent1,
+            TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+          range: Range(
+              start: Position(line: 999, character: 999),
+              end: Position(line: 999, character: 999)),
+          text: '   ',
+        ))
       ]);
     });
 
@@ -58,11 +61,13 @@
     await openFile(mainFileUri, initialContent);
     await changeFile(222, mainFileUri, [
       // Replace line1:5-1:8 with spaces.
-      TextDocumentContentChangeEvent(
-        Range(Position(1, 5), Position(1, 8)),
-        null,
-        '   ',
-      )
+      Either2<TextDocumentContentChangeEvent1,
+          TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+        range: Range(
+            start: Position(line: 1, character: 5),
+            end: Position(line: 1, character: 8)),
+        text: '   ',
+      ))
     ]);
     expect(_getOverlay(mainFilePath), equals(expectedUpdatedContent));
 
@@ -74,11 +79,13 @@
     // It's not valid for a client to send a request to modify a file that it
     // has not opened, but Visual Studio has done it in the past so we should
     // ensure it generates an obvious error that the user can understand.
-    final simpleEdit = TextDocumentContentChangeEvent(
-      Range(Position(1, 1), Position(1, 1)),
-      null,
-      'test',
-    );
+    final simpleEdit = Either2<TextDocumentContentChangeEvent1,
+        TextDocumentContentChangeEvent2>.t1(TextDocumentContentChangeEvent1(
+      range: Range(
+          start: Position(line: 1, character: 1),
+          end: Position(line: 1, character: 1)),
+      text: 'test',
+    ));
     await initialize();
     final notificationParams = await expectErrorNotification<ShowMessageParams>(
       () => changeFile(222, mainFileUri, [simpleEdit]),
diff --git a/pkg/analysis_server/test/lsp/flutter_outline_test.dart b/pkg/analysis_server/test/lsp/flutter_outline_test.dart
index f79de6c..8a21287 100644
--- a/pkg/analysis_server/test/lsp/flutter_outline_test.dart
+++ b/pkg/analysis_server/test/lsp/flutter_outline_test.dart
@@ -88,18 +88,33 @@
     expect(outline, isNotNull);
 
     // Root node is entire document
-    expect(outline.range, equals(Range(Position(0, 0), Position(15, 0))));
+    expect(
+        outline.range,
+        equals(Range(
+            start: Position(line: 0, character: 0),
+            end: Position(line: 15, character: 0))));
     expect(outline.children, hasLength(1));
 
     final build = outline.children[0];
     expect(build.kind, equals('DART_ELEMENT'));
-    expect(build.range, equals(Range(Position(2, 0), Position(14, 6))));
-    expect(build.codeRange, equals(Range(Position(3, 0), Position(14, 6))));
+    expect(
+        build.range,
+        equals(Range(
+            start: Position(line: 2, character: 0),
+            end: Position(line: 14, character: 6))));
+    expect(
+        build.codeRange,
+        equals(Range(
+            start: Position(line: 3, character: 0),
+            end: Position(line: 14, character: 6))));
     expect(build.dartElement.kind, equals('FUNCTION'));
     expect(build.dartElement.name, equals('build'));
     expect(build.dartElement.parameters, equals('(BuildContext context)'));
-    expect(build.dartElement.range,
-        equals(Range(Position(3, 7), Position(3, 12))));
+    expect(
+        build.dartElement.range,
+        equals(Range(
+            start: Position(line: 3, character: 7),
+            end: Position(line: 3, character: 12))));
     expect(build.dartElement.returnType, equals('Widget'));
     expect(build.children, hasLength(1));
 
@@ -107,13 +122,20 @@
         build.children[0].children[0].children[0].children[0].children[0];
     expect(icon.kind, equals('NEW_INSTANCE'));
     expect(icon.className, 'Icon');
-    expect(icon.range, equals(Range(Position(8, 31), Position(8, 50))));
+    expect(
+        icon.range,
+        equals(Range(
+            start: Position(line: 8, character: 31),
+            end: Position(line: 8, character: 50))));
     expect(icon.codeRange, equals(icon.range));
     expect(icon.attributes, hasLength(1));
     expect(icon.attributes[0].name, equals('icon'));
     expect(icon.attributes[0].label, equals('Icons.ac_unit'));
-    expect(icon.attributes[0].valueRange,
-        equals(Range(Position(8, 36), Position(8, 49))));
+    expect(
+        icon.attributes[0].valueRange,
+        equals(Range(
+            start: Position(line: 8, character: 36),
+            end: Position(line: 8, character: 49))));
     expect(icon.dartElement, isNull);
     expect(icon.children, hasLength(0));
   }
diff --git a/pkg/analysis_server/test/lsp/folding_test.dart b/pkg/analysis_server/test/lsp/folding_test.dart
index 807a303..1caf00a 100644
--- a/pkg/analysis_server/test/lsp/folding_test.dart
+++ b/pkg/analysis_server/test/lsp/folding_test.dart
@@ -28,11 +28,10 @@
     final range1 = rangeFromMarkers(content);
     final expectedRegions = [
       FoldingRange(
-        range1.start.line,
-        range1.start.character,
-        range1.end.line,
-        range1.end.character,
-        null,
+        startLine: range1.start.line,
+        startCharacter: range1.start.character,
+        endLine: range1.end.line,
+        endCharacter: range1.end.character,
       )
     ];
 
@@ -53,11 +52,11 @@
     final range1 = rangeFromMarkers(content);
     final expectedRegions = [
       FoldingRange(
-        range1.start.line,
-        range1.start.character,
-        range1.end.line,
-        range1.end.character,
-        FoldingRangeKind.Comment,
+        startLine: range1.start.line,
+        startCharacter: range1.start.character,
+        endLine: range1.end.line,
+        endCharacter: range1.end.character,
+        kind: FoldingRangeKind.Comment,
       )
     ];
 
@@ -91,11 +90,10 @@
     final ranges = rangesFromMarkers(content);
     final expectedRegions = ranges
         .map((range) => FoldingRange(
-              range.start.line,
-              range.start.character,
-              range.end.line,
-              range.end.character,
-              null,
+              startLine: range.start.line,
+              startCharacter: range.start.character,
+              endLine: range.end.line,
+              endCharacter: range.end.character,
             ))
         .toList();
 
@@ -219,11 +217,10 @@
     final ranges = rangesFromMarkers(content);
     final expectedRegions = ranges
         .map((range) => FoldingRange(
-              range.start.line,
-              range.start.character,
-              range.end.line,
-              range.end.character,
-              null,
+              startLine: range.start.line,
+              startCharacter: range.start.character,
+              endLine: range.end.line,
+              endCharacter: range.end.character,
             ))
         .toList();
 
@@ -265,11 +262,10 @@
     final ranges = rangesFromMarkers(content);
     final expectedRegions = ranges
         .map((range) => FoldingRange(
-              range.start.line,
-              range.start.character,
-              range.end.line,
-              range.end.character,
-              null,
+              startLine: range.start.line,
+              startCharacter: range.start.character,
+              endLine: range.end.line,
+              endCharacter: range.end.character,
             ))
         .toList();
 
@@ -282,11 +278,11 @@
 
   FoldingRange _toFoldingRange(Range range, FoldingRangeKind kind) {
     return FoldingRange(
-      range.start.line,
-      range.start.character,
-      range.end.line,
-      range.end.character,
-      kind,
+      startLine: range.start.line,
+      startCharacter: range.start.character,
+      endLine: range.end.line,
+      endCharacter: range.end.character,
+      kind: kind,
     );
   }
 }
diff --git a/pkg/analysis_server/test/lsp/format_test.dart b/pkg/analysis_server/test/lsp/format_test.dart
index 8c72af5..5a51229 100644
--- a/pkg/analysis_server/test/lsp/format_test.dart
+++ b/pkg/analysis_server/test/lsp/format_test.dart
@@ -18,6 +18,13 @@
 
 @reflectiveTest
 class FormatTest extends AbstractLspAnalysisServerTest {
+  Future<void> expectFormattedContents(
+      Uri uri, String original, String expected) async {
+    final formatEdits = await formatDocument(uri.toString());
+    final formattedContents = applyTextEdits(original, formatEdits);
+    expect(formattedContents, equals(expected));
+  }
+
   Future<void> test_alreadyFormatted() async {
     const contents = '''main() {
   print('test');
@@ -149,6 +156,32 @@
     expect(formatEdits, isNull);
   }
 
+  Future<void> test_lineLength() async {
+    const contents = '''
+    main() =>
+    print(
+    '123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789'
+    );
+    ''';
+    final expectedDefault = '''main() => print(
+    '123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789');\n''';
+    final expectedLongLines =
+        '''main() => print('123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789 123456789');\n''';
+
+    // Initialize with config support, supplying an empty config when requested.
+    await provideConfig(
+      () => initialize(
+          workspaceCapabilities: withDidChangeConfigurationDynamicRegistration(
+              withConfigurationSupport(emptyWorkspaceClientCapabilities))),
+      {}, // empty config
+    );
+    await openFile(mainFileUri, contents);
+
+    await expectFormattedContents(mainFileUri, contents, expectedDefault);
+    await updateConfig({'lineLength': 500});
+    await expectFormattedContents(mainFileUri, contents, expectedLongLines);
+  }
+
   Future<void> test_nonDartFile() async {
     await initialize();
     await openFile(pubspecFileUri, simplePubspecContent);
@@ -201,11 +234,7 @@
 ''';
     await initialize();
     await openFile(mainFileUri, contents);
-
-    final formatEdits = await formatDocument(mainFileUri.toString());
-    expect(formatEdits, isNotNull);
-    final formattedContents = applyTextEdits(contents, formatEdits);
-    expect(formattedContents, equals(expected));
+    await expectFormattedContents(mainFileUri, contents, expected);
   }
 
   Future<void> test_unopenFile() async {
@@ -222,10 +251,6 @@
 ''';
     newFile(mainFilePath, content: contents);
     await initialize();
-
-    final formatEdits = await formatDocument(mainFileUri.toString());
-    expect(formatEdits, isNotNull);
-    final formattedContents = applyTextEdits(contents, formatEdits);
-    expect(formattedContents, equals(expected));
+    await expectFormattedContents(mainFileUri, contents, expected);
   }
 }
diff --git a/pkg/analysis_server/test/lsp/hover_test.dart b/pkg/analysis_server/test/lsp/hover_test.dart
index a20279e..d46f8bb8 100644
--- a/pkg/analysis_server/test/lsp/hover_test.dart
+++ b/pkg/analysis_server/test/lsp/hover_test.dart
@@ -43,7 +43,7 @@
     await initialize();
     await openFile(mainFileUri, '');
     await expectLater(
-      () => getHover(mainFileUri, Position(999, 999)),
+      () => getHover(mainFileUri, Position(line: 999, character: 999)),
       throwsA(isResponseError(ServerErrorCodes.InvalidFileLineCol)),
     );
   }
diff --git a/pkg/analysis_server/test/lsp/implementation_test.dart b/pkg/analysis_server/test/lsp/implementation_test.dart
index ff4a3c8..195b46b 100644
--- a/pkg/analysis_server/test/lsp/implementation_test.dart
+++ b/pkg/analysis_server/test/lsp/implementation_test.dart
@@ -173,7 +173,7 @@
     );
 
     final expectedLocations = rangesFromMarkers(content)
-        .map((r) => Location(mainFileUri.toString(), r));
+        .map((r) => Location(uri: mainFileUri.toString(), range: r));
 
     if (shouldMatch) {
       expect(res, equals(expectedLocations));
diff --git a/pkg/analysis_server/test/lsp/initialization_test.dart b/pkg/analysis_server/test/lsp/initialization_test.dart
index 304ce32..f8bf3d6 100644
--- a/pkg/analysis_server/test/lsp/initialization_test.dart
+++ b/pkg/analysis_server/test/lsp/initialization_test.dart
@@ -45,6 +45,8 @@
     // static registrations for them.
     // https://github.com/dart-lang/sdk/issues/38490
     InitializeResult initResult = initResponse.result;
+    expect(initResult.serverInfo.name, 'Dart SDK LSP Analysis Server');
+    expect(initResult.serverInfo.version, isNotNull);
     expect(initResult.capabilities, isNotNull);
     expect(initResult.capabilities.textDocumentSync, isNull);
 
@@ -235,8 +237,9 @@
 
     final registrations = (request.params as RegistrationParams).registrations;
 
-    final documentFilterSql = DocumentFilter(null, 'file', '**/*.sql');
-    final documentFilterDart = DocumentFilter('dart', 'file', null);
+    final documentFilterSql =
+        DocumentFilter(scheme: 'file', pattern: '**/*.sql');
+    final documentFilterDart = DocumentFilter(language: 'dart', scheme: 'file');
     final expectedFoldingRegistration =
         isA<TextDocumentRegistrationOptions>().having(
       (o) => o.documentSelector,
@@ -277,10 +280,10 @@
   Future<void> test_initialize_invalidParams() async {
     final params = {'processId': 'invalid'};
     final request = RequestMessage(
-      Either2<num, String>.t1(1),
-      Method.initialize,
-      params,
-      jsonRpcVersion,
+      id: Either2<num, String>.t1(1),
+      method: Method.initialize,
+      params: params,
+      jsonrpc: jsonRpcVersion,
     );
     final response = await sendRequestToServer(request);
     expect(response.id, equals(request.id));
diff --git a/pkg/analysis_server/test/lsp/outline_test.dart b/pkg/analysis_server/test/lsp/outline_test.dart
index 26231f3..8ab0aa3 100644
--- a/pkg/analysis_server/test/lsp/outline_test.dart
+++ b/pkg/analysis_server/test/lsp/outline_test.dart
@@ -78,16 +78,32 @@
     expect(outline, isNotNull);
 
     // Root node is entire document
-    expect(outline.range, equals(Range(Position(0, 0), Position(11, 0))));
+    expect(
+        outline.range,
+        equals(Range(
+            start: Position(line: 0, character: 0),
+            end: Position(line: 11, character: 0))));
     expect(outline.children, hasLength(1));
 
     // class A
     final classA = outline.children[0];
     expect(classA.element.name, equals('A'));
     expect(classA.element.kind, equals('CLASS'));
-    expect(classA.element.range, equals(Range(Position(1, 6), Position(1, 7))));
-    expect(classA.range, equals(Range(Position(0, 0), Position(10, 1))));
-    expect(classA.codeRange, equals(Range(Position(1, 0), Position(10, 1))));
+    expect(
+        classA.element.range,
+        equals(Range(
+            start: Position(line: 1, character: 6),
+            end: Position(line: 1, character: 7))));
+    expect(
+        classA.range,
+        equals(Range(
+            start: Position(line: 0, character: 0),
+            end: Position(line: 10, character: 1))));
+    expect(
+        classA.codeRange,
+        equals(Range(
+            start: Position(line: 1, character: 0),
+            end: Position(line: 10, character: 1))));
     expect(classA.children, hasLength(2));
 
     // b()
@@ -95,9 +111,20 @@
     expect(methodB.element.name, equals('b'));
     expect(methodB.element.kind, equals('METHOD'));
     expect(
-        methodB.element.range, equals(Range(Position(3, 2), Position(3, 3))));
-    expect(methodB.range, equals(Range(Position(2, 2), Position(6, 3))));
-    expect(methodB.codeRange, equals(Range(Position(3, 2), Position(6, 3))));
+        methodB.element.range,
+        equals(Range(
+            start: Position(line: 3, character: 2),
+            end: Position(line: 3, character: 3))));
+    expect(
+        methodB.range,
+        equals(Range(
+            start: Position(line: 2, character: 2),
+            end: Position(line: 6, character: 3))));
+    expect(
+        methodB.codeRange,
+        equals(Range(
+            start: Position(line: 3, character: 2),
+            end: Position(line: 6, character: 3))));
     expect(methodB.children, hasLength(1));
 
     // c()
@@ -105,12 +132,23 @@
     expect(methodC.element.name, equals('c'));
     expect(methodC.element.kind, equals('FUNCTION'));
     expect(
-        methodC.element.range, equals(Range(Position(5, 4), Position(5, 5))));
+        methodC.element.range,
+        equals(Range(
+            start: Position(line: 5, character: 4),
+            end: Position(line: 5, character: 5))));
     // TODO(dantup): This one seems to be excluding its dartdoc?
     // should be line 4 for the starting range.
     // https://github.com/dart-lang/sdk/issues/39746
-    expect(methodC.range, equals(Range(Position(5, 4), Position(5, 10))));
-    expect(methodC.codeRange, equals(Range(Position(5, 4), Position(5, 10))));
+    expect(
+        methodC.range,
+        equals(Range(
+            start: Position(line: 5, character: 4),
+            end: Position(line: 5, character: 10))));
+    expect(
+        methodC.codeRange,
+        equals(Range(
+            start: Position(line: 5, character: 4),
+            end: Position(line: 5, character: 10))));
     expect(methodC.children, isNull);
 
     // num get d
@@ -118,9 +156,20 @@
     expect(fieldD.element.name, equals('d'));
     expect(fieldD.element.kind, equals('GETTER'));
     expect(
-        fieldD.element.range, equals(Range(Position(9, 10), Position(9, 11))));
-    expect(fieldD.range, equals(Range(Position(8, 2), Position(9, 17))));
-    expect(fieldD.codeRange, equals(Range(Position(9, 2), Position(9, 17))));
+        fieldD.element.range,
+        equals(Range(
+            start: Position(line: 9, character: 10),
+            end: Position(line: 9, character: 11))));
+    expect(
+        fieldD.range,
+        equals(Range(
+            start: Position(line: 8, character: 2),
+            end: Position(line: 9, character: 17))));
+    expect(
+        fieldD.codeRange,
+        equals(Range(
+            start: Position(line: 9, character: 2),
+            end: Position(line: 9, character: 17))));
     expect(fieldD.children, isNull);
   }
 }
diff --git a/pkg/analysis_server/test/lsp/references_test.dart b/pkg/analysis_server/test/lsp/references_test.dart
index a780df9..350de59 100644
--- a/pkg/analysis_server/test/lsp/references_test.dart
+++ b/pkg/analysis_server/test/lsp/references_test.dart
@@ -54,12 +54,14 @@
     expect(res, hasLength(2));
     expect(
         res,
-        contains(
-            Location(mainFileUri.toString(), rangeFromMarkers(mainContents))));
+        contains(Location(
+            uri: mainFileUri.toString(),
+            range: rangeFromMarkers(mainContents))));
     expect(
         res,
-        contains(Location(referencedFileUri.toString(),
-            rangeFromMarkers(referencedContents))));
+        contains(Location(
+            uri: referencedFileUri.toString(),
+            range: rangeFromMarkers(referencedContents))));
   }
 
   Future<void> test_acrossFiles_withoutDeclaration() async {
@@ -122,7 +124,8 @@
     expect(
       res,
       contains(
-        Location(mainFileUri.toString(), rangeFromMarkers(contents)),
+        Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(contents)),
       ),
     );
   }
@@ -142,7 +145,8 @@
     expect(
       res,
       contains(
-        Location(mainFileUri.toString(), rangeFromMarkers(contents)),
+        Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(contents)),
       ),
     );
   }
diff --git a/pkg/analysis_server/test/lsp/rename_test.dart b/pkg/analysis_server/test/lsp/rename_test.dart
index 5c1127b..0896bf2 100644
--- a/pkg/analysis_server/test/lsp/rename_test.dart
+++ b/pkg/analysis_server/test/lsp/rename_test.dart
@@ -80,8 +80,8 @@
     final request = makeRequest(
       Method.textDocument_prepareRename,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(mainFileUri.toString()),
-        positionFromMarker(content),
+        textDocument: TextDocumentIdentifier(uri: mainFileUri.toString()),
+        position: positionFromMarker(content),
       ),
     );
     final response = await channel.sendRequestToServer(request);
@@ -296,9 +296,9 @@
     final request = makeRequest(
       Method.textDocument_rename,
       RenameParams(
-        TextDocumentIdentifier(mainFileUri.toString()),
-        positionFromMarker(content),
-        'Object2',
+        newName: 'Object2',
+        textDocument: TextDocumentIdentifier(uri: mainFileUri.toString()),
+        position: positionFromMarker(content),
       ),
     );
     final response = await channel.sendRequestToServer(request);
diff --git a/pkg/analysis_server/test/lsp/server_abstract.dart b/pkg/analysis_server/test/lsp/server_abstract.dart
index a00a44e..2bf40b9 100644
--- a/pkg/analysis_server/test/lsp/server_abstract.dart
+++ b/pkg/analysis_server/test/lsp/server_abstract.dart
@@ -35,7 +35,9 @@
 /// communication to be printed to stdout.
 const debugPrintCommunication = false;
 
-final beginningOfDocument = Range(Position(0, 0), Position(0, 0));
+final beginningOfDocument = Range(
+    start: Position(line: 0, character: 0),
+    end: Position(line: 0, character: 0));
 
 abstract class AbstractLspAnalysisServerTest
     with
@@ -145,31 +147,9 @@
 }
 
 mixin ClientCapabilitiesHelperMixin {
-  final emptyTextDocumentClientCapabilities = TextDocumentClientCapabilities(
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null,
-      null);
+  final emptyTextDocumentClientCapabilities = TextDocumentClientCapabilities();
 
-  final emptyWorkspaceClientCapabilities = WorkspaceClientCapabilities(
-      null, null, null, null, null, null, null, null);
+  final emptyWorkspaceClientCapabilities = ClientCapabilitiesWorkspace();
 
   TextDocumentClientCapabilities extendTextDocumentCapabilities(
     TextDocumentClientCapabilities source,
@@ -189,8 +169,8 @@
     return TextDocumentClientCapabilities.fromJson(json);
   }
 
-  WorkspaceClientCapabilities extendWorkspaceCapabilities(
-    WorkspaceClientCapabilities source,
+  ClientCapabilitiesWorkspace extendWorkspaceCapabilities(
+    ClientCapabilitiesWorkspace source,
     Map<String, dynamic> workspaceCapabilities,
   ) {
     // TODO(dantup): As above - it seems like this round trip should be
@@ -201,7 +181,7 @@
         json[key] = workspaceCapabilities[key];
       });
     }
-    return WorkspaceClientCapabilities.fromJson(json);
+    return ClientCapabilitiesWorkspace.fromJson(json);
   }
 
   TextDocumentClientCapabilities withAllSupportedDynamicRegistrations(
@@ -228,8 +208,8 @@
     });
   }
 
-  WorkspaceClientCapabilities withApplyEditSupport(
-    WorkspaceClientCapabilities source,
+  ClientCapabilitiesWorkspace withApplyEditSupport(
+    ClientCapabilitiesWorkspace source,
   ) {
     return extendWorkspaceCapabilities(source, {'applyEdit': true});
   }
@@ -247,7 +227,7 @@
     });
   }
 
-  TextDocumentClientCapabilities withCompletionItemDeprecatedSupport(
+  TextDocumentClientCapabilities withCompletionItemDeprecatedFlagSupport(
     TextDocumentClientCapabilities source,
   ) {
     return extendTextDocumentCapabilities(source, {
@@ -280,22 +260,46 @@
     });
   }
 
-  WorkspaceClientCapabilities withConfigurationSupport(
-    WorkspaceClientCapabilities source,
+  TextDocumentClientCapabilities withCompletionItemTagSupport(
+    TextDocumentClientCapabilities source,
+    List<CompletionItemTag> tags,
+  ) {
+    return extendTextDocumentCapabilities(source, {
+      'completion': {
+        'completionItem': {
+          'tagSupport': {'valueSet': tags.map((k) => k.toJson()).toList()}
+        }
+      }
+    });
+  }
+
+  ClientCapabilitiesWorkspace withConfigurationSupport(
+    ClientCapabilitiesWorkspace source,
   ) {
     return extendWorkspaceCapabilities(source, {'configuration': true});
   }
 
-  WorkspaceClientCapabilities withDidChangeConfigurationDynamicRegistration(
-    WorkspaceClientCapabilities source,
+  TextDocumentClientCapabilities withDiagnosticTagSupport(
+    TextDocumentClientCapabilities source,
+    List<DiagnosticTag> tags,
+  ) {
+    return extendTextDocumentCapabilities(source, {
+      'publishDiagnostics': {
+        'tagSupport': {'valueSet': tags.map((k) => k.toJson()).toList()}
+      }
+    });
+  }
+
+  ClientCapabilitiesWorkspace withDidChangeConfigurationDynamicRegistration(
+    ClientCapabilitiesWorkspace source,
   ) {
     return extendWorkspaceCapabilities(source, {
       'didChangeConfiguration': {'dynamicRegistration': true}
     });
   }
 
-  WorkspaceClientCapabilities withDocumentChangesSupport(
-    WorkspaceClientCapabilities source,
+  ClientCapabilitiesWorkspace withDocumentChangesSupport(
+    ClientCapabilitiesWorkspace source,
   ) {
     return extendWorkspaceCapabilities(source, {
       'workspaceEdit': {'documentChanges': true}
@@ -370,8 +374,10 @@
   String projectFolderPath, mainFilePath, pubspecFilePath, analysisOptionsPath;
   Uri projectFolderUri, mainFileUri, pubspecFileUri, analysisOptionsUri;
   final String simplePubspecContent = 'name: my_project';
-  final startOfDocPos = Position(0, 0);
-  final startOfDocRange = Range(Position(0, 0), Position(0, 0));
+  final startOfDocPos = Position(line: 0, character: 0);
+  final startOfDocRange = Range(
+      start: Position(line: 0, character: 0),
+      end: Position(line: 0, character: 0));
 
   /// A stream of [NotificationMessage]s from the server that may be errors.
   Stream<NotificationMessage> get errorNotificationsFromServer {
@@ -514,13 +520,17 @@
   Future changeFile(
     int newVersion,
     Uri uri,
-    List<TextDocumentContentChangeEvent> changes,
+    List<
+            Either2<TextDocumentContentChangeEvent1,
+                TextDocumentContentChangeEvent2>>
+        changes,
   ) async {
     var notification = makeNotification(
       Method.textDocument_didChange,
       DidChangeTextDocumentParams(
-        VersionedTextDocumentIdentifier(newVersion, uri.toString()),
-        changes,
+        textDocument: VersionedTextDocumentIdentifier(
+            version: newVersion, uri: uri.toString()),
+        contentChanges: changes,
       ),
     );
     await sendNotificationToServer(notification);
@@ -530,9 +540,9 @@
     var notification = makeNotification(
       Method.workspace_didChangeWorkspaceFolders,
       DidChangeWorkspaceFoldersParams(
-        WorkspaceFoldersChangeEvent(
-          add?.map(toWorkspaceFolder)?.toList() ?? const [],
-          remove?.map(toWorkspaceFolder)?.toList() ?? const [],
+        event: WorkspaceFoldersChangeEvent(
+          added: add?.map(toWorkspaceFolder)?.toList() ?? const [],
+          removed: remove?.map(toWorkspaceFolder)?.toList() ?? const [],
         ),
       ),
     );
@@ -542,7 +552,8 @@
   Future closeFile(Uri uri) async {
     var notification = makeNotification(
       Method.textDocument_didClose,
-      DidCloseTextDocumentParams(TextDocumentIdentifier(uri.toString())),
+      DidCloseTextDocumentParams(
+          textDocument: TextDocumentIdentifier(uri: uri.toString())),
     );
     await sendNotificationToServer(notification);
   }
@@ -551,8 +562,8 @@
     final request = makeRequest(
       Method.workspace_executeCommand,
       ExecuteCommandParams(
-        command.command,
-        command.arguments,
+        command: command.command,
+        arguments: command.arguments,
       ),
     );
     return expectSuccessfulResponseTo(request);
@@ -646,8 +657,10 @@
     final request = makeRequest(
       Method.textDocument_formatting,
       DocumentFormattingParams(
-        TextDocumentIdentifier(fileUri),
-        FormattingOptions(2, true), // These currently don't do anything
+        textDocument: TextDocumentIdentifier(uri: fileUri),
+        options: FormattingOptions(
+            tabSize: 2,
+            insertSpaces: true), // These currently don't do anything
       ),
     );
     return expectSuccessfulResponseTo(request);
@@ -658,10 +671,12 @@
     final request = makeRequest(
       Method.textDocument_onTypeFormatting,
       DocumentOnTypeFormattingParams(
-        TextDocumentIdentifier(fileUri),
-        pos,
-        character,
-        FormattingOptions(2, true), // These currently don't do anything
+        ch: character,
+        options: FormattingOptions(
+            tabSize: 2,
+            insertSpaces: true), // These currently don't do anything
+        textDocument: TextDocumentIdentifier(uri: fileUri),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo(request);
@@ -675,12 +690,13 @@
     final request = makeRequest(
       Method.textDocument_codeAction,
       CodeActionParams(
-          TextDocumentIdentifier(fileUri),
-          range ?? beginningOfDocument,
-          // TODO(dantup): We may need to revise the tests/implementation when
-          // it's clear how we're supposed to handle diagnostics:
-          // https://github.com/Microsoft/language-server-protocol/issues/583
-          CodeActionContext([], kinds)),
+        textDocument: TextDocumentIdentifier(uri: fileUri),
+        range: range ?? beginningOfDocument,
+        // TODO(dantup): We may need to revise the tests/implementation when
+        // it's clear how we're supposed to handle diagnostics:
+        // https://github.com/Microsoft/language-server-protocol/issues/583
+        context: CodeActionContext(diagnostics: [], only: kinds),
+      ),
     );
     return expectSuccessfulResponseTo(request);
   }
@@ -690,9 +706,9 @@
     final request = makeRequest(
       Method.textDocument_completion,
       CompletionParams(
-        context,
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        context: context,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<List<CompletionItem>>(request);
@@ -702,8 +718,8 @@
     final request = makeRequest(
       Method.textDocument_definition,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<List<Location>>(request);
@@ -721,8 +737,8 @@
     final request = makeRequest(
       Method.textDocument_documentHighlight,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<List<DocumentHighlight>>(request);
@@ -733,7 +749,7 @@
     final request = makeRequest(
       Method.textDocument_documentSymbol,
       DocumentSymbolParams(
-        TextDocumentIdentifier(fileUri),
+        textDocument: TextDocumentIdentifier(uri: fileUri),
       ),
     );
     return expectSuccessfulResponseTo(request);
@@ -742,7 +758,9 @@
   Future<List<FoldingRange>> getFoldingRegions(Uri uri) {
     final request = makeRequest(
       Method.textDocument_foldingRange,
-      FoldingRangeParams(TextDocumentIdentifier(uri.toString())),
+      FoldingRangeParams(
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+      ),
     );
     return expectSuccessfulResponseTo<List<FoldingRange>>(request);
   }
@@ -750,7 +768,9 @@
   Future<Hover> getHover(Uri uri, Position pos) {
     final request = makeRequest(
       Method.textDocument_hover,
-      TextDocumentPositionParams(TextDocumentIdentifier(uri.toString()), pos),
+      TextDocumentPositionParams(
+          textDocument: TextDocumentIdentifier(uri: uri.toString()),
+          position: pos),
     );
     return expectSuccessfulResponseTo<Hover>(request);
   }
@@ -763,8 +783,8 @@
     final request = makeRequest(
       Method.textDocument_implementation,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<List<Location>>(request);
@@ -778,9 +798,9 @@
     final request = makeRequest(
       Method.textDocument_references,
       ReferenceParams(
-        ReferenceContext(includeDeclarations),
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        context: ReferenceContext(includeDeclaration: includeDeclarations),
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<List<Location>>(request);
@@ -790,8 +810,8 @@
     final request = makeRequest(
       Method.textDocument_signatureHelp,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<SignatureHelp>(request);
@@ -804,8 +824,8 @@
     final request = makeRequest(
       CustomMethods.Super,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<Location>(request);
@@ -814,7 +834,7 @@
   Future<List<SymbolInformation>> getWorkspaceSymbols(String query) {
     final request = makeRequest(
       Method.workspace_symbol,
-      WorkspaceSymbolParams(query),
+      WorkspaceSymbolParams(query: query),
     );
     return expectSuccessfulResponseTo(request);
   }
@@ -872,7 +892,8 @@
     Uri rootUri,
     List<Uri> workspaceFolders,
     TextDocumentClientCapabilities textDocumentCapabilities,
-    WorkspaceClientCapabilities workspaceCapabilities,
+    ClientCapabilitiesWorkspace workspaceCapabilities,
+    ClientCapabilitiesWindow windowCapabilities,
     Map<String, Object> initializationOptions,
     bool throwOnFailure = true,
   }) async {
@@ -884,17 +905,16 @@
     final request = makeRequest(
         Method.initialize,
         InitializeParams(
-            null,
-            rootPath,
-            rootUri?.toString(),
-            initializationOptions,
-            ClientCapabilities(
-              workspaceCapabilities,
-              textDocumentCapabilities,
-              null,
-            ),
-            null,
-            workspaceFolders?.map(toWorkspaceFolder)?.toList()));
+          rootPath: rootPath,
+          rootUri: rootUri?.toString(),
+          initializationOptions: initializationOptions,
+          capabilities: ClientCapabilities(
+            workspace: workspaceCapabilities,
+            textDocument: textDocumentCapabilities,
+            window: windowCapabilities,
+          ),
+          workspaceFolders: workspaceFolders?.map(toWorkspaceFolder)?.toList(),
+        ));
     final response = await sendRequestToServer(request);
     expect(response.id, equals(request.id));
 
@@ -912,24 +932,27 @@
   }
 
   NotificationMessage makeNotification(Method method, ToJsonable params) {
-    return NotificationMessage(method, params, jsonRpcVersion);
+    return NotificationMessage(
+        method: method, params: params, jsonrpc: jsonRpcVersion);
   }
 
   RequestMessage makeRenameRequest(
       int version, Uri uri, Position pos, String newName) {
     final docIdentifier = version != null
-        ? VersionedTextDocumentIdentifier(version, uri.toString())
-        : TextDocumentIdentifier(uri.toString());
+        ? VersionedTextDocumentIdentifier(version: version, uri: uri.toString())
+        : TextDocumentIdentifier(uri: uri.toString());
     final request = makeRequest(
       Method.textDocument_rename,
-      RenameParams(docIdentifier, pos, newName),
+      RenameParams(
+          newName: newName, textDocument: docIdentifier, position: pos),
     );
     return request;
   }
 
   RequestMessage makeRequest(Method method, ToJsonable params) {
     final id = Either2<num, String>.t1(_id++);
-    return RequestMessage(id, method, params, jsonRpcVersion);
+    return RequestMessage(
+        id: id, method: method, params: params, jsonrpc: jsonRpcVersion);
   }
 
   /// Watches for `client/registerCapability` requests and updates
@@ -968,7 +991,11 @@
     var notification = makeNotification(
       Method.textDocument_didOpen,
       DidOpenTextDocumentParams(
-          TextDocumentItem(uri.toString(), dartLanguageId, version, content)),
+          textDocument: TextDocumentItem(
+              uri: uri.toString(),
+              languageId: dartLanguageId,
+              version: version,
+              text: content)),
     );
     await sendNotificationToServer(notification);
     await pumpEventQueue();
@@ -996,8 +1023,8 @@
     final request = makeRequest(
       Method.textDocument_prepareRename,
       TextDocumentPositionParams(
-        TextDocumentIdentifier(uri.toString()),
-        pos,
+        textDocument: TextDocumentIdentifier(uri: uri.toString()),
+        position: pos,
       ),
     );
     return expectSuccessfulResponseTo<RangeAndPlaceholder>(request);
@@ -1048,9 +1075,9 @@
           throw 'Found unclosed range starting at offset $startMarker';
         }
         yield Range(
-          positionFromOffset(
+          start: positionFromOffset(
               startMarker + offsetForEarlierMarkers, contentsWithoutMarkers),
-          positionFromOffset(
+          end: positionFromOffset(
               endMarker + offsetForEarlierMarkers - rangeMarkerStart.length,
               contentsWithoutMarkers),
         );
@@ -1090,7 +1117,11 @@
     return changeFile(
       newVersion,
       uri,
-      [TextDocumentContentChangeEvent(null, null, content)],
+      [
+        Either2<TextDocumentContentChangeEvent1,
+                TextDocumentContentChangeEvent2>.t2(
+            TextDocumentContentChangeEvent2(text: content))
+      ],
     );
   }
 
@@ -1105,14 +1136,14 @@
   /// Sends [responseParams] to the server as a successful response to
   /// a server-initiated [request].
   void respondTo<T>(RequestMessage request, T responseParams) {
-    sendResponseToServer(
-        ResponseMessage(request.id, responseParams, null, jsonRpcVersion));
+    sendResponseToServer(ResponseMessage(
+        id: request.id, result: responseParams, jsonrpc: jsonRpcVersion));
   }
 
   Future<ResponseMessage> sendDidChangeConfiguration() {
     final request = makeRequest(
       Method.workspace_didChangeConfiguration,
-      DidChangeConfigurationParams(null),
+      DidChangeConfigurationParams(),
     );
     return sendRequestToServer(request);
   }
@@ -1134,7 +1165,10 @@
   }
 
   WorkspaceFolder toWorkspaceFolder(Uri uri) {
-    return WorkspaceFolder(uri.toString(), path.basename(uri.toFilePath()));
+    return WorkspaceFolder(
+      uri: uri.toString(),
+      name: path.basename(uri.toFilePath()),
+    );
   }
 
   /// Tells the server the config has changed, and provides the supplied config
diff --git a/pkg/analysis_server/test/lsp/server_test.dart b/pkg/analysis_server/test/lsp/server_test.dart
index adca252..3e7a202 100644
--- a/pkg/analysis_server/test/lsp/server_test.dart
+++ b/pkg/analysis_server/test/lsp/server_test.dart
@@ -3,6 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analysis_server/lsp_protocol/protocol_generated.dart';
+import 'package:analysis_server/lsp_protocol/protocol_special.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -23,8 +24,13 @@
     // client and server are out of sync and we expect the server to shut down.
     final error = await expectErrorNotification<ShowMessageParams>(() async {
       await changeFile(222, mainFileUri, [
-        TextDocumentContentChangeEvent(
-            Range(Position(99, 99), Position(99, 99)), null, ' '),
+        Either2<TextDocumentContentChangeEvent1,
+                TextDocumentContentChangeEvent2>.t1(
+            TextDocumentContentChangeEvent1(
+                range: Range(
+                    start: Position(line: 99, character: 99),
+                    end: Position(line: 99, character: 99)),
+                text: ' ')),
       ]);
     });
 
diff --git a/pkg/analysis_server/test/lsp/signature_help_test.dart b/pkg/analysis_server/test/lsp/signature_help_test.dart
index c5ef295..64937a9 100644
--- a/pkg/analysis_server/test/lsp/signature_help_test.dart
+++ b/pkg/analysis_server/test/lsp/signature_help_test.dart
@@ -40,8 +40,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
       expectedFormat: null,
     );
@@ -66,8 +66,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
       expectedFormat: MarkupKind.Markdown,
     );
@@ -90,8 +90,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
       expectedFormat: null,
     );
@@ -116,8 +116,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
       expectedFormat: MarkupKind.PlainText,
     );
@@ -146,8 +146,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
       expectedFormat: MarkupKind.Markdown,
     );
@@ -182,9 +182,9 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('bool b = true', null),
-        ParameterInformation('bool a', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'bool b = true'),
+        ParameterInformation(label: 'bool a'),
       ],
     );
   }
@@ -209,9 +209,9 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('bool b = true', null),
-        ParameterInformation('bool a', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'bool b = true'),
+        ParameterInformation(label: 'bool a'),
       ],
     );
   }
@@ -236,8 +236,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('bool b = true', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'bool b = true'),
       ],
     );
   }
@@ -262,8 +262,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('bool b = true', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'bool b = true'),
       ],
     );
   }
@@ -287,8 +287,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
     );
   }
@@ -312,8 +312,8 @@
       expectedLabel,
       expectedDoc,
       [
-        ParameterInformation('String s', null),
-        ParameterInformation('int i', null),
+        ParameterInformation(label: 'String s'),
+        ParameterInformation(label: 'int i'),
       ],
     );
   }
@@ -345,7 +345,7 @@
       // Plain string.
       expect(doc.valueEquals(expectedDoc), isTrue);
     } else {
-      final expected = MarkupContent(expectedFormat, expectedDoc);
+      final expected = MarkupContent(kind: expectedFormat, value: expectedDoc);
       expect(doc.valueEquals(expected), isTrue);
     }
   }
diff --git a/pkg/analysis_server/test/lsp/super_test.dart b/pkg/analysis_server/test/lsp/super_test.dart
index 0b81f12..b9192d9 100644
--- a/pkg/analysis_server/test/lsp/super_test.dart
+++ b/pkg/analysis_server/test/lsp/super_test.dart
@@ -31,8 +31,10 @@
       positionFromMarker(content),
     );
 
-    expect(res,
-        equals(Location(mainFileUri.toString(), rangeFromMarkers(content))));
+    expect(
+        res,
+        equals(Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(content))));
   }
 
   Future<void> test_insideClass() async {
@@ -52,8 +54,10 @@
       positionFromMarker(content),
     );
 
-    expect(res,
-        equals(Location(mainFileUri.toString(), rangeFromMarkers(content))));
+    expect(
+        res,
+        equals(Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(content))));
   }
 
   Future<void> test_insideMethod() async {
@@ -78,8 +82,10 @@
       positionFromMarker(content),
     );
 
-    expect(res,
-        equals(Location(mainFileUri.toString(), rangeFromMarkers(content))));
+    expect(
+        res,
+        equals(Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(content))));
   }
 
   Future<void> test_methodName() async {
@@ -104,8 +110,10 @@
       positionFromMarker(content),
     );
 
-    expect(res,
-        equals(Location(mainFileUri.toString(), rangeFromMarkers(content))));
+    expect(
+        res,
+        equals(Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(content))));
   }
 
   Future<void> test_methodReturnType() async {
@@ -130,7 +138,9 @@
       positionFromMarker(content),
     );
 
-    expect(res,
-        equals(Location(mainFileUri.toString(), rangeFromMarkers(content))));
+    expect(
+        res,
+        equals(Location(
+            uri: mainFileUri.toString(), range: rangeFromMarkers(content))));
   }
 }
diff --git a/pkg/analysis_server/test/lsp/workspace_symbols_test.dart b/pkg/analysis_server/test/lsp/workspace_symbols_test.dart
index 5138109..4c53c44 100644
--- a/pkg/analysis_server/test/lsp/workspace_symbols_test.dart
+++ b/pkg/analysis_server/test/lsp/workspace_symbols_test.dart
@@ -91,10 +91,10 @@
 
     // Create a request that doesn't supply the query param.
     final request = RequestMessage(
-      Either2<num, String>.t1(1),
-      Method.workspace_symbol,
-      <String, dynamic>{},
-      jsonRpcVersion,
+      id: Either2<num, String>.t1(1),
+      method: Method.workspace_symbol,
+      params: <String, dynamic>{},
+      jsonrpc: jsonRpcVersion,
     );
 
     final response = await sendRequestToServer(request);
diff --git a/pkg/analysis_server/test/src/cider/completion_test.dart b/pkg/analysis_server/test/src/cider/completion_test.dart
index ddebeae..4e0e47b 100644
--- a/pkg/analysis_server/test/src/cider/completion_test.dart
+++ b/pkg/analysis_server/test/src/cider/completion_test.dart
@@ -69,25 +69,6 @@
     ]);
   }
 
-  Future<void> test_compute_performance_timers() async {
-    await _compute(r'''
-main() {
-  ^
-}
-''');
-
-    void assertTimerNotEmpty(Duration duration) {
-      expect(duration, isNotNull);
-      expect(duration, isNot(Duration.zero));
-    }
-
-    var performance = _completionResult.performance;
-    assertTimerNotEmpty(performance.file);
-    assertTimerNotEmpty(performance.imports);
-    assertTimerNotEmpty(performance.resolution);
-    assertTimerNotEmpty(performance.suggestions);
-  }
-
   Future<void> test_compute_prefixStart_hasPrefix() async {
     await _compute('''
 class A {
@@ -366,6 +347,20 @@
     _assertHasGetter(text: 'isEven');
   }
 
+  Future<void> test_partialResolution_hasPart() async {
+    newFile('/workspace/dart/test/lib/a.dart', content: r'''
+class A {}
+''');
+
+    await _compute(r'''
+part 'a.dart';
+^
+''');
+
+    _assertHasClass(text: 'int');
+    _assertHasClass(text: 'A');
+  }
+
   Future<void> test_warmUp_cachesImportedLibraries() async {
     var aPath = convertPath('/workspace/dart/test/lib/a.dart');
     newFile(aPath, content: r'''
diff --git a/pkg/analysis_server/test/src/domains/completion/available_suggestion_sets_test.dart b/pkg/analysis_server/test/src/domains/completion/available_suggestion_sets_test.dart
index 9230187..e66c221 100644
--- a/pkg/analysis_server/test/src/domains/completion/available_suggestion_sets_test.dart
+++ b/pkg/analysis_server/test/src/domains/completion/available_suggestion_sets_test.dart
@@ -75,6 +75,7 @@
     "flags": 0
   },
   "relevanceTags": [
+    "ElementKind.CLASS",
     "package:test/a.dart::A",
     "A"
   ]
@@ -101,6 +102,7 @@
   "parameterNames": [],
   "parameterTypes": [],
   "relevanceTags": [
+    "ElementKind.CONSTRUCTOR",
     "package:test/a.dart::A",
     "a"
   ],
@@ -138,6 +140,7 @@
     "flags": 0
   },
   "relevanceTags": [
+    "ElementKind.ENUM",
     "package:test/a.dart::MyEnum",
     "MyEnum"
   ]
@@ -160,6 +163,8 @@
     "flags": 0
   },
   "relevanceTags": [
+    "ElementKind.ENUM_CONSTANT",
+    "ElementKind.ENUM_CONSTANT+const",
     "package:test/a.dart::MyEnum",
     "aaa"
   ]
@@ -182,6 +187,8 @@
     "flags": 0
   },
   "relevanceTags": [
+    "ElementKind.ENUM_CONSTANT",
+    "ElementKind.ENUM_CONSTANT+const",
     "package:test/a.dart::MyEnum",
     "bbb"
   ]
@@ -219,6 +226,7 @@
     "returnType": ""
   },
   "relevanceTags": [
+    "ElementKind.TOP_LEVEL_VARIABLE",
     "dart:core::bool",
     "boolV"
   ]
@@ -242,6 +250,7 @@
     "returnType": ""
   },
   "relevanceTags": [
+    "ElementKind.TOP_LEVEL_VARIABLE",
     "dart:core::int",
     "intV"
   ]
@@ -265,6 +274,7 @@
     "returnType": ""
   },
   "relevanceTags": [
+    "ElementKind.TOP_LEVEL_VARIABLE",
     "dart:core::double",
     "doubleV"
   ]
@@ -288,6 +298,7 @@
     "returnType": ""
   },
   "relevanceTags": [
+    "ElementKind.TOP_LEVEL_VARIABLE",
     "dart:core::String",
     "stringV"
   ]
diff --git a/pkg/analysis_server/test/src/domains/completion/get_suggestions_available_test.dart b/pkg/analysis_server/test/src/domains/completion/get_suggestions_available_test.dart
index e065bb7..805b561 100644
--- a/pkg/analysis_server/test/src/domains/completion/get_suggestions_available_test.dart
+++ b/pkg/analysis_server/test/src/domains/completion/get_suggestions_available_test.dart
@@ -204,6 +204,36 @@
     );
   }
 
+  Future<void> test_relevanceTags_constructorBeforeClass() async {
+    server.options.useNewRelevance = true;
+    addTestFile(r'''
+void foo(List<int> a) {}
+
+main() {
+  foo(); // ref
+}
+''');
+
+    var results = await _getSuggestions(
+      testFile,
+      testCode.indexOf('); // ref'),
+    );
+
+    var includedTags = results.includedSuggestionRelevanceTags;
+    int findBoost(String tag) {
+      for (var includedTag in includedTags) {
+        if (includedTag.tag == tag) {
+          return includedTag.relevanceBoost;
+        }
+      }
+      fail('Missing relevance boost for tag $tag');
+    }
+
+    var classBoost = findBoost('ElementKind.CLASS');
+    var constructorBoost = findBoost('ElementKind.CONSTRUCTOR');
+    expect(constructorBoost, greaterThan(classBoost));
+  }
+
   Future<void> test_relevanceTags_enum() async {
     newFile('/home/test/lib/a.dart', content: r'''
 enum MyEnum {
diff --git a/pkg/analysis_server/test/src/services/correction/assist/add_diagnostic_property_reference_test.dart b/pkg/analysis_server/test/src/services/correction/assist/add_diagnostic_property_reference_test.dart
index b763bed..f4bad61 100644
--- a/pkg/analysis_server/test/src/services/correction/assist/add_diagnostic_property_reference_test.dart
+++ b/pkg/analysis_server/test/src/services/correction/assist/add_diagnostic_property_reference_test.dart
@@ -42,4 +42,14 @@
 }
 ''');
   }
+
+  Future<void> test_notAvailable_mixin() async {
+    verifyNoTestUnitErrors = false;
+    await resolveTestUnit('''
+mixin MyMixin {
+  String get foo/*caret*/() {}
+}
+''');
+    await assertNoAssist();
+  }
 }
diff --git a/pkg/analysis_server/test/src/services/correction/assist/assign_to_local_variable_test.dart b/pkg/analysis_server/test/src/services/correction/assist/assign_to_local_variable_test.dart
index b117de0..936b9fa 100644
--- a/pkg/analysis_server/test/src/services/correction/assist/assign_to_local_variable_test.dart
+++ b/pkg/analysis_server/test/src/services/correction/assist/assign_to_local_variable_test.dart
@@ -79,6 +79,17 @@
     await assertNoAssistAt('345');
   }
 
+  Future<void> test_recovery_splitExpression() async {
+    verifyNoTestUnitErrors = false;
+    await resolveTestUnit('''
+Future<void> _extractDataForSite() async {
+  final Map<String, Object> data = {};
+  final data['table'][] //marker
+}
+''');
+    assertNoAssistAt('] //marker');
+  }
+
   Future<void> test_throw() async {
     await resolveTestUnit('''
 main() {
diff --git a/pkg/analysis_server/test/src/services/correction/assist/flutter_wrap_padding_test.dart b/pkg/analysis_server/test/src/services/correction/assist/flutter_wrap_padding_test.dart
index 27cf35b..c457ccf 100644
--- a/pkg/analysis_server/test/src/services/correction/assist/flutter_wrap_padding_test.dart
+++ b/pkg/analysis_server/test/src/services/correction/assist/flutter_wrap_padding_test.dart
@@ -57,4 +57,31 @@
 ''');
     await assertNoAssist();
   }
+
+  Future<void> test_inConstantContext() async {
+    addFlutterPackage();
+    await resolveTestUnit('''
+import 'package:flutter/widgets.dart';
+class FakeFlutter {
+  Widget build() {
+    return const Center(
+      child: /*caret*/Text('x'),
+    );
+  }
+}
+''');
+    await assertHasAssist('''
+import 'package:flutter/widgets.dart';
+class FakeFlutter {
+  Widget build() {
+    return const Center(
+      child: Padding(
+        padding: EdgeInsets.all(8.0),
+        child: Text('x'),
+      ),
+    );
+  }
+}
+''');
+  }
 }
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/bulk_fix_processor.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/bulk_fix_processor.dart
new file mode 100644
index 0000000..6ef1c95
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/bulk_fix_processor.dart
@@ -0,0 +1,77 @@
+// 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 'package:analysis_server/src/services/correction/bulk_fix_processor.dart';
+import 'package:analysis_server/src/services/correction/change_workspace.dart';
+import 'package:analyzer/src/dart/analysis/byte_store.dart';
+import 'package:analyzer/src/services/available_declarations.dart';
+import 'package:analyzer_plugin/protocol/protocol_common.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_workspace.dart';
+import 'package:test/test.dart';
+
+import '../../../../../abstract_single_unit.dart';
+
+/// A base class defining support for writing bulk fix processor tests.
+abstract class BulkFixProcessorTest extends AbstractSingleUnitTest {
+  /// The source change associated with the fix that was found, or `null` if
+  /// neither [assertHasFix] nor [assertHasFixAllFix] has been invoked.
+  SourceChange change;
+
+  /// The result of applying the [change] to the file content, or `null` if
+  /// neither [assertHasFix] nor [assertHasFixAllFix] has been invoked.
+  String resultCode;
+
+  /// Return a list of the experiments that are to be enabled for tests in this
+  /// class, or `null` if there are no experiments that should be enabled.
+  List<String> get experiments => null;
+
+  /// Return the lint code being tested.
+  String get lintCode => null;
+
+  /// The workspace in which fixes contributor operates.
+  ChangeWorkspace get workspace {
+    return DartChangeWorkspace([session]);
+  }
+
+  Future<void> assertHasFix(String expected) async {
+    change = await _computeFixes();
+
+    // apply to "file"
+    var fileEdits = change.edits;
+    expect(fileEdits, hasLength(1));
+
+    var fileContent = testCode;
+    resultCode = SourceEdit.applySequence(fileContent, change.edits[0].edits);
+    expect(resultCode, expected);
+  }
+
+  @override
+  void setUp() {
+    super.setUp();
+    verifyNoTestUnitErrors = false;
+    _createAnalysisOptionsFile();
+  }
+
+  /// Computes fixes for the given [error] in [testUnit].
+  Future<SourceChange> _computeFixes() async {
+    var tracker = DeclarationsTracker(MemoryByteStore(), resourceProvider);
+    tracker.addContext(driver.analysisContext);
+    var changeBuilder =
+        await BulkFixProcessor(workspace).fixErrorsInLibraries([testFile]);
+    return changeBuilder.sourceChange;
+  }
+
+  /// Create the analysis options file needed in order to correctly analyze the
+  /// test file.
+  void _createAnalysisOptionsFile() {
+    var code = lintCode;
+    if (code == null) {
+      createAnalysisOptionsFile(experiments: experiments);
+    } else {
+      createAnalysisOptionsFile(experiments: experiments, lints: [code]);
+    }
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/convert_documentation_into_line_test.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/convert_documentation_into_line_test.dart
new file mode 100644
index 0000000..5a5d169
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/convert_documentation_into_line_test.dart
@@ -0,0 +1,57 @@
+// 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 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'bulk_fix_processor.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConvertDocumentationIntoLineTest);
+  });
+}
+
+@reflectiveTest
+class ConvertDocumentationIntoLineTest extends BulkFixProcessorTest {
+  @override
+  String get lintCode => LintNames.slash_for_doc_comments;
+
+  Future<void> test_singleFile() async {
+    await resolveTestUnit('''
+/**
+ * C
+ */
+class C {
+  /**
+   * f
+   */
+  int f;
+
+  /**
+   * m
+   */
+  m() {}
+}
+
+/**
+ * f
+ */
+void f() {}
+''');
+    await assertHasFix('''
+/// C
+class C {
+  /// f
+  int f;
+
+  /// m
+  m() {}
+}
+
+/// f
+void f() {}
+''');
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_const_test.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_const_test.dart
new file mode 100644
index 0000000..5b6811d
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_const_test.dart
@@ -0,0 +1,37 @@
+// 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 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'bulk_fix_processor.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(RemoveUnnecessaryConstTest);
+  });
+}
+
+@reflectiveTest
+class RemoveUnnecessaryConstTest extends BulkFixProcessorTest {
+  @override
+  String get lintCode => LintNames.unnecessary_const;
+
+  Future<void> test_singleFile() async {
+    await resolveTestUnit('''
+class C { const C(); }
+class D { const D(C c); }
+const c = const C();
+const list = const [];
+var d = const D(const C());
+''');
+    await assertHasFix('''
+class C { const C(); }
+class D { const D(C c); }
+const c = C();
+const list = [];
+var d = const D(C());
+''');
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_new_test.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_new_test.dart
new file mode 100644
index 0000000..6f3b5e2
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/remove_unnecessary_new_test.dart
@@ -0,0 +1,45 @@
+// 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 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'bulk_fix_processor.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(RemoveUnnecessaryNewTest);
+  });
+}
+
+@reflectiveTest
+class RemoveUnnecessaryNewTest extends BulkFixProcessorTest {
+  @override
+  String get lintCode => LintNames.unnecessary_new;
+
+  Future<void> test_singleFile() async {
+    await resolveTestUnit('''
+C f() => new C();
+
+class C {
+  C();
+
+  void m() {
+    new C();
+  }
+}
+''');
+    await assertHasFix('''
+C f() => C();
+
+class C {
+  C();
+
+  void m() {
+    C();
+  }
+}
+''');
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/replace_colon_with_equals_test.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/replace_colon_with_equals_test.dart
new file mode 100644
index 0000000..c90d5f7
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/replace_colon_with_equals_test.dart
@@ -0,0 +1,37 @@
+// 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 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'bulk_fix_processor.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ReplaceColonWithEqualsTest);
+  });
+}
+
+@reflectiveTest
+class ReplaceColonWithEqualsTest extends BulkFixProcessorTest {
+  @override
+  String get lintCode => LintNames.prefer_equal_for_default_values;
+
+  Future<void> test_singleFile() async {
+    await resolveTestUnit('''
+void f({int a: 1}) => null;
+
+class C {
+  void m({int a: 1, int b: 2}) => null;
+}
+''');
+    await assertHasFix('''
+void f({int a = 1}) => null;
+
+class C {
+  void m({int a = 1, int b = 2}) => null;
+}
+''');
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/bulk/test_all.dart b/pkg/analysis_server/test/src/services/correction/fix/bulk/test_all.dart
new file mode 100644
index 0000000..b344a3a
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/bulk/test_all.dart
@@ -0,0 +1,20 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'convert_documentation_into_line_test.dart'
+    as convert_documentation_into_line;
+import 'remove_unnecessary_const_test.dart' as remove_unnecessary_const;
+import 'remove_unnecessary_new_test.dart' as remove_unnecessary_new;
+import 'replace_colon_with_equals_test.dart' as replace_colon_with_equals;
+
+void main() {
+  defineReflectiveSuite(() {
+    convert_documentation_into_line.main();
+    remove_unnecessary_const.main();
+    remove_unnecessary_new.main();
+    replace_colon_with_equals.main();
+  }, name: 'bulk');
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/create_function_test.dart b/pkg/analysis_server/test/src/services/correction/fix/create_function_test.dart
index e7bb640..ca334c7 100644
--- a/pkg/analysis_server/test/src/services/correction/fix/create_function_test.dart
+++ b/pkg/analysis_server/test/src/services/correction/fix/create_function_test.dart
@@ -388,6 +388,30 @@
 ''');
   }
 
+  Future<void> test_parameterName_fromIndexExpression() async {
+    await resolveTestUnit('''
+class A {
+  int operator[](int _) => 0;
+
+  void foo() {
+    bar(this[0]);
+  }
+}
+''');
+    await assertHasFix('''
+class A {
+  int operator[](int _) => 0;
+
+  void foo() {
+    bar(this[0]);
+  }
+}
+
+void bar(int i) {
+}
+''');
+  }
+
   Future<void> test_returnType_bool_and_left() async {
     await assert_returnType_bool('test() && b;');
   }
diff --git a/pkg/analysis_server/test/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change_test.dart b/pkg/analysis_server/test/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change_test.dart
new file mode 100644
index 0000000..7b5db56
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change_test.dart
@@ -0,0 +1,362 @@
+// 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 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/convert_argument_to_type_argument_change.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/element_descriptor.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/parameter_reference.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/rename_change.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform.dart';
+import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'data_driven_test_support.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(
+        ConvertArgumentToTypeArgumentChange_DeprecatedMemberUseTest);
+  });
+}
+
+@reflectiveTest
+class ConvertArgumentToTypeArgumentChange_DeprecatedMemberUseTest
+    extends DataDrivenFixProcessorTest {
+  @override
+  FixKind get kind => DartFixKind.DATA_DRIVEN;
+
+  Future<void> test_method_named_first_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1({Type t, int x}) {}
+  int m2<T>({int x}) {}
+}
+''');
+    setPackageData(_convertNamed(['C', 'm1'], 'm2', 't', 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(t: int, x: 0);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(x: 0);
+}
+''');
+  }
+
+  Future<void> test_method_named_last_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1({int x, int y, Type t}) {}
+  int m2<T>({int x, int y}) {}
+}
+''');
+    setPackageData(_convertNamed(['C', 'm1'], 'm2', 't', 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(x: 0, y: 1, t: int);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(x: 0, y: 1);
+}
+''');
+  }
+
+  Future<void> test_method_named_middle_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1({int x, Type t, int y}) {}
+  int m2<T>({int x, int y}) {}
+}
+''');
+    setPackageData(_convertNamed(['C', 'm1'], 'm2', 't', 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(x: 0, t: int, y: 1);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(x: 0, y: 1);
+}
+''');
+  }
+
+  Future<void> test_method_named_mixed_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1(int x, {Type t, int y}) {}
+  int m2<T>(int x, {int y}) {}
+}
+''');
+    setPackageData(_convertNamed(['C', 'm1'], 'm2', 't', 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(0, t: int, y: 1);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(0, y: 1);
+}
+''');
+  }
+
+  Future<void> test_method_positional_first_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1(Type t, int x) {}
+  int m2<T>(int x) {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 0, 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(int, 0);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(0);
+}
+''');
+  }
+
+  Future<void> test_method_positional_last_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1(int x, int y, Type t) {}
+  int m2<T>(int x, int y) {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 2, 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(0, 1, int);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(0, 1);
+}
+''');
+  }
+
+  Future<void> test_method_positional_middle_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1(int x, Type t, int y) {}
+  int m2<T>(int x, int y) {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 1, 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(0, int, 1);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>(0, 1);
+}
+''');
+  }
+
+  Future<void> test_method_positional_only_first() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1<T>(Type t) {}
+  int m2<S, T>() {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 0, 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1<int>(String);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<String, int>();
+}
+''');
+  }
+
+  Future<void> test_method_positional_only_last() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1<S, T>(Type t) {}
+  int m2<S, T, U>() {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 0, 2));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1<int, double>(String);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int, double, String>();
+}
+''');
+  }
+
+  Future<void> test_method_positional_only_middle() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1<S, U>(Type t) {}
+  int m2<S, T, U>() {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 0, 1));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1<int, double>(String);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int, String, double>();
+}
+''');
+  }
+
+  Future<void> test_method_positional_only_only() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int m1(Type t) {}
+  int m2<T>() {}
+}
+''');
+    setPackageData(_convertPositional(['C', 'm1'], 'm2', 0, 0));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.m1(int);
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.m2<int>();
+}
+''');
+  }
+
+  Transform _convertNamed(List<String> components, String newName,
+          String parameterName, int typeArgumentIndex) =>
+      Transform(
+          title: 'title',
+          element: ElementDescriptor(
+              libraryUris: [importUri], components: components),
+          changes: [
+            RenameChange(newName: newName),
+            ConvertArgumentToTypeArgumentChange(
+                parameterReference: NamedParameterReference(parameterName),
+                typeArgumentIndex: typeArgumentIndex),
+          ]);
+
+  Transform _convertPositional(List<String> components, String newName,
+          int argumentIndex, int typeArgumentIndex) =>
+      Transform(
+          title: 'title',
+          element: ElementDescriptor(
+              libraryUris: [importUri], components: components),
+          changes: [
+            RenameChange(newName: newName),
+            ConvertArgumentToTypeArgumentChange(
+                parameterReference: PositionalParameterReference(argumentIndex),
+                typeArgumentIndex: typeArgumentIndex),
+          ]);
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/data_driven/data_driven_test_support.dart b/pkg/analysis_server/test/src/services/correction/fix/data_driven/data_driven_test_support.dart
new file mode 100644
index 0000000..5198cf1
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/data_driven/data_driven_test_support.dart
@@ -0,0 +1,29 @@
+// 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 'package:analysis_server/src/services/correction/dart/data_driven.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform_set.dart';
+
+import '../fix_processor.dart';
+
+/// A base class defining support for writing fix processor tests for
+/// data-driven fixes.
+abstract class DataDrivenFixProcessorTest extends FixProcessorTest {
+  /// Return the URI used to import the library created by [setPackageContent].
+  String get importUri => 'package:p/lib.dart';
+
+  /// Set the content of the library that defines the element referenced by the
+  /// data on which this test is based.
+  void setPackageContent(String content) {
+    addPackageFile('p', 'lib.dart', content);
+  }
+
+  /// Set the data on which this test is based.
+  void setPackageData(Transform transform) {
+    DataDriven.transformSetsForTests = [
+      TransformSet()..addTransform(transform)
+    ];
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/data_driven/rename_change_test.dart b/pkg/analysis_server/test/src/services/correction/fix/data_driven/rename_change_test.dart
new file mode 100644
index 0000000..87aec0f
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/data_driven/rename_change_test.dart
@@ -0,0 +1,250 @@
+// 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 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/element_descriptor.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/rename_change.dart';
+import 'package:analysis_server/src/services/correction/fix/data_driven/transform.dart';
+import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'data_driven_test_support.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(RenameChange_DeprecatedMemberUseTest);
+  });
+}
+
+@reflectiveTest
+class RenameChange_DeprecatedMemberUseTest extends DataDrivenFixProcessorTest {
+  @override
+  FixKind get kind => DartFixKind.DATA_DRIVEN;
+
+  Future<void> test_class() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+@deprecated
+class Old {}
+class New {}
+''');
+    setPackageData(_rename(['Old'], 'New'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(Old o) {}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(New o) {}
+''');
+  }
+
+  Future<void> test_constructor_named() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  C.old();
+  C.new();
+}
+''');
+    setPackageData(_rename(['C', 'old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f() {
+  C.old();
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f() {
+  C.new();
+}
+''');
+  }
+
+  Future<void> test_constructor_unnamed() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+@deprecated
+class Old {
+  Old();
+}
+class New {
+  New();
+}
+''');
+    setPackageData(_rename(['Old'], 'New'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f() {
+  Old();
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f() {
+  New();
+}
+''');
+  }
+
+  Future<void> test_field_instance() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int old;
+  int new;
+}
+''');
+    setPackageData(_rename(['C', 'old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.old;
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.new;
+}
+''');
+  }
+
+  Future<void> test_field_static() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  static int old;
+  static int new;
+}
+''');
+    setPackageData(_rename(['C', 'old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f() {
+  C.old;
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f() {
+  C.new;
+}
+''');
+  }
+
+  Future<void> test_method_instance() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  int old() {}
+  int new() {}
+}
+''');
+    setPackageData(_rename(['C', 'old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f(C c) {
+  c.old();
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f(C c) {
+  c.new();
+}
+''');
+  }
+
+  Future<void> test_method_static() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+class C {
+  @deprecated
+  static int old() {}
+  static int new() {}
+}
+''');
+    setPackageData(_rename(['C', 'old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f() {
+  C.old();
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f() {
+  C.new();
+}
+''');
+  }
+
+  Future<void> test_topLevelFunction() async {
+    addMetaPackage();
+    setPackageContent('''
+import 'package:meta/meta.dart';
+
+@deprecated
+int old() {}
+int new() {}
+''');
+    setPackageData(_rename(['old'], 'new'));
+    await resolveTestUnit('''
+import '$importUri';
+
+void f() {
+  old();
+}
+''');
+    await assertHasFix('''
+import '$importUri';
+
+void f() {
+  new();
+}
+''');
+  }
+
+  Transform _rename(List<String> components, String newName) => Transform(
+          title: 'title',
+          element: ElementDescriptor(
+              libraryUris: [importUri], components: components),
+          changes: [
+            RenameChange(newName: newName),
+          ]);
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/data_driven/test_all.dart b/pkg/analysis_server/test/src/services/correction/fix/data_driven/test_all.dart
new file mode 100644
index 0000000..522023a
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/data_driven/test_all.dart
@@ -0,0 +1,16 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'convert_argument_to_type_argument_change_test.dart'
+    as convert_argument_to_type_argument_change;
+import 'rename_change_test.dart' as rename_change;
+
+void main() {
+  defineReflectiveSuite(() {
+    convert_argument_to_type_argument_change.main();
+    rename_change.main();
+  });
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/replace_cascade_with_dot_test.dart b/pkg/analysis_server/test/src/services/correction/fix/replace_cascade_with_dot_test.dart
new file mode 100644
index 0000000..f69a43a
--- /dev/null
+++ b/pkg/analysis_server/test/src/services/correction/fix/replace_cascade_with_dot_test.dart
@@ -0,0 +1,176 @@
+// 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 'package:analysis_server/src/services/correction/fix.dart';
+import 'package:analysis_server/src/services/linter/lint_names.dart';
+import 'package:analyzer/src/dart/analysis/experiments.dart';
+import 'package:analyzer_plugin/utilities/fixes/fixes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'fix_processor.dart';
+
+void main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ReplaceCascadeWithDotTest);
+    defineReflectiveTests(ReplaceCascadeWithDotWithNNBDTest);
+  });
+}
+
+@reflectiveTest
+class ReplaceCascadeWithDotTest extends FixProcessorLintTest {
+  @override
+  FixKind get kind => DartFixKind.REPLACE_CASCADE_WITH_DOT;
+
+  @override
+  String get lintCode =>
+      LintNames.avoid_single_cascade_in_expression_statements;
+
+  Future<void> test_assignment_index_normalCascade() async {
+    await resolveTestUnit('''
+void f(List<int> l) {
+  l..[0] = 0;
+}
+''');
+    await assertHasFix('''
+void f(List<int> l) {
+  l[0] = 0;
+}
+''');
+  }
+
+  Future<void> test_assignment_property_normalCascade() async {
+    await resolveTestUnit('''
+void f(C c) {
+  c..s = 0;
+}
+class C {
+  set s(int i) {}
+}
+''');
+    await assertHasFix('''
+void f(C c) {
+  c.s = 0;
+}
+class C {
+  set s(int i) {}
+}
+''');
+  }
+
+  Future<void> test_getter_normalCascade() async {
+    await resolveTestUnit('''
+void f(String s) {
+  s..length;
+}
+''');
+    await assertHasFix('''
+void f(String s) {
+  s.length;
+}
+''');
+  }
+
+  Future<void> test_index_normalCascade() async {
+    await resolveTestUnit('''
+void f(String s) {
+  s..[0];
+}
+''');
+    await assertHasFix('''
+void f(String s) {
+  s[0];
+}
+''');
+  }
+
+  Future<void> test_method_normalCascade() async {
+    await resolveTestUnit('''
+void f(String s) {
+  s..substring(0, 3);
+}
+''');
+    await assertHasFix('''
+void f(String s) {
+  s.substring(0, 3);
+}
+''');
+  }
+}
+
+@reflectiveTest
+class ReplaceCascadeWithDotWithNNBDTest extends ReplaceCascadeWithDotTest {
+  @override
+  List<String> get experiments => [EnableString.non_nullable];
+
+  Future<void> test_assignment_index_nullAwareCascade() async {
+    await resolveTestUnit('''
+void f(List<int>? l) {
+  l?..[0] = 0;
+}
+''');
+    await assertHasFix('''
+void f(List<int>? l) {
+  l?[0] = 0;
+}
+''');
+  }
+
+  Future<void> test_assignment_property_nullAwareCascade() async {
+    await resolveTestUnit('''
+void f(C? c) {
+  c?..s = 0;
+}
+class C {
+  set s(int i) {}
+}
+''');
+    await assertHasFix('''
+void f(C? c) {
+  c?.s = 0;
+}
+class C {
+  set s(int i) {}
+}
+''');
+  }
+
+  Future<void> test_getter_nullAwareCascade() async {
+    await resolveTestUnit('''
+void f(String? s) {
+  s?..length;
+}
+''');
+    await assertHasFix('''
+void f(String? s) {
+  s?.length;
+}
+''');
+  }
+
+  Future<void> test_index_nullAwareCascade() async {
+    await resolveTestUnit('''
+void f(String? s) {
+  s?..[0];
+}
+''');
+    await assertHasFix('''
+void f(String? s) {
+  s?[0];
+}
+''');
+  }
+
+  Future<void> test_method_nullAwareCascade() async {
+    await resolveTestUnit('''
+void f(String? s) {
+  s?..substring(0, 3);
+}
+''');
+    await assertHasFix('''
+void f(String? s) {
+  s?.substring(0, 3);
+}
+''');
+  }
+}
diff --git a/pkg/analysis_server/test/src/services/correction/fix/test_all.dart b/pkg/analysis_server/test/src/services/correction/fix/test_all.dart
index 6e53e11..32dd350 100644
--- a/pkg/analysis_server/test/src/services/correction/fix/test_all.dart
+++ b/pkg/analysis_server/test/src/services/correction/fix/test_all.dart
@@ -31,6 +31,7 @@
     as add_super_constructor_invocation;
 import 'add_type_annotation_test.dart' as add_type_annotation;
 import 'analysis_options/test_all.dart' as analysis_options;
+import 'bulk/test_all.dart' as bulk;
 import 'change_argument_name_test.dart' as change_argument_name;
 import 'change_to_nearest_precise_value_test.dart'
     as change_to_nearest_precise_value;
@@ -76,6 +77,7 @@
 import 'create_mixin_test.dart' as create_mixin;
 import 'create_no_such_method_test.dart' as create_no_such_method;
 import 'create_setter_test.dart' as create_setter;
+import 'data_driven/test_all.dart' as data_driven;
 import 'extend_class_for_mixin_test.dart' as extend_class_for_mixin;
 import 'fix_test.dart' as fix;
 import 'import_async_test.dart' as import_async;
@@ -131,6 +133,7 @@
 import 'remove_unused_parameter_test.dart' as remove_unused_parameter;
 import 'rename_to_camel_case_test.dart' as rename_to_camel_case;
 import 'replace_boolean_with_bool_test.dart' as replace_boolean_with_bool;
+import 'replace_cascade_with_dot_test.dart' as replace_cascade_with_dot;
 import 'replace_colon_with_equals_test.dart' as replace_colon_with_equals;
 import 'replace_final_with_const_test.dart' as replace_final_with_const;
 import 'replace_new_with_const_test.dart' as replace_new_with_const;
@@ -185,6 +188,7 @@
     add_super_constructor_invocation.main();
     add_type_annotation.main();
     analysis_options.main();
+    bulk.main();
     change_argument_name.main();
     change_to.main();
     change_to_nearest_precise_value.main();
@@ -225,6 +229,7 @@
     create_mixin.main();
     create_no_such_method.main();
     create_setter.main();
+    data_driven.main();
     extend_class_for_mixin.main();
     fix.main();
     import_async.main();
@@ -277,6 +282,7 @@
     remove_unused_parameter.main();
     rename_to_camel_case.main();
     replace_boolean_with_bool.main();
+    replace_cascade_with_dot.main();
     replace_colon_with_equals.main();
     replace_final_with_const.main();
     replace_new_with_const.main();
diff --git a/pkg/analysis_server/test/src/services/flutter/widget_description.dart b/pkg/analysis_server/test/src/services/flutter/widget_description.dart
index 8cda4ec..da82d9c 100644
--- a/pkg/analysis_server/test/src/services/flutter/widget_description.dart
+++ b/pkg/analysis_server/test/src/services/flutter/widget_description.dart
@@ -7,7 +7,6 @@
 import 'package:analysis_server/protocol/protocol_generated.dart' as protocol;
 import 'package:analysis_server/src/protocol_server.dart';
 import 'package:analysis_server/src/services/flutter/widget_descriptions.dart';
-import 'package:analysis_server/src/utilities/flutter.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -15,7 +14,6 @@
 
 @reflectiveTest
 class WidgetDescriptionBase extends AbstractSingleUnitTest {
-  final flutter = Flutter.mobile;
   final descriptions = WidgetDescriptions();
 
   void assertExpectedChange(SetPropertyValueResult result, String expected) {
diff --git a/pkg/analysis_server/test/src/utilities/flutter_test.dart b/pkg/analysis_server/test/src/utilities/flutter_test.dart
index 4e52eff..b7d9636 100644
--- a/pkg/analysis_server/test/src/utilities/flutter_test.dart
+++ b/pkg/analysis_server/test/src/utilities/flutter_test.dart
@@ -17,7 +17,7 @@
 
 @reflectiveTest
 class FlutterTest extends AbstractSingleUnitTest {
-  final flutter = Flutter.mobile;
+  Flutter get _flutter => Flutter.instance;
 
   @override
   void setUp() {
@@ -31,7 +31,7 @@
 var w = const Icon(Icons.book);
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), 'Icon(Icons.book)');
+    expect(_flutter.getWidgetPresentationText(w), 'Icon(Icons.book)');
   }
 
   Future<void> test_getWidgetPresentationText_icon_withoutArguments() async {
@@ -41,7 +41,7 @@
 var w = const Icon();
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), 'Icon');
+    expect(_flutter.getWidgetPresentationText(w), 'Icon');
   }
 
   Future<void> test_getWidgetPresentationText_notWidget() async {
@@ -50,7 +50,7 @@
 var w = new Object();
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), isNull);
+    expect(_flutter.getWidgetPresentationText(w), isNull);
   }
 
   Future<void> test_getWidgetPresentationText_text() async {
@@ -59,7 +59,7 @@
 var w = const Text('foo');
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), "Text('foo')");
+    expect(_flutter.getWidgetPresentationText(w), "Text('foo')");
   }
 
   Future<void> test_getWidgetPresentationText_text_longText() async {
@@ -69,7 +69,7 @@
 ''');
     var w = _getTopVariableCreation('w');
     expect(
-      flutter.getWidgetPresentationText(w),
+      _flutter.getWidgetPresentationText(w),
       "Text('abcabcabcabcab...cabcabcabcabc')",
     );
   }
@@ -81,7 +81,7 @@
 var w = const Text();
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), 'Text');
+    expect(_flutter.getWidgetPresentationText(w), 'Text');
   }
 
   Future<void> test_getWidgetPresentationText_unresolved() async {
@@ -91,7 +91,7 @@
 var w = new Foo();
 ''');
     var w = _getTopVariableCreation('w');
-    expect(flutter.getWidgetPresentationText(w), isNull);
+    expect(_flutter.getWidgetPresentationText(w), isNull);
   }
 
   Future<void> test_identifyWidgetExpression_node_instanceCreation() async {
@@ -120,12 +120,12 @@
       var constructorName = creation.constructorName;
       var typeName = constructorName.type;
       var argumentList = creation.argumentList;
-      expect(flutter.identifyWidgetExpression(creation), creation);
-      expect(flutter.identifyWidgetExpression(constructorName), creation);
-      expect(flutter.identifyWidgetExpression(typeName), creation);
-      expect(flutter.identifyWidgetExpression(argumentList), isNull);
+      expect(_flutter.identifyWidgetExpression(creation), creation);
+      expect(_flutter.identifyWidgetExpression(constructorName), creation);
+      expect(_flutter.identifyWidgetExpression(typeName), creation);
+      expect(_flutter.identifyWidgetExpression(argumentList), isNull);
       expect(
-        flutter.identifyWidgetExpression(argumentList.arguments[0]),
+        _flutter.identifyWidgetExpression(argumentList.arguments[0]),
         isNull,
       );
     }
@@ -137,14 +137,14 @@
       var constructorName = creation.constructorName;
       var typeName = constructorName.type;
       var argumentList = creation.argumentList;
-      expect(flutter.identifyWidgetExpression(creation), creation);
-      expect(flutter.identifyWidgetExpression(constructorName), creation);
-      expect(flutter.identifyWidgetExpression(typeName), creation);
-      expect(flutter.identifyWidgetExpression(typeName.name), creation);
-      expect(flutter.identifyWidgetExpression(constructorName.name), creation);
-      expect(flutter.identifyWidgetExpression(argumentList), isNull);
+      expect(_flutter.identifyWidgetExpression(creation), creation);
+      expect(_flutter.identifyWidgetExpression(constructorName), creation);
+      expect(_flutter.identifyWidgetExpression(typeName), creation);
+      expect(_flutter.identifyWidgetExpression(typeName.name), creation);
+      expect(_flutter.identifyWidgetExpression(constructorName.name), creation);
+      expect(_flutter.identifyWidgetExpression(argumentList), isNull);
       expect(
-        flutter.identifyWidgetExpression(argumentList.arguments[0]),
+        _flutter.identifyWidgetExpression(argumentList.arguments[0]),
         isNull,
       );
     }
@@ -165,19 +165,19 @@
     {
       MethodInvocation invocation = findNodeAtString(
           'createEmptyText();', (node) => node is MethodInvocation);
-      expect(flutter.identifyWidgetExpression(invocation), invocation);
+      expect(_flutter.identifyWidgetExpression(invocation), invocation);
       var argumentList = invocation.argumentList;
-      expect(flutter.identifyWidgetExpression(argumentList), isNull);
+      expect(_flutter.identifyWidgetExpression(argumentList), isNull);
     }
 
     {
       MethodInvocation invocation = findNodeAtString(
           "createText('xyz');", (node) => node is MethodInvocation);
-      expect(flutter.identifyWidgetExpression(invocation), invocation);
+      expect(_flutter.identifyWidgetExpression(invocation), invocation);
       var argumentList = invocation.argumentList;
-      expect(flutter.identifyWidgetExpression(argumentList), isNull);
+      expect(_flutter.identifyWidgetExpression(argumentList), isNull);
       expect(
-        flutter.identifyWidgetExpression(argumentList.arguments[0]),
+        _flutter.identifyWidgetExpression(argumentList.arguments[0]),
         isNull,
       );
     }
@@ -194,7 +194,7 @@
 Text createEmptyText() => new Text('');
 ''');
     Expression childExpression = findNodeAtString('child: ');
-    expect(flutter.identifyWidgetExpression(childExpression), isNull);
+    expect(_flutter.identifyWidgetExpression(childExpression), isNull);
   }
 
   Future<void>
@@ -211,7 +211,7 @@
 }
 ''');
     SimpleIdentifier bar = findNodeAtString('bar; // ref');
-    expect(flutter.identifyWidgetExpression(bar), bar.parent);
+    expect(_flutter.identifyWidgetExpression(bar), bar.parent);
   }
 
   Future<void>
@@ -228,7 +228,7 @@
 }
 ''');
     SimpleIdentifier foo = findNodeAtString('foo.bar');
-    expect(flutter.identifyWidgetExpression(foo), foo.parent);
+    expect(_flutter.identifyWidgetExpression(foo), foo.parent);
   }
 
   Future<void> test_identifyWidgetExpression_node_simpleIdentifier() async {
@@ -240,7 +240,7 @@
 }
 ''');
     Expression expression = findNodeAtString('widget; // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_identifyWidgetExpression_null() async {
@@ -254,15 +254,15 @@
 
 Text createEmptyText() => new Text('');
 ''');
-    expect(flutter.identifyWidgetExpression(null), isNull);
+    expect(_flutter.identifyWidgetExpression(null), isNull);
     {
       Expression expression = findNodeAtString('42;');
-      expect(flutter.identifyWidgetExpression(expression), isNull);
+      expect(_flutter.identifyWidgetExpression(expression), isNull);
     }
 
     {
       Expression expression = findNodeAtString('intVariable;');
-      expect(flutter.identifyWidgetExpression(expression), isNull);
+      expect(_flutter.identifyWidgetExpression(expression), isNull);
     }
   }
 
@@ -278,7 +278,7 @@
 void useWidget(Widget w) {}
 ''');
     Expression expression = findNodeAtString('text); // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void>
@@ -296,19 +296,19 @@
     // Assignment itself.
     {
       var expression = findNode.simple('text =');
-      expect(flutter.identifyWidgetExpression(expression), isNull);
+      expect(_flutter.identifyWidgetExpression(expression), isNull);
     }
 
     // Left hand side.
     {
       var expression = findNode.assignment('text =');
-      expect(flutter.identifyWidgetExpression(expression), isNull);
+      expect(_flutter.identifyWidgetExpression(expression), isNull);
     }
 
     // Right hand side.
     {
       var expression = findNode.instanceCreation('Text(');
-      expect(flutter.identifyWidgetExpression(expression), expression);
+      expect(_flutter.identifyWidgetExpression(expression), expression);
     }
   }
 
@@ -322,10 +322,10 @@
 }
 ''');
     Expression thenWidget = findNodeAtString('w1 :');
-    expect(flutter.identifyWidgetExpression(thenWidget), thenWidget);
+    expect(_flutter.identifyWidgetExpression(thenWidget), thenWidget);
 
     Expression elseWidget = findNodeAtString('w2;');
-    expect(flutter.identifyWidgetExpression(elseWidget), elseWidget);
+    expect(_flutter.identifyWidgetExpression(elseWidget), elseWidget);
   }
 
   Future<void>
@@ -336,7 +336,7 @@
 main(Widget widget) => widget; // ref
 ''');
     Expression expression = findNodeAtString('widget; // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void>
@@ -349,7 +349,7 @@
 }
 ''');
     Expression expression = findNodeAtString('widget; // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_identifyWidgetExpression_parent_forElement() async {
@@ -365,7 +365,7 @@
 void useWidget(Widget w) {}
 ''');
     var expression = findNode.instanceCreation('Container()');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_identifyWidgetExpression_parent_ifElement() async {
@@ -384,10 +384,10 @@
 void useWidget(Widget w) {}
 ''');
     var thenExpression = findNode.instanceCreation("Text('then')");
-    expect(flutter.identifyWidgetExpression(thenExpression), thenExpression);
+    expect(_flutter.identifyWidgetExpression(thenExpression), thenExpression);
 
     var elseExpression = findNode.instanceCreation("Text('else')");
-    expect(flutter.identifyWidgetExpression(elseExpression), elseExpression);
+    expect(_flutter.identifyWidgetExpression(elseExpression), elseExpression);
   }
 
   Future<void> test_identifyWidgetExpression_parent_listLiteral() async {
@@ -399,7 +399,7 @@
 }
 ''');
     Expression expression = findNodeAtString('widget]; // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_identifyWidgetExpression_parent_namedExpression() async {
@@ -414,7 +414,7 @@
 void useWidget({Widget child}) {}
 ''');
     Expression expression = findNodeAtString('text); // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_identifyWidgetExpression_parent_returnStatement() async {
@@ -426,7 +426,7 @@
 }
 ''');
     Expression expression = findNodeAtString('widget; // ref');
-    expect(flutter.identifyWidgetExpression(expression), expression);
+    expect(_flutter.identifyWidgetExpression(expression), expression);
   }
 
   Future<void> test_isWidget() async {
@@ -440,19 +440,19 @@
 class NotWidget extends State {}
 ''');
     var myStatelessWidget = testUnitElement.getType('MyStatelessWidget');
-    expect(flutter.isWidget(myStatelessWidget), isTrue);
+    expect(_flutter.isWidget(myStatelessWidget), isTrue);
 
     var myStatefulWidget = testUnitElement.getType('MyStatefulWidget');
-    expect(flutter.isWidget(myStatefulWidget), isTrue);
+    expect(_flutter.isWidget(myStatefulWidget), isTrue);
 
     var myContainer = testUnitElement.getType('MyContainer');
-    expect(flutter.isWidget(myContainer), isTrue);
+    expect(_flutter.isWidget(myContainer), isTrue);
 
     var notFlutter = testUnitElement.getType('NotFlutter');
-    expect(flutter.isWidget(notFlutter), isFalse);
+    expect(_flutter.isWidget(notFlutter), isFalse);
 
     var notWidget = testUnitElement.getType('NotWidget');
-    expect(flutter.isWidget(notWidget), isFalse);
+    expect(_flutter.isWidget(notWidget), isFalse);
   }
 
   Future<void> test_isWidgetCreation() async {
@@ -462,13 +462,13 @@
 var a = new Object();
 var b = new Text('bbb');
 ''');
-    expect(flutter.isWidgetCreation(null), isFalse);
+    expect(_flutter.isWidgetCreation(null), isFalse);
 
     var a = _getTopVariableCreation('a');
-    expect(flutter.isWidgetCreation(a), isFalse);
+    expect(_flutter.isWidgetCreation(a), isFalse);
 
     var b = _getTopVariableCreation('b');
-    expect(flutter.isWidgetCreation(b), isTrue);
+    expect(_flutter.isWidgetCreation(b), isTrue);
   }
 
   Future<void> test_isWidgetExpression() async {
@@ -493,46 +493,46 @@
 ''');
     {
       Expression expression = findNodeAtString('named(); // use');
-      expect(flutter.isWidgetExpression(expression), isFalse);
+      expect(_flutter.isWidgetExpression(expression), isFalse);
       var creation = expression.parent.parent as InstanceCreationExpression;
-      expect(flutter.isWidgetExpression(creation), isTrue);
+      expect(_flutter.isWidgetExpression(creation), isTrue);
     }
 
     {
       Expression expression = findNodeAtString("new Text('abc')");
-      expect(flutter.isWidgetExpression(expression), isTrue);
+      expect(_flutter.isWidgetExpression(expression), isTrue);
     }
 
     {
       Expression expression = findNodeAtString('text;');
-      expect(flutter.isWidgetExpression(expression), isTrue);
+      expect(_flutter.isWidgetExpression(expression), isTrue);
     }
 
     {
       Expression expression = findNodeAtString(
           'createEmptyText();', (node) => node is MethodInvocation);
-      expect(flutter.isWidgetExpression(expression), isTrue);
+      expect(_flutter.isWidgetExpression(expression), isTrue);
     }
 
     {
       SimpleIdentifier expression = findNodeAtString('Container(');
-      expect(flutter.isWidgetExpression(expression), isFalse);
+      expect(_flutter.isWidgetExpression(expression), isFalse);
     }
 
     {
       NamedExpression expression =
           findNodeAtString('child: ', (n) => n is NamedExpression);
-      expect(flutter.isWidgetExpression(expression), isFalse);
+      expect(_flutter.isWidgetExpression(expression), isFalse);
     }
 
     {
       Expression expression = findNodeAtString('42;');
-      expect(flutter.isWidgetExpression(expression), isFalse);
+      expect(_flutter.isWidgetExpression(expression), isFalse);
     }
 
     {
       Expression expression = findNodeAtString('intVariable;');
-      expect(flutter.isWidgetExpression(expression), isFalse);
+      expect(_flutter.isWidgetExpression(expression), isFalse);
     }
   }
 
diff --git a/pkg/analysis_server/test/stress/utilities/server.dart b/pkg/analysis_server/test/stress/utilities/server.dart
index 186743f..9bbafb3 100644
--- a/pkg/analysis_server/test/stress/utilities/server.dart
+++ b/pkg/analysis_server/test/stress/utilities/server.dart
@@ -796,8 +796,7 @@
   }
 
   /// Send a command to the server. An 'id' will be automatically assigned.
-  RequestData _send(String method, Map<String, dynamic> params,
-      {void Function(Response) onResponse}) {
+  RequestData _send(String method, Map<String, dynamic> params) {
     var id = '${_nextId++}';
     var requestData = RequestData(id, method, params, currentTime);
     _requestDataMap[id] = requestData;
diff --git a/pkg/analysis_server/test/tool/lsp_spec/generated_classes_test.dart b/pkg/analysis_server/test/tool/lsp_spec/generated_classes_test.dart
index 2ef1bdc..a506de9 100644
--- a/pkg/analysis_server/test/tool/lsp_spec/generated_classes_test.dart
+++ b/pkg/analysis_server/test/tool/lsp_spec/generated_classes_test.dart
@@ -9,18 +9,20 @@
 void main() {
   group('generated classes', () {
     test('can be checked for equality', () {
-      final a = TextDocumentIdentifier('/a');
-      final b = TextDocumentIdentifier('/a');
+      final a = TextDocumentIdentifier(uri: '/a');
+      final b = TextDocumentIdentifier(uri: '/a');
 
       expect(a, equals(b));
       expect(a.hashCode, equals(b.hashCode));
     });
 
     test('with list fields can be checked for equality', () {
-      final a = TextDocumentClientCapabilitiesCodeActionKind(
-          [CodeActionKind.QuickFix]);
-      final b = TextDocumentClientCapabilitiesCodeActionKind(
-          [CodeActionKind.QuickFix]);
+      final a = CodeActionClientCapabilitiesCodeActionKind(
+        valueSet: [CodeActionKind.QuickFix],
+      );
+      final b = CodeActionClientCapabilitiesCodeActionKind(
+        valueSet: [CodeActionKind.QuickFix],
+      );
 
       expect(a, equals(b));
       expect(a.hashCode, equals(b.hashCode));
@@ -28,21 +30,33 @@
 
     test('with aliased list fields can be checked for equality', () {
       final a = TextDocumentRegistrationOptions(
-          [DocumentFilter('dart', 'file', null)]);
+          documentSelector: [DocumentFilter(language: 'dart', scheme: 'file')]);
       final b = TextDocumentRegistrationOptions(
-          [DocumentFilter('dart', 'file', null)]);
+          documentSelector: [DocumentFilter(language: 'dart', scheme: 'file')]);
 
       expect(a, equals(b));
       expect(a.hashCode, equals(b.hashCode));
     });
 
     test('with map fields can be checked for equality', () {
-      final a = WorkspaceEdit({
-        'a': [TextEdit(Range(Position(0, 0), Position(0, 0)), 'a')]
-      }, null);
-      final b = WorkspaceEdit({
-        'a': [TextEdit(Range(Position(0, 0), Position(0, 0)), 'a')]
-      }, null);
+      final a = WorkspaceEdit(changes: {
+        'a': [
+          TextEdit(
+              range: Range(
+                  start: Position(line: 0, character: 0),
+                  end: Position(line: 0, character: 0)),
+              newText: 'a')
+        ]
+      });
+      final b = WorkspaceEdit(changes: {
+        'a': [
+          TextEdit(
+              range: Range(
+                  start: Position(line: 0, character: 0),
+                  end: Position(line: 0, character: 0)),
+              newText: 'a')
+        ]
+      });
 
       expect(a, equals(b));
       expect(a.hashCode, equals(b.hashCode));
@@ -57,10 +71,14 @@
     });
 
     test('with union fields can be checked for equality', () {
-      final a =
-          SignatureInformation('a', Either2<String, MarkupContent>.t1('a'), []);
-      final b =
-          SignatureInformation('a', Either2<String, MarkupContent>.t1('a'), []);
+      final a = SignatureInformation(
+          label: 'a',
+          documentation: Either2<String, MarkupContent>.t1('a'),
+          parameters: []);
+      final b = SignatureInformation(
+          label: 'a',
+          documentation: Either2<String, MarkupContent>.t1('a'),
+          parameters: []);
 
       expect(a, equals(b));
       expect(a.hashCode, equals(b.hashCode));
@@ -68,9 +86,10 @@
 
     test('consider subclasses when checking for equality', () {
       final a = TextDocumentRegistrationOptions(
-          [DocumentFilter('dart', 'file', null)]);
+          documentSelector: [DocumentFilter(language: 'dart', scheme: 'file')]);
       final b = TextDocumentSaveRegistrationOptions(
-          true, [DocumentFilter('dart', 'file', null)]);
+          includeText: true,
+          documentSelector: [DocumentFilter(language: 'dart', scheme: 'file')]);
 
       expect(a, isNot(equals(b)));
       expect(b, isNot(equals(a)));
diff --git a/pkg/analysis_server/test/tool/lsp_spec/json_test.dart b/pkg/analysis_server/test/tool/lsp_spec/json_test.dart
index 878f36d..da31eff 100644
--- a/pkg/analysis_server/test/tool/lsp_spec/json_test.dart
+++ b/pkg/analysis_server/test/tool/lsp_spec/json_test.dart
@@ -20,15 +20,17 @@
 
     test('returns correct output for union types', () {
       final message = RequestMessage(
-          Either2<num, String>.t1(1), Method.shutdown, null, 'test');
+          id: Either2<num, String>.t1(1),
+          method: Method.shutdown,
+          jsonrpc: 'test');
       final output = json.encode(message.toJson());
       expect(output, equals('{"id":1,"method":"shutdown","jsonrpc":"test"}'));
     });
 
     test('returns correct output for union types containing interface types',
         () {
-      final params = Either2<String, TextDocumentItem>.t2(
-          TextDocumentItem('!uri', '!language', 1, '!text'));
+      final params = Either2<String, TextDocumentItem>.t2(TextDocumentItem(
+          uri: '!uri', languageId: '!language', version: 1, text: '!text'));
       final output = json.encode(params);
       expect(
           output,
@@ -37,17 +39,19 @@
     });
 
     test('returns correct output for types with lists', () {
-      final start = Position(1, 1);
-      final end = Position(2, 2);
-      final range = Range(start, end);
-      final location = Location('y-uri', range);
+      final start = Position(line: 1, character: 1);
+      final end = Position(line: 2, character: 2);
+      final range = Range(start: start, end: end);
+      final location = Location(uri: 'y-uri', range: range);
       final codeAction = Diagnostic(
-        range,
-        DiagnosticSeverity.Error,
-        'test_err',
-        '/tmp/source.dart',
-        'err!!',
-        [DiagnosticRelatedInformation(location, 'message')],
+        range: range,
+        severity: DiagnosticSeverity.Error,
+        code: 'test_err',
+        source: '/tmp/source.dart',
+        message: 'err!!',
+        relatedInformation: [
+          DiagnosticRelatedInformation(location: location, message: 'message')
+        ],
       );
       final output = json.encode(codeAction.toJson());
       final expected = '''{
@@ -77,7 +81,12 @@
     });
 
     test('serialises enums to their underlying values', () {
-      final foldingRange = FoldingRange(1, 2, 3, 4, FoldingRangeKind.Comment);
+      final foldingRange = FoldingRange(
+          startLine: 1,
+          startCharacter: 2,
+          endLine: 3,
+          endCharacter: 4,
+          kind: FoldingRangeKind.Comment);
       final output = json.encode(foldingRange.toJson());
       final expected = '''{
         "startLine":1,
@@ -93,7 +102,8 @@
     test('ResponseMessage does not include an error with a result', () {
       final id = Either2<num, String>.t1(1);
       final result = 'my result';
-      final resp = ResponseMessage(id, result, null, jsonRpcVersion);
+      final resp =
+          ResponseMessage(id: id, result: result, jsonrpc: jsonRpcVersion);
       final jsonMap = resp.toJson();
       expect(jsonMap, contains('result'));
       expect(jsonMap, isNot(contains('error')));
@@ -236,7 +246,7 @@
 
     test('ResponseMessage can include a null result', () {
       final id = Either2<num, String>.t1(1);
-      final resp = ResponseMessage(id, null, null, jsonRpcVersion);
+      final resp = ResponseMessage(id: id, jsonrpc: jsonRpcVersion);
       final jsonMap = resp.toJson();
       expect(jsonMap, contains('result'));
       expect(jsonMap, isNot(contains('error')));
@@ -244,8 +254,10 @@
 
     test('ResponseMessage does not include a result for an error', () {
       final id = Either2<num, String>.t1(1);
-      final error = ResponseError<String>(ErrorCodes.ParseError, 'Error', null);
-      final resp = ResponseMessage(id, null, error, jsonRpcVersion);
+      final error =
+          ResponseError(code: ErrorCodes.ParseError, message: 'Error');
+      final resp =
+          ResponseMessage(id: id, error: error, jsonrpc: jsonRpcVersion);
       final jsonMap = resp.toJson();
       expect(jsonMap, contains('error'));
       expect(jsonMap, isNot(contains('result')));
@@ -254,8 +266,10 @@
     test('ResponseMessage throws if both result and error are non-null', () {
       final id = Either2<num, String>.t1(1);
       final result = 'my result';
-      final error = ResponseError<String>(ErrorCodes.ParseError, 'Error', null);
-      final resp = ResponseMessage(id, result, error, jsonRpcVersion);
+      final error =
+          ResponseError(code: ErrorCodes.ParseError, message: 'Error');
+      final resp = ResponseMessage(
+          id: id, result: result, error: error, jsonrpc: jsonRpcVersion);
       expect(resp.toJson, throwsA(TypeMatcher<String>()));
     });
   });
@@ -295,8 +309,9 @@
       // Create some JSON that includes a VersionedTextDocumentIdenfitier but
       // where the class definition only references a TextDocumentIdemntifier.
       final input = jsonEncode(TextDocumentPositionParams(
-        VersionedTextDocumentIdentifier(111, 'file:///foo/bar.dart'),
-        Position(1, 1),
+        textDocument: VersionedTextDocumentIdentifier(
+            version: 111, uri: 'file:///foo/bar.dart'),
+        position: Position(line: 1, character: 1),
       ).toJson());
       final params = TextDocumentPositionParams.fromJson(jsonDecode(input));
       expect(params.textDocument,
@@ -315,11 +330,18 @@
   });
 
   test('objects with lists can round-trip through to json and back', () {
-    final obj = InitializeParams(1, '!root', null, null,
-        ClientCapabilities(null, null, null), '!trace', [
-      WorkspaceFolder('!uri1', '!name1'),
-      WorkspaceFolder('!uri2', '!name2'),
-    ]);
+    final obj = InitializeParams(
+      processId: 1,
+      clientInfo:
+          InitializeParamsClientInfo(name: 'server name', version: '1.2.3'),
+      rootPath: '!root',
+      capabilities: ClientCapabilities(),
+      trace: '!trace',
+      workspaceFolders: [
+        WorkspaceFolder(uri: '!uri1', name: '!name1'),
+        WorkspaceFolder(uri: '!uri2', name: '!name2'),
+      ],
+    );
     final json = jsonEncode(obj);
     final restoredObj = InitializeParams.fromJson(jsonDecode(json));
 
@@ -334,7 +356,12 @@
   });
 
   test('objects with enums can round-trip through to json and back', () {
-    final obj = FoldingRange(1, 2, 3, 4, FoldingRangeKind.Comment);
+    final obj = FoldingRange(
+        startLine: 1,
+        startCharacter: 2,
+        endLine: 3,
+        endCharacter: 4,
+        kind: FoldingRangeKind.Comment);
     final json = jsonEncode(obj);
     final restoredObj = FoldingRange.fromJson(jsonDecode(json));
 
@@ -346,13 +373,13 @@
   });
 
   test('objects with maps can round-trip through to json and back', () {
-    final start = Position(1, 1);
-    final end = Position(2, 2);
-    final range = Range(start, end);
-    final obj = WorkspaceEdit(<String, List<TextEdit>>{
-      'fileA': [TextEdit(range, 'text A')],
-      'fileB': [TextEdit(range, 'text B')]
-    }, null);
+    final start = Position(line: 1, character: 1);
+    final end = Position(line: 2, character: 2);
+    final range = Range(start: start, end: end);
+    final obj = WorkspaceEdit(changes: <String, List<TextEdit>>{
+      'fileA': [TextEdit(range: range, newText: 'text A')],
+      'fileB': [TextEdit(range: range, newText: 'text B')]
+    });
     final json = jsonEncode(obj);
     final restoredObj = WorkspaceEdit.fromJson(jsonDecode(json));
 
diff --git a/pkg/analysis_server/test/tool/lsp_spec/typescript_test.dart b/pkg/analysis_server/test/tool/lsp_spec/typescript_test.dart
index 45a7fc1..fef2206 100644
--- a/pkg/analysis_server/test/tool/lsp_spec/typescript_test.dart
+++ b/pkg/analysis_server/test/tool/lsp_spec/typescript_test.dart
@@ -242,6 +242,39 @@
       expect(typeAlias.baseType, isArrayOf(isSimpleType('DocumentFilter')));
     });
 
+    test('parses a type alias that is a union of unnamed types', () {
+      final input = '''
+export type NameOrLength = { name: string } | { length: number };
+    ''';
+      final output = parseString(input);
+      expect(output, hasLength(3));
+
+      // Results should be the two inline interfaces followed by the type alias.
+
+      expect(output[0], const TypeMatcher<InlineInterface>());
+      final InlineInterface interface1 = output[0];
+      expect(interface1.name, equals('NameOrLength1'));
+      expect(interface1.members, hasLength(1));
+      expect(interface1.members[0].name, equals('name'));
+
+      expect(output[1], const TypeMatcher<InlineInterface>());
+      final InlineInterface interface2 = output[1];
+      expect(interface2.name, equals('NameOrLength2'));
+      expect(interface2.members, hasLength(1));
+      expect(interface2.members[0].name, equals('length'));
+
+      expect(output[2], const TypeMatcher<TypeAlias>());
+      final TypeAlias typeAlias = output[2];
+      expect(typeAlias.name, equals('NameOrLength'));
+      expect(typeAlias.baseType, const TypeMatcher<UnionType>());
+
+      // The type alias should be a union of the two types above.
+      UnionType union = typeAlias.baseType;
+      expect(union.types, hasLength(2));
+      expect(union.types[0], isSimpleType(interface1.name));
+      expect(union.types[1], isSimpleType(interface2.name));
+    });
+
     test('parses a namespace of constants', () {
       final input = '''
 export namespace ResourceOperationKind {
@@ -321,5 +354,18 @@
       expect(field.name, equals('label'));
       expect(field.type, isSimpleType('object'));
     });
+
+    test('parses multiple single-line comments into a single token', () {
+      final input = '''
+// This is line 1
+// This is line 2
+interface SomeInformation {
+}
+    ''';
+      final output = parseString(input);
+      expect(output, hasLength(1));
+      expect(output[0].commentNode.token.lexeme, equals('''// This is line 1
+// This is line 2'''));
+    });
   });
 }
diff --git a/pkg/analysis_server/tool/completion_metrics/completion_metrics.dart b/pkg/analysis_server/tool/completion_metrics/completion_metrics.dart
index 66b4b1e..73091f0 100644
--- a/pkg/analysis_server/tool/completion_metrics/completion_metrics.dart
+++ b/pkg/analysis_server/tool/completion_metrics/completion_metrics.dart
@@ -95,6 +95,11 @@
 /// A flag that causes additional output to be produced.
 const String VERBOSE = 'verbose';
 
+/// A [Counter] to track the performance of the new relevance to the old
+/// relevance.
+Counter oldVsNewComparison =
+    Counter('use old vs new relevance rank comparison');
+
 /// Create a parser that can be used to parse the command-line arguments.
 ArgParser createArgParser() {
   return ArgParser()
@@ -477,6 +482,12 @@
       printMetrics(metricsOldMode);
     }
     printMetrics(metricsNewMode);
+
+    print('');
+    print('====================');
+    oldVsNewComparison.printCounterValues();
+    print('====================');
+
     if (verbose) {
       printWorstResults(metricsNewMode);
       printSlowestResults(metricsNewMode);
@@ -485,7 +496,7 @@
     return resultCode;
   }
 
-  bool forEachExpectedCompletion(
+  int forEachExpectedCompletion(
       CompletionRequestImpl request,
       MetricsSuggestionListener listener,
       ExpectedCompletion expectedCompletion,
@@ -496,14 +507,14 @@
       bool doPrintMissedCompletions) {
     assert(suggestions != null);
 
-    var successfulCompletion;
+    var rank;
 
     var place = placementInSuggestionList(suggestions, expectedCompletion);
 
     metrics.mrrComputer.addRank(place.rank);
 
     if (place.denominator != 0) {
-      successfulCompletion = true;
+      rank = place.rank;
 
       metrics.completionCounter.count('successful');
 
@@ -518,7 +529,7 @@
       metrics.insertionLengthTheoretical
           .addValue(expectedCompletion.completion.length - charsBeforeTop);
     } else {
-      successfulCompletion = false;
+      rank = -1;
 
       metrics.completionCounter.count('unsuccessful');
 
@@ -544,7 +555,7 @@
         print('');
       }
     }
-    return successfulCompletion;
+    return rank;
   }
 
   void printMetrics(CompletionMetrics metrics) {
@@ -864,7 +875,7 @@
             // and results are collected with varying settings for
             // comparison:
 
-            Future<bool> handleExpectedCompletion(
+            Future<int> handleExpectedCompletion(
                 {MetricsSuggestionListener listener,
                 @required CompletionMetrics metrics,
                 @required bool printMissedCompletions,
@@ -910,9 +921,9 @@
 
             // First we compute the completions useNewRelevance set to
             // false:
-            var oldRelevanceSucceeded = false;
+            var oldRank;
             if (!skipOldRelevance) {
-              oldRelevanceSucceeded = await handleExpectedCompletion(
+              oldRank = await handleExpectedCompletion(
                   metrics: metricsOldMode,
                   printMissedCompletions: false,
                   useNewRelevance: false);
@@ -920,23 +931,29 @@
 
             // And again here with useNewRelevance set to true:
             var listener = MetricsSuggestionListener();
-            var newRelevanceSucceeded = await handleExpectedCompletion(
+            var newRank = await handleExpectedCompletion(
                 listener: listener,
                 metrics: metricsNewMode,
                 printMissedCompletions: verbose,
                 useNewRelevance: true);
 
-            if (!skipOldRelevance &&
-                verbose &&
-                oldRelevanceSucceeded != newRelevanceSucceeded) {
-              if (newRelevanceSucceeded) {
+            if (!skipOldRelevance && newRank != -1 && oldRank != -1) {
+              if (newRank <= oldRank) {
+                oldVsNewComparison.count('new relevance');
+              } else {
+                oldVsNewComparison.count('old relevance');
+              }
+            }
+
+            if (!skipOldRelevance && verbose) {
+              if (newRank > 0 && oldRank < 0) {
                 print('    ===========');
                 print(
                     '    The `useNewRelevance = true` generated a completion that `useNewRelevance = false` did not:');
                 print('    $expectedCompletion');
                 print('    ===========');
                 print('');
-              } else {
+              } else if (newRank < 0 && oldRank > 0) {
                 print('    ===========');
                 print(
                     '    The `useNewRelevance = false` generated a completion that `useNewRelevance = true` did not:');
diff --git a/pkg/analysis_server/tool/completion_metrics/relevance_metrics.dart b/pkg/analysis_server/tool/completion_metrics/relevance_metrics.dart
index 4dc6352..d1da6d3 100644
--- a/pkg/analysis_server/tool/completion_metrics/relevance_metrics.dart
+++ b/pkg/analysis_server/tool/completion_metrics/relevance_metrics.dart
@@ -267,9 +267,6 @@
   /// The relevance data being collected.
   final RelevanceData data;
 
-  /// The object used to determine Flutter-specific features.
-  Flutter flutter;
-
   InheritanceManager3 inheritanceManager = InheritanceManager3();
 
   /// The library containing the compilation unit being visited.
@@ -292,11 +289,6 @@
   /// [data].
   RelevanceDataCollector(this.data);
 
-  /// Initialize this collector prior to visiting the unit in the [result].
-  void initializeFrom(ResolvedUnitResult result) {
-    flutter = Flutter.of(result);
-  }
-
   @override
   void visitAdjacentStrings(AdjacentStrings node) {
     // There are no completions.
@@ -314,7 +306,7 @@
     var context = _argumentListContext(node);
     var parent = node.parent;
     var inWidgetConstructor = parent is InstanceCreationExpression &&
-        flutter.isWidgetType(parent.staticType);
+        Flutter.instance.isWidgetType(parent.staticType);
     for (var argument in node.arguments) {
       var realArgument = argument;
       var argumentKind = 'unnamed';
@@ -1981,7 +1973,6 @@
             continue;
           }
 
-          collector.initializeFrom(resolvedUnitResult);
           resolvedUnitResult.unit.accept(collector);
         } catch (exception, stacktrace) {
           print('Exception caught analyzing: "$filePath"');
diff --git a/pkg/analysis_server/tool/completion_metrics/relevance_table_generator.dart b/pkg/analysis_server/tool/completion_metrics/relevance_table_generator.dart
index 4b6d1dc..dacc489 100644
--- a/pkg/analysis_server/tool/completion_metrics/relevance_table_generator.dart
+++ b/pkg/analysis_server/tool/completion_metrics/relevance_table_generator.dart
@@ -215,9 +215,6 @@
   /// The compilation unit in which data is currently being collected.
   CompilationUnit unit;
 
-  /// The object used to determine Flutter-specific features.
-  Flutter flutter;
-
   InheritanceManager3 inheritanceManager = InheritanceManager3();
 
   /// The library containing the compilation unit being visited.
@@ -239,7 +236,6 @@
   /// Initialize this collector prior to visiting the unit in the [result].
   void initializeFrom(ResolvedUnitResult result) {
     unit = result.unit;
-    flutter = Flutter.of(result);
   }
 
   @override
@@ -1203,7 +1199,7 @@
       } else if (parent is FunctionExpressionInvocation) {
         return 'function';
       } else if (parent is InstanceCreationExpression) {
-        if (flutter.isWidgetType(parent.staticType)) {
+        if (Flutter.instance.isWidgetType(parent.staticType)) {
           return 'widgetConstructor';
         }
         return 'constructor';
diff --git a/pkg/analysis_server/tool/lsp_spec/README.md b/pkg/analysis_server/tool/lsp_spec/README.md
index d4890e4..bba94d6 100644
--- a/pkg/analysis_server/tool/lsp_spec/README.md
+++ b/pkg/analysis_server/tool/lsp_spec/README.md
@@ -30,6 +30,7 @@
 Client workspace settings are requested with `workspace/configuration` during initialization and re-requested whenever the client notifies the server with `workspace/didChangeConfiguration`. This allows the settings to take effect without restarting the server.
 
 - `dart.enableSdkFormatter`: When set to `false`, prevents registration (or unregisters) the SDK formatter. When set to `true` or not supplied, will register/reregister the SDK formatter.
+- `dart.lineLength`: The number of characters the formatter should wrap code at. If unspecified, code will be wrapped at `80` characters.
 
 ## Method Status
 
@@ -98,9 +99,9 @@
 | textDocument/prepareRename | ✅ | ✅ | | ✅ | ✅ |
 | textDocument/foldingRange | ✅ | ✅ | ✅ | ✅ | ✅ |
 
-## Custom Methods
+## Custom Methods and Notifications
 
-The following custom methods are also provided by the Dart LSP server:
+The following custom methods/notifications are also provided by the Dart LSP server:
 
 ### dart/diagnosticServer Method
 
diff --git a/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart b/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
index 6fd1691..c9ec3cb 100644
--- a/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
+++ b/pkg/analysis_server/tool/lsp_spec/codegen_dart.dart
@@ -36,7 +36,7 @@
 
 String generateDartForTypes(List<AstNode> types) {
   final buffer = IndentableStringBuffer();
-  _getSorted(types).forEach((t) => _writeType(buffer, t));
+  _getSortedUnique(types).forEach((t) => _writeType(buffer, t));
   final formattedCode = _formatCode(buffer.toString());
   return formattedCode.trim() + '\n'; // Ensure a single trailing newline.
 }
@@ -95,9 +95,27 @@
       .toList();
 }
 
-/// Returns a copy of the list sorted by name.
-List<AstNode> _getSorted(List<AstNode> items) {
-  final sortedList = items.toList();
+/// Returns a copy of the list sorted by name with duplicates (by name+type) removed.
+List<AstNode> _getSortedUnique(List<AstNode> items) {
+  final uniqueByName = <String, AstNode>{};
+  items.forEach((item) {
+    // It's fine to have the same name used for different types (eg. namespace +
+    // type alias) but some types are just duplicated entirely in the spec in
+    // different positions which should not be emitted twice.
+    final nameTypeKey = '${item.name}|${item.runtimeType}';
+    if (uniqueByName.containsKey(nameTypeKey)) {
+      // At the time of writing, there were two duplicated types:
+      // - TextDocumentSyncKind (same defintion in both places)
+      // - TextDocumentSyncOptions (first definition is just a subset)
+      // If this list grows, consider handling this better - or try to have the
+      // spec updated to be unambigious.
+      print('WARN: More than one definition for $nameTypeKey.');
+    }
+
+    // Keep the last one as in some cases the first definition is less specific.
+    uniqueByName[nameTypeKey] = item;
+  });
+  final sortedList = uniqueByName.values.toList();
   sortedList.sort((item1, item2) => item1.name.compareTo(item2.name));
   return sortedList;
 }
@@ -199,7 +217,7 @@
     }
     buffer.write('!(');
     _writeTypeCheckCondition(
-        buffer, "obj['${field.name}']", field.type, 'reporter');
+        buffer, interface, "obj['${field.name}']", field.type, 'reporter');
     buffer
       ..write(')) {')
       ..indent()
@@ -240,9 +258,13 @@
     return;
   }
   buffer
-    ..writeIndented('${interface.name}(')
-    ..write(allFields.map((field) => 'this.${field.name}').join(', '))
-    ..write(')');
+    ..writeIndented('${interface.name}({')
+    ..write(allFields.map((field) {
+      final annotation =
+          !field.allowsNull && !field.allowsUndefined ? '@required' : '';
+      return '$annotation this.${field.name}';
+    }).join(', '))
+    ..write('})');
   final fieldsWithValidation =
       allFields.where((f) => !f.allowsNull && !f.allowsUndefined).toList();
   if (fieldsWithValidation.isNotEmpty) {
@@ -302,7 +324,7 @@
     ..indent();
   if (allowsAnyValue) {
     buffer.writeIndentedln('return ');
-    _writeTypeCheckCondition(buffer, 'obj', typeOfValues, 'reporter');
+    _writeTypeCheckCondition(buffer, null, 'obj', typeOfValues, 'reporter');
     buffer.writeln(';');
   } else {
     buffer
@@ -445,7 +467,8 @@
 
     // Dynamic matches all type checks, so only emit it if required.
     if (!isDynamic) {
-      _writeTypeCheckCondition(buffer, valueCode, type, 'nullLspJsonReporter');
+      _writeTypeCheckCondition(
+          buffer, null, valueCode, type, 'nullLspJsonReporter');
       buffer.write(' ? ');
     }
 
@@ -503,7 +526,7 @@
   }
   buffer
     ..writeIndented('return ${interface.nameWithTypeArgs}(')
-    ..write(allFields.map((field) => '${field.name}').join(', '))
+    ..write(allFields.map((field) => '${field.name}: ${field.name}').join(', '))
     ..writeln(');')
     ..outdent()
     ..writeIndented('}');
@@ -609,7 +632,7 @@
 }
 
 void _writeMembers(IndentableStringBuffer buffer, List<Member> members) {
-  _getSorted(members).forEach((m) => _writeMember(buffer, m));
+  _getSortedUnique(members).forEach((m) => _writeMember(buffer, m));
 }
 
 void _writeToJsonFieldsForResponseMessage(
@@ -685,8 +708,8 @@
   }
 }
 
-void _writeTypeCheckCondition(IndentableStringBuffer buffer, String valueCode,
-    TypeBase type, String reporter) {
+void _writeTypeCheckCondition(IndentableStringBuffer buffer,
+    Interface interface, String valueCode, TypeBase type, String reporter) {
   type = resolveTypeAlias(type);
 
   final dartType = type.dartType;
@@ -703,7 +726,8 @@
       // TODO(dantup): If we're happy to assume we never have two lists in a union
       // we could skip this bit.
       buffer.write(' && ($valueCode.every((item) => ');
-      _writeTypeCheckCondition(buffer, 'item', type.elementType, reporter);
+      _writeTypeCheckCondition(
+          buffer, interface, 'item', type.elementType, reporter);
       buffer.write('))');
     }
     buffer.write(')');
@@ -711,9 +735,11 @@
     buffer.write('($valueCode is Map');
     if (fullDartType != 'dynamic') {
       buffer..write(' && (')..write('$valueCode.keys.every((item) => ');
-      _writeTypeCheckCondition(buffer, 'item', type.indexType, reporter);
+      _writeTypeCheckCondition(
+          buffer, interface, 'item', type.indexType, reporter);
       buffer..write('&& $valueCode.values.every((item) => ');
-      _writeTypeCheckCondition(buffer, 'item', type.valueType, reporter);
+      _writeTypeCheckCondition(
+          buffer, interface, 'item', type.valueType, reporter);
       buffer.write(')))');
     }
     buffer.write(')');
@@ -724,9 +750,18 @@
       if (i != 0) {
         buffer.write(' || ');
       }
-      _writeTypeCheckCondition(buffer, valueCode, type.types[i], reporter);
+      _writeTypeCheckCondition(
+          buffer, interface, valueCode, type.types[i], reporter);
     }
     buffer.write(')');
+  } else if (interface != null &&
+      interface.typeArgs != null &&
+      interface.typeArgs.any((typeArg) => typeArg.lexeme == fullDartType)) {
+    final comment = '/* $fullDartType.canParse($valueCode) */';
+    print(
+        'WARN: Unable to write a type check for $valueCode with generic type $fullDartType. '
+        'Please review the generated code annotated with $comment');
+    buffer.write('true $comment');
   } else {
     throw 'Unable to type check $valueCode against $fullDartType';
   }
diff --git a/pkg/analysis_server/tool/lsp_spec/generate_all.dart b/pkg/analysis_server/tool/lsp_spec/generate_all.dart
index 2ddf84a..de0b9b3 100644
--- a/pkg/analysis_server/tool/lsp_spec/generate_all.dart
+++ b/pkg/analysis_server/tool/lsp_spec/generate_all.dart
@@ -69,7 +69,7 @@
 /// The URI of the version of the spec to generate from. This should be periodically updated as
 /// there's no longer a stable URI for the latest published version.
 final Uri specUri = Uri.parse(
-    'https://raw.githubusercontent.com/microsoft/language-server-protocol/gh-pages/_specifications/specification-3-14.md');
+    'https://raw.githubusercontent.com/microsoft/language-server-protocol/gh-pages/_specifications/specification-3-15.md');
 
 /// Pattern to extract inline types from the `result: {xx, yy }` notes in the spec.
 /// Doesn't parse past full stops as some of these have english sentences tagged on
@@ -176,6 +176,7 @@
 import 'package:analysis_server/src/protocol/protocol_internal.dart'
     show listEqual, mapEqual;
 import 'package:analyzer/src/generated/utilities_general.dart';
+import 'package:meta/meta.dart';
 
 const jsonEncoder = JsonEncoder.withIndent('    ');
 
diff --git a/pkg/analysis_server/tool/lsp_spec/lsp_specification.md b/pkg/analysis_server/tool/lsp_spec/lsp_specification.md
index 2d3a9c8..4c8b08d 100644
--- a/pkg/analysis_server/tool/lsp_spec/lsp_specification.md
+++ b/pkg/analysis_server/tool/lsp_spec/lsp_specification.md
@@ -1,5 +1,5 @@
 This is an unmodified copy of the Language Server Protocol Specification,
-downloaded from https://raw.githubusercontent.com/microsoft/language-server-protocol/gh-pages/_specifications/specification-3-14.md. It is the version of the specification that was
+downloaded from https://raw.githubusercontent.com/microsoft/language-server-protocol/gh-pages/_specifications/specification-3-15.md. It is the version of the specification that was
 used to generate a portion of the Dart code used to support the protocol.
 
 To regenerate the generated code, run the script in
@@ -10,8 +10,8 @@
 ---
 
 Copyright (c) Microsoft Corporation.
- 
-All rights reserved. 
+
+All rights reserved.
 
 Distributed under the following terms:
 
@@ -22,34 +22,33 @@
 
 ---
 title: Specification
-shortTitle: 3.14 - Previous
+shortTitle: 3.15 - Current
 layout: specifications
-sectionid: specification-3-14
-toc: specification-3-14-toc
-index: 1
+sectionid: specification-3-15
+toc: specification-3-15-toc
+index: 2
 ---
-# Language Server Protocol Specification - 3.14
+# Language Server Protocol Specification - 3.15
 
-This document describes version 3.14.x of the language server protocol. An implementation for node of the 3.14.x version of the protocol can be found [here](https://github.com/Microsoft/vscode-languageserver-node).
+This document describes the 3.15.x version of the language server protocol. An implementation for node of the 3.15.x version of the protocol can be found [here](https://github.com/Microsoft/vscode-languageserver-node).
 
-The 2.x version of this document can be found [here](https://github.com/Microsoft/language-server-protocol/blob/master/versions/protocol-2-x.md).
-The 1.x version of this document can be found [here](https://github.com/Microsoft/language-server-protocol/blob/master/versions/protocol-1-x.md).
+**Note:** edits to this specification can be made via a pull request against this markdown [document](https://github.com/Microsoft/language-server-protocol/blob/gh-pages/_specifications/specification-3-15.md).
 
-**Note:** edits to this specification can be made via a pull request against this markdown [document](https://github.com/Microsoft/language-server-protocol/blob/gh-pages/_specifications/specification-3-14.md).
+## <a href="#whatIsNew" name="whatIsNew" class="anchor"> What's new in 3.15 </a>
 
-## Base Protocol
+All new 3.15 features are tagged with a corresponding since version 3.15 text or in JSDoc using `@since 3.15.0` annotation. Major new feature are:
+
+- [general progress support](#progress), [work done progress](#workDoneProgress) and [partial result progress](#partialResults)
+- support for [selection ranges](#textDocument_selectionRange)
+
+## <a href="#baseProtocol" name="baseProtocol" class="anchor"> Base Protocol </a>
 
 The base protocol consists of a header and a content part (comparable to HTTP). The header and content part are
 separated by a '\r\n'.
 
-### Header Part
+### <a href="#headerPart" name="headerPart" class="anchor"> Header Part </a>
 
-The header part consists of header fields. Each header field is comprised of a name and a value,
-separated by ': ' (a colon and a space).
-Each header field is terminated by '\r\n'.
-Considering the last header field and the overall header itself are each terminated with '\r\n',
-and that at least one header is mandatory, this means that two '\r\n' sequences always
-immediately precede the content part of a message.
+The header part consists of header fields. Each header field is comprised of a name and a value, separated by ': ' (a colon and a space). The structure of header fields conform to the [HTTP semantic](https://tools.ietf.org/html/rfc7230#section-3.2). Each header field is terminated by '\r\n'. Considering the last header field and the overall header itself are each terminated with '\r\n', and that at least one header is mandatory, this means that two '\r\n' sequences always immediately precede the content part of a message.
 
 Currently the following header fields are supported:
 
@@ -61,9 +60,9 @@
 
 The header part is encoded using the 'ascii' encoding. This includes the '\r\n' separating the header and content part.
 
-### Content Part
+### <a href="#contentPart" name="contentPart" class="anchor"> Content Part </a>
 
-Contains the actual content of the message. The content part of a message uses [JSON-RPC](http://www.jsonrpc.org/) to describe requests, responses and notifications. The content part is encoded using the charset provided in the Content-Type field. It defaults to `utf-8`, which is the only encoding supported right now. If a server or client receives a header with a different encoding than `utf-8`, then it should respond with an error.
+Contains the actual content of the message. The content part of a message uses [JSON-RPC](http://www.jsonrpc.org/) to describe requests, responses and notifications. The content part is encoded using the charset provided in the Content-Type field. It defaults to `utf-8`, which is the only encoding supported right now. If a server or client receives a header with a different encoding than `utf-8` it should respond with an error.
 
 (Prior versions of the protocol used the string constant `utf8` which is not a correct encoding constant according to [specification](http://www.iana.org/assignments/character-sets/character-sets.xhtml).) For backwards compatibility it is highly recommended that a client and a server treats the string `utf8` as `utf-8`.
 
@@ -94,7 +93,7 @@
 	jsonrpc: string;
 }
 ```
-#### Request Message
+#### <a href="#requestMessage" name="requestMessage" class="anchor"> Request Message </a>
 
 A request message to describe a request between the client and the server. Every processed request must send a response back to the sender of the request.
 
@@ -114,11 +113,11 @@
 	/**
 	 * The method's params.
 	 */
-	params?: Array<any> | object;
+	params?: array | object;
 }
 ```
 
-#### Response Message
+#### <a href="#responseMessage" name="responseMessage" class="anchor"> Response Message </a>
 
 A Response Message sent as a result of a request. If a request doesn't provide a result value the receiver of a request still needs to return a response message to conform to the JSON RPC specification. The result property of the ResponseMessage should be set to `null` in this case to signal a successful request.
 
@@ -138,10 +137,10 @@
 	/**
 	 * The error object in case a request fails.
 	 */
-	error?: ResponseError<any>;
+	error?: ResponseError;
 }
 
-interface ResponseError<D> {
+interface ResponseError {
 	/**
 	 * A number indicating the error type that occurred.
 	 */
@@ -153,10 +152,10 @@
 	message: string;
 
 	/**
-	 * A Primitive or Structured value that contains additional
+	 * A primitive or structured value that contains additional
 	 * information about the error. Can be omitted.
 	 */
-	data?: D;
+	data?: string | number | boolean | array | object | null;
 }
 
 export namespace ErrorCodes {
@@ -176,7 +175,7 @@
 	export const ContentModified: number = -32801;
 }
 ```
-#### Notification Message
+#### <a href="#notificationMessage" name="notificationMessage" class="anchor"> Notification Message </a>
 
 A notification message. A processed notification message must not send a response back. They work like events.
 
@@ -190,11 +189,11 @@
 	/**
 	 * The notification's params.
 	 */
-	params?: Array<any> | object;
+	params?: array | object;
 }
 ```
 
-#### $ Notifications and Requests
+#### <a href="#dollarRequests" name="dollarRequests" class="anchor"> $ Notifications and Requests </a>
 
 Notification and requests whose methods start with '$/' are messages which are protocol implementation dependent and might not be implementable in all clients or servers. For example if the server implementation uses a single threaded synchronous programming language then there is little a server can do to react to a '$/cancelRequest' notification. If a server or client receives notifications starting with '$/' it is free to ignore the notification. If a server or client receives a requests starting with '$/' it must error the request with error code `MethodNotFound` (e.g. `-32601`).
 
@@ -217,6 +216,35 @@
 
 A request that got canceled still needs to return from the server and send a response back. It can not be left open / hanging. This is in line with the JSON RPC protocol that requires that every request sends a response back. In addition it allows for returning partial results on cancel. If the request returns an error response on cancellation it is advised to set the error code to `ErrorCodes.RequestCancelled`.
 
+#### <a href="#progress" name="progress" class="anchor"> Progress Support (:arrow_right: :arrow_left:)</a>
+
+> *Since version 3.15.0*
+
+The base protocol offers also support to report progress in a generic fashion. This mechanism can be used to report any kind of progress including work done progress (usually used to report progress in the user interface using a progress bar) and partial result progress to support streaming of results.
+
+A progress notification has the following properties:
+
+_Notification_:
+* method: '$/progress'
+* params: `ProgressParams` defined as follows:
+
+```typescript
+type ProgressToken = number | string;
+interface ProgressParams<T> {
+	/**
+	 * The progress token provided by the client or server.
+	 */
+	token: ProgressToken;
+
+	/**
+	 * The progress data.
+	 */
+	value: T;
+}
+```
+
+Progress is reported against a token. The token is different than the request ID which allows to report progress out of band and also for notification.
+
 ## Language Server Protocol
 
 The language server protocol defines a set of JSON-RPC request, response and notification messages which are exchanged using the above base protocol. This section starts describing the basic JSON structures used in the protocol. The document uses TypeScript interfaces to describe these. Based on the basic JSON structures, the actual requests with their responses and the notifications are described.
@@ -227,7 +255,7 @@
 
 ### Basic JSON Structures
 
-#### URI
+#### <a href="#uri" name="uri" class="anchor"> URI </a>
 
 URI's are transferred as strings. The URI's format is defined in [http://tools.ietf.org/html/rfc3986](http://tools.ietf.org/html/rfc3986)
 
@@ -249,17 +277,17 @@
 type DocumentUri = string;
 ```
 
-#### Text Documents
+#### <a href="#textDocuments" name="textDocuments" class="anchor"> Text Documents </a>
 
 The current protocol is tailored for textual documents whose content can be represented as a string. There is currently no support for binary documents. A position inside a document (see Position definition below) is expressed as a zero-based line and character offset. The offsets are based on a UTF-16 string representation. So a string of the form `a𐐀b` the character offset of the character `a` is 0, the character offset of `𐐀` is 1 and the character offset of b is 3 since `𐐀` is represented using two code units in UTF-16. To ensure that both client and server split the string into the same line representation the protocol specifies the following end-of-line sequences: '\n', '\r\n' and '\r'.
 
-Positions are line end character agnostic. So you can not specify  a position that denotes `\r|\n` or `\n|` where `|` represents the character offset.
+Positions are line end character agnostic. So you can not specify a position that denotes `\r|\n` or `\n|` where `|` represents the character offset.
 
 ```typescript
 export const EOL: string[] = ['\n', '\r\n', '\r'];
 ```
 
-#### Position
+#### <a href="#position" name="position" class="anchor"> Position </a>
 
 Position in a text document expressed as zero-based line and zero-based character offset. A position is between two characters like an 'insert' cursor in a editor. Special values like for example `-1` to denote the end of a line are not supported.
 
@@ -281,13 +309,13 @@
 	character: number;
 }
 ```
-#### Range
+#### <a href="#range" name="range" class="anchor"> Range </a>
 
 A range in a text document expressed as (zero-based) start and end positions. A range is comparable to a selection in an editor. Therefore the end position is exclusive. If you want to specify a range that contains a line including the line ending character(s) then use an end position denoting the start of the next line. For example:
 ```typescript
 {
     start: { line: 5, character: 23 },
-    end : { line 6, character : 0 }
+    end : { line: 6, character: 0 }
 }
 ```
 
@@ -305,7 +333,7 @@
 }
 ```
 
-#### Location
+#### <a href="#location" name="location" class="anchor"> Location </a>
 
 Represents a location inside a resource, such as a line inside a text file.
 ```typescript
@@ -315,7 +343,7 @@
 }
 ```
 
-#### LocationLink
+#### <a href="#locationLink" name="locationLink" class="anchor"> LocationLink </a>
 
 Represents a link between a source and a target location.
 
@@ -350,12 +378,12 @@
 }
 ```
 
-#### Diagnostic
+#### <a href="#diagnostic" name="diagnostic" class="anchor"> Diagnostic </a>
 
 Represents a diagnostic, such as a compiler error or warning. Diagnostic objects are only valid in the scope of a resource.
 
 ```typescript
-interface Diagnostic {
+export interface Diagnostic {
 	/**
 	 * The range at which the message applies.
 	 */
@@ -365,7 +393,7 @@
 	 * The diagnostic's severity. Can be omitted. If omitted it is up to the
 	 * client to interpret diagnostics as error, warning, info or hint.
 	 */
-	severity?: number;
+	severity?: DiagnosticSeverity;
 
 	/**
 	 * The diagnostic's code, which might appear in the user interface.
@@ -384,6 +412,13 @@
 	message: string;
 
 	/**
+	 * Additional metadata about the diagnostic.
+	 *
+	 * @since 3.15.0
+	 */
+	tags?: DiagnosticTag[];
+
+	/**
 	 * An array of related diagnostic information, e.g. when symbol-names within
 	 * a scope collide all definitions can be marked via this property.
 	 */
@@ -391,33 +426,60 @@
 }
 ```
 
-The protocol currently supports the following diagnostic severities:
+The protocol currently supports the following diagnostic severities and tags:
 
 ```typescript
-namespace DiagnosticSeverity {
+export namespace DiagnosticSeverity {
 	/**
 	 * Reports an error.
 	 */
-	export const Error = 1;
+	export const Error: 1 = 1;
 	/**
 	 * Reports a warning.
 	 */
-	export const Warning = 2;
+	export const Warning: 2 = 2;
 	/**
 	 * Reports an information.
 	 */
-	export const Information = 3;
+	export const Information: 3 = 3;
 	/**
 	 * Reports a hint.
 	 */
-	export const Hint = 4;
+	export const Hint: 4 = 4;
 }
+
+export type DiagnosticSeverity = 1 | 2 | 3 | 4;
+
+/**
+ * The diagnostic tags.
+ *
+ * @since 3.15.0
+ */
+export namespace DiagnosticTag {
+    /**
+     * Unused or unnecessary code.
+     *
+     * Clients are allowed to render diagnostics with this tag faded out instead of having
+     * an error squiggle.
+     */
+    export const Unnecessary: 1 = 1;
+    /**
+     * Deprecated or obsolete code.
+     *
+     * Clients are allowed to rendered diagnostics with this tag strike through.
+     */
+    export const Deprecated: 2 = 2;
+}
+
+export type DiagnosticTag = 1 | 2;
 ```
 
+`DiagnosticRelatedInformation` is defined as follows:
+
 ```typescript
 /**
  * Represents a related message and source code location for a diagnostic. This should be
- * used to point to code locations that cause or related to a diagnostics, e.g when duplicating
+ * used to point to code locations that cause or are related to a diagnostics, e.g when duplicating
  * a symbol in a scope.
  */
 export interface DiagnosticRelatedInformation {
@@ -433,7 +495,7 @@
 }
 ```
 
-#### Command
+#### <a href="#command" name="command" class="anchor"> Command </a>
 
 Represents a reference to a command. Provides a title which will be used to represent a command in the UI. Commands are identified by a string identifier. The recommended way to handle commands is to implement their execution on the server side if the client and server provides the corresponding capabilities. Alternatively the tool extension code could handle the command. The protocol currently doesn't specify a set of well-known commands.
 
@@ -455,7 +517,7 @@
 }
 ```
 
-#### TextEdit
+#### <a href="#textEdit" name="textEdit" class="anchor"> TextEdit </a>
 
 A textual edit applicable to a text document.
 
@@ -475,15 +537,15 @@
 }
 ```
 
-#### TextEdit[]
+#### <a href="#textEditArray" name="textEditArray" class="anchor"> TextEdit[] </a>
 
 Complex text manipulations are described with an array of `TextEdit`'s, representing a single change to the document.
 
-All text edits ranges refer to positions in the original document. Text edits ranges must never overlap, that means no part of the original document must be manipulated by more than one edit. However, it is possible that multiple edits have the same start position: multiple inserts, or any number of inserts followed by a single remove or replace edit. If multiple inserts have the same position, the order in the array defines the order in which the inserted strings appear in the resulting text.
+All text edits ranges refer to positions in the document the are computed on. They therefore move a document from state S1 to S2 without describing any intermediate state. Text edits ranges must never overlap, that means no part of the original document must be manipulated by more than one edit. However, it is possible that multiple edits have the same start position: multiple inserts, or any number of inserts followed by a single remove or replace edit. If multiple inserts have the same position, the order in the array defines the order in which the inserted strings appear in the resulting text.
 
-#### TextDocumentEdit
+#### <a href="#textDocumentEdit" name="textDocumentEdit" class="anchor"> TextDocumentEdit </a>
 
-Describes textual changes on a single text document. The text document is referred to as a `VersionedTextDocumentIdentifier` to allow clients to check the text document version before an edit is applied. A `TextDocumentEdit` describes all changes on a version Si and after they are applied move the document to version Si+1. So the creator of a `TextDocumentEdit` doesn't need to sort the array or do any kind of ordering. However the edits must be non overlapping.
+Describes textual changes on a single text document. The text document is referred to as a `VersionedTextDocumentIdentifier` to allow clients to check the text document version before an edit is applied. A `TextDocumentEdit` describes all changes on a version Si and after they are applied move the document to version Si+1. So the creator of a `TextDocumentEdit` doesn't need to sort the array of edits or do any kind of ordering. However the edits must be non overlapping.
 
 ```typescript
 export interface TextDocumentEdit {
@@ -499,7 +561,7 @@
 }
 ```
 
-### File Resource changes
+### <a href="#resourceChanges" name="resourceChanges" class="anchor"> File Resource changes </a>
 
 > New in version 3.13:
 
@@ -607,7 +669,7 @@
 }
 ```
 
-#### WorkspaceEdit
+#### <a href="#workspaceEdit" name="workspaceEdit" class="anchor"> WorkspaceEdit </a>
 
 A workspace edit represents changes to many resources managed in the workspace. The edit should either provide `changes` or `documentChanges`. If the client can handle versioned document edits and if `documentChanges` are present, the latter are preferred over `changes`.
 
@@ -634,7 +696,96 @@
 }
 ```
 
-#### TextDocumentIdentifier
+##### <a href="#workspaceEditClientCapabilities" name="workspaceEditClientCapabilities" class="anchor"> WorkspaceEditClientCapabilities </a>
+
+> New in version 3.13: `ResourceOperationKind` and `FailureHandlingKind` and the client capability `workspace.workspaceEdit.resourceOperations` as well as `workspace.workspaceEdit.failureHandling`.
+
+
+The capabilities of a workspace edit has evolved over the time. Clients can describe their support using the following client capability:
+
+* property path (optional): `workspace.workspaceEdit`
+* property type: `WorkspaceEditClientCapabilities` defined as follows:
+
+```typescript
+export interface WorkspaceEditClientCapabilities {
+	/**
+	 * The client supports versioned document changes in `WorkspaceEdit`s
+	 */
+	documentChanges?: boolean;
+
+	/**
+	 * The resource operations the client supports. Clients should at least
+	 * support 'create', 'rename' and 'delete' files and folders.
+	 *
+	 * @since 3.13.0
+	 */
+	resourceOperations?: ResourceOperationKind[];
+
+	/**
+	 * The failure handling strategy of a client if applying the workspace edit
+	 * fails.
+	 *
+	 * @since 3.13.0
+	 */
+	failureHandling?: FailureHandlingKind;
+}
+
+/**
+ * The kind of resource operations supported by the client.
+ */
+export type ResourceOperationKind = 'create' | 'rename' | 'delete';
+
+export namespace ResourceOperationKind {
+
+	/**
+	 * Supports creating new files and folders.
+	 */
+	export const Create: ResourceOperationKind = 'create';
+
+	/**
+	 * Supports renaming existing files and folders.
+	 */
+	export const Rename: ResourceOperationKind = 'rename';
+
+	/**
+	 * Supports deleting existing files and folders.
+	 */
+	export const Delete: ResourceOperationKind = 'delete';
+}
+
+export type FailureHandlingKind = 'abort' | 'transactional' | 'undo' | 'textOnlyTransactional';
+
+export namespace FailureHandlingKind {
+
+	/**
+	 * Applying the workspace change is simply aborted if one of the changes provided
+	 * fails. All operations executed before the failing operation stay executed.
+	 */
+	export const Abort: FailureHandlingKind = 'abort';
+
+	/**
+	 * All operations are executed transactional. That means they either all
+	 * succeed or no changes at all are applied to the workspace.
+	 */
+	export const Transactional: FailureHandlingKind = 'transactional';
+
+
+	/**
+	 * If the workspace edit contains only textual file changes they are executed transactional.
+	 * If resource changes (create, rename or delete file) are part of the change the failure
+	 * handling strategy is abort.
+	 */
+	export const TextOnlyTransactional: FailureHandlingKind = 'textOnlyTransactional';
+
+	/**
+	 * The client tries to undo the operations already executed. But there is no
+	 * guarantee that this is succeeding.
+	 */
+	export const Undo: FailureHandlingKind = 'undo';
+}
+```
+
+#### <a href="#textDocumentIdentifier" name="textDocumentIdentifier" class="anchor"> TextDocumentIdentifier </a>
 
 Text documents are identified using a URI. On the protocol level, URIs are passed as strings. The corresponding JSON structure looks like this:
 ```typescript
@@ -646,7 +797,7 @@
 }
 ```
 
-#### TextDocumentItem
+#### <a href="#textDocumentItem" name="textDocumentItem" class="anchor"> TextDocumentItem </a>
 
 An item to transfer a text document from the client to the server.
 
@@ -691,6 +842,8 @@
 Diff | `diff`
 Dart | `dart`
 Dockerfile | `dockerfile`
+Elixir | `elixir`
+Erlang | `erlang`
 F# | `fsharp`
 Git | `git-commit` and `git-rebase`
 Go | `go`
@@ -734,7 +887,7 @@
 YAML | `yaml`
 {: .table .table-bordered .table-responsive}
 
-#### VersionedTextDocumentIdentifier
+#### <a href="#versionedTextDocumentIdentifier" name="versionedTextDocumentIdentifier" class="anchor"> VersionedTextDocumentIdentifier </a>
 
 An identifier to denote a specific version of a text document.
 
@@ -745,7 +898,7 @@
 	 * is sent from the server to the client and the file is not open in the editor
 	 * (the server has not received an open notification before) the server can send
 	 * `null` to indicate that the version is known and the content on disk is the
-	 * truth (as speced with document content ownership).
+	 * master (as speced with document content ownership).
 	 *
 	 * The version number of a document will increase after each change, including
 	 * undo/redo. The number doesn't need to be consecutive.
@@ -754,7 +907,7 @@
 }
 ```
 
-#### TextDocumentPositionParams
+#### <a href="#textDocumentPositionParams" name="textDocumentPositionParams" class="anchor"> TextDocumentPositionParams </a>
 
 Was `TextDocumentPosition` in 1.0 with inlined parameters.
 
@@ -774,7 +927,7 @@
 }
 ```
 
-#### DocumentFilter
+#### <a href="#documentFilter" name="documentFilter" class="anchor"> DocumentFilter </a>
 
 A document filter denotes a document through properties like `language`, `scheme` or `pattern`. An example is a filter that applies to TypeScript files on disk. Another example is a filter the applies to JSON files with name `package.json`:
 ```typescript
@@ -815,7 +968,41 @@
 export type DocumentSelector = DocumentFilter[];
 ```
 
-#### MarkupContent
+#### <a href="#staticRegistrationOptions" name="staticRegistrationOptions" class="anchor"> StaticRegistrationOptions </a>
+
+Static registration options can be used to register a feature in the initialize result with a given server control ID to be able to un-register the feature later on.
+
+```typescript
+/**
+ * Static registration options to be returned in the initialize request.
+ */
+export interface StaticRegistrationOptions {
+	/**
+	 * The id used to register the request. The id can be used to deregister
+	 * the request again. See also Registration#id.
+	 */
+	id?: string;
+}
+```
+
+#### <a href="#textDocumentRegistrationOptions" name="textDocumentRegistrationOptions" class="anchor"> TextDocumentRegistrationOptions </a>
+
+Options to dynamically register for requests for a set of text documents.
+
+```typescript
+/**
+ * General text document registration options.
+ */
+export interface TextDocumentRegistrationOptions {
+	/**
+	 * A document selector to identify the scope of the registration. If set to null
+	 * the document selector provided on the client side will be used.
+	 */
+	documentSelector: DocumentSelector | null;
+}
+```
+
+#### <a href="#markupContent" name="markupContent" class="anchor"> MarkupContent </a>
 
  A `MarkupContent` literal represents a string value which content can be represented in different formats. Currently `plaintext` and `markdown` are supported formats. A `MarkupContent` is usually used in documentation properties of result literals like `CompletionItem` or `SignatureInformation`.
 
@@ -877,13 +1064,250 @@
 }
 ```
 
+#### <a href="#workDoneProgress" name="workDoneProgress" class="anchor"> Work Done Progress </a>
+
+> *Since version 3.15.0*
+
+Work done progress is reported using the generic [`$/progress`](#progress) notification. The value payload of a work done progress notification can be of three different forms.
+
+##### <a href="#workDoneProgressBegin" name="workDoneProgressBegin" class="anchor"> Work Done Progress Begin </a>
+
+To start progress reporting a `$/progress` notification with the following payload must be sent:
+
+```typescript
+export interface WorkDoneProgressBegin {
+
+	kind: 'begin';
+
+	/**
+	 * Mandatory title of the progress operation. Used to briefly inform about
+	 * the kind of operation being performed.
+	 *
+	 * Examples: "Indexing" or "Linking dependencies".
+	 */
+	title: string;
+
+	/**
+	 * Controls if a cancel button should show to allow the user to cancel the
+	 * long running operation. Clients that don't support cancellation are allowed
+	 * to ignore the setting.
+	 */
+	cancellable?: boolean;
+
+	/**
+	 * Optional, more detailed associated progress message. Contains
+	 * complementary information to the `title`.
+	 *
+	 * Examples: "3/25 files", "project/src/module2", "node_modules/some_dep".
+	 * If unset, the previous progress message (if any) is still valid.
+	 */
+	message?: string;
+
+	/**
+	 * Optional progress percentage to display (value 100 is considered 100%).
+	 * If not provided infinite progress is assumed and clients are allowed
+	 * to ignore the `percentage` value in subsequent in report notifications.
+	 *
+	 * The value should be steadily rising. Clients are free to ignore values
+	 * that are not following this rule.
+	 */
+	percentage?: number;
+}
+```
+
+##### <a href="#workDoneProgressReport" name="workDoneProgressReport" class="anchor"> Work Done Progress Report </a>
+
+Reporting progress is done using the following payload:
+
+```typescript
+export interface WorkDoneProgressReport {
+
+	kind: 'report';
+
+	/**
+	 * Controls enablement state of a cancel button. This property is only valid if a cancel
+	 * button got requested in the `WorkDoneProgressStart` payload.
+	 *
+	 * Clients that don't support cancellation or don't support control the button's
+	 * enablement state are allowed to ignore the setting.
+	 */
+	cancellable?: boolean;
+
+	/**
+	 * Optional, more detailed associated progress message. Contains
+	 * complementary information to the `title`.
+	 *
+	 * Examples: "3/25 files", "project/src/module2", "node_modules/some_dep".
+	 * If unset, the previous progress message (if any) is still valid.
+	 */
+	message?: string;
+
+	/**
+	 * Optional progress percentage to display (value 100 is considered 100%).
+	 * If not provided infinite progress is assumed and clients are allowed
+	 * to ignore the `percentage` value in subsequent in report notifications.
+	 *
+	 * The value should be steadily rising. Clients are free to ignore values
+	 * that are not following this rule.
+	 */
+	percentage?: number;
+}
+```
+
+##### <a href="#workDoneProgressEnd" name="workDoneProgressEnd" class="anchor"> Work Done Progress End </a>
+
+Signaling the end of a progress reporting is done using the following payload:
+
+```typescript
+export interface WorkDoneProgressEnd {
+
+	kind: 'end';
+
+	/**
+	 * Optional, a final message indicating to for example indicate the outcome
+	 * of the operation.
+	 */
+	message?: string;
+}
+```
+
+##### <a href="#initiatingWorkDoneProgress" name="initiatingWorkDoneProgress" class="anchor"> Initiating Work Done Progress </a>
+
+Work Done progress can be initiated in two different ways:
+
+1. by the sender of a request (mostly clients) using the predefined `workDoneToken` property in the requests parameter literal.
+1. by a server using the request `window/workDoneProgress/create`.
+
+Consider a client sending a `textDocument/reference` request to a server and the client accepts work done progress reporting on that request. To signal this to the server the client would add a `workDoneToken` property to the reference request parameters. Something like this:
+
+```json
+{
+	"textDocument": {
+		"uri": "file:///folder/file.ts"
+	},
+	"position": {
+		"line": 9,
+		"character": 5
+	},
+	"context": {
+		"includeDeclaration": true
+	},
+	// The token used to report work done progress.
+	"workDoneToken": "1d546990-40a3-4b77-b134-46622995f6ae"
+}
+```
+
+A server uses the `workDoneToken` to report progress for the specific `textDocument/reference`. For the above request the `$/progress` notification params look like this:
+
+```json
+{
+	"token": "1d546990-40a3-4b77-b134-46622995f6ae",
+	"value": {
+		"kind": "begin",
+		"title": "Finding references for A#foo",
+		"cancellable": false,
+		"message": "Processing file X.ts",
+		"percentage": 0
+	}
+}
+```
+
+Server initiated work done progress works the same. The only difference is that the server requests a progress user interface using the `window/workDoneProgress/create` request providing a token that is afterwards used to report progress.
+
+##### <a href="#signalingWorkDoneProgressReporting" name="signalingWorkDoneProgressReporting" class="anchor"> Signaling Work Done Progress Reporting </a>
+
+To keep the protocol backwards compatible servers are only allowed to use work done progress reporting if the client signals corresponding support using the client capability `window.workDoneProgress`.
+
+To avoid that clients set up a progress monitor user interface before sending a request but the server doesn't actually report any progress a server needs to signal work done progress reporting in the corresponding server capability. For the above find references example a server would signal such a support by setting the `referencesProvider` property in the server capabilities as follows:
+
+```json
+{
+	"referencesProvider": {
+		"workDoneProgress": true
+	}
+}
+```
+
+#### <a href="#workDoneProgressParams" name="workDoneProgressParams" class="anchor"> WorkDoneProgressParams </a>
+
+A parameter literal used to pass a work done progress token.
+
+```typescript
+export interface WorkDoneProgressParams {
+	/**
+	 * An optional token that a server can use to report work done progress.
+	 */
+	workDoneToken?: ProgressToken;
+}
+```
+
+#### <a href="#workDoneProgressOptions" name="workDoneProgressOptions" class="anchor"> WorkDoneProgressOptions </a>
+
+Options to signal work done progress support in server capabilities.
+
+```typescript
+export interface WorkDoneProgressOptions {
+	workDoneProgress?: boolean;
+}
+```
+
+#### <a href="#partialResults" name="partialResults" class="anchor"> Partial Result Progress </a>
+
+> *Since version 3.15.0*
+
+Partial results are also reported using the generic [`$/progress`](#progress) notification. The value payload of a partial result progress notification is in most cases the same as the final result. For example the `workspace/symbol` request has `SymbolInformation[]` as the result type. Partial result is therefore also of type `SymbolInformation[]`. Whether a client accepts partial result notifications for a request is signaled by adding a `partialResultToken` to the request parameter. For example, a `textDocument/reference` request that supports both work done and partial result progress might look like this:
+
+```json
+{
+	"textDocument": {
+		"uri": "file:///folder/file.ts"
+	},
+	"position": {
+		"line": 9,
+		"character": 5
+	},
+	"context": {
+		"includeDeclaration": true
+	},
+	// The token used to report work done progress.
+	"workDoneToken": "1d546990-40a3-4b77-b134-46622995f6ae",
+	// The token used to report partial result progress.
+	"partialResultToken": "5f6f349e-4f81-4a3b-afff-ee04bff96804"
+}
+```
+
+The `partialResultToken` is then used to report partial results for the find references request.
+
+If a server reports partial result via a corresponding `$/progress`, the whole result must be reported using n `$/progress` notifications. The final response has to be empty in terms of result values. This avoids confusion about how the final result should be interpreted, e.g. as another partial result or as a replacing result.
+
+If the response errors the provided partial results should be treated as follows:
+
+- the `code` equals to `RequestCancelled`: the client is free to use the provided results but should make clear that the request got canceled and may be incomplete.
+- in all other cases the provided partial results shouldn't be used.
+
+#### <a href="#partialResultParams" name="partialResultParams" class="anchor"> PartialResultParams </a>
+
+A parameter literal used to pass a partial result token.
+
+```typescript
+export interface PartialResultParams {
+	/**
+	 * An optional token that a server can use to report partial results (e.g. streaming) to
+	 * the client.
+	 */
+	partialResultToken?: ProgressToken;
+}
+```
+
 ### Actual Protocol
 
 This section documents the actual language server protocol. It uses the following format:
 
 * a header describing the request
-* a _Request_: section describing the format of the request sent. The method is a string identifying the request the params are documented using a TypeScript interface
-* a _Response_: section describing the format of the response. The result item describes the returned data in case of a success. The error.data describes the returned data in case of an error. Please remember that in case of a failure the response already contains an error.code and an error.message field. These fields are only spec'd if the protocol forces the use of certain error codes or messages. In cases where the server can decide on these values freely they aren't listed here.
+* an optional _Client capability_ section describing the client capability of the request. This includes the client capabilities property path and JSON structure.
+* an optional _Server Capability_ section describing the server capability of the request. This includes the server capabilities property path and JSON structure.
+* a _Request_ section describing the format of the request sent. The method is a string identifying the request the params are documented using a TypeScript interface. It is also documented whether the request supports work done progress and partial result progress.
+* a _Response_ section describing the format of the response. The result item describes the returned data in case of a success. The optional partial result item describes the returned data of a partial result notification. The error.data describes the returned data in case of an error. Please remember that in case of a failure the response already contains an error.code and an error.message field. These fields are only spec'd if the protocol forces the use of certain error codes or messages. In cases where the server can decide on these values freely they aren't listed here.
 * a _Registration Options_ section describing the registration option if the request or notification supports dynamic capability registration.
 
 #### Request, Notification and Response ordering
@@ -903,7 +1327,7 @@
 * For a request the response should be an error with `code: -32002`. The message can be picked by the server.
 * Notifications should be dropped, except for the exit notification. This will allow the exit of a server without an initialize request.
 
-Until the server has responded to the `initialize` request with an `InitializeResult`, the client must not send any additional requests or notifications to the server. In addition the server is not allowed to send any requests or notifications to the client until it has responded with an `InitializeResult`, with the exception that during the `initialize` request the server is allowed to send the notifications `window/showMessage`, `window/logMessage` and `telemetry/event` as well as the `window/showMessageRequest` request to the client.
+Until the server has responded to the `initialize` request with an `InitializeResult`, the client must not send any additional requests or notifications to the server. In addition the server is not allowed to send any requests or notifications to the client until it has responded with an `InitializeResult`, with the exception that during the `initialize` request the server is allowed to send the notifications `window/showMessage`, `window/logMessage` and `telemetry/event` as well as the `window/showMessageRequest` request to the client. In case the client sets up a progress token in the initialize params (e.g. property `workDoneToken`) the server is also allowed to use that token (and only that token) using the `$/progress` notification sent from the server to the client.
 
 The `initialize` request may only be sent once.
 
@@ -912,7 +1336,7 @@
 * params: `InitializeParams` defined as follows:
 
 ```typescript
-interface InitializeParams {
+interface InitializeParams extends WorkDoneProgressParams {
 	/**
 	 * The process Id of the parent process that started
 	 * the server. Is null if the process has not been started by another process.
@@ -921,6 +1345,23 @@
 	processId: number | null;
 
 	/**
+	 * Information about the client
+	 *
+	 * @since 3.15.0
+	 */
+	clientInfo?: {
+		/**
+		 * The name of the client as defined by the client.
+		 */
+		name: string;
+
+		/**
+		 * The client's version as defined by the client.
+		 */
+		version?: string;
+	};
+
+	/**
 	 * The rootPath of the workspace. Is null
 	 * if no folder is open.
 	 *
@@ -956,179 +1397,13 @@
 	 * It can be `null` if the client supports workspace folders but none are
 	 * configured.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
 	workspaceFolders?: WorkspaceFolder[] | null;
 }
 ```
-Where `ClientCapabilities`, `TextDocumentClientCapabilities` and `WorkspaceClientCapabilities` are defined as follows:
+Where `ClientCapabilities` and `TextDocumentClientCapabilities` are defined as follows:
 
-##### `WorkspaceClientCapabilities` define capabilities the editor / tool provides on the workspace:
-
-> New in version 3.13: `ResourceOperationKind` and `FailureHandlingKind` and the client capability `workspace.workspaceEdit.resourceOperations` as well as `workspace.workspaceEdit.failureHandling`.
-
-```typescript
-
-/**
- * The kind of resource operations supported by the client.
- */
-export type ResourceOperationKind = 'create' | 'rename' | 'delete';
-
-export namespace ResourceOperationKind {
-
-	/**
-	 * Supports creating new files and folders.
-	 */
-	export const Create: ResourceOperationKind = 'create';
-
-	/**
-	 * Supports renaming existing files and folders.
-	 */
-	export const Rename: ResourceOperationKind = 'rename';
-
-	/**
-	 * Supports deleting existing files and folders.
-	 */
-	export const Delete: ResourceOperationKind = 'delete';
-}
-
-export type FailureHandlingKind = 'abort' | 'transactional' | 'undo' | 'textOnlyTransactional';
-
-export namespace FailureHandlingKind {
-
-	/**
-	 * Applying the workspace change is simply aborted if one of the changes provided
-	 * fails. All operations executed before the failing operation stay executed.
-	 */
-	export const Abort: FailureHandlingKind = 'abort';
-
-	/**
-	 * All operations are executed transactionally. That means they either all
-	 * succeed or no changes at all are applied to the workspace.
-	 */
-	export const Transactional: FailureHandlingKind = 'transactional';
-
-
-	/**
-	 * If the workspace edit contains only textual file changes they are executed transactionally.
-	 * If resource changes (create, rename or delete file) are part of the change the failure
-	 * handling strategy is abort.
-	 */
-	export const TextOnlyTransactional: FailureHandlingKind = 'textOnlyTransactional';
-
-	/**
-	 * The client tries to undo the operations already executed. But there is no
-	 * guarantee that this succeeds.
-	 */
-	export const Undo: FailureHandlingKind = 'undo';
-}
-
-/**
- * Workspace specific client capabilities.
- */
-export interface WorkspaceClientCapabilities {
-	/**
-	 * The client supports applying batch edits to the workspace by supporting
-	 * the request 'workspace/applyEdit'
-	 */
-	applyEdit?: boolean;
-
-	/**
-	 * Capabilities specific to `WorkspaceEdit`s
-	 */
-	workspaceEdit?: {
-		/**
-		 * The client supports versioned document changes in `WorkspaceEdit`s
-		 */
-		documentChanges?: boolean;
-
-		/**
-		 * The resource operations the client supports. Clients should at least
-		 * support 'create', 'rename' and 'delete' files and folders.
-		 */
-		resourceOperations?: ResourceOperationKind[];
-
-		/**
-		 * The failure handling strategy of a client if applying the workspace edit
-		 * fails.
-		 */
-		failureHandling?: FailureHandlingKind;
-	};
-
-	/**
-	 * Capabilities specific to the `workspace/didChangeConfiguration` notification.
-	 */
-	didChangeConfiguration?: {
-		/**
-		 * Did change configuration notification supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `workspace/didChangeWatchedFiles` notification.
-	 */
-	didChangeWatchedFiles?: {
-		/**
-		 * Did change watched files notification supports dynamic registration. Please note
-		 * that the current protocol doesn't support static configuration for file changes
-		 * from the server side.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `workspace/symbol` request.
-	 */
-	symbol?: {
-		/**
-		 * Symbol request supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * Specific capabilities for the `SymbolKind` in the `workspace/symbol` request.
-		 */
-		symbolKind?: {
-			/**
-			 * The symbol kind values the client supports. When this
-			 * property exists the client also guarantees that it will
-			 * handle values outside its set gracefully and falls back
-			 * to a default value when unknown.
-			 *
-			 * If this property is not present the client only supports
-			 * the symbol kinds from `File` to `Array` as defined in
-			 * the initial version of the protocol.
-			 */
-			valueSet?: SymbolKind[];
-		}
-	};
-
-	/**
-	 * Capabilities specific to the `workspace/executeCommand` request.
-	 */
-	executeCommand?: {
-		/**
-		 * Execute command supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * The client has support for workspace folders.
-	 *
-	 * Since 3.6.0
-	 */
-	workspaceFolders?: boolean;
-
-	/**
-	 * The client supports `workspace/configuration` requests.
-	 *
-	 * Since 3.6.0
-	 */
-	configuration?: boolean;
-}
-```
 
 ##### `TextDocumentClientCapabilities` define capabilities the editor / tool provides on text documents.
 
@@ -1138,426 +1413,129 @@
  */
 export interface TextDocumentClientCapabilities {
 
-	synchronization?: {
-		/**
-		 * Whether text document synchronization supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports sending will save notifications.
-		 */
-		willSave?: boolean;
-
-		/**
-		 * The client supports sending a will save request and
-		 * waits for a response providing text edits which will
-		 * be applied to the document before it is saved.
-		 */
-		willSaveWaitUntil?: boolean;
-
-		/**
-		 * The client supports did save notifications.
-		 */
-		didSave?: boolean;
-	}
+	synchronization?: TextDocumentSyncClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/completion`
+	 * Capabilities specific to the `textDocument/completion` request.
 	 */
-	completion?: {
-		/**
-		 * Whether completion supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports the following `CompletionItem` specific
-		 * capabilities.
-		 */
-		completionItem?: {
-			/**
-			 * The client supports snippets as insert text.
-			 *
-			 * A snippet can define tab stops and placeholders with `$1`, `$2`
-			 * and `${3:foo}`. `$0` defines the final tab stop, it defaults to
-			 * the end of the snippet. Placeholders with equal identifiers are linked,
-			 * that is typing in one will update others too.
-			 */
-			snippetSupport?: boolean;
-
-			/**
-			 * The client supports commit characters on a completion item.
-			 */
-			commitCharactersSupport?: boolean
-
-			/**
-			 * The client supports the following content formats for the documentation
-			 * property. The order describes the preferred format of the client.
-			 */
-			documentationFormat?: MarkupKind[];
-
-			/**
-			 * The client supports the deprecated property on a completion item.
-			 */
-			deprecatedSupport?: boolean;
-
-			/**
-			 * The client supports the preselect property on a completion item.
-			 */
-			preselectSupport?: boolean;
-		}
-
-		completionItemKind?: {
-			/**
-			 * The completion item kind values the client supports. When this
-			 * property exists the client also guarantees that it will
-			 * handle values outside its set gracefully and falls back
-			 * to a default value when unknown.
-			 *
-			 * If this property is not present the client only supports
-			 * the completion items kinds from `Text` to `Reference` as defined in
-			 * the initial version of the protocol.
-			 */
-			valueSet?: CompletionItemKind[];
-		},
-
-		/**
-		 * The client supports to send additional context information for a
-		 * `textDocument/completion` request.
-		 */
-		contextSupport?: boolean;
-	};
+	completion?: CompletionClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/hover`
+	 * Capabilities specific to the `textDocument/hover` request.
 	 */
-	hover?: {
-		/**
-		 * Whether hover supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports the follow content formats for the content
-		 * property. The order describes the preferred format of the client.
-		 */
-		contentFormat?: MarkupKind[];
-	};
+	hover?: HoverClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/signatureHelp`
+	 * Capabilities specific to the `textDocument/signatureHelp` request.
 	 */
-	signatureHelp?: {
-		/**
-		 * Whether signature help supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports the following `SignatureInformation`
-		 * specific properties.
-		 */
-		signatureInformation?: {
-			/**
-			 * The client supports the follow content formats for the documentation
-			 * property. The order describes the preferred format of the client.
-			 */
-			documentationFormat?: MarkupKind[];
-
-			/**
-			 * Client capabilities specific to parameter information.
-			 */
-			parameterInformation?: {
-				/**
-				 * The client supports processing label offsets instead of a
-				 * simple label string.
-				 *
-				 * Since 3.14.0
-				 */
-				labelOffsetSupport?: boolean;
-			}
-		};
-	};
+	signatureHelp?: SignatureHelpClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/references`
-	 */
-	references?: {
-		/**
-		 * Whether references supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/documentHighlight`
-	 */
-	documentHighlight?: {
-		/**
-		 * Whether document highlight supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/documentSymbol`
-	 */
-	documentSymbol?: {
-		/**
-		 * Whether document symbol supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * Specific capabilities for the `SymbolKind`.
-		 */
-		symbolKind?: {
-			/**
-			 * The symbol kind values the client supports. When this
-			 * property exists the client also guarantees that it will
-			 * handle values outside its set gracefully and falls back
-			 * to a default value when unknown.
-			 *
-			 * If this property is not present the client only supports
-			 * the symbol kinds from `File` to `Array` as defined in
-			 * the initial version of the protocol.
-			 */
-			valueSet?: SymbolKind[];
-		}
-
-		/**
-		 * The client supports hierarchical document symbols.
-		 */
-		hierarchicalDocumentSymbolSupport?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/formatting`
-	 */
-	formatting?: {
-		/**
-		 * Whether formatting supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/rangeFormatting`
-	 */
-	rangeFormatting?: {
-		/**
-		 * Whether range formatting supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/onTypeFormatting`
-	 */
-	onTypeFormatting?: {
-		/**
-		 * Whether on type formatting supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
-
-	/**
-		* Capabilities specific to the `textDocument/declaration`
-		*/
-	declaration?: {
-		/**
-		 * Whether declaration supports dynamic registration. If this is set to `true`
-		 * the client supports the new `(TextDocumentRegistrationOptions & StaticRegistrationOptions)`
-		 * return value for the corresponding server capability as well.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports additional metadata in the form of declaration links.
-		 *
-		 * Since 3.14.0
-		 */
-		linkSupport?: boolean;
-	};
-
-	/**
-	 * Capabilities specific to the `textDocument/definition`.
+	 * Capabilities specific to the `textDocument/declaration` request.
 	 *
-	 * Since 3.14.0
+	 * @since 3.14.0
 	 */
-	definition?: {
-		/**
-		 * Whether definition supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports additional metadata in the form of definition links.
-		 */
-		linkSupport?: boolean;
-	};
+	declaration?: DeclarationClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/typeDefinition`
+	 * Capabilities specific to the `textDocument/definition` request.
+	 */
+	definition?: DefinitionClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/typeDefinition` request.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
-	typeDefinition?: {
-		/**
-		 * Whether typeDefinition supports dynamic registration. If this is set to `true`
-		 * the client supports the new `(TextDocumentRegistrationOptions & StaticRegistrationOptions)`
-		 * return value for the corresponding server capability as well.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports additional metadata in the form of definition links.
-		 *
-		 * Since 3.14.0
-		 */
-		linkSupport?: boolean;
-	};
+	typeDefinition?: TypeDefinitionClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/implementation`.
+	 * Capabilities specific to the `textDocument/implementation` request.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
-	implementation?: {
-		/**
-		 * Whether implementation supports dynamic registration. If this is set to `true`
-		 * the client supports the new `(TextDocumentRegistrationOptions & StaticRegistrationOptions)`
-		 * return value for the corresponding server capability as well.
-		 */
-		dynamicRegistration?: boolean;
-
-		/**
-		 * The client supports additional metadata in the form of definition links.
-		 *
-		 * Since 3.14.0
-		 */
-		linkSupport?: boolean;
-	};
+	implementation?: ImplementationClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/codeAction`
+	 * Capabilities specific to the `textDocument/references` request.
 	 */
-	codeAction?: {
-		/**
-		 * Whether code action supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-		/**
-		 * The client support code action literals as a valid
-		 * response of the `textDocument/codeAction` request.
-		 *
-		 * Since 3.8.0
-		 */
-		codeActionLiteralSupport?: {
-			/**
-			 * The code action kind is support with the following value
-			 * set.
-			 */
-			codeActionKind: {
-
-				/**
-				 * The code action kind values the client supports. When this
-				 * property exists the client also guarantees that it will
-				 * handle values outside its set gracefully and falls back
-				 * to a default value when unknown.
-				 */
-				valueSet: CodeActionKind[];
-			};
-		};
-	};
+	references?: ReferenceClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/codeLens`
+	 * Capabilities specific to the `textDocument/documentHighlight` request.
 	 */
-	codeLens?: {
-		/**
-		 * Whether code lens supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
+	documentHighlight?: DocumentHighlightClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/documentLink`
+	 * Capabilities specific to the `textDocument/documentSymbol` request.
 	 */
-	documentLink?: {
-		/**
-		 * Whether document link supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-	};
+	documentSymbol?: DocumentSymbolClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/codeAction` request.
+	 */
+	codeAction?: CodeActionClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/codeLens` request.
+	 */
+	codeLens?: CodeLensClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/documentLink` request.
+	 */
+	documentLink?: DocumentLinkClientCapabilities;
 
 	/**
 	 * Capabilities specific to the `textDocument/documentColor` and the
 	 * `textDocument/colorPresentation` request.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
-	colorProvider?: {
-		/**
-		 * Whether colorProvider supports dynamic registration. If this is set to `true`
-		 * the client supports the new `(ColorProviderOptions & TextDocumentRegistrationOptions & StaticRegistrationOptions)`
-		 * return value for the corresponding server capability as well.
-		 */
-		dynamicRegistration?: boolean;
-	}
+	colorProvider?: DocumentColorClientCapabilities;
 
 	/**
-	 * Capabilities specific to the `textDocument/rename`
+	 * Capabilities specific to the `textDocument/formatting` request.
 	 */
-	rename?: {
-		/**
-		 * Whether rename supports dynamic registration.
-		 */
-		dynamicRegistration?: boolean;
-		/**
-		 * The client supports testing for validity of rename operations
-		 * before execution.
-		 */
-		prepareSupport?: boolean;
-	};
+	formatting?: DocumentFormattingClientCapabilities
 
 	/**
-	 * Capabilities specific to `textDocument/publishDiagnostics`.
+	 * Capabilities specific to the `textDocument/rangeFormatting` request.
 	 */
-	publishDiagnostics?: {
-		/**
-		 * Whether the clients accepts diagnostics with related information.
-		 */
-		relatedInformation?: boolean;
-	};
+	rangeFormatting?: DocumentRangeFormattingClientCapabilities;
+
+	/** request.
+	 * Capabilities specific to the `textDocument/onTypeFormatting` request.
+	 */
+	onTypeFormatting?: DocumentOnTypeFormattingClientCapabilities;
+
 	/**
-	 * Capabilities specific to `textDocument/foldingRange` requests.
+	 * Capabilities specific to the `textDocument/rename` request.
+	 */
+	rename?: RenameClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/publishDiagnostics` notification.
+	 */
+	publishDiagnostics?: PublishDiagnosticsClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/foldingRange` request.
 	 *
-	 * Since 3.10.0
+	 * @since 3.10.0
 	 */
-	foldingRange?: {
-		/**
-		 * Whether implementation supports dynamic registration for folding range providers. If this is set to `true`
-		 * the client supports the new `(FoldingRangeProviderOptions & TextDocumentRegistrationOptions & StaticRegistrationOptions)`
-		 * return value for the corresponding server capability as well.
-		 */
-		dynamicRegistration?: boolean;
-		/**
-		 * The maximum number of folding ranges that the client prefers to receive per document. The value serves as a
-		 * hint, servers are free to follow the limit.
-		 */
-		rangeLimit?: number;
-		/**
-		 * If set, the client signals that it only supports folding complete lines. If set, client will
-		 * ignore specified `startCharacter` and `endCharacter` properties in a FoldingRange.
-		 */
-		lineFoldingOnly?: boolean;
-	};
+	foldingRange?: FoldingRangeClientCapabilities;
+
+	/**
+	 * Capabilities specific to the `textDocument/selectionRange` request.
+	 *
+	 * @since 3.15.0
+	 */
+	selectionRange?: SelectionRangeClientCapabilities;
 }
 ```
 
-`ClientCapabilities` now define capabilities for dynamic registration, workspace and text document features the client supports. The `experimental` can be used to pass experimental capabilities under development. For future compatibility a `ClientCapabilities` object literal can have more properties set than currently defined. Servers receiving a `ClientCapabilities` object literal with unknown properties should ignore these properties. A missing property should be interpreted as an absence of the capability. If a missing property normally defines sub properties, all missing sub properties should be interpreted as an absence of the corresponding capability.
+`ClientCapabilities` define capabilities for dynamic registration, workspace and text document features the client supports. The `experimental` can be used to pass experimental capabilities under development. For future compatibility a `ClientCapabilities` object literal can have more properties set than currently defined. Servers receiving a `ClientCapabilities` object literal with unknown properties should ignore these properties. A missing property should be interpreted as an absence of the capability. If a missing property normally defines sub properties, all missing sub properties should be interpreted as an absence of the corresponding capability.
 
 Client capabilities got introduced with version 3.0 of the protocol. They therefore only describe capabilities that got introduced in 3.x or later. Capabilities that existed in the 2.x version of the protocol are still mandatory for clients. Clients cannot opt out of providing them. So even if a client omits the `ClientCapabilities.textDocument.synchronization` it is still required that the client provides text document synchronization (e.g. open, changed and close notifications).
 
@@ -1566,7 +1544,53 @@
 	/**
 	 * Workspace specific client capabilities.
 	 */
-	workspace?: WorkspaceClientCapabilities;
+	workspace?: {
+		/**
+		* The client supports applying batch edits
+		* to the workspace by supporting the request
+		* 'workspace/applyEdit'
+		*/
+		applyEdit?: boolean;
+
+		/**
+		* Capabilities specific to `WorkspaceEdit`s
+		*/
+		workspaceEdit?: WorkspaceEditClientCapabilities;
+
+		/**
+		* Capabilities specific to the `workspace/didChangeConfiguration` notification.
+		*/
+		didChangeConfiguration?: DidChangeConfigurationClientCapabilities;
+
+		/**
+		* Capabilities specific to the `workspace/didChangeWatchedFiles` notification.
+		*/
+		didChangeWatchedFiles?: DidChangeWatchedFilesClientCapabilities;
+
+		/**
+		* Capabilities specific to the `workspace/symbol` request.
+		*/
+		symbol?: WorkspaceSymbolClientCapabilities;
+
+		/**
+		* Capabilities specific to the `workspace/executeCommand` request.
+		*/
+		executeCommand?: ExecuteCommandClientCapabilities;
+
+		/**
+		* The client has support for workspace folders.
+		*
+		* Since 3.6.0
+		*/
+		workspaceFolders?: boolean;
+
+		/**
+		* The client supports `workspace/configuration` requests.
+		*
+		* Since 3.6.0
+		*/
+		configuration?: boolean;
+	};
 
 	/**
 	 * Text document specific client capabilities.
@@ -1574,6 +1598,19 @@
 	textDocument?: TextDocumentClientCapabilities;
 
 	/**
+	 * Window specific client capabilities.
+	 */
+	window?: {
+		/**
+		 * Whether client supports handling progress notifications. If set servers are allowed to
+		 * report in `workDoneProgress` property in the request specific server capabilities.
+		 *
+		 * Since 3.15.0
+		 */
+		workDoneProgress?: boolean;
+	}
+
+	/**
 	 * Experimental client capabilities.
 	 */
 	experimental?: any;
@@ -1589,6 +1626,23 @@
 	 * The capabilities the language server provides.
 	 */
 	capabilities: ServerCapabilities;
+
+	/**
+	 * Information about the server.
+	 *
+	 * @since 3.15.0
+	 */
+	serverInfo?: {
+		/**
+		 * The name of the server as defined by the server.
+		 */
+		name: string;
+
+		/**
+		 * The server's version as defined by the server.
+		 */
+		version?: string;
+	};
 }
 ```
 * error.code:
@@ -1624,288 +1678,139 @@
 The server can signal the following capabilities:
 
 ```typescript
-/**
- * Defines how the host (editor) should sync document changes to the language server.
- */
-export namespace TextDocumentSyncKind {
-	/**
-	 * Documents should not be synced at all.
-	 */
-	export const None = 0;
-
-	/**
-	 * Documents are synced by always sending the full content
-	 * of the document.
-	 */
-	export const Full = 1;
-
-	/**
-	 * Documents are synced by sending the full content on open.
-	 * After that only incremental updates to the document are
-	 * send.
-	 */
-	export const Incremental = 2;
-}
-
-/**
- * Completion options.
- */
-export interface CompletionOptions {
-	/**
-	 * The server provides support to resolve additional
-	 * information for a completion item.
-	 */
-	resolveProvider?: boolean;
-
-	/**
-	 * The characters that trigger completion automatically.
-	 */
-	triggerCharacters?: string[];
-}
-/**
- * Signature help options.
- */
-export interface SignatureHelpOptions {
-	/**
-	 * The characters that trigger signature help
-	 * automatically.
-	 */
-	triggerCharacters?: string[];
-}
-
-/**
- * Code Action options.
- */
-export interface CodeActionOptions {
-	/**
-	 * CodeActionKinds that this server may return.
-	 *
-	 * The list of kinds may be generic, such as `CodeActionKind.Refactor`, or the server
-	 * may list out every specific kind they provide.
-	 */
-	codeActionKinds?: CodeActionKind[];
-}
-
-/**
- * Code Lens options.
- */
-export interface CodeLensOptions {
-	/**
-	 * Code lens has a resolve provider as well.
-	 */
-	resolveProvider?: boolean;
-}
-
-/**
- * Format document on type options.
- */
-export interface DocumentOnTypeFormattingOptions {
-	/**
-	 * A character on which formatting should be triggered, like `}`.
-	 */
-	firstTriggerCharacter: string;
-
-	/**
-	 * More trigger characters.
-	 */
-	moreTriggerCharacter?: string[];
-}
-
-/**
- * Rename options
- */
-export interface RenameOptions {
-	/**
-	 * Renames should be checked and tested before being executed.
-	 */
-	prepareProvider?: boolean;
-}
-
-/**
- * Document link options.
- */
-export interface DocumentLinkOptions {
-	/**
-	 * Document links have a resolve provider as well.
-	 */
-	resolveProvider?: boolean;
-}
-
-/**
- * Execute command options.
- */
-export interface ExecuteCommandOptions {
-	/**
-	 * The commands to be executed on the server
-	 */
-	commands: string[]
-}
-
-/**
- * Save options.
- */
-export interface SaveOptions {
-	/**
-	 * The client is supposed to include the content on save.
-	 */
-	includeText?: boolean;
-}
-
-/**
- * Color provider options.
- */
-export interface ColorProviderOptions {
-}
-
-/**
- * Folding range provider options.
- */
-export interface FoldingRangeProviderOptions {
-}
-
-export interface TextDocumentSyncOptions {
-	/**
-	 * Open and close notifications are sent to the server. If omitted open close notification should not
-	 * be sent.
-	 */
-	openClose?: boolean;
-	/**
-	 * Change notifications are sent to the server. See TextDocumentSyncKind.None, TextDocumentSyncKind.Full
-	 * and TextDocumentSyncKind.Incremental. If omitted it defaults to TextDocumentSyncKind.None.
-	 */
-	change?: number;
-	/**
-	 * If present will save notifications are sent to the server. If omitted the notification should not be
-	 * sent.
-	 */
-	willSave?: boolean;
-	/**
-	 * If present will save wait until requests are sent to the server. If omitted the request should not be
-	 * sent.
-	 */
-	willSaveWaitUntil?: boolean;
-	/**
-	 * If present save notifications are sent to the server. If omitted the notification should not be
-	 * sent.
-	 */
-	save?: SaveOptions;
-}
-
-/**
- * Static registration options to be returned in the initialize request.
- */
-interface StaticRegistrationOptions {
-	/**
-	 * The id used to register the request. The id can be used to deregister
-	 * the request again. See also Registration#id.
-	 */
-	id?: string;
-}
-
 interface ServerCapabilities {
 	/**
 	 * Defines how text documents are synced. Is either a detailed structure defining each notification or
 	 * for backwards compatibility the TextDocumentSyncKind number. If omitted it defaults to `TextDocumentSyncKind.None`.
 	 */
 	textDocumentSync?: TextDocumentSyncOptions | number;
-	/**
-	 * The server provides hover support.
-	 */
-	hoverProvider?: boolean;
+
 	/**
 	 * The server provides completion support.
 	 */
 	completionProvider?: CompletionOptions;
+
+	/**
+	 * The server provides hover support.
+	 */
+	hoverProvider?: boolean | HoverOptions;
+
 	/**
 	 * The server provides signature help support.
 	 */
 	signatureHelpProvider?: SignatureHelpOptions;
+
+	/**
+	 * The server provides go to declaration support.
+	 *
+	 * @since 3.14.0
+	 */
+	declarationProvider?: boolean | DeclarationOptions | DeclarationRegistrationOptions;
+
 	/**
 	 * The server provides goto definition support.
 	 */
-	definitionProvider?: boolean;
+	definitionProvider?: boolean | DefinitionOptions;
+
 	/**
-	 * The server provides Goto Type Definition support.
+	 * The server provides goto type definition support.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
-	typeDefinitionProvider?: boolean | (TextDocumentRegistrationOptions & StaticRegistrationOptions);
+	typeDefinitionProvider?: boolean | TypeDefinitionOptions | TypeDefinitionRegistrationOptions;
+
 	/**
-	 * The server provides Goto Implementation support.
+	 * The server provides goto implementation support.
 	 *
-	 * Since 3.6.0
+	 * @since 3.6.0
 	 */
-	implementationProvider?: boolean | (TextDocumentRegistrationOptions & StaticRegistrationOptions);
+	implementationProvider?: boolean | ImplementationOptions | ImplementationRegistrationOptions;
+
 	/**
 	 * The server provides find references support.
 	 */
-	referencesProvider?: boolean;
+	referencesProvider?: boolean | ReferenceOptions;
+
 	/**
 	 * The server provides document highlight support.
 	 */
-	documentHighlightProvider?: boolean;
+	documentHighlightProvider?: boolean | DocumentHighlightOptions;
+
 	/**
 	 * The server provides document symbol support.
 	 */
-	documentSymbolProvider?: boolean;
-	/**
-	 * The server provides workspace symbol support.
-	 */
-	workspaceSymbolProvider?: boolean;
+	documentSymbolProvider?: boolean | DocumentSymbolOptions;
+
 	/**
 	 * The server provides code actions. The `CodeActionOptions` return type is only
 	 * valid if the client signals code action literal support via the property
 	 * `textDocument.codeAction.codeActionLiteralSupport`.
 	 */
 	codeActionProvider?: boolean | CodeActionOptions;
+
 	/**
 	 * The server provides code lens.
 	 */
 	codeLensProvider?: CodeLensOptions;
+
+	/**
+	 * The server provides document link support.
+	 */
+	documentLinkProvider?: DocumentLinkOptions;
+
+	/**
+	 * The server provides color provider support.
+	 *
+	 * @since 3.6.0
+	 */
+	colorProvider?: boolean | DocumentColorOptions | DocumentColorRegistrationOptions;
+
 	/**
 	 * The server provides document formatting.
 	 */
-	documentFormattingProvider?: boolean;
+	documentFormattingProvider?: boolean | DocumentFormattingOptions;
+
 	/**
 	 * The server provides document range formatting.
 	 */
-	documentRangeFormattingProvider?: boolean;
+	documentRangeFormattingProvider?: boolean | DocumentRangeFormattingOptions;
+
 	/**
 	 * The server provides document formatting on typing.
 	 */
 	documentOnTypeFormattingProvider?: DocumentOnTypeFormattingOptions;
+
 	/**
 	 * The server provides rename support. RenameOptions may only be
 	 * specified if the client states that it supports
 	 * `prepareSupport` in its initial `initialize` request.
 	 */
 	renameProvider?: boolean | RenameOptions;
-	/**
-	 * The server provides document link support.
-	 */
-	documentLinkProvider?: DocumentLinkOptions;
-	/**
-	 * The server provides color provider support.
-	 *
-	 * Since 3.6.0
-	 */
-	colorProvider?: boolean | ColorProviderOptions | (ColorProviderOptions & TextDocumentRegistrationOptions & StaticRegistrationOptions);
+
 	/**
 	 * The server provides folding provider support.
 	 *
-	 * Since 3.10.0
+	 * @since 3.10.0
 	 */
-	foldingRangeProvider?: boolean | FoldingRangeProviderOptions | (FoldingRangeProviderOptions & TextDocumentRegistrationOptions & StaticRegistrationOptions);
-	/**
-	 * The server provides go to declaration support.
-	 *
-	 * Since 3.14.0
-	 */
-	declarationProvider?: boolean | (TextDocumentRegistrationOptions & StaticRegistrationOptions);
+	foldingRangeProvider?: boolean | FoldingRangeOptions | FoldingRangeRegistrationOptions;
+
 	/**
 	 * The server provides execute command support.
 	 */
 	executeCommandProvider?: ExecuteCommandOptions;
+
+	/**
+	 * The server provides selection range support.
+	 *
+	 * @since 3.15.0
+	 */
+	selectionRangeProvider?: boolean | SelectionRangeOptions | SelectionRangeRegistrationOptions;
+
+	/**
+	 * The server provides workspace symbol support.
+	 */
+	workspaceSymbolProvider?: boolean;
+
 	/**
 	 * Workspace specific server capabilities
 	 */
@@ -1913,25 +1818,11 @@
 		/**
 		 * The server supports workspace folder.
 		 *
-		 * Since 3.6.0
+		 * @since 3.6.0
 		 */
-		workspaceFolders?: {
-			/**
-			* The server has support for workspace folders
-			*/
-			supported?: boolean;
-			/**
-			* Whether the server wants to receive workspace folder
-			* change notifications.
-			*
-			* If a strings is provided the string is treated as a ID
-			* under which the notification is registered on the client
-			* side. The ID can be used to unregister for these events
-			* using the `client/unregisterCapability` request.
-			*/
-			changeNotifications?: string | boolean;
-		}
+		workspaceFolders?: WorkspaceFoldersServerCapabilities;
 	}
+
 	/**
 	 * Experimental server capabilities.
 	 */
@@ -1954,7 +1845,7 @@
 
 #### <a href="#shutdown" name="shutdown" class="anchor">Shutdown Request (:leftwards_arrow_with_hook:)</a>
 
-The shutdown request is sent from the client to the server. It asks the server to shut down, but to not exit (otherwise the response might not be delivered correctly to the client). There is a separate exit notification that asks the server to exit. Clients must not send any notifications other than `exit` or requests to a server to which they have sent a shutdown requests. If a server receives requests after a shutdown request those requests should be errored with `InvalidRequest`.
+The shutdown request is sent from the client to the server. It asks the server to shut down, but to not exit (otherwise the response might not be delivered correctly to the client). There is a separate exit notification that asks the server to exit. Clients must not send any notifications other than `exit` or requests to a server to which they have sent a shutdown request. If a server receives requests after a shutdown request those requests should error with `InvalidRequest`.
 
 _Request_:
 * method: 'shutdown'
@@ -2082,7 +1973,46 @@
 }
 ```
 
-Where type is defined as above.
+#### <a href="#window_workDoneProgress_create" name="window_workDoneProgress_create" class="anchor"> Creating Work Done Progress (:arrow_right_hook:)</a>
+
+The `window/workDoneProgress/create` request is sent from the server to the client to ask the client to create a work done progress.
+
+_Request_:
+
+* method: 'window/workDoneProgress/create'
+* params: `WorkDoneProgressCreateParams` defined as follows:
+
+```typescript
+export interface WorkDoneProgressCreateParams {
+	/**
+	 * The token to be used to report progress.
+	 */
+	token: ProgressToken;
+}
+```
+
+_Response_:
+
+* result: void
+* error: code and message set in case an exception happens during the 'window/workDoneProgress/create' request. In case an error occurs a server must not send any progress notification using the token provided in the `WorkDoneProgressCreateParams`.
+
+#### <a href="#window_workDoneProgress_cancel" name="window_workDoneProgress_cancel" class="anchor"> Canceling a Work Done Progress (:arrow_right:)</a>
+
+The `window/workDoneProgress/cancel` notification is sent from the client to the server to cancel a progress initiated on the server side using the `window/workDoneProgress/create`.
+
+_Notification_:
+
+* method: 'window/workDoneProgress/cancel'
+* params: `WorkDoneProgressCancelParams` defined as follows:
+
+```typescript
+export interface WorkDoneProgressCancelParams {
+	/**
+	 * The token to be used to report progress.
+	 */
+	token: ProgressToken;
+}
+```
 
 #### <a href="#telemetry_event" name="telemetry_event" class="anchor">Telemetry Notification (:arrow_left:)</a>
 
@@ -2096,6 +2026,8 @@
 
 The `client/registerCapability` request is sent from the server to the client to register for a new capability on the client side. Not all clients need to support dynamic capability registration. A client opts in via the `dynamicRegistration` property on the specific client capabilities. A client can even provide dynamic registration for capability A but not for capability B (see `TextDocumentClientCapabilities` as an example).
 
+Server must not register the same capability both statically through the initialize result and dynamically for the same document selector. If a server wants to support both static and dynamic registration it needs to check the client capability in the initialize request and only register the capability statically if the client doesn't support dynamic registration for that capability.
+
 _Request_:
 * method: 'client/registerCapability'
 * params: `RegistrationParams`
@@ -2129,17 +2061,7 @@
 }
 ```
 
-Since most of the registration options require to specify a document selector there is a base interface that can be used.
-
-```typescript
-export interface TextDocumentRegistrationOptions {
-	/**
-	 * A document selector to identify the scope of the registration. If set to null
-	 * the document selector provided on the client side will be used.
-	 */
-	documentSelector: DocumentSelector | null;
-}
-```
+Since most of the registration options require to specify a document selector there is a base interface that can be used. See `TextDocumentRegistrationOptions`.
 
 An example JSON RPC message to register dynamically for the `textDocument/willSaveWaitUntil` feature on the client side is as follows (only details shown):
 
@@ -2196,6 +2118,9 @@
 }
 
 export interface UnregistrationParams {
+	// This should correctly be named `unregistrations`. However changing this
+	// is a breaking change and needs to wait until we deliver a 4.x version
+	// of the specification.
 	unregisterations: Unregistration[];
 }
 ```
@@ -2227,13 +2152,39 @@
 
 The `workspace/workspaceFolders` request is sent from the server to the client to fetch the current open list of workspace folders. Returns `null` in the response if only a single file is open in the tool. Returns an empty array if a workspace is open but no folders are configured.
 
-_Request_:
+_Client Capability_:
+* property path (optional): `workspace.workspaceFolders`
+* property type: `boolean`
 
+_Server Capability_:
+* property path (optional): `workspace.workspaceFolders`
+* property type: `WorkspaceFoldersServerCapabilities` defined as follows:
+
+```typescript
+export interface WorkspaceFoldersServerCapabilities {
+	/**
+	 * The server has support for workspace folders
+	 */
+	supported?: boolean;
+
+	/**
+	 * Whether the server wants to receive workspace folder
+	 * change notifications.
+	 *
+	 * If a string is provided, the string is treated as an ID
+	 * under which the notification is registered on the client
+	 * side. The ID can be used to unregister for these events
+	 * using the `client/unregisterCapability` request.
+	 */
+	changeNotifications?: string | boolean;
+}
+```
+
+_Request_:
 * method: 'workspace/workspaceFolders'
 * params: none
 
 _Response_:
-
 * result: `WorkspaceFolder[] | null` defined as follows:
 
 ```typescript
@@ -2256,7 +2207,7 @@
 
 > *Since version 3.6.0*
 
-The `workspace/didChangeWorkspaceFolders` notification is sent from the client to the server to inform the server about workspace folder configuration changes. The notification is sent by default if both _ServerCapabilities/workspace/workspaceFolders_ and _ClientCapabilities/workspace/workspaceFolders_ are true; or if the server has registered itself to receive this notification. To register for the `workspace/didChangeWorkspaceFolders` send a `client/registerCapability` request from the server to the client. The registration parameter must have a `registrations` item of the following form, where `id` is a unique id used to unregister the capability (the example uses a UUID):
+The `workspace/didChangeWorkspaceFolders` notification is sent from the client to the server to inform the server about workspace folder configuration changes. The notification is sent by default if both _client capability_ `workspace.workspaceFolders` and the _server capability_ `workspace.workspaceFolders.supported` are true; or if the server has registered itself to receive this notification. To register for the `workspace/didChangeWorkspaceFolders` send a `client/registerCapability` request from the server to the client. The registration parameter must have a `registrations` item of the following form, where `id` is a unique id used to unregister the capability (the example uses a UUID):
 ```ts
 {
 	id: "28c6150c-bd7b-11e7-abc4-cec278b6b50a",
@@ -2265,7 +2216,6 @@
 ```
 
 _Notification_:
-
 * method: 'workspace/didChangeWorkspaceFolders'
 * params: `DidChangeWorkspaceFoldersParams` defined as follows:
 
@@ -2297,6 +2247,19 @@
 
 A notification sent from the client to the server to signal the change of configuration settings.
 
+_Client Capability_:
+* property path (optional): `workspace.didChangeConfiguration`
+* property type: `DidChangeConfigurationClientCapabilities` defined as follows:
+
+```typescript
+export interface DidChangeConfigurationClientCapabilities {
+	/**
+	 * Did change configuration notification supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
 _Notification_:
 * method: 'workspace/didChangeConfiguration',
 * params: `DidChangeConfigurationParams` defined as follows:
@@ -2318,8 +2281,11 @@
 
 A `ConfigurationItem` consists of the configuration section to ask for and an additional scope URI. The configuration section ask for is defined by the server and doesn't necessarily need to correspond to the configuration store used be the client. So a server might ask for a configuration `cpp.formatterOptions` but the client stores the configuration in a XML store layout differently. It is up to the client to do the necessary conversion. If a scope URI is provided the client should return the setting scoped to the provided resource. If the client for example uses [EditorConfig](http://editorconfig.org/) to manage its settings the configuration should be returned for the passed resource URI. If the client can't provide a configuration setting for a given scope then `null` need to be present in the returned array.
 
-_Request_:
+_Client Capability_:
+* property path (optional): `workspace.configuration`
+* property type: `boolean`
 
+_Request_:
 * method: 'workspace/configuration'
 * params: `ConfigurationParams` defined as follows
 
@@ -2356,58 +2322,22 @@
 - a client usually starts more than one server. If every server runs its own file watching it can become a CPU or memory problem.
 - in general there are more server than client implementations. So this problem is better solved on the client side.
 
-
-_Notification_:
-* method: 'workspace/didChangeWatchedFiles'
-* params: `DidChangeWatchedFilesParams` defined as follows:
+_Client Capability_:
+* property path (optional): `workspace.didChangeWatchedFiles`
+* property type: `DidChangeWatchedFilesClientCapabilities` defined as follows:
 
 ```typescript
-interface DidChangeWatchedFilesParams {
+export interface DidChangeWatchedFilesClientCapabilities {
 	/**
-	 * The actual file events.
+	 * Did change watched files notification supports dynamic registration. Please note
+	 * that the current protocol doesn't support static configuration for file changes
+	 * from the server side.
 	 */
-	changes: FileEvent[];
+	dynamicRegistration?: boolean;
 }
 ```
 
-Where FileEvents are described as follows:
-
-```typescript
-/**
- * An event describing a file change.
- */
-interface FileEvent {
-	/**
-	 * The file's URI.
-	 */
-	uri: DocumentUri;
-	/**
-	 * The change type.
-	 */
-	type: number;
-}
-
-/**
- * The file event type.
- */
-export namespace FileChangeType {
-	/**
-	 * The file got created.
-	 */
-	export const Created = 1;
-	/**
-	 * The file got changed.
-	 */
-	export const Changed = 2;
-	/**
-	 * The file got deleted.
-	 */
-	export const Deleted = 3;
-}
-```
-
-_Registration Options_: `DidChangeWatchedFilesRegistrationOptions` defined as follows
-
+_Registration Options_: `DidChangeWatchedFilesRegistrationOptions` defined as follows:
 ```typescript
 /**
  * Describe options to be used when registering for file system change events.
@@ -2459,10 +2389,104 @@
 }
 ```
 
+_Notification_:
+* method: 'workspace/didChangeWatchedFiles'
+* params: `DidChangeWatchedFilesParams` defined as follows:
+
+```typescript
+interface DidChangeWatchedFilesParams {
+	/**
+	 * The actual file events.
+	 */
+	changes: FileEvent[];
+}
+```
+
+Where FileEvents are described as follows:
+
+```typescript
+/**
+ * An event describing a file change.
+ */
+interface FileEvent {
+	/**
+	 * The file's URI.
+	 */
+	uri: DocumentUri;
+	/**
+	 * The change type.
+	 */
+	type: number;
+}
+
+/**
+ * The file event type.
+ */
+export namespace FileChangeType {
+	/**
+	 * The file got created.
+	 */
+	export const Created = 1;
+	/**
+	 * The file got changed.
+	 */
+	export const Changed = 2;
+	/**
+	 * The file got deleted.
+	 */
+	export const Deleted = 3;
+}
+```
+
 #### <a href="#workspace_symbol" name="workspace_symbol" class="anchor">Workspace Symbols Request (:leftwards_arrow_with_hook:)</a>
 
 The workspace symbol request is sent from the client to the server to list project-wide symbols matching the query string.
 
+_Client Capability_:
+* property path (optional): `workspace.symbol`
+* property type: `WorkspaceSymbolClientCapabilities` defined as follows:
+
+```typescript
+interface WorkspaceSymbolClientCapabilities {
+	/**
+	 * Symbol request supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * Specific capabilities for the `SymbolKind` in the `workspace/symbol` request.
+	 */
+	symbolKind?: {
+		/**
+		 * The symbol kind values the client supports. When this
+		 * property exists the client also guarantees that it will
+		 * handle values outside its set gracefully and falls back
+		 * to a default value when unknown.
+		 *
+		 * If this property is not present the client only supports
+		 * the symbol kinds from `File` to `Array` as defined in
+		 * the initial version of the protocol.
+		 */
+		valueSet?: SymbolKind[];
+	}
+}
+```
+
+_Server Capability_:
+* property path (optional): `workspaceSymbolProvider`
+* property type: `boolean | WorkspaceSymbolOptions` where `WorkspaceSymbolOptions` is defined as follows:
+
+```typescript
+export interface WorkspaceSymbolOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `WorkspaceSymbolRegistrationOptions` defined as follows:
+```typescript
+export interface WorkspaceSymbolRegistrationOptions extends WorkspaceSymbolOptions {
+}
+```
+
 _Request_:
 * method: 'workspace/symbol'
 * params: `WorkspaceSymbolParams` defined as follows:
@@ -2471,9 +2495,10 @@
 /**
  * The parameters of a Workspace Symbol Request.
  */
-interface WorkspaceSymbolParams {
+interface WorkspaceSymbolParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
-	 * A non-empty query string
+	 * A query string to filter symbols by. Clients may send an empty
+	 * string here to request all symbols.
 	 */
 	query: string;
 }
@@ -2481,23 +2506,56 @@
 
 _Response_:
 * result: `SymbolInformation[]` \| `null` as defined above.
+* partial result: `SymbolInformation[]` as defined above.
 * error: code and message set in case an exception happens during the workspace symbol request.
 
-_Registration Options_: void
-
-
 #### <a href="#workspace_executeCommand" name="workspace_executeCommand" class="anchor">Execute a command (:leftwards_arrow_with_hook:)</a>
 
 The `workspace/executeCommand` request is sent from the client to the server to trigger command execution on the server. In most cases
 the server creates a `WorkspaceEdit` structure and applies the changes to the workspace using the request `workspace/applyEdit` which is
 sent from the server to the client.
 
+_Client Capability_:
+* property path (optional): `workspace.executeCommand`
+* property type: `ExecuteCommandClientCapabilities` defined as follows:
+
+```typescript
+export interface ExecuteCommandClientCapabilities {
+	/**
+	 * Execute command supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property path (optional): `executeCommandProvider`
+* property type: `ExecuteCommandOptions` defined as follows:
+
+```typescript
+export interface ExecuteCommandOptions extends WorkDoneProgressOptions {
+	/**
+	 * The commands to be executed on the server
+	 */
+	commands: string[]
+}
+```
+
+_Registration Options_: `ExecuteCommandRegistrationOptions` defined as follows:
+```typescript
+/**
+ * Execute command registration options.
+ */
+export interface ExecuteCommandRegistrationOptions extends ExecuteCommandOptions {
+}
+```
+
 _Request:_
 * method: 'workspace/executeCommand'
 * params: `ExecuteCommandParams` defined as follows:
 
 ```typescript
-export interface ExecuteCommandParams {
+export interface ExecuteCommandParams extends WorkDoneProgressParams {
 
 	/**
 	 * The identifier of the actual command handler.
@@ -2516,25 +2574,16 @@
 * result: `any` \| `null`
 * error: code and message set in case an exception happens during the request.
 
-_Registration Options_: `ExecuteCommandRegistrationOptions` defined as follows:
-
-```typescript
-/**
- * Execute command registration options.
- */
-export interface ExecuteCommandRegistrationOptions {
-	/**
-	 * The commands to be executed on the server
-	 */
-	commands: string[]
-}
-```
-
-
 #### <a href="#workspace_applyEdit" name="workspace_applyEdit" class="anchor">Applies a WorkspaceEdit (:arrow_right_hook:)</a>
 
 The `workspace/applyEdit` request is sent from the server to the client to modify resource on the client side.
 
+_Client Capability_:
+* property path (optional): `workspace.applyEdit`
+* property type: `boolean`
+
+See also the [WorkspaceEditClientCapabilities](#workspaceEditClientCapabilities) for the supported capabilities of a workspace edit.
+
 _Request_:
 * method: 'workspace/applyEdit'
 * params: `ApplyWorkspaceEditParams` defined as follows:
@@ -2576,13 +2625,73 @@
 ```
 * error: code and message set in case an exception happens during the request.
 
+#### <a href="#textDocument_synchronization" name="textDocument_synchronization" class="anchor">Text Document Synchronization</a>
+
+Client support for `textDocument/open`, `textDocument/change` and `textDocument/close` notifications is mandatory in the protocol and clients can not opt out supporting them. This includes both full and incremental syncronization in the `textDocument/change` notification. In addition a server must either implement all three of them or none. Their capabilities are therefore controlled via a combined client and server capability.
+
+<a href="#textDocument_synchronization_cc" name="textDocument_synchronization_cc" class="anchor"></a>_Client Capability_:
+* property path (optional): `textDocument.synchronization.dynamicRegistration`
+* property type: `boolean`
+
+Controls whether text document synchronization supports dynamic registration.
+
+<a href="#textDocument_synchronization_sc" name="textDocument_synchronization_sc" class="anchor"></a>_Server Capability_:
+* property path (optional): `textDocumentSync`
+* property type: `TextDocumentSyncKind | TextDocumentSyncOptions`. The below definition of the `TextDocumentSyncOptions` only covers the properties specific to the open, change and close notifications. A complete definition covering all properties can be found [here](#textDocument_didClose):
+
+```typescript
+/**
+ * Defines how the host (editor) should sync document changes to the language server.
+ */
+export namespace TextDocumentSyncKind {
+	/**
+	 * Documents should not be synced at all.
+	 */
+	export const None = 0;
+
+	/**
+	 * Documents are synced by always sending the full content
+	 * of the document.
+	 */
+	export const Full = 1;
+
+	/**
+	 * Documents are synced by sending the full content on open.
+	 * After that only incremental updates to the document are
+	 * send.
+	 */
+	export const Incremental = 2;
+}
+
+export interface TextDocumentSyncOptions {
+	/**
+	 * Open and close notifications are sent to the server. If omitted open close notification should not
+	 * be sent.
+	 */
+	openClose?: boolean;
+
+	/**
+	 * Change notifications are sent to the server. See TextDocumentSyncKind.None, TextDocumentSyncKind.Full
+	 * and TextDocumentSyncKind.Incremental. If omitted it defaults to TextDocumentSyncKind.None.
+	 */
+	change?: TextDocumentSyncKind;
+}
+```
 
 #### <a href="#textDocument_didOpen" name="textDocument_didOpen" class="anchor">DidOpenTextDocument Notification (:arrow_right:)</a>
 
-The document open notification is sent from the client to the server to signal newly opened text documents. The document's truth is now managed by the client and the server must not try to read the document's truth using the document's Uri. Open in this sense means it is managed by the client. It doesn't necessarily mean that its content is presented in an editor. An open notification must not be sent more than once without a corresponding close notification send before. This means open and close notification must be balanced and the max open count for a particular textDocument is one. Note that a server's ability to fulfill requests is independent of whether a text document is open or closed.
+The document open notification is sent from the client to the server to signal newly opened text documents. The document's content is now managed by the client and the server must not try to read the document's content using the document's Uri. Open in this sense means it is managed by the client. It doesn't necessarily mean that its content is presented in an editor. An open notification must not be sent more than once without a corresponding close notification send before. This means open and close notification must be balanced and the max open count for a particular textDocument is one. Note that a server's ability to fulfill requests is independent of whether a text document is open or closed.
 
 The `DidOpenTextDocumentParams` contain the language id the document is associated with. If the language Id of a document changes, the client needs to send a `textDocument/didClose` to the server followed by a `textDocument/didOpen` with the new language id if the server handles the new language id as well.
 
+_Client Capability_:
+See general synchronization [client capabilities](#textDocument_synchronization_cc).
+
+_Server Capability_:
+See general synchronization [server capabilities](#textDocument_synchronization_sc).
+
+_Registration Options_: [`TextDocumentRegistrationOptions`](#textDocumentRegistrationOptions)
+
 _Notification_:
 * method: 'textDocument/didOpen'
 * params: `DidOpenTextDocumentParams` defined as follows:
@@ -2596,12 +2705,29 @@
 }
 ```
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
-
 #### <a href="#textDocument_didChange" name="textDocument_didChange" class="anchor">DidChangeTextDocument Notification (:arrow_right:)</a>
 
-The document change notification is sent from the client to the server to signal changes to a text document. In 2.0 the shape of the params has changed to include proper version numbers and language ids.
+The document change notification is sent from the client to the server to signal changes to a text document. Before a client can change a text document it must claim ownership of its content using the `textDocument/didOpen` notification. In 2.0 the shape of the params has changed to include proper version numbers and language ids.
+
+_Client Capability_:
+See general synchronization [client capabilities](#textDocument_synchronization_cc).
+
+_Server Capability_:
+See general synchronization [server capabilities](#textDocument_synchronization_sc).
+
+_Registration Options_: `TextDocumentChangeRegistrationOptions` defined as follows:
+```typescript
+/**
+ * Describe options to be used when registering for text document change events.
+ */
+export interface TextDocumentChangeRegistrationOptions extends TextDocumentRegistrationOptions {
+	/**
+	 * How documents are synced to the server. See TextDocumentSyncKind.Full
+	 * and TextDocumentSyncKind.Incremental.
+	 */
+	syncKind: TextDocumentSyncKind;
+}
+```
 
 _Notification_:
 * method: 'textDocument/didChange'
@@ -2618,8 +2744,16 @@
 
 	/**
 	 * The actual content changes. The content changes describe single state changes
-	 * to the document. So if there are two content changes c1 and c2 for a document
-	 * in state S then c1 move the document to S' and c2 to S''.
+	 * to the document. So if there are two content changes c1 (at array index 0) and
+	 * c2 (at array index 1) for a document in state S then c1 moves the document from
+	 * S to S' and c2 from S' to S''. So c1 is computed on the state S and c2 is computed
+	 * on the state S'.
+	 *
+	 * To mirror the content of a document using change events use the following approach:
+	 * - start with the same initial content
+	 * - apply the 'textDocument/didChange' notifications in the order you recevie them.
+	 * - apply the `TextDocumentContentChangeEvent`s in a single notification in the order
+	 *   you receive them.
 	 */
 	contentChanges: TextDocumentContentChangeEvent[];
 }
@@ -2628,44 +2762,49 @@
  * An event describing a change to a text document. If range and rangeLength are omitted
  * the new text is considered to be the full content of the document.
  */
-interface TextDocumentContentChangeEvent {
+export type TextDocumentContentChangeEvent = {
 	/**
 	 * The range of the document that changed.
 	 */
-	range?: Range;
+	range: Range;
 
 	/**
-	 * The length of the range that got replaced.
+	 * The optional length of the range that got replaced.
+	 *
+	 * @deprecated use range instead.
 	 */
 	rangeLength?: number;
 
 	/**
-	 * The new text of the range/document.
+	 * The new text for the provided range.
+	 */
+	text: string;
+} | {
+	/**
+	 * The new text of the whole document.
 	 */
 	text: string;
 }
 ```
 
-_Registration Options_: `TextDocumentChangeRegistrationOptions` defined as follows:
-
-```typescript
-/**
- * Describe options to be used when registering for text document change events.
- */
-export interface TextDocumentChangeRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * How documents are synced to the server. See TextDocumentSyncKind.Full
-	 * and TextDocumentSyncKind.Incremental.
-	 */
-	syncKind: number;
-}
-```
-
-
 #### <a href="#textDocument_willSave" name="textDocument_willSave" class="anchor">WillSaveTextDocument Notification (:arrow_right:)</a>
 
 The document will save notification is sent from the client to the server before the document is actually saved.
 
+_Client Capability_:
+* property name (optional): `textDocument.synchronization.willSave`
+* property type: `boolean`
+
+The capability indicates that the client supports `textDocument/willSave` notifications.
+
+_Server Capability_:
+* property name (optional): `textDocumentSync.willSave`
+* property type: `boolean`
+
+The capability indicates that the server is interested in `textDocument/willSave` notifications.
+
+_Registration Options_: `TextDocumentRegistrationOptions`
+
 _Notification_:
 * method: 'textDocument/willSave'
 * params: `WillSaveTextDocumentParams` defined as follows:
@@ -2709,13 +2848,24 @@
 }
 ```
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
-
 #### <a href="#textDocument_willSaveWaitUntil" name="textDocument_willSaveWaitUntil" class="anchor">WillSaveWaitUntilTextDocument Request (:leftwards_arrow_with_hook:)</a>
 
 The document will save request is sent from the client to the server before the document is actually saved. The request can return an array of TextEdits which will be applied to the text document before it is saved. Please note that clients might drop results if computing the text edits took too long or if a server constantly fails on this request. This is done to keep the save fast and reliable.
 
+_Client Capability_:
+* property name (optional): `textDocument.synchronization.willSaveWaitUntil`
+* property type: `boolean`
+
+The capability indicates that the client supports `textDocument/willSaveWaitUntil` requests.
+
+_Server Capability_:
+* property name (optional): `textDocumentSync.willSaveWaitUntil`
+* property type: `boolean`
+
+The capability indicates that the server is interested in `textDocument/willSaveWaitUntil` requests.
+
+_Registration Options_: `TextDocumentRegistrationOptions`
+
 _Request_:
 * method: 'textDocument/willSaveWaitUntil'
 * params: `WillSaveTextDocumentParams`
@@ -2724,12 +2874,42 @@
 * result:`TextEdit[]` \| `null`
 * error: code and message set in case an exception happens during the `willSaveWaitUntil` request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_didSave" name="textDocument_didSave" class="anchor">DidSaveTextDocument Notification (:arrow_right:)</a>
 
 The document save notification is sent from the client to the server when the document was saved in the client.
 
+_Client Capability_:
+* property name (optional): `textDocument.synchronization.didSave`
+* property type: `boolean`
+
+The capability indicates that the client supports `textDocument/didSave` notifications.
+
+_Server Capability_:
+* property name (optional): `textDocumentSync.save`
+* property type: `boolean | SaveOptions` where `SaveOptions` is defined as follows:
+
+```typescript
+export interface SaveOptions {
+	/**
+	 * The client is supposed to include the content on save.
+	 */
+	includeText?: boolean;
+}
+```
+
+The capability indicates that the server is interested in `textDocument/didSave` notifications.
+
+_Registration Options_: `TextDocumentSaveRegistrationOptions` defined as follows:
+```typescript
+export interface TextDocumentSaveRegistrationOptions extends TextDocumentRegistrationOptions {
+	/**
+	 * The client is supposed to include the content on save.
+	 */
+	includeText?: boolean;
+}
+```
+
+_Notification_:
 * method: 'textDocument/didSave'
 * params: `DidSaveTextDocumentParams` defined as follows:
 
@@ -2748,20 +2928,17 @@
 }
 ```
 
-_Registration Options_: `TextDocumentSaveRegistrationOptions` defined as follows:
-
-```typescript
-export interface TextDocumentSaveRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * The client is supposed to include the content on save.
-	 */
-	includeText?: boolean;
-}
-```
-
 #### <a href="#textDocument_didClose" name="textDocument_didClose" class="anchor">DidCloseTextDocument Notification (:arrow_right:)</a>
 
-The document close notification is sent from the client to the server when the document got closed in the client. The document's truth now exists where the document's Uri points to (e.g. if the document's Uri is a file Uri the truth now exists on disk). As with the open notification the close notification is about managing the document's content. Receiving a close notification doesn't mean that the document was open in an editor before. A close notification requires a previous open notification to be sent. Note that a server's ability to fulfill requests is independent of whether a text document is open or closed.
+The document close notification is sent from the client to the server when the document got closed in the client. The document's master now exists where the document's Uri points to (e.g. if the document's Uri is a file Uri the master now exists on disk). As with the open notification the close notification is about managing the document's content. Receiving a close notification doesn't mean that the document was open in an editor before. A close notification requires a previous open notification to be sent. Note that a server's ability to fulfill requests is independent of whether a text document is open or closed.
+
+_Client Capability_:
+See general synchronization [client capabilities](#textDocument_synchronization_cc).
+
+_Server Capability_:
+See general synchronization [server capabilities](#textDocument_synchronization_sc).
+
+_Registration Options_: `TextDocumentRegistrationOptions`
 
 _Notification_:
 * method: 'textDocument/didClose'
@@ -2776,8 +2953,84 @@
 }
 ```
 
-_Registration Options_: `TextDocumentRegistrationOptions`
+The final structure of the `TextDocumentSyncClientCapabilities` and the `TextDocumentSyncOptions` server options look like this
 
+```typescript
+export interface TextDocumentSyncClientCapabilities {
+	/**
+	 * Whether text document synchronization supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports sending will save notifications.
+	 */
+	willSave?: boolean;
+
+	/**
+	 * The client supports sending a will save request and
+	 * waits for a response providing text edits which will
+	 * be applied to the document before it is saved.
+	 */
+	willSaveWaitUntil?: boolean;
+
+	/**
+	 * The client supports did save notifications.
+	 */
+	didSave?: boolean;
+}
+
+/**
+ * Defines how the host (editor) should sync document changes to the language server.
+ */
+export namespace TextDocumentSyncKind {
+	/**
+	 * Documents should not be synced at all.
+	 */
+	export const None = 0;
+
+	/**
+	 * Documents are synced by always sending the full content
+	 * of the document.
+	 */
+	export const Full = 1;
+
+	/**
+	 * Documents are synced by sending the full content on open.
+	 * After that only incremental updates to the document are
+	 * send.
+	 */
+	export const Incremental = 2;
+}
+
+export interface TextDocumentSyncOptions {
+	/**
+	 * Open and close notifications are sent to the server. If omitted open close notification should not
+	 * be sent.
+	 */
+	openClose?: boolean;
+	/**
+	 * Change notifications are sent to the server. See TextDocumentSyncKind.None, TextDocumentSyncKind.Full
+	 * and TextDocumentSyncKind.Incremental. If omitted it defaults to TextDocumentSyncKind.None.
+	 */
+	change?: number;
+	/**
+	 * If present will save notifications are sent to the server. If omitted the notification should not be
+	 * sent.
+	 */
+	willSave?: boolean;
+	/**
+	 * If present will save wait until requests are sent to the server. If omitted the request should not be
+	 * sent.
+	 */
+	willSaveWaitUntil?: boolean;
+	/**
+	 * If present save notifications are sent to the server. If omitted the notification should not be
+	 * sent.
+	 */
+	save?: boolean | SaveOptions;
+}
+```
 
 #### <a href="#textDocument_publishDiagnostics" name="textDocument_publishDiagnostics" class="anchor">PublishDiagnostics Notification (:arrow_left:)</a>
 
@@ -2790,6 +3043,42 @@
 
 When a file changes it is the server's responsibility to re-compute diagnostics and push them to the client. If the computed set is empty it has to push the empty array to clear former diagnostics. Newly pushed diagnostics always replace previously pushed diagnostics. There is no merging that happens on the client side.
 
+See also the [Diagnostic](#diagnostic) section.
+
+_Client Capability_:
+* property name (optional): `textDocument.publishDiagnostics`
+* property type `PublishDiagnosticsClientCapabilities` defined as follows:
+
+```typescript
+export interface PublishDiagnosticsClientCapabilities {
+	/**
+	 * Whether the clients accepts diagnostics with related information.
+	 */
+	relatedInformation?: boolean;
+
+	/**
+	 * Client supports the tag property to provide meta data about a diagnostic.
+	 * Clients supporting tags have to handle unknown tags gracefully.
+	 *
+	 * @since 3.15.0
+	 */
+	tagSupport?: {
+		/**
+		 * The tags supported by the client.
+		 */
+		valueSet: DiagnosticTag[];
+	};
+
+	/**
+	 * Whether the client interprets the version property of the
+	 * `textDocument/publishDiagnostics` notification's parameter.
+	 *
+	 * @since 3.15.0
+	 */
+	versionSupport?: boolean;
+}
+```
+
 _Notification_:
 * method: 'textDocument/publishDiagnostics'
 * params: `PublishDiagnosticsParams` defined as follows:
@@ -2802,6 +3091,13 @@
 	uri: DocumentUri;
 
 	/**
+	 * Optional the version number of the document the diagnostics are published for.
+	 *
+	 * @since 3.15.0
+	 */
+	version?: number;
+
+	/**
 	 * An array of diagnostic information items.
 	 */
 	diagnostics: Diagnostic[];
@@ -2810,15 +3106,146 @@
 
 #### <a href="#textDocument_completion" name="textDocument_completion" class="anchor">Completion Request (:leftwards_arrow_with_hook:)</a>
 
-The Completion request is sent from the client to the server to compute completion items at a given cursor position. Completion items are presented in the [IntelliSense](https://code.visualstudio.com/docs/editor/editingevolved#_intellisense) user interface. If computing full completion items is expensive, servers can additionally provide a handler for the completion item resolve request ('completionItem/resolve'). This request is sent when a completion item is selected in the user interface. A typical use case is for example: the 'textDocument/completion' request doesn't fill in the `documentation` property for returned completion items since it is expensive to compute. When the item is selected in the user interface then a 'completionItem/resolve' request is sent with the selected completion item as a parameter. The returned completion item should have the documentation property filled in. The request can delay the computation of the `detail` and `documentation` properties. However, properties that are needed for the initial sorting and filtering, like `sortText`, `filterText`, `insertText`, and `textEdit` must be provided in the `textDocument/completion` response and must not be changed during resolve.
+The Completion request is sent from the client to the server to compute completion items at a given cursor position. Completion items are presented in the [IntelliSense](https://code.visualstudio.com/docs/editor/editingevolved#_intellisense) user interface. If computing full completion items is expensive, servers can additionally provide a handler for the completion item resolve request ('completionItem/resolve'). This request is sent when a completion item is selected in the user interface. A typical use case is for example: the 'textDocument/completion' request doesn't fill in the `documentation` property for returned completion items since it is expensive to compute. When the item is selected in the user interface then a 'completionItem/resolve' request is sent with the selected completion item as a parameter. The returned completion item should have the documentation property filled in. The request can only delay the computation of the `detail` and `documentation` properties. Other properties like `sortText`, `filterText`, `insertText`, `textEdit` and `additionalTextEdits` must be provided in the `textDocument/completion` response and must not be changed during resolve.
+
+_Client Capability_:
+* property name (optional): `textDocument.completion`
+* property type: `CompletionClientCapabilities` defined as follows:
+
+```typescript
+export interface CompletionClientCapabilities {
+	/**
+	 * Whether completion supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports the following `CompletionItem` specific
+	 * capabilities.
+	 */
+	completionItem?: {
+		/**
+		 * Client supports snippets as insert text.
+		 *
+		 * A snippet can define tab stops and placeholders with `$1`, `$2`
+		 * and `${3:foo}`. `$0` defines the final tab stop, it defaults to
+		 * the end of the snippet. Placeholders with equal identifiers are linked,
+		 * that is typing in one will update others too.
+		 */
+		snippetSupport?: boolean;
+
+		/**
+		 * Client supports commit characters on a completion item.
+		 */
+		commitCharactersSupport?: boolean
+
+		/**
+		 * Client supports the follow content formats for the documentation
+		 * property. The order describes the preferred format of the client.
+		 */
+		documentationFormat?: MarkupKind[];
+
+		/**
+		 * Client supports the deprecated property on a completion item.
+		 */
+		deprecatedSupport?: boolean;
+
+		/**
+		 * Client supports the preselect property on a completion item.
+		 */
+		preselectSupport?: boolean;
+
+		/**
+		 * Client supports the tag property on a completion item. Clients supporting
+		 * tags have to handle unknown tags gracefully. Clients especially need to
+		 * preserve unknown tags when sending a completion item back to the server in
+		 * a resolve call.
+		 *
+		 * @since 3.15.0
+		 */
+		tagSupport?: {
+			/**
+			 * The tags supported by the client.
+			 */
+			valueSet: CompletionItemTag[]
+		}
+	};
+
+	completionItemKind?: {
+		/**
+		 * The completion item kind values the client supports. When this
+		 * property exists the client also guarantees that it will
+		 * handle values outside its set gracefully and falls back
+		 * to a default value when unknown.
+		 *
+		 * If this property is not present the client only supports
+		 * the completion items kinds from `Text` to `Reference` as defined in
+		 * the initial version of the protocol.
+		 */
+		valueSet?: CompletionItemKind[];
+	};
+
+	/**
+	 * The client supports to send additional context information for a
+	 * `textDocument/completion` request.
+	 */
+	contextSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `completionProvider`
+* property type: `CompletionOptions` defined as follows:
+
+```typescript
+/**
+ * Completion options.
+ */
+export interface CompletionOptions extends WorkDoneProgressOptions {
+	/**
+	 * Most tools trigger completion request automatically without explicitly requesting
+	 * it using a keyboard shortcut (e.g. Ctrl+Space). Typically they do so when the user
+	 * starts to type an identifier. For example if the user types `c` in a JavaScript file
+	 * code complete will automatically pop up present `console` besides others as a
+	 * completion item. Characters that make up identifiers don't need to be listed here.
+	 *
+	 * If code complete should automatically be trigger on characters not being valid inside
+	 * an identifier (for example `.` in JavaScript) list them in `triggerCharacters`.
+	 */
+	triggerCharacters?: string[];
+
+	/**
+	 * The list of all possible characters that commit a completion. This field can be used
+	 * if clients don't support individual commit characters per completion item. See
+	 * `ClientCapabilities.textDocument.completion.completionItem.commitCharactersSupport`.
+	 *
+	 * If a server provides both `allCommitCharacters` and commit characters on an individual
+	 * completion item the ones on the completion item win.
+	 *
+	 * @since 3.2.0
+	 */
+	allCommitCharacters?: string[];
+
+	/**
+	 * The server provides support to resolve additional
+	 * information for a completion item.
+	 */
+	resolveProvider?: boolean;
+}
+```
+
+_Registration Options_: `CompletionRegistrationOptions` options defined as follows:
+```typescript
+export interface CompletionRegistrationOptions extends TextDocumentRegistrationOptions, CompletionOptions {
+}
+```
 
 _Request_:
 * method: 'textDocument/completion'
 * params: `CompletionParams` defined as follows:
 
 ```typescript
-export interface CompletionParams extends TextDocumentPositionParams {
-
+export interface CompletionParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The completion context. This is only available if the client specifies
 	 * to send this using `ClientCapabilities.textDocument.completion.contextSupport === true`
@@ -2875,7 +3302,7 @@
  * Represents a collection of [completion items](#CompletionItem) to be presented
  * in the editor.
  */
-interface CompletionList {
+export interface CompletionList {
 	/**
 	 * This list it not complete. Further typing should result in recomputing
 	 * this list.
@@ -2892,7 +3319,7 @@
  * Defines whether the insert text in a completion item should be interpreted as
  * plain text or a snippet.
  */
-namespace InsertTextFormat {
+export namespace InsertTextFormat {
 	/**
 	 * The primary text to be inserted is treated as a plain string.
 	 */
@@ -2909,9 +3336,24 @@
 	export const Snippet = 2;
 }
 
-type InsertTextFormat = 1 | 2;
+export type InsertTextFormat = 1 | 2;
 
-interface CompletionItem {
+/**
+ * Completion item tags are extra annotations that tweak the rendering of a completion
+ * item.
+ *
+ * @since 3.15.0
+ */
+export namespace CompletionItemTag {
+	/**
+	 * Render a completion as obsolete, usually using a strike-out.
+	 */
+	export const Deprecated = 1;
+}
+
+export type CompletionItemTag = 1;
+
+export interface CompletionItem {
 	/**
 	 * The label of this completion item. By default
 	 * also the text that is inserted when selecting
@@ -2927,6 +3369,13 @@
 	kind?: number;
 
 	/**
+	 * Tags for this completion item.
+	 *
+	 * @since 3.15.0
+	 */
+	tags?: CompletionItemTag[];
+
+	/**
 	 * A human-readable string with additional information
 	 * about this item, like type or symbol information.
 	 */
@@ -2939,6 +3388,8 @@
 
 	/**
 	 * Indicates if this item is deprecated.
+	 *
+	 * @deprecated Use `tags` instead if supported.
 	 */
 	deprecated?: boolean;
 
@@ -2978,7 +3429,7 @@
 
 	/**
 	 * The format of the insert text. The format applies to both the `insertText` property
-	 * and the `newText` property of a provided `textEdit`. If ommitted defaults to
+	 * and the `newText` property of a provided `textEdit`. If omitted defaults to
 	 * `InsertTextFormat.PlainText`.
 	 */
 	insertTextFormat?: InsertTextFormat;
@@ -3027,7 +3478,7 @@
 /**
  * The kind of a completion entry.
  */
-namespace CompletionItemKind {
+export namespace CompletionItemKind {
 	export const Text = 1;
 	export const Method = 2;
 	export const Function = 3;
@@ -3055,47 +3506,12 @@
 	export const TypeParameter = 25;
 }
 ```
+* partial result: `CompletionItem[]`  or `CompletionList` followed by `CompletionItem[]`. If the first provided result item is of type `CompletionList` subsequent partial results of `CompletionItem[]` add to the `items` property of the `CompletionList`.
 * error: code and message set in case an exception happens during the completion request.
 
-_Registration Options_: `CompletionRegistrationOptions` options defined as follows:
-
-```typescript
-export interface CompletionRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * Most tools trigger completion request automatically without explicitly requesting
-	 * it using a keyboard shortcut (e.g. Ctrl+Space). Typically they do so when the user
-	 * starts to type an identifier. For example if the user types `c` in a JavaScript file
-	 * code complete will automatically pop up present `console` besides others as a
-	 * completion item. Characters that make up identifiers don't need to be listed here.
-	 *
-	 * If code complete should automatically be trigger on characters not being valid inside
-	 * an identifier (for example `.` in JavaScript) list them in `triggerCharacters`.
-	 */
-	triggerCharacters?: string[];
-
-	/**
-	 * The list of all possible characters that commit a completion. This field can be used
-	 * if clients don't support individual commmit characters per completion item. See
-	 * `ClientCapabilities.textDocument.completion.completionItem.commitCharactersSupport`.
-	 *
-	 * If a server provides both `allCommitCharacters` and commit characters on an individual
-	 * completion item the ones on the completion item win.
-	 *
-     * Since 3.2.0
-	 */
-	allCommitCharacters?: string[];
-
-	/**
-	 * The server provides support to resolve additional
-	 * information for a completion item.
-	 */
-	resolveProvider?: boolean;
-}
-```
-
 Completion items support snippets (see `InsertTextFormat.Snippet`). The snippet format is as follows:
 
-##### Snippet Syntax
+##### <a href="#snippet_syntax" name="snippet_syntax" class="anchor">Snippet Syntax</a>
 
 The `body` of a snippet can use special constructs to control cursors and the text being inserted. The following are supported features and their syntaxes:
 
@@ -3191,9 +3607,48 @@
 
 The hover request is sent from the client to the server to request hover information at a given text document position.
 
+_Client Capability_:
+* property name (optional): `textDocument.hover`
+* property type: `HoverClientCapabilities` defined as follows:
+
+```typescript
+export interface HoverClientCapabilities {
+	/**
+	 * Whether hover supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * Client supports the follow content formats for the content
+	 * property. The order describes the preferred format of the client.
+	 */
+	contentFormat?: MarkupKind[];
+}
+```
+
+_Server Capability_:
+* property name (optional): `hoverProvider`
+* property type: `boolean | HoverOptions` where `HoverOptions` is defined as follows:
+
+```typescript
+export interface HoverOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `HoverRegistrationOptions` defined as follows:
+```typescript
+export interface HoverRegistrationOptions extends TextDocumentRegistrationOptions, HoverOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/hover'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `HoverParams` defined as follows:
+
+```typescript
+export interface HoverParams extends TextDocumentPositionParams, WorkDoneProgressParams {
+}
+```
 
 _Response_:
 * result: `Hover` \| `null` defined as follows:
@@ -3202,7 +3657,7 @@
 /**
  * The result of a hover request.
  */
-interface Hover {
+export interface Hover {
 	/**
 	 * The hover's content
 	 */
@@ -3238,15 +3693,159 @@
 
 * error: code and message set in case an exception happens during the hover request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_signatureHelp" name="textDocument_signatureHelp" class="anchor">Signature Help Request (:leftwards_arrow_with_hook:)</a>
 
 The signature help request is sent from the client to the server to request signature information at a given cursor position.
 
+_Client Capability_:
+* property name (optional): `textDocument.signatureHelp`
+* property type: `SignatureHelpClientCapabilities` defined as follows:
+
+```typescript
+export interface SignatureHelpClientCapabilities {
+	/**
+	 * Whether signature help supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports the following `SignatureInformation`
+	 * specific properties.
+	 */
+	signatureInformation?: {
+		/**
+		 * Client supports the follow content formats for the documentation
+		 * property. The order describes the preferred format of the client.
+		 */
+		documentationFormat?: MarkupKind[];
+
+		/**
+		 * Client capabilities specific to parameter information.
+		 */
+		parameterInformation?: {
+			/**
+			 * The client supports processing label offsets instead of a
+			 * simple label string.
+			 *
+			 * @since 3.14.0
+			 */
+			labelOffsetSupport?: boolean;
+		};
+	};
+
+	/**
+	 * The client supports to send additional context information for a
+	 * `textDocument/signatureHelp` request. A client that opts into
+	 * contextSupport will also support the `retriggerCharacters` on
+	 * `SignatureHelpOptions`.
+	 *
+	 * @since 3.15.0
+	 */
+	contextSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `signatureHelpProvider`
+* property type: `SignatureHelpOptions` defined as follows:
+
+```typescript
+export interface SignatureHelpOptions extends WorkDoneProgressOptions {
+	/**
+	 * The characters that trigger signature help
+	 * automatically.
+	 */
+	triggerCharacters?: string[];
+
+	/**
+	 * List of characters that re-trigger signature help.
+	 *
+	 * These trigger characters are only active when signature help is already showing. All trigger characters
+	 * are also counted as re-trigger characters.
+	 *
+	 * @since 3.15.0
+	 */
+	retriggerCharacters?: string[];
+}
+```
+
+_Registration Options_: `SignatureHelpRegistrationOptions` defined as follows:
+```typescript
+export interface SignatureHelpRegistrationOptions extends TextDocumentRegistrationOptions, SignatureHelpOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/signatureHelp'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `SignatureHelpParams` defined as follows:
+
+```typescript
+export interface SignatureHelpParams extends TextDocumentPositionParams, WorkDoneProgressParams {
+	/**
+	 * The signature help context. This is only available if the client specifies
+	 * to send this using the client capability  `textDocument.signatureHelp.contextSupport === true`
+	 *
+	 * @since 3.15.0
+	 */
+	context?: SignatureHelpContext;
+}
+
+/**
+ * How a signature help was triggered.
+ *
+ * @since 3.15.0
+ */
+export namespace SignatureHelpTriggerKind {
+	/**
+	 * Signature help was invoked manually by the user or by a command.
+	 */
+	export const Invoked: 1 = 1;
+	/**
+	 * Signature help was triggered by a trigger character.
+	 */
+	export const TriggerCharacter: 2 = 2;
+	/**
+	 * Signature help was triggered by the cursor moving or by the document content changing.
+	 */
+	export const ContentChange: 3 = 3;
+}
+export type SignatureHelpTriggerKind = 1 | 2 | 3;
+
+/**
+ * Additional information about the context in which a signature help request was triggered.
+ *
+ * @since 3.15.0
+ */
+export interface SignatureHelpContext {
+	/**
+	 * Action that caused signature help to be triggered.
+	 */
+	triggerKind: SignatureHelpTriggerKind;
+
+	/**
+	 * Character that caused signature help to be triggered.
+	 *
+	 * This is undefined when `triggerKind !== SignatureHelpTriggerKind.TriggerCharacter`
+	 */
+	triggerCharacter?: string;
+
+	/**
+	 * `true` if signature help was already showing when it was triggered.
+	 *
+	 * Retriggers occur when the signature help is already active and can be caused by actions such as
+	 * typing a trigger character, a cursor move, or document content changes.
+	 */
+	isRetrigger: boolean;
+
+	/**
+	 * The currently active `SignatureHelp`.
+	 *
+	 * The `activeSignatureHelp` has its `SignatureHelp.activeSignature` field updated based on
+	 * the user navigating through available signatures.
+	 */
+	activeSignatureHelp?: SignatureHelp;
+}
+```
 
 _Response_:
 * result: `SignatureHelp` \| `null` defined as follows:
@@ -3257,18 +3856,21 @@
  * callable. There can be multiple signature but only one
  * active and only one active parameter.
  */
-interface SignatureHelp {
+export interface SignatureHelp {
 	/**
-	 * One or more signatures.
+	 * One or more signatures. If no signaures are availabe the signature help
+	 * request should return `null`.
 	 */
 	signatures: SignatureInformation[];
 
 	/**
 	 * The active signature. If omitted or the value lies outside the
-	 * range of `signatures` the value defaults to zero or is ignored if
-	 * `signatures.length === 0`. Whenever possible implementors should
-	 * make an active decision about the active signature and shouldn't
-	 * rely on a default value.
+	 * range of `signatures` the value defaults to zero or is ignore if
+	 * the `SignatureHelp` as no signatures.
+	 *
+	 * Whenever possible implementors should make an active decision about
+	 * the active signature and shouldn't rely on a default value.
+	 *
 	 * In future version of the protocol this property might become
 	 * mandatory to better express this.
 	 */
@@ -3291,7 +3893,7 @@
  * can have a label, like a function-name, a doc-comment, and
  * a set of parameters.
  */
-interface SignatureInformation {
+export interface SignatureInformation {
 	/**
 	 * The label of this signature. Will be shown in
 	 * the UI.
@@ -3314,7 +3916,7 @@
  * Represents a parameter of a callable-signature. A parameter can
  * have a label and a doc-comment.
  */
-interface ParameterInformation {
+export interface ParameterInformation {
 
 	/**
 	 * The label of this parameter information.
@@ -3338,103 +3940,278 @@
 
 * error: code and message set in case an exception happens during the signature help request.
 
-_Registration Options_: `SignatureHelpRegistrationOptions` defined as follows:
-
-```typescript
-export interface SignatureHelpRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * The characters that trigger signature help
-	 * automatically.
-	 */
-	triggerCharacters?: string[];
-}
-```
 #### <a href="#textDocument_declaration" name="textDocument_declaration" class="anchor">Goto Declaration Request (:leftwards_arrow_with_hook:)</a>
 
 > *Since version 3.14.0*
 
 The go to declaration request is sent from the client to the server to resolve the declaration location of a symbol at a given text document position.
 
-The result type [`LocationLink`](#locationlink)[] got introduce with version 3.14.0 and depends in the corresponding client capability `clientCapabilities.textDocument.declaration.linkSupport`.
+The result type [`LocationLink`](#locationLink)[] got introduced with version 3.14.0 and depends on the corresponding client capability `textDocument.declaration.linkSupport`.
+
+_Client Capability_:
+* property name (optional): `textDocument.declaration`
+* property type: `DeclarationClientCapabilities` defined as follows:
+
+```typescript
+export interface DeclarationClientCapabilities {
+	/**
+	 * Whether declaration supports dynamic registration. If this is set to `true`
+	 * the client supports the new `DeclarationRegistrationOptions` return value
+	 * for the corresponding server capability as well.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports additional metadata in the form of declaration links.
+	 */
+	linkSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `declarationProvider`
+* property type: `boolean | DeclarationOptions | DeclarationRegistrationOptions` where `DeclarationOptions` is defined as follows:
+
+```typescript
+export interface DeclarationOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DeclarationRegistrationOptions` defined as follows:
+```typescript
+export interface DeclarationRegistrationOptions extends DeclarationOptions, TextDocumentRegistrationOptions, StaticRegistrationOptions  {
+}
+```
 
 _Request_:
 * method: 'textDocument/declaration'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `DeclarationParams` defined as follows:
+
+```typescript
+export interface DeclarationParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
+}
+```
 
 _Response_:
-* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationlink)[] \|`null`
+* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationLink)[] \|`null`
+* partial result: [`Location`](#location)[] \| [`LocationLink`](#locationLink)[]
 * error: code and message set in case an exception happens during the declaration request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_definition" name="textDocument_definition" class="anchor">Goto Definition Request (:leftwards_arrow_with_hook:)</a>
 
-> *Since version 3.14.0*
-
 The go to definition request is sent from the client to the server to resolve the definition location of a symbol at a given text document position.
 
-The result type [`LocationLink`](#locationlink)[] got introduce with version 3.14.0 and depends in the corresponding client capability `clientCapabilities.textDocument.definition.linkSupport`.
+The result type [`LocationLink`](#locationLink)[] got introduced with version 3.14.0 and depends on the corresponding client capability `textDocument.definition.linkSupport`.
+
+_Client Capability_:
+* property name (optional): `textDocument.definition`
+* property type: `DefinitionClientCapabilities` defined as follows:
+
+```typescript
+export interface DefinitionClientCapabilities {
+	/**
+	 * Whether definition supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports additional metadata in the form of definition links.
+	 *
+	 * @since 3.14.0
+	 */
+	linkSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `definitionProvider`
+* property type: `boolean | DefinitionOptions` where `DefinitionOptions` is defined as follows:
+
+```typescript
+export interface DefinitionOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DefinitionRegistrationOptions` defined as follows:
+```typescript
+export interface DefinitionRegistrationOptions extends TextDocumentRegistrationOptions, DefinitionOptions {
+}
+```
 
 _Request_:
 * method: 'textDocument/definition'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `DefinitionParams` defined as follows:
+
+```typescript
+export interface DefinitionParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
+}
+```
 
 _Response_:
-* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationlink)[] \| `null`
+* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationLink)[] \| `null`
+* partial result: [`Location`](#location)[] \| [`LocationLink`](#locationLink)[]
 * error: code and message set in case an exception happens during the definition request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_typeDefinition" name="textDocument_typeDefinition" class="anchor">Goto Type Definition Request (:leftwards_arrow_with_hook:)</a>
 
 > *Since version 3.6.0*
 
 The go to type definition request is sent from the client to the server to resolve the type definition location of a symbol at a given text document position.
 
-The result type [`LocationLink`](#locationlink)[] got introduce with version 3.14.0 and depends in the corresponding client capability `clientCapabilities.textDocument.typeDefinition.linkSupport`.
+The result type [`LocationLink`](#locationLink)[] got introduced with version 3.14.0 and depends on the corresponding client capability `textDocument.typeDefinition.linkSupport`.
+
+_Client Capability_:
+* property name (optional): `textDocument.typeDefinition`
+* property type: `TypeDefinitionClientCapabilities` defined as follows:
+
+```typescript
+export interface TypeDefinitionClientCapabilities {
+	/**
+	 * Whether implementation supports dynamic registration. If this is set to `true`
+	 * the client supports the new `TypeDefinitionRegistrationOptions` return value
+	 * for the corresponding server capability as well.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports additional metadata in the form of definition links.
+	 *
+	 * @since 3.14.0
+	 */
+	linkSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `typeDefinitionProvider`
+* property type: `boolean | TypeDefinitionOptions | TypeDefinitionRegistrationOptions` where `TypeDefinitionOptions` is defined as follows:
+
+```typescript
+export interface TypeDefinitionOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `TypeDefinitionRegistrationOptions` defined as follows:
+```typescript
+export interface TypeDefinitionRegistrationOptions extends TextDocumentRegistrationOptions, TypeDefinitionOptions, StaticRegistrationOptions {
+}
+```
 
 _Request_:
 * method: 'textDocument/typeDefinition'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `TypeDefinitionParams` defined as follows:
+
+```typescript
+export interface TypeDefinitionParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
+}
+```
 
 _Response_:
-* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationlink)[] \| `null`
+* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationLink)[] \| `null`
+* partial result: [`Location`](#location)[] \| [`LocationLink`](#locationLink)[]
 * error: code and message set in case an exception happens during the definition request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_implementation" name="textDocument_implementation" class="anchor">Goto Implementation Request (:leftwards_arrow_with_hook:)</a>
 
 > *Since version 3.6.0*
 
 The go to implementation request is sent from the client to the server to resolve the implementation location of a symbol at a given text document position.
 
-The result type [`LocationLink`](#locationlink)[] got introduce with version 3.14.0 and depends in the corresponding client capability `clientCapabilities.implementation.typeDefinition.linkSupport`.
+The result type [`LocationLink`](#locationLink)[] got introduced with version 3.14.0 and depends on the corresponding client capability `textDocument.implementation.linkSupport`.
+
+_Client Capability_:
+* property name (optional): `textDocument.implementation`
+* property type: `ImplementationClientCapabilities` defined as follows:
+
+```typescript
+export interface ImplementationClientCapabilities {
+	/**
+	 * Whether implementation supports dynamic registration. If this is set to `true`
+	 * the client supports the new `ImplementationRegistrationOptions` return value
+	 * for the corresponding server capability as well.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports additional metadata in the form of definition links.
+	 *
+	 * @since 3.14.0
+	 */
+	linkSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `implementationProvider`
+* property type: `boolean | ImplementationOptions | ImplementationRegistrationOptions` where `ImplementationOptions` is defined as follows:
+
+```typescript
+export interface ImplementationOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `ImplementationRegistrationOptions` defined as follows:
+```typescript
+export interface ImplementationRegistrationOptions extends TextDocumentRegistrationOptions, ImplementationOptions, StaticRegistrationOptions {
+}
+```
 
 _Request_:
 * method: 'textDocument/implementation'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `ImplementationParams` defined as follows:
+
+```typescript
+export interface ImplementationParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
+}
+```
 
 _Response_:
-* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationlink)[] \| `null`
+* result: [`Location`](#location) \| [`Location`](#location)[] \| [`LocationLink`](#locationLink)[] \| `null`
+* partial result: [`Location`](#location)[] \| [`LocationLink`](#locationLink)[]
 * error: code and message set in case an exception happens during the definition request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_references" name="textDocument_references" class="anchor">Find References Request (:leftwards_arrow_with_hook:)</a>
 
 The references request is sent from the client to the server to resolve project-wide references for the symbol denoted by the given text document position.
 
+_Client Capability_:
+* property name (optional): `textDocument.references`
+* property type: `ReferenceClientCapabilities` defined as follows:
+
+```typescript
+export interface ReferenceClientCapabilities {
+	/**
+	 * Whether references supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `referencesProvider`
+* property type: `boolean | ReferenceOptions` where `ReferenceOptions` is defined as follows:
+
+```typescript
+export interface ReferenceOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `ReferenceRegistrationOptions` defined as follows:
+```typescript
+export interface ReferenceRegistrationOptions extends TextDocumentRegistrationOptions, ReferenceOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/references'
 * params: `ReferenceParams` defined as follows:
 
 ```typescript
-interface ReferenceParams extends TextDocumentPositionParams {
+export interface ReferenceParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
 	context: ReferenceContext
 }
 
-interface ReferenceContext {
+export interface ReferenceContext {
 	/**
 	 * Include the declaration of the current symbol.
 	 */
@@ -3443,10 +4220,9 @@
 ```
 _Response_:
 * result: [`Location`](#location)[] \| `null`
+* partial result: [`Location`](#location)[]
 * error: code and message set in case an exception happens during the reference request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_documentHighlight" name="textDocument_documentHighlight" class="anchor">Document Highlights Request (:leftwards_arrow_with_hook:)</a>
 
 The document highlight request is sent from the client to the server to resolve a document highlights for a given text document position.
@@ -3454,9 +4230,42 @@
 and 'textDocument/references' separate requests since the first one is allowed to be more fuzzy. Symbol matches usually have a `DocumentHighlightKind`
 of `Read` or `Write` whereas fuzzy or textual matches use `Text`as the kind.
 
+_Client Capability_:
+* property name (optional): `textDocument.documentHighlight`
+* property type: `DocumentHighlightClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentHighlightClientCapabilities {
+	/**
+	 * Whether document highlight supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentHighlightProvider`
+* property type: `boolean | DocumentHighlightOptions` where `DocumentHighlightOptions` is defined as follows:
+
+```typescript
+export interface DocumentHighlightOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DocumentHighlightRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentHighlightRegistrationOptions extends TextDocumentRegistrationOptions, DocumentHighlightOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/documentHighlight'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `DocumentHighlightParams` defined as follows:
+
+```typescript
+export interface DocumentHighlightParams extends TextDocumentPositionParams, WorkDoneProgressParams, PartialResultParams {
+}
+```
 
 _Response_:
 * result: `DocumentHighlight[]` \| `null` defined as follows:
@@ -3468,7 +4277,7 @@
  * the background color of its range.
  *
  */
-interface DocumentHighlight {
+export interface DocumentHighlight {
 	/**
 	 * The range this highlight applies to.
 	 */
@@ -3501,10 +4310,9 @@
 }
 ```
 
+* partial result: `DocumentHighlight[]`
 * error: code and message set in case an exception happens during the document highlight request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_documentSymbol" name="textDocument_documentSymbol" class="anchor">Document Symbols Request (:leftwards_arrow_with_hook:)</a>
 
 The document symbol request is sent from the client to the server. The returned result is either
@@ -3512,12 +4320,62 @@
 - `SymbolInformation[]` which is a flat list of all symbols found in a given text document. Then neither the symbol's location range nor the symbol's container name should be used to infer a hierarchy.
 - `DocumentSymbol[]` which is a hierarchy of symbols found in a given text document.
 
+_Client Capability_:
+* property name (optional): `textDocument.documentSymbol`
+* property type: `DocumentSymbolClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentSymbolClientCapabilities {
+	/**
+	 * Whether document symbol supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * Specific capabilities for the `SymbolKind` in the `textDocument/documentSymbol` request.
+	 */
+	symbolKind?: {
+		/**
+		 * The symbol kind values the client supports. When this
+		 * property exists the client also guarantees that it will
+		 * handle values outside its set gracefully and falls back
+		 * to a default value when unknown.
+		 *
+		 * If this property is not present the client only supports
+		 * the symbol kinds from `File` to `Array` as defined in
+		 * the initial version of the protocol.
+		 */
+		valueSet?: SymbolKind[];
+	}
+
+	/**
+	 * The client supports hierarchical document symbols.
+	 */
+	hierarchicalDocumentSymbolSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentSymbolProvider`
+* property type: `boolean | DocumentSymbolOptions` where `DocumentSymbolOptions` is defined as follows:
+
+```typescript
+export interface DocumentSymbolOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DocumentSymbolRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentSymbolRegistrationOptions extends TextDocumentRegistrationOptions, DocumentSymbolOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/documentSymbol'
 * params: `DocumentSymbolParams` defined as follows:
 
 ```typescript
-interface DocumentSymbolParams {
+export interface DocumentSymbolParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The text document.
 	 */
@@ -3566,7 +4424,7 @@
  * hierarchical and they have two ranges: one that encloses its definition and one that points to its most interesting range,
  * e.g. the range of an identifier.
  */
-export class DocumentSymbol {
+export interface DocumentSymbol {
 
 	/**
 	 * The name of this symbol. Will be displayed in the user interface and therefore must not be
@@ -3612,7 +4470,7 @@
  * Represents information about programming constructs like variables, classes,
  * interfaces etc.
  */
-interface SymbolInformation {
+export interface SymbolInformation {
 	/**
 	 * The name of this symbol.
 	 */
@@ -3621,7 +4479,7 @@
 	/**
 	 * The kind of this symbol.
 	 */
-	kind: number;
+	kind: SymbolKind;
 
 	/**
 	 * Indicates if this symbol is deprecated.
@@ -3649,13 +4507,11 @@
 	 */
 	containerName?: string;
 }
-
 ```
 
+* partial result: `DocumentSymbol[]` \| `SymbolInformation[]`. `DocumentSymbol[]` and `SymbolInformation[]` can not be mixed. That means the first chunk defines the type of all the other chunks.
 * error: code and message set in case an exception happens during the document symbol request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_codeAction" name="textDocument_codeAction" class="anchor">Code Action Request (:leftwards_arrow_with_hook:)</a>
 
 The code action request is sent from the client to the server to compute commands for a given text document and range. These commands are typically code fixes to either fix problems or to beautify/refactor code. The result of a `textDocument/codeAction` request is an array of `Command` literals which are typically presented in the user interface. To ensure that a server is useful in many clients the commands specified in a code actions should be handled by the server and not by the client (see `workspace/executeCommand` and `ServerCapabilities.executeCommandProvider`). If the client supports providing edits with a code action then the mode should be used.
@@ -3667,7 +4523,71 @@
 - the ability to directly return a workspace edit from the code action request. This avoids having another server roundtrip to execute an actual code action. However server providers should be aware that if the code action is expensive to compute or the edits are huge it might still be beneficial if the result is simply a command and the actual edit is only computed when needed.
 - the ability to group code actions using a kind. Clients are allowed to ignore that information. However it allows them to better group code action for example into corresponding menus (e.g. all refactor code actions into a refactor menu).
 
-Clients need to announce their support for code action literals and code action kinds via the corresponding client capability `textDocument.codeAction.codeActionLiteralSupport`.
+Clients need to announce their support for code action literals (e.g. literals of type `CodeAction`) and code action kinds via the corresponding client capability `codeAction.codeActionLiteralSupport`.
+
+_Client Capability_:
+* property name (optional): `textDocument.codeAction`
+* property type: `CodeActionClientCapabilities` defined as follows:
+
+```typescript
+export interface CodeActionClientCapabilities {
+	/**
+	 * Whether code action supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * The client supports code action literals as a valid
+	 * response of the `textDocument/codeAction` request.
+	 *
+	 * @since 3.8.0
+	 */
+	codeActionLiteralSupport?: {
+		/**
+		 * The code action kind is supported with the following value
+		 * set.
+		 */
+		codeActionKind: {
+
+			/**
+			 * The code action kind values the client supports. When this
+			 * property exists the client also guarantees that it will
+			 * handle values outside its set gracefully and falls back
+			 * to a default value when unknown.
+			 */
+			valueSet: CodeActionKind[];
+		};
+	};
+
+	/**
+	 * Whether code action supports the `isPreferred` property.
+	 * @since 3.15.0
+	 */
+	isPreferredSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `codeActionProvider`
+* property type: `boolean | CodeActionOptions` where `CodeActionOptions` is defined as follows:
+
+```typescript
+export interface CodeActionOptions extends WorkDoneProgressOptions {
+	/**
+	 * CodeActionKinds that this server may return.
+	 *
+	 * The list of kinds may be generic, such as `CodeActionKind.Refactor`, or the server
+	 * may list out every specific kind they provide.
+	 */
+	codeActionKinds?: CodeActionKind[];
+}
+```
+
+_Registration Options_: `CodeActionRegistrationOptions` defined as follows:
+```typescript
+export interface CodeActionRegistrationOptions extends TextDocumentRegistrationOptions, CodeActionOptions {
+}
+```
 
 _Request_:
 * method: 'textDocument/codeAction'
@@ -3677,7 +4597,7 @@
 /**
  * Params for the CodeActionRequest
  */
-interface CodeActionParams {
+export interface CodeActionParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The document in which the command was invoked.
 	 */
@@ -3705,7 +4625,7 @@
 export type CodeActionKind = string;
 
 /**
- * A set of predefined code action kinds
+ * A set of predefined code action kinds.
  */
 export namespace CodeActionKind {
 
@@ -3715,17 +4635,17 @@
 	export const Empty: CodeActionKind = '';
 
 	/**
-	 * Base kind for quickfix actions: 'quickfix'
+	 * Base kind for quickfix actions: 'quickfix'.
 	 */
 	export const QuickFix: CodeActionKind = 'quickfix';
 
 	/**
-	 * Base kind for refactoring actions: 'refactor'
+	 * Base kind for refactoring actions: 'refactor'.
 	 */
 	export const Refactor: CodeActionKind = 'refactor';
 
 	/**
-	 * Base kind for refactoring extraction actions: 'refactor.extract'
+	 * Base kind for refactoring extraction actions: 'refactor.extract'.
 	 *
 	 * Example extract actions:
 	 *
@@ -3738,7 +4658,7 @@
 	export const RefactorExtract: CodeActionKind = 'refactor.extract';
 
 	/**
-	 * Base kind for refactoring inline actions: 'refactor.inline'
+	 * Base kind for refactoring inline actions: 'refactor.inline'.
 	 *
 	 * Example inline actions:
 	 *
@@ -3750,7 +4670,7 @@
 	export const RefactorInline: CodeActionKind = 'refactor.inline';
 
 	/**
-	 * Base kind for refactoring rewrite actions: 'refactor.rewrite'
+	 * Base kind for refactoring rewrite actions: 'refactor.rewrite'.
 	 *
 	 * Example rewrite actions:
 	 *
@@ -3764,14 +4684,14 @@
 	export const RefactorRewrite: CodeActionKind = 'refactor.rewrite';
 
 	/**
-	 * Base kind for source actions: `source`
+	 * Base kind for source actions: `source`.
 	 *
 	 * Source code actions apply to the entire file.
 	 */
 	export const Source: CodeActionKind = 'source';
 
 	/**
-	 * Base kind for an organize imports source action: `source.organizeImports`
+	 * Base kind for an organize imports source action: `source.organizeImports`.
 	 */
 	export const SourceOrganizeImports: CodeActionKind = 'source.organizeImports';
 }
@@ -3780,9 +4700,13 @@
  * Contains additional diagnostic information about the context in which
  * a code action is run.
  */
-interface CodeActionContext {
+export interface CodeActionContext {
 	/**
-	 * An array of diagnostics.
+	 * An array of diagnostics known on the client side overlapping the range provided to the
+	 * `textDocument/codeAction` request. They are provided so that the server knows which
+	 * errors are currently presented to the user for the given range. There is no guarantee
+	 * that these accurately reflect the error state of the resource. The primary parameter
+	 * to compute code actions is the provided range.
 	 */
 	diagnostics: Diagnostic[];
 
@@ -3826,6 +4750,17 @@
 	diagnostics?: Diagnostic[];
 
 	/**
+	 * Marks this as a preferred action. Preferred actions are used by the `auto fix` command and can be targeted
+	 * by keybindings.
+	 *
+	 * A quick fix should be marked preferred if it properly addresses the underlying error.
+	 * A refactoring should be marked preferred if it is the most reasonable choice of actions to take.
+	 *
+	 * @since 3.15.0
+	 */
+	isPreferred?: boolean;
+
+	/**
 	 * The workspace edit this code action performs.
 	 */
 	edit?: WorkspaceEdit;
@@ -3838,27 +4773,51 @@
 	command?: Command;
 }
 ```
-
+* partial result: `(Command | CodeAction)[]`
 * error: code and message set in case an exception happens during the code action request.
 
-_Registration Options_: `CodeActionRegistrationOptions`  defined as follows:
-
-```typescript
-export interface CodeActionRegistrationOptions extends TextDocumentRegistrationOptions, CodeActionOptions {
-}
-```
-
-
 #### <a href="#textDocument_codeLens" name="textDocument_codeLens" class="anchor">Code Lens Request (:leftwards_arrow_with_hook:)</a>
 
 The code lens request is sent from the client to the server to compute code lenses for a given text document.
 
+_Client Capability_:
+* property name (optional): `textDocument.codeLens`
+* property type: `CodeLensClientCapabilities` defined as follows:
+
+```typescript
+export interface CodeLensClientCapabilities {
+	/**
+	 * Whether code lens supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `codeLensProvider`
+* property type: `CodeLensOptions` defined as follows:
+
+```typescript
+export interface CodeLensOptions extends WorkDoneProgressOptions {
+	/**
+	 * Code lens has a resolve provider as well.
+	 */
+	resolveProvider?: boolean;
+}
+```
+
+_Registration Options_: `CodeLensRegistrationOptions` defined as follows:
+```typescript
+export interface CodeLensRegistrationOptions extends TextDocumentRegistrationOptions, CodeLensOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/codeLens'
 * params: `CodeLensParams` defined as follows:
 
 ```typescript
-interface CodeLensParams {
+interface CodeLensParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The document to request code lens for.
 	 */
@@ -3895,19 +4854,9 @@
 	data?: any
 }
 ```
+* partial result: `CodeLens[]`
 * error: code and message set in case an exception happens during the code lens request.
 
-_Registration Options_: `CodeLensRegistrationOptions` defined as follows:
-
-```typescript
-export interface CodeLensRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * Code lens has a resolve provider as well.
-	 */
-	resolveProvider?: boolean;
-}
-```
-
 #### <a href="#codeLens_resolve" name="codeLens_resolve" class="anchor">Code Lens Resolve Request (:leftwards_arrow_with_hook:)</a>
 
 The code lens resolve request is sent from the client to the server to resolve the command for a given code lens item.
@@ -3924,12 +4873,51 @@
 
 The document links request is sent from the client to the server to request the location of links in a document.
 
-_Request_:
-* method: 'textDocument/documentLink'
-* params: `DocumentLinkParams`, defined as follows:
+_Client Capability_:
+* property name (optional): `textDocument.documentLink`
+* property type: `DocumentLinkClientCapabilities` defined as follows:
 
 ```typescript
-interface DocumentLinkParams {
+export interface DocumentLinkClientCapabilities {
+	/**
+	 * Whether document link supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * Whether the client supports the `tooltip` property on `DocumentLink`.
+	 *
+	 * @since 3.15.0
+	 */
+	tooltipSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentLinkProvider`
+* property type: `DocumentLinkOptions` defined as follows:
+
+```typescript
+export interface DocumentLinkOptions extends WorkDoneProgressOptions {
+	/**
+	 * Document links have a resolve provider as well.
+	 */
+	resolveProvider?: boolean;
+}
+```
+
+_Registration Options_: `DocumentLinkRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentLinkRegistrationOptions extends TextDocumentRegistrationOptions, DocumentLinkOptions {
+}
+```
+
+_Request_:
+* method: 'textDocument/documentLink'
+* params: `DocumentLinkParams` defined as follows:
+
+```typescript
+interface DocumentLinkParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The document to provide document links for.
 	 */
@@ -3938,7 +4926,7 @@
 ```
 
 _Response_:
-* result: An array of `DocumentLink` \| `null`.
+* result: `DocumentLink[]` \| `null`.
 
 ```typescript
 /**
@@ -3950,10 +4938,23 @@
 	 * The range this link applies to.
 	 */
 	range: Range;
+
 	/**
 	 * The uri this link points to. If missing a resolve request is sent later.
 	 */
 	target?: DocumentUri;
+
+	/**
+	 * The tooltip text when you hover over this link.
+	 *
+	 * If a tooltip is provided, is will be displayed in a string that includes instructions on how to
+	 * trigger the link, such as `{0} (ctrl + click)`. The specific instructions vary depending on OS,
+	 * user settings, and localization.
+	 *
+	 * @since 3.15.0
+	 */
+	tooltip?: string;
+
 	/**
 	 * A data entry field that is preserved on a document link between a
 	 * DocumentLinkRequest and a DocumentLinkResolveRequest.
@@ -3961,19 +4962,9 @@
 	data?: any;
 }
 ```
+* partial result: `DocumentLink[]`
 * error: code and message set in case an exception happens during the document link request.
 
-_Registration Options_: `DocumentLinkRegistrationOptions` defined as follows:
-
-```typescript
-export interface DocumentLinkRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * Document links have a resolve provider as well.
-	 */
-	resolveProvider?: boolean;
-}
-```
-
 #### <a href="#documentLink_resolve" name="documentLink_resolve" class="anchor">Document Link Resolve Request (:leftwards_arrow_with_hook:)</a>
 
 The document link resolve request is sent from the client to the server to resolve the target of a given document link.
@@ -3996,13 +4987,41 @@
 - Color boxes showing the actual color next to the reference
 - Show a color picker when a color reference is edited
 
+_Client Capability_:
+* property name (optional): `textDocument.colorProvider`
+* property type: `DocumentColorClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentColorClientCapabilities {
+	/**
+	 * Whether document color supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `colorProvider`
+* property type: `boolean | DocumentColorOptions | DocumentColorRegistrationOptions` where `DocumentColorOptions` is defined as follows:
+
+```typescript
+export interface DocumentColorOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DocumentColorRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentColorRegistrationOptions extends TextDocumentRegistrationOptions, StaticRegistrationOptions, DocumentColorOptions {
+}
+```
+
 _Request_:
 
 * method: 'textDocument/documentColor'
 * params: `DocumentColorParams` defined as follows
 
-```ts
-interface DocumentColorParams {
+```typescript
+interface DocumentColorParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The text document.
 	 */
@@ -4052,6 +5071,7 @@
 	readonly alpha: number;
 }
 ```
+* partial result: `ColorInformation[]`
 * error: code and message set in case an exception happens during the 'textDocument/documentColor' request
 
 #### <a href="#textDocument_colorPresentation" name="textDocument_colorPresentation" class="anchor">Color Presentation Request (:leftwards_arrow_with_hook:)</a>
@@ -4062,6 +5082,7 @@
 - modify a color reference.
 - show in a color picker and let users pick one of the presentations
 
+This request has no special capabilities and registration options since it is send as a resolve request for the `textDocument/documentColor` request.
 
 _Request_:
 
@@ -4069,7 +5090,7 @@
 * params: `ColorPresentationParams` defined as follows
 
 ```typescript
-interface ColorPresentationParams {
+interface ColorPresentationParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The text document.
 	 */
@@ -4112,18 +5133,47 @@
 }
 ```
 
+* partial result: `ColorPresentation[]`
 * error: code and message set in case an exception happens during the 'textDocument/colorPresentation' request
 
 #### <a href="#textDocument_formatting" name="textDocument_formatting" class="anchor">Document Formatting Request  (:leftwards_arrow_with_hook:)</a>
 
 The document formatting request is sent from the client to the server to format a whole document.
 
+_Client Capability_:
+* property name (optional): `textDocument.formatting`
+* property type: `DocumentFormattingClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentFormattingClientCapabilities {
+	/**
+	 * Whether formatting supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentFormattingProvider`
+* property type: `boolean | DocumentFormattingOptions` where `DocumentFormattingOptions` is defined as follows:
+
+```typescript
+export interface DocumentFormattingOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DocumentFormattingRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentFormattingRegistrationOptions extends TextDocumentRegistrationOptions, DocumentFormattingOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/formatting'
 * params: `DocumentFormattingParams` defined as follows
 
 ```typescript
-interface DocumentFormattingParams {
+interface DocumentFormattingParams extends WorkDoneProgressParams {
 	/**
 	 * The document to format.
 	 */
@@ -4150,6 +5200,27 @@
 	insertSpaces: boolean;
 
 	/**
+	 * Trim trailing whitespace on a line.
+	 *
+	 * @since 3.15.0
+	 */
+	trimTrailingWhitespace?: boolean;
+
+	/**
+	 * Insert a newline character at the end of the file if one does not exist.
+	 *
+	 * @since 3.15.0
+	 */
+	insertFinalNewline?: boolean;
+
+	/**
+	 * Trim all newlines after the final newline at the end of the file.
+	 *
+	 * @since 3.15.0
+	 */
+	trimFinalNewlines?: boolean;
+
+	/**
 	 * Signature for further properties.
 	 */
 	[key: string]: boolean | number | string;
@@ -4160,18 +5231,44 @@
 * result: [`TextEdit[]`](#textedit) \| `null` describing the modification to the document to be formatted.
 * error: code and message set in case an exception happens during the formatting request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_rangeFormatting" name="textDocument_rangeFormatting" class="anchor">Document Range Formatting Request (:leftwards_arrow_with_hook:)</a>
 
 The document range formatting request is sent from the client to the server to format a given range in a document.
 
+_Client Capability_:
+* property name (optional): `textDocument.rangeFormatting`
+* property type: `DocumentRangeFormattingClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentRangeFormattingClientCapabilities {
+	/**
+	 * Whether formatting supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentRangeFormattingProvider`
+* property type: `boolean | DocumentRangeFormattingOptions` where `DocumentRangeFormattingOptions` is defined as follows:
+
+```typescript
+export interface DocumentRangeFormattingOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `DocumentFormattingRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentRangeFormattingRegistrationOptions extends TextDocumentRegistrationOptions, DocumentRangeFormattingOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/rangeFormatting',
 * params: `DocumentRangeFormattingParams` defined as follows:
 
 ```typescript
-interface DocumentRangeFormattingParams {
+interface DocumentRangeFormattingParams extends WorkDoneProgressParams {
 	/**
 	 * The document to format.
 	 */
@@ -4193,28 +5290,53 @@
 * result: [`TextEdit[]`](#textedit) \| `null` describing the modification to the document to be formatted.
 * error: code and message set in case an exception happens during the range formatting request.
 
-_Registration Options_: `TextDocumentRegistrationOptions`
-
 #### <a href="#textDocument_onTypeFormatting" name="textDocument_onTypeFormatting" class="anchor">Document on Type Formatting Request (:leftwards_arrow_with_hook:)</a>
 
 The document on type formatting request is sent from the client to the server to format parts of the document during typing.
 
+_Client Capability_:
+* property name (optional): `textDocument.onTypeFormatting`
+* property type: `DocumentOnTypeFormattingClientCapabilities` defined as follows:
+
+```typescript
+export interface DocumentOnTypeFormattingClientCapabilities {
+	/**
+	 * Whether on type formatting supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `documentOnTypeFormattingProvider`
+* property type: `DocumentOnTypeFormattingOptions` defined as follows:
+
+```typescript
+export interface DocumentOnTypeFormattingOptions {
+	/**
+	 * A character on which formatting should be triggered, like `}`.
+	 */
+	firstTriggerCharacter: string;
+
+	/**
+	 * More trigger characters.
+	 */
+	moreTriggerCharacter?: string[];
+}
+```
+
+_Registration Options_: `DocumentOnTypeFormattingRegistrationOptions` defined as follows:
+```typescript
+export interface DocumentOnTypeFormattingRegistrationOptions extends TextDocumentRegistrationOptions, DocumentOnTypeFormattingOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/onTypeFormatting'
 * params: `DocumentOnTypeFormattingParams` defined as follows:
 
 ```typescript
-interface DocumentOnTypeFormattingParams {
-	/**
-	 * The document to format.
-	 */
-	textDocument: TextDocumentIdentifier;
-
-	/**
-	 * The position at which this request was sent.
-	 */
-	position: Position;
-
+interface DocumentOnTypeFormattingParams extends TextDocumentPositionParams {
 	/**
 	 * The character that has been typed.
 	 */
@@ -4231,40 +5353,58 @@
 * result: [`TextEdit[]`](#textedit) \| `null` describing the modification to the document.
 * error: code and message set in case an exception happens during the range formatting request.
 
-_Registration Options_: `DocumentOnTypeFormattingRegistrationOptions` defined as follows:
-
-```typescript
-export interface DocumentOnTypeFormattingRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * A character on which formatting should be triggered, like `}`.
-	 */
-	firstTriggerCharacter: string;
-	/**
-	 * More trigger characters.
-	 */
-	moreTriggerCharacter?: string[]
-}
-```
 #### <a href="#textDocument_rename" name="textDocument_rename" class="anchor">Rename Request (:leftwards_arrow_with_hook:)</a>
 
 The rename request is sent from the client to the server to ask the server to compute a workspace change so that the client can perform a workspace-wide rename of a symbol.
 
+_Client Capability_:
+* property name (optional): `textDocument.rename`
+* property type: `RenameClientCapabilities` defined as follows:
+
+```typescript
+export interface RenameClientCapabilities {
+	/**
+	 * Whether rename supports dynamic registration.
+	 */
+	dynamicRegistration?: boolean;
+
+	/**
+	 * Client supports testing for validity of rename operations
+	 * before execution.
+	 *
+	 * @since version 3.12.0
+	 */
+	prepareSupport?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `renameProvider`
+* property type: `boolean | RenameOptions` where `RenameOptions` is defined as follows:
+
+`RenameOptions` may only be specified if the client states that it supports `prepareSupport` in its initial `initialize` request.
+
+```typescript
+export interface RenameOptions extends WorkDoneProgressOptions {
+	/**
+	 * Renames should be checked and tested before being executed.
+	 */
+	prepareProvider?: boolean;
+}
+```
+
+_Registration Options_: `RenameRegistrationOptions` defined as follows:
+```typescript
+export interface RenameRegistrationOptions extends TextDocumentRegistrationOptions, RenameOptions {
+}
+```
+
 _Request_:
 * method: 'textDocument/rename'
 * params: `RenameParams` defined as follows
 
 ```typescript
-interface RenameParams {
-	/**
-	 * The document to rename.
-	 */
-	textDocument: TextDocumentIdentifier;
-
-	/**
-	 * The position at which this request was sent.
-	 */
-	position: Position;
-
+interface RenameParams extends TextDocumentPositionParams, WorkDoneProgressParams {
 	/**
 	 * The new name of the symbol. If the given name is not valid the
 	 * request must return a [ResponseError](#ResponseError) with an
@@ -4278,17 +5418,6 @@
 * result: [`WorkspaceEdit`](#workspaceedit) \| `null` describing the modification to the workspace.
 * error: code and message set in case an exception happens during the rename request.
 
-_Registration Options_: `RenameRegistrationOptions` defined as follows:
-
-```typescript
-export interface RenameRegistrationOptions extends TextDocumentRegistrationOptions {
-	/**
-	 * Renames should be checked and tested for validity before being executed.
-	 */
-	prepareProvider?: boolean;
-}
-```
-
 #### <a href="#textDocument_prepareRename" name="textDocument_prepareRename" class="anchor">Prepare Rename Request (:leftwards_arrow_with_hook:)</a>
 
 > *Since version 3.12.0*
@@ -4297,11 +5426,15 @@
 
 _Request_:
 * method: 'textDocument/prepareRename'
-* params: [`TextDocumentPositionParams`](#textdocumentpositionparams)
+* params: `PrepareRenameParams` defined as follows:
+```typescript
+export interface PrepareRenameParams extends TextDocumentPositionParams {
+}
+```
 
 _Response_:
 * result: [`Range`](#range) \| `{ range: Range, placeholder: string }` \| `null` describing the range of the string to rename and optionally a placeholder text of the string content to be renamed. If `null` is returned then it is deemed that a 'textDocument/rename' request is not valid at the given position.
-* error: code and message set in case an exception happens during the prepare rename request.
+* error: code and message set in case the element can't be renamed. Clients should show the information in their user interface.
 
 #### <a href="#textDocument_foldingRange" name="textDocument_foldingRange" class="anchor">Folding Range Request (:leftwards_arrow_with_hook:)</a>
 
@@ -4309,19 +5442,58 @@
 
 The folding range request is sent from the client to the server to return all folding ranges found in a given text document.
 
+_Client Capability_:
+* property name (optional): `textDocument.foldingRange`
+* property type: `FoldingRangeClientCapabilities` defined as follows:
+
+```typescript
+export interface FoldingRangeClientCapabilities {
+	/**
+	 * Whether implementation supports dynamic registration for folding range providers. If this is set to `true`
+	 * the client supports the new `FoldingRangeRegistrationOptions` return value for the corresponding server
+	 * capability as well.
+	 */
+	dynamicRegistration?: boolean;
+	/**
+	 * The maximum number of folding ranges that the client prefers to receive per document. The value serves as a
+	 * hint, servers are free to follow the limit.
+	 */
+	rangeLimit?: number;
+	/**
+	 * If set, the client signals that it only supports folding complete lines. If set, client will
+	 * ignore specified `startCharacter` and `endCharacter` properties in a FoldingRange.
+	 */
+	lineFoldingOnly?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `foldingRangeProvider`
+* property type: `boolean | FoldingRangeOptions | FoldingRangeRegistrationOptions` where `FoldingRangeOptions` is defined as follows:
+
+```typescript
+export interface FoldingRangeOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `FoldingRangeRegistrationOptions` defined as follows:
+```typescript
+export interface FoldingRangeRegistrationOptions extends TextDocumentRegistrationOptions, FoldingRangeOptions, StaticRegistrationOptions {
+}
+```
+
 _Request_:
 
 * method: 'textDocument/foldingRange'
 * params: `FoldingRangeParams` defined as follows
 
 ```typescript
-export interface FoldingRangeParams {
+export interface FoldingRangeParams extends WorkDoneProgressParams, PartialResultParams {
 	/**
 	 * The text document.
 	 */
 	textDocument: TextDocumentIdentifier;
 }
-
 ```
 
 _Response_:
@@ -4380,10 +5552,86 @@
 }
 ```
 
+* partial result: `FoldingRange[]`
 * error: code and message set in case an exception happens during the 'textDocument/foldingRange' request
 
-_Registration Options_: `TextDocumentRegistrationOptions`
+#### <a href="#textDocument_selectionRange" name="textDocument_selectionRange" class="anchor">Selection Range Request (:leftwards_arrow_with_hook:)</a>
 
+> *Since version 3.15.0*
+
+The selection range request is sent from the client to the server to return suggested selection ranges at an array of given positions. A selection range is a range around the cursor position which the user might be interested in selecting.
+
+A selection range in the return array is for the position in the provided parameters at the same index. Therefore positions[i] must be contained in result[i].range.
+
+Typically, but not necessary, selection ranges correspond to the nodes of the syntax tree.
+
+_Client Capability_:
+* property name (optional): `textDocument.selectionRange`
+* property type: `SelectionRangeClientCapabilities` defined as follows:
+
+```typescript
+export interface SelectionRangeClientCapabilities {
+	/**
+	 * Whether implementation supports dynamic registration for selection range providers. If this is set to `true`
+	 * the client supports the new `SelectionRangeRegistrationOptions` return value for the corresponding server
+	 * capability as well.
+	 */
+	dynamicRegistration?: boolean;
+}
+```
+
+_Server Capability_:
+* property name (optional): `selectionRangeProvider`
+* property type: `boolean | SelectionRangeOptions | SelectionRangeRegistrationOptions` where `SelectionRangeOptions` is defined as follows:
+
+```typescript
+export interface SelectionRangeOptions extends WorkDoneProgressOptions {
+}
+```
+
+_Registration Options_: `SelectionRangeRegistrationOptions` defined as follows:
+```typescript
+export interface SelectionRangeRegistrationOptions extends SelectionRangeOptions, TextDocumentRegistrationOptions, StaticRegistrationOptions {
+}
+```
+
+_Request_:
+
+* method: 'textDocument/selectionRange'
+* params: `SelectionRangeParams` defined as follows
+
+```typescript
+export interface SelectionRangeParams extends WorkDoneProgressParams, PartialResultParams {
+	/**
+	 * The text document.
+	 */
+	textDocument: TextDocumentIdentifier;
+
+	/**
+	 * The positions inside the text document.
+	 */
+	positions: Position[];
+}
+```
+
+_Response_:
+* result: `SelectionRange[] | null` defined as follows:
+
+```typescript
+export interface SelectionRange {
+    /**
+     * The [range](#Range) of this selection range.
+     */
+    range: Range;
+    /**
+     * The parent selection range containing this range. Therefore `parent.range` must contain `this.range`.
+     */
+    parent?: SelectionRange;
+}
+```
+
+* partial result: `SelectionRange[]`
+* error: code and message set in case an exception happens during the 'textDocument/selectionRange' request
 
 ### Implementation considerations
 
@@ -4392,10 +5640,28 @@
 - if a client sends a request to the server and the client state changes in a way that the result will be invalid it should cancel the server request and ignore the result. If necessary it can resend the request to receive an up to date result.
 - if a server detects a state change that invalidates the result of a request in execution the server can error these requests with `ContentModified`. If clients receive a `ContentModified` error, it generally should not show it in the UI for the end-user. Clients can resend the request if appropriate.
 - if servers end up in an inconsistent state they should log this to the client using the `window/logMessage` request. If they can't recover from this the best they can do right now is to exit themselves. We are considering an [extension to the protocol](https://github.com/Microsoft/language-server-protocol/issues/646) that allows servers to request a restart on the client side.
-- if a client notices that a server exists unexpectedly it should try to restart the server. However clients should be careful to not restart a crashing server endlessly. VS Code for example doesn't restart a server if it crashes 5 times in the last 180 seconds.
+- if a client notices that a server exits unexpectedly, it should try to restart the server. However clients should be careful not to restart a crashing server endlessly. VS Code, for example, doesn't restart a server which has crashed 5 times in the last 180 seconds.
 
 ### <a href="#changeLog" name="changeLog" class="anchor">Change Log</a>
 
+#### <a href="#version_3_15_0" name="version_3_15_0" class="anchor">3.15.0 (01/14/2020)</a>
+
+* Add generic progress reporting support.
+* Add specific work done progress reporting support to requests where applicable.
+* Add specific partial result progress support to requests where applicable.
+* Add support for `textDocument/selectionRange`.
+* Add support for server and client information.
+* Add signature help context.
+* Add Erlang and Elixir to the list of supported programming languages
+* Add `version` on `PublishDiagnosticsParams`
+* Add `CodeAction#isPreferred` support.
+* Add `CompletionItem#tag` support.
+* Add `Diagnostic#tag` support.
+* Add `DocumentLink#tooltip` support.
+* Add `trimTrailingWhitespace`, `insertFinalNewline` and `trimFinalNewlines` to `FormattingOptions`.
+* Clarified `WorkspaceSymbolParams#query` parameter.
+
+
 #### <a href="#version_3_14_0" name="version_3_14_0" class="anchor">3.14.0 (12/13/2018)</a>
 
 * Add support for signature label offsets.
diff --git a/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart b/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
index d303886..8121590 100644
--- a/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
+++ b/pkg/analysis_server/tool/lsp_spec/typescript_parser.dart
@@ -151,6 +151,7 @@
     this.baseTypes,
     this.members,
   ) : super(comment);
+
   @override
   String get name => nameToken.lexeme;
   String get nameWithTypeArgs => '$name$typeArgsString';
@@ -502,7 +503,9 @@
     if (includeUndefined) {
       types.add(Type.Undefined);
     }
+    var typeIndex = 0;
     while (true) {
+      typeIndex++;
       TypeBase type;
       if (_match([TokenType.LEFT_BRACE])) {
         // Inline interfaces.
@@ -521,7 +524,12 @@
           type = MapType(indexer.indexType, indexer.valueType);
         } else {
           // Add a synthetic interface to the parsers list of nodes to represent this type.
-          final generatedName = _joinNames(containerName, fieldName);
+          // If we have no fieldName to base the synthetic name from, we should use
+          // the index of this type, for example in:
+          //    type Foo = { [..] } | { [...] }
+          // we will generate Foo1 and Foo2 for the types.
+          final nameSuffix = fieldName ?? '$typeIndex';
+          final generatedName = _joinNames(containerName, nameSuffix);
           _nodes.add(InlineInterface(generatedName, members));
           // Record the type as a simple type that references this interface.
           type = Type.identifier(generatedName);
@@ -616,7 +624,9 @@
     final name = _consume(TokenType.IDENTIFIER, 'Expected identifier');
     _consume(TokenType.EQUAL, 'Expected =');
     final type = _type(name.lexeme, null);
-    _consume(TokenType.SEMI_COLON, 'Expected ;');
+    if (!_isAtEnd) {
+      _consume(TokenType.SEMI_COLON, 'Expected ;');
+    }
 
     return TypeAlias(leadingComment, name, type);
   }
@@ -640,8 +650,16 @@
     return _tokens;
   }
 
-  void _addToken(TokenType type) {
-    final text = _source.substring(_startOfToken, _currentPos);
+  void _addToken(TokenType type, {bool mergeSameTypes = false}) {
+    var text = _source.substring(_startOfToken, _currentPos);
+
+    // Consecutive tokens of some types (for example Comments) are merged
+    // together.
+    if (mergeSameTypes && _tokens.isNotEmpty && type == _tokens.last.type) {
+      text = '${_tokens.last.lexeme}\n$text';
+      _tokens.removeLast();
+    }
+
     _tokens.add(Token(type, text));
   }
 
@@ -744,13 +762,13 @@
             _advance();
             _advance();
           }
-          _addToken(TokenType.COMMENT);
+          _addToken(TokenType.COMMENT, mergeSameTypes: true);
         } else if (_match('/')) {
           // Single line comment.
           while (_peek() != '\n' && !_isAtEnd) {
             _advance();
           }
-          _addToken(TokenType.COMMENT);
+          _addToken(TokenType.COMMENT, mergeSameTypes: true);
         } else {
           _addToken(TokenType.SLASH);
         }
diff --git a/pkg/analysis_server/tool/migration_runner.dart b/pkg/analysis_server/tool/migration_runner.dart
index 8b989cd..1edcefa 100644
--- a/pkg/analysis_server/tool/migration_runner.dart
+++ b/pkg/analysis_server/tool/migration_runner.dart
@@ -30,8 +30,8 @@
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/file_system/physical_file_system.dart';
 import 'package:analyzer/instrumentation/instrumentation.dart';
-import 'package:analyzer/src/dart/sdk/sdk.dart';
 import 'package:analyzer/src/generated/sdk.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:path/path.dart' as path;
 import 'package:test/test.dart';
 
@@ -70,9 +70,7 @@
     // Create server
     //
     var options = AnalysisServerOptions();
-    var sdkPath = FolderBasedDartSdk.defaultSdkDirectory(
-      PhysicalResourceProvider.INSTANCE,
-    ).path;
+    var sdkPath = getSdkPath();
     return AnalysisServer(
         serverChannel,
         resourceProvider,
diff --git a/pkg/analysis_server/tool/spec/generated/java/AnalysisServer.java b/pkg/analysis_server/tool/spec/generated/java/AnalysisServer.java
index 388a2c7..ee2d987 100644
--- a/pkg/analysis_server/tool/spec/generated/java/AnalysisServer.java
+++ b/pkg/analysis_server/tool/spec/generated/java/AnalysisServer.java
@@ -469,6 +469,22 @@
   public void diagnostic_getServerPort(GetServerPortConsumer consumer);
 
   /**
+   * {@code edit.bulkFixes}
+   *
+   * Analyze the specified sources for fixes that can be applied in bulk and return a set of
+   * suggested edits for those sources. These edits may include changes to sources outside the set of
+   * specified sources if a change in a specified source requires it.
+   *
+   * @param included A list of the files and directories for which edits should be suggested. If a
+   *         request is made with a path that is invalid, e.g. is not absolute and normalized, an
+   *         error of type INVALID_FILE_PATH_FORMAT will be generated. If a request is made for a
+   *         file which does not exist, or which is not currently subject to analysis (e.g. because
+   *         it is not associated with any analysis root specified to analysis.setAnalysisRoots), an
+   *         error of type FILE_NOT_ANALYZED will be generated.
+   */
+  public void edit_bulkFixes(List<String> included, BulkFixesConsumer consumer);
+
+  /**
    * {@code edit.dartfix}
    *
    * Analyze the specified sources for recommended changes and return a set of suggested edits for
diff --git a/pkg/analysis_server/tool/spec/spec_input.html b/pkg/analysis_server/tool/spec/spec_input.html
index 81cfb21..5a3e9d2 100644
--- a/pkg/analysis_server/tool/spec/spec_input.html
+++ b/pkg/analysis_server/tool/spec/spec_input.html
@@ -2160,6 +2160,44 @@
       </field>
     </result>
   </request>
+  <request method="bulkFixes" experimental="true">
+    <p>
+      Analyze the specified sources for fixes that can be applied in bulk
+      and return a set of suggested edits for those sources.
+      These edits may include changes to sources outside the set
+      of specified sources if a change in a specified source requires it.
+    </p>
+    <params>
+      <field name="included">
+        <list>
+          <ref>FilePath</ref>
+        </list>
+        <p>
+          A list of the files and directories for which edits should be
+          suggested.
+        </p>
+        <p>
+          If a request is made with a path that is invalid, e.g. is not absolute
+          and normalized, an error of type <tt>INVALID_FILE_PATH_FORMAT</tt>
+          will be generated. If a request is made for a file which does not
+          exist, or which is not currently subject to analysis (e.g. because it
+          is not associated with any analysis root specified to
+          analysis.setAnalysisRoots), an error of type
+          <tt>FILE_NOT_ANALYZED</tt> will be generated.
+        </p>
+      </field>
+    </params>
+    <result>
+      <field name="edits">
+        <list>
+          <ref>SourceFileEdit</ref>
+        </list>
+        <p>
+          A list of source edits to apply the recommended changes.
+        </p>
+      </field>
+    </result>
+  </request>
   <request method="dartfix" experimental="true">
     <p>
       Analyze the specified sources for recommended changes
diff --git a/pkg/analysis_server_client/lib/src/protocol/protocol_constants.dart b/pkg/analysis_server_client/lib/src/protocol/protocol_constants.dart
index 2a888ca..2ba9eea 100644
--- a/pkg/analysis_server_client/lib/src/protocol/protocol_constants.dart
+++ b/pkg/analysis_server_client/lib/src/protocol/protocol_constants.dart
@@ -164,6 +164,8 @@
 const String DIAGNOSTIC_REQUEST_GET_SERVER_PORT = 'diagnostic.getServerPort';
 const String DIAGNOSTIC_RESPONSE_GET_DIAGNOSTICS_CONTEXTS = 'contexts';
 const String DIAGNOSTIC_RESPONSE_GET_SERVER_PORT_PORT = 'port';
+const String EDIT_REQUEST_BULK_FIXES = 'edit.bulkFixes';
+const String EDIT_REQUEST_BULK_FIXES_INCLUDED = 'included';
 const String EDIT_REQUEST_DARTFIX = 'edit.dartfix';
 const String EDIT_REQUEST_DARTFIX_EXCLUDED_FIXES = 'excludedFixes';
 const String EDIT_REQUEST_DARTFIX_INCLUDED = 'included';
@@ -220,6 +222,7 @@
 const String EDIT_REQUEST_ORGANIZE_DIRECTIVES_FILE = 'file';
 const String EDIT_REQUEST_SORT_MEMBERS = 'edit.sortMembers';
 const String EDIT_REQUEST_SORT_MEMBERS_FILE = 'file';
+const String EDIT_RESPONSE_BULK_FIXES_EDITS = 'edits';
 const String EDIT_RESPONSE_DARTFIX_DETAILS = 'details';
 const String EDIT_RESPONSE_DARTFIX_EDITS = 'edits';
 const String EDIT_RESPONSE_DARTFIX_HAS_ERRORS = 'hasErrors';
diff --git a/pkg/analysis_server_client/lib/src/protocol/protocol_generated.dart b/pkg/analysis_server_client/lib/src/protocol/protocol_generated.dart
index a9a1cf0..29ae9ac 100644
--- a/pkg/analysis_server_client/lib/src/protocol/protocol_generated.dart
+++ b/pkg/analysis_server_client/lib/src/protocol/protocol_generated.dart
@@ -7115,6 +7115,180 @@
   }
 }
 
+/// edit.bulkFixes params
+///
+/// {
+///   "included": List<FilePath>
+/// }
+///
+/// Clients may not extend, implement or mix-in this class.
+class EditBulkFixesParams implements RequestParams {
+  List<String> _included;
+
+  /// A list of the files and directories for which edits should be suggested.
+  ///
+  /// If a request is made with a path that is invalid, e.g. is not absolute
+  /// and normalized, an error of type INVALID_FILE_PATH_FORMAT will be
+  /// generated. If a request is made for a file which does not exist, or which
+  /// is not currently subject to analysis (e.g. because it is not associated
+  /// with any analysis root specified to analysis.setAnalysisRoots), an error
+  /// of type FILE_NOT_ANALYZED will be generated.
+  List<String> get included => _included;
+
+  /// A list of the files and directories for which edits should be suggested.
+  ///
+  /// If a request is made with a path that is invalid, e.g. is not absolute
+  /// and normalized, an error of type INVALID_FILE_PATH_FORMAT will be
+  /// generated. If a request is made for a file which does not exist, or which
+  /// is not currently subject to analysis (e.g. because it is not associated
+  /// with any analysis root specified to analysis.setAnalysisRoots), an error
+  /// of type FILE_NOT_ANALYZED will be generated.
+  set included(List<String> value) {
+    assert(value != null);
+    _included = value;
+  }
+
+  EditBulkFixesParams(List<String> included) {
+    this.included = included;
+  }
+
+  factory EditBulkFixesParams.fromJson(
+      JsonDecoder jsonDecoder, String jsonPath, Object json) {
+    json ??= {};
+    if (json is Map) {
+      List<String> included;
+      if (json.containsKey('included')) {
+        included = jsonDecoder.decodeList(
+            jsonPath + '.included', json['included'], jsonDecoder.decodeString);
+      } else {
+        throw jsonDecoder.mismatch(jsonPath, 'included');
+      }
+      return EditBulkFixesParams(included);
+    } else {
+      throw jsonDecoder.mismatch(jsonPath, 'edit.bulkFixes params', json);
+    }
+  }
+
+  factory EditBulkFixesParams.fromRequest(Request request) {
+    return EditBulkFixesParams.fromJson(
+        RequestDecoder(request), 'params', request.params);
+  }
+
+  @override
+  Map<String, dynamic> toJson() {
+    var result = <String, dynamic>{};
+    result['included'] = included;
+    return result;
+  }
+
+  @override
+  Request toRequest(String id) {
+    return Request(id, 'edit.bulkFixes', toJson());
+  }
+
+  @override
+  String toString() => json.encode(toJson());
+
+  @override
+  bool operator ==(other) {
+    if (other is EditBulkFixesParams) {
+      return listEqual(
+          included, other.included, (String a, String b) => a == b);
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, included.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+}
+
+/// edit.bulkFixes result
+///
+/// {
+///   "edits": List<SourceFileEdit>
+/// }
+///
+/// Clients may not extend, implement or mix-in this class.
+class EditBulkFixesResult implements ResponseResult {
+  List<SourceFileEdit> _edits;
+
+  /// A list of source edits to apply the recommended changes.
+  List<SourceFileEdit> get edits => _edits;
+
+  /// A list of source edits to apply the recommended changes.
+  set edits(List<SourceFileEdit> value) {
+    assert(value != null);
+    _edits = value;
+  }
+
+  EditBulkFixesResult(List<SourceFileEdit> edits) {
+    this.edits = edits;
+  }
+
+  factory EditBulkFixesResult.fromJson(
+      JsonDecoder jsonDecoder, String jsonPath, Object json) {
+    json ??= {};
+    if (json is Map) {
+      List<SourceFileEdit> edits;
+      if (json.containsKey('edits')) {
+        edits = jsonDecoder.decodeList(
+            jsonPath + '.edits',
+            json['edits'],
+            (String jsonPath, Object json) =>
+                SourceFileEdit.fromJson(jsonDecoder, jsonPath, json));
+      } else {
+        throw jsonDecoder.mismatch(jsonPath, 'edits');
+      }
+      return EditBulkFixesResult(edits);
+    } else {
+      throw jsonDecoder.mismatch(jsonPath, 'edit.bulkFixes result', json);
+    }
+  }
+
+  factory EditBulkFixesResult.fromResponse(Response response) {
+    return EditBulkFixesResult.fromJson(
+        ResponseDecoder(REQUEST_ID_REFACTORING_KINDS.remove(response.id)),
+        'result',
+        response.result);
+  }
+
+  @override
+  Map<String, dynamic> toJson() {
+    var result = <String, dynamic>{};
+    result['edits'] =
+        edits.map((SourceFileEdit value) => value.toJson()).toList();
+    return result;
+  }
+
+  @override
+  Response toResponse(String id) {
+    return Response(id, result: toJson());
+  }
+
+  @override
+  String toString() => json.encode(toJson());
+
+  @override
+  bool operator ==(other) {
+    if (other is EditBulkFixesResult) {
+      return listEqual(
+          edits, other.edits, (SourceFileEdit a, SourceFileEdit b) => a == b);
+    }
+    return false;
+  }
+
+  @override
+  int get hashCode {
+    var hash = 0;
+    hash = JenkinsSmiHash.combine(hash, edits.hashCode);
+    return JenkinsSmiHash.finish(hash);
+  }
+}
+
 /// edit.dartfix params
 ///
 /// {
diff --git a/pkg/analyzer/CHANGELOG.md b/pkg/analyzer/CHANGELOG.md
index ce3906e..c5d67c1 100644
--- a/pkg/analyzer/CHANGELOG.md
+++ b/pkg/analyzer/CHANGELOG.md
@@ -1,6 +1,29 @@
-## 0.39.13-dev
+## 0.39.15-dev
+* Move `asInstanceOf(ClassElement)` to `DartType`, so that it is also
+  supported for `TypeParameterType` when its bound implements the
+  requested interface.
+
+## 0.39.14
+* Removed `defaultSdkDirectory()` and `getSdkProperty()` from internal
+  `FolderBasedDartSdk`. It is up to the clients to decide how to
+  find SDK, for example using `package:cli_util`.
+* Fixed `LintDriver` for the new way to access `WorkspacePackage`.
+* Deprecated `Scope.lookup()`, use `Scope.lookup2()` instead.
+* Updated implementations of `ContextBuilder.createContext()` and
+  `ContextLocator.locateContexts` to use the current SDK if `sdkPath`
+  is not provided.
+* Bug fixes: #41981, #29731, #42720, #33545, #42599, #42699.
+
+## 0.39.13
 * Added 'dart/sdk/build_sdk_summary.dart' with `buildSdkSummary`.
 * Added `DynamicType`, `NeverType`, and `VoidType` interfaces.
+* Added `TypeVisitor` and `DartType.accept(TypeVisitor)`.
+* Changed `ConstructorElement.returnType` to `InterfaceType`.
+* Added `InterfaceType.allSupertypes`.
+* Added `InterfaceType.asInstanceOf(ClassElement)`.
+* Removed deprecated internal `bogus-disabled` and `bogus-enabled`.
+* Added `Scope`, `LibraryElement.scope`, and `PrefixElement.scope`.
+* Bug fixes: #32192, #42620, #42256, #42605.
 
 ## 0.39.12
 * Deprecated `canUseSummaries` in `DartSdkManager` constructor.
diff --git a/pkg/analyzer/analysis_options.yaml b/pkg/analyzer/analysis_options.yaml
index fe59776..4258c77 100644
--- a/pkg/analyzer/analysis_options.yaml
+++ b/pkg/analyzer/analysis_options.yaml
@@ -14,8 +14,22 @@
     # There are currently 2000 violations in lib/.
     unnecessary_this: ignore
 
+    # "strict-inference" is enabled, but "unused" parameters named '_' are
+    # still reported.  Re-evaluate after
+    # https://github.com/dart-lang/language/pull/599 and a functional fix land.
+    inference_failure_on_untyped_parameter: ignore
+    # There are about 10k violations in test/ due to missing return types on
+    # test methods. It would be nice to mark this code as
+    # "ignored for test/**/*.dart".
+    inference_failure_on_function_return_type: ignore
+
+  language:
+    strict-inference: true
+
 linter:
   rules:
     - avoid_unused_constructor_parameters
     - empty_statements
+    - prefer_typing_uninitialized_variables
     - unnecessary_brace_in_string_interps
+    - unnecessary_parenthesis
diff --git a/pkg/analyzer/doc/tutorial/analysis.md b/pkg/analyzer/doc/tutorial/analysis.md
index c72050d..dde9f45 100644
--- a/pkg/analyzer/doc/tutorial/analysis.md
+++ b/pkg/analyzer/doc/tutorial/analysis.md
@@ -48,14 +48,14 @@
 to analyze.
 
 ```dart
-main() {
+void main() {
   List<String> includedPaths = <String>[/* ... */];
   AnalysisContextCollection collection =
       new AnalysisContextCollection(includedPaths: includedPaths);
   analyzeSomeFiles(collection, includedPaths);
 }
 
-analyzeSomeFiles(
+void analyzeSomeFiles(
     AnalysisContextCollection collection, List<String> includedPaths) {
   // See below.
 }
@@ -77,7 +77,7 @@
 analysis with the following:
 
 ```dart
-analyzeSomeFiles(
+void analyzeSomeFiles(
     AnalysisContextCollection collection, List<String> includedPaths) {
   for (String path in includedPaths) {
     AnalysisContext context = collection.contextFor(path);
@@ -85,7 +85,7 @@
   }
 }
 
-analyzeSingleFile(AnalysisContext context, String path) {
+void analyzeSingleFile(AnalysisContext context, String path) {
   // See below.
 }
 ```
@@ -97,7 +97,7 @@
 different API:
 
 ```dart
-analyzeAllFiles(AnalysisContextCollection collection) {
+void analyzeAllFiles(AnalysisContextCollection collection) {
   for (AnalysisContext context in collection.contexts) {
     for (String path in context.contextRoot.analyzedFiles()) {
       analyzeSingleFile(context, path);
@@ -105,7 +105,7 @@
   }
 }
 
-analyzeSingleFile(AnalysisContext context, String path) {
+void analyzeSingleFile(AnalysisContext context, String path) {
   // See below.
 }
 ```
@@ -123,7 +123,7 @@
 perform the analysis.
 
 ```dart
-analyzeSingleFile(AnalysisContext context, String path) {
+void analyzeSingleFile(AnalysisContext context, String path) {
   AnalysisSession session = context.currentSession;
   // ...
 }
diff --git a/pkg/analyzer/doc/tutorial/ast.md b/pkg/analyzer/doc/tutorial/ast.md
index 57af577..e39a89b 100644
--- a/pkg/analyzer/doc/tutorial/ast.md
+++ b/pkg/analyzer/doc/tutorial/ast.md
@@ -54,7 +54,7 @@
 the AST:
 
 ```dart
-processFile(AnalysisSession session, String path) {
+void processFile(AnalysisSession session, String path) {
   ParsedUnitResult result = session.getParsedUnit(path);
   CompilationUnit unit = result.unit;
 }
@@ -64,7 +64,7 @@
 method to access it:
 
 ```dart
-processFile(AnalysisSession session, String path) async {
+void processFile(AnalysisSession session, String path) async {
   ResolvedUnitResult result = await session.getResolvedUnit(path);
   CompilationUnit unit = result.unit;
 }
diff --git a/pkg/analyzer/doc/tutorial/element.md b/pkg/analyzer/doc/tutorial/element.md
index 88db476..5464d12 100644
--- a/pkg/analyzer/doc/tutorial/element.md
+++ b/pkg/analyzer/doc/tutorial/element.md
@@ -45,7 +45,7 @@
 ask the analysis session for the compilation unit representing that file.
 
 ```dart
-analyzeSingleFile(AnalysisSession session, String path) async {
+void analyzeSingleFile(AnalysisSession session, String path) async {
   UnitElementResult result = await session.getUnitElement(path);
   CompilationUnitElement element = result.element;
 }
diff --git a/pkg/analyzer/lib/dart/element/element.dart b/pkg/analyzer/lib/dart/element/element.dart
index e25a5b3..12f85cc 100644
--- a/pkg/analyzer/lib/dart/element/element.dart
+++ b/pkg/analyzer/lib/dart/element/element.dart
@@ -37,6 +37,7 @@
 import 'package:analyzer/dart/analysis/session.dart';
 import 'package:analyzer/dart/constant/value.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/dart/element/type_system.dart';
@@ -487,6 +488,9 @@
   /// if this constructor does not redirect to another constructor or if the
   /// library containing this constructor has not yet been resolved.
   ConstructorElement get redirectedConstructor;
+
+  @override
+  InterfaceType get returnType;
 }
 
 /// The base class for all of the elements in the element model. Generally
@@ -1372,6 +1376,10 @@
   /// computed yet.
   Namespace get publicNamespace;
 
+  /// Return the name lookup scope for this library. It consists of elements
+  /// that are either declared in the library, or imported into it.
+  Scope get scope;
+
   /// Return the top-level elements defined in each of the compilation units
   /// that are included in this library. This includes both public and private
   /// elements, but does not include imports, exports, or synthetic elements.
@@ -1571,6 +1579,11 @@
 abstract class PrefixElement implements Element {
   @override
   LibraryElement get enclosingElement;
+
+  /// Return the name lookup scope for this import prefix. It consists of
+  /// elements imported into the enclosing library with this prefix. The
+  /// namespace combinators of the import directives are taken into account.
+  Scope get scope;
 }
 
 /// A variable that might be subject to type promotion.  This might be a local
diff --git a/pkg/analyzer/lib/dart/element/scope.dart b/pkg/analyzer/lib/dart/element/scope.dart
new file mode 100644
index 0000000..ee35529
--- /dev/null
+++ b/pkg/analyzer/lib/dart/element/scope.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.
+
+import 'package:analyzer/dart/element/element.dart';
+import 'package:meta/meta.dart';
+
+/// Scopes are used to resolve names to elements.
+abstract class Scope {
+  /// Return the element with the name `id` or `id=` (if [setter] is `true`),
+  /// `null` if the name is not defined within this scope.
+  @Deprecated('Use lookup2() that is closer to the language specification')
+  Element lookup({@required String id, @required bool setter});
+
+  /// Return the result of lexical lookup for the given [id], not `null`.
+  ///
+  /// Getters and setters are bundled, when we found one or another, we are
+  /// done with the lookup, and return both the getter and the setter, if
+  /// available.
+  ScopeLookupResult lookup2(String id);
+}
+
+class ScopeLookupResult {
+  final Element getter;
+  final Element setter;
+
+  ScopeLookupResult(this.getter, this.setter);
+}
diff --git a/pkg/analyzer/lib/dart/element/type.dart b/pkg/analyzer/lib/dart/element/type.dart
index e3d864e..e15d880 100644
--- a/pkg/analyzer/lib/dart/element/type.dart
+++ b/pkg/analyzer/lib/dart/element/type.dart
@@ -21,6 +21,7 @@
 /// the references to `String` and `int` are type arguments.
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart' show InterfaceTypeImpl;
 
 /// The type associated with elements in the element model.
@@ -122,6 +123,26 @@
   /// Return the nullability suffix of this type.
   NullabilitySuffix get nullabilitySuffix;
 
+  /// Use the given [visitor] to visit this type.
+  R accept<R>(TypeVisitor<R> visitor);
+
+  /// Return the canonical interface that this type implements for [element],
+  /// or `null` if such an interface does not exist.
+  ///
+  /// For example, given the following definitions
+  /// ```
+  /// class A<E> {}
+  /// class B<E> implements A<E> {}
+  /// class C implements A<String> {}
+  /// ```
+  /// Asking the type `B<int>` for the type associated with `A` will return the
+  /// type `A<int>`. Asking the type `C` for the type associated with `A` will
+  /// return the type `A<String>`.
+  ///
+  /// For a [TypeParameterType] with a bound (declared or promoted), returns
+  /// the interface implemented by the bound.
+  InterfaceType asInstanceOf(ClassElement element);
+
   /// Return the presentation of this type as it should appear when presented
   /// to users in contexts such as error messages.
   ///
@@ -257,6 +278,10 @@
   /// declared in this type.
   List<PropertyAccessorElement> get accessors;
 
+  /// Return all the super-interfaces implemented by this interface. This
+  /// includes superclasses, mixins, interfaces, and superclass constraints.
+  List<InterfaceType> get allSupertypes;
+
   /// Return a list containing all of the constructors declared in this type.
   List<ConstructorElement> get constructors;
 
diff --git a/pkg/analyzer/lib/dart/element/type_visitor.dart b/pkg/analyzer/lib/dart/element/type_visitor.dart
new file mode 100644
index 0000000..d23115d
--- /dev/null
+++ b/pkg/analyzer/lib/dart/element/type_visitor.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 'package:analyzer/dart/element/type.dart';
+
+/// Interface for type visitors.
+///
+/// Clients may not extend, implement, or mix-in this class.
+abstract class TypeVisitor<R> {
+  const TypeVisitor();
+
+  R visitDynamicType(DynamicType type);
+
+  R visitFunctionType(FunctionType type);
+
+  R visitInterfaceType(InterfaceType type);
+
+  R visitNeverType(NeverType type);
+
+  R visitTypeParameterType(TypeParameterType type);
+
+  R visitVoidType(VoidType type);
+}
+
+/// Invokes [visitDartType] from any other `visitXyz` method.
+///
+/// Clients may extend this class.
+abstract class UnifyingTypeVisitor<R> implements TypeVisitor<R> {
+  const UnifyingTypeVisitor();
+
+  /// By default other `visitXyz` methods invoke this method.
+  R visitDartType(DartType type);
+
+  @override
+  R visitDynamicType(DynamicType type) => visitDartType(type);
+
+  @override
+  R visitFunctionType(FunctionType type) => visitDartType(type);
+
+  @override
+  R visitInterfaceType(InterfaceType type) => visitDartType(type);
+
+  @override
+  R visitNeverType(NeverType type) => visitDartType(type);
+
+  @override
+  R visitTypeParameterType(TypeParameterType type) => visitDartType(type);
+
+  @override
+  R visitVoidType(VoidType type) => visitDartType(type);
+}
diff --git a/pkg/analyzer/lib/error/error.dart b/pkg/analyzer/lib/error/error.dart
index d675223..fbd5b03 100644
--- a/pkg/analyzer/lib/error/error.dart
+++ b/pkg/analyzer/lib/error/error.dart
@@ -169,6 +169,8 @@
   CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_BOUND,
   CompileTimeErrorCode.GENERIC_FUNCTION_TYPE_CANNOT_BE_TYPE_ARGUMENT,
   CompileTimeErrorCode.IF_ELEMENT_CONDITION_FROM_DEFERRED_LIBRARY,
+  CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE,
+  CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE,
   CompileTimeErrorCode.IMPLEMENTS_DEFERRED_CLASS,
   CompileTimeErrorCode.IMPLEMENTS_DISALLOWED_CLASS,
   CompileTimeErrorCode.IMPLEMENTS_NON_CLASS,
@@ -180,6 +182,7 @@
   CompileTimeErrorCode.INCONSISTENT_CASE_EXPRESSION_TYPES,
   CompileTimeErrorCode.INCONSISTENT_INHERITANCE,
   CompileTimeErrorCode.INCONSISTENT_INHERITANCE_GETTER_AND_METHOD,
+  CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE,
   CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD,
   CompileTimeErrorCode.INITIALIZER_FOR_STATIC_FIELD,
   CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD,
@@ -192,6 +195,14 @@
   CompileTimeErrorCode.INVALID_ANNOTATION,
   CompileTimeErrorCode.INVALID_ANNOTATION_FROM_DEFERRED_LIBRARY,
   CompileTimeErrorCode.INVALID_ANNOTATION_GETTER,
+  CompileTimeErrorCode.INVALID_CAST_FUNCTION,
+  CompileTimeErrorCode.INVALID_CAST_FUNCTION_EXPR,
+  CompileTimeErrorCode.INVALID_CAST_LITERAL,
+  CompileTimeErrorCode.INVALID_CAST_LITERAL_LIST,
+  CompileTimeErrorCode.INVALID_CAST_LITERAL_MAP,
+  CompileTimeErrorCode.INVALID_CAST_LITERAL_SET,
+  CompileTimeErrorCode.INVALID_CAST_METHOD,
+  CompileTimeErrorCode.INVALID_CAST_NEW_EXPR,
   CompileTimeErrorCode.INVALID_CONSTANT,
   CompileTimeErrorCode.INVALID_CONSTRUCTOR_NAME,
   CompileTimeErrorCode.INVALID_EXTENSION_ARGUMENT_COUNT,
@@ -239,6 +250,7 @@
   CompileTimeErrorCode.MIXIN_SUPER_CLASS_CONSTRAINT_DISALLOWED_CLASS,
   CompileTimeErrorCode.MIXIN_SUPER_CLASS_CONSTRAINT_NON_INTERFACE,
   CompileTimeErrorCode.MIXIN_WITH_NON_CLASS_SUPERCLASS,
+  CompileTimeErrorCode.MIXINS_SUPER_CLASS,
   CompileTimeErrorCode.MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS,
   CompileTimeErrorCode.MULTIPLE_SUPER_INITIALIZERS,
   CompileTimeErrorCode.NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS,
@@ -270,6 +282,7 @@
   CompileTimeErrorCode.NOT_INITIALIZED_NON_NULLABLE_INSTANCE_FIELD,
   CompileTimeErrorCode.NOT_INITIALIZED_NON_NULLABLE_INSTANCE_FIELD_CONSTRUCTOR,
   CompileTimeErrorCode.NOT_INITIALIZED_NON_NULLABLE_VARIABLE,
+  CompileTimeErrorCode.NOT_INSTANTIATED_BOUND,
   CompileTimeErrorCode.NOT_ITERABLE_SPREAD,
   CompileTimeErrorCode.NOT_MAP_SPREAD,
   CompileTimeErrorCode.NOT_NULL_AWARE_NULL_SPREAD,
@@ -284,8 +297,10 @@
   CompileTimeErrorCode.PART_OF_UNNAMED_LIBRARY,
   CompileTimeErrorCode.PREFIX_COLLIDES_WITH_TOP_LEVEL_MEMBER,
   CompileTimeErrorCode.PREFIX_IDENTIFIER_NOT_FOLLOWED_BY_DOT,
+  CompileTimeErrorCode.PREFIX_SHADOWED_BY_LOCAL_DECLARATION,
   CompileTimeErrorCode.PRIVATE_COLLISION_IN_MIXIN_APPLICATION,
   CompileTimeErrorCode.PRIVATE_OPTIONAL_PARAMETER,
+  CompileTimeErrorCode.PRIVATE_SETTER,
   CompileTimeErrorCode.RECURSIVE_COMPILE_TIME_CONSTANT,
   CompileTimeErrorCode.RECURSIVE_CONSTRUCTOR_REDIRECT,
   CompileTimeErrorCode.RECURSIVE_FACTORY_REDIRECT,
@@ -460,6 +475,7 @@
   HintCode.UNUSED_CATCH_CLAUSE,
   HintCode.UNUSED_CATCH_STACK,
   HintCode.UNUSED_ELEMENT,
+  HintCode.UNUSED_ELEMENT_PARAMETER,
   HintCode.UNUSED_FIELD,
   HintCode.UNUSED_IMPORT,
   HintCode.UNUSED_LABEL,
@@ -693,9 +709,7 @@
   StaticTypeWarningCode.EXPECTED_TWO_MAP_TYPE_ARGUMENTS,
   StaticTypeWarningCode.FOR_IN_OF_INVALID_ELEMENT_TYPE,
   StaticTypeWarningCode.FOR_IN_OF_INVALID_TYPE,
-  StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE,
   StaticTypeWarningCode.ILLEGAL_ASYNC_RETURN_TYPE,
-  StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE,
   StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER,
   StaticTypeWarningCode.INVALID_ASSIGNMENT,
   StaticTypeWarningCode.INVOCATION_OF_NON_FUNCTION,
@@ -743,7 +757,6 @@
   // ignore: deprecated_member_use_from_same_package
   StaticWarningCode.CONST_WITH_ABSTRACT_CLASS,
   StaticWarningCode.DEAD_NULL_AWARE_EXPRESSION,
-  StaticWarningCode.EXPORT_DUPLICATED_LIBRARY_NAMED,
   // ignore: deprecated_member_use_from_same_package
   StaticWarningCode.EXTRA_POSITIONAL_ARGUMENTS,
   // ignore: deprecated_member_use_from_same_package
@@ -758,11 +771,11 @@
   StaticWarningCode.FINAL_NOT_INITIALIZED_CONSTRUCTOR_3_PLUS,
   StaticWarningCode.GETTER_NOT_ASSIGNABLE_SETTER_TYPES,
   StaticWarningCode.GETTER_NOT_SUBTYPE_SETTER_TYPES,
-  StaticWarningCode.IMPORT_DUPLICATED_LIBRARY_NAMED,
   // ignore: deprecated_member_use_from_same_package
   StaticWarningCode.IMPORT_OF_NON_LIBRARY,
   StaticWarningCode.INSTANTIATE_ABSTRACT_CLASS,
   StaticWarningCode.INVALID_NULL_AWARE_OPERATOR,
+  StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
   StaticWarningCode.INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_NAMED,
   StaticWarningCode.INVALID_OVERRIDE_DIFFERENT_DEFAULT_VALUES_POSITIONAL,
   StaticWarningCode.INVALID_USE_OF_NULL_VALUE,
@@ -814,7 +827,6 @@
   StaticWarningCode.UNNECESSARY_NON_NULL_ASSERTION,
   StaticWarningCode.USE_OF_VOID_RESULT,
   StrongModeCode.COULD_NOT_INFER,
-  StrongModeCode.DYNAMIC_INVOKE,
   StrongModeCode.IMPLICIT_DYNAMIC_FIELD,
   StrongModeCode.IMPLICIT_DYNAMIC_FUNCTION,
   StrongModeCode.IMPLICIT_DYNAMIC_INVOKE,
@@ -825,17 +837,8 @@
   StrongModeCode.IMPLICIT_DYNAMIC_RETURN,
   StrongModeCode.IMPLICIT_DYNAMIC_TYPE,
   StrongModeCode.IMPLICIT_DYNAMIC_VARIABLE,
-  StrongModeCode.INVALID_CAST_FUNCTION,
-  StrongModeCode.INVALID_CAST_FUNCTION_EXPR,
-  StrongModeCode.INVALID_CAST_LITERAL,
-  StrongModeCode.INVALID_CAST_LITERAL_LIST,
-  StrongModeCode.INVALID_CAST_LITERAL_MAP,
-  StrongModeCode.INVALID_CAST_LITERAL_SET,
-  StrongModeCode.INVALID_CAST_METHOD,
-  StrongModeCode.INVALID_CAST_NEW_EXPR,
   StrongModeCode.INVALID_PARAMETER_DECLARATION,
   StrongModeCode.INVALID_SUPER_INVOCATION,
-  StrongModeCode.NOT_INSTANTIATED_BOUND,
   StrongModeCode.TOP_LEVEL_CYCLE,
   StrongModeCode.TOP_LEVEL_FUNCTION_LITERAL_BLOCK,
   StrongModeCode.TOP_LEVEL_IDENTIFIER_NO_TYPE,
diff --git a/pkg/analyzer/lib/exception/exception.dart b/pkg/analyzer/lib/exception/exception.dart
index 6a2bd6c..8f3a1af 100644
--- a/pkg/analyzer/lib/exception/exception.dart
+++ b/pkg/analyzer/lib/exception/exception.dart
@@ -41,12 +41,13 @@
 
   /// Initialize a newly created caught exception to have the given [exception]
   /// and [stackTrace].
-  CaughtException(exception, stackTrace)
+  CaughtException(Object exception, StackTrace stackTrace)
       : this.withMessage(null, exception, stackTrace);
 
   /// Initialize a newly created caught exception to have the given [exception],
   /// [stackTrace], and [message].
-  CaughtException.withMessage(this.message, this.exception, stackTrace)
+  CaughtException.withMessage(
+      this.message, this.exception, StackTrace stackTrace)
       : this.stackTrace = stackTrace ?? StackTrace.current;
 
   /// Recursively unwrap this [CaughtException] if it itself contains a
@@ -98,7 +99,7 @@
 /// This is still considered an exceptional situation and will be sent to crash
 /// reporting.
 class SilentException extends CaughtException {
-  SilentException(String message, exception, stackTrace)
+  SilentException(String message, Object exception, StackTrace stackTrace)
       : super.withMessage(message, exception, stackTrace);
 
   /// Create a [SilentException] to wrap a [CaughtException], adding a
diff --git a/pkg/analyzer/lib/file_system/memory_file_system.dart b/pkg/analyzer/lib/file_system/memory_file_system.dart
index 1781738..9baa63a 100644
--- a/pkg/analyzer/lib/file_system/memory_file_system.dart
+++ b/pkg/analyzer/lib/file_system/memory_file_system.dart
@@ -28,12 +28,12 @@
 
   MemoryResourceProvider(
       {pathos.Context context, @deprecated bool isWindows = false})
-      : _pathContext = (context ??= pathos.style == pathos.Style.windows
+      : _pathContext = context ??= pathos.style == pathos.Style.windows
             // On Windows, ensure that the current drive matches
             // the drive inserted by MemoryResourceProvider.convertPath
             // so that packages are mapped to the correct drive
             ? pathos.Context(current: 'C:\\')
-            : pathos.context);
+            : pathos.context;
 
   @override
   pathos.Context get pathContext => _pathContext;
@@ -584,11 +584,11 @@
   String get shortName => _provider.pathContext.basename(path);
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     if (runtimeType != other.runtimeType) {
       return false;
     }
-    return path == other.path;
+    return path == (other as _MemoryResource).path;
   }
 
   @override
diff --git a/pkg/analyzer/lib/file_system/overlay_file_system.dart b/pkg/analyzer/lib/file_system/overlay_file_system.dart
index 601b913..2b12574 100644
--- a/pkg/analyzer/lib/file_system/overlay_file_system.dart
+++ b/pkg/analyzer/lib/file_system/overlay_file_system.dart
@@ -369,11 +369,11 @@
   String get shortName => _resource.shortName;
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     if (runtimeType != other.runtimeType) {
       return false;
     }
-    return path == other.path;
+    return path == (other as _OverlayResource).path;
   }
 
   @override
diff --git a/pkg/analyzer/lib/file_system/physical_file_system.dart b/pkg/analyzer/lib/file_system/physical_file_system.dart
index bd914e2..2e5f628 100644
--- a/pkg/analyzer/lib/file_system/physical_file_system.dart
+++ b/pkg/analyzer/lib/file_system/physical_file_system.dart
@@ -241,7 +241,7 @@
 
   @override
   Stream<WatchEvent> get changes =>
-      DirectoryWatcher(_entry.path).events.handleError((error) {},
+      DirectoryWatcher(_entry.path).events.handleError((Object error) {},
           test: (error) =>
               error is io.FileSystemException &&
               // Don't suppress "Directory watcher closed," so the outer
@@ -378,11 +378,11 @@
   String get shortName => pathContext.basename(path);
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     if (runtimeType != other.runtimeType) {
       return false;
     }
-    return path == other.path;
+    return path == (other as _PhysicalResource).path;
   }
 
   @override
diff --git a/pkg/analyzer/lib/instrumentation/multicast_service.dart b/pkg/analyzer/lib/instrumentation/multicast_service.dart
index d0e288d..995dbfe 100644
--- a/pkg/analyzer/lib/instrumentation/multicast_service.dart
+++ b/pkg/analyzer/lib/instrumentation/multicast_service.dart
@@ -17,7 +17,7 @@
   }
 
   @override
-  void logException(exception,
+  void logException(Object exception,
       [StackTrace stackTrace,
       List<InstrumentationServiceAttachment> attachments]) {
     _services
@@ -49,7 +49,8 @@
   }
 
   @override
-  void logPluginException(PluginData plugin, exception, StackTrace stackTrace) {
+  void logPluginException(
+      PluginData plugin, Object exception, StackTrace stackTrace) {
     _services
         .forEach((s) => s.logPluginException(plugin, exception, stackTrace));
   }
diff --git a/pkg/analyzer/lib/src/clients/angular_analyzer_plugin/angular_analyzer_plugin.dart b/pkg/analyzer/lib/src/clients/angular_analyzer_plugin/angular_analyzer_plugin.dart
new file mode 100644
index 0000000..abedb68
--- /dev/null
+++ b/pkg/analyzer/lib/src/clients/angular_analyzer_plugin/angular_analyzer_plugin.dart
@@ -0,0 +1,106 @@
+// 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.
+
+/// This library provides additional APIs for the corresponding client.
+///
+/// By providing such higher level APIs we simplify the clients, and reduce
+/// dependencies on analyzer internal, so can make otherwise breaking
+/// changes easily.
+library angular_analyzer_plugin;
+
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/error/listener.dart';
+import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
+import 'package:analyzer/src/dart/resolver/resolution_visitor.dart';
+import 'package:analyzer/src/generated/error_verifier.dart';
+import 'package:analyzer/src/generated/resolver.dart';
+import 'package:analyzer/src/generated/source.dart';
+import 'package:meta/meta.dart';
+
+/// Resolve the given [node] in the specified context.
+///
+/// The [componentClass] is the component class.
+///
+/// The [templateSource] is the file with the template.
+///
+/// The template might declare [localVariables], which might be referenced
+/// in the node being resolved.
+///
+/// The [overrideAsExpression] is invoked during [AsExpression] to support
+/// custom resolution behavior.
+void resolveTemplateNode({
+  @required ClassElement componentClass,
+  @required Source templateSource,
+  @required Iterable<LocalVariableElement> localVariables,
+  @required AstNode node,
+  @required AnalysisErrorListener errorListener,
+  @required ErrorReporter errorReporter,
+  OverrideAsExpression overrideAsExpression,
+}) {
+  final unitElement = componentClass.enclosingElement;
+  final library = componentClass.library;
+
+  node.accept(
+    ResolutionVisitor(
+      unitElement: unitElement,
+      errorListener: errorListener,
+      featureSet: library.context.analysisOptions.contextFeatures,
+      nameScope: library.scope,
+    ),
+  );
+
+  final inheritanceManager = InheritanceManager3();
+  final resolver = _AngularTemplateResolver(inheritanceManager, library,
+      templateSource, library.typeProvider, errorListener,
+      overrideAsExpression: overrideAsExpression);
+  // fill the name scope
+  final classScope = ClassScope(resolver.nameScope, componentClass);
+  final localScope = LocalScope(classScope);
+  resolver
+    ..nameScope = localScope
+    ..enclosingClass = componentClass;
+  localVariables.forEach(localScope.add);
+  // do resolve
+  node.accept(resolver);
+  // verify
+  final verifier = ErrorVerifier(
+      errorReporter, library, library.typeProvider, inheritanceManager)
+    ..enclosingClass = componentClass;
+  node.accept(verifier);
+}
+
+typedef OverrideAsExpression = void Function({
+  @required AsExpression node,
+  @required void Function(AsExpression) invokeSuper,
+});
+
+class _AngularTemplateResolver extends ResolverVisitor {
+  final OverrideAsExpression overrideAsExpression;
+
+  _AngularTemplateResolver(
+    InheritanceManager3 inheritanceManager,
+    LibraryElement library,
+    Source source,
+    TypeProvider typeProvider,
+    AnalysisErrorListener errorListener, {
+    @required this.overrideAsExpression,
+  }) : super(inheritanceManager, library, source, typeProvider, errorListener);
+
+  @override
+  void visitAsExpression(AsExpression node) {
+    if (overrideAsExpression != null) {
+      overrideAsExpression(
+        node: node,
+        invokeSuper: (node) {
+          super.visitAsExpression(node);
+        },
+      );
+    } else {
+      super.visitAsExpression(node);
+    }
+  }
+}
diff --git a/pkg/analyzer/lib/src/command_line/arguments.dart b/pkg/analyzer/lib/src/command_line/arguments.dart
index f3b2c37..e5bb8c1 100644
--- a/pkg/analyzer/lib/src/command_line/arguments.dart
+++ b/pkg/analyzer/lib/src/command_line/arguments.dart
@@ -6,10 +6,10 @@
 
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/src/context/builder.dart';
-import 'package:analyzer/src/dart/sdk/sdk.dart';
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:args/args.dart';
+import 'package:cli_util/cli_util.dart';
 
 const String analysisOptionsFileOption = 'options';
 const String defineVariableOption = 'D';
@@ -103,11 +103,9 @@
 /// `true` and if the summary information exists.
 DartSdkManager createDartSdkManager(
     ResourceProvider resourceProvider, ArgResults args) {
-  String sdkPath = args[sdkPathOption];
+  String sdkPath = args[sdkPathOption] ?? getSdkPath();
 
-  return DartSdkManager(
-    sdkPath ?? FolderBasedDartSdk.defaultSdkDirectory(resourceProvider)?.path,
-  );
+  return DartSdkManager(sdkPath);
 }
 
 /// Add the standard flags and options to the given [parser]. The standard flags
@@ -117,7 +115,7 @@
 /// TODO(danrubel) Update DDC to support all the options defined in this method
 /// then remove the [ddc] named argument from this method.
 void defineAnalysisArguments(ArgParser parser,
-    {bool hide = true, ddc = false}) {
+    {bool hide = true, bool ddc = false}) {
   parser.addOption(sdkPathOption,
       help: 'The path to the Dart SDK.', hide: ddc && hide);
   parser.addOption(analysisOptionsFileOption,
diff --git a/pkg/analyzer/lib/src/context/builder.dart b/pkg/analyzer/lib/src/context/builder.dart
index 3bcc89f..daf2deb 100644
--- a/pkg/analyzer/lib/src/context/builder.dart
+++ b/pkg/analyzer/lib/src/context/builder.dart
@@ -133,10 +133,12 @@
       includedPaths: [contextRoot.root],
       excludedPaths: contextRoot.exclude,
     );
-    driver.analysisContext = api.DriverBasedAnalysisContext(
-      resourceProvider,
-      apiContextRoots.first,
-      driver,
+    driver.configure(
+      analysisContext: api.DriverBasedAnalysisContext(
+        resourceProvider,
+        apiContextRoots.first,
+        driver,
+      ),
     );
 
     // temporary plugin support:
diff --git a/pkg/analyzer/lib/src/context/context_root.dart b/pkg/analyzer/lib/src/context/context_root.dart
index 2b058e5..393c3d5 100644
--- a/pkg/analyzer/lib/src/context/context_root.dart
+++ b/pkg/analyzer/lib/src/context/context_root.dart
@@ -39,7 +39,7 @@
   }
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     if (other is ContextRoot) {
       return root == other.root &&
           _listEqual(exclude, other.exclude, (String a, String b) => a == b);
diff --git a/pkg/analyzer/lib/src/dart/analysis/analysis_context_collection.dart b/pkg/analyzer/lib/src/dart/analysis/analysis_context_collection.dart
index 8d0ba8e..d2ae5c0 100644
--- a/pkg/analyzer/lib/src/dart/analysis/analysis_context_collection.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/analysis_context_collection.dart
@@ -8,6 +8,7 @@
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/file_system/physical_file_system.dart';
 import 'package:analyzer/src/dart/analysis/context_builder.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:meta/meta.dart';
 
 /// An implementation of [AnalysisContextCollection].
@@ -28,6 +29,8 @@
       String sdkPath})
       : resourceProvider =
             resourceProvider ?? PhysicalResourceProvider.INSTANCE {
+    sdkPath ??= getSdkPath();
+
     _throwIfAnyNotAbsoluteNormalizedPath(includedPaths);
     if (sdkPath != null) {
       _throwIfNotAbsoluteNormalizedPath(sdkPath);
diff --git a/pkg/analyzer/lib/src/dart/analysis/context_builder.dart b/pkg/analyzer/lib/src/dart/analysis/context_builder.dart
index fde460e..beba8d7 100644
--- a/pkg/analyzer/lib/src/dart/analysis/context_builder.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/context_builder.dart
@@ -20,9 +20,9 @@
     show FileContentOverlay;
 import 'package:analyzer/src/dart/analysis/performance_logger.dart'
     show PerformanceLog;
-import 'package:analyzer/src/dart/sdk/sdk.dart';
 import 'package:analyzer/src/generated/sdk.dart' show DartSdkManager;
 import 'package:analyzer/src/generated/source.dart' show ContentCache;
+import 'package:cli_util/cli_util.dart';
 import 'package:meta/meta.dart';
 
 /// An implementation of a context builder.
@@ -37,11 +37,6 @@
       : resourceProvider =
             resourceProvider ?? PhysicalResourceProvider.INSTANCE;
 
-  /// Return the path to the default location of the SDK, or `null` if the sdk
-  /// cannot be found.
-  String get _defaultSdkPath =>
-      FolderBasedDartSdk.defaultSdkDirectory(resourceProvider)?.path;
-
   @override
   AnalysisContext createContext(
       {@required ContextRoot contextRoot,
@@ -52,14 +47,14 @@
       @deprecated AnalysisDriverScheduler scheduler,
       String sdkPath,
       String sdkSummaryPath}) {
+    // TODO(scheglov) Remove this, and make `sdkPath` required.
+    sdkPath ??= getSdkPath();
+    ArgumentError.checkNotNull(sdkPath, 'sdkPath');
+
     var byteStore = MemoryByteStore();
     var fileContentOverlay = FileContentOverlay();
     performanceLog ??= PerformanceLog(StringBuffer());
 
-    sdkPath ??= _defaultSdkPath;
-    if (sdkPath == null) {
-      throw ArgumentError('Cannot find path to the SDK');
-    }
     DartSdkManager sdkManager = DartSdkManager(sdkPath);
 
     if (scheduler == null) {
diff --git a/pkg/analyzer/lib/src/dart/analysis/context_locator.dart b/pkg/analyzer/lib/src/dart/analysis/context_locator.dart
index 807470c..e88e7e0 100644
--- a/pkg/analyzer/lib/src/dart/analysis/context_locator.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/context_locator.dart
@@ -23,10 +23,10 @@
     show FileContentOverlay;
 import 'package:analyzer/src/dart/analysis/performance_logger.dart'
     show PerformanceLog;
-import 'package:analyzer/src/dart/sdk/sdk.dart' show FolderBasedDartSdk;
 import 'package:analyzer/src/generated/sdk.dart' show DartSdkManager;
 import 'package:analyzer/src/task/options.dart';
 import 'package:analyzer/src/util/yaml.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:glob/glob.dart';
 import 'package:meta/meta.dart';
 import 'package:path/path.dart';
@@ -50,10 +50,6 @@
       : this.resourceProvider =
             resourceProvider ?? PhysicalResourceProvider.INSTANCE;
 
-  /// Return the path to the default location of the SDK.
-  String get _defaultSdkPath =>
-      FolderBasedDartSdk.defaultSdkDirectory(resourceProvider).path;
-
   @deprecated
   @override
   List<AnalysisContext> locateContexts(
@@ -62,6 +58,10 @@
       String optionsFile,
       String packagesFile,
       String sdkPath}) {
+    // TODO(scheglov) Remove this, and make `sdkPath` required.
+    sdkPath ??= getSdkPath();
+    ArgumentError.checkNotNull(sdkPath, 'sdkPath');
+
     List<ContextRoot> roots = locateRoots(
         includedPaths: includedPaths,
         excludedPaths: excludedPaths,
@@ -72,7 +72,7 @@
     }
     PerformanceLog performanceLog = PerformanceLog(StringBuffer());
     AnalysisDriverScheduler scheduler = AnalysisDriverScheduler(performanceLog);
-    DartSdkManager sdkManager = DartSdkManager(sdkPath ?? _defaultSdkPath);
+    DartSdkManager sdkManager = DartSdkManager(sdkPath);
     scheduler.start();
     ContextBuilderOptions options = ContextBuilderOptions();
     ContextBuilder builder =
diff --git a/pkg/analyzer/lib/src/dart/analysis/dependency/node.dart b/pkg/analyzer/lib/src/dart/analysis/dependency/node.dart
index 10baa3c..c7713fb 100644
--- a/pkg/analyzer/lib/src/dart/analysis/dependency/node.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/dependency/node.dart
@@ -26,7 +26,7 @@
       : hashCode = JenkinsSmiHash.hash2(target.hashCode, name.hashCode);
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     return other is ClassMemberReference &&
         other.target == target &&
         other.name == name;
diff --git a/pkg/analyzer/lib/src/dart/analysis/driver.dart b/pkg/analyzer/lib/src/dart/analysis/driver.dart
index f711628..30b0a74 100644
--- a/pkg/analyzer/lib/src/dart/analysis/driver.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/driver.dart
@@ -91,7 +91,7 @@
 /// TODO(scheglov) Clean up the list of implicitly analyzed files.
 class AnalysisDriver implements AnalysisDriverGeneric {
   /// The version of data format, should be incremented on every format change.
-  static const int DATA_VERSION = 104;
+  static const int DATA_VERSION = 106;
 
   /// The length of the list returned by [_computeDeclaredVariablesSignature].
   static const int _declaredVariablesSignatureLength = 4;
@@ -488,10 +488,14 @@
   /// At least one of the optional parameters should be provided, but only those
   /// that represent state that has actually changed need be provided.
   void configure({
+    api.AnalysisContext analysisContext,
     AnalysisOptions analysisOptions,
     Packages packages,
     SourceFactory sourceFactory,
   }) {
+    if (analysisContext != null) {
+      this.analysisContext = analysisContext;
+    }
     if (analysisOptions != null) {
       _analysisOptions = analysisOptions;
     }
@@ -1286,7 +1290,6 @@
             libraryContext.elementFactory,
             libraryContext.analysisSession.inheritanceManager,
             library,
-            _resourceProvider,
             testingData: testingData);
         Map<FileState, UnitAnalysisResult> results = analyzer.analyze();
 
@@ -1363,7 +1366,6 @@
           libraryContext.elementFactory,
           libraryContext.analysisSession.inheritanceManager,
           library,
-          _resourceProvider,
           testingData: testingData);
       Map<FileState, UnitAnalysisResult> unitResults = analyzer.analyze();
       var resolvedUnits = <ResolvedUnitResult>[];
@@ -1453,6 +1455,7 @@
 
     featureSetProvider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: _resourceProvider,
       packages: _packages,
       packageDefaultFeatureSet: _analysisOptions.contextFeatures,
       nonPackageDefaultFeatureSet: _analysisOptions.nonPackageFeatureSet,
@@ -1465,6 +1468,7 @@
       _resourceProvider,
       name,
       sourceFactory,
+      analysisContext?.workspace,
       analysisOptions,
       declaredVariables,
       _saltForUnlinked,
@@ -1631,7 +1635,7 @@
         null);
   }
 
-  void _reportException(String path, exception, StackTrace stackTrace) {
+  void _reportException(String path, Object exception, StackTrace stackTrace) {
     String contextKey;
     if (exception is _ExceptionState) {
       var state = exception as _ExceptionState;
@@ -1639,12 +1643,20 @@
       stackTrace = state.stackTrace;
       contextKey = state.contextKey;
     }
+
     CaughtException caught = CaughtException(exception, stackTrace);
-    String fileContent = _fsState.getFileForPath(path).content;
+
+    var fileContentMap = <String, String>{};
+    var libraryFile = _fsState.getFileForPath(path);
+    for (var file in libraryFile.libraryFiles) {
+      fileContentMap[file.path] = file.content;
+    }
+
     _exceptionController.add(
       ExceptionResult(
         filePath: path,
-        fileContent: fileContent,
+        fileContentMap: fileContentMap,
+        fileContent: libraryFile.content,
         exception: caught,
         contextKey: contextKey,
       ),
@@ -1665,8 +1677,8 @@
         .toBuffer();
   }
 
-  String _storeExceptionContext(
-      String path, FileState libraryFile, exception, StackTrace stackTrace) {
+  String _storeExceptionContext(String path, FileState libraryFile,
+      Object exception, StackTrace stackTrace) {
     if (allowedNumberOfContextsToWrite <= 0) {
       return null;
     } else {
@@ -2119,33 +2131,25 @@
   /// Return the lint code with the given [errorName], or `null` if there is no
   /// lint registered with that name.
   static ErrorCode _lintCodeByUniqueName(String errorName) {
-    const String lintPrefix = 'LintCode.';
-    if (errorName.startsWith(lintPrefix)) {
-      String lintName = errorName.substring(lintPrefix.length);
-      return linter.Registry.ruleRegistry.getRule(lintName)?.lintCode;
-    }
-
-    const String lintPrefixOld = '_LintCode.';
-    if (errorName.startsWith(lintPrefixOld)) {
-      String lintName = errorName.substring(lintPrefixOld.length);
-      return linter.Registry.ruleRegistry.getRule(lintName)?.lintCode;
-    }
-
-    return null;
+    return linter.Registry.ruleRegistry.codeForUniqueName(errorName);
   }
 }
 
 /// Exception that happened during analysis.
 class ExceptionResult {
-  /// The path of the file being analyzed when the [exception] happened.
+  /// The path of the library being analyzed when the [exception] happened.
   ///
   /// Absolute and normalized.
   final String filePath;
 
+  /// The content of the library and its parts.
+  final Map<String, String> fileContentMap;
+
   /// The path of the file being analyzed when the [exception] happened.
+  @Deprecated('Use fileContentMap instead')
   final String fileContent;
 
-  /// The exception during analysis of the file with the [path].
+  /// The exception during analysis of the file with the [filePath].
   final CaughtException exception;
 
   /// If the exception happened during a file analysis, and the context in which
@@ -2156,6 +2160,7 @@
 
   ExceptionResult({
     @required this.filePath,
+    @required this.fileContentMap,
     @required this.fileContent,
     @required this.exception,
     @required this.contextKey,
@@ -2262,7 +2267,7 @@
 
 /// Information about an exception and its context.
 class _ExceptionState {
-  final exception;
+  final Object exception;
   final StackTrace stackTrace;
 
   /// The key under which the context of the exception was stored, or `null`
diff --git a/pkg/analyzer/lib/src/dart/analysis/experiments.g.dart b/pkg/analyzer/lib/src/dart/analysis/experiments.g.dart
index 98663d9..085bacb 100644
--- a/pkg/analyzer/lib/src/dart/analysis/experiments.g.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/experiments.g.dart
@@ -8,7 +8,7 @@
 
 /// The current version of the Dart language (or, for non-stable releases, the
 /// version of the language currently in the process of being developed).
-const _currentVersion = '2.9.0';
+const _currentVersion = '2.10.0';
 
 /// A map containing information about all known experimental flags.
 const _knownFeatures = <String, ExperimentalFeature>{
@@ -23,11 +23,6 @@
   EnableString.spread_collections: ExperimentalFeatures.spread_collections,
   EnableString.triple_shift: ExperimentalFeatures.triple_shift,
   EnableString.variance: ExperimentalFeatures.variance,
-
-  // ignore: deprecated_member_use_from_same_package
-  EnableString.bogus_disabled: ExperimentalFeatures.bogus_disabled,
-  // ignore: deprecated_member_use_from_same_package
-  EnableString.bogus_enabled: ExperimentalFeatures.bogus_enabled,
 };
 
 List<bool> _buildExperimentalFlagsArray() => <bool>[
@@ -40,8 +35,6 @@
       true, // spread-collections
       IsEnabledByDefault.triple_shift,
       IsEnabledByDefault.variance,
-      false, // bogus-disabled
-      true, // bogus-enabled
     ];
 
 /// Constant strings for enabling each of the currently known experimental
@@ -73,14 +66,6 @@
 
   /// String to enable the experiment "variance"
   static const String variance = 'variance';
-
-  /// String to enable the experiment "bogus-disabled"
-  @deprecated
-  static const String bogus_disabled = 'bogus-disabled';
-
-  /// String to enable the experiment "bogus-enabled"
-  @deprecated
-  static const String bogus_enabled = 'bogus-enabled';
 }
 
 class ExperimentalFeatures {
@@ -164,28 +149,6 @@
     documentation: 'Sound variance',
     firstSupportedVersion: null,
   );
-
-  @deprecated
-  static const bogus_disabled = ExperimentalFeature(
-    index: 9,
-    // ignore: deprecated_member_use_from_same_package
-    enableString: EnableString.bogus_disabled,
-    isEnabledByDefault: IsEnabledByDefault.bogus_disabled,
-    isExpired: IsExpired.bogus_disabled,
-    documentation: null,
-    firstSupportedVersion: null,
-  );
-
-  @deprecated
-  static const bogus_enabled = ExperimentalFeature(
-    index: 10,
-    // ignore: deprecated_member_use_from_same_package
-    enableString: EnableString.bogus_enabled,
-    isEnabledByDefault: IsEnabledByDefault.bogus_enabled,
-    isExpired: IsExpired.bogus_enabled,
-    documentation: null,
-    firstSupportedVersion: '1.0.0',
-  );
 }
 
 /// Constant bools indicating whether each experimental flag is currently
@@ -217,14 +180,6 @@
 
   /// Default state of the experiment "variance"
   static const bool variance = false;
-
-  /// Default state of the experiment "bogus-disabled"
-  @deprecated
-  static const bool bogus_disabled = false;
-
-  /// Default state of the experiment "bogus-enabled"
-  @deprecated
-  static const bool bogus_enabled = true;
 }
 
 /// Constant bools indicating whether each experimental flag is currently
@@ -257,23 +212,9 @@
 
   /// Expiration status of the experiment "variance"
   static const bool variance = false;
-
-  /// Expiration status of the experiment "bogus-disabled"
-  static const bool bogus_disabled = true;
-
-  /// Expiration status of the experiment "bogus-enabled"
-  static const bool bogus_enabled = true;
 }
 
 mixin _CurrentState {
-  /// Current state for the flag "bogus-disabled"
-  @deprecated
-  bool get bogus_disabled => isEnabled(ExperimentalFeatures.bogus_disabled);
-
-  /// Current state for the flag "bogus-enabled"
-  @deprecated
-  bool get bogus_enabled => isEnabled(ExperimentalFeatures.bogus_enabled);
-
   /// Current state for the flag "constant-update-2018"
   bool get constant_update_2018 =>
       isEnabled(ExperimentalFeatures.constant_update_2018);
diff --git a/pkg/analyzer/lib/src/dart/analysis/feature_set_provider.dart b/pkg/analyzer/lib/src/dart/analysis/feature_set_provider.dart
index 8604562..5fe2dd4 100644
--- a/pkg/analyzer/lib/src/dart/analysis/feature_set_provider.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/feature_set_provider.dart
@@ -4,10 +4,12 @@
 
 import 'package:_fe_analyzer_shared/src/sdk/allowed_experiments.dart';
 import 'package:analyzer/dart/analysis/features.dart';
+import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/src/context/packages.dart';
 import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:analyzer/src/generated/source.dart';
+import 'package:analyzer/src/util/uri.dart';
 import 'package:meta/meta.dart';
 import 'package:pub_semver/pub_semver.dart';
 
@@ -17,16 +19,19 @@
   static const isNullSafetySdk = true;
 
   final AllowedExperiments _allowedExperiments;
+  final ResourceProvider _resourceProvider;
   final Packages _packages;
   final FeatureSet _packageDefaultFeatureSet;
   final FeatureSet _nonPackageDefaultFeatureSet;
 
   FeatureSetProvider._({
     @required AllowedExperiments allowedExperiments,
+    @required ResourceProvider resourceProvider,
     @required Packages packages,
     @required FeatureSet packageDefaultFeatureSet,
     @required FeatureSet nonPackageDefaultFeatureSet,
   })  : _allowedExperiments = allowedExperiments,
+        _resourceProvider = resourceProvider,
         _packages = packages,
         _packageDefaultFeatureSet = packageDefaultFeatureSet,
         _nonPackageDefaultFeatureSet = nonPackageDefaultFeatureSet;
@@ -44,7 +49,7 @@
       }
     }
 
-    var package = _packages.packageForPath(path);
+    var package = _findPackage(uri, path);
     if (package != null) {
       var experiments = _allowedExperiments.forPackage(package.name);
       if (experiments != null) {
@@ -65,8 +70,7 @@
     if (uri.isScheme('dart')) {
       return ExperimentStatus.currentVersion;
     }
-
-    var package = _packages.packageForPath(path);
+    var package = _findPackage(uri, path);
     if (package != null) {
       var languageVersion = package.languageVersion;
       if (languageVersion != null) {
@@ -77,8 +81,31 @@
     return ExperimentStatus.currentVersion;
   }
 
+  /// Return the package corresponding to the [uri] or [path], `null` if none.
+  Package _findPackage(Uri uri, String path) {
+    if (uri.isScheme('package')) {
+      var pathSegments = uri.pathSegments;
+      if (pathSegments.isNotEmpty) {
+        var packageName = pathSegments.first;
+        var package = _packages[packageName];
+        if (package != null) {
+          return package;
+        }
+      }
+    } else if (uri.isScheme('file')) {
+      var uriPath = fileUriToNormalizedPath(_resourceProvider.pathContext, uri);
+      var package = _packages.packageForPath(uriPath);
+      if (package != null) {
+        return package;
+      }
+    }
+
+    return _packages.packageForPath(path);
+  }
+
   static FeatureSetProvider build({
     @required SourceFactory sourceFactory,
+    @required ResourceProvider resourceProvider,
     @required Packages packages,
     @required FeatureSet packageDefaultFeatureSet,
     @required FeatureSet nonPackageDefaultFeatureSet,
@@ -86,6 +113,7 @@
     var allowedExperiments = _experimentsForSdk(sourceFactory.dartSdk);
     return FeatureSetProvider._(
       allowedExperiments: allowedExperiments,
+      resourceProvider: resourceProvider,
       packages: packages,
       packageDefaultFeatureSet: packageDefaultFeatureSet,
       nonPackageDefaultFeatureSet: nonPackageDefaultFeatureSet,
diff --git a/pkg/analyzer/lib/src/dart/analysis/file_byte_store.dart b/pkg/analyzer/lib/src/dart/analysis/file_byte_store.dart
index b93a6c8..2b3d215 100644
--- a/pkg/analyzer/lib/src/dart/analysis/file_byte_store.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/file_byte_store.dart
@@ -84,7 +84,7 @@
 
   /// This function is started in a new isolate, receives cache folder clean up
   /// requests and evicts older files from the folder.
-  static void _cacheCleanUpFunction(message) {
+  static void _cacheCleanUpFunction(Object message) {
     SendPort initialReplyTo = message;
     ReceivePort port = ReceivePort();
     initialReplyTo.send(port.sendPort);
diff --git a/pkg/analyzer/lib/src/dart/analysis/file_state.dart b/pkg/analyzer/lib/src/dart/analysis/file_state.dart
index 8d47e14..1b5e12a 100644
--- a/pkg/analyzer/lib/src/dart/analysis/file_state.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/file_state.dart
@@ -38,6 +38,7 @@
 import 'package:analyzer/src/summary/idl.dart';
 import 'package:analyzer/src/summary/package_bundle_reader.dart';
 import 'package:analyzer/src/summary2/informative_data.dart';
+import 'package:analyzer/src/workspace/workspace.dart';
 import 'package:convert/convert.dart';
 import 'package:crypto/crypto.dart';
 import 'package:meta/meta.dart';
@@ -91,6 +92,11 @@
   /// The [Source] of the file with the [uri].
   final Source source;
 
+  /// The [WorkspacePackage] that contains this file.
+  ///
+  /// It might be `null` if the file is outside of the workspace.
+  final WorkspacePackage workspacePackage;
+
   /// Return `true` if this file is a stub created for a file in the provided
   /// external summary store. The values of most properties are not the same
   /// as they would be if the file were actually read from the file system.
@@ -144,6 +150,7 @@
     this.path,
     this.uri,
     this.source,
+    this.workspacePackage,
     this._contextFeatureSet,
     this._packageLanguageVersion,
   ) : isInExternalSummaries = false;
@@ -152,6 +159,7 @@
       : isInExternalSummaries = true,
         path = null,
         source = null,
+        workspacePackage = null,
         _exists = true,
         _contextFeatureSet = null,
         _packageLanguageVersion = null {
@@ -734,6 +742,7 @@
   final ByteStore _byteStore;
   final FileContentOverlay _contentOverlay;
   final SourceFactory _sourceFactory;
+  final Workspace _workspace;
   final AnalysisOptions _analysisOptions;
   final DeclaredVariables _declaredVariables;
   final Uint32List _saltForUnlinked;
@@ -793,6 +802,7 @@
     this._resourceProvider,
     this.contextName,
     this._sourceFactory,
+    this._workspace,
     this._analysisOptions,
     this._declaredVariables,
     this._saltForUnlinked,
@@ -814,8 +824,8 @@
   FileState get unresolvedFile {
     if (_unresolvedFile == null) {
       var featureSet = FeatureSet.fromEnableFlags([]);
-      _unresolvedFile = FileState._(
-          this, null, null, null, featureSet, ExperimentStatus.currentVersion);
+      _unresolvedFile = FileState._(this, null, null, null, null, featureSet,
+          ExperimentStatus.currentVersion);
       _unresolvedFile.refresh();
     }
     return _unresolvedFile;
@@ -841,11 +851,12 @@
       }
       // Create a new file.
       FileSource uriSource = FileSource(resource, uri);
+      WorkspacePackage workspacePackage = _workspace?.findPackageFor(path);
       FeatureSet featureSet = featureSetProvider.getFeatureSet(path, uri);
       Version packageLanguageVersion =
           featureSetProvider.getLanguageVersion(path, uri);
-      file = FileState._(
-          this, path, uri, uriSource, featureSet, packageLanguageVersion);
+      file = FileState._(this, path, uri, uriSource, workspacePackage,
+          featureSet, packageLanguageVersion);
       _uriToFile[uri] = file;
       _addFileWithPath(path, file);
       _pathToCanonicalFile[path] = file;
@@ -884,11 +895,12 @@
       String path = uriSource.fullName;
       File resource = _resourceProvider.getFile(path);
       FileSource source = FileSource(resource, uri);
+      WorkspacePackage workspacePackage = _workspace?.findPackageFor(path);
       FeatureSet featureSet = featureSetProvider.getFeatureSet(path, uri);
       Version packageLanguageVersion =
           featureSetProvider.getLanguageVersion(path, uri);
-      file = FileState._(
-          this, path, uri, source, featureSet, packageLanguageVersion);
+      file = FileState._(this, path, uri, source, workspacePackage, featureSet,
+          packageLanguageVersion);
       _uriToFile[uri] = file;
       _addFileWithPath(path, file);
       file.refresh(allowCached: true);
diff --git a/pkg/analyzer/lib/src/dart/analysis/fletcher16.dart b/pkg/analyzer/lib/src/dart/analysis/fletcher16.dart
index 46f3ae6..f2efe65 100644
--- a/pkg/analyzer/lib/src/dart/analysis/fletcher16.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/fletcher16.dart
@@ -25,5 +25,5 @@
   c0 = c0 % 255;
   c1 = c1 % 255;
 
-  return (c1 << 8 | c0);
+  return c1 << 8 | c0;
 }
diff --git a/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart b/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
index 4aad110..8e31e2a 100644
--- a/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/library_analyzer.dart
@@ -8,8 +8,6 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/error/listener.dart';
-import 'package:analyzer/file_system/file_system.dart';
-import 'package:analyzer/src/context/builder.dart';
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/testing_data.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
@@ -26,7 +24,6 @@
 import 'package:analyzer/src/dart/resolver/flow_analysis_visitor.dart';
 import 'package:analyzer/src/dart/resolver/legacy_type_asserter.dart';
 import 'package:analyzer/src/dart/resolver/resolution_visitor.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart' show LibraryScope;
 import 'package:analyzer/src/error/best_practices_verifier.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/error/dart2js_verifier.dart';
@@ -50,7 +47,6 @@
 import 'package:analyzer/src/services/lint.dart';
 import 'package:analyzer/src/summary2/linked_element_factory.dart';
 import 'package:analyzer/src/task/strong/checker.dart';
-import 'package:analyzer/src/workspace/workspace.dart';
 import 'package:pub_semver/pub_semver.dart';
 
 var timerLibraryAnalyzer = Stopwatch();
@@ -70,7 +66,6 @@
   final DeclaredVariables _declaredVariables;
   final SourceFactory _sourceFactory;
   final FileState _library;
-  final ResourceProvider _resourceProvider;
 
   final InheritanceManager3 _inheritance;
   final bool Function(Uri) _isLibraryUri;
@@ -79,7 +74,6 @@
 
   LibraryElement _libraryElement;
 
-  LibraryScope _libraryScope;
   final Map<FileState, LineInfo> _fileToLineInfo = {};
 
   final Map<FileState, IgnoreInfo> _fileToIgnoreInfo = {};
@@ -100,7 +94,6 @@
       this._elementFactory,
       this._inheritance,
       this._library,
-      this._resourceProvider,
       {TestingData testingData})
       : _testingData = testingData;
 
@@ -128,7 +121,6 @@
     timerLibraryAnalyzerFreshUnit.stop();
 
     _libraryElement = _elementFactory.libraryOfUri(_library.uriStr);
-    _libraryScope = LibraryScope(_libraryElement);
 
     // Resolve URIs in directives to corresponding sources.
     FeatureSet featureSet = units[_library].featureSet;
@@ -190,6 +182,8 @@
 
     assert(units.values.every(LegacyTypeAsserter.assertLegacyTypes));
 
+    _checkForInconsistentLanguageVersionOverride(units);
+
     timerLibraryAnalyzerVerify.stop();
 
     // Return full results.
@@ -203,6 +197,44 @@
     return results;
   }
 
+  void _checkForInconsistentLanguageVersionOverride(
+    Map<FileState, CompilationUnit> units,
+  ) {
+    var libraryUnit = units.values.first;
+    var libraryOverrideToken = libraryUnit.languageVersionToken;
+
+    for (var partEntry in units.entries.skip(1)) {
+      var partUnit = partEntry.value;
+      var partOverrideToken = partUnit.languageVersionToken;
+      if (libraryOverrideToken != null) {
+        if (partOverrideToken != null) {
+          if (partOverrideToken.major != libraryOverrideToken.major ||
+              partOverrideToken.minor != libraryOverrideToken.minor) {
+            _getErrorReporter(partEntry.key).reportErrorForToken(
+              CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE,
+              partOverrideToken,
+            );
+          }
+        } else {
+          var partDirectives = partUnit.directives;
+          for (var partOf in partDirectives.whereType<PartOfDirective>()) {
+            var partOffset = partOf.partKeyword.offset;
+            _getErrorReporter(partEntry.key).reportErrorForOffset(
+              CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE,
+              partOffset,
+              partOf.ofKeyword.end - partOffset,
+            );
+          }
+        }
+      } else if (partOverrideToken != null) {
+        _getErrorReporter(partEntry.key).reportErrorForToken(
+          CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE,
+          partOverrideToken,
+        );
+      }
+    }
+  }
+
   void _computeConstantErrors(
       ErrorReporter errorReporter, CompilationUnit unit) {
     ConstantVerifier constantVerifier = ConstantVerifier(
@@ -251,8 +283,8 @@
         declaredVariables: _declaredVariables,
         typeSystem: _typeSystem,
         inheritanceManager: _inheritance,
-        resourceProvider: _resourceProvider,
         analysisOptions: _context.analysisOptions,
+        workspacePackage: _library.workspacePackage,
       ),
     );
 
@@ -309,8 +341,6 @@
     var nodeRegistry = NodeLintRegistry(_analysisOptions.enableTiming);
     var visitors = <AstVisitor>[];
 
-    final workspacePackage = _getPackage(currentUnit.unit);
-
     var context = LinterContextImpl(
       allUnits,
       currentUnit,
@@ -319,7 +349,7 @@
       _typeSystem,
       _inheritance,
       _analysisOptions,
-      workspacePackage,
+      file.workspacePackage,
     );
     for (Linter linter in _analysisOptions.lintRules) {
       linter.reporter = errorReporter;
@@ -479,23 +509,6 @@
     });
   }
 
-  WorkspacePackage _getPackage(CompilationUnit unit) {
-    final libraryPath = _library.source.fullName;
-    Workspace workspace =
-        unit.declaredElement.session?.analysisContext?.workspace;
-
-    // If there is no driver setup (as in test environments), we need to create
-    // a workspace ourselves.
-    // todo (pq): fix tests or otherwise de-dup this logic shared w/ resolver.
-    if (workspace == null) {
-      final builder = ContextBuilder(
-          _resourceProvider, null /* sdkManager */, null /* contentCache */);
-      workspace = ContextBuilder.createWorkspace(
-          _resourceProvider, libraryPath, builder);
-    }
-    return workspace?.findPackageFor(libraryPath);
-  }
-
   /// Return the name of the library that the given part is declared to be a
   /// part of, or `null` if the part does not contain a part-of directive.
   _NameOrSource _getPartLibraryNameOrUri(Source partSource,
@@ -694,14 +707,14 @@
         unitElement: unitElement,
         errorListener: errorListener,
         featureSet: unit.featureSet,
-        nameScope: _libraryScope,
+        nameScope: _libraryElement.scope,
         elementWalker: ElementWalker.forCompilationUnit(unitElement),
       ),
     );
 
     unit.accept(VariableResolverVisitor(
         _libraryElement, source, _typeProvider, errorListener,
-        nameScope: _libraryScope));
+        nameScope: _libraryElement.scope));
 
     // Nothing for RESOLVED_UNIT8?
     // Nothing for RESOLVED_UNIT9?
diff --git a/pkg/analyzer/lib/src/dart/analysis/library_context.dart b/pkg/analyzer/lib/src/dart/analysis/library_context.dart
index dfb0e07..e20331c 100644
--- a/pkg/analyzer/lib/src/dart/analysis/library_context.dart
+++ b/pkg/analyzer/lib/src/dart/analysis/library_context.dart
@@ -172,7 +172,7 @@
                       '[cycle: $cycle]'
                       '[loadedBundles: ${loadedBundles.toList()}]'
                       '[elementFactory.libraries: $libraryUriList]';
-                  throw LibraryCycleLinkException(
+                  throw CaughtExceptionWithFiles(
                     'Cycle loading state error',
                     StackTrace.current,
                     {'status': statusText},
@@ -314,19 +314,10 @@
         fileContentMap[file.path] = file.content;
       }
     }
-    throw LibraryCycleLinkException(exception, stackTrace, fileContentMap);
+    throw CaughtExceptionWithFiles(exception, stackTrace, fileContentMap);
   }
 }
 
 class LibraryContextTestView {
   final List<Set<String>> linkedCycles = [];
 }
-
-/// TODO(scheglov) replace in the internal patch
-class LibraryCycleLinkException extends CaughtExceptionWithFiles {
-  LibraryCycleLinkException(
-    Object exception,
-    StackTrace stackTrace,
-    Map<String, String> fileContentMap,
-  ) : super(exception, stackTrace, fileContentMap);
-}
diff --git a/pkg/analyzer/lib/src/dart/ast/ast.dart b/pkg/analyzer/lib/src/dart/ast/ast.dart
index 89a1d3f..4fbd468 100644
--- a/pkg/analyzer/lib/src/dart/ast/ast.dart
+++ b/pkg/analyzer/lib/src/dart/ast/ast.dart
@@ -3886,7 +3886,7 @@
   bool get isNullAware {
     var nextType = argumentList.endToken.next.type;
     return nextType == TokenType.QUESTION_PERIOD ||
-        nextType == TokenType.QUESTION_PERIOD_OPEN_SQUARE_BRACKET;
+        nextType == TokenType.QUESTION;
   }
 
   @override
@@ -4311,35 +4311,30 @@
   }
 
   @override
-  bool get isNamed =>
-      kind == ParameterKind.NAMED || kind == ParameterKind.NAMED_REQUIRED;
+  bool get isNamed => kind.isNamed;
 
   @override
-  bool get isOptional =>
-      kind == ParameterKind.NAMED || kind == ParameterKind.POSITIONAL;
+  bool get isOptional => kind.isOptional;
 
   @override
-  bool get isOptionalNamed => kind == ParameterKind.NAMED;
+  bool get isOptionalNamed => kind.isOptionalNamed;
 
   @override
-  bool get isOptionalPositional => kind == ParameterKind.POSITIONAL;
+  bool get isOptionalPositional => kind.isOptionalPositional;
 
   @override
-  bool get isPositional =>
-      kind == ParameterKind.POSITIONAL || kind == ParameterKind.REQUIRED;
+  bool get isPositional => kind.isPositional;
 
   @override
-  bool get isRequired =>
-      kind == ParameterKind.REQUIRED || kind == ParameterKind.NAMED_REQUIRED;
+  bool get isRequired => kind.isRequired;
 
   @override
-  bool get isRequiredNamed => kind == ParameterKind.NAMED_REQUIRED;
+  bool get isRequiredNamed => kind.isRequiredNamed;
 
   @override
-  bool get isRequiredPositional => kind == ParameterKind.REQUIRED;
+  bool get isRequiredPositional => kind.isRequiredPositional;
 
   @override
-  // Overridden to remove the 'deprecated' annotation.
   ParameterKind get kind;
 }
 
@@ -5868,7 +5863,6 @@
       return _ancestorCascade.isNullAware;
     }
     return question != null ||
-        leftBracket.type == TokenType.QUESTION_PERIOD_OPEN_SQUARE_BRACKET ||
         (leftBracket.type == TokenType.OPEN_SQUARE_BRACKET &&
             period != null &&
             period.type == TokenType.QUESTION_PERIOD_PERIOD);
@@ -6279,22 +6273,24 @@
   Iterable<SyntacticEntity> get childEntities => ChildEntities()..add(contents);
 
   @override
-  int get contentsEnd {
-    String lexeme = contents.lexeme;
-    return offset + StringLexemeHelper(lexeme, true, true).end;
-  }
+  int get contentsEnd => offset + _lexemeHelper.end;
 
   @override
-  int get contentsOffset {
-    int offset = contents.offset;
-    String lexeme = contents.lexeme;
-    return offset + StringLexemeHelper(lexeme, true, true).start;
-  }
+  int get contentsOffset => contents.offset + _lexemeHelper.start;
 
   @override
   Token get endToken => contents;
 
   @override
+  StringInterpolation get parent => super.parent;
+
+  StringLexemeHelper get _lexemeHelper {
+    String lexeme = contents.lexeme;
+    return StringLexemeHelper(lexeme, identical(this, parent.elements.first),
+        identical(this, parent.elements.last));
+  }
+
+  @override
   E accept<E>(AstVisitor<E> visitor) => visitor.visitInterpolationString(this);
 
   @override
@@ -7686,11 +7682,10 @@
     _identifier = _becomeParentOf(identifier as SimpleIdentifierImpl);
   }
 
-  @deprecated
   @override
   ParameterKind get kind {
     AstNode parent = this.parent;
-    if (parent is DefaultFormalParameter) {
+    if (parent is DefaultFormalParameterImpl) {
       return parent.kind;
     }
     return ParameterKind.REQUIRED;
diff --git a/pkg/analyzer/lib/src/dart/ast/extensions.dart b/pkg/analyzer/lib/src/dart/ast/extensions.dart
new file mode 100644
index 0000000..a7da188
--- /dev/null
+++ b/pkg/analyzer/lib/src/dart/ast/extensions.dart
@@ -0,0 +1,12 @@
+// 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 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/src/dart/ast/ast.dart';
+
+extension ListOfFormalParameterExtension on List<FormalParameter> {
+  Iterable<FormalParameterImpl> get asImpl {
+    return this.cast<FormalParameterImpl>();
+  }
+}
diff --git a/pkg/analyzer/lib/src/dart/ast/utilities.dart b/pkg/analyzer/lib/src/dart/ast/utilities.dart
index 250c38e..30e603e 100644
--- a/pkg/analyzer/lib/src/dart/ast/utilities.dart
+++ b/pkg/analyzer/lib/src/dart/ast/utilities.dart
@@ -339,8 +339,7 @@
 
   @override
   DefaultFormalParameter visitDefaultFormalParameter(
-          DefaultFormalParameter node) =>
-      // ignore: deprecated_member_use_from_same_package
+          covariant DefaultFormalParameterImpl node) =>
       astFactory.defaultFormalParameter(cloneNode(node.parameter), node.kind,
           cloneToken(node.separator), cloneNode(node.defaultValue));
 
@@ -1446,10 +1445,9 @@
   }
 
   @override
-  bool visitDefaultFormalParameter(DefaultFormalParameter node) {
-    DefaultFormalParameter other = _other as DefaultFormalParameter;
+  bool visitDefaultFormalParameter(covariant DefaultFormalParameterImpl node) {
+    var other = _other as DefaultFormalParameterImpl;
     return isEqualNodes(node.parameter, other.parameter) &&
-        // ignore: deprecated_member_use_from_same_package
         node.kind == other.kind &&
         isEqualTokens(node.separator, other.separator) &&
         isEqualNodes(node.defaultValue, other.defaultValue);
@@ -4321,11 +4319,10 @@
   }
 
   @override
-  bool visitDefaultFormalParameter(DefaultFormalParameter node) {
-    DefaultFormalParameter toNode = this._toNode as DefaultFormalParameter;
+  bool visitDefaultFormalParameter(covariant DefaultFormalParameterImpl node) {
+    var toNode = this._toNode as DefaultFormalParameterImpl;
     return _and(
         _isEqualNodes(node.parameter, toNode.parameter),
-        // ignore: deprecated_member_use_from_same_package
         node.kind == toNode.kind,
         _isEqualTokens(node.separator, toNode.separator),
         _isEqualNodes(node.defaultValue, toNode.defaultValue));
diff --git a/pkg/analyzer/lib/src/dart/constant/evaluation.dart b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
index 40da2ac..2509b5f 100644
--- a/pkg/analyzer/lib/src/dart/constant/evaluation.dart
+++ b/pkg/analyzer/lib/src/dart/constant/evaluation.dart
@@ -355,8 +355,7 @@
         if (defaultSuperInvocationNeeded) {
           // No explicit superconstructor invocation found, so we need to
           // manually insert a reference to the implicit superconstructor.
-          InterfaceType superclass =
-              (constant.returnType as InterfaceType).superclass;
+          InterfaceType superclass = constant.returnType.superclass;
           if (superclass != null && !superclass.isDartCoreObject) {
             ConstructorElement unnamedConstructor =
                 superclass.element.unnamedConstructor?.declaration;
@@ -476,7 +475,7 @@
     );
 
     constructor = followConstantRedirectionChain(constructor);
-    InterfaceType definingClass = constructor.returnType as InterfaceType;
+    InterfaceType definingClass = constructor.returnType;
     if (constructor.isFactory) {
       // We couldn't find a non-factory constructor.
       // See if it's because we reached an external const factory constructor
diff --git a/pkg/analyzer/lib/src/dart/constant/has_type_parameter_reference.dart b/pkg/analyzer/lib/src/dart/constant/has_type_parameter_reference.dart
index 0aa6243..30ae5e3 100644
--- a/pkg/analyzer/lib/src/dart/constant/has_type_parameter_reference.dart
+++ b/pkg/analyzer/lib/src/dart/constant/has_type_parameter_reference.dart
@@ -8,7 +8,7 @@
 /// Return `true` if the [type] has a type parameter reference.
 bool hasTypeParameterReference(DartType type) {
   var visitor = _ReferencesTypeParameterVisitor();
-  DartTypeVisitor.visit(type, visitor);
+  type.accept(visitor);
   return visitor.result;
 }
 
@@ -24,9 +24,6 @@
   bool result = false;
 
   @override
-  bool defaultDartType(_) => true;
-
-  @override
   bool visitTypeParameterType(_) {
     result = true;
     // Stop visiting at this point.
diff --git a/pkg/analyzer/lib/src/dart/constant/value.dart b/pkg/analyzer/lib/src/dart/constant/value.dart
index e1529fc..3b51c9d 100644
--- a/pkg/analyzer/lib/src/dart/constant/value.dart
+++ b/pkg/analyzer/lib/src/dart/constant/value.dart
@@ -1157,7 +1157,7 @@
     if (value == null) {
       return UNKNOWN_VALUE;
     }
-    return DoubleState(-(value));
+    return DoubleState(-value);
   }
 
   @override
diff --git a/pkg/analyzer/lib/src/dart/element/element.dart b/pkg/analyzer/lib/src/dart/element/element.dart
index 50d892a..eea79c5 100644
--- a/pkg/analyzer/lib/src/dart/element/element.dart
+++ b/pkg/analyzer/lib/src/dart/element/element.dart
@@ -10,21 +10,25 @@
 import 'package:analyzer/dart/constant/value.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
+import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/constant/compute.dart';
 import 'package:analyzer/src/dart/constant/evaluation.dart';
 import 'package:analyzer/src/dart/constant/value.dart';
 import 'package:analyzer/src/dart/element/display_string_builder.dart';
 import 'package:analyzer/src/dart/element/member.dart';
 import 'package:analyzer/src/dart/element/nullability_eliminator.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_algebra.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
+import 'package:analyzer/src/dart/resolver/scope.dart'
+    show Namespace, NamespaceBuilder;
 import 'package:analyzer/src/dart/resolver/variance.dart';
 import 'package:analyzer/src/generated/constant.dart' show EvaluationResultImpl;
 import 'package:analyzer/src/generated/element_type_provider.dart';
@@ -2143,7 +2147,7 @@
   }
 
   @override
-  DartType get returnType =>
+  InterfaceType get returnType =>
       ElementTypeProvider.current.getExecutableReturnType(this);
 
   @override
@@ -2152,15 +2156,8 @@
   }
 
   @override
-  DartType get returnTypeInternal {
-    if (_returnType != null) return _returnType;
-
-    InterfaceTypeImpl classThisType = enclosingElement.thisType;
-    return _returnType = InterfaceTypeImpl(
-      element: classThisType.element,
-      typeArguments: classThisType.typeArguments,
-      nullabilitySuffix: classThisType.nullabilitySuffix,
-    );
+  InterfaceType get returnTypeInternal {
+    return _returnType ??= enclosingElement.thisType;
   }
 
   @override
@@ -5215,6 +5212,9 @@
   /// The cached list of prefixes.
   List<PrefixElement> _prefixes;
 
+  /// The scope of this library, `null` if it has not been created yet.
+  LibraryScope _scope;
+
   /// Initialize a newly created library element in the given [context] to have
   /// the given [name] and [offset].
   LibraryElementImpl(this.context, this.session, String name, int offset,
@@ -5589,6 +5589,11 @@
   }
 
   @override
+  Scope get scope {
+    return _scope ??= LibraryScope(this);
+  }
+
+  @override
   Source get source {
     if (_definingCompilationUnit == null) {
       return null;
@@ -6675,8 +6680,7 @@
     if (_parameterKind != null) return _parameterKind;
 
     if (linkedNode != null) {
-      FormalParameter linkedNode = this.linkedNode;
-      // ignore: deprecated_member_use_from_same_package
+      var linkedNode = this.linkedNode as FormalParameterImpl;
       return linkedNode.kind;
     }
     return _parameterKind;
@@ -6898,36 +6902,28 @@
 /// [ParameterElement].
 mixin ParameterElementMixin implements ParameterElement {
   @override
-  bool get isNamed =>
-      parameterKind == ParameterKind.NAMED ||
-      parameterKind == ParameterKind.NAMED_REQUIRED;
+  bool get isNamed => parameterKind.isNamed;
 
   @override
-  bool get isNotOptional =>
-      parameterKind == ParameterKind.REQUIRED ||
-      parameterKind == ParameterKind.NAMED_REQUIRED;
+  bool get isNotOptional => parameterKind.isRequired;
 
   @override
-  bool get isOptional =>
-      parameterKind == ParameterKind.NAMED ||
-      parameterKind == ParameterKind.POSITIONAL;
+  bool get isOptional => parameterKind.isOptional;
 
   @override
-  bool get isOptionalNamed => parameterKind == ParameterKind.NAMED;
+  bool get isOptionalNamed => parameterKind.isOptionalNamed;
 
   @override
-  bool get isOptionalPositional => parameterKind == ParameterKind.POSITIONAL;
+  bool get isOptionalPositional => parameterKind.isOptionalPositional;
 
   @override
-  bool get isPositional =>
-      parameterKind == ParameterKind.POSITIONAL ||
-      parameterKind == ParameterKind.REQUIRED;
+  bool get isPositional => parameterKind.isPositional;
 
   @override
-  bool get isRequiredNamed => parameterKind == ParameterKind.NAMED_REQUIRED;
+  bool get isRequiredNamed => parameterKind.isRequiredNamed;
 
   @override
-  bool get isRequiredPositional => parameterKind == ParameterKind.REQUIRED;
+  bool get isRequiredPositional => parameterKind.isRequiredPositional;
 
   @override
   // Overridden to remove the 'deprecated' annotation.
@@ -6954,6 +6950,9 @@
 
 /// A concrete implementation of a [PrefixElement].
 class PrefixElementImpl extends ElementImpl implements PrefixElement {
+  /// The scope of this prefix, `null` if it has not been created yet.
+  PrefixScope _scope;
+
   /// Initialize a newly created method element to have the given [name] and
   /// [nameOffset].
   PrefixElementImpl(String name, int nameOffset) : super(name, nameOffset);
@@ -6989,6 +6988,9 @@
   }
 
   @override
+  Scope get scope => _scope ??= PrefixScope(enclosingElement, this);
+
+  @override
   T accept<T>(ElementVisitor<T> visitor) => visitor.visitPrefixElement(this);
 
   @override
diff --git a/pkg/analyzer/lib/src/dart/element/generic_inferrer.dart b/pkg/analyzer/lib/src/dart/element/generic_inferrer.dart
index 908d87c..0cd3aa6 100644
--- a/pkg/analyzer/lib/src/dart/element/generic_inferrer.dart
+++ b/pkg/analyzer/lib/src/dart/element/generic_inferrer.dart
@@ -496,7 +496,7 @@
       var prefix = parts[0];
       var middle = parts[1];
       var prefixPad = ' ' * (prefixMax - prefix.length);
-      var middlePad = ' ' * (prefixMax);
+      var middlePad = ' ' * prefixMax;
       var end = "";
       if (parts.length > 2) {
         end = '\n  $middlePad ${parts[2]}';
diff --git a/pkg/analyzer/lib/src/dart/element/inheritance_manager3.dart b/pkg/analyzer/lib/src/dart/element/inheritance_manager3.dart
index 16cb851..bb1f519 100644
--- a/pkg/analyzer/lib/src/dart/element/inheritance_manager3.dart
+++ b/pkg/analyzer/lib/src/dart/element/inheritance_manager3.dart
@@ -890,7 +890,7 @@
   Name._internal(this.libraryUri, this.name, this.isPublic, this.hashCode);
 
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     return other is Name &&
         name == other.name &&
         libraryUri == other.libraryUri;
diff --git a/pkg/analyzer/lib/src/dart/element/member.dart b/pkg/analyzer/lib/src/dart/element/member.dart
index 7fccac1..d97532c 100644
--- a/pkg/analyzer/lib/src/dart/element/member.dart
+++ b/pkg/analyzer/lib/src/dart/element/member.dart
@@ -84,6 +84,9 @@
   }
 
   @override
+  InterfaceType get returnType => type.returnType as InterfaceType;
+
+  @override
   T accept<T>(ElementVisitor<T> visitor) =>
       visitor.visitConstructorElement(this);
 
diff --git a/pkg/analyzer/lib/src/dart/element/nullability_eliminator.dart b/pkg/analyzer/lib/src/dart/element/nullability_eliminator.dart
index 6b7fa75..63e7084 100644
--- a/pkg/analyzer/lib/src/dart/element/nullability_eliminator.dart
+++ b/pkg/analyzer/lib/src/dart/element/nullability_eliminator.dart
@@ -5,7 +5,6 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/replacement_visitor.dart';
-import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
 
@@ -15,7 +14,7 @@
   NullabilityEliminator(this._typeProvider);
 
   @override
-  DartType visitNeverType(NeverTypeImpl type) {
+  DartType visitNeverType(NeverType type) {
     return _typeProvider.nullStar;
   }
 
@@ -38,11 +37,12 @@
   /// If the [type] itself, or any of its components, has any nullability,
   /// return a new type with legacy nullability suffixes. Otherwise return the
   /// original instance.
-  static T perform<T extends DartType>(TypeProviderImpl typeProvider, T type) {
+  static DartType perform(TypeProviderImpl typeProvider, DartType type) {
     if (type == null) {
       return type;
     }
 
-    return NullabilityEliminator(typeProvider).visit(type) ?? type;
+    var visitor = NullabilityEliminator(typeProvider);
+    return type.accept<DartType>(visitor) ?? type;
   }
 }
diff --git a/pkg/analyzer/lib/src/dart/element/replacement_visitor.dart b/pkg/analyzer/lib/src/dart/element/replacement_visitor.dart
index 27566d1..c550ccd 100644
--- a/pkg/analyzer/lib/src/dart/element/replacement_visitor.dart
+++ b/pkg/analyzer/lib/src/dart/element/replacement_visitor.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/extensions.dart';
 import 'package:analyzer/src/dart/element/type.dart';
@@ -12,13 +13,12 @@
 import 'package:analyzer/src/dart/element/type_schema.dart';
 import 'package:analyzer/src/dart/element/type_visitor.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
-import 'package:analyzer/src/summary2/function_type_builder.dart';
-import 'package:analyzer/src/summary2/named_type_builder.dart';
 import 'package:meta/meta.dart';
 
 /// Helper visitor that clones a type if a nested type is replaced, and
 /// otherwise returns `null`.
-class ReplacementVisitor implements DartTypeVisitor<DartType> {
+class ReplacementVisitor
+    implements TypeVisitor<DartType>, InferenceTypeVisitor<DartType> {
   const ReplacementVisitor();
 
   void changeVariance() {}
@@ -103,16 +103,7 @@
   }
 
   @override
-  DartType defaultDartType(DartType type) {
-    return null;
-  }
-
-  DartType visit(DartType type) {
-    return DartTypeVisitor.visit(type, this);
-  }
-
-  @override
-  DartType visitDynamicType(DynamicTypeImpl type) {
+  DartType visitDynamicType(DynamicType type) {
     return null;
   }
 
@@ -125,7 +116,7 @@
       var typeParameter = node.typeFormals[i];
       var bound = typeParameter.bound;
       if (bound != null) {
-        var newBound = visit(bound);
+        var newBound = bound.accept(this);
         if (newBound != null) {
           newTypeParameters ??= node.typeFormals.toList(growable: false);
           newTypeParameters[i] = TypeParameterElementImpl.synthetic(
@@ -160,7 +151,7 @@
 
     DartType visitType(DartType type) {
       if (type == null) return null;
-      var result = visit(type);
+      var result = type.accept(this);
       if (substitution != null) {
         result = substitution.substituteType(result ?? type);
       }
@@ -203,17 +194,12 @@
   }
 
   @override
-  DartType visitFunctionTypeBuilder(FunctionTypeBuilder type) {
-    throw UnimplementedError();
-  }
-
-  @override
   DartType visitInterfaceType(InterfaceType type) {
     var newNullability = visitNullability(type);
 
     List<DartType> newTypeArguments;
     for (var i = 0; i < type.typeArguments.length; i++) {
-      var substitution = visit(type.typeArguments[i]);
+      var substitution = type.typeArguments[i].accept(this);
       if (substitution != null) {
         newTypeArguments ??= type.typeArguments.toList(growable: false);
         newTypeArguments[i] = substitution;
@@ -228,12 +214,7 @@
   }
 
   @override
-  DartType visitNamedTypeBuilder(NamedTypeBuilder type) {
-    throw UnimplementedError();
-  }
-
-  @override
-  DartType visitNeverType(NeverTypeImpl type) {
+  DartType visitNeverType(NeverType type) {
     var newNullability = visitNullability(type);
 
     return createNeverType(
@@ -256,7 +237,7 @@
 
     var promotedBound = (type as TypeParameterTypeImpl).promotedBound;
     if (promotedBound != null) {
-      var newPromotedBound = visit(promotedBound);
+      var newPromotedBound = promotedBound.accept(this);
       return createPromotedTypeParameterType(
         type: type,
         newNullability: newNullability,
diff --git a/pkg/analyzer/lib/src/dart/element/scope.dart b/pkg/analyzer/lib/src/dart/element/scope.dart
new file mode 100644
index 0000000..fa08358
--- /dev/null
+++ b/pkg/analyzer/lib/src/dart/element/scope.dart
@@ -0,0 +1,318 @@
+// 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 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
+import 'package:analyzer/src/dart/element/element.dart';
+import 'package:analyzer/src/dart/resolver/scope.dart' as impl;
+import 'package:meta/meta.dart';
+
+/// The scope defined by a class.
+class ClassScope extends EnclosedScope {
+  ClassScope(Scope parent, ClassElement element) : super(parent) {
+    element.accessors.forEach(_addPropertyAccessor);
+    element.methods.forEach(_addGetter);
+  }
+}
+
+/// The scope for the initializers in a constructor.
+class ConstructorInitializerScope extends EnclosedScope {
+  ConstructorInitializerScope(Scope parent, ConstructorElement element)
+      : super(parent) {
+    element.parameters.forEach(_addGetter);
+  }
+}
+
+/// A scope that is lexically enclosed in another scope.
+class EnclosedScope implements Scope {
+  final Scope _parent;
+  final Map<String, Element> _getters = {};
+  final Map<String, Element> _setters = {};
+
+  EnclosedScope(Scope parent) : _parent = parent;
+
+  Scope get parent => _parent;
+
+  @Deprecated('Use lookup2() that is closer to the language specification')
+  @override
+  Element lookup({@required String id, @required bool setter}) {
+    var result = lookup2(id);
+    return setter ? result.setter : result.getter;
+  }
+
+  @override
+  ScopeLookupResult lookup2(String id) {
+    var getter = _getters[id];
+    var setter = _setters[id];
+    if (getter != null || setter != null) {
+      return ScopeLookupResult(getter, setter);
+    }
+
+    return _parent.lookup2(id);
+  }
+
+  void _addGetter(Element element) {
+    _addTo(_getters, element);
+  }
+
+  void _addPropertyAccessor(PropertyAccessorElement element) {
+    if (element.isGetter) {
+      _addGetter(element);
+    } else {
+      _addSetter(element);
+    }
+  }
+
+  void _addSetter(Element element) {
+    _addTo(_setters, element);
+  }
+
+  void _addTo(Map<String, Element> map, Element element) {
+    var id = element.displayName;
+    map[id] ??= element;
+  }
+}
+
+/// The scope defined by an extension.
+class ExtensionScope extends EnclosedScope {
+  ExtensionScope(
+    Scope parent,
+    ExtensionElement element,
+  ) : super(parent) {
+    element.accessors.forEach(_addPropertyAccessor);
+    element.methods.forEach(_addGetter);
+  }
+}
+
+class FormalParameterScope extends EnclosedScope {
+  FormalParameterScope(
+    Scope parent,
+    List<ParameterElement> elements,
+  ) : super(parent) {
+    for (var parameter in elements) {
+      if (parameter is! FieldFormalParameterElement) {
+        _addGetter(parameter);
+      }
+    }
+  }
+}
+
+class LibraryScope extends EnclosedScope {
+  final LibraryElement _element;
+  final List<ExtensionElement> extensions = [];
+
+  LibraryScope(LibraryElement element)
+      : _element = element,
+        super(_LibraryImportScope(element)) {
+    extensions.addAll((_parent as _LibraryImportScope).extensions);
+
+    _element.prefixes.forEach(_addGetter);
+    _element.units.forEach(_addUnitElements);
+  }
+
+  bool shouldIgnoreUndefined({
+    @required String prefix,
+    @required String name,
+  }) {
+    Iterable<NamespaceCombinator> getShowCombinators(
+        ImportElement importElement) {
+      return importElement.combinators.whereType<ShowElementCombinator>();
+    }
+
+    if (prefix != null) {
+      for (var importElement in _element.imports) {
+        if (importElement.prefix?.name == prefix &&
+            importElement.importedLibrary?.isSynthetic != false) {
+          var showCombinators = getShowCombinators(importElement);
+          if (showCombinators.isEmpty) {
+            return true;
+          }
+          for (ShowElementCombinator combinator in showCombinators) {
+            if (combinator.shownNames.contains(name)) {
+              return true;
+            }
+          }
+        }
+      }
+    } else {
+      // TODO(scheglov) merge for(s).
+      for (var importElement in _element.imports) {
+        if (importElement.prefix == null &&
+            importElement.importedLibrary?.isSynthetic != false) {
+          for (ShowElementCombinator combinator
+              in getShowCombinators(importElement)) {
+            if (combinator.shownNames.contains(name)) {
+              return true;
+            }
+          }
+        }
+      }
+    }
+
+    return false;
+  }
+
+  void _addExtension(ExtensionElement element) {
+    _addGetter(element);
+    if (!extensions.contains(element)) {
+      extensions.add(element);
+    }
+  }
+
+  void _addUnitElements(CompilationUnitElement compilationUnit) {
+    compilationUnit.accessors.forEach(_addPropertyAccessor);
+    compilationUnit.enums.forEach(_addGetter);
+    compilationUnit.extensions.forEach(_addExtension);
+    compilationUnit.functions.forEach(_addGetter);
+    compilationUnit.functionTypeAliases.forEach(_addGetter);
+    compilationUnit.mixins.forEach(_addGetter);
+    compilationUnit.types.forEach(_addGetter);
+  }
+}
+
+class LocalScope extends EnclosedScope {
+  LocalScope(Scope parent) : super(parent);
+
+  void add(Element element) {
+    _addGetter(element);
+  }
+}
+
+class PrefixScope implements Scope {
+  final LibraryElement _library;
+  final Map<String, Element> _getters = {};
+  final Map<String, Element> _setters = {};
+  final Set<ExtensionElement> _extensions = {};
+
+  PrefixScope(this._library, PrefixElement prefix) {
+    for (var import in _library.imports) {
+      if (import.prefix == prefix) {
+        var elements = impl.NamespaceBuilder().getImportedElements(import);
+        elements.forEach(_add);
+      }
+    }
+  }
+
+  @Deprecated('Use lookup2() that is closer to the language specification')
+  @override
+  Element lookup({@required String id, @required bool setter}) {
+    var result = lookup2(id);
+    return setter ? result.setter : result.getter;
+  }
+
+  @override
+  ScopeLookupResult lookup2(String id) {
+    var getter = _getters[id];
+    var setter = _setters[id];
+    return ScopeLookupResult(getter, setter);
+  }
+
+  void _add(Element element) {
+    if (element is PropertyAccessorElement && element.isSetter) {
+      _addTo(map: _setters, element: element);
+    } else {
+      _addTo(map: _getters, element: element);
+      if (element is ExtensionElement) {
+        _extensions.add(element);
+      }
+    }
+  }
+
+  void _addTo({
+    @required Map<String, Element> map,
+    @required Element element,
+  }) {
+    var id = element.displayName;
+
+    var existing = map[id];
+    if (existing != null && existing != element) {
+      map[id] = _merge(existing, element);
+      return;
+    }
+
+    map[id] = element;
+  }
+
+  Element _merge(Element existing, Element other) {
+    if (_isSdkElement(existing)) {
+      if (!_isSdkElement(other)) {
+        return other;
+      }
+    } else {
+      if (_isSdkElement(other)) {
+        return existing;
+      }
+    }
+
+    var conflictingElements = <Element>{};
+    _addElement(conflictingElements, existing);
+    _addElement(conflictingElements, other);
+
+    return MultiplyDefinedElementImpl(
+      _library.context,
+      _library.session,
+      conflictingElements.first.name,
+      conflictingElements.toList(),
+    );
+  }
+
+  static void _addElement(
+    Set<Element> conflictingElements,
+    Element element,
+  ) {
+    if (element is MultiplyDefinedElementImpl) {
+      conflictingElements.addAll(element.conflictingElements);
+    } else {
+      conflictingElements.add(element);
+    }
+  }
+
+  static bool _isSdkElement(Element element) {
+    if (element is DynamicElementImpl || element is NeverElementImpl) {
+      return true;
+    }
+    if (element is MultiplyDefinedElement) {
+      return false;
+    }
+    return element.library.isInSdk;
+  }
+}
+
+class TypeParameterScope extends EnclosedScope {
+  TypeParameterScope(
+    Scope parent,
+    List<TypeParameterElement> elements,
+  ) : super(parent) {
+    elements.forEach(_addGetter);
+  }
+}
+
+class _LibraryImportScope implements Scope {
+  final LibraryElement _library;
+  final PrefixScope _nullPrefixScope;
+  List<ExtensionElement> _extensions;
+
+  _LibraryImportScope(LibraryElement library)
+      : _library = library,
+        _nullPrefixScope = PrefixScope(library, null);
+
+  List<ExtensionElement> get extensions {
+    return _extensions ??= {
+      ..._nullPrefixScope._extensions,
+      for (var prefix in _library.prefixes)
+        ...(prefix.scope as PrefixScope)._extensions,
+    }.toList();
+  }
+
+  @Deprecated('Use lookup2() that is closer to the language specification')
+  @override
+  Element lookup({@required String id, @required bool setter}) {
+    throw UnimplementedError();
+  }
+
+  @override
+  ScopeLookupResult lookup2(String id) {
+    return _nullPrefixScope.lookup2(id);
+  }
+}
diff --git a/pkg/analyzer/lib/src/dart/element/type.dart b/pkg/analyzer/lib/src/dart/element/type.dart
index 8fd0cf4..3d6e3df 100644
--- a/pkg/analyzer/lib/src/dart/element/type.dart
+++ b/pkg/analyzer/lib/src/dart/element/type.dart
@@ -10,6 +10,7 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
 import 'package:analyzer/src/dart/element/display_string_builder.dart';
 import 'package:analyzer/src/dart/element/element.dart';
@@ -69,6 +70,11 @@
   bool operator ==(Object object) => identical(object, this);
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitDynamicType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeDynamicType();
   }
@@ -269,6 +275,11 @@
   }
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitFunctionType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeFunctionType(this);
   }
@@ -361,7 +372,7 @@
   }
 
   void _forEachParameterType(
-      ParameterKind kind, Function(String name, DartType type) callback) {
+      ParameterKind kind, void Function(String name, DartType type) callback) {
     for (var parameter in parameters) {
       // ignore: deprecated_member_use_from_same_package
       if (parameter.parameterKind == kind) {
@@ -706,6 +717,12 @@
   }
 
   @override
+  List<InterfaceType> get allSupertypes {
+    var substitution = Substitution.fromInterfaceType(this);
+    return element.allSupertypes.map(substitution.substituteType).toList();
+  }
+
+  @override
   List<ConstructorElement> get constructors {
     if (_constructors == null) {
       List<ConstructorElement> constructors = element.constructors;
@@ -874,24 +891,16 @@
   }
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitInterfaceType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeInterfaceType(this);
   }
 
-  /// Return either this type or a supertype of this type that is defined by the
-  /// [targetElement], or `null` if such a type does not exist. If this type
-  /// inherits from the target element along multiple paths, then the returned
-  /// type is arbitrary.
-  ///
-  /// For example, given the following definitions
-  /// ```
-  /// class A<E> {}
-  /// class B<E> implements A<E> {}
-  /// class C implements A<String> {}
-  /// ```
-  /// Asking the type `B<int>` for the type associated with `A` will return the
-  /// type `A<int>`. Asking the type `C` for the type associated with `A` will
-  /// return the type `A<String>`.
+  @override
   InterfaceType asInstanceOf(ClassElement targetElement) {
     if (element == targetElement) {
       return this;
@@ -1663,7 +1672,7 @@
   int get hashCode => 0;
 
   @override
-  bool get isBottom => true;
+  bool get isBottom => nullabilitySuffix != NullabilitySuffix.question;
 
   @override
   bool get isDartCoreNull {
@@ -1679,6 +1688,11 @@
   bool operator ==(Object object) => identical(object, this);
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitNeverType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeNeverType(this);
   }
@@ -1808,6 +1822,9 @@
   void appendTo(ElementDisplayStringBuilder builder);
 
   @override
+  InterfaceType asInstanceOf(ClassElement element) => null;
+
+  @override
   String getDisplayString({
     bool skipAllDynamicArguments = false,
     bool withNullability = false,
@@ -1928,6 +1945,25 @@
   @override
   int get hashCode => element.hashCode;
 
+  @override
+  bool get isBottom {
+    // In principle we ought to be able to do `return bound.isBottom;`, but that
+    // goes into an infinite loop with illegal code in which type parameter
+    // bounds form a loop.  So we have to be more careful.
+    Set<TypeParameterElement> seenTypes = {};
+    TypeParameterType type = this;
+    while (seenTypes.add(type.element)) {
+      var bound = type.bound;
+      if (bound is TypeParameterType) {
+        type = bound;
+      } else {
+        return bound.isBottom;
+      }
+    }
+    // Infinite loop.
+    return false;
+  }
+
   @Deprecated('Check element, or use getDisplayString()')
   @override
   String get name => element.name;
@@ -1951,11 +1987,21 @@
   }
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitTypeParameterType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeTypeParameterType(this);
   }
 
   @override
+  InterfaceType asInstanceOf(ClassElement element) {
+    return bound?.asInstanceOf(element);
+  }
+
+  @override
   DartType replaceTopAndBottom(TypeProvider typeProvider,
       {bool isCovariant = true}) {
     return this;
@@ -2087,6 +2133,11 @@
   bool operator ==(Object object) => identical(object, this);
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    return visitor.visitVoidType(this);
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeVoidType();
   }
diff --git a/pkg/analyzer/lib/src/dart/element/type_algebra.dart b/pkg/analyzer/lib/src/dart/element/type_algebra.dart
index 648d60b..9ba3091 100644
--- a/pkg/analyzer/lib/src/dart/element/type_algebra.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_algebra.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/extensions.dart';
 import 'package:analyzer/src/dart/element/type.dart';
@@ -139,7 +140,8 @@
   DartType getSubstitute(TypeParameterElement parameter, bool upperBound);
 
   DartType substituteType(DartType type, {bool contravariant = false}) {
-    return _TopSubstitutor(this, contravariant).visit(type);
+    var visitor = _TopSubstitutor(this, contravariant);
+    return type.accept(visitor);
   }
 
   /// Substitutes both variables from [first] and [second], favoring those from
@@ -259,7 +261,7 @@
       var element = elements[i];
       if (element.bound != null) {
         TypeParameterElementImpl freshElement = freshElements[i];
-        freshElement.bound = visit(element.bound);
+        freshElement.bound = element.bound.accept(this);
       }
     }
 
@@ -331,7 +333,11 @@
   }
 }
 
-abstract class _TypeSubstitutor extends DartTypeVisitor<DartType> {
+abstract class _TypeSubstitutor
+    implements
+        TypeVisitor<DartType>,
+        InferenceTypeVisitor<DartType>,
+        LinkingTypeVisitor<DartType> {
   final _TypeSubstitutor outer;
   bool covariantContext = true;
 
@@ -382,12 +388,8 @@
     return _FreshTypeParametersSubstitutor(this);
   }
 
-  DartType visit(DartType type) {
-    return DartTypeVisitor.visit(type, this);
-  }
-
   @override
-  DartType visitDynamicType(DynamicTypeImpl type) => type;
+  DartType visitDynamicType(DynamicType type) => type;
 
   @override
   DartType visitFunctionType(FunctionType type) {
@@ -415,14 +417,14 @@
     inner.invertVariance();
 
     var parameters = type.parameters.map((parameter) {
-      var type = inner.visit(parameter.type);
+      var type = parameter.type.accept(inner);
       return parameter.copyWith(type: type);
     }).toList();
 
     inner.invertVariance();
 
-    var returnType = inner.visit(type.returnType);
-    var typeArguments = type.typeArguments.map(visit).toList();
+    var returnType = type.returnType.accept(inner);
+    var typeArguments = _mapList(type.typeArguments);
 
     if (this.useCounter == before) return type;
 
@@ -462,13 +464,13 @@
     inner.invertVariance();
 
     var parameters = type.parameters.map((parameter) {
-      var type = inner.visit(parameter.type);
+      var type = parameter.type.accept(inner);
       return parameter.copyWith(type: type);
     }).toList();
 
     inner.invertVariance();
 
-    var returnType = inner.visit(type.returnType);
+    var returnType = type.returnType.accept(inner);
 
     if (this.useCounter == before) return type;
 
@@ -487,7 +489,7 @@
     }
 
     int before = useCounter;
-    var typeArguments = type.typeArguments.map(visit).toList();
+    var typeArguments = _mapList(type.typeArguments);
     if (useCounter == before) {
       return type;
     }
@@ -506,7 +508,7 @@
     }
 
     int before = useCounter;
-    var arguments = type.arguments.map(visit).toList();
+    var arguments = _mapList(type.arguments);
     if (useCounter == before) {
       return type;
     }
@@ -520,7 +522,7 @@
   }
 
   @override
-  DartType visitNeverType(NeverTypeImpl type) => type;
+  DartType visitNeverType(NeverType type) => type;
 
   @override
   DartType visitTypeParameterType(TypeParameterType type) {
@@ -541,6 +543,10 @@
   @override
   DartType visitVoidType(VoidType type) => type;
 
+  List<DartType> _mapList(List<DartType> types) {
+    return types.map((e) => e.accept(this)).toList();
+  }
+
   ///  1. Substituting T=X! into T! yields X!
   ///  2. Substituting T=X* into T! yields X*
   ///  3. Substituting T=X? into T! yields X?
diff --git a/pkg/analyzer/lib/src/dart/element/type_demotion.dart b/pkg/analyzer/lib/src/dart/element/type_demotion.dart
index 41a9e17..581f22b 100644
--- a/pkg/analyzer/lib/src/dart/element/type_demotion.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_demotion.dart
@@ -5,10 +5,10 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/replacement_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/element/type_visitor.dart';
 
 /// Returns [type] in which all promoted type variables have been replace with
 /// their unpromoted equivalents, and, if [library] is non-nullable by default,
@@ -16,16 +16,18 @@
 DartType demoteType(LibraryElement library, DartType type) {
   if (library.isNonNullableByDefault) {
     var visitor = const _DemotionNonNullification();
-    return visitor.visit(type) ?? type;
+    return type.accept(visitor) ?? type;
   } else {
     var visitor = const _DemotionNonNullification(nonNullifyTypes: false);
-    return visitor.visit(type) ?? type;
+    return type.accept(visitor) ?? type;
   }
 }
 
 /// Returns `true` if type contains a promoted type variable.
 bool hasPromotedTypeVariable(DartType type) {
-  return const _HasPromotedTypeVariableVisitor()._visit(type);
+  return type.accept(
+    const _HasPromotedTypeVariableVisitor(),
+  );
 }
 
 /// Returns [type] in which all legacy types have been replaced with
@@ -33,7 +35,7 @@
 DartType nonNullifyType(TypeSystemImpl typeSystem, DartType type) {
   if (typeSystem.isNonNullableByDefault && type != null) {
     var visitor = const _DemotionNonNullification(demoteTypeVariables: false);
-    return visitor.visit(type) ?? type;
+    return type.accept(visitor) ?? type;
   }
   return type;
 }
@@ -81,20 +83,20 @@
 }
 
 /// Visitor that returns `true` if a type contains a promoted type variable.
-class _HasPromotedTypeVariableVisitor extends DartTypeVisitor<bool> {
+class _HasPromotedTypeVariableVisitor extends UnifyingTypeVisitor<bool> {
   const _HasPromotedTypeVariableVisitor();
 
   @override
-  bool defaultDartType(DartType type) => false;
+  bool visitDartType(DartType type) => false;
 
   @override
   bool visitFunctionType(FunctionType type) {
-    if (_visit(type.returnType)) {
+    if (type.returnType.accept(this)) {
       return true;
     }
 
     for (var parameter in type.parameters) {
-      if (_visit(parameter.type)) {
+      if (parameter.type.accept(this)) {
         return true;
       }
     }
@@ -105,7 +107,7 @@
   @override
   bool visitInterfaceType(InterfaceType type) {
     for (var typeArgument in type.typeArguments) {
-      if (_visit(typeArgument)) {
+      if (typeArgument.accept(this)) {
         return true;
       }
     }
@@ -116,8 +118,4 @@
   bool visitTypeParameterType(TypeParameterType type) {
     return (type as TypeParameterTypeImpl).promotedBound != null;
   }
-
-  bool _visit(DartType type) {
-    return DartTypeVisitor.visit(type, this);
-  }
 }
diff --git a/pkg/analyzer/lib/src/dart/element/type_provider.dart b/pkg/analyzer/lib/src/dart/element/type_provider.dart
index 724e63b..1180bc1 100644
--- a/pkg/analyzer/lib/src/dart/element/type_provider.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_provider.dart
@@ -27,7 +27,7 @@
   @override
   bool isObjectGetter(String id) {
     PropertyAccessorElement element = objectType.element.getGetter(id);
-    return (element != null && !element.isStatic);
+    return element != null && !element.isStatic;
   }
 
   @override
@@ -38,7 +38,7 @@
   @override
   bool isObjectMethod(String id) {
     MethodElement element = objectType.element.getMethod(id);
-    return (element != null && !element.isStatic);
+    return element != null && !element.isStatic;
   }
 }
 
diff --git a/pkg/analyzer/lib/src/dart/element/type_schema.dart b/pkg/analyzer/lib/src/dart/element/type_schema.dart
index b94870c..a26acd1 100644
--- a/pkg/analyzer/lib/src/dart/element/type_schema.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_schema.dart
@@ -6,8 +6,10 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/display_string_builder.dart';
 import 'package:analyzer/src/dart/element/type.dart';
+import 'package:analyzer/src/dart/element/type_visitor.dart';
 
 /// A type that is being inferred but is not currently known.
 ///
@@ -37,6 +39,16 @@
   bool operator ==(Object object) => identical(object, this);
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    if (visitor is InferenceTypeVisitor<R>) {
+      var visitor2 = visitor as InferenceTypeVisitor<R>;
+      return visitor2.visitUnknownInferredType(this);
+    } else {
+      throw StateError('Should not happen outside inference.');
+    }
+  }
+
+  @override
   void appendTo(ElementDisplayStringBuilder builder) {
     builder.writeUnknownInferredType();
   }
diff --git a/pkg/analyzer/lib/src/dart/element/type_schema_elimination.dart b/pkg/analyzer/lib/src/dart/element/type_schema_elimination.dart
index 9fd1240..56e772a5 100644
--- a/pkg/analyzer/lib/src/dart/element/type_schema_elimination.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_schema_elimination.dart
@@ -48,7 +48,7 @@
       bottomType,
       isLeastClosure,
     );
-    var result = visitor.visit(schema);
+    var result = schema.accept(visitor);
     assert(visitor._isLeastClosure == isLeastClosure);
     return result ?? schema;
   }
diff --git a/pkg/analyzer/lib/src/dart/element/type_system.dart b/pkg/analyzer/lib/src/dart/element/type_system.dart
index 27bef03..e9a450b 100644
--- a/pkg/analyzer/lib/src/dart/element/type_system.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_system.dart
@@ -241,7 +241,16 @@
     var substitution = Substitution.fromPairs(typeParameters, inferredTypes);
 
     for (int i = 0; i < srcTypes.length; i++) {
-      if (substitution.substituteType(srcTypes[i]) != destTypes[i]) {
+      var srcType = substitution.substituteType(srcTypes[i]);
+      var destType = destTypes[i];
+      if (isNonNullableByDefault) {
+        // TODO(scheglov) waiting for the spec
+        // https://github.com/dart-lang/sdk/issues/42605
+      } else {
+        srcType = toLegacyType(srcType);
+        destType = toLegacyType(destType);
+      }
+      if (srcType != destType) {
         // Failed to find an appropriate substitution
         return null;
       }
@@ -264,8 +273,8 @@
     if (type is! InterfaceType) return null;
     if (genericType is! InterfaceType) return null;
 
-    var asInstanceOf = (type as InterfaceTypeImpl)
-        .asInstanceOf((genericType as InterfaceType).element);
+    var asInstanceOf =
+        type.asInstanceOf((genericType as InterfaceType).element);
 
     if (asInstanceOf != null) {
       return asInstanceOf.typeArguments[0];
@@ -345,6 +354,11 @@
     return type;
   }
 
+  DartType toLegacyType(DartType type) {
+    if (isNonNullableByDefault) return type;
+    return NullabilityEliminator.perform(typeProvider, type);
+  }
+
   /// Tries to promote from the first type from the second type, and returns the
   /// promoted type if it succeeds, otherwise null.
   DartType tryPromoteToType(DartType to, DartType from);
@@ -970,8 +984,10 @@
   /// Return `true`  for things in the equivalence class of `Never`.
   bool isBottom(DartType type) {
     // BOTTOM(Never) is true
-    if (identical(type, NeverTypeImpl.instance)) {
-      return true;
+    if (type is NeverType) {
+      var result = type.nullabilitySuffix != NullabilitySuffix.question;
+      assert(type.isBottom == result);
+      return result;
     }
 
     // BOTTOM(X&T) is true iff BOTTOM(T)
@@ -979,16 +995,21 @@
     if (type is TypeParameterTypeImpl) {
       var T = type.promotedBound;
       if (T != null) {
-        return isBottom(T);
+        var result = isBottom(T);
+        assert(type.isBottom == result);
+        return result;
       }
 
       T = type.element.bound;
       if (T != null) {
-        return isBottom(T);
+        var result = isBottom(T);
+        assert(type.isBottom == result);
+        return result;
       }
     }
 
     // BOTTOM(T) is false otherwise
+    assert(!type.isBottom);
     return false;
   }
 
@@ -1427,11 +1448,6 @@
     return RuntimeTypeEqualityHelper(this).equal(T1, T2);
   }
 
-  DartType toLegacyType(DartType type) {
-    if (isNonNullableByDefault) return type;
-    return NullabilityEliminator.perform(typeProvider, type);
-  }
-
   /// Merges two types into a single type.
   /// Compute the canonical representation of [T].
   ///
diff --git a/pkg/analyzer/lib/src/dart/element/type_visitor.dart b/pkg/analyzer/lib/src/dart/element/type_visitor.dart
index 714fac0..78ce59a 100644
--- a/pkg/analyzer/lib/src/dart/element/type_visitor.dart
+++ b/pkg/analyzer/lib/src/dart/element/type_visitor.dart
@@ -3,66 +3,12 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_schema.dart';
 import 'package:analyzer/src/summary2/function_type_builder.dart';
 import 'package:analyzer/src/summary2/named_type_builder.dart';
 
-class DartTypeVisitor<R> {
-  const DartTypeVisitor();
-
-  R defaultDartType(DartType type) => null;
-
-  R visitDynamicType(DynamicTypeImpl type) => defaultDartType(type);
-
-  R visitFunctionType(FunctionType type) => defaultDartType(type);
-
-  R visitFunctionTypeBuilder(FunctionTypeBuilder type) => defaultDartType(type);
-
-  R visitInterfaceType(InterfaceType type) => defaultDartType(type);
-
-  R visitNamedTypeBuilder(NamedTypeBuilder type) => defaultDartType(type);
-
-  R visitNeverType(NeverTypeImpl type) => defaultDartType(type);
-
-  R visitTypeParameterType(TypeParameterType type) => defaultDartType(type);
-
-  R visitUnknownInferredType(UnknownInferredType type) => defaultDartType(type);
-
-  R visitVoidType(VoidType type) => defaultDartType(type);
-
-  static R visit<R>(DartType type, DartTypeVisitor<R> visitor) {
-    if (type is NeverTypeImpl) {
-      return visitor.visitNeverType(type);
-    }
-    if (type is DynamicTypeImpl) {
-      return visitor.visitDynamicType(type);
-    }
-    if (type is FunctionType) {
-      return visitor.visitFunctionType(type);
-    }
-    if (type is FunctionTypeBuilder) {
-      return visitor.visitFunctionTypeBuilder(type);
-    }
-    if (type is InterfaceType) {
-      return visitor.visitInterfaceType(type);
-    }
-    if (type is NamedTypeBuilder) {
-      return visitor.visitNamedTypeBuilder(type);
-    }
-    if (type is TypeParameterType) {
-      return visitor.visitTypeParameterType(type);
-    }
-    if (type is UnknownInferredType) {
-      return visitor.visitUnknownInferredType(type);
-    }
-    if (type is VoidType) {
-      return visitor.visitVoidType(type);
-    }
-    throw UnimplementedError('(${type.runtimeType}) $type');
-  }
-}
-
 class DartTypeVisitor1<R, T> {
   const DartTypeVisitor1();
 
@@ -136,12 +82,29 @@
   }
 }
 
+/// Visitors that implement this interface can be used to visit partially
+/// inferred types, during type inference.
+abstract class InferenceTypeVisitor<R> {
+  R visitUnknownInferredType(UnknownInferredType type);
+}
+
+/// Visitors that implement this interface can be used to visit partially
+/// built types, during linking element model.
+abstract class LinkingTypeVisitor<R> {
+  R visitFunctionTypeBuilder(FunctionTypeBuilder type);
+
+  R visitNamedTypeBuilder(NamedTypeBuilder type);
+}
+
 /// Recursively visits a DartType tree until any visit method returns `false`.
-abstract class RecursiveTypeVisitor extends DartTypeVisitor<bool> {
+class RecursiveTypeVisitor extends UnifyingTypeVisitor<bool> {
   /// Visit each item in the list until one returns `false`, in which case, this
   /// will also return `false`.
   bool visitChildren(Iterable<DartType> types) =>
-      types.every((type) => DartTypeVisitor.visit(type, this));
+      types.every((type) => type.accept(this));
+
+  @override
+  bool visitDartType(DartType type) => true;
 
   @override
   bool visitFunctionType(FunctionType type) => visitChildren([
@@ -153,14 +116,12 @@
       ]);
 
   @override
-  bool visitFunctionTypeBuilder(FunctionTypeBuilder type) =>
-      throw StateError("Builders should not exist outside substitution.");
-
-  @override
   bool visitInterfaceType(InterfaceType type) =>
       visitChildren(type.typeArguments);
 
   @override
-  bool visitNamedTypeBuilder(NamedTypeBuilder type) =>
-      throw StateError("Builders should not exist outside substitution.");
+  bool visitTypeParameterType(TypeParameterType type) {
+    // TODO(scheglov) Should we visit the bound here?
+    return true;
+  }
 }
diff --git a/pkg/analyzer/lib/src/dart/error/hint_codes.dart b/pkg/analyzer/lib/src/dart/error/hint_codes.dart
index e96b66e..15b3b1e 100644
--- a/pkg/analyzer/lib/src/dart/error/hint_codes.dart
+++ b/pkg/analyzer/lib/src/dart/error/hint_codes.dart
@@ -2585,6 +2585,17 @@
 
   /**
    * Parameters:
+   * 0: the name of the parameter that is declared but not used
+   */
+  static const HintCode UNUSED_ELEMENT_PARAMETER = HintCodeWithUniqueName(
+      'UNUSED_ELEMENT',
+      'HintCode.UNUSED_ELEMENT_PARAMETER',
+      "A value for optional parameter '{0}' isn't ever given.",
+      correction: "Try removing the unused parameter.",
+      hasPublishedDocs: true);
+
+  /**
+   * Parameters:
    * 0: the name of the unused field
    */
   // #### Description
diff --git a/pkg/analyzer/lib/src/dart/error/lint_codes.dart b/pkg/analyzer/lib/src/dart/error/lint_codes.dart
index 313c98e..5b5e320 100644
--- a/pkg/analyzer/lib/src/dart/error/lint_codes.dart
+++ b/pkg/analyzer/lib/src/dart/error/lint_codes.dart
@@ -32,7 +32,17 @@
   String get url => 'https://dart-lang.github.io/linter/lints/$name.html';
 
   @override
-  bool operator ==(other) => uniqueName == other.uniqueName;
+  bool operator ==(Object other) =>
+      other is LintCode && uniqueName == other.uniqueName;
+}
+
+class LintCodeWithUniqueName extends LintCode {
+  @override
+  final String uniqueName;
+
+  const LintCodeWithUniqueName(String name, this.uniqueName, String message,
+      {String correction})
+      : super(name, message, correction: correction);
 }
 
 /// Defines security-related best practice recommendations.
@@ -46,3 +56,13 @@
   @override
   bool get isIgnorable => false;
 }
+
+class SecurityLintCodeWithUniqueName extends SecurityLintCode {
+  @override
+  final String uniqueName;
+
+  const SecurityLintCodeWithUniqueName(
+      String name, this.uniqueName, String message,
+      {String correction})
+      : super(name, message, correction: correction);
+}
diff --git a/pkg/analyzer/lib/src/dart/micro/cider_byte_store.dart b/pkg/analyzer/lib/src/dart/micro/cider_byte_store.dart
index 60e8d0f..5d97366 100644
--- a/pkg/analyzer/lib/src/dart/micro/cider_byte_store.dart
+++ b/pkg/analyzer/lib/src/dart/micro/cider_byte_store.dart
@@ -23,15 +23,22 @@
   void put(String key, List<int> signature, List<int> bytes);
 }
 
+class CiderCacheEntry {
+  final List<int> signature;
+  final List<int> bytes;
+
+  CiderCacheEntry(this.signature, this.bytes);
+}
+
 class CiderMemoryByteStore implements CiderByteStore {
-  final Map<String, _CiderCacheEntry> _map = {};
+  final Map<String, CiderCacheEntry> _map = {};
 
   @override
   List<int> get(String key, List<int> signature) {
     var entry = _map[key];
 
     if (entry != null &&
-        const ListEquality().equals(entry.signature, signature)) {
+        const ListEquality<int>().equals(entry.signature, signature)) {
       return entry.bytes;
     }
     return null;
@@ -39,13 +46,6 @@
 
   @override
   void put(String key, List<int> signature, List<int> bytes) {
-    _map[key] = _CiderCacheEntry(signature, bytes);
+    _map[key] = CiderCacheEntry(signature, bytes);
   }
 }
-
-class _CiderCacheEntry {
-  final List<int> signature;
-  final List<int> bytes;
-
-  _CiderCacheEntry(this.signature, this.bytes);
-}
diff --git a/pkg/analyzer/lib/src/dart/micro/library_analyzer.dart b/pkg/analyzer/lib/src/dart/micro/library_analyzer.dart
index 44bc665f..f4297a2 100644
--- a/pkg/analyzer/lib/src/dart/micro/library_analyzer.dart
+++ b/pkg/analyzer/lib/src/dart/micro/library_analyzer.dart
@@ -24,7 +24,6 @@
 import 'package:analyzer/src/dart/resolver/flow_analysis_visitor.dart';
 import 'package:analyzer/src/dart/resolver/legacy_type_asserter.dart';
 import 'package:analyzer/src/dart/resolver/resolution_visitor.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/error/best_practices_verifier.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/error/dart2js_verifier.dart';
@@ -70,7 +69,6 @@
 
   LibraryElement _libraryElement;
 
-  LibraryScope _libraryScope;
   final Map<FileState, LineInfo> _fileToLineInfo = {};
 
   final Map<FileState, IgnoreInfo> _fileToIgnoreInfo = {};
@@ -118,7 +116,10 @@
     performance.run('parse', (performance) {
       for (FileState file in _library.libraryFiles) {
         if (completionPath == null || file.path == completionPath) {
-          units[file] = _parse(file);
+          units[file] = _parse(
+            file: file,
+            performance: performance,
+          );
         }
       }
     });
@@ -133,10 +134,8 @@
 
     _libraryElement = _elementFactory.libraryOfUri(_library.uriStr);
 
-    _libraryScope = LibraryScope(_libraryElement);
-
     performance.run('resolveDirectives', (performance) {
-      _resolveDirectives(units);
+      _resolveDirectives(units, forCompletion);
     });
 
     performance.run('resolveFiles', (performance) {
@@ -279,8 +278,8 @@
         declaredVariables: _declaredVariables,
         typeSystem: _typeSystem,
         inheritanceManager: _inheritance,
-        resourceProvider: _resourceProvider,
         analysisOptions: _context.analysisOptions,
+        workspacePackage: null, // TODO(scheglov) implement it
       ),
     );
 
@@ -514,10 +513,16 @@
   }
 
   /// Return a  parsed unresolved [CompilationUnit].
-  CompilationUnit _parse(FileState file) {
-    AnalysisErrorListener errorListener = _getErrorListener(file);
+  CompilationUnit _parse({
+    @required FileState file,
+    @required OperationPerformanceImpl performance,
+  }) {
     String content = _getFileContent(file.path);
 
+    performance.getDataInt('count').increment();
+    performance.getDataInt('length').add(content.length);
+
+    AnalysisErrorListener errorListener = _getErrorListener(file);
     CompilationUnit unit = file.parse(errorListener, content);
 
     LineInfo lineInfo = unit.lineInfo;
@@ -527,10 +532,17 @@
     return unit;
   }
 
-  void _resolveDirectives(Map<FileState, CompilationUnit> units) {
+  void _resolveDirectives(
+    Map<FileState, CompilationUnit> units,
+    bool forCompletion,
+  ) {
     CompilationUnit definingCompilationUnit = units[_library];
     definingCompilationUnit.element = _libraryElement.definingCompilationUnit;
 
+    if (forCompletion) {
+      return;
+    }
+
     bool matchNodeElement(Directive node, Element element) {
       return node.keyword.offset == element.nameOffset;
     }
@@ -677,14 +689,14 @@
         unitElement: unitElement,
         errorListener: errorListener,
         featureSet: unit.featureSet,
-        nameScope: _libraryScope,
+        nameScope: _libraryElement.scope,
         elementWalker: ElementWalker.forCompilationUnit(unitElement),
       ),
     );
 
     unit.accept(VariableResolverVisitor(
         _libraryElement, source, _typeProvider, errorListener,
-        nameScope: _libraryScope));
+        nameScope: _libraryElement.scope));
 
     // Nothing for RESOLVED_UNIT8?
     // Nothing for RESOLVED_UNIT9?
diff --git a/pkg/analyzer/lib/src/dart/micro/library_graph.dart b/pkg/analyzer/lib/src/dart/micro/library_graph.dart
index 1b818ef..eb0a42f 100644
--- a/pkg/analyzer/lib/src/dart/micro/library_graph.dart
+++ b/pkg/analyzer/lib/src/dart/micro/library_graph.dart
@@ -166,6 +166,7 @@
     @required OperationPerformanceImpl performance,
   }) {
     _fsState.testView.refreshedFiles.add(path);
+    performance.getDataInt('count').increment();
 
     performance.run('digest', (_) {
       _digest = utf8.encode(_fsState.getFileDigest(path));
@@ -184,13 +185,16 @@
           return getContent();
         });
 
-        var unit = performance.run('parse', (_) {
+        var unit = performance.run('parse', (performance) {
+          performance.getDataInt('count').increment();
+          performance.getDataInt('length').add(content.length);
           return parse(AnalysisErrorListener.NULL_LISTENER, content);
         });
 
-        performance.run('unlinked', (_) {
+        performance.run('unlinked', (performance) {
           var unlinkedBuilder = serializeAstCiderUnlinked(_digest, unit);
           bytes = unlinkedBuilder.toBuffer();
+          performance.getDataInt('length').add(bytes.length);
           _fsState._byteStore.put(unlinkedKey, _digest, bytes);
         });
 
diff --git a/pkg/analyzer/lib/src/dart/micro/performance.dart b/pkg/analyzer/lib/src/dart/micro/performance.dart
deleted file mode 100644
index cf591ff..0000000
--- a/pkg/analyzer/lib/src/dart/micro/performance.dart
+++ /dev/null
@@ -1,9 +0,0 @@
-// 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 'package:analyzer/src/util/performance/operation_performance.dart';
-
-/// The performance of an operation.
-@Deprecated('Use OperationPerformance')
-abstract class CiderOperationPerformance implements OperationPerformance {}
diff --git a/pkg/analyzer/lib/src/dart/micro/resolve_file.dart b/pkg/analyzer/lib/src/dart/micro/resolve_file.dart
index c496128..080fae0 100644
--- a/pkg/analyzer/lib/src/dart/micro/resolve_file.dart
+++ b/pkg/analyzer/lib/src/dart/micro/resolve_file.dart
@@ -185,7 +185,7 @@
 
           bytes = CiderUnitErrorsBuilder(
             signature: errorsSignature,
-            errors: errors.map((ErrorEncoding.encode)).toList(),
+            errors: errors.map(ErrorEncoding.encode).toList(),
           ).toBuffer();
           byteStore.put(errorsKey, errorsSignature, bytes);
         }
@@ -218,8 +218,11 @@
     @required OperationPerformanceImpl performance,
   }) {
     return performance.run('fileContext', (performance) {
-      var analysisOptions = performance.run('analysisOptions', (_) {
-        return _getAnalysisOptions(path);
+      var analysisOptions = performance.run('analysisOptions', (performance) {
+        return _getAnalysisOptions(
+          path: path,
+          performance: performance,
+        );
       });
 
       performance.run('createContext', (_) {
@@ -251,8 +254,10 @@
     return file.libraryCycle.signatureStr;
   }
 
+  /// The [completionLine] and [completionColumn] are zero based.
   ResolvedUnitResult resolve({
-    int completionOffset,
+    int completionLine,
+    int completionColumn,
     @required String path,
     OperationPerformanceImpl performance,
   }) {
@@ -269,14 +274,23 @@
         var file = fileContext.file;
         var libraryFile = file.partOfLibrary ?? file;
 
+        int completionOffset;
+        if (completionLine != null && completionColumn != null) {
+          var lineOffset = file.lineInfo.getOffsetOfLine(completionLine);
+          completionOffset = lineOffset + completionColumn;
+        }
+
         performance.run('libraryContext', (performance) {
-          libraryContext.load2(libraryFile);
+          libraryContext.load2(
+            targetLibrary: libraryFile,
+            performance: performance,
+          );
         });
 
         testView?.addResolvedFile(path);
 
+        var content = _getFileContent(path);
         var errorListener = RecordingErrorListener();
-        var content = resourceProvider.getFile(path).readAsStringSync();
         var unit = file.parse(errorListener, content);
 
         Map<FileState, UnitAnalysisResult> results;
@@ -320,19 +334,6 @@
     });
   }
 
-  @deprecated
-  ResolvedUnitResult resolve2({
-    int completionOffset,
-    @required String path,
-    OperationPerformanceImpl performance,
-  }) {
-    return resolve(
-      completionOffset: completionOffset,
-      path: path,
-      performance: performance,
-    );
-  }
-
   /// Make sure that [fsState], [contextObjects], and [libraryContext] are
   /// created and configured with the given [fileAnalysisOptions].
   ///
@@ -358,6 +359,7 @@
     if (fsState == null) {
       var featureSetProvider = FeatureSetProvider.build(
         sourceFactory: sourceFactory,
+        resourceProvider: resourceProvider,
         packages: Packages.empty,
         packageDefaultFeatureSet: analysisOptions.contextFeatures,
         nonPackageDefaultFeatureSet: analysisOptions.nonPackageFeatureSet,
@@ -419,50 +421,76 @@
   /// default options, if the file exists.
   ///
   /// Otherwise, return the default options.
-  AnalysisOptionsImpl _getAnalysisOptions(String path) {
+  AnalysisOptionsImpl _getAnalysisOptions({
+    @required String path,
+    @required OperationPerformanceImpl performance,
+  }) {
     YamlMap optionMap;
-    var folder = resourceProvider.getFile(path).parent;
-    var optionsFile = _findOptionsFile(folder);
-    if (optionsFile != null) {
-      try {
-        var optionsProvider = AnalysisOptionsProvider(sourceFactory);
-        optionMap = optionsProvider.getOptionsFromFile(optionsFile);
-      } catch (e) {
-        // ignored
-      }
-    } else {
-      Source source;
-      if (workspace is WorkspaceWithDefaultAnalysisOptions) {
-        var separator = resourceProvider.pathContext.separator;
-        if (path
-            .contains('${separator}third_party${separator}dart$separator')) {
-          source = sourceFactory
-              .forUri(WorkspaceWithDefaultAnalysisOptions.thirdPartyUri);
-        } else {
-          source =
-              sourceFactory.forUri(WorkspaceWithDefaultAnalysisOptions.uri);
-        }
-      }
 
-      if (source != null && source.exists()) {
+    var optionsFile = performance.run('findOptionsFile', (_) {
+      var folder = resourceProvider.getFile(path).parent;
+      return _findOptionsFile(folder);
+    });
+
+    if (optionsFile != null) {
+      performance.run('getOptionsFromFile', (_) {
         try {
           var optionsProvider = AnalysisOptionsProvider(sourceFactory);
-          optionMap = optionsProvider.getOptionsFromSource(source);
+          optionMap = optionsProvider.getOptionsFromFile(optionsFile);
         } catch (e) {
           // ignored
         }
+      });
+    } else {
+      var source = performance.run('defaultOptions', (_) {
+        if (workspace is WorkspaceWithDefaultAnalysisOptions) {
+          var separator = resourceProvider.pathContext.separator;
+          if (path
+              .contains('${separator}third_party${separator}dart$separator')) {
+            return sourceFactory.forUri(
+              WorkspaceWithDefaultAnalysisOptions.thirdPartyUri,
+            );
+          } else {
+            return sourceFactory.forUri(
+              WorkspaceWithDefaultAnalysisOptions.uri,
+            );
+          }
+        }
+        return null;
+      });
+
+      if (source != null && source.exists()) {
+        performance.run('getOptionsFromFile', (_) {
+          try {
+            var optionsProvider = AnalysisOptionsProvider(sourceFactory);
+            optionMap = optionsProvider.getOptionsFromSource(source);
+          } catch (e) {
+            // ignored
+          }
+        });
       }
     }
 
     var options = AnalysisOptionsImpl();
 
     if (optionMap != null) {
-      applyToAnalysisOptions(options, optionMap);
+      performance.run('applyToAnalysisOptions', (_) {
+        applyToAnalysisOptions(options, optionMap);
+      });
     }
 
     return options;
   }
 
+  /// Return the file content, the empty string if any exception.
+  String _getFileContent(String path) {
+    try {
+      return resourceProvider.getFile(path).readAsStringSync();
+    } catch (_) {
+      return '';
+    }
+  }
+
   void _throwIfNotAbsoluteNormalizedPath(String path) {
     var pathContext = resourceProvider.pathContext;
     if (pathContext.normalize(path) != path) {
@@ -526,23 +554,21 @@
   }
 
   /// Load data required to access elements of the given [targetLibrary].
-  void load2(FileState targetLibrary) {
+  void load2({
+    @required FileState targetLibrary,
+    @required OperationPerformanceImpl performance,
+  }) {
     var inputBundles = <LinkedNodeBundle>[];
 
-    var numCycles = 0;
-    var librariesTotal = 0;
-    var librariesLoaded = 0;
     var librariesLinked = 0;
     var librariesLinkedTimer = Stopwatch();
     var inputsTimer = Stopwatch();
-    var bytesGet = 0;
-    var bytesPut = 0;
 
     void loadBundle(LibraryCycle cycle) {
       if (!loadedBundles.add(cycle)) return;
 
-      numCycles++;
-      librariesTotal += cycle.libraries.length;
+      performance.getDataInt('cycleCount').increment();
+      performance.getDataInt('libraryCount').add(cycle.libraries.length);
 
       cycle.directDependencies.forEach(loadBundle);
 
@@ -562,10 +588,16 @@
           var partIndex = -1;
           for (var file in libraryFile.libraryFiles) {
             var isSynthetic = !file.exists;
+
             var content = '';
             try {
-              content = resourceProvider.getFile(file.path).readAsStringSync();
+              var resource = resourceProvider.getFile(file.path);
+              content = resource.readAsStringSync();
             } catch (_) {}
+
+            performance.getDataInt('parseCount').increment();
+            performance.getDataInt('parseLength').add(content.length);
+
             var unit = file.parse(
               AnalysisErrorListener.NULL_LISTENER,
               content,
@@ -599,13 +631,12 @@
         bytes = serializeBundle(cycle.signature, linkResult).toBuffer();
 
         byteStore.put(key, cycle.signature, bytes);
-        bytesPut += bytes.length;
+        performance.getDataInt('bytesPut').add(bytes.length);
 
         librariesLinkedTimer.stop();
       } else {
-        // TODO(scheglov) Take / clear parsed units in files.
-        bytesGet += bytes.length;
-        librariesLoaded += cycle.libraries.length;
+        performance.getDataInt('bytesGet').add(bytes.length);
+        performance.getDataInt('libraryLoadCount').add(cycle.libraries.length);
       }
 
       // We are about to load dart:core, but if we have just linked it, the
@@ -637,13 +668,9 @@
       var libraryCycle = targetLibrary.libraryCycle;
       loadBundle(libraryCycle);
       logger.writeln(
-        '[numCycles: $numCycles]'
-        '[librariesTotal: $librariesTotal]'
-        '[librariesLoaded: $librariesLoaded]'
         '[inputsTimer: ${inputsTimer.elapsedMilliseconds} ms]'
         '[librariesLinked: $librariesLinked]'
-        '[librariesLinkedTimer: ${librariesLinkedTimer.elapsedMilliseconds} ms]'
-        '[bytesGet: $bytesGet][bytesPut: $bytesPut]',
+        '[librariesLinkedTimer: ${librariesLinkedTimer.elapsedMilliseconds} ms]',
       );
     });
 
diff --git a/pkg/analyzer/lib/src/dart/resolver/ast_rewrite.dart b/pkg/analyzer/lib/src/dart/resolver/ast_rewrite.dart
index a2709ff..aeff38b 100644
--- a/pkg/analyzer/lib/src/dart/resolver/ast_rewrite.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/ast_rewrite.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/error/listener.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/resolver/scope.dart';
@@ -13,10 +14,9 @@
 /// Helper for [MethodInvocation]s into [InstanceCreationExpression] to support
 /// the optional `new` and `const` feature, or [ExtensionOverride].
 class AstRewriter {
-  final LibraryElement _libraryElement;
   final ErrorReporter _errorReporter;
 
-  AstRewriter(this._libraryElement, this._errorReporter);
+  AstRewriter(this._errorReporter);
 
   AstNode methodInvocation(Scope nameScope, MethodInvocation node) {
     SimpleIdentifier methodName = node.methodName;
@@ -33,7 +33,7 @@
         // This isn't a constructor invocation because it's in a cascade.
         return node;
       }
-      Element element = nameScope.lookup(methodName, _libraryElement);
+      Element element = nameScope.lookupIdentifier(methodName);
       if (element is ClassElement) {
         TypeName typeName = astFactory.typeName(methodName, node.typeArguments);
         ConstructorName constructorName =
@@ -57,7 +57,7 @@
         // This isn't a constructor invocation because a null aware operator is
         // being used.
       }
-      Element element = nameScope.lookup(target, _libraryElement);
+      Element element = nameScope.lookupIdentifier(target);
       if (element is ClassElement) {
         // Possible case: C.n()
         var constructorElement = element.getNamedConstructor(methodName.name);
@@ -87,7 +87,7 @@
             astFactory.simpleIdentifier(target.token),
             null,
             astFactory.simpleIdentifier(methodName.token));
-        Element prefixedElement = nameScope.lookup(identifier, _libraryElement);
+        Element prefixedElement = nameScope.lookupIdentifier(identifier);
         if (prefixedElement is ClassElement) {
           TypeName typeName = astFactory.typeName(
               astFactory.prefixedIdentifier(target, node.operator, methodName),
@@ -112,10 +112,10 @@
       }
     } else if (target is PrefixedIdentifier) {
       // Possible case: p.C.n()
-      Element prefixElement = nameScope.lookup(target.prefix, _libraryElement);
+      Element prefixElement = nameScope.lookupIdentifier(target.prefix);
       target.prefix.staticElement = prefixElement;
       if (prefixElement is PrefixElement) {
-        Element element = nameScope.lookup(target, _libraryElement);
+        Element element = nameScope.lookupIdentifier(target);
         if (element is ClassElement) {
           var constructorElement = element.getNamedConstructor(methodName.name);
           if (constructorElement != null) {
diff --git a/pkg/analyzer/lib/src/dart/resolver/body_inference_context.dart b/pkg/analyzer/lib/src/dart/resolver/body_inference_context.dart
index 6824312..6b5aaf4 100644
--- a/pkg/analyzer/lib/src/dart/resolver/body_inference_context.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/body_inference_context.dart
@@ -92,13 +92,7 @@
       endOfBlockIsReachable: endOfBlockIsReachable,
     );
 
-    DartType clampedReturnedType;
-    if (contextType == null ||
-        _typeSystem.isSubtypeOf2(actualReturnedType, contextType)) {
-      clampedReturnedType = actualReturnedType;
-    } else {
-      clampedReturnedType = nonNullifyType(_typeSystem, contextType);
-    }
+    var clampedReturnedType = _clampToContextType(actualReturnedType);
 
     if (_isGenerator) {
       if (_isAsynchronous) {
@@ -117,6 +111,35 @@
     }
   }
 
+  /// Let `T` be the **actual returned type** of a function literal.
+  DartType _clampToContextType(DartType T) {
+    // Let `R` be the greatest closure of the typing context `K`.
+    var R = contextType;
+    if (R == null) {
+      return T;
+    }
+
+    // If `R` is `void`, or the function literal is marked `async` and `R` is
+    // `FutureOr<void>`, let `S` be `void`.
+    if (_typeSystem.isNonNullableByDefault) {
+      if (R.isVoid ||
+          _isAsynchronous &&
+              R is InterfaceType &&
+              R.isDartAsyncFutureOr &&
+              R.typeArguments[0].isVoid) {
+        return VoidTypeImpl.instance;
+      }
+    }
+
+    // Otherwise, if `T <: R` then let `S` be `T`.
+    if (_typeSystem.isSubtypeOf2(T, R)) {
+      return T;
+    }
+
+    // Otherwise, let `S` be `R`.
+    return nonNullifyType(_typeSystem, R);
+  }
+
   DartType _computeActualReturnedType({
     @required bool endOfBlockIsReachable,
   }) {
@@ -138,11 +161,9 @@
   }
 
   static DartType _argumentOf(DartType type, ClassElement element) {
-    if (type is InterfaceTypeImpl) {
-      var elementType = type.asInstanceOf(element);
-      if (elementType != null) {
-        return elementType.typeArguments[0];
-      }
+    var elementType = type.asInstanceOf(element);
+    if (elementType != null) {
+      return elementType.typeArguments[0];
     }
     return null;
   }
diff --git a/pkg/analyzer/lib/src/dart/resolver/extension_member_resolver.dart b/pkg/analyzer/lib/src/dart/resolver/extension_member_resolver.dart
index c29cef9..a8a6d9e 100644
--- a/pkg/analyzer/lib/src/dart/resolver/extension_member_resolver.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/extension_member_resolver.dart
@@ -4,6 +4,7 @@
 
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/listener.dart';
diff --git a/pkg/analyzer/lib/src/dart/resolver/flow_analysis_visitor.dart b/pkg/analyzer/lib/src/dart/resolver/flow_analysis_visitor.dart
index 5a625a1..9d22406 100644
--- a/pkg/analyzer/lib/src/dart/resolver/flow_analysis_visitor.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/flow_analysis_visitor.dart
@@ -363,6 +363,11 @@
   }
 
   @override
+  bool isNever(DartType type) {
+    return typeSystem.isBottom(type);
+  }
+
+  @override
   bool isSameType(covariant TypeImpl type1, covariant TypeImpl type2) {
     return type1 == type2;
   }
diff --git a/pkg/analyzer/lib/src/dart/resolver/for_resolver.dart b/pkg/analyzer/lib/src/dart/resolver/for_resolver.dart
index 7844f5b..63a9cfb 100644
--- a/pkg/analyzer/lib/src/dart/resolver/for_resolver.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/for_resolver.dart
@@ -58,9 +58,7 @@
         ? _resolver.typeProvider.streamElement
         : _resolver.typeProvider.iterableElement;
 
-    InterfaceType iteratedType = iterableType is InterfaceTypeImpl
-        ? iterableType.asInstanceOf(iteratedElement)
-        : null;
+    InterfaceType iteratedType = iterableType.asInstanceOf(iteratedElement);
 
     if (iteratedType != null) {
       var elementType = iteratedType.typeArguments.single;
diff --git a/pkg/analyzer/lib/src/dart/resolver/invocation_inference_helper.dart b/pkg/analyzer/lib/src/dart/resolver/invocation_inference_helper.dart
index da2e57c..29e89fe 100644
--- a/pkg/analyzer/lib/src/dart/resolver/invocation_inference_helper.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/invocation_inference_helper.dart
@@ -217,7 +217,7 @@
       expression.staticType = DynamicTypeImpl.instance;
     } else {
       expression.staticType = type;
-      if (identical(type, NeverTypeImpl.instance)) {
+      if (_typeSystem.isBottom(type)) {
         _flowAnalysis?.flow?.handleExit();
       }
     }
diff --git a/pkg/analyzer/lib/src/dart/resolver/legacy_type_asserter.dart b/pkg/analyzer/lib/src/dart/resolver/legacy_type_asserter.dart
index b5dcd58..b934ae0 100644
--- a/pkg/analyzer/lib/src/dart/resolver/legacy_type_asserter.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/legacy_type_asserter.dart
@@ -114,7 +114,7 @@
       return;
     }
 
-    if (type.isBottom && type.isDartCoreNull) {
+    if (type is NeverType && type.isDartCoreNull) {
       // Never?, which is ok.
       //
       // Note: we could allow Null? and Null, but we really should be able to
diff --git a/pkg/analyzer/lib/src/dart/resolver/method_invocation_resolver.dart b/pkg/analyzer/lib/src/dart/resolver/method_invocation_resolver.dart
index 0ad5812..0118d45 100644
--- a/pkg/analyzer/lib/src/dart/resolver/method_invocation_resolver.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/method_invocation_resolver.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
@@ -480,7 +481,7 @@
 
   void _resolveReceiverNull(
       MethodInvocation node, SimpleIdentifier nameNode, String name) {
-    var element = nameScope.lookup(nameNode, _definingLibrary);
+    var element = nameScope.lookup2(name).getter;
     if (element != null) {
       element = _resolver.toLegacyElement(element);
       nameNode.staticElement = element;
@@ -545,7 +546,7 @@
     // TODO(scheglov) I don't like how we resolve prefixed names.
     // But maybe this is the only one solution.
     var prefixedName = PrefixedIdentifierImpl.temp(receiver, nameNode);
-    var element = nameScope.lookup(prefixedName, _definingLibrary);
+    var element = prefix.scope.lookup2(name).getter;
     element = _resolver.toLegacyElement(element);
     nameNode.staticElement = element;
 
diff --git a/pkg/analyzer/lib/src/dart/resolver/resolution_visitor.dart b/pkg/analyzer/lib/src/dart/resolver/resolution_visitor.dart
index d006206..6ed6207 100644
--- a/pkg/analyzer/lib/src/dart/resolver/resolution_visitor.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/resolution_visitor.dart
@@ -7,12 +7,14 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/error/listener.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/element/element.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/resolver/ast_rewrite.dart';
 import 'package:analyzer/src/dart/resolver/scope.dart';
@@ -116,7 +118,7 @@
       unitElement,
       isNonNullableByDefault,
       errorReporter,
-      AstRewriter(libraryElement, errorReporter),
+      AstRewriter(errorReporter),
       typeNameResolver,
       nameScope,
       elementWalker,
@@ -149,7 +151,7 @@
   void visitBlock(Block node) {
     var outerScope = _nameScope;
     try {
-      _nameScope = EnclosedScope(_nameScope);
+      _nameScope = LocalScope(_nameScope);
 
       var statements = node.statements;
       _buildLocalElements(statements);
@@ -172,7 +174,7 @@
           exceptionNode.offset,
         );
         _elementHolder.enclose(element);
-        _nameScope.define(element);
+        _define(element);
 
         exceptionNode.staticElement = element;
 
@@ -198,7 +200,7 @@
           stackTraceNode.offset,
         );
         _elementHolder.enclose(element);
-        _nameScope.define(element);
+        _define(element);
 
         stackTraceNode.staticElement = element;
 
@@ -336,7 +338,7 @@
   }
 
   @override
-  void visitDefaultFormalParameter(DefaultFormalParameter node) {
+  void visitDefaultFormalParameter(covariant DefaultFormalParameterImpl node) {
     NormalFormalParameter normalParameter = node.parameter;
     SimpleIdentifier nameNode = normalParameter.identifier;
 
@@ -358,7 +360,6 @@
       element.isConst = node.isConst;
       element.isExplicitlyCovariant = node.parameter.covariantKeyword != null;
       element.isFinal = node.isFinal;
-      // ignore: deprecated_member_use_from_same_package
       element.parameterKind = node.kind;
 
       if (normalParameter is SimpleFormalParameter &&
@@ -457,7 +458,7 @@
   }
 
   @override
-  void visitFieldFormalParameter(FieldFormalParameter node) {
+  void visitFieldFormalParameter(covariant FieldFormalParameterImpl node) {
     FieldFormalParameterElementImpl element;
     if (node.parent is DefaultFormalParameter) {
       element = node.declaredElement;
@@ -475,7 +476,6 @@
         element.isConst = node.isConst;
         element.isExplicitlyCovariant = node.covariantKeyword != null;
         element.isFinal = node.isFinal;
-        // ignore: deprecated_member_use_from_same_package
         element.parameterKind = node.kind;
         _setCodeRange(element, node);
         element.metadata = _createElementAnnotations(node.metadata);
@@ -507,6 +507,13 @@
   }
 
   @override
+  void visitForPartsWithDeclarations(ForPartsWithDeclarations node) {
+    _withNameScope(() {
+      super.visitForPartsWithDeclarations(node);
+    });
+  }
+
+  @override
   void visitFunctionDeclaration(FunctionDeclaration node) {
     ExecutableElementImpl element;
     if (_elementWalker != null) {
@@ -629,7 +636,9 @@
   }
 
   @override
-  void visitFunctionTypedFormalParameter(FunctionTypedFormalParameter node) {
+  void visitFunctionTypedFormalParameter(
+    covariant FunctionTypedFormalParameterImpl node,
+  ) {
     ParameterElementImpl element;
     if (node.parent is DefaultFormalParameter) {
       element = node.declaredElement;
@@ -643,7 +652,6 @@
         element.isConst = node.isConst;
         element.isExplicitlyCovariant = node.covariantKeyword != null;
         element.isFinal = node.isFinal;
-        // ignore: deprecated_member_use_from_same_package
         element.parameterKind = node.kind;
         _setCodeRange(element, node);
       }
@@ -857,7 +865,7 @@
   }
 
   @override
-  void visitSimpleFormalParameter(SimpleFormalParameter node) {
+  void visitSimpleFormalParameter(covariant SimpleFormalParameterImpl node) {
     ParameterElementImpl element;
     if (node.parent is DefaultFormalParameter) {
       element = node.declaredElement;
@@ -877,15 +885,14 @@
         element.isConst = node.isConst;
         element.isExplicitlyCovariant = node.covariantKeyword != null;
         element.isFinal = node.isFinal;
-        // ignore: deprecated_member_use_from_same_package
         element.parameterKind = node.kind;
         if (node.type == null) {
           element.hasImplicitType = true;
         }
-        (node as SimpleFormalParameterImpl).declaredElement = element;
+        node.declaredElement = element;
       }
       nameNode?.staticElement = element;
-      (node as SimpleFormalParameterImpl).declaredElement = element;
+      node.declaredElement = element;
     }
 
     node.type?.accept(this);
@@ -1054,7 +1061,7 @@
     var nameNode = node.name;
     var element = FunctionElementImpl(nameNode.name, nameNode.offset);
     nameNode.staticElement = element;
-    _nameScope.define(element);
+    _define(element);
     _elementHolder.enclose(element);
   }
 
@@ -1079,7 +1086,7 @@
       }
       variableName.staticElement = element;
       _elementHolder.enclose(element);
-      _nameScope.define(element);
+      _define(element);
 
       element.isConst = isConst;
       element.isFinal = isFinal;
@@ -1107,7 +1114,7 @@
         _setCodeRange(element, typeParameter);
       }
       name.staticElement = element;
-      _nameScope.define(element);
+      _define(element);
     }
   }
 
@@ -1125,12 +1132,16 @@
     }).toList();
   }
 
+  void _define(Element element) {
+    (_nameScope as LocalScope).add(element);
+  }
+
   /// Define given [elements] in the [_nameScope].
   void _defineElements(List<Element> elements) {
     int length = elements.length;
     for (int i = 0; i < length; i++) {
       var element = elements[i];
-      _nameScope.define(element);
+      _define(element);
     }
   }
 
@@ -1140,7 +1151,7 @@
     for (int i = 0; i < length; i++) {
       ParameterElement parameter = parameters[i];
       if (!parameter.isInitializingFormal) {
-        _nameScope.define(parameter);
+        _define(parameter);
       }
     }
   }
@@ -1275,7 +1286,7 @@
   void _withNameScope(void Function() f) {
     var current = _nameScope;
     try {
-      _nameScope = EnclosedScope(current);
+      _nameScope = LocalScope(current);
       f();
     } finally {
       _nameScope = current;
diff --git a/pkg/analyzer/lib/src/dart/resolver/scope.dart b/pkg/analyzer/lib/src/dart/resolver/scope.dart
index 34e34b51..78c625c 100644
--- a/pkg/analyzer/lib/src/dart/resolver/scope.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/scope.dart
@@ -6,27 +6,14 @@
 
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/element.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/generated/engine.dart';
 
 /// The scope defined by a block.
-class BlockScope extends EnclosedScope {
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// based on the given [block].
-  BlockScope(Scope enclosingScope, Block block) : super(enclosingScope) {
-    if (block == null) {
-      throw ArgumentError("block cannot be null");
-    }
-    _defineElements(block);
-  }
-
-  void _defineElements(Block block) {
-    for (Element element in elementsInBlock(block)) {
-      define(element);
-    }
-  }
-
+class BlockScope {
   /// Return the elements that are declared directly in the given [block]. This
   /// does not include elements declared in nested blocks.
   static Iterable<Element> elementsInBlock(Block block) sync* {
@@ -47,184 +34,6 @@
   }
 }
 
-/// The scope defined by a class.
-class ClassScope extends EnclosedScope {
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// based on the given [classElement].
-  ClassScope(Scope enclosingScope, ClassElement classElement)
-      : super(enclosingScope) {
-    if (classElement == null) {
-      throw ArgumentError("class element cannot be null");
-    }
-    _defineMembers(classElement);
-  }
-
-  /// Define the instance members defined by the given [classElement].
-  void _defineMembers(ClassElement classElement) {
-    List<PropertyAccessorElement> accessors = classElement.accessors;
-    int accessorLength = accessors.length;
-    for (int i = 0; i < accessorLength; i++) {
-      define(accessors[i]);
-    }
-    List<MethodElement> methods = classElement.methods;
-    int methodLength = methods.length;
-    for (int i = 0; i < methodLength; i++) {
-      define(methods[i]);
-    }
-  }
-}
-
-/// The scope defined for the initializers in a constructor.
-class ConstructorInitializerScope extends EnclosedScope {
-  /// Initialize a newly created scope, enclosed within the [enclosingScope].
-  ConstructorInitializerScope(Scope enclosingScope, ConstructorElement element)
-      : super(enclosingScope) {
-    _initializeFieldFormalParameters(element);
-  }
-
-  /// Initialize the local scope with all of the field formal parameters.
-  void _initializeFieldFormalParameters(ConstructorElement element) {
-    for (ParameterElement parameter in element.parameters) {
-      if (parameter is FieldFormalParameterElement) {
-        define(parameter);
-      }
-    }
-  }
-}
-
-/// A scope that is lexically enclosed in another scope.
-class EnclosedScope extends Scope {
-  /// The scope in which this scope is lexically enclosed.
-  @override
-  final Scope enclosingScope;
-
-  /// Initialize a newly created scope, enclosed within the [enclosingScope].
-  EnclosedScope(this.enclosingScope);
-
-  @override
-  Element internalLookup(String name) {
-    Element element = localLookup(name);
-    if (element != null) {
-      return element;
-    }
-    // Check enclosing scope.
-    return enclosingScope.internalLookup(name);
-  }
-
-  @override
-  Element _internalLookupPrefixed(String prefix, String name) {
-    return enclosingScope._internalLookupPrefixed(prefix, name);
-  }
-}
-
-/// The scope defined by an extension.
-class ExtensionScope extends EnclosedScope {
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// that represents the given [_extensionElement].
-  ExtensionScope(Scope enclosingScope, ExtensionElement extensionElement)
-      : super(enclosingScope) {
-    _defineMembers(extensionElement);
-  }
-
-  /// Define the static members defined by the given [extensionElement]. The
-  /// instance members should only be found if they would be found by normal
-  /// lookup on `this`.
-  void _defineMembers(ExtensionElement extensionElement) {
-    List<PropertyAccessorElement> accessors = extensionElement.accessors;
-    int accessorLength = accessors.length;
-    for (int i = 0; i < accessorLength; i++) {
-      define(accessors[i]);
-    }
-    List<MethodElement> methods = extensionElement.methods;
-    int methodLength = methods.length;
-    for (int i = 0; i < methodLength; i++) {
-      define(methods[i]);
-    }
-  }
-}
-
-/// The scope defined by a function.
-class FunctionScope extends EnclosedScope {
-  /// The element representing the function that defines this scope.
-  final FunctionTypedElement _functionElement;
-
-  /// A flag indicating whether the parameters have already been defined, used
-  /// to prevent the parameters from being defined multiple times.
-  bool _parametersDefined = false;
-
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// that represents the given [_functionElement].
-  FunctionScope(Scope enclosingScope, this._functionElement)
-      : super(EnclosedScope(EnclosedScope(enclosingScope))) {
-    if (_functionElement == null) {
-      throw ArgumentError("function element cannot be null");
-    }
-    _defineTypeParameters();
-  }
-
-  /// Define the parameters for the given function in the scope that encloses
-  /// this function.
-  void defineParameters() {
-    if (_parametersDefined) {
-      return;
-    }
-    _parametersDefined = true;
-    Scope parameterScope = enclosingScope;
-    List<ParameterElement> parameters = _functionElement.parameters;
-    int length = parameters.length;
-    for (int i = 0; i < length; i++) {
-      ParameterElement parameter = parameters[i];
-      if (!parameter.isInitializingFormal) {
-        parameterScope.define(parameter);
-      }
-    }
-  }
-
-  /// Define the type parameters for the function.
-  void _defineTypeParameters() {
-    Scope typeParameterScope = enclosingScope.enclosingScope;
-    List<TypeParameterElement> typeParameters = _functionElement.typeParameters;
-    int length = typeParameters.length;
-    for (int i = 0; i < length; i++) {
-      TypeParameterElement typeParameter = typeParameters[i];
-      typeParameterScope.define(typeParameter);
-    }
-  }
-}
-
-/// The scope defined by a function type alias.
-class FunctionTypeScope extends EnclosedScope {
-  final FunctionTypeAliasElement _typeElement;
-
-  bool _parametersDefined = false;
-
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// that represents the given [_typeElement].
-  FunctionTypeScope(Scope enclosingScope, this._typeElement)
-      : super(EnclosedScope(enclosingScope)) {
-    _defineTypeParameters();
-  }
-
-  /// Define the parameters for the function type alias.
-  void defineParameters() {
-    if (_parametersDefined) {
-      return;
-    }
-    _parametersDefined = true;
-    for (ParameterElement parameter in _typeElement.function.parameters) {
-      define(parameter);
-    }
-  }
-
-  /// Define the type parameters for the function type alias.
-  void _defineTypeParameters() {
-    Scope typeParameterScope = enclosingScope;
-    for (TypeParameterElement typeParameter in _typeElement.typeParameters) {
-      typeParameterScope.define(typeParameter);
-    }
-  }
-}
-
 /// The scope statements that can be the target of unlabeled `break` and
 /// `continue` statements.
 class ImplicitLabelScope {
@@ -246,7 +55,7 @@
   /// `continue` statement, or `null` if there is no appropriate target.
   Statement getTarget(bool isContinue) {
     if (outerScope == null) {
-      // This scope represents the toplevel of a function body, so it doesn't
+      // This scope represents the top-level of a function body, so it doesn't
       // match either break or continue.
       return null;
     }
@@ -292,286 +101,6 @@
   }
 }
 
-/// The scope containing all of the names available from imported libraries.
-class LibraryImportScope extends Scope {
-  /// The element representing the library in which this scope is enclosed.
-  final LibraryElement _definingLibrary;
-
-  /// A list of the namespaces representing the names that are available in this
-  /// scope from imported libraries.
-  List<Namespace> _importedNamespaces;
-
-  /// A table mapping prefixes that have been referenced to a map from the names
-  /// that have been referenced to the element associated with the prefixed
-  /// name.
-  Map<String, Map<String, Element>> _definedPrefixedNames;
-
-  /// Cache of public extensions defined in this library's imported namespaces.
-  List<ExtensionElement> _extensions;
-
-  /// Initialize a newly created scope representing the names imported into the
-  /// [_definingLibrary].
-  LibraryImportScope(this._definingLibrary) {
-    _createImportedNamespaces();
-  }
-
-  @override
-  List<ExtensionElement> get extensions {
-    if (_extensions == null) {
-      _extensions = [];
-      List<ImportElement> imports = _definingLibrary.imports;
-      int count = imports.length;
-      for (int i = 0; i < count; i++) {
-        for (var element in imports[i].namespace.definedNames.values) {
-          if (element is ExtensionElement && !_extensions.contains(element)) {
-            _extensions.add(element);
-          }
-        }
-      }
-    }
-    return _extensions;
-  }
-
-  @override
-  void define(Element element) {
-    if (!Scope.isPrivateName(element.displayName)) {
-      super.define(element);
-    }
-  }
-
-  @override
-  Element internalLookup(String name) {
-    return localLookup(name);
-  }
-
-  @override
-  Element localLookup(String name) {
-    var element = super.localLookup(name);
-    if (element != null) {
-      return element;
-    }
-
-    element = _lookupInImportedNamespaces((namespace) {
-      return namespace.get(name);
-    });
-    if (element != null) {
-      defineNameWithoutChecking(name, element);
-    }
-
-    return element;
-  }
-
-  @override
-  bool shouldIgnoreUndefined(Identifier node) {
-    Iterable<NamespaceCombinator> getShowCombinators(
-        ImportElement importElement) {
-      return importElement.combinators.whereType<ShowElementCombinator>();
-    }
-
-    if (node is PrefixedIdentifier) {
-      String prefix = node.prefix.name;
-      String name = node.identifier.name;
-      List<ImportElement> imports = _definingLibrary.imports;
-      int count = imports.length;
-      for (int i = 0; i < count; i++) {
-        ImportElement importElement = imports[i];
-        if (importElement.prefix?.name == prefix &&
-            importElement.importedLibrary?.isSynthetic != false) {
-          Iterable<NamespaceCombinator> showCombinators =
-              getShowCombinators(importElement);
-          if (showCombinators.isEmpty) {
-            return true;
-          }
-          for (ShowElementCombinator combinator in showCombinators) {
-            if (combinator.shownNames.contains(name)) {
-              return true;
-            }
-          }
-        }
-      }
-    } else if (node is SimpleIdentifier) {
-      String name = node.name;
-      List<ImportElement> imports = _definingLibrary.imports;
-      int count = imports.length;
-      for (int i = 0; i < count; i++) {
-        ImportElement importElement = imports[i];
-        if (importElement.prefix == null &&
-            importElement.importedLibrary?.isSynthetic != false) {
-          for (ShowElementCombinator combinator
-              in getShowCombinators(importElement)) {
-            if (combinator.shownNames.contains(name)) {
-              return true;
-            }
-          }
-        }
-      }
-    }
-    return false;
-  }
-
-  /// Create all of the namespaces associated with the libraries imported into
-  /// this library. The names are not added to this scope, but are stored for
-  /// later reference.
-  void _createImportedNamespaces() {
-    List<ImportElement> imports = _definingLibrary.imports;
-    int count = imports.length;
-    _importedNamespaces = List<Namespace>(count);
-    for (int i = 0; i < count; i++) {
-      _importedNamespaces[i] = imports[i].namespace;
-    }
-  }
-
-  /// Add the given [element] to this scope without checking for duplication or
-  /// hiding.
-  void _definePrefixedNameWithoutChecking(
-      String prefix, String name, Element element) {
-    _definedPrefixedNames ??= HashMap<String, Map<String, Element>>();
-    Map<String, Element> unprefixedNames = _definedPrefixedNames.putIfAbsent(
-        prefix, () => HashMap<String, Element>());
-    unprefixedNames[name] = element;
-  }
-
-  @override
-  Element _internalLookupPrefixed(String prefix, String name) {
-    Element element = _localPrefixedLookup(prefix, name);
-    if (element != null) {
-      return element;
-    }
-    element = _lookupInImportedNamespaces(
-        (Namespace namespace) => namespace.getPrefixed(prefix, name));
-    if (element != null) {
-      _definePrefixedNameWithoutChecking(prefix, name, element);
-    }
-    return element;
-  }
-
-  /// Return the element with which the given [prefix] and [name] are
-  /// associated, or `null` if the name is not defined within this scope.
-  Element _localPrefixedLookup(String prefix, String name) {
-    if (_definedPrefixedNames != null) {
-      Map<String, Element> unprefixedNames = _definedPrefixedNames[prefix];
-      if (unprefixedNames != null) {
-        return unprefixedNames[name];
-      }
-    }
-    return null;
-  }
-
-  Element _lookupInImportedNamespaces(
-      Element Function(Namespace namespace) lookup) {
-    Element result;
-
-    bool hasPotentialConflict = false;
-    for (int i = 0; i < _importedNamespaces.length; i++) {
-      Element element = lookup(_importedNamespaces[i]);
-      if (element != null) {
-        if (result == null || result == element) {
-          result = element;
-        } else {
-          hasPotentialConflict = true;
-        }
-      }
-    }
-
-    if (hasPotentialConflict) {
-      var sdkElements = <Element>{};
-      var nonSdkElements = <Element>{};
-      for (int i = 0; i < _importedNamespaces.length; i++) {
-        Element element = lookup(_importedNamespaces[i]);
-        if (element != null) {
-          if (element is NeverElementImpl || element.library.isInSdk) {
-            sdkElements.add(element);
-          } else {
-            nonSdkElements.add(element);
-          }
-        }
-      }
-      if (sdkElements.length > 1 || nonSdkElements.length > 1) {
-        var conflictingElements = <Element>[
-          ...sdkElements,
-          ...nonSdkElements,
-        ];
-        return MultiplyDefinedElementImpl(
-            _definingLibrary.context,
-            _definingLibrary.session,
-            conflictingElements.first.name,
-            conflictingElements);
-      }
-      if (nonSdkElements.isNotEmpty) {
-        result = nonSdkElements.first;
-      } else if (sdkElements.isNotEmpty) {
-        result = sdkElements.first;
-      }
-    }
-
-    return result;
-  }
-}
-
-/// A scope containing all of the names defined in a given library.
-class LibraryScope extends EnclosedScope {
-  final List<ExtensionElement> _extensions = <ExtensionElement>[];
-
-  /// Initialize a newly created scope representing the names defined in the
-  /// [definingLibrary].
-  LibraryScope(LibraryElement definingLibrary)
-      : super(LibraryImportScope(definingLibrary)) {
-    _defineTopLevelNames(definingLibrary);
-
-    // For `dart:core` to be able to pass analysis, it has to have `dynamic`
-    // added to its library scope. Note that this is not true of, for instance,
-    // `Object`, because `Object` has a source definition which is not possible
-    // for `dynamic`.
-    if (definingLibrary.isDartCore) {
-      define(DynamicElementImpl.instance);
-    }
-  }
-
-  @override
-  List<ExtensionElement> get extensions =>
-      enclosingScope.extensions.toList()..addAll(_extensions);
-
-  /// Add to this scope all of the public top-level names that are defined in
-  /// the given [compilationUnit].
-  void _defineLocalNames(CompilationUnitElement compilationUnit) {
-    for (PropertyAccessorElement element in compilationUnit.accessors) {
-      define(element);
-    }
-    for (ClassElement element in compilationUnit.enums) {
-      define(element);
-    }
-    for (ExtensionElement element in compilationUnit.extensions) {
-      define(element);
-      _extensions.add(element);
-    }
-    for (FunctionElement element in compilationUnit.functions) {
-      define(element);
-    }
-    for (FunctionTypeAliasElement element
-        in compilationUnit.functionTypeAliases) {
-      define(element);
-    }
-    for (ClassElement element in compilationUnit.mixins) {
-      define(element);
-    }
-    for (ClassElement element in compilationUnit.types) {
-      define(element);
-    }
-  }
-
-  /// Add to this scope all of the names that are explicitly defined in the
-  /// [definingLibrary].
-  void _defineTopLevelNames(LibraryElement definingLibrary) {
-    for (PrefixElement prefix in definingLibrary.prefixes) {
-      define(prefix);
-    }
-    _defineLocalNames(definingLibrary.definingCompilationUnit);
-    for (CompilationUnitElement compilationUnit in definingLibrary.parts) {
-      _defineLocalNames(compilationUnit);
-    }
-  }
-}
-
 /// A mapping of identifiers to the elements represented by those identifiers.
 /// Namespaces are the building blocks for scopes.
 class Namespace {
@@ -666,6 +195,19 @@
     return Namespace(definedNames);
   }
 
+  /// Return elements imported with the given [element].
+  Iterable<Element> getImportedElements(ImportElement element) {
+    var importedLibrary = element.importedLibrary;
+
+    // If the URI is invalid.
+    if (importedLibrary == null) {
+      return [];
+    }
+
+    var map = _getExportMapping(importedLibrary);
+    return _applyCombinators(map, element.combinators).values;
+  }
+
   /// Add all of the names in the given [namespace] to the table of
   /// [definedNames].
   void _addAllFromNamespace(
@@ -679,7 +221,7 @@
   /// publicly visible name.
   void _addIfPublic(Map<String, Element> definedNames, Element element) {
     String name = element.name;
-    if (name != null && name.isNotEmpty && !Scope.isPrivateName(name)) {
+    if (name != null && name.isNotEmpty && !Identifier.isPrivateName(name)) {
       definedNames[name] = element;
     }
   }
@@ -858,133 +400,60 @@
   }
 }
 
-/// A name scope used by the resolver to determine which names are visible at
-/// any given point in the code.
-abstract class Scope {
-  /// The prefix used to mark an identifier as being private to its library.
-  static int PRIVATE_NAME_PREFIX = 0x5F;
-
-  /// The suffix added to the declared name of a setter when looking up the
-  /// setter. Used to disambiguate between a getter and a setter that have the
-  /// same name.
-  static String SETTER_SUFFIX = "=";
-
-  /// The name used to look up the method used to implement the unary minus
-  /// operator. Used to disambiguate between the unary and binary operators.
-  static String UNARY_MINUS = "unary-";
-
-  /// A table mapping names that are defined in this scope to the element
-  /// representing the thing declared with that name.
-  Map<String, Element> _definedNames;
-
-  /// Return the scope in which this scope is lexically enclosed.
-  Scope get enclosingScope => null;
-
-  /// The list of extensions defined in this scope.
-  List<ExtensionElement> get extensions =>
-      enclosingScope == null ? <ExtensionElement>[] : enclosingScope.extensions;
-
-  /// Add the given [element] to this scope. If there is already an element with
-  /// the given name defined in this scope, then the original element will
-  /// continue to be mapped to the name.
-  void define(Element element) {
-    String name = _getName(element);
-    if (name != null && name.isNotEmpty) {
-      _definedNames ??= HashMap<String, Element>();
-      _definedNames.putIfAbsent(name, () => element);
-    }
-  }
-
-  /// Add the given [element] to this scope without checking for duplication or
-  /// hiding.
-  void defineNameWithoutChecking(String name, Element element) {
-    _definedNames ??= HashMap<String, Element>();
-    _definedNames[name] = element;
-  }
-
-  /// Add the given [element] to this scope without checking for duplication or
-  /// hiding.
-  void defineWithoutChecking(Element element) {
-    _definedNames ??= HashMap<String, Element>();
-    _definedNames[_getName(element)] = element;
-  }
-
-  /// Return the element with which the given [name] is associated, or `null` if
-  /// the name is not defined within this scope.
-  Element internalLookup(String name);
-
-  /// Return the element with which the given [name] is associated, or `null` if
-  /// the name is not defined within this scope. This method only returns
-  /// elements that are directly defined within this scope, not elements that
-  /// are defined in an enclosing scope.
-  Element localLookup(String name) {
-    if (_definedNames != null) {
-      return _definedNames[name];
-    }
-    return null;
-  }
-
-  /// Return the element with which the given [identifier] is associated, or
-  /// `null` if the name is not defined within this scope. The
-  /// [referencingLibrary] is the library that contains the reference to the
-  /// name, used to implement library-level privacy.
-  Element lookup(Identifier identifier, LibraryElement referencingLibrary) {
-    if (identifier is PrefixedIdentifier) {
-      return _internalLookupPrefixed(
-          identifier.prefix.name, identifier.identifier.name);
-    }
-    return internalLookup(identifier.name);
-  }
-
+extension ScopeExtension on Scope {
   /// Return `true` if the fact that the given [node] is not defined should be
   /// ignored (from the perspective of error reporting). This will be the case
   /// if there is at least one import that defines the node's prefix, and if
   /// that import either has no show combinators or has a show combinator that
   /// explicitly lists the node's name.
   bool shouldIgnoreUndefined(Identifier node) {
-    if (enclosingScope != null) {
-      return enclosingScope.shouldIgnoreUndefined(node);
+    if (node is PrefixedIdentifier) {
+      return _enclosingLibraryScope.shouldIgnoreUndefined(
+        prefix: node.prefix.name,
+        name: node.identifier.name,
+      );
     }
-    return false;
+
+    return _enclosingLibraryScope.shouldIgnoreUndefined(
+      prefix: null,
+      name: (node as SimpleIdentifier).name,
+    );
   }
 
-  /// Return the name that will be used to look up the given [element].
-  String _getName(Element element) {
-    if (element is MethodElement) {
-      MethodElement method = element;
-      if (method.name == "-" && method.parameters.isEmpty) {
-        return UNARY_MINUS;
+  List<ExtensionElement> get extensions {
+    return _enclosingLibraryScope.extensions;
+  }
+
+  LibraryScope get _enclosingLibraryScope {
+    var scope = this;
+    while (scope != null) {
+      if (scope is LibraryScope) {
+        return scope;
+      }
+      scope = (scope as EnclosedScope).parent;
+    }
+    throw StateError('Can only be used in a LibraryScope.');
+  }
+
+  // TODO(scheglov) check if it might be inlined
+  Element lookupIdentifier(Identifier identifier) {
+    if (identifier is SimpleIdentifier) {
+      var result = this.lookup2(identifier.name);
+      return result.getter ?? result.setter;
+    } else {
+      var prefixedIdentifier = identifier as PrefixedIdentifier;
+
+      var prefixIdentifier = prefixedIdentifier.prefix;
+      var prefixName = prefixIdentifier.name;
+      var prefixElement = this.lookup2(prefixName).getter;
+      prefixIdentifier.staticElement = prefixElement;
+
+      if (prefixElement is PrefixElement) {
+        var name = prefixedIdentifier.identifier.name;
+        var result = prefixElement.scope.lookup2(name);
+        return result.getter ?? result.setter;
       }
     }
-    return element.name;
-  }
-
-  /// Return the element with which the given [prefix] and [name] are
-  /// associated, or `null` if the name is not defined within this scope.
-  Element _internalLookupPrefixed(String prefix, String name);
-
-  /// Return `true` if the given [name] is a library-private name.
-  static bool isPrivateName(String name) =>
-      name != null && name.startsWith('_');
-}
-
-/// The scope defined by the type parameters in an element that defines type
-/// parameters.
-class TypeParameterScope extends EnclosedScope {
-  /// Initialize a newly created scope, enclosed within the [enclosingScope],
-  /// that defines the type parameters from the given [element].
-  TypeParameterScope(Scope enclosingScope, TypeParameterizedElement element)
-      : super(enclosingScope) {
-    if (element == null) {
-      throw ArgumentError("element cannot be null");
-    }
-    _defineTypeParameters(element);
-  }
-
-  /// Define the type parameters declared by the [element].
-  void _defineTypeParameters(TypeParameterizedElement element) {
-    for (TypeParameterElement typeParameter in element.typeParameters) {
-      define(typeParameter);
-    }
+    return null;
   }
 }
diff --git a/pkg/analyzer/lib/src/dart/resolver/type_name_resolver.dart b/pkg/analyzer/lib/src/dart/resolver/type_name_resolver.dart
index 183cf50..1c99b27 100644
--- a/pkg/analyzer/lib/src/dart/resolver/type_name_resolver.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/type_name_resolver.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/listener.dart';
@@ -23,7 +24,7 @@
   final TypeSystemImpl typeSystem;
   final DartType dynamicType;
   final bool isNonNullableByDefault;
-  final LibraryElement definingLibrary;
+  final LibraryElement definingLibrary; // TODO(scheglov) remove
   final ErrorReporter errorReporter;
 
   Scope nameScope;
@@ -74,7 +75,25 @@
       return;
     }
 
-    var element = nameScope.lookup(typeIdentifier, definingLibrary);
+    // TODO(scheglov) Update to use `lookup2`.
+    var element = nameScope.lookupIdentifier(typeIdentifier);
+
+    // TODO(scheglov) When fixing the previous TODO, report the prefix sooner.
+    if (typeIdentifier is PrefixedIdentifier) {
+      var prefix = typeIdentifier.prefix;
+      var prefixElement = prefix.staticElement;
+      if (prefixElement != null &&
+          prefixElement is! PrefixElement &&
+          prefixElement is! ClassElement) {
+        errorReporter.reportErrorForNode(
+          CompileTimeErrorCode.PREFIX_SHADOWED_BY_LOCAL_DECLARATION,
+          prefix,
+          [prefix.name],
+        );
+        node.type = dynamicType;
+        return;
+      }
+    }
 
     if (element is MultiplyDefinedElement) {
       _setElement(typeIdentifier, element);
@@ -88,17 +107,11 @@
       return;
     }
 
+    // TODO(scheglov) Can we do rewriting better with using `lookup2`?
     if (_rewriteToConstructorName(node)) {
       return;
     }
 
-    // Full `prefix.Name` cannot be resolved, try to resolve 'prefix' alone.
-    if (typeIdentifier is PrefixedIdentifier) {
-      var prefixIdentifier = typeIdentifier.prefix;
-      var prefixElement = nameScope.lookup(prefixIdentifier, definingLibrary);
-      prefixIdentifier.staticElement = prefixElement;
-    }
-
     node.type = dynamicType;
     if (nameScope.shouldIgnoreUndefined(typeIdentifier)) {
       return;
@@ -305,7 +318,7 @@
         constructorName is ConstructorName &&
         constructorName.name == null) {
       var classIdentifier = typeIdentifier.prefix;
-      var classElement = nameScope.lookup(classIdentifier, definingLibrary);
+      var classElement = nameScope.lookupIdentifier(classIdentifier);
       if (classElement is ClassElement) {
         var constructorIdentifier = typeIdentifier.identifier;
 
@@ -347,7 +360,7 @@
     } else if (typeName is PrefixedIdentifier) {
       typeName.identifier.staticElement = element;
       SimpleIdentifier prefix = typeName.prefix;
-      prefix.staticElement = nameScope.lookup(prefix, definingLibrary);
+      prefix.staticElement = nameScope.lookupIdentifier(prefix);
     }
   }
 
diff --git a/pkg/analyzer/lib/src/dart/resolver/typed_literal_resolver.dart b/pkg/analyzer/lib/src/dart/resolver/typed_literal_resolver.dart
index 7e3a0f5..84d9c7b0 100644
--- a/pkg/analyzer/lib/src/dart/resolver/typed_literal_resolver.dart
+++ b/pkg/analyzer/lib/src/dart/resolver/typed_literal_resolver.dart
@@ -178,7 +178,7 @@
       var expressionType = element.expression.staticType;
       if (expressionType.isDynamic) {
         return expressionType;
-      } else if (expressionType is InterfaceTypeImpl) {
+      } else if (expressionType is InterfaceType) {
         if (expressionType.isDartCoreNull) {
           if (element.isNullAware) {
             return expressionType;
@@ -336,16 +336,16 @@
       if (!isNull && expressionType is InterfaceType) {
         if (_typeSystem.isSubtypeOf2(
             expressionType, _typeProvider.iterableForSetMapDisambiguation)) {
-          InterfaceType iterableType = (expressionType as InterfaceTypeImpl)
-              .asInstanceOf(_typeProvider.iterableElement);
+          InterfaceType iterableType =
+              expressionType.asInstanceOf(_typeProvider.iterableElement);
           return _InferredCollectionElementTypeInformation(
               elementType: iterableType.typeArguments[0],
               keyType: null,
               valueType: null);
         } else if (_typeSystem.isSubtypeOf2(
             expressionType, _typeProvider.mapForSetMapDisambiguation)) {
-          InterfaceType mapType = (expressionType as InterfaceTypeImpl)
-              .asInstanceOf(_typeProvider.mapElement);
+          InterfaceType mapType =
+              expressionType.asInstanceOf(_typeProvider.mapElement);
           List<DartType> typeArguments = mapType.typeArguments;
           return _InferredCollectionElementTypeInformation(
               elementType: null,
diff --git a/pkg/analyzer/lib/src/dart/sdk/sdk.dart b/pkg/analyzer/lib/src/dart/sdk/sdk.dart
index f8e3074..d50e6e6 100644
--- a/pkg/analyzer/lib/src/dart/sdk/sdk.dart
+++ b/pkg/analyzer/lib/src/dart/sdk/sdk.dart
@@ -3,7 +3,6 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'dart:collection';
-import 'dart:io' as io;
 
 import 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/analysis/utilities.dart';
@@ -15,7 +14,6 @@
 import 'package:analyzer/src/generated/java_engine_io.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:analyzer/src/generated/source_io.dart';
-import 'package:path/path.dart' as pathos;
 import 'package:yaml/yaml.dart';
 
 /// An abstract implementation of a Dart SDK in which the available libraries
@@ -522,58 +520,6 @@
       return null;
     }
   }
-
-  /// Return the default directory for the Dart SDK, or `null` if the directory
-  /// cannot be determined (or does not exist). The default directory is
-  /// provided by a system property named `com.google.dart.sdk`.
-  static Folder defaultSdkDirectory(ResourceProvider resourceProvider) {
-    // TODO(brianwilkerson) This is currently only being used in the analysis
-    // server's Driver class to find the default SDK. The command-line analyzer
-    // uses cli_utils to find the SDK. Not sure why they're different.
-    String sdkProperty = getSdkProperty(resourceProvider);
-    if (sdkProperty == null) {
-      return null;
-    }
-    Folder sdkDirectory = resourceProvider.getFolder(sdkProperty);
-    if (!sdkDirectory.exists) {
-      return null;
-    }
-    return sdkDirectory;
-  }
-
-  static String getSdkProperty(ResourceProvider resourceProvider) {
-    String exec = io.Platform.resolvedExecutable;
-    if (exec.isEmpty) {
-      return null;
-    }
-    pathos.Context pathContext = resourceProvider.pathContext;
-    if (pathContext.style != pathos.context.style) {
-      // This will only happen when running tests.
-      if (exec.startsWith(RegExp('[a-zA-Z]:'))) {
-        exec = exec.substring(2);
-      } else if (resourceProvider is MemoryResourceProvider) {
-        exec = resourceProvider.convertPath(exec);
-      }
-      exec = pathContext.fromUri(pathos.context.toUri(exec));
-    }
-    // Might be "xcodebuild/ReleaseIA32/dart" with "sdk" sibling
-    String outDir = pathContext.dirname(pathContext.dirname(exec));
-    String sdkPath = pathContext.join(pathContext.dirname(outDir), "sdk");
-    if (resourceProvider.getFolder(sdkPath).exists) {
-      // We are executing in the context of a test.  sdkPath is the path to the
-      // *source* files for the SDK.  But we want to test using the path to the
-      // *built* SDK if possible.
-      String builtSdkPath =
-          pathContext.join(pathContext.dirname(exec), 'dart-sdk');
-      if (resourceProvider.getFolder(builtSdkPath).exists) {
-        return builtSdkPath;
-      } else {
-        return sdkPath;
-      }
-    }
-    // probably be "dart-sdk/bin/dart"
-    return pathContext.dirname(pathContext.dirname(exec));
-  }
 }
 
 /// An object used to read and parse the libraries file
diff --git a/pkg/analyzer/lib/src/diagnostic/diagnostic_factory.dart b/pkg/analyzer/lib/src/diagnostic/diagnostic_factory.dart
index 63533de..14c09b7 100644
--- a/pkg/analyzer/lib/src/diagnostic/diagnostic_factory.dart
+++ b/pkg/analyzer/lib/src/diagnostic/diagnostic_factory.dart
@@ -3,6 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/diagnostic/diagnostic.dart';
 import 'package:analyzer/error/error.dart';
@@ -47,6 +48,25 @@
     ]);
   }
 
+  /// Return a diagnostic indicating that the [duplicateKey] (in a constant map)
+  /// is a duplicate of the [originalKey].
+  AnalysisError invalidNullAwareAfterShortCircuit(Source source, int offset,
+      int length, List<Object> arguments, Token previousToken) {
+    var lexeme = previousToken.lexeme;
+    return AnalysisError(
+        source,
+        offset,
+        length,
+        StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+        arguments, [
+      DiagnosticMessageImpl(
+          filePath: source.fullName,
+          message: "The operator '$lexeme' is causing the short circuiting.",
+          offset: previousToken.offset,
+          length: previousToken.length)
+    ]);
+  }
+
   /// Return a diagnostic indicating that the given [identifier] was referenced
   /// before it was declared.
   AnalysisError referencedBeforeDeclaration(
diff --git a/pkg/analyzer/lib/src/error/best_practices_verifier.dart b/pkg/analyzer/lib/src/error/best_practices_verifier.dart
index ba3ca9e..3839122 100644
--- a/pkg/analyzer/lib/src/error/best_practices_verifier.dart
+++ b/pkg/analyzer/lib/src/error/best_practices_verifier.dart
@@ -13,8 +13,6 @@
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/listener.dart';
-import 'package:analyzer/file_system/file_system.dart';
-import 'package:analyzer/src/context/builder.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/element/type.dart';
@@ -65,7 +63,7 @@
   final _InvalidAccessVerifier _invalidAccessVerifier;
 
   /// The [WorkspacePackage] in which [_currentLibrary] is declared.
-  WorkspacePackage _workspacePackage;
+  final WorkspacePackage _workspacePackage;
 
   /// The [LinterContext] used for possible const calculations.
   LinterContext _linterContext;
@@ -87,9 +85,9 @@
     String content, {
     @required TypeSystemImpl typeSystem,
     @required InheritanceManager3 inheritanceManager,
-    @required ResourceProvider resourceProvider,
     @required DeclaredVariables declaredVariables,
     @required AnalysisOptions analysisOptions,
+    @required WorkspacePackage workspacePackage,
   })  : _nullType = typeProvider.nullType,
         _typeSystem = typeSystem,
         _isNonNullableByDefault = typeSystem.isNonNullableByDefault,
@@ -97,10 +95,9 @@
             (analysisOptions as AnalysisOptionsImpl).strictInference,
         _inheritanceManager = inheritanceManager,
         _invalidAccessVerifier =
-            _InvalidAccessVerifier(_errorReporter, _currentLibrary) {
+            _InvalidAccessVerifier(_errorReporter, _currentLibrary),
+        _workspacePackage = workspacePackage {
     _inDeprecatedMember = _currentLibrary.hasDeprecated;
-    String libraryPath = _currentLibrary.source.fullName;
-    _workspacePackage = _getPackage(libraryPath, resourceProvider);
 
     _linterContext = LinterContextImpl(
       null /* allUnits */,
@@ -1356,20 +1353,6 @@
     }
   }
 
-  WorkspacePackage _getPackage(String root, ResourceProvider resourceProvider) {
-    Workspace workspace = _currentLibrary.session?.analysisContext?.workspace;
-    // If there is no driver setup (as in test environments), we need to create
-    // a workspace ourselves.
-    // todo (pq): fix tests or otherwise de-dup this logic shared w/ library_analyzer.
-    if (workspace == null) {
-      final builder = ContextBuilder(
-          resourceProvider, null /* sdkManager */, null /* contentCache */);
-      workspace =
-          ContextBuilder.createWorkspace(resourceProvider, root, builder);
-    }
-    return workspace?.findPackageFor(root);
-  }
-
   bool _isLibraryInWorkspacePackage(LibraryElement library) {
     if (_workspacePackage == null || library == null) {
       // Better to not make a big claim that they _are_ in the same package,
@@ -1543,9 +1526,9 @@
     }
     AstNode grandparent = parent?.parent;
 
-    var element;
-    var name;
-    var node;
+    Element element;
+    String name;
+    AstNode node;
 
     if (grandparent is ConstructorName) {
       element = grandparent.staticElement;
@@ -1626,18 +1609,7 @@
     if (element == null) {
       return false;
     }
-    if (element == superElement) {
-      return true;
-    }
-    // TODO(scheglov) `allSupertypes` is very expensive
-    var allSupertypes = element.allSupertypes;
-    for (var i = 0; i < allSupertypes.length; i++) {
-      var supertype = allSupertypes[i];
-      if (supertype.element == superElement) {
-        return true;
-      }
-    }
-    return false;
+    return element.thisType.asInstanceOf(superElement) != null;
   }
 
   bool _hasVisibleForTemplate(Element element) {
diff --git a/pkg/analyzer/lib/src/error/codes.dart b/pkg/analyzer/lib/src/error/codes.dart
index 6071d56..70e254d 100644
--- a/pkg/analyzer/lib/src/error/codes.dart
+++ b/pkg/analyzer/lib/src/error/codes.dart
@@ -2735,6 +2735,30 @@
           correction: "Try making the deferred import non-deferred.");
 
   /**
+   * It is a compile-time error if the declared return type of a function marked
+   * 'async*' is not a supertype of 'Stream<T>' for some type 'T'.
+   */
+  static const CompileTimeErrorCode ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE =
+      CompileTimeErrorCode(
+          'ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE',
+          "Functions marked 'async*' must have a return type that is a "
+              "supertype of 'Stream<T>' for some type 'T'.",
+          correction: "Try fixing the return type of the function, or "
+              "removing the modifier 'async*' from the function body.");
+
+  /**
+   * It is a compile-time error if the declared return type of a function marked
+   * 'sync*' is not a supertype of 'Iterable<T>' for some type 'T'.
+   */
+  static const CompileTimeErrorCode ILLEGAL_SYNC_GENERATOR_RETURN_TYPE =
+      CompileTimeErrorCode(
+          'ILLEGAL_SYNC_GENERATOR_RETURN_TYPE',
+          "Functions marked 'sync*' must have a return type that is a "
+              "supertype of 'Iterable<T>' for some type 'T'.",
+          correction: "Try fixing the return type of the function, or "
+              "removing the modifier 'sync*' from the function body.");
+
+  /**
    * 7.10 Superinterfaces: It is a compile-time error if the implements clause
    * of a class <i>C</i> specifies a malformed type or deferred type as a
    * superinterface.
@@ -3033,6 +3057,20 @@
               "inconsistency.");
 
   /**
+   * It is a compile-time error if a part file has a different language version
+   * override than its library.
+   *
+   * https://github.com/dart-lang/language/blob/master/accepted/
+   * future-releases/language-versioning/feature-specification.md
+   * #individual-library-language-version-override
+   */
+  static const CompileTimeErrorCode INCONSISTENT_LANGUAGE_VERSION_OVERRIDE =
+      CompileTimeErrorCode(
+          'INCONSISTENT_LANGUAGE_VERSION_OVERRIDE',
+          "Parts must have exactly the same language version override as "
+              "the library.");
+
+  /**
    * Parameters:
    * 0: the name of the initializing formal that is not an instance variable in
    *    the immediately enclosing class
@@ -3377,6 +3415,95 @@
           correction: "Try using a top-level variable or a field.");
 
   /**
+   * Parameters:
+   * 0: the type of the function
+   * 1: the expected function type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_FUNCTION = CompileTimeErrorCode(
+      'INVALID_CAST_FUNCTION',
+      "The function '{0}' has type '{1}' that isn't of expected type "
+          "'{2}'. This means its parameter or return type doesn't match what "
+          "is expected.");
+
+  /**
+   * Parameters:
+   * 0: the type of the torn-off function expression
+   * 1: the expected function type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_FUNCTION_EXPR =
+      CompileTimeErrorCode(
+          'INVALID_CAST_FUNCTION_EXPR',
+          "The function expression type '{0}' isn't of type '{1}'. "
+              "This means its parameter or return type doesn't match what is "
+              "expected. Consider changing parameter type(s) or the returned "
+              "type(s).");
+
+  /**
+   * Parameters:
+   * 0: the type of the literal
+   * 1: the expected type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_LITERAL = CompileTimeErrorCode(
+      'INVALID_CAST_LITERAL',
+      "The literal '{0}' with type '{1}' isn't of expected type '{2}'.");
+
+  /**
+   * Parameters:
+   * 0: the type of the list literal
+   * 1: the expected type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_LITERAL_LIST =
+      CompileTimeErrorCode(
+          'INVALID_CAST_LITERAL_LIST',
+          "The list literal type '{0}' isn't of expected type '{1}'. The "
+              "list's type can be changed with an explicit generic type "
+              "argument or by changing the element types.");
+
+  /**
+   * Parameters:
+   * 0: the type of the map literal
+   * 1: the expected type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_LITERAL_MAP =
+      CompileTimeErrorCode(
+          'INVALID_CAST_LITERAL_MAP',
+          "The map literal type '{0}' isn't of expected type '{1}'. The maps's "
+              "type can be changed with an explicit generic type arguments or "
+              "by changing the key and value types.");
+
+  /**
+   * Parameters:
+   * 0: the type of the set literal
+   * 1: the expected type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_LITERAL_SET =
+      CompileTimeErrorCode(
+          'INVALID_CAST_LITERAL_SET',
+          "The set literal type '{0}' isn't of expected type '{1}'. The set's "
+              "type can be changed with an explicit generic type argument or "
+              "by changing the element types.");
+
+  /**
+   * Parameters:
+   * 0: the type of the instantiated object
+   * 1: the expected type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_NEW_EXPR = CompileTimeErrorCode(
+      'INVALID_CAST_NEW_EXPR',
+      "The constructor returns type '{0}' that isn't of expected type '{1}'.");
+
+  /**
+   * Parameters:
+   * 0: the type of the torn-off method
+   * 1: the expected function type
+   */
+  static const CompileTimeErrorCode INVALID_CAST_METHOD = CompileTimeErrorCode(
+      'INVALID_CAST_METHOD',
+      "The method tear-off '{0}' has type '{1}' that isn't of expected type "
+          "'{2}'. This means its parameter or return type doesn't match what "
+          "is expected.");
+
+  /**
    * TODO(brianwilkerson) Remove this when we have decided on how to report
    * errors in compile-time constants. Until then, this acts as a placeholder
    * for more informative errors.
@@ -4249,6 +4376,18 @@
           "Mixin can only be applied to class.");
 
   /**
+   * Technically this is [IMPLEMENTS_SUPER_CLASS].
+   * See https://github.com/dart-lang/sdk/issues/25765#issuecomment-307422593
+   *
+   * Parameters:
+   * 0: the name of the class that appears in both "extends" and "with" clauses
+   */
+  static const CompileTimeErrorCode MIXINS_SUPER_CLASS = CompileTimeErrorCode(
+      'MIXINS_SUPER_CLASS',
+      "'{0}' can't be used in both 'extends' and 'with' clauses.",
+      correction: "Try removing one of the occurrences.");
+
+  /**
    * 7.6.1 Generative Constructors: A generative constructor may be redirecting,
    * in which case its only action is to invoke another generative constructor.
    */
@@ -5171,6 +5310,14 @@
   /**
    * No parameters.
    */
+  static const CompileTimeErrorCode NOT_INSTANTIATED_BOUND =
+      CompileTimeErrorCode('NOT_INSTANTIATED_BOUND',
+          'Type parameter bound types must be instantiated.',
+          correction: 'Try adding type arguments to the type parameter bound.');
+
+  /**
+   * No parameters.
+   */
   // #### Description
   //
   // The analyzer produces this diagnostic when the static type of the
@@ -5564,6 +5711,24 @@
           hasPublishedDocs: true);
 
   /**
+   * From the `Static Types` section of the spec:
+   *
+   *     A type T is malformed if:
+   *     - T has the form id or the form prefix.id, and in the enclosing lexical
+   *       scope, the name id (respectively prefix.id) does not denote a type.
+   *
+   * In particular, this means that if an import prefix is shadowed by a local
+   * declaration, it is an error to try to use it as a prefix for a type name.
+   */
+  static const CompileTimeErrorCode PREFIX_SHADOWED_BY_LOCAL_DECLARATION =
+      CompileTimeErrorCode(
+          'PREFIX_SHADOWED_BY_LOCAL_DECLARATION',
+          "The prefix '{0}' can't be used here because it is shadowed by a "
+              "local declaration.",
+          correction:
+              "Try renaming either the prefix or the local declaration.");
+
+  /**
    * It is an error for a mixin to add a private name that conflicts with a
    * private name added by a superclass or another mixin.
    */
@@ -5582,6 +5747,12 @@
       CompileTimeErrorCode('PRIVATE_OPTIONAL_PARAMETER',
           "Named optional parameters can't start with an underscore.");
 
+  static const CompileTimeErrorCode PRIVATE_SETTER = CompileTimeErrorCode(
+      'PRIVATE_SETTER',
+      "The setter '{0}' is private and can't be accessed outside of the "
+          "library that declares it.",
+      correction: "Try making it public.");
+
   /**
    * 12.1 Constants: It is a compile-time error if the value of a compile-time
    * constant expression depends on itself.
@@ -7113,18 +7284,6 @@
           correction: "Try adjusting the number of type arguments.");
 
   /**
-   * 9 Functions: It is a static warning if the declared return type of a
-   * function marked async* may not be assigned to Stream.
-   */
-  static const StaticTypeWarningCode ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE =
-      StaticTypeWarningCode(
-          'ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE',
-          "Functions marked 'async*' must have a return type assignable to "
-              "'Stream'.",
-          correction: "Try fixing the return type of the function, or "
-              "removing the modifier 'async*' from the function body.");
-
-  /**
    * No parameters.
    */
   // #### Description
@@ -7173,18 +7332,6 @@
           hasPublishedDocs: true);
 
   /**
-   * 9 Functions: It is a static warning if the declared return type of a
-   * function marked sync* may not be assigned to Iterable.
-   */
-  static const StaticTypeWarningCode ILLEGAL_SYNC_GENERATOR_RETURN_TYPE =
-      StaticTypeWarningCode(
-          'ILLEGAL_SYNC_GENERATOR_RETURN_TYPE',
-          "Functions marked 'sync*' must have a return type assignable to "
-              "'Iterable'.",
-          correction: "Try fixing the return type of the function, or "
-              "removing the modifier 'sync*' from the function body.");
-
-  /**
    * Parameters:
    * 0: the name of the static member
    * 1: the kind of the static member (field, getter, setter, or method)
@@ -8846,23 +8993,6 @@
       errorSeverity: ErrorSeverity.WARNING,
       hasPublishedDocs: true);
 
-  /**
-   * 14.2 Exports: It is a static warning to export two different libraries with
-   * the same name.
-   *
-   * Parameters:
-   * 0: the uri pointing to a first library
-   * 1: the uri pointing to a second library
-   * 2:e the shared name of the exported libraries
-   */
-  static const StaticWarningCode EXPORT_DUPLICATED_LIBRARY_NAMED =
-      StaticWarningCode(
-          'EXPORT_DUPLICATED_LIBRARY_NAMED',
-          "The exported libraries '{0}' and '{1}' can't have the same name "
-              "'{2}'.",
-          correction:
-              "Try adding a hide clause to one of the export directives.");
-
   @Deprecated('Use CompileTimeErrorCode.EXTRA_POSITIONAL_ARGUMENTS')
   static const CompileTimeErrorCode EXTRA_POSITIONAL_ARGUMENTS =
       CompileTimeErrorCode.EXTRA_POSITIONAL_ARGUMENTS;
@@ -9223,22 +9353,6 @@
               "of the type '{2}' of its setter '{3}'.",
           correction: "Try changing the types so that they are compatible.");
 
-  /**
-   * 14.1 Imports: It is a static warning to import two different libraries with
-   * the same name.
-   *
-   * Parameters:
-   * 0: the uri pointing to a first library
-   * 1: the uri pointing to a second library
-   * 2: the shared name of the imported libraries
-   */
-  static const StaticWarningCode IMPORT_DUPLICATED_LIBRARY_NAMED =
-      StaticWarningCode(
-          'IMPORT_DUPLICATED_LIBRARY_NAMED',
-          "The imported libraries '{0}' and '{1}' can't have the same name "
-              "'{2}'.",
-          correction: "Try adding a hide clause to one of the imports.");
-
   @Deprecated('Use CompileTimeErrorCode.IMPORT_OF_NON_LIBRARY')
   static const CompileTimeErrorCode IMPORT_OF_NON_LIBRARY =
       CompileTimeErrorCode.IMPORT_OF_NON_LIBRARY;
@@ -9327,6 +9441,22 @@
           hasPublishedDocs: true);
 
   /**
+   * Parameters:
+   * 0: The null-aware operator that is invalid
+   * 1: The non-null-aware operator that can replace the invalid operator
+   */
+  static const StaticWarningCode
+      INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT =
+      StaticWarningCodeWithUniqueName(
+          'INVALID_NULL_AWARE_OPERATOR',
+          'INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT',
+          "The target expression can't be null because of short-circuiting, so "
+              "the null-aware operator '{0}' can't be used.",
+          correction: "Try replace the operator '{0}' with '{1}'.",
+          errorSeverity: ErrorSeverity.WARNING,
+          hasPublishedDocs: true);
+
+  /**
    * 7.1 Instance Methods: It is a static warning if an instance method
    * <i>m1</i> overrides an instance member <i>m2</i>, the signature of
    * <i>m2</i> explicitly specifies a default value for a formal parameter
@@ -10615,10 +10745,12 @@
   const StaticWarningCodeWithUniqueName(
       String name, this.uniqueName, String message,
       {String correction,
+      ErrorSeverity errorSeverity = ErrorSeverity.ERROR,
       bool hasPublishedDocs,
       bool isUnresolvedIdentifier = false})
       : super(name, message,
             correction: correction,
+            errorSeverity: errorSeverity,
             hasPublishedDocs: hasPublishedDocs,
             isUnresolvedIdentifier: isUnresolvedIdentifier);
 }
@@ -10655,68 +10787,12 @@
       'COULD_NOT_INFER',
       "Couldn't infer type parameter '{0}'.{1}");
 
-  static const StrongModeCode INVALID_CAST_LITERAL = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_LITERAL',
-      "The literal '{0}' with type '{1}' isn't of expected type '{2}'.");
-
-  static const StrongModeCode INVALID_CAST_LITERAL_LIST = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_LITERAL_LIST',
-      "The list literal type '{0}' isn't of expected type '{1}'. The list's "
-          "type can be changed with an explicit generic type argument or by "
-          "changing the element types.");
-
-  static const StrongModeCode INVALID_CAST_LITERAL_MAP = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_LITERAL_MAP',
-      "The map literal type '{0}' isn't of expected type '{1}'. The maps's "
-          "type can be changed with an explicit generic type arguments or by "
-          "changing the key and value types.");
-
-  static const StrongModeCode INVALID_CAST_LITERAL_SET = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_LITERAL_SET',
-      "The set literal type '{0}' isn't of expected type '{1}'. The set's "
-          "type can be changed with an explicit generic type argument or by "
-          "changing the element types.");
-
-  static const StrongModeCode INVALID_CAST_FUNCTION_EXPR = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_FUNCTION_EXPR',
-      "The function expression type '{0}' isn't of type '{1}'. "
-          "This means its parameter or return type doesn't match what is "
-          "expected. Consider changing parameter type(s) or the returned "
-          "type(s).");
-
-  static const StrongModeCode INVALID_CAST_NEW_EXPR = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_NEW_EXPR',
-      "The constructor returns type '{0}' that isn't of expected type '{1}'.");
-
-  static const StrongModeCode INVALID_CAST_METHOD = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_METHOD',
-      "The method tear-off '{0}' has type '{1}' that isn't of expected type "
-          "'{2}'. This means its parameter or return type doesn't match what "
-          "is expected.");
-
-  static const StrongModeCode INVALID_CAST_FUNCTION = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'INVALID_CAST_FUNCTION',
-      "The function '{0}' has type '{1}' that isn't of expected type "
-          "'{2}'. This means its parameter or return type doesn't match what "
-          "is expected.");
-
   static const StrongModeCode INVALID_SUPER_INVOCATION = StrongModeCode(
       ErrorType.COMPILE_TIME_ERROR,
       'INVALID_SUPER_INVOCATION',
       "The super call must be last in an initializer "
           "list (see https://goo.gl/EY6hDP): '{0}'.");
 
-  static const StrongModeCode DYNAMIC_INVOKE = StrongModeCode(
-      ErrorType.HINT, 'DYNAMIC_INVOKE', "'{0}' requires a dynamic invoke.");
-
   static const StrongModeCode IMPLICIT_DYNAMIC_PARAMETER = StrongModeCode(
       ErrorType.COMPILE_TIME_ERROR,
       'IMPLICIT_DYNAMIC_PARAMETER',
@@ -10777,12 +10853,6 @@
       "Missing type arguments for calling generic function type '{0}'.",
       correction: _implicitDynamicCorrection);
 
-  static const StrongModeCode NOT_INSTANTIATED_BOUND = StrongModeCode(
-      ErrorType.COMPILE_TIME_ERROR,
-      'NOT_INSTANTIATED_BOUND',
-      "Type parameter bound types must be instantiated.",
-      correction: "Try adding type arguments.");
-
   /*
    * TODO(brianwilkerson) Make the TOP_LEVEL_ error codes be errors rather than
    * hints and then clean up the function _errorSeverity in
diff --git a/pkg/analyzer/lib/src/error/correct_override.dart b/pkg/analyzer/lib/src/error/correct_override.dart
index 0512bac..8abb0b4 100644
--- a/pkg/analyzer/lib/src/error/correct_override.dart
+++ b/pkg/analyzer/lib/src/error/correct_override.dart
@@ -172,7 +172,7 @@
             i,
           );
           if (superParameter != null) {
-            var parameterSuperList = (result[parameter] ??= []);
+            var parameterSuperList = result[parameter] ??= [];
             var superType = _superSubstitution(superMember)
                 .substituteType(superParameter.type);
             parameterSuperList.add(
diff --git a/pkg/analyzer/lib/src/error/literal_element_verifier.dart b/pkg/analyzer/lib/src/error/literal_element_verifier.dart
index e3098b0..2d455a8 100644
--- a/pkg/analyzer/lib/src/error/literal_element_verifier.dart
+++ b/pkg/analyzer/lib/src/error/literal_element_verifier.dart
@@ -7,7 +7,6 @@
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/listener.dart';
-import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/error/codes.dart';
 
@@ -144,10 +143,9 @@
 
     expressionType = typeSystem.resolveToBound(expressionType);
 
-    InterfaceType iterableType;
-    if (expressionType is InterfaceTypeImpl) {
-      iterableType = expressionType.asInstanceOf(typeProvider.iterableElement);
-    }
+    var iterableType = expressionType.asInstanceOf(
+      typeProvider.iterableElement,
+    );
 
     if (iterableType == null) {
       return errorReporter.reportErrorForNode(
@@ -187,10 +185,9 @@
 
     expressionType = typeSystem.resolveToBound(expressionType);
 
-    InterfaceType mapType;
-    if (expressionType is InterfaceTypeImpl) {
-      mapType = expressionType.asInstanceOf(typeProvider.mapElement);
-    }
+    var mapType = expressionType.asInstanceOf(
+      typeProvider.mapElement,
+    );
 
     if (mapType == null) {
       return errorReporter.reportErrorForNode(
diff --git a/pkg/analyzer/lib/src/error/return_type_verifier.dart b/pkg/analyzer/lib/src/error/return_type_verifier.dart
index eca4fd0..ab59f54 100644
--- a/pkg/analyzer/lib/src/error/return_type_verifier.dart
+++ b/pkg/analyzer/lib/src/error/return_type_verifier.dart
@@ -10,6 +10,7 @@
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
+import 'package:analyzer/src/error/analyzer_error_code.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/error_verifier.dart';
 import 'package:meta/meta.dart';
@@ -87,19 +88,33 @@
 
     void checkElement(
       ClassElement expectedElement,
-      StaticTypeWarningCode errorCode,
+      AnalyzerErrorCode errorCode,
     ) {
-      if (!_isLegalReturnType(expectedElement)) {
+      void reportError() {
         enclosingExecutable.hasLegalReturnType = false;
         _errorReporter.reportErrorForNode(errorCode, returnType);
       }
+
+      // It is a compile-time error if the declared return type of
+      // a function marked `sync*` or `async*` is `void`.
+      if (enclosingExecutable.isGenerator) {
+        if (enclosingExecutable.returnType.isVoid) {
+          return reportError();
+        }
+      }
+
+      // It is a compile-time error if the declared return type of
+      // a function marked `...` is not a supertype of `...`.
+      if (!_isLegalReturnType(expectedElement)) {
+        return reportError();
+      }
     }
 
     if (enclosingExecutable.isAsynchronous) {
       if (enclosingExecutable.isGenerator) {
         checkElement(
           _typeProvider.streamElement,
-          StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE,
+          CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE,
         );
       } else {
         checkElement(
@@ -110,7 +125,7 @@
     } else if (enclosingExecutable.isGenerator) {
       checkElement(
         _typeProvider.iterableElement,
-        StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE,
+        CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE,
       );
     }
   }
diff --git a/pkg/analyzer/lib/src/error/unused_local_elements_verifier.dart b/pkg/analyzer/lib/src/error/unused_local_elements_verifier.dart
index a713c1e..fd25c70 100644
--- a/pkg/analyzer/lib/src/error/unused_local_elements_verifier.dart
+++ b/pkg/analyzer/lib/src/error/unused_local_elements_verifier.dart
@@ -107,6 +107,18 @@
   }
 
   @override
+  void visitMethodInvocation(MethodInvocation node) {
+    var function = node.methodName.staticElement;
+    if (function is FunctionElement || function is MethodElement) {
+      for (var argument in node.argumentList.arguments) {
+        var parameter = argument.staticParameterElement;
+        usedElements.elements.add(parameter);
+      }
+    }
+    super.visitMethodInvocation(node);
+  }
+
+  @override
   void visitPostfixExpression(PostfixExpression node) {
     var element = node.staticElement;
     usedElements.members.add(element);
@@ -135,16 +147,39 @@
     }
     bool isIdentifierRead = _isReadIdentifier(node);
     if (element is PropertyAccessorElement &&
-        element.isSynthetic &&
         isIdentifierRead &&
         element.variable is TopLevelVariableElement) {
-      usedElements.addElement(element.variable);
+      if (element.isSynthetic) {
+        usedElements.addElement(element.variable);
+      } else {
+        usedElements.members.add(element);
+        _addMemberAndCorrespondingGetter(element);
+      }
     } else if (element is LocalVariableElement) {
       if (isIdentifierRead) {
         usedElements.addElement(element);
       }
     } else {
       _useIdentifierElement(node);
+      var parent = node.parent;
+      // If [node] is a method tear-off, assume all parameters are used.
+      var functionReferenceIsCall =
+          (element is ExecutableElement && parent is MethodInvocation) ||
+              // named constructor
+              (element is ConstructorElement &&
+                  parent is ConstructorName &&
+                  parent.parent is InstanceCreationExpression) ||
+              // unnamed constructor
+              (element is ClassElement &&
+                  parent.parent is ConstructorName &&
+                  parent.parent.parent is InstanceCreationExpression);
+      if (element is ExecutableElement &&
+          isIdentifierRead &&
+          !functionReferenceIsCall) {
+        for (var parameter in element.parameters) {
+          usedElements.addElement(parameter);
+        }
+      }
       var enclosingElement = element?.enclosingElement;
       if (element == null) {
         if (isIdentifierRead) {
@@ -163,17 +198,23 @@
           !identical(element, _enclosingExec)) {
         usedElements.members.add(element);
         if (isIdentifierRead) {
-          // Store the corresponding getter.
-          if (element is PropertyAccessorElement && element.isSetter) {
-            element = (element as PropertyAccessorElement).correspondingGetter;
-          }
-          usedElements.members.add(element);
-          usedElements.readMembers.add(element);
+          _addMemberAndCorrespondingGetter(element);
         }
       }
     }
   }
 
+  /// Add [element] as a used member and, if [element] is a setter, add its
+  /// corresponding getter as a used member.
+  void _addMemberAndCorrespondingGetter(Element element) {
+    if (element is PropertyAccessorElement && element.isSetter) {
+      usedElements.members.add(element.correspondingGetter);
+      usedElements.readMembers.add(element.correspondingGetter);
+    } else {
+      usedElements.readMembers.add(element);
+    }
+  }
+
   /// Marks an [Element] of [node] as used in the library.
   void _useIdentifierElement(Identifier node) {
     Element element = node.staticElement;
@@ -269,6 +310,17 @@
       : _libraryUri = library.source.uri;
 
   @override
+  void visitFormalParameterList(FormalParameterList node) {
+    for (var element in node.parameterElements) {
+      if (!_isUsedElement(element)) {
+        _reportErrorForElement(
+            HintCode.UNUSED_ELEMENT_PARAMETER, element, [element.displayName]);
+      }
+    }
+    super.visitFormalParameterList(node);
+  }
+
+  @override
   void visitSimpleIdentifier(SimpleIdentifier node) {
     if (node.inDeclarationContext()) {
       var element = node.staticElement;
@@ -314,6 +366,24 @@
       (element is ClassElement || element is ExtensionElement) &&
       element.isPrivate;
 
+  /// Returns whether [element] is accessible outside of the library in which
+  /// it is declared.
+  bool _isPubliclyAccessible(ExecutableElement element) {
+    if (element.isPrivate) {
+      return false;
+    }
+    var enclosingElement = element.enclosingElement;
+    if (enclosingElement is ClassElement &&
+        enclosingElement.isPrivate &&
+        (element.isStatic || element is ConstructorElement)) {
+      return false;
+    } else if (enclosingElement is ExtensionElement &&
+        enclosingElement.isPrivate) {
+      return false;
+    }
+    return true;
+  }
+
   /// Returns whether [element] is a private element which is read somewhere in
   /// the library.
   bool _isReadMember(Element element) {
@@ -352,6 +422,24 @@
     if (element is LocalVariableElement ||
         element is FunctionElement && !element.isStatic) {
       // local variable or function
+    } else if (element is ParameterElement) {
+      var enclosingElement = element.enclosingElement;
+      // Only report unused parameters of methods or functions.
+      if (enclosingElement is! ConstructorElement &&
+          enclosingElement is! FunctionElement &&
+          enclosingElement is! MethodElement) {
+        return true;
+      }
+
+      if (!element.isOptional) {
+        return true;
+      }
+      if (_isPubliclyAccessible(enclosingElement)) {
+        return true;
+      }
+      if (_overridesUsedParameter(element, enclosingElement)) {
+        return true;
+      }
     } else {
       if (element.isPublic) {
         return true;
@@ -361,20 +449,8 @@
   }
 
   bool _isUsedMember(ExecutableElement element) {
-    var enclosingElement = element.enclosingElement;
-    if (element.isPublic) {
-      if (enclosingElement is ClassElement &&
-          enclosingElement.isPrivate &&
-          element.isStatic) {
-        // Public static members of private classes are inaccessible from
-        // outside the library in which they are declared.
-      } else if (enclosingElement is ExtensionElement &&
-          enclosingElement.isPrivate) {
-        // Public members of private extensions are inaccessible from outside
-        // the library in which they are declared.
-      } else {
-        return true;
-      }
+    if (_isPubliclyAccessible(element)) {
+      return true;
     }
     if (element.isSynthetic) {
       return true;
@@ -389,19 +465,64 @@
     return _overridesUsedElement(element);
   }
 
-  // Check if this is a class member which overrides a super class's class
-  // member which is used.
-  bool _overridesUsedElement(Element element) {
+  Iterable<ExecutableElement> _overriddenElements(Element element) {
     Element enclosingElement = element.enclosingElement;
     if (enclosingElement is ClassElement) {
       Name name = Name(_libraryUri, element.name);
-      Iterable<ExecutableElement> overriddenElements = _inheritanceManager
-          .getOverridden2(enclosingElement, name)
-          ?.map((ExecutableElement e) =>
-              (e is ExecutableMember) ? e.declaration : e);
-      if (overriddenElements != null) {
-        return overriddenElements.any((ExecutableElement e) =>
-            _usedElements.members.contains(e) || _overridesUsedElement(e));
+      var overridden =
+          _inheritanceManager.getOverridden2(enclosingElement, name);
+      if (overridden == null) {
+        return [];
+      }
+      return overridden.map((e) => (e is ExecutableMember) ? e.declaration : e);
+    } else {
+      return [];
+    }
+  }
+
+  /// Check if [element] is a class member which overrides a super class's class
+  /// member which is used.
+  bool _overridesUsedElement(Element element) {
+    return _overriddenElements(element).any((ExecutableElement e) =>
+        _usedElements.members.contains(e) || _overridesUsedElement(e));
+  }
+
+  /// Check if [element] is a parameter of a method which overrides a super
+  /// class's method in which the corresponding parameter is used.
+  bool _overridesUsedParameter(
+      ParameterElement element, ExecutableElement enclosingElement) {
+    var overriddenElements = _overriddenElements(enclosingElement);
+    for (var overridden in overriddenElements) {
+      ParameterElement correspondingParameter;
+      if (element.isNamed) {
+        correspondingParameter = overridden.parameters
+            .firstWhere((p) => p.name == element.name, orElse: () => null);
+      } else {
+        var parameterIndex = 0;
+        var parameterCount = enclosingElement.parameters.length;
+        while (parameterIndex < parameterCount) {
+          if (enclosingElement.parameters[parameterIndex] == element) {
+            break;
+          }
+          parameterIndex++;
+        }
+        if (overridden.parameters.length <= parameterIndex) {
+          // Something is wrong with the overridden element. Ignore it.
+          continue;
+        }
+        correspondingParameter = overridden.parameters[parameterIndex];
+      }
+      // The parameter was added in the override.
+      if (correspondingParameter == null) {
+        continue;
+      }
+      // The parameter was made optional in the override.
+      if (correspondingParameter.isRequiredNamed ||
+          correspondingParameter.isRequiredPositional) {
+        return true;
+      }
+      if (_usedElements.elements.contains(correspondingParameter)) {
+        return true;
       }
     }
     return false;
diff --git a/pkg/analyzer/lib/src/fasta/ast_builder.dart b/pkg/analyzer/lib/src/fasta/ast_builder.dart
index ceda591..a8c359f 100644
--- a/pkg/analyzer/lib/src/fasta/ast_builder.dart
+++ b/pkg/analyzer/lib/src/fasta/ast_builder.dart
@@ -7,6 +7,7 @@
         LocatedMessage,
         Message,
         MessageCode,
+        messageAbstractClassMember,
         messageConstConstructorWithBody,
         messageConstructorWithTypeParameters,
         messageDirectiveAfterDeclaration,
@@ -20,8 +21,8 @@
         messageInvalidThisInInitializer,
         messageMissingAssignableSelector,
         messageNativeClauseShouldBeAnnotation,
-        messageTypedefNotFunction,
         messageOperatorWithTypeParameters,
+        messageTypedefNotFunction,
         templateDuplicateLabelInSwitchStatement,
         templateExpectedButGot,
         templateExpectedIdentifier,
@@ -836,6 +837,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -847,6 +849,10 @@
     assert(optional(';', semicolon));
     debugEvent("Fields");
 
+    if (!enableNonNullable && abstractToken != null) {
+      handleRecoverableError(
+          messageAbstractClassMember, abstractToken, abstractToken);
+    }
     if (externalToken != null) {
       handleRecoverableError(
           messageExternalField, externalToken, externalToken);
@@ -1204,6 +1210,7 @@
 
   @override
   void endExtensionFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1218,8 +1225,8 @@
       // an error at this point, but we include them in order to get navigation,
       // search, etc.
     }
-    endClassFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    endClassFields(abstractToken, externalToken, staticToken, covariantToken,
+        lateToken, varFinalOrConst, count, beginToken, endToken);
   }
 
   @override
@@ -1842,6 +1849,7 @@
 
   @override
   void endMixinFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1850,8 +1858,8 @@
       int count,
       Token beginToken,
       Token endToken) {
-    endClassFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    endClassFields(abstractToken, externalToken, staticToken, covariantToken,
+        lateToken, varFinalOrConst, count, beginToken, endToken);
   }
 
   @override
diff --git a/pkg/analyzer/lib/src/fasta/error_converter.dart b/pkg/analyzer/lib/src/fasta/error_converter.dart
index 7a75120..7dc779c4 100644
--- a/pkg/analyzer/lib/src/fasta/error_converter.dart
+++ b/pkg/analyzer/lib/src/fasta/error_converter.dart
@@ -149,27 +149,31 @@
         return;
       case "INVALID_CAST_FUNCTION":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_FUNCTION, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_FUNCTION, offset, length);
         return;
       case "INVALID_CAST_FUNCTION_EXPR":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_FUNCTION_EXPR, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_FUNCTION_EXPR, offset, length);
         return;
       case "INVALID_CAST_LITERAL_LIST":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_LITERAL_LIST, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_LITERAL_LIST, offset, length);
         return;
       case "INVALID_CAST_LITERAL_MAP":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_LITERAL_MAP, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_LITERAL_MAP, offset, length);
+        return;
+      case "INVALID_CAST_LITERAL_SET":
+        errorReporter?.reportErrorForOffset(
+            CompileTimeErrorCode.INVALID_CAST_LITERAL_SET, offset, length);
         return;
       case "INVALID_CAST_METHOD":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_METHOD, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_METHOD, offset, length);
         return;
       case "INVALID_CAST_NEW_EXPR":
         errorReporter?.reportErrorForOffset(
-            StrongModeCode.INVALID_CAST_NEW_EXPR, offset, length);
+            CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, offset, length);
         return;
       case "INVALID_CODE_POINT":
         errorReporter?.reportErrorForOffset(
diff --git a/pkg/analyzer/lib/src/generated/element_resolver.dart b/pkg/analyzer/lib/src/generated/element_resolver.dart
index f4ecf94..1b0cb36 100644
--- a/pkg/analyzer/lib/src/generated/element_resolver.dart
+++ b/pkg/analyzer/lib/src/generated/element_resolver.dart
@@ -198,7 +198,7 @@
         prefix.staticElement = element;
         if (element is PrefixElement) {
           // TODO(brianwilkerson) Report this error?
-          element = _resolver.nameScope.lookup(identifier, _definingLibrary);
+          element = _resolver.nameScope.lookupIdentifier(identifier);
           name.staticElement = element;
           return;
         }
@@ -500,13 +500,13 @@
     //
     Element prefixElement = prefix.staticElement;
     if (prefixElement is PrefixElement) {
-      Element element = _resolver.nameScope.lookup(node, _definingLibrary);
+      Element element = _resolver.nameScope.lookupIdentifier(node);
       if (element == null && identifier.inSetterContext()) {
         Identifier setterName = PrefixedIdentifierImpl.temp(
             node.prefix,
             SimpleIdentifierImpl(StringToken(TokenType.STRING,
                 "${node.identifier.name}=", node.identifier.offset - 1)));
-        element = _resolver.nameScope.lookup(setterName, _definingLibrary);
+        element = _resolver.nameScope.lookupIdentifier(setterName);
       }
       element = _resolver.toLegacyElement(element);
       if (element == null && _resolver.nameScope.shouldIgnoreUndefined(node)) {
@@ -1334,8 +1334,15 @@
         ExecutableElement element;
 
         var setter = typeReference.getSetter(propertyName.name);
-        if (setter != null && setter.isAccessibleIn(_definingLibrary)) {
+        if (setter != null) {
           element = setter;
+          if (!setter.isAccessibleIn(_definingLibrary)) {
+            _errorReporter.reportErrorForNode(
+              CompileTimeErrorCode.PRIVATE_SETTER,
+              propertyName,
+              [propertyName.name, typeReference.name],
+            );
+          }
         }
 
         if (element != null) {
@@ -1523,39 +1530,38 @@
   /// which it could be resolved, or `null` if it could not be resolved. This
   /// does not record the results of the resolution.
   Element _resolveSimpleIdentifier(SimpleIdentifier identifier) {
-    Element element = _resolver.nameScope.lookup(identifier, _definingLibrary);
+    var lookupResult = _resolver.nameScope.lookup2(identifier.name);
+
+    Element element = lookupResult.getter;
     element = _resolver.toLegacyElement(element);
+
     if (element is PropertyAccessorElement && identifier.inSetterContext()) {
-      PropertyInducingElement variable =
-          (element as PropertyAccessorElement).variable;
-      if (variable != null) {
-        PropertyAccessorElement setter = variable.setter;
-        if (setter == null) {
-          //
-          // Check to see whether there might be a locally defined getter and
-          // an inherited setter.
-          //
-          ClassElement enclosingClass = _resolver.enclosingClass;
-          if (enclosingClass != null) {
-            var result = _typePropertyResolver.resolve(
-              receiver: null,
-              receiverType: enclosingClass.thisType,
-              name: identifier.name,
-              receiverErrorNode: identifier,
-              nameErrorNode: identifier,
-            );
-            setter = result.setter;
-          }
+      PropertyAccessorElement setter = lookupResult.setter;
+      if (setter == null) {
+        //
+        // Check to see whether there might be a locally defined getter and
+        // an inherited setter.
+        //
+        ClassElement enclosingClass = _resolver.enclosingClass;
+        if (enclosingClass != null) {
+          var result = _typePropertyResolver.resolve(
+            receiver: null,
+            receiverType: enclosingClass.thisType,
+            name: identifier.name,
+            receiverErrorNode: identifier,
+            nameErrorNode: identifier,
+          );
+          setter = result.setter;
         }
-        if (setter != null) {
-          element = setter;
-        }
+      }
+      if (setter != null) {
+        setter = _resolver.toLegacyElement(setter);
+        element = setter;
       }
     } else if (element == null &&
         (identifier.inSetterContext() ||
             identifier.parent is CommentReference)) {
-      Identifier setterId = SyntheticIdentifier('${identifier.name}=');
-      element = _resolver.nameScope.lookup(setterId, _definingLibrary);
+      element = lookupResult.setter;
       element = _resolver.toLegacyElement(element);
     }
     if (element == null) {
diff --git a/pkg/analyzer/lib/src/generated/engine.dart b/pkg/analyzer/lib/src/generated/engine.dart
index d25b96d..387f3d4 100644
--- a/pkg/analyzer/lib/src/generated/engine.dart
+++ b/pkg/analyzer/lib/src/generated/engine.dart
@@ -754,7 +754,7 @@
       buffer.addString(linterVersion ?? '');
       buffer.addInt(lintRules.length);
       for (Linter lintRule in lintRules) {
-        buffer.addString(lintRule.lintCode.uniqueName);
+        buffer.addString(lintRule.name);
       }
 
       // Append plugin names.
@@ -860,19 +860,6 @@
     enableLazyAssignmentOperators = options.enableLazyAssignmentOperators;
   }
 
-  /// Return whether the given lists of lints are equal.
-  static bool compareLints(List<Linter> a, List<Linter> b) {
-    if (a.length != b.length) {
-      return false;
-    }
-    for (int i = 0; i < a.length; i++) {
-      if (a[i].lintCode != b[i].lintCode) {
-        return false;
-      }
-    }
-    return true;
-  }
-
   /// Predicate used for [analyzeFunctionBodiesPredicate] when
   /// [analyzeFunctionBodies] is set to `true`.
   @deprecated
diff --git a/pkg/analyzer/lib/src/generated/error_verifier.dart b/pkg/analyzer/lib/src/generated/error_verifier.dart
index e2567c4..40b26f2 100644
--- a/pkg/analyzer/lib/src/generated/error_verifier.dart
+++ b/pkg/analyzer/lib/src/generated/error_verifier.dart
@@ -40,6 +40,7 @@
 import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
 import 'package:analyzer/src/generated/sdk.dart' show DartSdk, SdkLibrary;
 import 'package:analyzer/src/task/strong/checker.dart';
+import 'package:meta/meta.dart';
 
 class EnclosingExecutableContext {
   final ExecutableElement element;
@@ -48,7 +49,7 @@
   final bool isFactoryConstructor;
   final bool isGenerativeConstructor;
   final bool isGenerator;
-  final bool isStaticMethod;
+  final bool inStaticMethod;
 
   /// The return statements that have a value.
   final List<ReturnStatement> _returnsWith = [];
@@ -68,7 +69,7 @@
         isGenerativeConstructor =
             element is ConstructorElement && !element.isFactory,
         isGenerator = element != null && element.isGenerator,
-        isStaticMethod = _isStaticMethod(element);
+        inStaticMethod = _inStaticMethod(element);
 
   EnclosingExecutableContext.empty() : this(null);
 
@@ -104,11 +105,14 @@
 
   DartType get returnType => element.returnType;
 
-  static bool _isStaticMethod(ExecutableElement element) {
+  static bool _inStaticMethod(ExecutableElement element) {
     var enclosing = element?.enclosingElement;
     if (enclosing is ClassElement || enclosing is ExtensionElement) {
       return element.isStatic;
     }
+    if (enclosing is ExecutableElement) {
+      return _inStaticMethod(enclosing);
+    }
     return false;
   }
 }
@@ -195,16 +199,6 @@
   EnclosingExecutableContext _enclosingExecutable =
       EnclosingExecutableContext.empty();
 
-  /// A table mapping name of the library to the export directive which export
-  /// this library.
-  final Map<String, LibraryElement> _nameToExportElement =
-      HashMap<String, LibraryElement>();
-
-  /// A table mapping name of the library to the import directive which import
-  /// this library.
-  final Map<String, LibraryElement> _nameToImportElement =
-      HashMap<String, LibraryElement>();
-
   /// A table mapping names to the exported elements.
   final Map<String, Element> _exportedElements = HashMap<String, Element>();
 
@@ -546,7 +540,6 @@
     if (exportElement != null) {
       LibraryElement exportedLibrary = exportElement.exportedLibrary;
       _checkForAmbiguousExport(node, exportElement, exportedLibrary);
-      _checkForExportDuplicateLibraryName(node, exportElement, exportedLibrary);
       _checkForExportInternalLibrary(node, exportElement);
       _checkForExportLegacySymbol(node);
     }
@@ -787,7 +780,6 @@
           node.prefix, CompileTimeErrorCode.BUILT_IN_IDENTIFIER_AS_PREFIX_NAME);
     }
     if (importElement != null) {
-      _checkForImportDuplicateLibraryName(node, importElement);
       _checkForImportInternalLibrary(node, importElement);
       if (importElement.isDeferred) {
         _checkForDeferredImportOfExtensions(node, importElement);
@@ -798,7 +790,22 @@
 
   @override
   void visitIndexExpression(IndexExpression node) {
-    _checkForArgumentTypeNotAssignableForArgument(node.index);
+    void checkIndexExpression(MethodElement method) {
+      if (method != null) {
+        var parameters = method.parameters;
+        if (parameters.isNotEmpty) {
+          _checkForArgumentTypeNotAssignableForArgument2(
+            argument: node.index,
+            parameter: parameters[0],
+            promoteParameterToNullable: false,
+          );
+        }
+      }
+    }
+
+    checkIndexExpression(node.staticElement);
+    checkIndexExpression(node.auxiliaryElements?.staticElement);
+
     if (node.isNullAware) {
       var target = node.realTarget;
       if (_isExpressionWithType(target)) {
@@ -1248,6 +1255,7 @@
       _checkForRepeatedType(implementsClause?.interfaces,
           CompileTimeErrorCode.IMPLEMENTS_REPEATED);
       _checkImplementsSuperClass(implementsClause);
+      _checkMixinsSuperClass(withClause);
       _checkMixinInference(node, withClause);
       _checkForMixinWithConflictingPrivateMember(withClause, superclass);
       _checkForConflictingGenerics(node);
@@ -1453,12 +1461,24 @@
   /// See [StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE].
   void _checkForArgumentTypeNotAssignableForArgument(Expression argument,
       {bool promoteParameterToNullable = false}) {
+    // TODO(scheglov) probably cannot happen
     if (argument == null) {
       return;
     }
 
-    ParameterElement staticParameterElement = argument.staticParameterElement;
-    DartType staticParameterType = staticParameterElement?.type;
+    _checkForArgumentTypeNotAssignableForArgument2(
+      argument: argument,
+      parameter: argument.staticParameterElement,
+      promoteParameterToNullable: promoteParameterToNullable,
+    );
+  }
+
+  void _checkForArgumentTypeNotAssignableForArgument2({
+    @required Expression argument,
+    @required ParameterElement parameter,
+    @required bool promoteParameterToNullable,
+  }) {
+    DartType staticParameterType = parameter?.type;
     if (promoteParameterToNullable && staticParameterType != null) {
       staticParameterType = _typeSystem.makeNullable(staticParameterType);
     }
@@ -2228,7 +2248,7 @@
     }
 
     DartType sequenceElementType;
-    if (iterableType is InterfaceTypeImpl) {
+    {
       var sequenceElement = awaitKeyword != null
           ? _typeProvider.streamElement
           : _typeProvider.iterableElement;
@@ -2253,38 +2273,6 @@
     return true;
   }
 
-  /// Verify that the given export [directive] has a unique name among other
-  /// exported libraries. The [exportElement] is the [ExportElement] retrieved
-  /// from the node, if the element in the node was `null`, then this method is
-  /// not called. The [exportedLibrary] is the library element containing the
-  /// exported element.
-  ///
-  /// See [CompileTimeErrorCode.EXPORT_DUPLICATED_LIBRARY_NAME].
-  void _checkForExportDuplicateLibraryName(ExportDirective directive,
-      ExportElement exportElement, LibraryElement exportedLibrary) {
-    if (exportedLibrary == null) {
-      return;
-    }
-    String name = exportedLibrary.name;
-    // check if there is other exported library with the same name
-    LibraryElement prevLibrary = _nameToExportElement[name];
-    if (prevLibrary != null) {
-      if (prevLibrary != exportedLibrary) {
-        if (name.isNotEmpty) {
-          _errorReporter.reportErrorForNode(
-              StaticWarningCode.EXPORT_DUPLICATED_LIBRARY_NAMED, directive, [
-            prevLibrary.definingCompilationUnit.source.uri.toString(),
-            exportedLibrary.definingCompilationUnit.source.uri.toString(),
-            name
-          ]);
-        }
-        return;
-      }
-    } else {
-      _nameToExportElement[name] = exportedLibrary;
-    }
-  }
-
   /// Check that if the visiting library is not system, then any given library
   /// should not be SDK internal library. The [exportElement] is the
   /// [ExportElement] retrieved from the node, if the element in the node was
@@ -2684,7 +2672,7 @@
       return;
     }
     if (!_isInConstructorInitializer &&
-        !_enclosingExecutable.isStaticMethod &&
+        !_enclosingExecutable.inStaticMethod &&
         !_enclosingExecutable.isFactoryConstructor &&
         !_isInInstanceNotLateVariableDeclaration &&
         !_isInStaticVariableDeclaration) {
@@ -2727,7 +2715,8 @@
       }
     }
 
-    if (_enclosingExecutable.isStaticMethod) {
+    if (_enclosingExecutable.inStaticMethod) {
+      // TODO
       _errorReporter.reportErrorForNode(
           CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_STATIC, identifier);
     } else if (_enclosingExecutable.isFactoryConstructor) {
@@ -2741,36 +2730,6 @@
     }
   }
 
-  /// Verify that the given import [directive] has a unique name among other
-  /// imported libraries. The [importElement] is the [ImportElement] retrieved
-  /// from the node, if the element in the node was `null`, then this method is
-  /// not called.
-  ///
-  /// See [CompileTimeErrorCode.IMPORT_DUPLICATED_LIBRARY_NAME].
-  void _checkForImportDuplicateLibraryName(
-      ImportDirective directive, ImportElement importElement) {
-    // prepare imported library
-    LibraryElement nodeLibrary = importElement.importedLibrary;
-    if (nodeLibrary == null) {
-      return;
-    }
-    String name = nodeLibrary.name;
-    // check if there is another imported library with the same name
-    LibraryElement prevLibrary = _nameToImportElement[name];
-    if (prevLibrary != null) {
-      if (prevLibrary != nodeLibrary && name.isNotEmpty) {
-        _errorReporter.reportErrorForNode(
-            StaticWarningCode.IMPORT_DUPLICATED_LIBRARY_NAMED, directive, [
-          prevLibrary.definingCompilationUnit.source.uri,
-          nodeLibrary.definingCompilationUnit.source.uri,
-          name
-        ]);
-      }
-    } else {
-      _nameToImportElement[name] = nodeLibrary;
-    }
-  }
-
   /// Check that if the visiting library is not system, then any given library
   /// should not be SDK internal library. The [importElement] is the
   /// [ImportElement] retrieved from the node, if the element in the node was
@@ -4124,7 +4083,7 @@
   }
 
   void _checkForTypeParameterReferencedByStatic(SimpleIdentifier identifier) {
-    if (_enclosingExecutable.isStaticMethod || _isInStaticVariableDeclaration) {
+    if (_enclosingExecutable.inStaticMethod || _isInStaticVariableDeclaration) {
       var element = identifier.staticElement;
       if (element is TypeParameterElement &&
           element.enclosingElement is ClassElement) {
@@ -4223,9 +4182,6 @@
     } else if (operator.type == TokenType.QUESTION_PERIOD_PERIOD) {
       errorCode = StaticWarningCode.INVALID_NULL_AWARE_OPERATOR;
       arguments = [operator.lexeme, '..'];
-    } else if (operator.type == TokenType.QUESTION_PERIOD_OPEN_SQUARE_BRACKET) {
-      errorCode = StaticWarningCode.INVALID_NULL_AWARE_OPERATOR;
-      arguments = [operator.lexeme, '['];
     } else if (operator.type == TokenType.PERIOD_PERIOD_PERIOD_QUESTION) {
       errorCode = StaticWarningCode.INVALID_NULL_AWARE_OPERATOR;
       arguments = [operator.lexeme, '...'];
@@ -4235,7 +4191,54 @@
       return;
     }
 
+    /// If the operator is not valid because the target already makes use of a
+    /// null aware operator, return the null aware operator from the target.
+    Token previousShortCircuitingOperator(Expression target) {
+      if (target is PropertyAccess) {
+        var operator = target.operator;
+        var type = operator.type;
+        if (type == TokenType.QUESTION_PERIOD) {
+          var realTarget = target.realTarget;
+          if (_isExpressionWithType(realTarget)) {
+            return previousShortCircuitingOperator(realTarget) ?? operator;
+          }
+        }
+      } else if (target is IndexExpression) {
+        if (target.question != null) {
+          var realTarget = target.realTarget;
+          if (_isExpressionWithType(realTarget)) {
+            return previousShortCircuitingOperator(realTarget) ??
+                target.question;
+          }
+        }
+      } else if (target is MethodInvocation) {
+        var operator = target.operator;
+        var type = operator?.type;
+        if (type == TokenType.QUESTION_PERIOD) {
+          var realTarget = target.realTarget;
+          if (_isExpressionWithType(realTarget)) {
+            return previousShortCircuitingOperator(realTarget) ?? operator;
+          }
+          return operator;
+        }
+      }
+      return null;
+    }
+
     if (_typeSystem.isStrictlyNonNullable(target.staticType)) {
+      if (errorCode == StaticWarningCode.INVALID_NULL_AWARE_OPERATOR) {
+        var previousOperator = previousShortCircuitingOperator(target);
+        if (previousOperator != null) {
+          _errorReporter.reportError(DiagnosticFactory()
+              .invalidNullAwareAfterShortCircuit(
+                  _errorReporter.source,
+                  operator.offset,
+                  endToken.end - operator.offset,
+                  arguments,
+                  previousOperator));
+          return;
+        }
+      }
       _errorReporter.reportErrorForOffset(
         errorCode,
         operator.offset,
@@ -4626,27 +4629,27 @@
     }
   }
 
-  /// Verify that the given class [declaration] does not have the same class in
-  /// the 'extends' and 'implements' clauses.
+  /// Verify that the current class does not have the same class in the
+  /// 'extends' and 'implements' clauses.
   ///
   /// See [CompileTimeErrorCode.IMPLEMENTS_SUPER_CLASS].
   void _checkImplementsSuperClass(ImplementsClause implementsClause) {
-    // prepare super type
-    InterfaceType superType = _enclosingClass.supertype;
-    if (superType == null) {
-      return;
-    }
-    // prepare interfaces
     if (implementsClause == null) {
       return;
     }
-    // check interfaces
-    for (TypeName interfaceNode in implementsClause.interfaces) {
-      if (interfaceNode.type == superType) {
+
+    var superElement = _enclosingClass.supertype?.element;
+    if (superElement == null) {
+      return;
+    }
+
+    for (var interfaceNode in implementsClause.interfaces) {
+      if (interfaceNode.type.element == superElement) {
         _errorReporter.reportErrorForNode(
-            CompileTimeErrorCode.IMPLEMENTS_SUPER_CLASS,
-            interfaceNode,
-            [superType]);
+          CompileTimeErrorCode.IMPLEMENTS_SUPER_CLASS,
+          interfaceNode,
+          [superElement],
+        );
       }
     }
   }
@@ -4720,6 +4723,31 @@
     }
   }
 
+  /// Verify that the current class does not have the same class in the
+  /// 'extends' and 'with' clauses.
+  ///
+  /// See [CompileTimeErrorCode.IMPLEMENTS_SUPER_CLASS].
+  void _checkMixinsSuperClass(WithClause withClause) {
+    if (withClause == null) {
+      return;
+    }
+
+    var superElement = _enclosingClass.supertype?.element;
+    if (superElement == null) {
+      return;
+    }
+
+    for (var mixinNode in withClause.mixinTypes) {
+      if (mixinNode.type.element == superElement) {
+        _errorReporter.reportErrorForNode(
+          CompileTimeErrorCode.MIXINS_SUPER_CLASS,
+          mixinNode,
+          [superElement],
+        );
+      }
+    }
+  }
+
   void _checkUseOfCovariantInParameters(FormalParameterList node) {
     AstNode parent = node.parent;
     if (_enclosingClass != null &&
@@ -5232,7 +5260,7 @@
   _UninstantiatedBoundChecker(this._errorReporter);
 
   @override
-  void visitTypeName(node) {
+  void visitTypeName(TypeName node) {
     var typeArgs = node.typeArguments;
     if (typeArgs != null) {
       typeArgs.accept(this);
@@ -5241,8 +5269,10 @@
 
     var element = node.name.staticElement;
     if (element is TypeParameterizedElement && !element.isSimplyBounded) {
-      _errorReporter
-          .reportErrorForNode(StrongModeCode.NOT_INSTANTIATED_BOUND, node, []);
+      // TODO(srawlins): Don't report this if TYPE_ALIAS_CANNOT_REFERENCE_ITSELF
+      //  has been reported.
+      _errorReporter.reportErrorForNode(
+          CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, node, []);
     }
   }
 }
diff --git a/pkg/analyzer/lib/src/generated/incremental_resolver.dart b/pkg/analyzer/lib/src/generated/incremental_resolver.dart
deleted file mode 100644
index c9b2b7e..0000000
--- a/pkg/analyzer/lib/src/generated/incremental_resolver.dart
+++ /dev/null
@@ -1,147 +0,0 @@
-// Copyright (c) 2014, 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 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer/exception/exception.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
-
-/// The context to resolve an [AstNode] in.
-class ResolutionContext {
-  CompilationUnitElement enclosingUnit;
-  ClassDeclaration enclosingClassDeclaration;
-  ClassElement enclosingClass;
-  Scope scope;
-}
-
-/// Instances of the class [ResolutionContextBuilder] build the context for a
-/// given node in an AST structure. At the moment, this class only handles
-/// top-level and class-level declarations.
-class ResolutionContextBuilder {
-  /// The class containing the enclosing [CompilationUnitElement].
-  CompilationUnitElement _enclosingUnit;
-
-  /// The class containing the enclosing [ClassDeclaration], or `null` if we are
-  /// not in the scope of a class.
-  ClassDeclaration _enclosingClassDeclaration;
-
-  /// The class containing the enclosing [ClassElement], or `null` if we are not
-  /// in the scope of a class.
-  ClassElement _enclosingClass;
-
-  Scope _scopeFor(AstNode node) {
-    if (node is CompilationUnit) {
-      return _scopeForAstNode(node);
-    }
-    AstNode parent = node.parent;
-    if (parent == null) {
-      throw AnalysisException(
-          "Cannot create scope: node is not part of a CompilationUnit");
-    }
-    return _scopeForAstNode(parent);
-  }
-
-  /// Return the scope in which the given AST structure should be resolved.
-  ///
-  /// *Note:* This method needs to be kept in sync with
-  /// [IncrementalResolver.canBeResolved].
-  ///
-  /// [node] - the root of the AST structure to be resolved.
-  ///
-  /// Throws [AnalysisException] if the AST structure has not been resolved or
-  /// is not part of a [CompilationUnit]
-  Scope _scopeForAstNode(AstNode node) {
-    if (node is CompilationUnit) {
-      return _scopeForCompilationUnit(node);
-    }
-    AstNode parent = node.parent;
-    if (parent == null) {
-      throw AnalysisException(
-          "Cannot create scope: node is not part of a CompilationUnit");
-    }
-    Scope scope = _scopeForAstNode(parent);
-    if (node is ClassDeclaration) {
-      _enclosingClassDeclaration = node;
-      _enclosingClass = node.declaredElement;
-      if (_enclosingClass == null) {
-        throw AnalysisException("Cannot build a scope for an unresolved class");
-      }
-      scope = ClassScope(
-          TypeParameterScope(scope, _enclosingClass), _enclosingClass);
-    } else if (node is ClassTypeAlias) {
-      ClassElement element = node.declaredElement;
-      if (element == null) {
-        throw AnalysisException(
-            "Cannot build a scope for an unresolved class type alias");
-      }
-      scope = ClassScope(TypeParameterScope(scope, element), element);
-    } else if (node is ConstructorDeclaration) {
-      ConstructorElement element = node.declaredElement;
-      if (element == null) {
-        throw AnalysisException(
-            "Cannot build a scope for an unresolved constructor");
-      }
-      FunctionScope functionScope = FunctionScope(scope, element);
-      functionScope.defineParameters();
-      scope = functionScope;
-    } else if (node is FunctionDeclaration) {
-      ExecutableElement element = node.declaredElement;
-      if (element == null) {
-        throw AnalysisException(
-            "Cannot build a scope for an unresolved function");
-      }
-      FunctionScope functionScope = FunctionScope(scope, element);
-      functionScope.defineParameters();
-      scope = functionScope;
-    } else if (node is FunctionTypeAlias) {
-      scope = FunctionTypeScope(scope, node.declaredElement);
-    } else if (node is MethodDeclaration) {
-      ExecutableElement element = node.declaredElement;
-      if (element == null) {
-        throw AnalysisException(
-            "Cannot build a scope for an unresolved method");
-      }
-      FunctionScope functionScope = FunctionScope(scope, element);
-      functionScope.defineParameters();
-      scope = functionScope;
-    }
-    return scope;
-  }
-
-  Scope _scopeForCompilationUnit(CompilationUnit node) {
-    _enclosingUnit = node.declaredElement;
-    if (_enclosingUnit == null) {
-      throw AnalysisException(
-          "Cannot create scope: compilation unit is not resolved");
-    }
-    LibraryElement libraryElement = _enclosingUnit.library;
-    if (libraryElement == null) {
-      throw AnalysisException(
-          "Cannot create scope: compilation unit is not part of a library");
-    }
-    return LibraryScope(libraryElement);
-  }
-
-  /// Return the context in which the given AST structure should be resolved.
-  ///
-  /// [node] - the root of the AST structure to be resolved.
-  ///
-  /// Throws [AnalysisException] if the AST structure has not been resolved or
-  /// is not part of a [CompilationUnit]
-  static ResolutionContext contextFor(AstNode node) {
-    if (node == null) {
-      throw AnalysisException("Cannot create context: node is null");
-    }
-    // build scope
-    ResolutionContextBuilder builder = ResolutionContextBuilder();
-    Scope scope = builder._scopeFor(node);
-    // prepare context
-    ResolutionContext context = ResolutionContext();
-    context.scope = scope;
-    context.enclosingUnit = builder._enclosingUnit;
-    context.enclosingClassDeclaration = builder._enclosingClassDeclaration;
-    context.enclosingClass = builder._enclosingClass;
-    return context;
-  }
-}
diff --git a/pkg/analyzer/lib/src/generated/java_core.dart b/pkg/analyzer/lib/src/generated/java_core.dart
index 800d03f..0cd4eb0 100644
--- a/pkg/analyzer/lib/src/generated/java_core.dart
+++ b/pkg/analyzer/lib/src/generated/java_core.dart
@@ -8,7 +8,14 @@
 ///     format('{0} are you {1}ing?', 'How', 'do') = 'How are you doing?'
 ///     format('{0} are you {1}ing?', 'What', 'read') = 'What are you reading?'
 String format(String pattern,
-    [arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7]) {
+    [Object arg0,
+    Object arg1,
+    Object arg2,
+    Object arg3,
+    Object arg4,
+    Object arg5,
+    Object arg6,
+    Object arg7]) {
   // TODO(rnystrom): This is not used by analyzer, but is called by
   // analysis_server. Move this code there and remove it from here.
   return formatList(pattern, [arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7]);
@@ -144,7 +151,7 @@
   final StringBuffer _sb = StringBuffer();
 
   @override
-  void print(x) {
+  void print(Object x) {
     _sb.write(x);
   }
 
@@ -157,7 +164,7 @@
     this.print('\n');
   }
 
-  void print(x);
+  void print(Object x);
 
   void printf(String fmt, List args) {
     this.print(_printf(fmt, args));
diff --git a/pkg/analyzer/lib/src/generated/java_io.dart b/pkg/analyzer/lib/src/generated/java_io.dart
index 4773d79..eb94d99 100644
--- a/pkg/analyzer/lib/src/generated/java_io.dart
+++ b/pkg/analyzer/lib/src/generated/java_io.dart
@@ -26,7 +26,7 @@
   @override
   int get hashCode => _path.hashCode;
   @override
-  bool operator ==(other) {
+  bool operator ==(Object other) {
     return other is JavaFile && other._path == _path;
   }
 
diff --git a/pkg/analyzer/lib/src/generated/resolver.dart b/pkg/analyzer/lib/src/generated/resolver.dart
index 79bdfac..9070ccd 100644
--- a/pkg/analyzer/lib/src/generated/resolver.dart
+++ b/pkg/analyzer/lib/src/generated/resolver.dart
@@ -9,17 +9,18 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/error/listener.dart';
-import 'package:analyzer/exception/exception.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/element/member.dart'
     show ConstructorMember, Member;
 import 'package:analyzer/src/dart/element/nullability_eliminator.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/dart/resolver/assignment_expression_resolver.dart';
@@ -44,7 +45,6 @@
 import 'package:analyzer/src/error/nullable_dereference_verifier.dart';
 import 'package:analyzer/src/generated/constant.dart';
 import 'package:analyzer/src/generated/element_resolver.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/migratable_ast_info_provider.dart';
 import 'package:analyzer/src/generated/migration.dart';
 import 'package:analyzer/src/generated/source.dart';
@@ -259,7 +259,7 @@
       AnalysisErrorListener errorListener,
       {FeatureSet featureSet,
       Scope nameScope,
-      reportConstEvaluationErrors = true,
+      bool reportConstEvaluationErrors = true,
       FlowAnalysisHelper flowAnalysisHelper})
       : this._(
             inheritanceManager,
@@ -285,7 +285,7 @@
       AnalysisErrorListener errorListener,
       FeatureSet featureSet,
       Scope nameScope,
-      reportConstEvaluationErrors,
+      bool reportConstEvaluationErrors,
       this._flowAnalysis,
       this._migratableAstInfoProvider,
       MigrationResolutionHooks migrationResolutionHooks)
@@ -731,10 +731,44 @@
     AstNode parent = node.parent;
     if (parent is FunctionDeclaration ||
         parent is FunctionTypeAlias ||
-        parent is ConstructorDeclaration ||
-        parent is MethodDeclaration) {
+        parent is ConstructorDeclaration) {
       return;
     }
+
+    // TODO(scheglov) Change corresponding visiting places to visit comments
+    // with name scopes set for correct comments resolution.
+    if (parent is GenericTypeAlias) {
+      var element = parent.declaredElement as GenericTypeAliasElement;
+      var outerScope = nameScope;
+      try {
+        nameScope = TypeParameterScope(nameScope, element.typeParameters);
+
+        var functionElement = element.function;
+        if (functionElement != null) {
+          nameScope = FormalParameterScope(
+            TypeParameterScope(nameScope, functionElement.typeParameters),
+            functionElement.parameters,
+          );
+        }
+
+        super.visitComment(node);
+        return;
+      } finally {
+        nameScope = outerScope;
+      }
+    } else if (parent is MethodDeclaration) {
+      var outerScope = nameScope;
+      try {
+        var element = parent.declaredElement;
+        nameScope = FormalParameterScope(nameScope, element.parameters);
+
+        super.visitComment(node);
+        return;
+      } finally {
+        nameScope = outerScope;
+      }
+    }
+
     super.visitComment(node);
   }
 
@@ -1122,8 +1156,11 @@
     } else {
       Scope outerScope = nameScope;
       try {
-        ExecutableElement functionElement = node.declaredElement;
-        nameScope = FunctionScope(nameScope, functionElement);
+        ExecutableElement element = node.declaredElement;
+        nameScope = FormalParameterScope(
+          TypeParameterScope(nameScope, element.typeParameters),
+          element.parameters,
+        );
         _functionExpressionResolver.resolve(node);
       } finally {
         nameScope = outerScope;
@@ -1337,12 +1374,6 @@
   }
 
   @override
-  void visitMethodDeclarationInScope(MethodDeclaration node) {
-    super.visitMethodDeclarationInScope(node);
-    safelyVisitComment(node.documentationComment);
-  }
-
-  @override
   void visitMethodInvocation(MethodInvocation node) {
     node.target?.accept(this);
 
@@ -2108,7 +2139,7 @@
   ///
   /// @return the enclosing [Scope].
   Scope popNameScope() {
-    nameScope = nameScope.enclosingScope;
+    nameScope = (nameScope as EnclosedScope).parent;
     return nameScope;
   }
 
@@ -2116,7 +2147,7 @@
   ///
   /// @return the new [Scope].
   Scope pushNameScope() {
-    Scope newScope = EnclosedScope(nameScope);
+    Scope newScope = LocalScope(nameScope);
     nameScope = newScope;
     return nameScope;
   }
@@ -2125,7 +2156,8 @@
   void visitBlock(Block node) {
     Scope outerScope = nameScope;
     try {
-      EnclosedScope enclosedScope = BlockScope(nameScope, node);
+      var enclosedScope = LocalScope(nameScope);
+      BlockScope.elementsInBlock(node).forEach(enclosedScope.add);
       nameScope = enclosedScope;
       _setNodeNameScope(node, nameScope);
       super.visitBlock(node);
@@ -2151,11 +2183,11 @@
     if (exception != null) {
       Scope outerScope = nameScope;
       try {
-        nameScope = EnclosedScope(nameScope);
-        nameScope.define(exception.staticElement);
+        nameScope = LocalScope(nameScope);
+        _define(exception.staticElement);
         SimpleIdentifier stackTrace = node.stackTraceParameter;
         if (stackTrace != null) {
-          nameScope.define(stackTrace.staticElement);
+          _define(stackTrace.staticElement);
         }
         super.visitCatchClause(node);
       } finally {
@@ -2168,28 +2200,22 @@
 
   @override
   void visitClassDeclaration(ClassDeclaration node) {
-    ClassElement classElement = node.declaredElement;
     Scope outerScope = nameScope;
+    ClassElement outerClass = enclosingClass;
     try {
-      if (classElement == null) {
-        AnalysisEngine.instance.instrumentationService.logInfo(
-            "Missing element for class declaration ${node.name.name} in "
-            "${definingLibrary.source.fullName}",
-            CaughtException(AnalysisException(), null));
-        super.visitClassDeclaration(node);
-      } else {
-        ClassElement outerClass = enclosingClass;
-        try {
-          enclosingClass = node.declaredElement;
-          nameScope = TypeParameterScope(nameScope, classElement);
-          visitClassDeclarationInScope(node);
-          nameScope = ClassScope(nameScope, classElement);
-          visitClassMembersInScope(node);
-        } finally {
-          enclosingClass = outerClass;
-        }
-      }
+      ClassElement element = node.declaredElement;
+      enclosingClass = node.declaredElement;
+
+      nameScope = TypeParameterScope(
+        nameScope,
+        element.typeParameters,
+      );
+      visitClassDeclarationInScope(node);
+
+      nameScope = ClassScope(nameScope, element);
+      visitClassMembersInScope(node);
     } finally {
+      enclosingClass = outerClass;
       nameScope = outerScope;
     }
   }
@@ -2214,7 +2240,10 @@
     Scope outerScope = nameScope;
     try {
       ClassElement element = node.declaredElement;
-      nameScope = ClassScope(TypeParameterScope(nameScope, element), element);
+      nameScope = ClassScope(
+        TypeParameterScope(nameScope, element.typeParameters),
+        element,
+      );
       super.visitClassTypeAlias(node);
     } finally {
       nameScope = outerScope;
@@ -2229,40 +2258,32 @@
 
   @override
   void visitConstructorDeclaration(ConstructorDeclaration node) {
-    ConstructorElement constructorElement = node.declaredElement;
-    if (constructorElement == null) {
-      StringBuffer buffer = StringBuffer();
-      buffer.write("Missing element for constructor ");
-      buffer.write(node.returnType.name);
-      if (node.name != null) {
-        buffer.write(".");
-        buffer.write(node.name.name);
-      }
-      buffer.write(" in ");
-      buffer.write(definingLibrary.source.fullName);
-      AnalysisEngine.instance.instrumentationService.logInfo(buffer.toString());
-    }
     Scope outerScope = nameScope;
     try {
-      if (constructorElement != null) {
-        nameScope = FunctionScope(nameScope, constructorElement);
-      }
+      ConstructorElement element = node.declaredElement;
+
       node.documentationComment?.accept(this);
       node.metadata.accept(this);
       node.returnType?.accept(this);
       node.name?.accept(this);
       node.parameters?.accept(this);
-      Scope functionScope = nameScope;
+
       try {
-        if (constructorElement != null) {
-          nameScope =
-              ConstructorInitializerScope(nameScope, constructorElement);
-        }
+        nameScope = ConstructorInitializerScope(
+          nameScope,
+          element,
+        );
         node.initializers.accept(this);
       } finally {
-        nameScope = functionScope;
+        nameScope = outerScope;
       }
+
       node.redirectedConstructor?.accept(this);
+
+      nameScope = FormalParameterScope(
+        nameScope,
+        element.parameters,
+      );
       visitConstructorDeclarationInScope(node);
     } finally {
       nameScope = outerScope;
@@ -2276,8 +2297,9 @@
   @override
   void visitDeclaredIdentifier(DeclaredIdentifier node) {
     VariableElement element = node.declaredElement;
+    // TODO(scheglov) Do we need this?
     if (element != null) {
-      nameScope.define(element);
+      _define(element);
     }
     super.visitDeclaredIdentifier(node);
   }
@@ -2300,25 +2322,16 @@
 
   @override
   void visitEnumDeclaration(EnumDeclaration node) {
-    ClassElement classElement = node.declaredElement;
     Scope outerScope = nameScope;
+    ClassElement outerClass = enclosingClass;
     try {
-      if (classElement == null) {
-        AnalysisEngine.instance.instrumentationService.logInfo(
-            "Missing element for enum declaration ${node.name.name} in "
-            "${definingLibrary.source.fullName}");
-        super.visitEnumDeclaration(node);
-      } else {
-        ClassElement outerClass = enclosingClass;
-        try {
-          enclosingClass = node.declaredElement;
-          nameScope = ClassScope(nameScope, classElement);
-          visitEnumMembersInScope(node);
-        } finally {
-          enclosingClass = outerClass;
-        }
-      }
+      ClassElement element = node.declaredElement;
+      enclosingClass = node.declaredElement;
+
+      nameScope = ClassScope(nameScope, element);
+      visitEnumMembersInScope(node);
     } finally {
+      enclosingClass = outerClass;
       nameScope = outerScope;
     }
   }
@@ -2337,27 +2350,22 @@
 
   @override
   void visitExtensionDeclaration(ExtensionDeclaration node) {
-    ExtensionElement extensionElement = node.declaredElement;
     Scope outerScope = nameScope;
+    ExtensionElement outerExtension = enclosingExtension;
     try {
-      if (extensionElement == null) {
-        AnalysisEngine.instance.instrumentationService.logInfo(
-            "Missing element for extension declaration ${node.name.name} "
-            "in ${definingLibrary.source.fullName}");
-        super.visitExtensionDeclaration(node);
-      } else {
-        ExtensionElement outerExtension = enclosingExtension;
-        try {
-          enclosingExtension = extensionElement;
-          nameScope = TypeParameterScope(nameScope, extensionElement);
-          visitExtensionDeclarationInScope(node);
-          nameScope = ExtensionScope(nameScope, extensionElement);
-          visitExtensionMembersInScope(node);
-        } finally {
-          enclosingExtension = outerExtension;
-        }
-      }
+      ExtensionElement element = node.declaredElement;
+      enclosingExtension = element;
+
+      nameScope = TypeParameterScope(
+        nameScope,
+        element.typeParameters,
+      );
+      visitExtensionDeclarationInScope(node);
+
+      nameScope = ExtensionScope(nameScope, element);
+      visitExtensionMembersInScope(node);
     } finally {
+      enclosingExtension = outerExtension;
       nameScope = outerScope;
     }
   }
@@ -2388,7 +2396,7 @@
   void visitForElement(ForElement node) {
     Scope outerNameScope = nameScope;
     try {
-      nameScope = EnclosedScope(nameScope);
+      nameScope = LocalScope(nameScope);
       _setNodeNameScope(node, nameScope);
       visitForElementInScope(node);
     } finally {
@@ -2413,12 +2421,22 @@
     // scope.  Note: we must not do this if the parent is a
     // FunctionTypedFormalParameter, because in that case we aren't finished
     // resolving the full function signature, just a part of it.
-    if (nameScope is FunctionScope &&
-        node.parent is! FunctionTypedFormalParameter) {
-      (nameScope as FunctionScope).defineParameters();
-    }
-    if (nameScope is FunctionTypeScope) {
-      (nameScope as FunctionTypeScope).defineParameters();
+    var parent = node.parent;
+    if (parent is FunctionExpression) {
+      nameScope = FormalParameterScope(
+        nameScope,
+        parent.declaredElement.parameters,
+      );
+    } else if (parent is FunctionTypeAlias) {
+      nameScope = FormalParameterScope(
+        nameScope,
+        parent.declaredElement.parameters,
+      );
+    } else if (parent is MethodDeclaration) {
+      nameScope = FormalParameterScope(
+        nameScope,
+        parent.declaredElement.parameters,
+      );
     }
   }
 
@@ -2427,7 +2445,7 @@
     Scope outerNameScope = nameScope;
     ImplicitLabelScope outerImplicitScope = _implicitLabelScope;
     try {
-      nameScope = EnclosedScope(nameScope);
+      nameScope = LocalScope(nameScope);
       _implicitLabelScope = _implicitLabelScope.nest(node);
       _setNodeNameScope(node, nameScope);
       visitForStatementInScope(node);
@@ -2449,20 +2467,19 @@
 
   @override
   void visitFunctionDeclaration(FunctionDeclaration node) {
-    ExecutableElement functionElement = node.declaredElement;
-    if (functionElement != null &&
-        functionElement.enclosingElement is! CompilationUnitElement) {
-      nameScope.define(functionElement);
+    ExecutableElement element = node.declaredElement;
+    // TODO(scheglov) Do we need this?
+    if (element != null &&
+        element.enclosingElement is! CompilationUnitElement) {
+      _define(element);
     }
+
     Scope outerScope = nameScope;
     try {
-      if (functionElement == null) {
-        AnalysisEngine.instance.instrumentationService.logInfo(
-            "Missing element for top-level function ${node.name.name} in "
-            "${definingLibrary.source.fullName}");
-      } else {
-        nameScope = FunctionScope(nameScope, functionElement);
-      }
+      nameScope = TypeParameterScope(
+        nameScope,
+        element.typeParameters,
+      );
       visitFunctionDeclarationInScope(node);
     } finally {
       nameScope = outerScope;
@@ -2478,34 +2495,19 @@
     if (node.parent is FunctionDeclaration) {
       // We have already created a function scope and don't need to do so again.
       super.visitFunctionExpression(node);
-    } else {
-      Scope outerScope = nameScope;
-      try {
-        ExecutableElement functionElement = node.declaredElement;
-        if (functionElement == null) {
-          StringBuffer buffer = StringBuffer();
-          buffer.write("Missing element for function ");
-          AstNode parent = node.parent;
-          while (parent != null) {
-            if (parent is Declaration) {
-              Element parentElement = parent.declaredElement;
-              buffer.write(parentElement == null
-                  ? "<unknown> "
-                  : "${parentElement.name} ");
-            }
-            parent = parent.parent;
-          }
-          buffer.write("in ");
-          buffer.write(definingLibrary.source.fullName);
-          AnalysisEngine.instance.instrumentationService
-              .logInfo(buffer.toString());
-        } else {
-          nameScope = FunctionScope(nameScope, functionElement);
-        }
-        super.visitFunctionExpression(node);
-      } finally {
-        nameScope = outerScope;
-      }
+      return;
+    }
+
+    Scope outerScope = nameScope;
+    try {
+      ExecutableElement element = node.declaredElement;
+      nameScope = FormalParameterScope(
+        TypeParameterScope(nameScope, element.typeParameters),
+        element.parameters,
+      );
+      super.visitFunctionExpression(node);
+    } finally {
+      nameScope = outerScope;
     }
   }
 
@@ -2513,7 +2515,8 @@
   void visitFunctionTypeAlias(FunctionTypeAlias node) {
     Scope outerScope = nameScope;
     try {
-      nameScope = FunctionTypeScope(nameScope, node.declaredElement);
+      var element = node.declaredElement;
+      nameScope = TypeParameterScope(nameScope, element.typeParameters);
       visitFunctionTypeAliasInScope(node);
     } finally {
       nameScope = outerScope;
@@ -2528,19 +2531,11 @@
   void visitFunctionTypedFormalParameter(FunctionTypedFormalParameter node) {
     Scope outerScope = nameScope;
     try {
-      ParameterElement parameterElement = node.declaredElement;
-      if (parameterElement == null) {
-        AnalysisEngine.instance.instrumentationService.logInfo(
-            "Missing element for function typed formal parameter "
-            "${node.identifier.name} in ${definingLibrary.source.fullName}");
-      } else {
-        nameScope = EnclosedScope(nameScope);
-        var typeParameters = parameterElement.typeParameters;
-        int length = typeParameters.length;
-        for (int i = 0; i < length; i++) {
-          nameScope.define(typeParameters[i]);
-        }
-      }
+      ParameterElement element = node.declaredElement;
+      nameScope = TypeParameterScope(
+        nameScope,
+        element.typeParameters,
+      );
       super.visitFunctionTypedFormalParameter(node);
     } finally {
       nameScope = outerScope;
@@ -2556,19 +2551,13 @@
       super.visitGenericFunctionType(node);
       return;
     }
-    GenericFunctionTypeElement element =
-        (node as GenericFunctionTypeImpl).declaredElement;
+
     Scope outerScope = nameScope;
     try {
-      if (element == null) {
-        AnalysisEngine.instance.instrumentationService
-            .logInfo("Missing element for generic function type in "
-                "${definingLibrary.source.fullName}");
-        super.visitGenericFunctionType(node);
-      } else {
-        nameScope = TypeParameterScope(nameScope, element);
-        super.visitGenericFunctionType(node);
-      }
+      GenericFunctionTypeElement element =
+          (node as GenericFunctionTypeImpl).declaredElement;
+      nameScope = TypeParameterScope(nameScope, element.typeParameters);
+      super.visitGenericFunctionType(node);
     } finally {
       nameScope = outerScope;
     }
@@ -2576,24 +2565,19 @@
 
   @override
   void visitGenericTypeAlias(GenericTypeAlias node) {
-    GenericTypeAliasElement element = node.declaredElement;
     Scope outerScope = nameScope;
     try {
-      if (element == null) {
-        AnalysisEngine.instance.instrumentationService
-            .logInfo("Missing element for generic function type in "
-                "${definingLibrary.source.fullName}");
-        super.visitGenericTypeAlias(node);
-      } else {
-        nameScope = TypeParameterScope(nameScope, element);
-        super.visitGenericTypeAlias(node);
+      GenericTypeAliasElement element = node.declaredElement;
+      nameScope = TypeParameterScope(nameScope, element.typeParameters);
+      super.visitGenericTypeAlias(node);
 
-        GenericFunctionTypeElement functionElement = element.function;
-        if (functionElement != null) {
-          nameScope = FunctionScope(nameScope, functionElement)
-            ..defineParameters();
-          visitGenericTypeAliasInFunctionScope(node);
-        }
+      GenericFunctionTypeElement functionElement = element.function;
+      if (functionElement != null) {
+        nameScope = FormalParameterScope(
+          nameScope,
+          functionElement.parameters,
+        );
+        visitGenericTypeAliasInFunctionScope(node);
       }
     } finally {
       nameScope = outerScope;
@@ -2623,14 +2607,11 @@
   void visitMethodDeclaration(MethodDeclaration node) {
     Scope outerScope = nameScope;
     try {
-      ExecutableElement methodElement = node.declaredElement;
-      if (methodElement == null) {
-        AnalysisEngine.instance.instrumentationService
-            .logInfo("Missing element for method ${node.name.name} in "
-                "${definingLibrary.source.fullName}");
-      } else {
-        nameScope = FunctionScope(nameScope, methodElement);
-      }
+      ExecutableElement element = node.declaredElement;
+      nameScope = TypeParameterScope(
+        nameScope,
+        element.typeParameters,
+      );
       visitMethodDeclarationInScope(node);
     } finally {
       nameScope = outerScope;
@@ -2643,14 +2624,13 @@
 
   @override
   void visitMixinDeclaration(MixinDeclaration node) {
-    ClassElement element = node.declaredElement;
-
     Scope outerScope = nameScope;
     ClassElement outerClass = enclosingClass;
     try {
+      ClassElement element = node.declaredElement;
       enclosingClass = element;
 
-      nameScope = TypeParameterScope(nameScope, element);
+      nameScope = TypeParameterScope(nameScope, element.typeParameters);
       visitMixinDeclarationInScope(node);
 
       nameScope = ClassScope(nameScope, element);
@@ -2687,7 +2667,7 @@
     } else if (node != null) {
       Scope outerNameScope = nameScope;
       try {
-        nameScope = EnclosedScope(nameScope);
+        nameScope = LocalScope(nameScope);
         node.accept(this);
       } finally {
         nameScope = outerNameScope;
@@ -2700,7 +2680,7 @@
     node.expression.accept(this);
     Scope outerNameScope = nameScope;
     try {
-      nameScope = EnclosedScope(nameScope);
+      nameScope = LocalScope(nameScope);
       _setNodeNameScope(node, nameScope);
       node.statements.accept(this);
     } finally {
@@ -2712,7 +2692,7 @@
   void visitSwitchDefault(SwitchDefault node) {
     Scope outerNameScope = nameScope;
     try {
-      nameScope = EnclosedScope(nameScope);
+      nameScope = LocalScope(nameScope);
       _setNodeNameScope(node, nameScope);
       node.statements.accept(this);
     } finally {
@@ -2750,9 +2730,10 @@
     super.visitVariableDeclaration(node);
     if (node.parent.parent is! TopLevelVariableDeclaration &&
         node.parent.parent is! FieldDeclaration) {
+      // TODO(scheglov) Do we need this?
       VariableElement element = node.declaredElement;
       if (element != null) {
-        nameScope.define(element);
+        _define(element);
       }
     }
   }
@@ -2784,6 +2765,10 @@
     return outerScope;
   }
 
+  void _define(Element element) {
+    (nameScope as LocalScope).add(element);
+  }
+
   /// Return the [Scope] to use while resolving inside the [node].
   ///
   /// Not every node has the scope set, for example we set the scopes for
@@ -2934,7 +2919,7 @@
       return;
     }
     // Prepare VariableElement.
-    Element element = nameScope.lookup(node, definingLibrary);
+    Element element = nameScope.lookupIdentifier(node);
     if (element is! VariableElement) {
       return;
     }
diff --git a/pkg/analyzer/lib/src/generated/static_type_analyzer.dart b/pkg/analyzer/lib/src/generated/static_type_analyzer.dart
index eafa028..4c605a3 100644
--- a/pkg/analyzer/lib/src/generated/static_type_analyzer.dart
+++ b/pkg/analyzer/lib/src/generated/static_type_analyzer.dart
@@ -112,7 +112,7 @@
       expression.staticType = _dynamicType;
     } else {
       expression.staticType = type;
-      if (identical(type, NeverTypeImpl.instance)) {
+      if (_typeSystem.isBottom(type)) {
         _flowAnalysis?.flow?.handleExit();
       }
     }
diff --git a/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart b/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart
index 8b8744a..b2e8b8a 100644
--- a/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart
+++ b/pkg/analyzer/lib/src/generated/testing/ast_test_factory.dart
@@ -778,14 +778,27 @@
           [List<Combinator> combinators]) =>
       importDirective(null, uri, false, prefix, combinators);
 
-  static IndexExpression indexExpression(Expression array, Expression index,
-          [TokenType leftBracket = TokenType.OPEN_SQUARE_BRACKET]) =>
-      astFactory.indexExpressionForTarget2(
-          target: array,
-          leftBracket: TokenFactory.tokenFromType(leftBracket),
-          index: index,
-          rightBracket:
-              TokenFactory.tokenFromType(TokenType.CLOSE_SQUARE_BRACKET));
+  static IndexExpression indexExpression({
+    @required Expression target,
+    bool hasQuestion = false,
+    @required Expression index,
+  }) {
+    return astFactory.indexExpressionForTarget2(
+      target: target,
+      question: hasQuestion
+          ? TokenFactory.tokenFromType(
+              TokenType.QUESTION,
+            )
+          : null,
+      leftBracket: TokenFactory.tokenFromType(
+        TokenType.OPEN_SQUARE_BRACKET,
+      ),
+      index: index,
+      rightBracket: TokenFactory.tokenFromType(
+        TokenType.CLOSE_SQUARE_BRACKET,
+      ),
+    );
+  }
 
   static IndexExpression indexExpressionForCascade(Expression array,
           Expression index, TokenType period, TokenType leftBracket) =>
diff --git a/pkg/analyzer/lib/src/generated/utilities_dart.dart b/pkg/analyzer/lib/src/generated/utilities_dart.dart
index 87dede9..118a2ad 100644
--- a/pkg/analyzer/lib/src/generated/utilities_dart.dart
+++ b/pkg/analyzer/lib/src/generated/utilities_dart.dart
@@ -5,6 +5,7 @@
 import 'package:analyzer/dart/ast/ast.dart' show AnnotatedNode, Comment;
 import 'package:analyzer/dart/ast/token.dart' show Token;
 import 'package:analyzer/src/dart/element/element.dart' show ElementImpl;
+import 'package:meta/meta.dart';
 
 export 'package:_fe_analyzer_shared/src/util/resolve_relative_uri.dart'
     show resolveRelativeUri;
@@ -49,19 +50,60 @@
 /// can be either required or optional.
 class ParameterKind implements Comparable<ParameterKind> {
   /// A positional required parameter.
-  static const ParameterKind REQUIRED =
-      ParameterKind('REQUIRED', 0, false, false);
+  static const ParameterKind REQUIRED = ParameterKind(
+    name: 'REQUIRED',
+    ordinal: 0,
+    isPositional: true,
+    isRequiredPositional: true,
+    isOptionalPositional: false,
+    isNamed: false,
+    isRequiredNamed: false,
+    isOptionalNamed: false,
+    isRequired: true,
+    isOptional: false,
+  );
 
   /// A positional optional parameter.
-  static const ParameterKind POSITIONAL =
-      ParameterKind('POSITIONAL', 1, false, true);
+  static const ParameterKind POSITIONAL = ParameterKind(
+    name: 'POSITIONAL',
+    ordinal: 1,
+    isPositional: true,
+    isRequiredPositional: false,
+    isOptionalPositional: true,
+    isNamed: false,
+    isRequiredNamed: false,
+    isOptionalNamed: false,
+    isRequired: false,
+    isOptional: true,
+  );
 
   /// A named required parameter.
-  static const ParameterKind NAMED_REQUIRED =
-      ParameterKind('NAMED_REQUIRED', 2, true, false);
+  static const ParameterKind NAMED_REQUIRED = ParameterKind(
+    name: 'NAMED_REQUIRED',
+    ordinal: 2,
+    isPositional: false,
+    isRequiredPositional: false,
+    isOptionalPositional: false,
+    isNamed: true,
+    isRequiredNamed: true,
+    isOptionalNamed: false,
+    isRequired: true,
+    isOptional: false,
+  );
 
   /// A named optional parameter.
-  static const ParameterKind NAMED = ParameterKind('NAMED', 2, true, true);
+  static const ParameterKind NAMED = ParameterKind(
+    name: 'NAMED',
+    ordinal: 3,
+    isPositional: false,
+    isRequiredPositional: false,
+    isOptionalPositional: false,
+    isNamed: true,
+    isRequiredNamed: false,
+    isOptionalNamed: true,
+    isRequired: false,
+    isOptional: true,
+  );
 
   static const List<ParameterKind> values = [
     REQUIRED,
@@ -76,14 +118,57 @@
   /// The ordinal value of the parameter.
   final int ordinal;
 
-  /// A flag indicating whether this is a named or positional parameter.
+  /// Return `true` if is a positional parameter.
+  ///
+  /// Positional parameters can either be required or optional.
+  final bool isPositional;
+
+  /// Return `true` if both a required and positional parameter.
+  final bool isRequiredPositional;
+
+  /// Return `true` if both an optional and positional parameter.
+  final bool isOptionalPositional;
+
+  /// Return `true` if a named parameter.
+  ///
+  /// Named parameters can either be required or optional.
   final bool isNamed;
 
-  /// A flag indicating whether this is an optional or required parameter.
+  /// Return `true` if both a required and named parameter.
+  ///
+  /// Note: this will return `false` for a named parameter that is annotated
+  /// with the `@required` annotation.
+  final bool isRequiredNamed;
+
+  /// Return `true` if both an optional and named parameter.
+  final bool isOptionalNamed;
+
+  /// Return `true` if a required parameter.
+  ///
+  /// Required parameters can either be positional or named.
+  ///
+  /// Note: this will return `false` for a named parameter that is annotated
+  /// with the `@required` annotation.
+  final bool isRequired;
+
+  /// Return `true` if an optional parameter.
+  ///
+  /// Optional parameters can either be positional or named.
   final bool isOptional;
 
   /// Initialize a newly created kind with the given state.
-  const ParameterKind(this.name, this.ordinal, this.isNamed, this.isOptional);
+  const ParameterKind({
+    @required this.name,
+    @required this.ordinal,
+    @required this.isPositional,
+    @required this.isRequiredPositional,
+    @required this.isOptionalPositional,
+    @required this.isNamed,
+    @required this.isRequiredNamed,
+    @required this.isOptionalNamed,
+    @required this.isRequired,
+    @required this.isOptional,
+  });
 
   @override
   int get hashCode => ordinal;
diff --git a/pkg/analyzer/lib/src/generated/utilities_general.dart b/pkg/analyzer/lib/src/generated/utilities_general.dart
index dc05c2c..4eb59de 100644
--- a/pkg/analyzer/lib/src/generated/utilities_general.dart
+++ b/pkg/analyzer/lib/src/generated/utilities_general.dart
@@ -85,13 +85,14 @@
   }
 
   /// Combines together two hash codes.
-  static int hash2(a, b) => finish(combine(combine(0, a), b));
+  static int hash2(Object a, Object b) => finish(combine(combine(0, a), b));
 
   /// Combines together three hash codes.
-  static int hash3(a, b, c) => finish(combine(combine(combine(0, a), b), c));
+  static int hash3(Object a, Object b, Object c) =>
+      finish(combine(combine(combine(0, a), b), c));
 
   /// Combines together four hash codes.
-  static int hash4(a, b, c, d) =>
+  static int hash4(Object a, Object b, Object c, Object d) =>
       finish(combine(combine(combine(combine(0, a), b), c), d));
 }
 
diff --git a/pkg/analyzer/lib/src/lint/analysis.dart b/pkg/analyzer/lib/src/lint/analysis.dart
index 35a0852..2990f6d 100644
--- a/pkg/analyzer/lib/src/lint/analysis.dart
+++ b/pkg/analyzer/lib/src/lint/analysis.dart
@@ -6,6 +6,7 @@
 import 'dart:collection';
 import 'dart:io' as io;
 
+import 'package:analyzer/dart/analysis/context_locator.dart' as api;
 import 'package:analyzer/dart/analysis/results.dart';
 import 'package:analyzer/file_system/file_system.dart'
     show File, Folder, ResourceProvider, ResourceUriResolver;
@@ -15,6 +16,8 @@
 import 'package:analyzer/src/context/packages.dart';
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
+import 'package:analyzer/src/dart/analysis/driver_based_analysis_context.dart'
+    as api;
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/performance_logger.dart';
 import 'package:analyzer/src/dart/sdk/sdk.dart';
@@ -169,6 +172,9 @@
       _buildAnalyzerOptions(options),
       packages: Packages.empty,
     );
+
+    _setAnalysisDriverAnalysisContext(analysisDriver, files);
+
     analysisDriver.results.listen((_) {});
     analysisDriver.exceptions.listen((_) {});
     scheduler.start();
@@ -242,13 +248,46 @@
     }
     return null;
   }
+
+  void _setAnalysisDriverAnalysisContext(
+    AnalysisDriver analysisDriver,
+    Iterable<io.File> files,
+  ) {
+    if (files.isEmpty) {
+      return;
+    }
+
+    var rootPath = p.normalize(files.first.absolute.path);
+    if (rootPath == null) {
+      return;
+    }
+
+    var apiContextRoots = api.ContextLocator(
+      resourceProvider: resourceProvider,
+    ).locateRoots(
+      includedPaths: [rootPath],
+      excludedPaths: [],
+    );
+
+    if (apiContextRoots.isEmpty) {
+      return;
+    }
+
+    analysisDriver.configure(
+      analysisContext: api.DriverBasedAnalysisContext(
+        resourceProvider,
+        apiContextRoots.first,
+        analysisDriver,
+      ),
+    );
+  }
 }
 
 /// Prints logging information comments to the [outSink] and error messages to
 /// [errorSink].
 class StdInstrumentation extends NoopInstrumentationService {
   @override
-  void logError(String message, [exception]) {
+  void logError(String message, [Object exception]) {
     errorSink.writeln(message);
     if (exception != null) {
       errorSink.writeln(exception);
@@ -264,7 +303,7 @@
   }
 
   @override
-  void logInfo(String message, [exception]) {
+  void logInfo(String message, [Object exception]) {
     outSink.writeln(message);
     if (exception != null) {
       outSink.writeln(exception);
diff --git a/pkg/analyzer/lib/src/lint/config.dart b/pkg/analyzer/lib/src/lint/config.dart
index b6c801c..f18198a 100644
--- a/pkg/analyzer/lib/src/lint/config.dart
+++ b/pkg/analyzer/lib/src/lint/config.dart
@@ -60,7 +60,7 @@
   @override
   final ruleConfigs = <RuleConfig>[];
 
-  void addAsListOrString(value, List<String> list) {
+  void addAsListOrString(Object value, List<String> list) {
     if (value is List) {
       value.forEach((v) => list.add(v));
     } else if (value is String) {
@@ -68,7 +68,7 @@
     }
   }
 
-  bool asBool(scalar) {
+  bool asBool(Object scalar) {
     Object value = scalar is YamlScalar ? scalar.value : scalar;
     if (value is bool) {
       return value;
@@ -84,7 +84,7 @@
     return null;
   }
 
-  String asString(scalar) {
+  String asString(Object scalar) {
     Object value = scalar is YamlScalar ? scalar.value : scalar;
     if (value is String) {
       return value;
@@ -92,7 +92,7 @@
     return null;
   }
 
-  Map<String, dynamic> parseArgs(args) {
+  Map<String, dynamic> parseArgs(Object args) {
     bool enabled = asBool(args);
     if (enabled != null) {
       return {'enabled': enabled};
diff --git a/pkg/analyzer/lib/src/lint/linter.dart b/pkg/analyzer/lib/src/lint/linter.dart
index b3e9d16..20e1c69 100644
--- a/pkg/analyzer/lib/src/lint/linter.dart
+++ b/pkg/analyzer/lib/src/lint/linter.dart
@@ -10,6 +10,7 @@
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/constant/value.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/dart/element/type_system.dart';
 import 'package:analyzer/error/error.dart';
@@ -24,7 +25,6 @@
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/error/lint_codes.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/engine.dart'
     show
@@ -49,7 +49,7 @@
 
 export 'package:analyzer/src/lint/linter_visitor.dart' show NodeLintRegistry;
 
-typedef Printer = Function(String msg);
+typedef Printer = void Function(String msg);
 
 /// Describes a String in valid camel case format.
 @deprecated // Never intended for public use.
@@ -212,7 +212,7 @@
 
   String get html => '<a href="$href">${_emph(label)}</a>';
 
-  String _emph(msg) => bold ? '<strong>$msg</strong>' : msg;
+  String _emph(String msg) => bold ? '<strong>$msg</strong>' : msg;
 }
 
 /// The result of attempting to evaluate an expression.
@@ -370,8 +370,6 @@
   @override
   LinterNameInScopeResolutionResult resolveNameInScope(
       String id, bool setter, AstNode node) {
-    var idEq = '$id=';
-
     Scope scope;
     for (var context = node; context != null; context = context.parent) {
       scope = ScopedVisitor.getNodeNameScope(context);
@@ -381,18 +379,9 @@
     }
 
     if (scope != null) {
-      Element idElement;
-      Element idEqElement;
-
-      void lookupScopeAndEnclosing() {
-        while (scope != null && idElement == null && idEqElement == null) {
-          idElement = scope.localLookup(id);
-          idEqElement = scope.localLookup(idEq);
-          scope = scope.enclosingScope;
-        }
-      }
-
-      lookupScopeAndEnclosing();
+      var lookupResult = scope.lookup2(id);
+      var idElement = lookupResult.getter;
+      var idEqElement = lookupResult.setter;
 
       var requestedElement = setter ? idEqElement : idElement;
       var differentElement = setter ? idElement : idEqElement;
diff --git a/pkg/analyzer/lib/src/lint/registry.dart b/pkg/analyzer/lib/src/lint/registry.dart
index 3fd2ff3..b1c2ccd 100644
--- a/pkg/analyzer/lib/src/lint/registry.dart
+++ b/pkg/analyzer/lib/src/lint/registry.dart
@@ -4,6 +4,7 @@
 
 import 'dart:collection';
 
+import 'package:analyzer/src/dart/error/lint_codes.dart';
 import 'package:analyzer/src/lint/config.dart';
 import 'package:analyzer/src/lint/linter.dart';
 
@@ -13,7 +14,10 @@
   static final Registry ruleRegistry = Registry();
 
   /// A table mapping rule names to rules.
-  final Map<String, LintRule> _ruleMap = <String, LintRule>{};
+  final Map<String, LintRule> _ruleMap = {};
+
+  /// A table mapping unique names to lint codes.
+  final Map<String, LintCode> _codeMap = {};
 
   @override
   Iterator<LintRule> get iterator => _ruleMap.values.iterator;
@@ -24,6 +28,9 @@
   /// Return the lint rule with the given [name].
   LintRule operator [](String name) => _ruleMap[name];
 
+  /// Return the lint code that has the given [uniqueName].
+  LintCode codeForUniqueName(String uniqueName) => _codeMap[uniqueName];
+
   /// Return a list of the lint rules explicitly enabled by the given [config].
   ///
   /// For example:
@@ -41,5 +48,8 @@
   /// Add the given lint [rule] to this registry.
   void register(LintRule rule) {
     _ruleMap[rule.name] = rule;
+    for (var lintCode in rule.lintCodes) {
+      _codeMap[lintCode.uniqueName] = lintCode;
+    }
   }
 }
diff --git a/pkg/analyzer/lib/src/services/available_declarations.dart b/pkg/analyzer/lib/src/services/available_declarations.dart
index 3a6484c..c1e1a66 100644
--- a/pkg/analyzer/lib/src/services/available_declarations.dart
+++ b/pkg/analyzer/lib/src/services/available_declarations.dart
@@ -1325,7 +1325,7 @@
       List<String> parameterNames,
       List<String> parameterTypes,
       Declaration parent,
-      List<String> relevanceTags,
+      @required List<String> relevanceTags,
       int requiredParameterCount,
       String returnType,
       String typeParameters,
@@ -1333,9 +1333,6 @@
       if (Identifier.isPrivateName(name.name)) {
         return null;
       }
-      if (isConst) {
-        relevanceTags = [...?relevanceTags, 'isConst'];
-      }
 
       var locationOffset = name.offset;
       var lineLocation = lineInfo.getLocation(locationOffset);
@@ -1392,6 +1389,7 @@
           if (classMember is ConstructorDeclaration) {
             var parameters = classMember.parameters;
             var defaultArguments = _computeDefaultArguments(parameters);
+            var isConst = classMember.constKeyword != null;
 
             var constructorName = classMember.name;
             constructorName ??= SimpleIdentifierImpl(
@@ -1402,6 +1400,7 @@
               ),
             );
 
+            // TODO(brianwilkerson) Should we be passing in `isConst`?
             addDeclaration(
               defaultArgumentListString: defaultArguments?.text,
               defaultArgumentListTextRanges: defaultArguments?.ranges,
@@ -1412,12 +1411,18 @@
               parameterNames: _getFormalParameterNames(parameters),
               parameterTypes: _getFormalParameterTypes(parameters),
               parent: parent,
+              relevanceTags: [
+                'ElementKind.CONSTRUCTOR',
+                if (isConst) 'ElementKind.CONSTRUCTOR+const'
+              ],
               requiredParameterCount:
                   _getFormalParameterRequiredCount(parameters),
               returnType: classMember.returnType.name,
             );
             hasConstructor = true;
           } else if (classMember is FieldDeclaration) {
+            // TODO(brianwilkerson) Why are we creating declarations for
+            //  instance members?
             var isStatic = classMember.isStatic;
             var isConst = classMember.fields.isConst;
             var isFinal = classMember.fields.isFinal;
@@ -1431,7 +1436,11 @@
                 kind: DeclarationKind.FIELD,
                 name: field.name,
                 parent: parent,
-                relevanceTags: RelevanceTags._forExpression(field.initializer),
+                relevanceTags: [
+                  'ElementKind.FIELD',
+                  if (isConst) 'ElementKind.FIELD+const',
+                  ...?RelevanceTags._forExpression(field.initializer)
+                ],
                 returnType: _getTypeAnnotationString(classMember.fields.type),
               );
             }
@@ -1445,6 +1454,7 @@
                 kind: DeclarationKind.GETTER,
                 name: classMember.name,
                 parent: parent,
+                relevanceTags: ['ElementKind.FIELD'],
                 returnType: _getTypeAnnotationString(classMember.returnType),
               );
             } else if (classMember.isSetter) {
@@ -1457,6 +1467,7 @@
                 parameterNames: _getFormalParameterNames(parameters),
                 parameterTypes: _getFormalParameterTypes(parameters),
                 parent: parent,
+                relevanceTags: ['ElementKind.FIELD'],
                 requiredParameterCount:
                     _getFormalParameterRequiredCount(parameters),
               );
@@ -1473,6 +1484,7 @@
                 parameterNames: _getFormalParameterNames(parameters),
                 parameterTypes: _getFormalParameterTypes(parameters),
                 parent: parent,
+                relevanceTags: ['ElementKind.METHOD'],
                 requiredParameterCount:
                     _getFormalParameterRequiredCount(parameters),
                 returnType: _getTypeAnnotationString(classMember.returnType),
@@ -1489,6 +1501,7 @@
           isDeprecated: isDeprecated,
           kind: DeclarationKind.CLASS,
           name: node.name,
+          relevanceTags: ['ElementKind.CLASS'],
         );
         if (classDeclaration == null) continue;
 
@@ -1519,7 +1532,7 @@
             parameterNames: [],
             parameterTypes: [],
             parent: classDeclaration,
-            relevanceTags: null,
+            relevanceTags: ['ElementKind.CONSTRUCTOR'],
             requiredParameterCount: 0,
             returnType: node.name.name,
             typeParameters: null,
@@ -1530,12 +1543,14 @@
           isDeprecated: isDeprecated,
           kind: DeclarationKind.CLASS_TYPE_ALIAS,
           name: node.name,
+          relevanceTags: ['ElementKind.CLASS'],
         );
       } else if (node is EnumDeclaration) {
         var enumDeclaration = addDeclaration(
           isDeprecated: isDeprecated,
           kind: DeclarationKind.ENUM,
           name: node.name,
+          relevanceTags: ['ElementKind.ENUM'],
         );
         if (enumDeclaration == null) continue;
 
@@ -1547,6 +1562,10 @@
             kind: DeclarationKind.ENUM_CONSTANT,
             name: constant.name,
             parent: enumDeclaration,
+            relevanceTags: [
+              'ElementKind.ENUM_CONSTANT',
+              'ElementKind.ENUM_CONSTANT+const'
+            ],
           );
         }
       } else if (node is ExtensionDeclaration) {
@@ -1555,8 +1574,11 @@
             isDeprecated: isDeprecated,
             kind: DeclarationKind.EXTENSION,
             name: node.name,
+            relevanceTags: ['ElementKind.EXTENSION'],
           );
         }
+        // TODO(brianwilkerson) Should we be creating declarations for the
+        //  static members of the extension?
       } else if (node is FunctionDeclaration) {
         var functionExpression = node.functionExpression;
         var parameters = functionExpression.parameters;
@@ -1565,6 +1587,7 @@
             isDeprecated: isDeprecated,
             kind: DeclarationKind.GETTER,
             name: node.name,
+            relevanceTags: ['ElementKind.FUNCTION'],
             returnType: _getTypeAnnotationString(node.returnType),
           );
         } else if (node.isSetter) {
@@ -1575,6 +1598,7 @@
             parameters: parameters.toSource(),
             parameterNames: _getFormalParameterNames(parameters),
             parameterTypes: _getFormalParameterTypes(parameters),
+            relevanceTags: ['ElementKind.FUNCTION'],
             requiredParameterCount:
                 _getFormalParameterRequiredCount(parameters),
           );
@@ -1589,6 +1613,7 @@
             parameters: parameters.toSource(),
             parameterNames: _getFormalParameterNames(parameters),
             parameterTypes: _getFormalParameterTypes(parameters),
+            relevanceTags: ['ElementKind.FUNCTION'],
             requiredParameterCount:
                 _getFormalParameterRequiredCount(parameters),
             returnType: _getTypeAnnotationString(node.returnType),
@@ -1607,6 +1632,7 @@
           parameters: parameters.toSource(),
           parameterNames: _getFormalParameterNames(parameters),
           parameterTypes: _getFormalParameterTypes(parameters),
+          relevanceTags: ['ElementKind.FUNCTION_TYPE_ALIAS'],
           requiredParameterCount: _getFormalParameterRequiredCount(parameters),
           returnType: _getTypeAnnotationString(functionType.returnType),
           typeParameters: functionType.typeParameters?.toSource(),
@@ -1620,6 +1646,7 @@
           parameters: parameters.toSource(),
           parameterNames: _getFormalParameterNames(parameters),
           parameterTypes: _getFormalParameterTypes(parameters),
+          relevanceTags: ['ElementKind.FUNCTION_TYPE_ALIAS'],
           requiredParameterCount: _getFormalParameterRequiredCount(parameters),
           returnType: _getTypeAnnotationString(node.returnType),
           typeParameters: node.typeParameters?.toSource(),
@@ -1629,6 +1656,7 @@
           isDeprecated: isDeprecated,
           kind: DeclarationKind.MIXIN,
           name: node.name,
+          relevanceTags: ['ElementKind.MIXIN'],
         );
         if (mixinDeclaration == null) continue;
         addClassMembers(mixinDeclaration, node.members);
@@ -1643,7 +1671,11 @@
             isFinal: isFinal,
             kind: DeclarationKind.VARIABLE,
             name: variable.name,
-            relevanceTags: RelevanceTags._forExpression(variable.initializer),
+            relevanceTags: [
+              'ElementKind.TOP_LEVEL_VARIABLE',
+              if (isConst) 'ElementKind.TOP_LEVEL_VARIABLE+const',
+              ...?RelevanceTags._forExpression(variable.initializer)
+            ],
             returnType: _getTypeAnnotationString(node.variables.type),
           );
         }
@@ -1653,8 +1685,11 @@
 
   void _computeRelevanceTags(List<Declaration> declarations) {
     for (var declaration in declarations) {
-      declaration._relevanceTags ??=
-          RelevanceTags._forDeclaration(uriStr, declaration);
+      var tags = RelevanceTags._forDeclaration(uriStr, declaration);
+      if (tags != null) {
+        declaration._relevanceTags ??= [];
+        declaration._relevanceTags.addAll(tags);
+      }
       _computeRelevanceTags(declaration.children);
     }
   }
diff --git a/pkg/analyzer/lib/src/services/lint.dart b/pkg/analyzer/lib/src/services/lint.dart
index f65130f..495e345 100644
--- a/pkg/analyzer/lib/src/services/lint.dart
+++ b/pkg/analyzer/lib/src/services/lint.dart
@@ -38,6 +38,15 @@
   /// Return the lint code associated with this linter.
   LintCode get lintCode => null;
 
+  /// Return the lint codes associated with this lint rule.
+  List<LintCode> get lintCodes {
+    var code = lintCode;
+    if (code == null) {
+      return const <LintCode>[];
+    }
+    return <LintCode>[code];
+  }
+
   /// Linter name.
   String get name;
 
diff --git a/pkg/analyzer/lib/src/summary/format.dart b/pkg/analyzer/lib/src/summary/format.dart
index 8680e93..54a723b 100644
--- a/pkg/analyzer/lib/src/summary/format.dart
+++ b/pkg/analyzer/lib/src/summary/format.dart
@@ -137,7 +137,7 @@
     int index = const fb.Uint8Reader().read(bc, offset);
     return index < idl.LinkedNodeTypeKind.values.length
         ? idl.LinkedNodeTypeKind.values[index]
-        : idl.LinkedNodeTypeKind.bottom;
+        : idl.LinkedNodeTypeKind.dynamic_;
   }
 }
 
@@ -16691,7 +16691,7 @@
   }
 
   @override
-  idl.LinkedNodeTypeKind get kind => _kind ??= idl.LinkedNodeTypeKind.bottom;
+  idl.LinkedNodeTypeKind get kind => _kind ??= idl.LinkedNodeTypeKind.dynamic_;
 
   set kind(idl.LinkedNodeTypeKind value) {
     this._kind = value;
@@ -16850,7 +16850,7 @@
     if (offset_interfaceTypeArguments != null) {
       fbBuilder.addOffset(4, offset_interfaceTypeArguments);
     }
-    if (_kind != null && _kind != idl.LinkedNodeTypeKind.bottom) {
+    if (_kind != null && _kind != idl.LinkedNodeTypeKind.dynamic_) {
       fbBuilder.addUint8(5, _kind.index);
     }
     if (_nullabilitySuffix != null &&
@@ -16954,7 +16954,7 @@
   @override
   idl.LinkedNodeTypeKind get kind {
     _kind ??= const _LinkedNodeTypeKindReader()
-        .vTableGet(_bc, _bcOffset, 5, idl.LinkedNodeTypeKind.bottom);
+        .vTableGet(_bc, _bcOffset, 5, idl.LinkedNodeTypeKind.dynamic_);
     return _kind;
   }
 
@@ -17010,7 +17010,7 @@
       _result["interfaceTypeArguments"] =
           interfaceTypeArguments.map((_value) => _value.toJson()).toList();
     }
-    if (kind != idl.LinkedNodeTypeKind.bottom) {
+    if (kind != idl.LinkedNodeTypeKind.dynamic_) {
       _result["kind"] = kind.toString().split('.')[1];
     }
     if (nullabilitySuffix != idl.EntityRefNullabilitySuffix.starOrIrrelevant) {
diff --git a/pkg/analyzer/lib/src/summary/format.fbs b/pkg/analyzer/lib/src/summary/format.fbs
index 3829aa2..31bfa9c 100644
--- a/pkg/analyzer/lib/src/summary/format.fbs
+++ b/pkg/analyzer/lib/src/summary/format.fbs
@@ -414,14 +414,14 @@
 
 /// Kinds of [LinkedNodeType]s.
 enum LinkedNodeTypeKind : byte {
-  bottom,
-
   dynamic_,
 
   function,
 
   interface,
 
+  never,
+
   typeParameter,
 
   void_
diff --git a/pkg/analyzer/lib/src/summary/idl.dart b/pkg/analyzer/lib/src/summary/idl.dart
index 5648d6e..1eea7da 100644
--- a/pkg/analyzer/lib/src/summary/idl.dart
+++ b/pkg/analyzer/lib/src/summary/idl.dart
@@ -1842,10 +1842,10 @@
 
 /// Kinds of [LinkedNodeType]s.
 enum LinkedNodeTypeKind {
-  bottom,
   dynamic_,
   function,
   interface,
+  never,
   typeParameter,
   void_
 }
diff --git a/pkg/analyzer/lib/src/summary2/ast_resolver.dart b/pkg/analyzer/lib/src/summary2/ast_resolver.dart
index 06b0f40..2b88556 100644
--- a/pkg/analyzer/lib/src/summary2/ast_resolver.dart
+++ b/pkg/analyzer/lib/src/summary2/ast_resolver.dart
@@ -4,10 +4,10 @@
 
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/error/listener.dart';
 import 'package:analyzer/src/dart/resolver/flow_analysis_visitor.dart';
 import 'package:analyzer/src/dart/resolver/resolution_visitor.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/generated/resolver.dart';
 import 'package:analyzer/src/summary2/link.dart';
 
diff --git a/pkg/analyzer/lib/src/summary2/constructor_initializer_resolver.dart b/pkg/analyzer/lib/src/summary2/constructor_initializer_resolver.dart
index 7a858a8..bb3c11c 100644
--- a/pkg/analyzer/lib/src/summary2/constructor_initializer_resolver.dart
+++ b/pkg/analyzer/lib/src/summary2/constructor_initializer_resolver.dart
@@ -5,7 +5,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/element/element.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/summary2/ast_resolver.dart';
 import 'package:analyzer/src/summary2/link.dart';
 import 'package:analyzer/src/summary2/linking_node_scope.dart';
diff --git a/pkg/analyzer/lib/src/summary2/default_types_builder.dart b/pkg/analyzer/lib/src/summary2/default_types_builder.dart
index ef75758..ce0b852 100644
--- a/pkg/analyzer/lib/src/summary2/default_types_builder.dart
+++ b/pkg/analyzer/lib/src/summary2/default_types_builder.dart
@@ -19,22 +19,27 @@
     for (var node in nodes) {
       if (node is ClassDeclaration) {
         var element = node.declaredElement;
+        _breakSelfCycles(node.typeParameters);
         _breakRawTypeCycles(element, node.typeParameters);
         _computeBounds(element, node.typeParameters);
       } else if (node is ClassTypeAlias) {
         var element = node.declaredElement;
+        _breakSelfCycles(node.typeParameters);
         _breakRawTypeCycles(element, node.typeParameters);
         _computeBounds(element, node.typeParameters);
       } else if (node is FunctionTypeAlias) {
         var element = node.declaredElement;
+        _breakSelfCycles(node.typeParameters);
         _breakRawTypeCycles(element, node.typeParameters);
         _computeBounds(element, node.typeParameters);
       } else if (node is GenericTypeAlias) {
         var element = node.declaredElement;
+        _breakSelfCycles(node.typeParameters);
         _breakRawTypeCycles(element, node.typeParameters);
         _computeBounds(element, node.typeParameters);
       } else if (node is MixinDeclaration) {
         var element = node.declaredElement;
+        _breakSelfCycles(node.typeParameters);
         _breakRawTypeCycles(element, node.typeParameters);
         _computeBounds(element, node.typeParameters);
       }
@@ -86,6 +91,45 @@
     }
   }
 
+  void _breakSelfCycles(TypeParameterList parameterList) {
+    if (parameterList == null) return;
+    var typeParameters = parameterList.typeParameters;
+
+    Map<String, TypeParameter> typeParametersByName;
+    for (var parameter in typeParameters) {
+      var boundNode = parameter.bound;
+      if (boundNode is TypeName) {
+        if (typeParametersByName == null) {
+          typeParametersByName = {};
+          for (var parameterNode in typeParameters) {
+            var name = parameterNode.name.name;
+            typeParametersByName[name] = parameterNode;
+          }
+        }
+
+        var current = parameter;
+        for (var step = 0;
+            current != null && step < typeParameters.length;
+            ++step) {
+          var bound = current.bound;
+          if (bound is TypeName) {
+            var typeNameIdentifier = bound.name;
+            if (typeNameIdentifier is SimpleIdentifier) {
+              current = typeParametersByName[typeNameIdentifier.name];
+              continue;
+            }
+          }
+          current = null;
+          break;
+        }
+
+        if (current != null) {
+          boundNode.type = DynamicTypeImpl.instance;
+        }
+      }
+    }
+  }
+
   /// Build actual default type [DartType]s from computed [TypeBuilder]s.
   void _build(TypeParameterList parameterList) {
     if (parameterList == null) return;
diff --git a/pkg/analyzer/lib/src/summary2/default_value_resolver.dart b/pkg/analyzer/lib/src/summary2/default_value_resolver.dart
index f3cee91..a8398e4 100644
--- a/pkg/analyzer/lib/src/summary2/default_value_resolver.dart
+++ b/pkg/analyzer/lib/src/summary2/default_value_resolver.dart
@@ -4,9 +4,9 @@
 
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/generated/resolver.dart' show InferenceContext;
 import 'package:analyzer/src/summary2/ast_resolver.dart';
 import 'package:analyzer/src/summary2/link.dart';
diff --git a/pkg/analyzer/lib/src/summary2/function_type_builder.dart b/pkg/analyzer/lib/src/summary2/function_type_builder.dart
index 4114f26..74cf1fd 100644
--- a/pkg/analyzer/lib/src/summary2/function_type_builder.dart
+++ b/pkg/analyzer/lib/src/summary2/function_type_builder.dart
@@ -6,9 +6,12 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
+import 'package:analyzer/src/dart/ast/extensions.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
+import 'package:analyzer/src/dart/element/type_visitor.dart';
 import 'package:analyzer/src/summary2/lazy_ast.dart';
 import 'package:analyzer/src/summary2/type_builder.dart';
 
@@ -61,6 +64,16 @@
   Element get element => null;
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    if (visitor is LinkingTypeVisitor<R>) {
+      var visitor2 = visitor as LinkingTypeVisitor<R>;
+      return visitor2.visitFunctionTypeBuilder(this);
+    } else {
+      throw StateError('Should not happen outside linking.');
+    }
+  }
+
+  @override
   DartType build() {
     if (_type != null) {
       return _type;
@@ -148,11 +161,10 @@
     bool isNNBD,
     FormalParameterList node,
   ) {
-    return node.parameters.map((parameter) {
+    return node.parameters.asImpl.map((parameter) {
       return ParameterElementImpl.synthetic(
         parameter.identifier?.name ?? '',
         _getParameterType(isNNBD, parameter),
-        // ignore: deprecated_member_use_from_same_package
         parameter.kind,
       );
     }).toList();
diff --git a/pkg/analyzer/lib/src/summary2/library_builder.dart b/pkg/analyzer/lib/src/summary2/library_builder.dart
index e7c61e6..e956041 100644
--- a/pkg/analyzer/lib/src/summary2/library_builder.dart
+++ b/pkg/analyzer/lib/src/summary2/library_builder.dart
@@ -6,7 +6,7 @@
 import 'package:analyzer/dart/ast/ast.dart' as ast;
 import 'package:analyzer/src/dart/ast/mixin_super_invoked_names.dart';
 import 'package:analyzer/src/dart/element/element.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart' show LibraryScope;
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
 import 'package:analyzer/src/summary/format.dart';
 import 'package:analyzer/src/summary/idl.dart';
@@ -209,7 +209,7 @@
 
   void buildElement() {
     element = linker.elementFactory.libraryOfUri('$uri');
-    scope = LibraryScope(element);
+    scope = element.scope;
   }
 
   void buildInitialExportScope() {
diff --git a/pkg/analyzer/lib/src/summary2/linked_unit_context.dart b/pkg/analyzer/lib/src/summary2/linked_unit_context.dart
index a5d02ce..0a34140 100644
--- a/pkg/analyzer/lib/src/summary2/linked_unit_context.dart
+++ b/pkg/analyzer/lib/src/summary2/linked_unit_context.dart
@@ -922,10 +922,7 @@
     if (linkedType == null) return null;
 
     var kind = linkedType.kind;
-    if (kind == LinkedNodeTypeKind.bottom) {
-      var nullabilitySuffix = _nullabilitySuffix(linkedType.nullabilitySuffix);
-      return NeverTypeImpl.instance.withNullability(nullabilitySuffix);
-    } else if (kind == LinkedNodeTypeKind.dynamic_) {
+    if (kind == LinkedNodeTypeKind.dynamic_) {
       return DynamicTypeImpl.instance;
     } else if (kind == LinkedNodeTypeKind.function) {
       var typeParameterDataList = linkedType.functionTypeParameters;
@@ -985,6 +982,9 @@
         typeArguments: linkedType.interfaceTypeArguments.map(readType).toList(),
         nullabilitySuffix: nullabilitySuffix,
       );
+    } else if (kind == LinkedNodeTypeKind.never) {
+      var nullabilitySuffix = _nullabilitySuffix(linkedType.nullabilitySuffix);
+      return NeverTypeImpl.instance.withNullability(nullabilitySuffix);
     } else if (kind == LinkedNodeTypeKind.typeParameter) {
       TypeParameterElement element;
       var id = linkedType.typeParameterId;
diff --git a/pkg/analyzer/lib/src/summary2/linking_bundle_context.dart b/pkg/analyzer/lib/src/summary2/linking_bundle_context.dart
index f2fa94d..72d0e9d 100644
--- a/pkg/analyzer/lib/src/summary2/linking_bundle_context.dart
+++ b/pkg/analyzer/lib/src/summary2/linking_bundle_context.dart
@@ -78,12 +78,7 @@
   LinkedNodeTypeBuilder writeType(DartType type) {
     if (type == null) return null;
 
-    if (type.isBottom) {
-      return LinkedNodeTypeBuilder(
-        kind: LinkedNodeTypeKind.bottom,
-        nullabilitySuffix: _nullabilitySuffix(type),
-      );
-    } else if (type.isDynamic) {
+    if (type.isDynamic) {
       return LinkedNodeTypeBuilder(
         kind: LinkedNodeTypeKind.dynamic_,
       );
@@ -96,6 +91,11 @@
         interfaceTypeArguments: type.typeArguments.map(writeType).toList(),
         nullabilitySuffix: _nullabilitySuffix(type),
       );
+    } else if (type is NeverType) {
+      return LinkedNodeTypeBuilder(
+        kind: LinkedNodeTypeKind.never,
+        nullabilitySuffix: _nullabilitySuffix(type),
+      );
     } else if (type is TypeParameterType) {
       TypeParameterElementImpl element = type.element;
       var id = _typeParameters[element];
diff --git a/pkg/analyzer/lib/src/summary2/linking_node_scope.dart b/pkg/analyzer/lib/src/summary2/linking_node_scope.dart
index 8c8e6e9..a97dccc 100644
--- a/pkg/analyzer/lib/src/summary2/linking_node_scope.dart
+++ b/pkg/analyzer/lib/src/summary2/linking_node_scope.dart
@@ -3,7 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
+import 'package:analyzer/dart/element/scope.dart';
 
 /// This class provides access to [Scope]s corresponding to [AstNode]s.
 class LinkingNodeContext {
diff --git a/pkg/analyzer/lib/src/summary2/metadata_resolver.dart b/pkg/analyzer/lib/src/summary2/metadata_resolver.dart
index 219a1e6..a4182c5 100644
--- a/pkg/analyzer/lib/src/summary2/metadata_resolver.dart
+++ b/pkg/analyzer/lib/src/summary2/metadata_resolver.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/element.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/summary2/ast_resolver.dart';
 import 'package:analyzer/src/summary2/link.dart';
 import 'package:analyzer/src/summary2/linking_node_scope.dart';
diff --git a/pkg/analyzer/lib/src/summary2/named_type_builder.dart b/pkg/analyzer/lib/src/summary2/named_type_builder.dart
index 0edea72..0bc869d 100644
--- a/pkg/analyzer/lib/src/summary2/named_type_builder.dart
+++ b/pkg/analyzer/lib/src/summary2/named_type_builder.dart
@@ -6,10 +6,13 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
+import 'package:analyzer/src/dart/ast/extensions.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_algebra.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
+import 'package:analyzer/src/dart/element/type_visitor.dart';
 import 'package:analyzer/src/summary2/lazy_ast.dart';
 import 'package:analyzer/src/summary2/type_builder.dart';
 import 'package:meta/meta.dart';
@@ -63,6 +66,16 @@
   }
 
   @override
+  R accept<R>(TypeVisitor<R> visitor) {
+    if (visitor is LinkingTypeVisitor<R>) {
+      var visitor2 = visitor as LinkingTypeVisitor<R>;
+      return visitor2.visitNamedTypeBuilder(this);
+    } else {
+      throw StateError('Should not happen outside linking.');
+    }
+  }
+
+  @override
   DartType build() {
     if (_type != null) {
       return _type;
@@ -191,15 +204,7 @@
   }) {
     var returnType = _buildNodeType(returnTypeNode);
     var typeParameters = _typeParameters(typeParameterList);
-
-    var formalParameters = parameterList.parameters.map((parameter) {
-      return ParameterElementImpl.synthetic(
-        parameter.identifier?.name ?? '',
-        _buildFormalParameterType(parameter),
-        // ignore: deprecated_member_use_from_same_package
-        parameter.kind,
-      );
-    }).toList();
+    var formalParameters = _formalParameters(parameterList);
 
     return FunctionTypeImpl(
       typeFormals: typeParameters,
@@ -230,6 +235,16 @@
     }
   }
 
+  List<ParameterElementImpl> _formalParameters(FormalParameterList node) {
+    return node.parameters.asImpl.map((parameter) {
+      return ParameterElementImpl.synthetic(
+        parameter.identifier?.name ?? '',
+        _buildFormalParameterType(parameter),
+        parameter.kind,
+      );
+    }).toList();
+  }
+
   NullabilitySuffix _getNullabilitySuffix(bool hasQuestion) {
     if (hasQuestion) {
       return NullabilitySuffix.question;
diff --git a/pkg/analyzer/lib/src/summary2/reference_resolver.dart b/pkg/analyzer/lib/src/summary2/reference_resolver.dart
index 3e93c70..0ebc307 100644
--- a/pkg/analyzer/lib/src/summary2/reference_resolver.dart
+++ b/pkg/analyzer/lib/src/summary2/reference_resolver.dart
@@ -7,8 +7,10 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/src/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/element/element.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/dart/resolver/scope.dart';
@@ -34,7 +36,6 @@
   final TypeSystemImpl _typeSystem;
   final NodesToBuildType nodesToBuildType;
   final LinkedElementFactory elementFactory;
-  final LibraryElement _libraryElement;
   final Reference unitReference;
 
   /// Indicates whether the library is opted into NNBD.
@@ -52,11 +53,11 @@
   ReferenceResolver(
     this.nodesToBuildType,
     this.elementFactory,
-    this._libraryElement,
+    LibraryElement libraryElement,
     this.unitReference,
     this.isNNBD,
     this.scope,
-  )   : _typeSystem = _libraryElement.typeSystem,
+  )   : _typeSystem = libraryElement.typeSystem,
         reference = unitReference;
 
   @override
@@ -74,7 +75,7 @@
     node.name.staticElement = element;
 
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(scope, element);
+    scope = TypeParameterScope(scope, element.typeParameters);
 
     node.typeParameters?.accept(this);
     node.extendsClause?.accept(this);
@@ -109,9 +110,9 @@
 
     ClassElementImpl element = reference.element;
     node.name.staticElement = element;
+
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(scope, element);
-    scope = ClassScope(scope, element);
+    scope = TypeParameterScope(scope, element.typeParameters);
     LinkingNodeContext(node, scope);
 
     node.typeParameters?.accept(this);
@@ -143,10 +144,10 @@
       reference,
       node,
     );
+    (node as ConstructorDeclarationImpl).declaredElement = element;
 
-    var functionScope = FunctionScope(scope, element);
-    functionScope.defineParameters();
-    LinkingNodeContext(node, functionScope);
+    scope = TypeParameterScope(scope, element.typeParameters);
+    LinkingNodeContext(node, scope);
 
     node.parameters?.accept(this);
     node.initializers.accept(
@@ -188,7 +189,7 @@
     node.name?.staticElement = element;
 
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(scope, element);
+    scope = TypeParameterScope(scope, element.typeParameters);
 
     node.typeParameters?.accept(this);
     node.extendedType.accept(this);
@@ -223,18 +224,15 @@
     reference = reference.getChild('@parameter').getChild(name);
     reference.node = node;
 
-    var element = ParameterElementImpl.forLinkedNode(
+    var element = FieldFormalParameterElementImpl.forLinkedNode(
       outerReference.element,
       reference,
       node,
     );
     node.identifier.staticElement = element;
-    _createTypeParameterElements(node.typeParameters);
 
-    scope = EnclosedScope(scope);
-    for (var typeParameter in element.typeParameters) {
-      scope.define(typeParameter);
-    }
+    _createTypeParameterElements(node.typeParameters);
+    scope = TypeParameterScope(scope, element.typeParameters);
 
     node.type?.accept(this);
     node.typeParameters?.accept(this);
@@ -268,8 +266,9 @@
 
     ExecutableElementImpl element = reference.element;
     node.name.staticElement = element;
+
     _createTypeParameterElements(node.functionExpression.typeParameters);
-    scope = FunctionScope(scope, element);
+    scope = TypeParameterScope(outerScope, element.typeParameters);
     LinkingNodeContext(node, scope);
 
     node.returnType?.accept(this);
@@ -296,8 +295,9 @@
 
     GenericTypeAliasElementImpl element = reference.element;
     node.name.staticElement = element;
+
     _createTypeParameterElements(node.typeParameters);
-    scope = FunctionTypeScope(outerScope, element);
+    scope = TypeParameterScope(outerScope, element.typeParameters);
 
     node.returnType?.accept(this);
     node.typeParameters?.accept(this);
@@ -327,12 +327,9 @@
       node,
     );
     node.identifier.staticElement = element;
-    _createTypeParameterElements(node.typeParameters);
 
-    scope = EnclosedScope(scope);
-    for (var typeParameter in element.typeParameters) {
-      scope.define(typeParameter);
-    }
+    _createTypeParameterElements(node.typeParameters);
+    scope = TypeParameterScope(scope, element.typeParameters);
 
     node.returnType?.accept(this);
     node.typeParameters?.accept(this);
@@ -360,8 +357,9 @@
       node,
     );
     (node as GenericFunctionTypeImpl).declaredElement = element;
+
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(outerScope, element);
+    scope = TypeParameterScope(outerScope, element.typeParameters);
 
     node.returnType?.accept(this);
     node.typeParameters?.accept(this);
@@ -386,8 +384,9 @@
 
     GenericTypeAliasElementImpl element = reference.element;
     node.name.staticElement = element;
+
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(outerScope, element);
+    scope = TypeParameterScope(outerScope, element.typeParameters);
 
     node.typeParameters?.accept(this);
     node.functionType?.accept(this);
@@ -425,7 +424,8 @@
     );
     node.name.staticElement = element;
     _createTypeParameterElements(node.typeParameters);
-    scope = FunctionScope(scope, element);
+
+    scope = TypeParameterScope(scope, element.typeParameters);
     LinkingNodeContext(node, scope);
 
     node.returnType?.accept(this);
@@ -449,7 +449,7 @@
     node.name.staticElement = element;
 
     _createTypeParameterElements(node.typeParameters);
-    scope = TypeParameterScope(scope, element);
+    scope = TypeParameterScope(scope, element.typeParameters);
 
     node.typeParameters?.accept(this);
     node.onClause?.accept(this);
@@ -498,13 +498,13 @@
       return;
     }
 
-    var element = scope.lookup(typeName, _libraryElement);
+    var element = scope.lookupIdentifier(typeName);
     if (typeName is SimpleIdentifier) {
       typeName.staticElement = element;
     } else if (typeName is PrefixedIdentifier) {
       typeName.identifier.staticElement = element;
       SimpleIdentifier prefix = typeName.prefix;
-      prefix.staticElement = scope.lookup(prefix, _libraryElement);
+      prefix.staticElement = scope.lookupIdentifier(prefix);
     }
 
     node.typeArguments?.accept(this);
diff --git a/pkg/analyzer/lib/src/summary2/scope.dart b/pkg/analyzer/lib/src/summary2/scope.dart
index b9da45d..11d7d60 100644
--- a/pkg/analyzer/lib/src/summary2/scope.dart
+++ b/pkg/analyzer/lib/src/summary2/scope.dart
@@ -16,7 +16,7 @@
     map[name] = reference;
   }
 
-  void forEach(Function(String name, Reference reference) f) {
+  void forEach(void Function(String name, Reference reference) f) {
     map.forEach(f);
   }
 
diff --git a/pkg/analyzer/lib/src/summary2/top_level_inference.dart b/pkg/analyzer/lib/src/summary2/top_level_inference.dart
index 20ab4a3..2bd5727 100644
--- a/pkg/analyzer/lib/src/summary2/top_level_inference.dart
+++ b/pkg/analyzer/lib/src/summary2/top_level_inference.dart
@@ -5,12 +5,12 @@
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_demotion.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/generated/element_type_provider.dart';
 import 'package:analyzer/src/generated/resolver.dart';
 import 'package:analyzer/src/summary/format.dart';
diff --git a/pkg/analyzer/lib/src/summary2/types_builder.dart b/pkg/analyzer/lib/src/summary2/types_builder.dart
index 517f976..5248e64 100644
--- a/pkg/analyzer/lib/src/summary2/types_builder.dart
+++ b/pkg/analyzer/lib/src/summary2/types_builder.dart
@@ -8,6 +8,7 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
+import 'package:analyzer/src/dart/ast/extensions.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
@@ -55,24 +56,8 @@
     NullabilitySuffix nullabilitySuffix,
   ) {
     var returnType = returnTypeNode?.type ?? _dynamicType;
-
-    List<TypeParameterElement> typeParameters;
-    if (typeParameterList != null) {
-      typeParameters = typeParameterList.typeParameters
-          .map<TypeParameterElement>((p) => p.declaredElement)
-          .toList();
-    } else {
-      typeParameters = const <TypeParameterElement>[];
-    }
-
-    var formalParameters = parameterList.parameters.map((parameter) {
-      return ParameterElementImpl.synthetic(
-        parameter.identifier?.name ?? '',
-        _getType(parameter),
-        // ignore: deprecated_member_use_from_same_package
-        parameter.kind,
-      );
-    }).toList();
+    var typeParameters = _typeParameters(typeParameterList);
+    var formalParameters = _formalParameters(parameterList);
 
     return FunctionTypeImpl(
       typeFormals: typeParameters,
@@ -156,6 +141,16 @@
     }
   }
 
+  List<ParameterElementImpl> _formalParameters(FormalParameterList node) {
+    return node.parameters.asImpl.map((parameter) {
+      return ParameterElementImpl.synthetic(
+        parameter.identifier?.name ?? '',
+        _getType(parameter),
+        parameter.kind,
+      );
+    }).toList();
+  }
+
   void _functionTypeAlias(FunctionTypeAlias node) {
     var returnTypeNode = node.returnType;
     LazyAst.setReturnType(node, returnTypeNode?.type ?? _dynamicType);
@@ -188,6 +183,16 @@
     }
   }
 
+  List<TypeParameterElement> _typeParameters(TypeParameterList node) {
+    if (node == null) {
+      return const <TypeParameterElement>[];
+    }
+
+    return node.typeParameters
+        .map<TypeParameterElement>((p) => p.declaredElement)
+        .toList();
+  }
+
   static DartType _getType(FormalParameter node) {
     if (node is DefaultFormalParameter) {
       return _getType(node.parameter);
diff --git a/pkg/analyzer/lib/src/task/strong/checker.dart b/pkg/analyzer/lib/src/task/strong/checker.dart
index 0d1d5b3..00cc152 100644
--- a/pkg/analyzer/lib/src/task/strong/checker.dart
+++ b/pkg/analyzer/lib/src/task/strong/checker.dart
@@ -17,7 +17,8 @@
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/error/codes.dart' show StrongModeCode;
+import 'package:analyzer/src/error/codes.dart'
+    show CompileTimeErrorCode, StrongModeCode;
 import 'package:analyzer/src/summary/idl.dart';
 
 /// Given an [expression] and a corresponding [typeSystem] and [typeProvider],
@@ -174,9 +175,7 @@
       checkAssignment(element.expression, expressionCastType);
 
       var exprType = element.expression.staticType;
-      var asIterableType = exprType is InterfaceTypeImpl
-          ? exprType.asInstanceOf(typeProvider.iterableElement)
-          : null;
+      var asIterableType = exprType.asInstanceOf(typeProvider.iterableElement);
       var elementType =
           asIterableType == null ? null : asIterableType.typeArguments[0];
       // Items in the spread will then potentially be downcast to the expected
@@ -213,9 +212,7 @@
       checkAssignment(element.expression, expressionCastType);
 
       var exprType = element.expression.staticType;
-      var asMapType = exprType is InterfaceTypeImpl
-          ? exprType.asInstanceOf(typeProvider.mapElement)
-          : null;
+      var asMapType = exprType.asInstanceOf(typeProvider.mapElement);
 
       var elementKeyType =
           asMapType == null ? null : asMapType.typeArguments[0];
@@ -845,11 +842,9 @@
 
   DartType _getInstanceTypeArgument(
       DartType expressionType, ClassElement instanceType) {
-    if (expressionType is InterfaceTypeImpl) {
-      var asInstanceType = expressionType.asInstanceOf(instanceType);
-      if (asInstanceType != null) {
-        return asInstanceType.typeArguments[0];
-      }
+    var asInstanceType = expressionType.asInstanceOf(instanceType);
+    if (asInstanceType != null) {
+      return asInstanceType.typeArguments[0];
     }
     return null;
   }
@@ -918,9 +913,9 @@
   void _recordImplicitCast(Expression expr, DartType to,
       {DartType from,
       bool opAssign = false,
-      forSpread = false,
-      forSpreadKey = false,
-      forSpreadValue = false}) {
+      bool forSpread = false,
+      bool forSpreadKey = false,
+      bool forSpreadValue = false}) {
     // If this is an implicit tearoff, we need to mark the cast, but we don't
     // want to warn if it's a legal subtype.
     if (from is InterfaceType && rules.acceptsFunctionType(to)) {
@@ -940,28 +935,29 @@
         // runtime.
         if (expr is ListLiteral) {
           _recordMessage(
-              expr, StrongModeCode.INVALID_CAST_LITERAL_LIST, [from, to]);
+              expr, CompileTimeErrorCode.INVALID_CAST_LITERAL_LIST, [from, to]);
         } else if (expr is SetOrMapLiteral) {
           if (expr.isMap) {
-            _recordMessage(
-                expr, StrongModeCode.INVALID_CAST_LITERAL_MAP, [from, to]);
+            _recordMessage(expr, CompileTimeErrorCode.INVALID_CAST_LITERAL_MAP,
+                [from, to]);
           } else if (expr.isSet) {
-            _recordMessage(
-                expr, StrongModeCode.INVALID_CAST_LITERAL_SET, [from, to]);
+            _recordMessage(expr, CompileTimeErrorCode.INVALID_CAST_LITERAL_SET,
+                [from, to]);
           } else {
             // This should only happen when the code is invalid, in which case
             // the error should have been reported elsewhere.
           }
         } else {
-          _recordMessage(
-              expr, StrongModeCode.INVALID_CAST_LITERAL, [expr, from, to]);
+          _recordMessage(expr, CompileTimeErrorCode.INVALID_CAST_LITERAL,
+              [expr, from, to]);
         }
         return;
       }
 
       if (expr is FunctionExpression) {
+        // TODO(srawlins): Add _any_ test that shows this code is reported.
         _recordMessage(
-            expr, StrongModeCode.INVALID_CAST_FUNCTION_EXPR, [from, to]);
+            expr, CompileTimeErrorCode.INVALID_CAST_FUNCTION_EXPR, [from, to]);
         return;
       }
 
@@ -971,7 +967,7 @@
           // fromT should be an exact type - this will almost certainly fail at
           // runtime.
           _recordMessage(
-              expr, StrongModeCode.INVALID_CAST_NEW_EXPR, [from, to]);
+              expr, CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, [from, to]);
           return;
         }
       }
@@ -981,8 +977,8 @@
         _recordMessage(
             expr,
             e is MethodElement
-                ? StrongModeCode.INVALID_CAST_METHOD
-                : StrongModeCode.INVALID_CAST_FUNCTION,
+                ? CompileTimeErrorCode.INVALID_CAST_METHOD
+                : CompileTimeErrorCode.INVALID_CAST_FUNCTION,
             [e.name, from, to]);
         return;
       }
@@ -1067,18 +1063,7 @@
   final CodeChecker _codeChecker;
   final String _name;
 
-  /// A flag indicating whether certain diagnostics related to top-level
-  /// elements should be produced. The diagnostics are the ones introduced by
-  /// the analyzer to signal to users when the version of type inference
-  /// performed by the analyzer was unable to accurately infer type information.
-  /// The implementation of type inference used by the task model still has
-  /// these deficiencies, but the implementation used by the driver does not.
-  // TODO(brianwilkerson) Remove this field when the task model has been
-  // removed.
-  final bool flagTopLevel;
-
-  _TopLevelInitializerValidator(this._codeChecker, this._name,
-      {this.flagTopLevel = true});
+  _TopLevelInitializerValidator(this._codeChecker, this._name);
 
   void validateHasType(AstNode n, PropertyAccessorElement e) {
     if (e.hasImplicitReturnType) {
@@ -1111,7 +1096,7 @@
       if (e is PropertyAccessorElement) {
         if (e.isStatic) {
           validateHasType(n, e);
-        } else if (e.hasImplicitReturnType && flagTopLevel) {
+        } else if (e.hasImplicitReturnType) {
           _codeChecker._recordMessage(
               n, StrongModeCode.TOP_LEVEL_INSTANCE_GETTER, [_name, e.name]);
         }
@@ -1119,7 +1104,7 @@
           e is ExecutableElement &&
           e.kind == ElementKind.METHOD &&
           !e.isStatic) {
-        if (_hasAnyImplicitType(e) && flagTopLevel) {
+        if (_hasAnyImplicitType(e)) {
           _codeChecker._recordMessage(
               n, StrongModeCode.TOP_LEVEL_INSTANCE_METHOD, [_name, e.name]);
         }
@@ -1223,16 +1208,14 @@
     if (method is ExecutableElement) {
       if (method.kind == ElementKind.METHOD &&
           !method.isStatic &&
-          method.hasImplicitReturnType &&
-          flagTopLevel) {
+          method.hasImplicitReturnType) {
         _codeChecker._recordMessage(node,
             StrongModeCode.TOP_LEVEL_INSTANCE_METHOD, [_name, method.name]);
       }
       if (node.typeArguments == null && method.typeParameters.isNotEmpty) {
         if (method.kind == ElementKind.METHOD &&
             !method.isStatic &&
-            _anyParameterHasImplicitType(method) &&
-            flagTopLevel) {
+            _anyParameterHasImplicitType(method)) {
           _codeChecker._recordMessage(node,
               StrongModeCode.TOP_LEVEL_INSTANCE_METHOD, [_name, method.name]);
         }
diff --git a/pkg/analyzer/lib/src/test_utilities/find_node.dart b/pkg/analyzer/lib/src/test_utilities/find_node.dart
index 65daa02..07b410e 100644
--- a/pkg/analyzer/lib/src/test_utilities/find_node.dart
+++ b/pkg/analyzer/lib/src/test_utilities/find_node.dart
@@ -259,6 +259,10 @@
     return _node(search, (n) => n is Statement);
   }
 
+  StringInterpolation stringInterpolation(String search) {
+    return _node(search, (n) => n is StringInterpolation);
+  }
+
   StringLiteral stringLiteral(String search) {
     return _node(search, (n) => n is StringLiteral);
   }
diff --git a/pkg/analyzer/lib/src/util/glob.dart b/pkg/analyzer/lib/src/util/glob.dart
index 2edfd89..3fa8a1a9 100644
--- a/pkg/analyzer/lib/src/util/glob.dart
+++ b/pkg/analyzer/lib/src/util/glob.dart
@@ -39,7 +39,7 @@
   int get hashCode => _pattern.hashCode;
 
   @override
-  bool operator ==(other) => other is Glob && _pattern == other._pattern;
+  bool operator ==(Object other) => other is Glob && _pattern == other._pattern;
 
   /// Return `true` if the given [path] matches this glob.
   /// The given [path] must use the same [_separator] as the glob.
diff --git a/pkg/analyzer/lib/src/util/lru_map.dart b/pkg/analyzer/lib/src/util/lru_map.dart
index 006b02c..050663e 100644
--- a/pkg/analyzer/lib/src/util/lru_map.dart
+++ b/pkg/analyzer/lib/src/util/lru_map.dart
@@ -5,7 +5,7 @@
 import 'dart:collection';
 
 /// This handler is notified when an item is evicted from the cache.
-typedef EvictionHandler<K, V> = Function(K key, V value);
+typedef EvictionHandler<K, V> = void Function(K key, V value);
 
 /// A hash-table based cache implementation.
 ///
diff --git a/pkg/analyzer/lib/src/util/performance/operation_performance.dart b/pkg/analyzer/lib/src/util/performance/operation_performance.dart
index 1764514..c2ce9ae 100644
--- a/pkg/analyzer/lib/src/util/performance/operation_performance.dart
+++ b/pkg/analyzer/lib/src/util/performance/operation_performance.dart
@@ -9,6 +9,10 @@
   /// The child operations, might be empty.
   List<OperationPerformance> get children;
 
+  /// The data attachments, for non-timing data, e.g. how many files were read,
+  /// or how many bytes were processed.
+  List<OperationPerformanceData> get data;
+
   /// The duration of this operation, including its children.
   Duration get elapsed;
 
@@ -27,6 +31,42 @@
   });
 }
 
+/// The data attachment for a [OperationPerformance].
+abstract class OperationPerformanceData<T> {
+  String get name;
+
+  T get value;
+}
+
+abstract class OperationPerformanceDataImpl<T>
+    implements OperationPerformanceData<T> {
+  @override
+  final String name;
+
+  OperationPerformanceDataImpl(this.name);
+
+  @override
+  String toString() {
+    return '$name: $value';
+  }
+}
+
+class OperationPerformanceDataImpl_int
+    extends OperationPerformanceDataImpl<int> {
+  @override
+  int value = 0;
+
+  OperationPerformanceDataImpl_int(String name) : super(name);
+
+  void add(int item) {
+    value += item;
+  }
+
+  void increment() {
+    value++;
+  }
+}
+
 class OperationPerformanceImpl implements OperationPerformance {
   @override
   final String name;
@@ -34,6 +74,8 @@
   final Stopwatch _timer = Stopwatch();
   final List<OperationPerformance> _children = [];
 
+  final Map<String, OperationPerformanceData<Object>> _data = {};
+
   OperationPerformanceImpl(this.name);
 
   @override
@@ -42,6 +84,11 @@
   }
 
   @override
+  List<OperationPerformanceData<Object>> get data {
+    return _data.values.toList();
+  }
+
+  @override
   Duration get elapsed {
     return _timer.elapsed;
   }
@@ -66,6 +113,13 @@
     );
   }
 
+  OperationPerformanceDataImpl_int getDataInt(String name) {
+    return _data.putIfAbsent(
+      name,
+      () => OperationPerformanceDataImpl_int(name),
+    );
+  }
+
   /// Run the [operation] as a child with the given [name].
   ///
   /// If there is no such child, a new one is created, with a new timer.
@@ -112,8 +166,17 @@
   }
 
   @override
-  void write({StringBuffer buffer, String indent = ''}) {
-    buffer.writeln('$indent${toString()}');
+  void write({@required StringBuffer buffer, String indent = ''}) {
+    buffer.write('$indent${toString()}');
+
+    if (_data.isNotEmpty) {
+      var sortedNames = _data.keys.toList()..sort();
+      var sortedData = sortedNames.map((name) => _data[name]);
+      var dataStr = sortedData.map((e) => '$e').join(', ');
+      buffer.write('($dataStr)');
+    }
+
+    buffer.writeln();
 
     var childIndent = '$indent  ';
     for (var child in children) {
diff --git a/pkg/analyzer/lib/src/workspace/bazel.dart b/pkg/analyzer/lib/src/workspace/bazel.dart
index 5b6bd92..22e4b56 100644
--- a/pkg/analyzer/lib/src/workspace/bazel.dart
+++ b/pkg/analyzer/lib/src/workspace/bazel.dart
@@ -59,6 +59,13 @@
   @override
   Source resolveAbsolute(Uri uri, [Uri actualUri]) {
     return _sourceCache.putIfAbsent(uri, () {
+      if (uri.scheme == 'file') {
+        var pathRelativeToRoot = _workspace._relativeToRoot(uri.path);
+        if (pathRelativeToRoot == null) return null;
+        var fullFilePath = _context.join(_workspace.root, pathRelativeToRoot);
+        File file = _workspace.findFile(fullFilePath);
+        return file?.createSource(uri);
+      }
       if (uri.scheme != 'package') {
         return null;
       }
@@ -306,6 +313,32 @@
     }
   }
 
+  String _relativeToRoot(String p) {
+    path.Context context = provider.pathContext;
+    // genfiles
+    if (genfiles != null && context.isWithin(genfiles, p)) {
+      return context.relative(p, from: genfiles);
+    }
+    // bin
+    for (String bin in binPaths) {
+      if (context.isWithin(bin, p)) {
+        return context.relative(p, from: bin);
+      }
+    }
+    // READONLY
+    if (readonly != null) {
+      if (context.isWithin(readonly, p)) {
+        return context.relative(p, from: readonly);
+      }
+    }
+    // Not generated
+    if (context.isWithin(root, p)) {
+      return context.relative(p, from: root);
+    }
+    // Failed reverse lookup
+    return null;
+  }
+
   /// Find the Bazel workspace that contains the given [filePath].
   ///
   /// This method walks up the file system from [filePath], looking for various
diff --git a/pkg/analyzer/pubspec.yaml b/pkg/analyzer/pubspec.yaml
index 4044ff8..be7867b 100644
--- a/pkg/analyzer/pubspec.yaml
+++ b/pkg/analyzer/pubspec.yaml
@@ -1,5 +1,5 @@
 name: analyzer
-version: 0.39.13-dev
+version: 0.39.15-dev
 description: This package provides a library that performs static analysis of Dart code.
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/analyzer
 
@@ -7,9 +7,10 @@
   sdk: '>=2.6.0 <3.0.0'
 
 dependencies:
-  _fe_analyzer_shared: ^5.0.0
+  _fe_analyzer_shared: ^6.0.0
   args: ^1.0.0
   charcode: ^1.1.0
+  cli_util: ^0.1.4
   collection: ^1.10.1
   convert: ^2.0.0
   crypto: ^2.0.0
diff --git a/pkg/analyzer/test/dart/analysis/test_all.dart b/pkg/analyzer/test/dart/analysis/test_all.dart
index a7e9797..40e2965 100644
--- a/pkg/analyzer/test/dart/analysis/test_all.dart
+++ b/pkg/analyzer/test/dart/analysis/test_all.dart
@@ -7,7 +7,7 @@
 import 'from_environment_evaluator_test.dart' as declared_variables;
 import 'utilities_test.dart' as utilities;
 
-main() {
+void main() {
   defineReflectiveSuite(() {
     declared_variables.main();
     utilities.main();
diff --git a/pkg/analyzer/test/dart/ast/ast_test.dart b/pkg/analyzer/test/dart/ast/ast_test.dart
index 3fdfab1..bad835b 100644
--- a/pkg/analyzer/test/dart/ast/ast_test.dart
+++ b/pkg/analyzer/test/dart/ast/ast_test.dart
@@ -25,6 +25,7 @@
     defineReflectiveTests(ConstructorDeclarationTest);
     defineReflectiveTests(FieldFormalParameterTest);
     defineReflectiveTests(IndexExpressionTest);
+    defineReflectiveTests(InterpolationStringTest);
     defineReflectiveTests(MethodDeclarationTest);
     defineReflectiveTests(MethodInvocationTest);
     defineReflectiveTests(NodeListTest);
@@ -222,7 +223,9 @@
 class IndexExpressionTest {
   void test_inGetterContext_assignment_compound_left() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b] += c
     AstTestFactory.assignmentExpression(
         expression, TokenType.PLUS_EQ, AstTestFactory.identifier3("c"));
@@ -231,7 +234,9 @@
 
   void test_inGetterContext_assignment_simple_left() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b] = c
     AstTestFactory.assignmentExpression(
         expression, TokenType.EQ, AstTestFactory.identifier3("c"));
@@ -240,7 +245,9 @@
 
   void test_inGetterContext_nonAssignment() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b] + c
     AstTestFactory.binaryExpression(
         expression, TokenType.PLUS, AstTestFactory.identifier3("c"));
@@ -249,7 +256,9 @@
 
   void test_inSetterContext_assignment_compound_left() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b] += c
     AstTestFactory.assignmentExpression(
         expression, TokenType.PLUS_EQ, AstTestFactory.identifier3("c"));
@@ -258,7 +267,9 @@
 
   void test_inSetterContext_assignment_compound_right() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // c += a[b]
     AstTestFactory.assignmentExpression(
         AstTestFactory.identifier3("c"), TokenType.PLUS_EQ, expression);
@@ -267,7 +278,9 @@
 
   void test_inSetterContext_assignment_simple_left() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b] = c
     AstTestFactory.assignmentExpression(
         expression, TokenType.EQ, AstTestFactory.identifier3("c"));
@@ -276,7 +289,9 @@
 
   void test_inSetterContext_assignment_simple_right() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // c = a[b]
     AstTestFactory.assignmentExpression(
         AstTestFactory.identifier3("c"), TokenType.EQ, expression);
@@ -285,7 +300,9 @@
 
   void test_inSetterContext_nonAssignment() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     AstTestFactory.binaryExpression(
         expression, TokenType.PLUS, AstTestFactory.identifier3("c"));
     // a[b] + cc
@@ -294,7 +311,9 @@
 
   void test_inSetterContext_postfix_bang() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // a[b]!
     AstTestFactory.postfixExpression(expression, TokenType.BANG);
     expect(expression.inSetterContext(), isFalse);
@@ -302,7 +321,9 @@
 
   void test_inSetterContext_postfix_plusPlus() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     AstTestFactory.postfixExpression(expression, TokenType.PLUS_PLUS);
     // a[b]++
     expect(expression.inSetterContext(), isTrue);
@@ -310,7 +331,9 @@
 
   void test_inSetterContext_prefix_bang() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // !a[b]
     AstTestFactory.prefixExpression(TokenType.BANG, expression);
     expect(expression.inSetterContext(), isFalse);
@@ -318,7 +341,9 @@
 
   void test_inSetterContext_prefix_minusMinus() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // --a[b]
     AstTestFactory.prefixExpression(TokenType.MINUS_MINUS, expression);
     expect(expression.inSetterContext(), isTrue);
@@ -326,7 +351,9 @@
 
   void test_inSetterContext_prefix_plusPlus() {
     IndexExpression expression = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("b"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("b"),
+    );
     // ++a[b]
     AstTestFactory.prefixExpression(TokenType.PLUS_PLUS, expression);
     expect(expression.inSetterContext(), isTrue);
@@ -360,30 +387,201 @@
 
   void test_isNullAware_false() {
     final expression = AstTestFactory.indexExpression(
-        AstTestFactory.nullLiteral(),
-        AstTestFactory.nullLiteral(),
-        TokenType.OPEN_SQUARE_BRACKET);
+      target: AstTestFactory.nullLiteral(),
+      index: AstTestFactory.nullLiteral(),
+    );
     expect(expression.isNullAware, isFalse);
   }
 
   void test_isNullAware_regularIndex() {
     final expression = AstTestFactory.indexExpression(
-        AstTestFactory.nullLiteral(),
-        AstTestFactory.nullLiteral(),
-        TokenType.OPEN_SQUARE_BRACKET);
+      target: AstTestFactory.nullLiteral(),
+      index: AstTestFactory.nullLiteral(),
+    );
     expect(expression.isNullAware, isFalse);
   }
 
   void test_isNullAware_true() {
     final expression = AstTestFactory.indexExpression(
-        AstTestFactory.nullLiteral(),
-        AstTestFactory.nullLiteral(),
-        TokenType.QUESTION_PERIOD_OPEN_SQUARE_BRACKET);
+      target: AstTestFactory.nullLiteral(),
+      hasQuestion: true,
+      index: AstTestFactory.nullLiteral(),
+    );
     expect(expression.isNullAware, isTrue);
   }
 }
 
 @reflectiveTest
+class InterpolationStringTest extends ParserTestCase {
+  InterpolationString interpolationString(
+      String lexeme, String value, bool isFirst, bool isLast) {
+    var node = AstTestFactory.interpolationString(lexeme, value);
+    var nodes = <InterpolationElement>[
+      if (!isFirst) AstTestFactory.interpolationString("'first", "first"),
+      node,
+      if (!isLast) AstTestFactory.interpolationString("last'", "last")
+    ];
+    var parent = AstTestFactory.string(nodes);
+    assert(node.parent == parent);
+    return node;
+  }
+
+  void test_contentsOffset_doubleQuote_first() {
+    var node = interpolationString('"foo', "foo", true, true);
+    expect(node.contentsOffset, '"'.length);
+    expect(node.contentsEnd, '"'.length + "foo".length);
+  }
+
+  void test_contentsOffset_doubleQuote_firstLast() {
+    var node = interpolationString('"foo"', "foo", true, true);
+    expect(node.contentsOffset, '"'.length);
+    expect(node.contentsEnd, '"'.length + "foo".length);
+  }
+
+  void test_contentsOffset_doubleQuote_last() {
+    var node = interpolationString('foo"', "foo", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo".length);
+  }
+
+  void test_contentsOffset_doubleQuote_last_empty() {
+    var node = interpolationString('"', "", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, 0);
+  }
+
+  void test_contentsOffset_doubleQuote_last_unterminated() {
+    var node = interpolationString('foo', "foo", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo".length);
+  }
+
+  void test_contentsOffset_doubleQuote_multiline_first() {
+    var node = interpolationString('"""\nfoo\n', "foo\n", true, true);
+    expect(node.contentsOffset, '"""\n'.length);
+    expect(node.contentsEnd, '"""\n'.length + "foo\n".length);
+  }
+
+  void test_contentsOffset_doubleQuote_multiline_firstLast() {
+    var node = interpolationString('"""\nfoo\n"""', "foo\n", true, true);
+    expect(node.contentsOffset, '"""\n'.length);
+    expect(node.contentsEnd, '"""\n'.length + "foo\n".length);
+  }
+
+  void test_contentsOffset_doubleQuote_multiline_last() {
+    var node = interpolationString('foo\n"""', "foo\n", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo\n".length);
+  }
+
+  void test_contentsOffset_doubleQuote_multiline_last_empty() {
+    var node = interpolationString('"""', "", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, 0);
+  }
+
+  void test_contentsOffset_doubleQuote_multiline_last_unterminated() {
+    var node = interpolationString('foo\n', "foo\n", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo\n".length);
+  }
+
+  void test_contentsOffset_escapeCharacters() {
+    // Contents offset cannot use 'value' string, because of escape sequences.
+    var node = interpolationString(r'"foo\nbar"', "foo\nbar", true, true);
+    expect(node.contentsOffset, '"'.length);
+    expect(node.contentsEnd, '"'.length + "foo\\nbar".length);
+  }
+
+  void test_contentsOffset_middle() {
+    var node = interpolationString("foo", "foo", false, false);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo".length);
+  }
+
+  void test_contentsOffset_middle_quoteBegin() {
+    // This occurs in, for instance, `"$a'foo$b"`
+    var node = interpolationString("'foo", "'foo", false, false);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "'foo".length);
+  }
+
+  void test_contentsOffset_middle_quoteBeginEnd() {
+    // This occurs in, for instance, `"$a'foo'$b"`
+    var node = interpolationString("'foo'", "'foo'", false, false);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "'foo'".length);
+  }
+
+  void test_contentsOffset_middle_quoteEnd() {
+    // This occurs in, for instance, `"${a}foo'$b"`
+    var node = interpolationString("foo'", "foo'", false, false);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo'".length);
+  }
+
+  void test_contentsOffset_singleQuote_first() {
+    var node = interpolationString("'foo", "foo", true, true);
+    expect(node.contentsOffset, "'".length);
+    expect(node.contentsEnd, "'".length + "foo".length);
+  }
+
+  void test_contentsOffset_singleQuote_firstLast() {
+    var node = interpolationString("'foo'", "foo", true, true);
+    expect(node.contentsOffset, "'".length);
+    expect(node.contentsEnd, "'".length + "foo".length);
+  }
+
+  void test_contentsOffset_singleQuote_last() {
+    var node = interpolationString("foo'", "foo", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo".length);
+  }
+
+  void test_contentsOffset_singleQuote_last_empty() {
+    var node = interpolationString("'", "", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, 0);
+  }
+
+  void test_contentsOffset_singleQuote_last_unterminated() {
+    var node = interpolationString("foo", "foo", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo".length);
+  }
+
+  void test_contentsOffset_singleQuote_multiline_first() {
+    var node = interpolationString("'''\nfoo\n", "foo\n", true, true);
+    expect(node.contentsOffset, "'''\n".length);
+    expect(node.contentsEnd, "'''\n".length + "foo\n".length);
+  }
+
+  void test_contentsOffset_singleQuote_multiline_firstLast() {
+    var node = interpolationString("'''\nfoo\n'''", "foo\n", true, true);
+    expect(node.contentsOffset, "'''\n".length);
+    expect(node.contentsEnd, "'''\n".length + "foo\n".length);
+  }
+
+  void test_contentsOffset_singleQuote_multiline_last() {
+    var node = interpolationString("foo\n'''", "foo\n", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo\n".length);
+  }
+
+  void test_contentsOffset_singleQuote_multiline_last_empty() {
+    var node = interpolationString("'''", "", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, 0);
+  }
+
+  void test_contentsOffset_singleQuote_multiline_last_unterminated() {
+    var node = interpolationString("foo\n", "foo\n", false, true);
+    expect(node.contentsOffset, 0);
+    expect(node.contentsEnd, "foo\n".length);
+  }
+}
+
+@reflectiveTest
 class MethodDeclarationTest {
   void test_firstTokenAfterCommentAndMetadata_external() {
     MethodDeclaration declaration =
diff --git a/pkg/analyzer/test/generated/compile_time_error_code.dart b/pkg/analyzer/test/generated/compile_time_error_code.dart
index 6840ac0..761b1fb 100644
--- a/pkg/analyzer/test/generated/compile_time_error_code.dart
+++ b/pkg/analyzer/test/generated/compile_time_error_code.dart
@@ -5,102 +5,12 @@
 import 'dart:async';
 
 import 'package:analyzer/dart/analysis/declared_variables.dart';
-import 'package:analyzer/error/error.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
-import 'package:test/test.dart' show expect;
-import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../src/dart/resolution/driver_resolution.dart';
 
 class CompileTimeErrorCodeTestBase extends DriverResolutionTest {
-  @failingTest
-  test_accessPrivateEnumField() async {
-    await assertErrorsInCode(r'''
-enum E { ONE }
-String name(E e) {
-  return e._name;
-}
-''', [
-      error(CompileTimeErrorCode.ACCESS_PRIVATE_ENUM_FIELD, 45, 5),
-    ]);
-  }
-
-  test_annotationWithNotClass() async {
-    await assertErrorsInCode('''
-class Property {
-  final int value;
-  const Property(this.value);
-}
-
-const Property property = const Property(42);
-
-@property(123)
-main() {
-}
-''', [
-      error(CompileTimeErrorCode.ANNOTATION_WITH_NON_CLASS, 117, 8),
-    ]);
-  }
-
-  test_annotationWithNotClass_prefixed() async {
-    newFile("/test/lib/annotations.dart", content: r'''
-class Property {
-  final int value;
-  const Property(this.value);
-}
-
-const Property property = const Property(42);
-''');
-    await assertErrorsInCode('''
-import 'annotations.dart' as pref;
-@pref.property(123)
-main() {
-}
-''', [
-      error(CompileTimeErrorCode.ANNOTATION_WITH_NON_CLASS, 36, 13),
-    ]);
-  }
-
-  test_asyncForInWrongContext() async {
-    await assertErrorsInCode(r'''
-f(list) {
-  await for (var e in list) {
-  }
-}
-''', [
-      error(HintCode.UNUSED_LOCAL_VARIABLE, 27, 1),
-      error(CompileTimeErrorCode.ASYNC_FOR_IN_WRONG_CONTEXT, 29, 2),
-    ]);
-  }
-
-  test_awaitInWrongContext_sync() async {
-    // This test requires better error recovery than we currently have. In
-    // particular, we need to be able to distinguish between an await expression
-    // in the wrong context, and the use of 'await' as an identifier.
-    await assertErrorsInCode(r'''
-f(x) {
-  return await x;
-}
-''', [
-      error(CompileTimeErrorCode.AWAIT_IN_WRONG_CONTEXT, 16, 5),
-    ]);
-  }
-
-  test_awaitInWrongContext_syncStar() async {
-    // This test requires better error recovery than we currently have. In
-    // particular, we need to be able to distinguish between an await expression
-    // in the wrong context, and the use of 'await' as an identifier.
-    await assertErrorsInCode(r'''
-f(x) sync* {
-  yield await x;
-}
-''', [
-      error(CompileTimeErrorCode.AWAIT_IN_WRONG_CONTEXT, 21, 5),
-    ]);
-  }
-
   test_bug_23176() async {
     await assertErrorsInCode('''
 class A {
@@ -185,168 +95,6 @@
 ''');
   }
 
-  test_constConstructorWithNonConstSuper_explicit() async {
-    await assertErrorsInCode(r'''
-class A {
-  A();
-}
-class B extends A {
-  const B(): super();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 52, 7),
-    ]);
-  }
-
-  test_constConstructorWithNonConstSuper_implicit() async {
-    await assertErrorsInCode(r'''
-class A {
-  A();
-}
-class B extends A {
-  const B();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 47, 1),
-    ]);
-  }
-
-  test_constConstructorWithNonFinalField_mixin() async {
-    await assertErrorsInCode(r'''
-class A {
-  var a;
-}
-class B extends Object with A {
-  const B();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 61, 1),
-      error(
-          CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_MIXIN_WITH_FIELD, 61, 1),
-    ]);
-  }
-
-  test_constConstructorWithNonFinalField_super() async {
-    await assertErrorsInCode(r'''
-class A {
-  var a;
-}
-class B extends A {
-  const B();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 49, 1),
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 49, 1),
-    ]);
-  }
-
-  test_constConstructorWithNonFinalField_this_named() async {
-    await assertErrorsInCode(r'''
-class A {
-  int x;
-  const A.a();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 27, 3),
-    ]);
-  }
-
-  test_constConstructorWithNonFinalField_this_unnamed() async {
-    await assertErrorsInCode(r'''
-class A {
-  int x;
-  const A();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 27, 1),
-    ]);
-  }
-
-  test_constDeferredClass() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-class A {
-  const A();
-}
-''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-main() {
-  const a.A();
-}
-''', [
-      error(CompileTimeErrorCode.CONST_DEFERRED_CLASS, 65, 3),
-    ]);
-  }
-
-  test_constDeferredClass_namedConstructor() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-class A {
-  const A.b();
-}''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-main() {
-  const a.A.b();
-}''', [
-      error(CompileTimeErrorCode.CONST_DEFERRED_CLASS, 65, 5),
-    ]);
-  }
-
-  test_constEval_newInstance_constConstructor() async {
-    await assertErrorsInCode(r'''
-class A {
-  const A();
-}
-const a = new A();
-''', [
-      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 35,
-          7),
-    ]);
-  }
-
-  test_constEval_newInstance_externalFactoryConstConstructor() async {
-    // We can't evaluate "const A()" because its constructor is external.  But
-    // the code is correct--we shouldn't report an error.
-    await assertNoErrorsInCode(r'''
-class A {
-  external const factory A();
-}
-const x = const A();
-''');
-  }
-
-  test_constEval_nonStaticField_inGenericClass() async {
-    await assertErrorsInCode('''
-class C<T> {
-  const C();
-  T get t => null;
-}
-
-const x = const C().t;
-''', [
-      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 58,
-          11),
-    ]);
-  }
-
-  test_constEval_propertyExtraction_targetNotConst() async {
-    await assertErrorsInCode(r'''
-class A {
-  const A();
-  int m() => 0;
-}
-final a = const A();
-const C = a.m;
-''', [
-      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 72,
-          1),
-    ]);
-  }
-
   test_constEvalThrowsException() async {
     await assertErrorsInCode(r'''
 class C {
@@ -366,77 +114,6 @@
     ]);
   }
 
-  test_constEvalTypeBool_binary_and() async {
-    await assertErrorsInCode('''
-const _ = true && '';
-''', [
-      error(HintCode.UNUSED_ELEMENT, 6, 1),
-      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL, 10, 10),
-      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 18, 2),
-    ]);
-  }
-
-  test_constEvalTypeBool_binary_leftTrue() async {
-    await assertErrorsInCode('''
-const C = (true || 0);
-''', [
-      error(HintCode.DEAD_CODE, 19, 1),
-      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 19, 1),
-    ]);
-  }
-
-  test_constEvalTypeBool_binary_or() async {
-    await assertErrorsInCode(r'''
-const _ = false || '';
-''', [
-      error(HintCode.UNUSED_ELEMENT, 6, 1),
-      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL, 10, 11),
-      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 19, 2),
-    ]);
-  }
-
-  test_constEvalTypeBool_logicalOr_trueLeftOperand() async {
-    await assertNoErrorsInCode(r'''
-class C {
-  final int x;
-  const C({this.x}) : assert(x == null || x >= 0);
-}
-const c = const C();
-''');
-  }
-
-  test_constEvalTypeBoolNumString_equal() async {
-    await assertErrorsInCode(
-        r'''
-class A {
-  const A();
-}
-
-const num a = 0;
-const b = a == const A();
-''',
-        IsEnabledByDefault.constant_update_2018
-            ? []
-            : [
-                error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL_NUM_STRING, 53,
-                    14),
-              ]);
-  }
-
-  test_constEvalTypeBoolNumString_notEqual() async {
-    await assertErrorsInCode(r'''
-class A {
-  const A();
-}
-
-const num a = 0;
-const _ = a != const A();
-''', [
-      error(HintCode.UNUSED_ELEMENT, 49, 1),
-      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL_NUM_STRING, 53, 14),
-    ]);
-  }
-
   test_constEvalTypeInt_binary() async {
     await _check_constEvalTypeBoolOrInt_binary("a ^ ''");
     await _check_constEvalTypeBoolOrInt_binary("a & ''");
@@ -458,188 +135,6 @@
     await _check_constEvalTypeNum_binary("a % ''");
   }
 
-  test_constFormalParameter_fieldFormalParameter() async {
-    await assertErrorsInCode(r'''
-class A {
-  var x;
-  A(const this.x) {}
-}
-''', [
-      error(CompileTimeErrorCode.CONST_FORMAL_PARAMETER, 23, 12),
-      error(ParserErrorCode.EXTRANEOUS_MODIFIER, 23, 5),
-    ]);
-  }
-
-  test_constFormalParameter_simpleFormalParameter() async {
-    await assertErrorsInCode('''
-f(const x) {}
-''', [
-      error(CompileTimeErrorCode.CONST_FORMAL_PARAMETER, 2, 7),
-      error(ParserErrorCode.EXTRANEOUS_MODIFIER, 2, 5),
-    ]);
-  }
-
-  test_constInitializedWithNonConstValue() async {
-    await assertErrorsInCode(r'''
-f(p) {
-  const C = p;
-}
-''', [
-      error(HintCode.UNUSED_LOCAL_VARIABLE, 15, 1),
-      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 19,
-          1),
-    ]);
-  }
-
-  test_constInitializedWithNonConstValue_finalField() async {
-    // Regression test for bug #25526 which previously
-    // caused two errors to be reported.
-    await assertErrorsInCode(r'''
-class Foo {
-  final field = 0;
-  foo([int x = field]) {}
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 46, 5),
-    ]);
-  }
-
-  test_constInitializedWithNonConstValue_missingConstInListLiteral() async {
-    await assertNoErrorsInCode('''
-const List L = [0];
-''');
-  }
-
-  test_constInitializedWithNonConstValue_missingConstInMapLiteral() async {
-    await assertNoErrorsInCode('''
-const Map M = {'a' : 0};
-''');
-  }
-
-  test_constInitializedWithNonConstValueFromDeferredClass() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-const V = 1;
-''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-const B = a.V;
-''', [
-      error(
-          CompileTimeErrorCode
-              .CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE_FROM_DEFERRED_LIBRARY,
-          58,
-          3),
-    ]);
-  }
-
-  test_constInitializedWithNonConstValueFromDeferredClass_nested() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-const V = 1;
-''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-const B = a.V + 1;
-''', [
-      error(
-          CompileTimeErrorCode
-              .CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE_FROM_DEFERRED_LIBRARY,
-          58,
-          7),
-    ]);
-  }
-
-  test_constInstanceField() async {
-    await assertErrorsInCode(r'''
-class C {
-  const int f = 0;
-}
-''', [
-      error(CompileTimeErrorCode.CONST_INSTANCE_FIELD, 12, 5),
-    ]);
-  }
-
-  test_constWithNonConst() async {
-    await assertErrorsInCode(r'''
-class T {
-  T(a, b, {c, d}) {}
-}
-f() { return const T(0, 1, c: 2, d: 3); }
-''', [
-      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 46, 5),
-    ]);
-  }
-
-  test_constWithNonConst_in_const_context() async {
-    await assertErrorsInCode(r'''
-class A {
-  const A(x);
-}
-class B {
-}
-main() {
-  const A(B());
-}
-''', [
-      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 57, 3),
-    ]);
-  }
-
-  test_constWithNonConst_mixinApplication_constSuperConstructor() async {
-    await assertNoErrorsInCode(r'''
-mixin M {}
-class A {
-  const A();
-}
-class B = A with M;
-const b = const B();
-''');
-  }
-
-  test_constWithNonConst_mixinApplication_constSuperConstructor_field() async {
-    await assertErrorsInCode(r'''
-mixin M {
-  int i = 0;
-}
-class A {
-  const A();
-}
-class B = A with M;
-var b = const B();
-''', [
-      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 78, 5),
-    ]);
-  }
-
-  test_constWithNonConst_mixinApplication_constSuperConstructor_getter() async {
-    await assertNoErrorsInCode(r'''
-mixin M {
-  int get i => 0;
-}
-class A {
-  const A();
-}
-class B = A with M;
-var b = const B();
-''');
-  }
-
-  test_constWithNonConst_mixinApplication_constSuperConstructor_setter() async {
-    await assertNoErrorsInCode(r'''
-mixin M {
-  set(int i) {}
-}
-class A {
-  const A();
-}
-class B = A with M;
-var b = const B();
-''');
-  }
-
   test_constWithNonConstantArgument_annotation() async {
     await assertErrorsInCode(r'''
 class A {
@@ -654,11 +149,8 @@
     ]);
   }
 
-  @FailingTest(issue: 'https://github.com/dart-lang/sdk/issues/38352')
   test_constWithNonConstantArgument_classShadowedBySetter() async {
-    // TODO(paulberry): once this is fixed, change this test to use
-    // assertErrorsInCode and verify the exact error message(s).
-    var code = '''
+    await assertErrorsInCode(r'''
 class Annotation {
   const Annotation(Object obj);
 }
@@ -669,10 +161,10 @@
   @Annotation(Bar)
   set Bar(int value) {}
 }
-''';
-    addTestFile(code);
-    await resolveTestFile();
-    assertHasTestErrors();
+''', [
+      error(CompileTimeErrorCode.CONST_WITH_NON_CONSTANT_ARGUMENT, 94, 3),
+      error(StaticWarningCode.UNDEFINED_IDENTIFIER, 94, 3),
+    ]);
   }
 
   test_constWithNonConstantArgument_instanceCreation() async {
@@ -941,263 +433,6 @@
     ]);
   }
 
-  test_initializerForNonExistent_const() async {
-    // Check that the absence of a matching field doesn't cause a
-    // crash during constant evaluation.
-    await assertErrorsInCode(r'''
-class A {
-  const A() : x = 'foo';
-}
-A a = const A();
-''', [
-      error(CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD, 24, 9),
-    ]);
-  }
-
-  test_initializerForNonExistent_initializer() async {
-    await assertErrorsInCode(r'''
-class A {
-  A() : x = 0 {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD, 18, 5),
-    ]);
-  }
-
-  test_initializerForStaticField() async {
-    await assertErrorsInCode(r'''
-class A {
-  static int x;
-  A() : x = 0 {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZER_FOR_STATIC_FIELD, 34, 5),
-    ]);
-  }
-
-  test_initializingFormalForNonExistentField() async {
-    await assertErrorsInCode(r'''
-class A {
-  A(this.x) {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 14,
-          6),
-    ]);
-  }
-
-  test_initializingFormalForNonExistentField_notInEnclosingClass() async {
-    await assertErrorsInCode(r'''
-class A {
-int x;
-}
-class B extends A {
-  B(this.x) {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 43,
-          6),
-    ]);
-  }
-
-  test_initializingFormalForNonExistentField_optional() async {
-    await assertErrorsInCode(r'''
-class A {
-  A([this.x]) {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 15,
-          6),
-    ]);
-  }
-
-  test_initializingFormalForNonExistentField_synthetic() async {
-    await assertErrorsInCode(r'''
-class A {
-  int get x => 1;
-  A(this.x) {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 32,
-          6),
-    ]);
-  }
-
-  test_initializingFormalForStaticField() async {
-    await assertErrorsInCode(r'''
-class A {
-  static int x;
-  A([this.x]) {}
-}
-''', [
-      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_STATIC_FIELD, 31, 6),
-    ]);
-  }
-
-  test_instanceMemberAccessFromFactory_named() async {
-    await assertErrorsInCode(r'''
-class A {
-  m() {}
-  A();
-  factory A.make() {
-    m();
-    return new A();
-  }
-}
-''', [
-      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_FACTORY, 51, 1),
-    ]);
-  }
-
-  test_instanceMemberAccessFromFactory_unnamed() async {
-    await assertErrorsInCode(r'''
-class A {
-  m() {}
-  A._();
-  factory A() {
-    m();
-    return new A._();
-  }
-}
-''', [
-      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_FACTORY, 48, 1),
-    ]);
-  }
-
-  test_instantiateEnum_const() async {
-    await assertErrorsInCode(r'''
-enum E { ONE }
-E e(String name) {
-  return const E();
-}
-''', [
-      error(CompileTimeErrorCode.INSTANTIATE_ENUM, 49, 1),
-    ]);
-  }
-
-  test_instantiateEnum_new() async {
-    await assertErrorsInCode(r'''
-enum E { ONE }
-E e(String name) {
-  return new E();
-}
-''', [
-      error(CompileTimeErrorCode.INSTANTIATE_ENUM, 47, 1),
-    ]);
-  }
-
-  test_integerLiteralAsDoubleOutOfRange_excessiveExponent() async {
-    await assertErrorsInCode(
-        'double x = 0xfffffffffffff80000000000000000000000000000000000000000000'
-        '0000000000000000000000000000000000000000000000000000000000000000000000'
-        '0000000000000000000000000000000000000000000000000000000000000000000000'
-        '000000000000000000000000000000000000000000000000000000000000;',
-        [
-          error(CompileTimeErrorCode.INTEGER_LITERAL_IMPRECISE_AS_DOUBLE, 11,
-              259),
-        ]);
-    AnalysisError firstError = result.errors[0];
-
-    // Check that we suggest the max double instead.
-    expect(
-        true,
-        firstError.correction.contains(
-            '179769313486231570814527423731704356798070567525844996598917476803'
-            '157260780028538760589558632766878171540458953514382464234321326889'
-            '464182768467546703537516986049910576551282076245490090389328944075'
-            '868508455133942304583236903222948165808559332123348274797826204144'
-            '723168738177180919299881250404026184124858368'));
-  }
-
-  test_integerLiteralAsDoubleOutOfRange_excessiveMantissa() async {
-    await assertErrorsInCode('''
-double x = 9223372036854775809;
-''', [
-      error(CompileTimeErrorCode.INTEGER_LITERAL_IMPRECISE_AS_DOUBLE, 11, 19),
-    ]);
-    AnalysisError firstError = result.errors[0];
-    // Check that we suggest a valid double instead.
-    expect(true, firstError.correction.contains('9223372036854775808'));
-  }
-
-  test_integerLiteralOutOfRange_negative() async {
-    await assertErrorsInCode('''
-int x = -9223372036854775809;
-''', [
-      error(CompileTimeErrorCode.INTEGER_LITERAL_OUT_OF_RANGE, 9, 19),
-    ]);
-  }
-
-  test_integerLiteralOutOfRange_positive() async {
-    await assertErrorsInCode('''
-int x = 9223372036854775808;
-''', [
-      error(CompileTimeErrorCode.INTEGER_LITERAL_OUT_OF_RANGE, 8, 19),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_member_async() async {
-    // TODO(danrubel): Investigate why error message is duplicated when
-    // using fasta parser.
-    await assertErrorsInCode(r'''
-class A {
-  set x(v) async {}
-}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_member_asyncStar() async {
-    await assertErrorsInCode(r'''
-class A {
-  set x(v) async* {}
-}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_member_syncStar() async {
-    await assertErrorsInCode(r'''
-class A {
-  set x(v) sync* {}
-}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 4),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 4),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_topLevel_async() async {
-    await assertErrorsInCode('''
-set x(v) async {}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_topLevel_asyncStar() async {
-    await assertErrorsInCode('''
-set x(v) async* {}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
-    ]);
-  }
-
-  test_invalidModifierOnSetter_topLevel_syncStar() async {
-    await assertErrorsInCode('''
-set x(v) sync* {}
-''', [
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 4),
-      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 4),
-    ]);
-  }
-
   test_length_of_erroneous_constant() async {
     // Attempting to compute the length of constant that couldn't be evaluated
     // (due to an error) should not crash the analyzer (see dartbug.com/23383)
@@ -1211,192 +446,6 @@
     ]);
   }
 
-  test_multipleRedirectingConstructorInvocations() async {
-    await assertErrorsInCode(r'''
-class A {
-  A() : this.a(), this.b();
-  A.a() {}
-  A.b() {}
-}
-''', [
-      error(CompileTimeErrorCode.MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS,
-          28, 8),
-    ]);
-  }
-
-  test_multipleSuperInitializers() async {
-    await assertErrorsInCode(r'''
-class A {}
-class B extends A {
-  B() : super(), super() {}
-}
-''', [
-      error(StrongModeCode.INVALID_SUPER_INVOCATION, 39, 7),
-      error(CompileTimeErrorCode.MULTIPLE_SUPER_INITIALIZERS, 48, 7),
-    ]);
-  }
-
-  test_nativeClauseInNonSDKCode() async {
-    await assertErrorsInCode('''
-class A native 'string' {}
-''', [
-      error(ParserErrorCode.NATIVE_CLAUSE_IN_NON_SDK_CODE, 8, 15),
-    ]);
-  }
-
-  test_nativeFunctionBodyInNonSDKCode_function() async {
-    await assertErrorsInCode('''
-int m(a) native 'string';
-''', [
-      error(ParserErrorCode.NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE, 9, 16),
-    ]);
-  }
-
-  test_nativeFunctionBodyInNonSDKCode_method() async {
-    await assertErrorsInCode(r'''
-class A{
-  static int m(a) native 'string';
-}
-''', [
-      error(ParserErrorCode.NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE, 27, 16),
-    ]);
-  }
-
-  test_noAnnotationConstructorArguments() async {
-    await assertErrorsInCode(r'''
-class A {
-  const A();
-}
-@A
-main() {
-}
-''', [
-      error(CompileTimeErrorCode.NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS, 25, 2),
-    ]);
-  }
-
-  test_nonConstantAnnotationConstructor_named() async {
-    await assertErrorsInCode(r'''
-class A {
-  A.fromInt() {}
-}
-@A.fromInt()
-main() {
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_ANNOTATION_CONSTRUCTOR, 29, 12),
-    ]);
-  }
-
-  test_nonConstantAnnotationConstructor_unnamed() async {
-    await assertErrorsInCode(r'''
-class A {
-  A() {}
-}
-@A()
-main() {
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_ANNOTATION_CONSTRUCTOR, 21, 4),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_function_named() async {
-    await assertErrorsInCode(r'''
-int y;
-f({x : y}) {}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 14, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_function_positional() async {
-    await assertErrorsInCode(r'''
-int y;
-f([x = y]) {}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 14, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_inConstructor_named() async {
-    await assertErrorsInCode(r'''
-class A {
-  int y;
-  A({x : y}) {}
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_inConstructor_positional() async {
-    await assertErrorsInCode(r'''
-class A {
-  int y;
-  A([x = y]) {}
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_method_named() async {
-    await assertErrorsInCode(r'''
-class A {
-  int y;
-  m({x : y}) {}
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValue_method_positional() async {
-    await assertErrorsInCode(r'''
-class A {
-  int y;
-  m([x = y]) {}
-}
-''', [
-      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
-    ]);
-  }
-
-  test_nonConstantDefaultValueFromDeferredLibrary() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-const V = 1;
-''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-f({x : a.V}) {}
-''', [
-      error(
-          CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE_FROM_DEFERRED_LIBRARY,
-          55,
-          3),
-    ]);
-  }
-
-  test_nonConstantDefaultValueFromDeferredLibrary_nested() async {
-    newFile('/test/lib/lib1.dart', content: '''
-library lib1;
-const V = 1;
-''');
-    await assertErrorsInCode('''
-library root;
-import 'lib1.dart' deferred as a;
-f({x : a.V + 1}) {}
-''', [
-      error(
-          CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE_FROM_DEFERRED_LIBRARY,
-          55,
-          7),
-    ]);
-  }
-
   test_nonConstMapAsExpressionStatement_begin() async {
     // TODO(danrubel): Consider improving recovery
     await assertErrorsInCode(r'''
diff --git a/pkg/analyzer/test/generated/compile_time_error_code_test.dart b/pkg/analyzer/test/generated/compile_time_error_code_test.dart
index 5ef0017..86d4e60 100644
--- a/pkg/analyzer/test/generated/compile_time_error_code_test.dart
+++ b/pkg/analyzer/test/generated/compile_time_error_code_test.dart
@@ -20,12 +20,6 @@
 class CompileTimeErrorCodeTest extends CompileTimeErrorCodeTestBase {
   @override
   @failingTest
-  test_awaitInWrongContext_sync() {
-    return super.test_awaitInWrongContext_sync();
-  }
-
-  @override
-  @failingTest
   test_constEvalThrowsException() {
     return super.test_constEvalThrowsException();
   }
diff --git a/pkg/analyzer/test/generated/element_resolver_test.dart b/pkg/analyzer/test/generated/element_resolver_test.dart
index 0636397..52d7501 100644
--- a/pkg/analyzer/test/generated/element_resolver_test.dart
+++ b/pkg/analyzer/test/generated/element_resolver_test.dart
@@ -9,10 +9,12 @@
 import 'package:analyzer/dart/ast/standard_ast_factory.dart';
 import 'package:analyzer/dart/ast/token.dart';
 import 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/dart/element/scope.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
+import 'package:analyzer/src/dart/element/scope.dart';
 import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/generated/element_resolver.dart';
 import 'package:analyzer/src/generated/resolver.dart';
@@ -404,8 +406,10 @@
     //
     SimpleIdentifier array = AstTestFactory.identifier3("a");
     array.staticType = interfaceTypeStar(classD);
-    IndexExpression expression =
-        AstTestFactory.indexExpression(array, AstTestFactory.identifier3("i"));
+    IndexExpression expression = AstTestFactory.indexExpression(
+      target: array,
+      index: AstTestFactory.identifier3("i"),
+    );
     expect(_resolveIndexExpression(expression), same(operator));
     _listener.assertNoErrors();
   }
@@ -442,8 +446,7 @@
         ElementFactory.setterElement(propName, false, _typeProvider.intType);
     classA.accessors = <PropertyAccessorElement>[getter, setter];
     // set name scope
-    _visitor.nameScope = EnclosedScope(null)
-      ..defineNameWithoutChecking('A', classA);
+    _visitor.nameScope = LocalScope(null)..add(classA);
     // prepare "A.p"
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', 'p');
     CommentReference commentReference =
@@ -462,8 +465,7 @@
         ElementFactory.methodElement("m", _typeProvider.intType);
     classA.methods = <MethodElement>[method];
     // set name scope
-    _visitor.nameScope = EnclosedScope(null)
-      ..defineNameWithoutChecking('A', classA);
+    _visitor.nameScope = LocalScope(null)..add(classA);
     // prepare "A.m"
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', 'm');
     CommentReference commentReference =
@@ -482,8 +484,7 @@
         ElementFactory.methodElement("==", _typeProvider.boolType);
     classA.methods = <MethodElement>[method];
     // set name scope
-    _visitor.nameScope = EnclosedScope(null)
-      ..defineNameWithoutChecking('A', classA);
+    _visitor.nameScope = LocalScope(null)..add(classA);
     // prepare "A.=="
     PrefixedIdentifier prefixed = AstTestFactory.identifier5('A', '==');
     CommentReference commentReference =
@@ -1029,7 +1030,9 @@
     try {
       _visitor.enclosingClass = enclosingClass;
       EnclosedScope innerScope = ClassScope(
-          TypeParameterScope(outerScope, enclosingClass), enclosingClass);
+        TypeParameterScope(outerScope, enclosingClass.typeParameters),
+        enclosingClass,
+      );
       _visitor.nameScope = innerScope;
       node.accept(_resolver);
     } finally {
@@ -1061,10 +1064,10 @@
   void _resolveNode(AstNode node, [List<Element> definedElements]) {
     Scope outerScope = _visitor.nameScope;
     try {
-      EnclosedScope innerScope = EnclosedScope(outerScope);
+      var innerScope = LocalScope(outerScope);
       if (definedElements != null) {
         for (Element element in definedElements) {
-          innerScope.define(element);
+          innerScope.add(element);
         }
       }
       _visitor.nameScope = innerScope;
diff --git a/pkg/analyzer/test/generated/elements_types_mixin.dart b/pkg/analyzer/test/generated/elements_types_mixin.dart
index e4010b2..00b967c 100644
--- a/pkg/analyzer/test/generated/elements_types_mixin.dart
+++ b/pkg/analyzer/test/generated/elements_types_mixin.dart
@@ -590,17 +590,49 @@
     return element;
   }
 
-  TypeParameterTypeImpl typeParameterTypeNone(TypeParameterElement element) {
-    return element.instantiate(nullabilitySuffix: NullabilitySuffix.none);
+  TypeParameterTypeImpl typeParameterType(
+    TypeParameterElement element, {
+    @required NullabilitySuffix nullabilitySuffix,
+    DartType promotedBound,
+  }) {
+    return TypeParameterTypeImpl(
+      element: element,
+      nullabilitySuffix: nullabilitySuffix,
+      promotedBound: promotedBound,
+    );
+  }
+
+  TypeParameterTypeImpl typeParameterTypeNone(
+    TypeParameterElement element, {
+    DartType promotedBound,
+  }) {
+    return typeParameterType(
+      element,
+      nullabilitySuffix: NullabilitySuffix.none,
+      promotedBound: promotedBound,
+    );
   }
 
   TypeParameterTypeImpl typeParameterTypeQuestion(
-      TypeParameterElement element) {
-    return element.instantiate(nullabilitySuffix: NullabilitySuffix.question);
+    TypeParameterElement element, {
+    DartType promotedBound,
+  }) {
+    return typeParameterType(
+      element,
+      nullabilitySuffix: NullabilitySuffix.question,
+      promotedBound: promotedBound,
+    );
   }
 
-  TypeParameterTypeImpl typeParameterTypeStar(TypeParameterElement element) {
-    return element.instantiate(nullabilitySuffix: NullabilitySuffix.star);
+  TypeParameterTypeImpl typeParameterTypeStar(
+    TypeParameterElement element, {
+    DartType promotedBound,
+  }) {
+    return typeParameterType(
+      element,
+      nullabilitySuffix: NullabilitySuffix.star,
+      promotedBound: promotedBound,
+    );
   }
 }
 
diff --git a/pkg/analyzer/test/generated/invalid_code_test.dart b/pkg/analyzer/test/generated/invalid_code_test.dart
index 50449a8..035fd21 100644
--- a/pkg/analyzer/test/generated/invalid_code_test.dart
+++ b/pkg/analyzer/test/generated/invalid_code_test.dart
@@ -4,12 +4,11 @@
 
 import 'dart:async';
 
-import 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../src/dart/resolution/driver_resolution.dart';
+import '../src/dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -337,15 +336,8 @@
 }
 
 @reflectiveTest
-class InvalidCodeWithNullSafetyTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class InvalidCodeWithNullSafetyTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_issue_40837() async {
     await _assertCanBeAnalyzed('''
 class A {
diff --git a/pkg/analyzer/test/generated/parser_fasta_listener.dart b/pkg/analyzer/test/generated/parser_fasta_listener.dart
index b75416d..bb429e9 100644
--- a/pkg/analyzer/test/generated/parser_fasta_listener.dart
+++ b/pkg/analyzer/test/generated/parser_fasta_listener.dart
@@ -621,6 +621,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -631,8 +632,16 @@
       Token endToken) {
     // beginMember --> endClassFields, endMember
     expectIn('Member');
-    super.endClassFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    super.endClassFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
@@ -749,6 +758,7 @@
 
   @override
   void endExtensionFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -759,8 +769,16 @@
       Token endToken) {
     // beginMember --> endExtensionFields, endMember
     expectIn('Member');
-    super.endExtensionFields(externalToken, staticToken, covariantToken,
-        lateToken, varFinalOrConst, count, beginToken, endToken);
+    super.endExtensionFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
@@ -1005,6 +1023,7 @@
 
   @override
   void endMixinFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1015,8 +1034,16 @@
       Token endToken) {
     // beginMember --> endMixinFields, endMember
     expectIn('Member');
-    super.endMixinFields(externalToken, staticToken, covariantToken, lateToken,
-        varFinalOrConst, count, beginToken, endToken);
+    super.endMixinFields(
+        abstractToken,
+        externalToken,
+        staticToken,
+        covariantToken,
+        lateToken,
+        varFinalOrConst,
+        count,
+        beginToken,
+        endToken);
   }
 
   @override
diff --git a/pkg/analyzer/test/generated/parser_fasta_test.dart b/pkg/analyzer/test/generated/parser_fasta_test.dart
index 9bd30a8..fd9767c 100644
--- a/pkg/analyzer/test/generated/parser_fasta_test.dart
+++ b/pkg/analyzer/test/generated/parser_fasta_test.dart
@@ -1676,7 +1676,7 @@
     var extension = unit.declarations[0] as ExtensionDeclaration;
     expect(extension.name.name, 'E');
     expect(extension.onKeyword.lexeme, 'on');
-    var namedType = (extension.extendedType as NamedType);
+    var namedType = extension.extendedType as NamedType;
     expect(namedType.name.name, 'C');
     expect(namedType.typeArguments.arguments, hasLength(1));
     expect(extension.members, hasLength(0));
@@ -1688,7 +1688,7 @@
     var extension = unit.declarations[0] as ExtensionDeclaration;
     expect(extension.name.name, 'E');
     expect(extension.onKeyword.lexeme, 'on');
-    var namedType = (extension.extendedType as NamedType);
+    var namedType = extension.extendedType as NamedType;
     expect(namedType.name.name, 'C');
     expect(namedType.typeArguments.arguments, hasLength(1));
     expect(extension.members, hasLength(0));
@@ -1700,7 +1700,7 @@
     var extension = unit.declarations[0] as ExtensionDeclaration;
     expect(extension.name, isNull);
     expect(extension.onKeyword.lexeme, 'on');
-    var namedType = (extension.extendedType as NamedType);
+    var namedType = extension.extendedType as NamedType;
     expect(namedType.name.name, 'C');
     expect(namedType.typeArguments.arguments, hasLength(1));
     expect(extension.members, hasLength(0));
@@ -1799,7 +1799,7 @@
     expect(extension.name.name, 'E');
     expect(extension.onKeyword.lexeme, 'on');
     expect((extension.extendedType as NamedType).name.name, 'C');
-    var namedType = (extension.extendedType as NamedType);
+    var namedType = extension.extendedType as NamedType;
     expect(namedType.name.name, 'C');
     expect(namedType.typeArguments, isNull);
     expect(extension.members, hasLength(0));
@@ -1836,7 +1836,7 @@
     expect(extension.name, isNull);
     expect(extension.onKeyword.lexeme, 'on');
     expect((extension.extendedType as NamedType).name.name, 'C');
-    var namedType = (extension.extendedType as NamedType);
+    var namedType = extension.extendedType as NamedType;
     expect(namedType.name.name, 'C');
     expect(namedType.typeArguments, isNull);
     expect(extension.members, hasLength(0));
diff --git a/pkg/analyzer/test/generated/parser_test.dart b/pkg/analyzer/test/generated/parser_test.dart
index 8bb5a73..61362bf 100644
--- a/pkg/analyzer/test/generated/parser_test.dart
+++ b/pkg/analyzer/test/generated/parser_test.dart
@@ -4416,8 +4416,8 @@
     ]);
     FunctionDeclaration declaration = unit.declarations.first;
     BlockFunctionBody blockBody = declaration.functionExpression.body;
-    ExpressionStatement statement = (blockBody).block.statements.first;
-    Expression expression = (statement).expression;
+    ExpressionStatement statement = blockBody.block.statements.first;
+    Expression expression = statement.expression;
     expect(expression, isSuperExpression);
     SuperExpression superExpression = expression;
     expect(superExpression.superKeyword, isNotNull);
@@ -11450,7 +11450,7 @@
 
   void test_missing_commaInArgumentList() {
     MethodInvocation expression = parseExpression("f(x: 1 y: 2)",
-        errors: ([expectedError(ParserErrorCode.EXPECTED_TOKEN, 7, 1)]));
+        errors: [expectedError(ParserErrorCode.EXPECTED_TOKEN, 7, 1)]);
     NodeList<Expression> arguments = expression.argumentList.arguments;
     expect(arguments, hasLength(2));
   }
diff --git a/pkg/analyzer/test/generated/resolver_test.dart b/pkg/analyzer/test/generated/resolver_test.dart
index fc7ab58..9b6101f 100644
--- a/pkg/analyzer/test/generated/resolver_test.dart
+++ b/pkg/analyzer/test/generated/resolver_test.dart
@@ -8,48 +8,26 @@
 import 'package:analyzer/dart/ast/visitor.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
-import 'package:analyzer/src/generated/testing/ast_test_factory.dart';
 import 'package:analyzer/src/generated/testing/element_factory.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../src/dart/resolution/driver_resolution.dart';
 import 'resolver_test_case.dart';
-import 'test_analysis_context.dart';
 
 main() {
   defineReflectiveSuite(() {
-    defineReflectiveTests(EnclosedScopeTest);
     defineReflectiveTests(ErrorResolverTest);
-    defineReflectiveTests(LibraryImportScopeTest);
-    defineReflectiveTests(LibraryScopeTest);
     defineReflectiveTests(PrefixedNamespaceTest);
-    defineReflectiveTests(ScopeTest);
     defineReflectiveTests(StrictModeTest);
     defineReflectiveTests(TypePropagationTest);
   });
 }
 
 @reflectiveTest
-class EnclosedScopeTest extends DriverResolutionTest {
-  test_define_duplicate() async {
-    Scope rootScope = _RootScope();
-    EnclosedScope scope = EnclosedScope(rootScope);
-    SimpleIdentifier identifier = AstTestFactory.identifier3('v');
-    VariableElement element1 = ElementFactory.localVariableElement(identifier);
-    VariableElement element2 = ElementFactory.localVariableElement(identifier);
-    scope.define(element1);
-    scope.define(element2);
-    expect(scope.lookup(identifier, null), same(element1));
-  }
-}
-
-@reflectiveTest
 class ErrorResolverTest extends DriverResolutionTest {
   test_breakLabelOnSwitchMember() async {
     await assertErrorsInCode(r'''
@@ -129,287 +107,6 @@
 }
 
 @reflectiveTest
-class LibraryImportScopeTest extends ResolverTestCase {
-  void test_creation_empty() {
-    LibraryImportScope(createDefaultTestLibrary());
-  }
-
-  void test_creation_nonEmpty() {
-    AnalysisContext context = TestAnalysisContext();
-    String importedTypeName = "A";
-    ClassElement importedType = ClassElementImpl(importedTypeName, -1);
-    LibraryElement importedLibrary = createTestLibrary(context, "imported");
-    (importedLibrary.definingCompilationUnit as CompilationUnitElementImpl)
-        .types = <ClassElement>[importedType];
-    LibraryElementImpl definingLibrary =
-        createTestLibrary(context, "importing");
-    ImportElementImpl importElement = ImportElementImpl(0);
-    importElement.importedLibrary = importedLibrary;
-    definingLibrary.imports = <ImportElement>[importElement];
-    Scope scope = LibraryImportScope(definingLibrary);
-    expect(
-        scope.lookup(
-            AstTestFactory.identifier3(importedTypeName), definingLibrary),
-        importedType);
-  }
-
-  void test_extensions_imported() {
-    var context = TestAnalysisContext();
-
-    var extension = ElementFactory.extensionElement('test_extension');
-
-    var importedUnit1 = ElementFactory.compilationUnit('/imported1.dart');
-    importedUnit1.extensions = <ExtensionElement>[extension];
-
-    var importedLibraryName = 'imported_lib';
-    var importedLibrary = LibraryElementImpl(context, null, importedLibraryName,
-        0, importedLibraryName.length, false);
-    importedLibrary.definingCompilationUnit = importedUnit1;
-
-    var importingLibraryName = 'importing_lib';
-    var importingLibrary = LibraryElementImpl(context, null,
-        importingLibraryName, 0, importingLibraryName.length, false);
-    importingLibrary.definingCompilationUnit =
-        ElementFactory.compilationUnit('/importing.dart');
-
-    var importElement = ImportElementImpl(0);
-    importElement.importedLibrary = importedLibrary;
-    importingLibrary.imports = <ImportElement>[importElement];
-
-    expect(
-        LibraryImportScope(importingLibrary).extensions, contains(extension));
-  }
-
-  void test_prefixedAndNonPrefixed() {
-    AnalysisContext context = TestAnalysisContext();
-    String typeName = "C";
-    String prefixName = "p";
-    ClassElement prefixedType = ElementFactory.classElement2(typeName);
-    ClassElement nonPrefixedType = ElementFactory.classElement2(typeName);
-    LibraryElement prefixedLibrary =
-        createTestLibrary(context, "import.prefixed");
-    (prefixedLibrary.definingCompilationUnit as CompilationUnitElementImpl)
-        .types = <ClassElement>[prefixedType];
-    ImportElementImpl prefixedImport = ElementFactory.importFor(
-        prefixedLibrary, ElementFactory.prefix(prefixName));
-    LibraryElement nonPrefixedLibrary =
-        createTestLibrary(context, "import.nonPrefixed");
-    (nonPrefixedLibrary.definingCompilationUnit as CompilationUnitElementImpl)
-        .types = <ClassElement>[nonPrefixedType];
-    ImportElementImpl nonPrefixedImport =
-        ElementFactory.importFor(nonPrefixedLibrary, null);
-    LibraryElementImpl importingLibrary =
-        createTestLibrary(context, "importing");
-    importingLibrary.imports = <ImportElement>[
-      prefixedImport,
-      nonPrefixedImport
-    ];
-    Scope scope = LibraryImportScope(importingLibrary);
-    Element prefixedElement = scope.lookup(
-        AstTestFactory.identifier5(prefixName, typeName), importingLibrary);
-    expect(prefixedElement, same(prefixedType));
-    Element nonPrefixedElement =
-        scope.lookup(AstTestFactory.identifier3(typeName), importingLibrary);
-    expect(nonPrefixedElement, same(nonPrefixedType));
-  }
-}
-
-@reflectiveTest
-class LibraryScopeTest extends ResolverTestCase {
-  void test_creation_empty() {
-    LibraryScope(createDefaultTestLibrary());
-  }
-
-  void test_creation_nonEmpty() {
-    AnalysisContext context = TestAnalysisContext();
-    String importedTypeName = "A";
-    ClassElement importedType = ClassElementImpl(importedTypeName, -1);
-    LibraryElement importedLibrary = createTestLibrary(context, "imported");
-    (importedLibrary.definingCompilationUnit as CompilationUnitElementImpl)
-        .types = <ClassElement>[importedType];
-    LibraryElementImpl definingLibrary =
-        createTestLibrary(context, "importing");
-    ImportElementImpl importElement = ImportElementImpl(0);
-    importElement.importedLibrary = importedLibrary;
-    definingLibrary.imports = <ImportElement>[importElement];
-    Scope scope = LibraryScope(definingLibrary);
-    expect(
-        scope.lookup(
-            AstTestFactory.identifier3(importedTypeName), definingLibrary),
-        importedType);
-  }
-
-  void test_extensions() {
-    ExtensionElement extension =
-        ElementFactory.extensionElement('test_extension');
-
-    CompilationUnitElementImpl compilationUnit =
-        ElementFactory.compilationUnit('/test.dart');
-    compilationUnit.extensions = <ExtensionElement>[extension];
-
-    String libraryName = 'lib';
-    LibraryElementImpl library = LibraryElementImpl(
-        null, null, libraryName, 0, libraryName.length, false);
-    library.definingCompilationUnit = compilationUnit;
-
-    expect(LibraryScope(library).extensions, contains(extension));
-  }
-
-  void test_extensions_imported() {
-    var context = TestAnalysisContext();
-
-    var importedUnit1 = ElementFactory.compilationUnit('/imported1.dart');
-    var importedExtension = ElementFactory.extensionElement('test_extension');
-    var unnamedImportedExtension = ElementFactory.extensionElement();
-    importedUnit1.extensions = [importedExtension, unnamedImportedExtension];
-
-    var importedLibraryName = 'imported_lib';
-    var importedLibrary = LibraryElementImpl(context, null, importedLibraryName,
-        0, importedLibraryName.length, false);
-    importedLibrary.definingCompilationUnit = importedUnit1;
-
-    var importingLibraryName = 'importing_lib';
-    var importingLibrary = LibraryElementImpl(context, null,
-        importingLibraryName, 0, importingLibraryName.length, false);
-
-    var localExtension = ElementFactory.extensionElement('test_extension');
-
-    var importingUnit = ElementFactory.compilationUnit('/importing.dart');
-    importingUnit.extensions = [localExtension];
-    importingLibrary.definingCompilationUnit = importingUnit;
-
-    var importElement = ImportElementImpl(0);
-    importElement.importedLibrary = importedLibrary;
-    importingLibrary.imports = [importElement];
-
-    var libraryExtensions = LibraryScope(importingLibrary).extensions;
-
-    expect(libraryExtensions, contains(localExtension));
-    expect(libraryExtensions, contains(importedExtension));
-    expect(libraryExtensions, isNot(contains(unnamedImportedExtension)));
-  }
-
-  /// Ensure that if a library L1 defines an extension E, L2 exports L1, and L3
-  /// imports L2, then E is included in the list.
-  void test_extensions_imported_chain() {
-    var context = TestAnalysisContext();
-
-    var unit1 = ElementFactory.compilationUnit('/unit1.dart');
-    var ext1 = ElementFactory.extensionElement('ext1');
-    unit1.extensions = [ext1];
-
-    var lib1Name = 'lib1';
-    var lib1 =
-        LibraryElementImpl(context, null, lib1Name, 0, lib1Name.length, false);
-    lib1.definingCompilationUnit = unit1;
-
-    var unit2 = ElementFactory.compilationUnit('/unit2.dart');
-
-    var lib2Name = 'lib2';
-    var lib2 =
-        LibraryElementImpl(context, null, lib2Name, 0, lib2Name.length, false);
-    lib2.definingCompilationUnit = unit2;
-
-    var lib1Export = ExportElementImpl(0);
-    lib1Export.exportedLibrary = lib1;
-    lib2.exports = [lib1Export];
-
-    var importingLibraryName = 'importing_lib';
-    var importingLibrary = LibraryElementImpl(context, null,
-        importingLibraryName, 0, importingLibraryName.length, false);
-
-    var importingUnit = ElementFactory.compilationUnit('/importing.dart');
-    importingLibrary.definingCompilationUnit = importingUnit;
-
-    var lib2Import = ImportElementImpl(0);
-    lib2Import.importedLibrary = lib2;
-    importingLibrary.imports = [lib2Import];
-
-    var libraryExtensions = LibraryScope(importingLibrary).extensions;
-
-    expect(libraryExtensions, orderedEquals([ext1]));
-  }
-
-  /// Ensure that if there are two extensions with the same name that are
-  /// imported from different libraries that they are both in the list of
-  /// extensions.
-  void test_extensions_imported_same_name() {
-    var context = TestAnalysisContext();
-
-    var sharedExtensionName = 'test_ext';
-
-    var unit1 = ElementFactory.compilationUnit('/unit1.dart');
-    var ext1 = ElementFactory.extensionElement(sharedExtensionName);
-    unit1.extensions = [ext1];
-
-    var lib1Name = 'lib1';
-    var lib1 =
-        LibraryElementImpl(context, null, lib1Name, 0, lib1Name.length, false);
-    lib1.definingCompilationUnit = unit1;
-
-    var unit2 = ElementFactory.compilationUnit('/unit2.dart');
-    var ext2 = ElementFactory.extensionElement(sharedExtensionName);
-    unit2.extensions = [ext2];
-
-    var lib2Name = 'lib2';
-    var lib2 =
-        LibraryElementImpl(context, null, lib2Name, 0, lib2Name.length, false);
-    lib2.definingCompilationUnit = unit2;
-
-    var importingLibraryName = 'importing_lib';
-    var importingLibrary = LibraryElementImpl(context, null,
-        importingLibraryName, 0, importingLibraryName.length, false);
-
-    var importingUnit = ElementFactory.compilationUnit('/importing.dart');
-    importingLibrary.definingCompilationUnit = importingUnit;
-
-    var importElement1 = ImportElementImpl(0);
-    importElement1.importedLibrary = lib1;
-    var importElement2 = ImportElementImpl(0);
-    importElement2.importedLibrary = lib2;
-    importingLibrary.imports = [importElement1, importElement2];
-
-    var libraryExtensions = LibraryScope(importingLibrary).extensions;
-
-    expect(libraryExtensions, contains(ext1));
-    expect(libraryExtensions, contains(ext2));
-  }
-
-  /// Ensure that if there are two imports for the same library that the
-  /// imported extension is only in the list one time.
-  void test_extensions_imported_twice() {
-    var context = TestAnalysisContext();
-
-    var sharedExtensionName = 'test_ext';
-
-    var unit1 = ElementFactory.compilationUnit('/unit1.dart');
-    var ext1 = ElementFactory.extensionElement(sharedExtensionName);
-    unit1.extensions = [ext1];
-
-    var lib1Name = 'lib1';
-    var lib1 =
-        LibraryElementImpl(context, null, lib1Name, 0, lib1Name.length, false);
-    lib1.definingCompilationUnit = unit1;
-
-    var importingLibraryName = 'importing_lib';
-    var importingLibrary = LibraryElementImpl(context, null,
-        importingLibraryName, 0, importingLibraryName.length, false);
-
-    var importingUnit = ElementFactory.compilationUnit('/importing.dart');
-    importingLibrary.definingCompilationUnit = importingUnit;
-
-    var importElement1 = ImportElementImpl(0);
-    importElement1.importedLibrary = lib1;
-    var importElement2 = ImportElementImpl(0);
-    importElement2.importedLibrary = lib1;
-    importingLibrary.imports = [importElement1, importElement2];
-
-    var libraryExtensions = LibraryScope(importingLibrary).extensions;
-    expect(libraryExtensions, orderedEquals([ext1]));
-  }
-}
-
-@reflectiveTest
 class PrefixedNamespaceTest extends DriverResolutionTest {
   void test_lookup_missing() {
     ClassElement element = ElementFactory.classElement2('A');
@@ -438,27 +135,6 @@
   }
 }
 
-@reflectiveTest
-class ScopeTest extends DriverResolutionTest {
-  void test_define_duplicate() {
-    Scope scope = _RootScope();
-    SimpleIdentifier identifier = AstTestFactory.identifier3('v');
-    VariableElement element1 = ElementFactory.localVariableElement(identifier);
-    VariableElement element2 = ElementFactory.localVariableElement(identifier);
-    scope.define(element1);
-    scope.define(element2);
-    expect(scope.localLookup('v'), same(element1));
-  }
-
-  void test_isPrivateName_nonPrivate() {
-    expect(Scope.isPrivateName("Public"), isFalse);
-  }
-
-  void test_isPrivateName_private() {
-    expect(Scope.isPrivateName("_Private"), isTrue);
-  }
-}
-
 /// Instances of the class `StaticTypeVerifier` verify that all of the nodes in
 /// an AST structure that should have a static type associated with them do have
 /// a static type.
@@ -787,20 +463,6 @@
     assertType(findNode.simple('v; // return'), 'int');
   }
 
-  test_functionExpression_asInvocationArgument_notSubtypeOfStaticType() async {
-    await assertErrorsInCode(r'''
-class A {
-  m(void f(int i)) {}
-}
-x() {
-  A a = new A();
-  a.m(() => 0);
-}''', [
-      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 63, 7),
-    ]);
-    assertType(findNode.functionExpression('() => 0'), 'int Function()');
-  }
-
   test_initializer_hasStaticType() async {
     await resolveTestCode(r'''
 f() {
@@ -952,8 +614,3 @@
     assertTypeDynamic(findNode.simple('v = '));
   }
 }
-
-class _RootScope extends Scope {
-  @override
-  Element internalLookup(String name) => null;
-}
diff --git a/pkg/analyzer/test/generated/resolver_test_case.dart b/pkg/analyzer/test/generated/resolver_test_case.dart
index cb180fe..04d739a 100644
--- a/pkg/analyzer/test/generated/resolver_test_case.dart
+++ b/pkg/analyzer/test/generated/resolver_test_case.dart
@@ -637,8 +637,7 @@
   }
 }
 
-/// Shared infrastructure for [StaticTypeAnalyzer2Test] and
-/// [StrongModeStaticTypeAnalyzer2Test].
+/// Shared infrastructure for [StaticTypeAnalyzer2Test].
 class StaticTypeAnalyzer2TestShared extends DriverResolutionTest {
   /// Find the expression that starts at the offset of [search] and validate its
   /// that its static type matches the given [type].
diff --git a/pkg/analyzer/test/generated/static_type_analyzer_test.dart b/pkg/analyzer/test/generated/static_type_analyzer_test.dart
index e47e3aa..e51614b 100644
--- a/pkg/analyzer/test/generated/static_type_analyzer_test.dart
+++ b/pkg/analyzer/test/generated/static_type_analyzer_test.dart
@@ -11,7 +11,6 @@
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/resolver/scope.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:analyzer/src/generated/resolver.dart' show ResolverVisitor;
 import 'package:analyzer/src/generated/source.dart';
@@ -33,8 +32,6 @@
     defineReflectiveTests(SetLiteralsTest);
     defineReflectiveTests(StaticTypeAnalyzerTest);
     defineReflectiveTests(StaticTypeAnalyzer2Test);
-    defineReflectiveTests(StaticTypeAnalyzer3Test);
-    defineReflectiveTests(StaticTypeAnalyzerWithSetLiteralsTest);
   });
 }
 
@@ -64,6 +61,66 @@
 /// Like [StaticTypeAnalyzerTest], but as end-to-end tests.
 @reflectiveTest
 class StaticTypeAnalyzer2Test extends StaticTypeAnalyzer2TestShared {
+  test_emptyListLiteral_inferredFromLinkedList() async {
+    await assertErrorsInCode(r'''
+abstract class ListImpl<T> implements List<T> {}
+ListImpl<int> f() => [];
+''', [
+      error(CompileTimeErrorCode.INVALID_CAST_LITERAL_LIST, 70, 2),
+    ]);
+    expectExpressionType('[]', 'List<dynamic>');
+  }
+
+  test_emptyMapLiteral_inferredFromLinkedHashMap() async {
+    await assertErrorsInCode(r'''
+import 'dart:collection';
+LinkedHashMap<int, int> f() => {};
+''', [
+      error(CompileTimeErrorCode.INVALID_CAST_LITERAL_MAP, 57, 2),
+    ]);
+    expectExpressionType('{}', 'Map<dynamic, dynamic>');
+  }
+
+  test_emptyMapLiteral_initializer_var() async {
+    await assertErrorsInCode(r'''
+main() {
+  var v = {};
+}
+''', [
+      error(HintCode.UNUSED_LOCAL_VARIABLE, 15, 1),
+    ]);
+    expectExpressionType('{}', 'Map<dynamic, dynamic>');
+  }
+
+  test_emptyMapLiteral_parameter_typed() async {
+    await assertNoErrorsInCode(r'''
+main() {
+  useMap({});
+}
+void useMap(Map<int, int> m) {
+}
+''');
+    expectExpressionType('{}', 'Map<int, int>');
+  }
+
+  test_emptySetLiteral_inferredFromLinkedHashSet() async {
+    await assertErrorsInCode(r'''
+import 'dart:collection';
+LinkedHashSet<int> f() => {};
+''', [
+      error(CompileTimeErrorCode.INVALID_CAST_LITERAL_SET, 52, 2),
+    ]);
+    expectExpressionType('{}', 'Set<dynamic>');
+  }
+
+  test_emptySetLiteral_initializer_typed_nested() async {
+    await assertNoErrorsInCode(r'''
+Set<Set<int>> ints = {{}};
+''');
+    expectExpressionType('{}', 'Set<int>');
+    expectExpressionType('{{}}', 'Set<Set<int>>');
+  }
+
   test_FunctionExpressionInvocation_block() async {
     await assertErrorsInCode(r'''
 main() {
@@ -169,32 +226,6 @@
   }
 }
 
-/// End-to-end tests of the static type analyzer that use the new driver.
-@reflectiveTest
-class StaticTypeAnalyzer3Test extends StaticTypeAnalyzer2TestShared {
-  test_emptyMapLiteral_initializer_var() async {
-    await assertErrorsInCode(r'''
-main() {
-  var v = {};
-}
-''', [
-      error(HintCode.UNUSED_LOCAL_VARIABLE, 15, 1),
-    ]);
-    expectExpressionType('{}', 'Map<dynamic, dynamic>');
-  }
-
-  test_emptyMapLiteral_parameter_typed() async {
-    await assertNoErrorsInCode(r'''
-main() {
-  useMap({});
-}
-void useMap(Map<int, int> m) {
-}
-''');
-    expectExpressionType('{}', 'Map<int, int>');
-  }
-}
-
 @reflectiveTest
 class StaticTypeAnalyzerTest with ResourceProviderMixin, ElementsTypesMixin {
   /// The error listener to which errors will be reported.
@@ -718,7 +749,7 @@
 
     _visitor = ResolverVisitor(
         inheritance, _definingLibrary, source, _typeProvider, _listener,
-        featureSet: featureSet, nameScope: LibraryScope(_definingLibrary));
+        featureSet: featureSet, nameScope: _definingLibrary.scope);
     _analyzer = _visitor.typeAnalyzer;
   }
 
@@ -771,27 +802,3 @@
     return identifier;
   }
 }
-
-/// End-to-end tests of the static type analyzer that use the new driver and
-/// enable the set-literals experiment.
-@reflectiveTest
-class StaticTypeAnalyzerWithSetLiteralsTest
-    extends StaticTypeAnalyzer2TestShared {
-  test_emptySetLiteral_inferredFromLinkedHashSet() async {
-    await assertErrorsInCode(r'''
-import 'dart:collection';
-LinkedHashSet<int> test4() => {};
-''', [
-      error(StrongModeCode.INVALID_CAST_LITERAL_SET, 56, 2),
-    ]);
-    expectExpressionType('{}', 'Set<dynamic>');
-  }
-
-  test_emptySetLiteral_initializer_typed_nested() async {
-    await assertNoErrorsInCode(r'''
-Set<Set<int>> ints = {{}};
-''');
-    expectExpressionType('{}', 'Set<int>');
-    expectExpressionType('{{}}', 'Set<Set<int>>');
-  }
-}
diff --git a/pkg/analyzer/test/generated/static_type_warning_code_test.dart b/pkg/analyzer/test/generated/static_type_warning_code_test.dart
index 6d659a6..d0ad450 100644
--- a/pkg/analyzer/test/generated/static_type_warning_code_test.dart
+++ b/pkg/analyzer/test/generated/static_type_warning_code_test.dart
@@ -190,36 +190,6 @@
     ]);
   }
 
-  test_expectedOneListTypeArgument() async {
-    await assertErrorsInCode(r'''
-main() {
-  <int, int> [];
-}
-''', [
-      error(StaticTypeWarningCode.EXPECTED_ONE_LIST_TYPE_ARGUMENTS, 11, 10),
-    ]);
-  }
-
-  test_expectedOneSetTypeArgument() async {
-    await assertErrorsInCode(r'''
-main() {
-  <int, int, int>{2, 3};
-}
-''', [
-      error(StaticTypeWarningCode.EXPECTED_ONE_SET_TYPE_ARGUMENTS, 11, 15),
-    ]);
-  }
-
-  test_expectedTwoMapTypeArguments_three() async {
-    await assertErrorsInCode(r'''
-main() {
-  <int, int, int> {};
-}
-''', [
-      error(StaticTypeWarningCode.EXPECTED_TWO_MAP_TYPE_ARGUMENTS, 11, 15),
-    ]);
-  }
-
   test_forIn_declaredVariableRightType() async {
     await assertErrorsInCode('''
 f() {
@@ -362,184 +332,9 @@
     ]);
   }
 
-  test_illegalAsyncGeneratorReturnType_function_nonStream() async {
-    await assertErrorsInCode('''
-int f() async* {}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 3),
-    ]);
-  }
-
-  test_illegalAsyncGeneratorReturnType_function_subtypeOfStream() async {
-    await assertErrorsInCode('''
-import 'dart:async';
-abstract class SubStream<T> implements Stream<T> {}
-SubStream<int> f() async* {}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 73, 14),
-    ]);
-  }
-
-  test_illegalAsyncGeneratorReturnType_method_nonStream() async {
-    await assertErrorsInCode('''
-class C {
-  int f() async* {}
-}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 12, 3),
-    ]);
-  }
-
-  test_illegalAsyncGeneratorReturnType_method_subtypeOfStream() async {
-    await assertErrorsInCode('''
-import 'dart:async';
-abstract class SubStream<T> implements Stream<T> {}
-class C {
-  SubStream<int> f() async* {}
-}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 85, 14),
-    ]);
-  }
-
-  test_illegalSyncGeneratorReturnType_function_nonIterator() async {
-    await assertErrorsInCode('''
-int f() sync* {}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 0, 3),
-    ]);
-  }
-
-  test_illegalSyncGeneratorReturnType_function_subclassOfIterator() async {
-    await assertErrorsInCode('''
-abstract class SubIterator<T> implements Iterator<T> {}
-SubIterator<int> f() sync* {}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 56, 16),
-    ]);
-  }
-
-  test_illegalSyncGeneratorReturnType_method_nonIterator() async {
-    await assertErrorsInCode('''
-class C {
-  int f() sync* {}
-}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 12, 3),
-    ]);
-  }
-
-  test_illegalSyncGeneratorReturnType_method_subclassOfIterator() async {
-    await assertErrorsInCode('''
-abstract class SubIterator<T> implements Iterator<T> {}
-class C {
-  SubIterator<int> f() sync* {}
-}
-''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 68, 16),
-    ]);
-  }
-
-  test_instanceAccessToStaticMember_method_reference() async {
-    await assertErrorsInCode(r'''
-class A {
-  static m() {}
-}
-main(A a) {
-  a.m;
-}
-''', [
-      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 44, 1),
-    ]);
-  }
-
-  test_instanceAccessToStaticMember_propertyAccess_field() async {
-    await assertErrorsInCode(r'''
-class A {
-  static var f;
-}
-main(A a) {
-  a.f;
-}
-''', [
-      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 44, 1),
-    ]);
-  }
-
-  test_instanceAccessToStaticMember_propertyAccess_getter() async {
-    await assertErrorsInCode(r'''
-class A {
-  static get f => 42;
-}
-main(A a) {
-  a.f;
-}
-''', [
-      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 50, 1),
-    ]);
-  }
-
-  test_instanceAccessToStaticMember_propertyAccess_setter() async {
-    await assertErrorsInCode(r'''
-class A {
-  static set f(x) {}
-}
-main(A a) {
-  a.f = 42;
-}
-''', [
-      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 49, 1),
-    ]);
-  }
-
-  test_invocationOfNonFunctionExpression_literal() async {
-    await assertErrorsInCode(r'''
-f() {
-  3(5);
-}
-''', [
-      error(StaticTypeWarningCode.INVOCATION_OF_NON_FUNCTION_EXPRESSION, 8, 1),
-    ]);
-  }
-
-  test_nonTypeAsTypeArgument_notAType() async {
-    await assertErrorsInCode(r'''
-int A;
-class B<E> {}
-f(B<A> b) {}
-''', [
-      error(StaticTypeWarningCode.NON_TYPE_AS_TYPE_ARGUMENT, 25, 1),
-    ]);
-  }
-
-  test_nonTypeAsTypeArgument_undefinedIdentifier() async {
-    await assertErrorsInCode(r'''
-class B<E> {}
-f(B<A> b) {}
-''', [
-      error(StaticTypeWarningCode.NON_TYPE_AS_TYPE_ARGUMENT, 18, 1),
-    ]);
-  }
-
-  test_typeParameterSupertypeOfItsBound_1of1() async {
-    await assertErrorsInCode(r'''
-class A<T extends T> {
-}
-''', [
-      error(StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 8, 11),
-    ]);
-  }
-
-  test_typeParameterSupertypeOfItsBound_2of3() async {
-    await assertErrorsInCode(r'''
-class A<T1 extends T3, T2, T3 extends T1> {
-}
-''', [
-      error(StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 8, 13),
-      error(
-          StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 27, 13),
-    ]);
-  }
+  // TODO(srawlins) Figure out what to do with the rest of these tests.
+  //  The names do not correspond to diagnostic codes, so it isn't clear what
+  //  they're testing.
 
   test_typePromotion_booleanAnd_useInRight_accessedInClosureRight_mutated() async {
     await assertErrorsInCode(r'''
@@ -787,64 +582,6 @@
     ]);
   }
 
-  test_unqualifiedReferenceToNonLocalStaticMember_getter() async {
-    await assertErrorsInCode(r'''
-class A {
-  static int get a => 0;
-}
-class B extends A {
-  int b() {
-    return a;
-  }
-}
-''', [
-      error(
-          StaticTypeWarningCode
-              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
-          80,
-          1),
-    ]);
-  }
-
-  test_unqualifiedReferenceToNonLocalStaticMember_getter_invokeTarget() async {
-    await assertErrorsInCode(r'''
-class A {
-  static int foo;
-}
-
-class B extends A {
-  static bar() {
-    foo.abs();
-  }
-}
-''', [
-      error(
-          StaticTypeWarningCode
-              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
-          72,
-          3),
-    ]);
-  }
-
-  test_unqualifiedReferenceToNonLocalStaticMember_setter() async {
-    await assertErrorsInCode(r'''
-class A {
-  static set a(x) {}
-}
-class B extends A {
-  b(y) {
-    a = y;
-  }
-}
-''', [
-      error(
-          StaticTypeWarningCode
-              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
-          66,
-          1),
-    ]);
-  }
-
   test_wrongNumberOfTypeArguments() async {
     await assertErrorsInCode(r'''
 class A<E> {
diff --git a/pkg/analyzer/test/generated/strong_mode_test.dart b/pkg/analyzer/test/generated/strong_mode_test.dart
index 568173f..fd8a5af 100644
--- a/pkg/analyzer/test/generated/strong_mode_test.dart
+++ b/pkg/analyzer/test/generated/strong_mode_test.dart
@@ -1147,8 +1147,8 @@
  ''');
     var analysisResult = await computeAnalysisResult(source);
     assertErrors(source, [
-      StrongModeCode.INVALID_CAST_LITERAL,
-      StrongModeCode.INVALID_CAST_LITERAL
+      CompileTimeErrorCode.INVALID_CAST_LITERAL,
+      CompileTimeErrorCode.INVALID_CAST_LITERAL
     ]);
     var unit = analysisResult.unit;
     var h = (AstFinder.getStatementsInTopLevelFunction(unit, "test")[0]
@@ -1263,9 +1263,9 @@
     assertNoErrors(source);
     verify([source]);
     var unit = analysisResult.unit;
-    var body = (AstFinder.getTopLevelFunction(unit, '_mergeSort')
+    var body = AstFinder.getTopLevelFunction(unit, '_mergeSort')
         .functionExpression
-        .body as BlockFunctionBody);
+        .body as BlockFunctionBody;
     var stmts = body.block.statements;
     for (ExpressionStatement stmt in stmts) {
       MethodInvocation invoke = stmt.expression;
@@ -1290,9 +1290,9 @@
     assertNoErrors(source);
     verify([source]);
     var unit = analysisResult.unit;
-    var body = (AstFinder.getTopLevelFunction(unit, '_mergeSort')
+    var body = AstFinder.getTopLevelFunction(unit, '_mergeSort')
         .functionExpression
-        .body as BlockFunctionBody);
+        .body as BlockFunctionBody;
     var stmts = body.block.statements;
     for (ExpressionStatement stmt in stmts) {
       MethodInvocation invoke = stmt.expression;
@@ -1317,9 +1317,9 @@
     assertNoErrors(source);
     verify([source]);
     var unit = analysisResult.unit;
-    var body = (AstFinder.getTopLevelFunction(unit, '_mergeSort')
+    var body = AstFinder.getTopLevelFunction(unit, '_mergeSort')
         .functionExpression
-        .body as BlockFunctionBody);
+        .body as BlockFunctionBody;
     var stmts = body.block.statements;
     for (ExpressionStatement stmt in stmts) {
       MethodInvocation invoke = stmt.expression;
@@ -1934,7 +1934,7 @@
    ''';
     Source source = addSource(code);
     TestAnalysisResult analysisResult = await computeAnalysisResult(source);
-    assertErrors(source, [StrongModeCode.INVALID_CAST_LITERAL]);
+    assertErrors(source, [CompileTimeErrorCode.INVALID_CAST_LITERAL]);
     verify([source]);
     CompilationUnit unit = analysisResult.unit;
     FunctionDeclaration test = AstFinder.getTopLevelFunction(unit, "test");
@@ -1986,7 +1986,7 @@
     Source source = addSource(code);
     TestAnalysisResult analysisResult = await computeAnalysisResult(source);
     assertErrors(source, [
-      StrongModeCode.INVALID_CAST_LITERAL,
+      CompileTimeErrorCode.INVALID_CAST_LITERAL,
     ]);
     verify([source]);
     CompilationUnit unit = analysisResult.unit;
@@ -3526,168 +3526,6 @@
 ''');
   }
 
-  test_notInstantiatedBound_class_error_recursion() async {
-    await assertErrorsInCode(r'''
-class A<T extends B> {} // points to a
-class B<T extends A> {} // points to b
-class C<T extends A> {} // points to a cyclical type
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 18, 1),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 57, 1),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 96, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_class_error_recursion_less_direct() async {
-    await assertErrorsInCode(r'''
-class A<T extends B<A>> {}
-class B<T extends A<B>> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 20, 1),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 47, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_class_error_recursion_typedef() async {
-    await assertErrorsInCode(r'''
-typedef F(C value);
-class C<T extends F> {}
-class D<T extends C> {}
-''', [
-      error(CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, 0, 19),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 38, 1),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 62, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_class_argument() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends List<K>> {}
-class C<T extends A> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 51, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_class_argument2() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends List<List<K>>> {}
-class C<T extends A> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 57, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_class_direct() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends K> {}
-class C<T extends A> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 45, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_class_indirect() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends K> {}
-class C<T extends List<A>> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 50, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_functionType() async {
-    await assertErrorsInCode(r'''
-class A<T extends Function(T)> {}
-class B<T extends T Function()> {}
-class C<T extends A> {}
-class D<T extends B> {}
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 87, 1),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 111, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_typedef_argument() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends List<K>> {}
-typedef void F<T extends A>();
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 58, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_typedef_argument2() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends List<List<K>>> {}
-typedef void F<T extends A>();
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 64, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_error_typedef_direct() async {
-    await assertErrorsInCode(r'''
-class A<K, V extends K> {}
-typedef void F<T extends A>();
-''', [
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 52, 1),
-    ]);
-  }
-
-  test_notInstantiatedBound_ok_class() async {
-    await assertNoErrorsInCode(r'''
-class A<T extends int> {}
-class C1<T extends A> {}
-class C2<T extends List<A>> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_class_class2() async {
-    await assertNoErrorsInCode(r'''
-class A<T> {}
-class C<T extends A<int>> {}
-class D<T extends C> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_class_class3() async {
-    await assertNoErrorsInCode(r'''
-class A<T> {}
-class B<T extends int> {}
-class C<T extends A<B>> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_class_class4() async {
-    await assertNoErrorsInCode(r'''
-class A<K, V> {}
-class B<T extends int> {}
-class C<T extends A<B, B>> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_class_function() async {
-    await assertNoErrorsInCode(r'''
-class A<T extends void Function()> {}
-class B<T extends A> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_class_typedef() async {
-    await assertNoErrorsInCode(r'''
-typedef void F<T extends int>();
-class C<T extends F> {}
-''');
-  }
-
-  test_notInstantiatedBound_ok_typedef_class() async {
-    await assertNoErrorsInCode(r'''
-class C<T extends int> {}
-typedef void F<T extends C>();
-''');
-  }
-
   test_objectMethodOnFunctions_Anonymous() async {
     await _objectMethodOnFunctions_helper2(r'''
 void main() {
diff --git a/pkg/analyzer/test/generated/utilities_test.dart b/pkg/analyzer/test/generated/utilities_test.dart
index abf0107..78ad197 100644
--- a/pkg/analyzer/test/generated/utilities_test.dart
+++ b/pkg/analyzer/test/generated/utilities_test.dart
@@ -3123,7 +3123,9 @@
 
   void test_indexExpression() {
     IndexExpression node = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.identifier3("i"));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.identifier3("i"),
+    );
     _assertReplace(node, Getter_NodeReplacerTest_test_indexExpression());
     _assertReplace(node, Getter_NodeReplacerTest_test_indexExpression_2());
   }
diff --git a/pkg/analyzer/test/src/clients/angular_analyzer_plugin/resolve_template_node_test.dart b/pkg/analyzer/test/src/clients/angular_analyzer_plugin/resolve_template_node_test.dart
new file mode 100644
index 0000000..0af2907
--- /dev/null
+++ b/pkg/analyzer/test/src/clients/angular_analyzer_plugin/resolve_template_node_test.dart
@@ -0,0 +1,119 @@
+// 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 'package:analyzer/dart/analysis/utilities.dart';
+import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/error/listener.dart';
+import 'package:analyzer/src/clients/angular_analyzer_plugin/angular_analyzer_plugin.dart';
+import 'package:analyzer/src/test_utilities/find_node.dart';
+import 'package:meta/meta.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ResolveTemplateNodeTest);
+  });
+}
+
+@reflectiveTest
+class ResolveTemplateNodeTest extends DriverResolutionTest {
+  test_asExpression() async {
+    await assertNoErrorsInCode(r'''
+class MyComponent {}
+''');
+
+    var source = findElement.unitElement.source;
+    var errorListener = RecordingErrorListener();
+
+    var template = _parseTemplate('var x = 0 as int;');
+    var node = template.findNode.variableDeclaration('x = ').initializer;
+
+    var overrideAsExpressionInvoked = false;
+
+    resolveTemplateNode(
+      componentClass: findElement.class_('MyComponent'),
+      templateSource: source,
+      localVariables: [],
+      node: node,
+      errorListener: errorListener,
+      errorReporter: ErrorReporter(errorListener, source),
+      overrideAsExpression: ({node, invokeSuper}) {
+        overrideAsExpressionInvoked = true;
+        expect(invokeSuper, isNotNull);
+      },
+    );
+
+    expect(overrideAsExpressionInvoked, isTrue);
+  }
+
+  test_references() async {
+    await assertNoErrorsInCode(r'''
+class MyComponent {
+  void someContext() {
+    // ignore:unused_local_variable
+    var foo = 0;
+  }
+
+  void bar(int a) {}
+}
+''');
+
+    var source = findElement.unitElement.source;
+    var errorListener = RecordingErrorListener();
+
+    var template = _parseTemplate('var x = bar(foo);');
+    var node = template.findNode.variableDeclaration('x = ').initializer;
+    assertElementNull(template.findNode.simple('foo'));
+    assertElementNull(template.findNode.methodInvocation('bar'));
+
+    resolveTemplateNode(
+      componentClass: findElement.class_('MyComponent'),
+      templateSource: source,
+      localVariables: [
+        findElement.localVar('foo'),
+      ],
+      node: node,
+      errorListener: errorListener,
+      errorReporter: ErrorReporter(errorListener, source),
+    );
+
+    assertElement(
+      template.findNode.simple('foo'),
+      findElement.localVar('foo'),
+    );
+
+    assertElement(
+      template.findNode.methodInvocation('bar'),
+      findElement.method('bar'),
+    );
+  }
+
+  _ParsedTemplate _parseTemplate(String templateCode) {
+    var templateUnit = parseString(
+      content: templateCode,
+      featureSet: result.unit.featureSet,
+    ).unit;
+
+    return _ParsedTemplate(
+      content: templateCode,
+      unit: templateUnit,
+      findNode: FindNode(templateCode, templateUnit),
+    );
+  }
+}
+
+class _ParsedTemplate {
+  final String content;
+  final CompilationUnit unit;
+  final FindNode findNode;
+
+  _ParsedTemplate({
+    @required this.content,
+    @required this.unit,
+    @required this.findNode,
+  });
+}
diff --git a/pkg/analyzer/test/src/clients/angular_analyzer_plugin/test_all.dart b/pkg/analyzer/test/src/clients/angular_analyzer_plugin/test_all.dart
new file mode 100644
index 0000000..1494e1f
--- /dev/null
+++ b/pkg/analyzer/test/src/clients/angular_analyzer_plugin/test_all.dart
@@ -0,0 +1,13 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'resolve_template_node_test.dart' as resolve_template_node;
+
+main() {
+  defineReflectiveSuite(() {
+    resolve_template_node.main();
+  }, name: 'angular_analyzer_plugin');
+}
diff --git a/pkg/analyzer/test/src/clients/test_all.dart b/pkg/analyzer/test/src/clients/test_all.dart
new file mode 100644
index 0000000..6ba96a8
--- /dev/null
+++ b/pkg/analyzer/test/src/clients/test_all.dart
@@ -0,0 +1,13 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'angular_analyzer_plugin/test_all.dart' as angular_analyzer_plugin;
+
+main() {
+  defineReflectiveSuite(() {
+    angular_analyzer_plugin.main();
+  }, name: 'clients');
+}
diff --git a/pkg/analyzer/test/src/command_line/arguments_test.dart b/pkg/analyzer/test/src/command_line/arguments_test.dart
index 38ccc7c..17017c4 100644
--- a/pkg/analyzer/test/src/command_line/arguments_test.dart
+++ b/pkg/analyzer/test/src/command_line/arguments_test.dart
@@ -4,11 +4,11 @@
 
 import 'package:analyzer/src/command_line/arguments.dart';
 import 'package:analyzer/src/context/builder.dart';
-import 'package:analyzer/src/dart/sdk/sdk.dart';
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/sdk.dart';
 import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
 import 'package:args/args.dart';
+import 'package:cli_util/cli_util.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -78,8 +78,7 @@
     ArgResults result = parse(resourceProvider, parser, args);
     DartSdkManager manager = createDartSdkManager(resourceProvider, result);
     expect(manager, isNotNull);
-    expect(manager.defaultSdkDirectory,
-        FolderBasedDartSdk.defaultSdkDirectory(resourceProvider)?.path);
+    expect(manager.defaultSdkDirectory, getSdkPath());
   }
 
   void test_createDartSdkManager_path() {
diff --git a/pkg/analyzer/test/src/context/builder_test.dart b/pkg/analyzer/test/src/context/builder_test.dart
index 63c88ec..816bd11 100644
--- a/pkg/analyzer/test/src/context/builder_test.dart
+++ b/pkg/analyzer/test/src/context/builder_test.dart
@@ -8,6 +8,7 @@
 import 'package:analyzer/src/context/context_root.dart';
 import 'package:analyzer/src/context/packages.dart';
 import 'package:analyzer/src/context/source.dart';
+import 'package:analyzer/src/dart/error/lint_codes.dart';
 import 'package:analyzer/src/file_system/file_system.dart';
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/sdk.dart';
@@ -821,6 +822,9 @@
   _MockLintRule(this._name);
 
   @override
+  List<LintCode> get lintCodes => [LintCode(_name, '')];
+
+  @override
   String get name => _name;
 
   @override
diff --git a/pkg/analyzer/test/src/dart/analysis/context_builder_test.dart b/pkg/analyzer/test/src/dart/analysis/context_builder_test.dart
index a937fd6..f705281 100644
--- a/pkg/analyzer/test/src/dart/analysis/context_builder_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/context_builder_test.dart
@@ -46,7 +46,10 @@
     DeclaredVariables declaredVariables =
         DeclaredVariables.fromMap({'foo': 'true'});
     DriverBasedAnalysisContext context = contextBuilder.createContext(
-        contextRoot: contextRoot, declaredVariables: declaredVariables);
+      contextRoot: contextRoot,
+      declaredVariables: declaredVariables,
+      sdkPath: resourceProvider.convertPath(sdkRoot),
+    );
     expect(context.analysisOptions, isNotNull);
     expect(context.contextRoot, contextRoot);
     assertEquals(context.driver.declaredVariables, declaredVariables);
@@ -68,8 +71,10 @@
   }
 
   test_createContext_defaults() {
-    AnalysisContext context =
-        contextBuilder.createContext(contextRoot: contextRoot);
+    AnalysisContext context = contextBuilder.createContext(
+      contextRoot: contextRoot,
+      sdkPath: resourceProvider.convertPath(sdkRoot),
+    );
     expect(context.analysisOptions, isNotNull);
     expect(context.contextRoot, contextRoot);
   }
diff --git a/pkg/analyzer/test/src/dart/analysis/driver_resolution_test.dart b/pkg/analyzer/test/src/dart/analysis/driver_resolution_test.dart
index 9984659..90c11509 100644
--- a/pkg/analyzer/test/src/dart/analysis/driver_resolution_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/driver_resolution_test.dart
@@ -8495,8 +8495,7 @@
 
   /// Assert that the [argument] has the [expectedType]. If the [argument] is
   /// a [NamedExpression], the name must be resolved to the same parameter.
-  void _assertArgumentToParameter2(Expression argument, String expectedType,
-      {DartType memberType}) {
+  void _assertArgumentToParameter2(Expression argument, String expectedType) {
     ParameterElement actual = argument.staticParameterElement;
     assertType(actual.type, expectedType);
 
diff --git a/pkg/analyzer/test/src/dart/analysis/experiments_test.dart b/pkg/analyzer/test/src/dart/analysis/experiments_test.dart
index dee7327..d45fd53 100644
--- a/pkg/analyzer/test/src/dart/analysis/experiments_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/experiments_test.dart
@@ -194,7 +194,7 @@
 
   test_fromStrings_unrecognized_flag() {
     // Unrecognized flags are ignored.
-    expect(getFlags(fromStrings(['a'])), []);
+    expect(getFlags(fromStrings(['a'])), <Object>[]);
   }
 
   test_validateFlagCombination_disable_then_enable() {
diff --git a/pkg/analyzer/test/src/dart/analysis/feature_set_provider_test.dart b/pkg/analyzer/test/src/dart/analysis/feature_set_provider_test.dart
index f5328f8..8e88069 100644
--- a/pkg/analyzer/test/src/dart/analysis/feature_set_provider_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/feature_set_provider_test.dart
@@ -13,6 +13,7 @@
 import 'package:analyzer/src/source/package_map_resolver.dart';
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
+import 'package:meta/meta.dart';
 import 'package:pub_semver/pub_semver.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
@@ -79,6 +80,7 @@
 
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: packages,
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -125,6 +127,7 @@
 
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: packages,
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -171,24 +174,54 @@
 
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: packages,
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
     );
 
-    void check(String posixPath, Version expected) {
+    void check({
+      @required String uriStr,
+      @required String posixPath,
+      @required Version expected,
+    }) {
+      var uri = Uri.parse(uriStr);
       var path = convertPath(posixPath);
-      var uri = Uri.parse('package:aaa/a.dart');
       expect(
         provider.getLanguageVersion(path, uri),
         expected,
       );
     }
 
-    check('/packages/aaa/a.dart', Version.parse('2.5.0'));
-    check('/packages/aaa/bbb/b.dart', Version.parse('2.6.0'));
-    check('/packages/ccc/c.dart', Version.parse('2.7.0'));
-    check('/packages/ddd/d.dart', ExperimentStatus.currentVersion);
+    check(
+      uriStr: 'package:aaa/a.dart',
+      posixPath: '/packages/aaa/a.dart',
+      expected: Version.parse('2.5.0'),
+    );
+
+    check(
+      uriStr: toUriStr('/packages/aaa/test/a.dart'),
+      posixPath: '/packages/aaa/test/a.dart',
+      expected: Version.parse('2.5.0'),
+    );
+
+    check(
+      uriStr: 'package:bbb/b.dart',
+      posixPath: '/packages/aaa/bbb/b.dart',
+      expected: Version.parse('2.6.0'),
+    );
+
+    check(
+      uriStr: 'package:ccc/c.dart',
+      posixPath: '/packages/ccc/c.dart',
+      expected: Version.parse('2.7.0'),
+    );
+
+    check(
+      uriStr: 'package:ddd/a.dart',
+      posixPath: '/packages/ddd/d.dart',
+      expected: ExperimentStatus.currentVersion,
+    );
   }
 
   test_packages_contextExperiments_nonNullable() {
@@ -209,6 +242,7 @@
 
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: packages,
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags(['non-nullable']),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -238,6 +272,7 @@
 
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: findPackagesFrom(resourceProvider, getFolder('/test')),
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -269,6 +304,7 @@
 ''');
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: findPackagesFrom(resourceProvider, getFolder('/test')),
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -284,6 +320,7 @@
   test_sdk_allowedExperiments_mockDefault() {
     provider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: findPackagesFrom(resourceProvider, getFolder('/test')),
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
diff --git a/pkg/analyzer/test/src/dart/analysis/file_state_test.dart b/pkg/analyzer/test/src/dart/analysis/file_state_test.dart
index 5ec7d05..b9af9b1 100644
--- a/pkg/analyzer/test/src/dart/analysis/file_state_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/file_state_test.dart
@@ -21,6 +21,7 @@
 import 'package:analyzer/src/source/package_map_resolver.dart';
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
+import 'package:analyzer/src/workspace/basic.dart';
 import 'package:convert/convert.dart';
 import 'package:crypto/crypto.dart';
 import 'package:test/test.dart';
@@ -50,18 +51,29 @@
   void setUp() {
     logger = PerformanceLog(logBuffer);
     sdk = MockSdk(resourceProvider: resourceProvider);
+
+    var packageMap = <String, List<Folder>>{
+      'aaa': [getFolder('/aaa/lib')],
+      'bbb': [getFolder('/bbb/lib')],
+    };
+
+    var workspace = BasicWorkspace.find(
+      resourceProvider,
+      packageMap,
+      convertPath('/test'),
+    );
+
     sourceFactory = SourceFactory([
       DartUriResolver(sdk),
       generatedUriResolver,
-      PackageMapUriResolver(resourceProvider, <String, List<Folder>>{
-        'aaa': [getFolder('/aaa/lib')],
-        'bbb': [getFolder('/bbb/lib')],
-      }),
+      PackageMapUriResolver(resourceProvider, packageMap),
       ResourceUriResolver(resourceProvider)
     ]);
+
     AnalysisOptions analysisOptions = AnalysisOptionsImpl();
     var featureSetProvider = FeatureSetProvider.build(
       sourceFactory: sourceFactory,
+      resourceProvider: resourceProvider,
       packages: Packages.empty,
       packageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
       nonPackageDefaultFeatureSet: FeatureSet.fromEnableFlags([]),
@@ -73,6 +85,7 @@
       resourceProvider,
       'contextName',
       sourceFactory,
+      workspace,
       analysisOptions,
       DeclaredVariables(),
       Uint32List(0),
diff --git a/pkg/analyzer/test/src/dart/analysis/mutex_test.dart b/pkg/analyzer/test/src/dart/analysis/mutex_test.dart
index 565168f..5ffbda9 100644
--- a/pkg/analyzer/test/src/dart/analysis/mutex_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/mutex_test.dart
@@ -23,7 +23,7 @@
       Future(() async {
         await mutex.acquire();
         try {
-          await Future.delayed(Duration(milliseconds: 10));
+          await Future<void>.delayed(Duration(milliseconds: 10));
           values.add(1);
         } finally {
           mutex.release();
@@ -50,7 +50,7 @@
     await Future.wait([
       Future(() async {
         await mutex.guard(() async {
-          await Future.delayed(Duration(milliseconds: 10));
+          await Future<void>.delayed(Duration(milliseconds: 10));
           values.add(1);
         });
       }),
diff --git a/pkg/analyzer/test/src/dart/analysis/search_test.dart b/pkg/analyzer/test/src/dart/analysis/search_test.dart
index ce1dd18..7885e20 100644
--- a/pkg/analyzer/test/src/dart/analysis/search_test.dart
+++ b/pkg/analyzer/test/src/dart/analysis/search_test.dart
@@ -1755,7 +1755,7 @@
   /// Create [ExpectedResult] for a qualified and resolved match.
   ExpectedResult _expectIdQ(
       Element element, SearchResultKind kind, String search,
-      {int length, bool isResolved = true}) {
+      {int length}) {
     return _expectId(element, kind, search, isQualified: true, length: length);
   }
 
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 8207f4e..df8306d 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
@@ -1741,9 +1741,12 @@
 
   void test_visitIndexExpression() {
     _assertSource(
-        "a[i]",
-        AstTestFactory.indexExpression(
-            AstTestFactory.identifier3("a"), AstTestFactory.identifier3("i")));
+      "a[i]",
+      AstTestFactory.indexExpression(
+        target: AstTestFactory.identifier3("a"),
+        index: AstTestFactory.identifier3("i"),
+      ),
+    );
   }
 
   void test_visitInstanceCreationExpression_const() {
diff --git a/pkg/analyzer/test/src/dart/ast/utilities_test.dart b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
index 1489f45..be73747 100644
--- a/pkg/analyzer/test/src/dart/ast/utilities_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
@@ -498,7 +498,9 @@
 
   void test_visitIndexExpression() {
     IndexExpression fromNode = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.integer(0));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.integer(0),
+    );
     MethodElement staticElement = ElementFactory.methodElement(
         "m", interfaceTypeStar(ElementFactory.classElement2('C')));
     AuxiliaryElements auxiliaryElements = AuxiliaryElements(staticElement);
@@ -507,7 +509,9 @@
     DartType staticType = interfaceTypeStar(ElementFactory.classElement2('C'));
     fromNode.staticType = staticType;
     IndexExpression toNode = AstTestFactory.indexExpression(
-        AstTestFactory.identifier3("a"), AstTestFactory.integer(0));
+      target: AstTestFactory.identifier3("a"),
+      index: AstTestFactory.integer(0),
+    );
     ResolutionCopier.copyResolutionData(fromNode, toNode);
     expect(toNode.auxiliaryElements, same(auxiliaryElements));
     expect(toNode.staticElement, same(staticElement));
diff --git a/pkg/analyzer/test/src/dart/constant/evaluation_test.dart b/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
index 056f1c4..78c6212 100644
--- a/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
+++ b/pkg/analyzer/test/src/dart/constant/evaluation_test.dart
@@ -15,7 +15,7 @@
 
 import '../../../generated/test_support.dart';
 import '../resolution/driver_resolution.dart';
-import 'potentially_constant_test.dart';
+import '../resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/constant/potentially_constant_test.dart b/pkg/analyzer/test/src/dart/constant/potentially_constant_test.dart
index 91e2cc5..225f997 100644
--- a/pkg/analyzer/test/src/dart/constant/potentially_constant_test.dart
+++ b/pkg/analyzer/test/src/dart/constant/potentially_constant_test.dart
@@ -2,15 +2,13 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/constant/potentially_constant.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../resolution/driver_resolution.dart';
+import '../resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -969,14 +967,3 @@
 ''', () => _xInitializer());
   }
 }
-
-mixin WithNullSafetyMixin on DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
diff --git a/pkg/analyzer/test/src/dart/element/element_test.dart b/pkg/analyzer/test/src/dart/element/element_test.dart
index e4d0ac4..4be0fa5 100644
--- a/pkg/analyzer/test/src/dart/element/element_test.dart
+++ b/pkg/analyzer/test/src/dart/element/element_test.dart
@@ -2219,6 +2219,57 @@
 
 @reflectiveTest
 class TypeParameterTypeImplTest extends AbstractTypeTest {
+  void test_asInstanceOf_hasBound_element() {
+    var T = typeParameter('T', bound: listNone(intNone));
+    _assert_asInstanceOf(
+      typeParameterTypeNone(T),
+      typeProvider.iterableElement,
+      'Iterable<int>',
+    );
+  }
+
+  void test_asInstanceOf_hasBound_element_noMatch() {
+    var T = typeParameter('T', bound: numNone);
+    _assert_asInstanceOf(
+      typeParameterTypeNone(T),
+      typeProvider.iterableElement,
+      null,
+    );
+  }
+
+  void test_asInstanceOf_hasBound_promoted() {
+    var T = typeParameter('T');
+    _assert_asInstanceOf(
+      typeParameterTypeNone(
+        T,
+        promotedBound: listNone(intNone),
+      ),
+      typeProvider.iterableElement,
+      'Iterable<int>',
+    );
+  }
+
+  void test_asInstanceOf_hasBound_promoted_noMatch() {
+    var T = typeParameter('T');
+    _assert_asInstanceOf(
+      typeParameterTypeNone(
+        T,
+        promotedBound: numNone,
+      ),
+      typeProvider.iterableElement,
+      null,
+    );
+  }
+
+  void test_asInstanceOf_noBound() {
+    var T = typeParameter('T');
+    _assert_asInstanceOf(
+      typeParameterTypeNone(T),
+      typeProvider.iterableElement,
+      null,
+    );
+  }
+
   void test_creation() {
     expect(typeParameterTypeStar(TypeParameterElementImpl('E', -1)), isNotNull);
   }
@@ -2240,7 +2291,7 @@
   void test_resolveToBound_bound_nullableInner() {
     ClassElementImpl classS = class_(name: 'A');
     TypeParameterElementImpl element = TypeParameterElementImpl('E', -1);
-    element.bound = (interfaceTypeQuestion(classS));
+    element.bound = interfaceTypeQuestion(classS);
     TypeParameterTypeImpl type = typeParameterTypeStar(element);
     expect(type.resolveToBound(null), same(element.bound));
   }
@@ -2337,6 +2388,18 @@
     expect(type.substitute2(<DartType>[argument], <DartType>[parameter]),
         same(type));
   }
+
+  void _assert_asInstanceOf(
+    DartType type,
+    ClassElement element,
+    String expected,
+  ) {
+    var result = (type as TypeImpl).asInstanceOf(element);
+    expect(
+      result?.getDisplayString(withNullability: true),
+      expected,
+    );
+  }
 }
 
 @reflectiveTest
diff --git a/pkg/analyzer/test/src/dart/element/inheritance_manager3_test.dart b/pkg/analyzer/test/src/dart/element/inheritance_manager3_test.dart
index ab566fc..2abef15 100644
--- a/pkg/analyzer/test/src/dart/element/inheritance_manager3_test.dart
+++ b/pkg/analyzer/test/src/dart/element/inheritance_manager3_test.dart
@@ -2,16 +2,15 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/null_safety_understanding_flag.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:meta/meta.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../resolution/driver_resolution.dart';
+import '../resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -1043,15 +1042,8 @@
 }
 
 @reflectiveTest
-class InheritanceManager3WithNnbdTest extends _InheritanceManager3Base {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class InheritanceManager3WithNnbdTest extends _InheritanceManager3Base
+    with WithNullSafetyMixin {
   test_getInheritedMap_topMerge_method() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.6
diff --git a/pkg/analyzer/test/src/dart/element/normalize_type_test.dart b/pkg/analyzer/test/src/dart/element/normalize_type_test.dart
index a687593..9309834 100644
--- a/pkg/analyzer/test/src/dart/element/normalize_type_test.dart
+++ b/pkg/analyzer/test/src/dart/element/normalize_type_test.dart
@@ -7,9 +7,9 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
-import 'package:analyzer/src/dart/element/type_visitor.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -508,7 +508,7 @@
     var typeStr = '';
 
     var typeParameterCollector = _TypeParameterCollector();
-    DartTypeVisitor.visit(type, typeParameterCollector);
+    type.accept(typeParameterCollector);
     for (var typeParameter in typeParameterCollector.typeParameters) {
       typeStr += ', $typeParameter';
     }
@@ -522,7 +522,7 @@
   }
 }
 
-class _TypeParameterCollector extends DartTypeVisitor<void> {
+class _TypeParameterCollector extends TypeVisitor<void> {
   final Set<String> typeParameters = {};
 
   /// We don't need to print bounds for these type parameters, because
@@ -531,12 +531,7 @@
   final Set<TypeParameterElement> functionTypeParameters = {};
 
   @override
-  void defaultDartType(DartType type) {
-    throw UnimplementedError('(${type.runtimeType}) $type');
-  }
-
-  @override
-  void visitDynamicType(DynamicTypeImpl type) {}
+  void visitDynamicType(DynamicType type) {}
 
   @override
   void visitFunctionType(FunctionType type) {
@@ -544,24 +539,24 @@
     for (var typeParameter in type.typeFormals) {
       var bound = typeParameter.bound;
       if (bound != null) {
-        DartTypeVisitor.visit(bound, this);
+        bound.accept(this);
       }
     }
     for (var parameter in type.parameters) {
-      DartTypeVisitor.visit(parameter.type, this);
+      parameter.type.accept(this);
     }
-    DartTypeVisitor.visit(type.returnType, this);
+    type.returnType.accept(this);
   }
 
   @override
   void visitInterfaceType(InterfaceType type) {
     for (var typeArgument in type.typeArguments) {
-      DartTypeVisitor.visit(typeArgument, this);
+      typeArgument.accept(this);
     }
   }
 
   @override
-  void visitNeverType(NeverTypeImpl type) {}
+  void visitNeverType(NeverType type) {}
 
   @override
   void visitTypeParameterType(TypeParameterType type) {
diff --git a/pkg/analyzer/test/src/dart/element/subtype_test.dart b/pkg/analyzer/test/src/dart/element/subtype_test.dart
index 1585cec..452060b 100644
--- a/pkg/analyzer/test/src/dart/element/subtype_test.dart
+++ b/pkg/analyzer/test/src/dart/element/subtype_test.dart
@@ -6,8 +6,8 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart';
-import 'package:analyzer/src/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/resolver/variance.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
@@ -5792,7 +5792,7 @@
     var typeStr = '';
 
     var typeParameterCollector = _TypeParameterCollector();
-    DartTypeVisitor.visit(type, typeParameterCollector);
+    type.accept(typeParameterCollector);
     for (var typeParameter in typeParameterCollector.typeParameters) {
       typeStr += ', $typeParameter';
     }
@@ -5975,7 +5975,7 @@
 
 class _SubtypingTestBase extends AbstractTypeSystemNullSafetyTest {}
 
-class _TypeParameterCollector extends DartTypeVisitor<void> {
+class _TypeParameterCollector extends TypeVisitor<void> {
   final Set<String> typeParameters = {};
 
   /// We don't need to print bounds for these type parameters, because
@@ -5984,12 +5984,7 @@
   final Set<TypeParameterElement> functionTypeParameters = {};
 
   @override
-  void defaultDartType(DartType type) {
-    throw UnimplementedError('(${type.runtimeType}) $type');
-  }
-
-  @override
-  void visitDynamicType(DynamicTypeImpl type) {}
+  void visitDynamicType(DynamicType type) {}
 
   @override
   void visitFunctionType(FunctionType type) {
@@ -5997,24 +5992,24 @@
     for (var typeParameter in type.typeFormals) {
       var bound = typeParameter.bound;
       if (bound != null) {
-        DartTypeVisitor.visit(bound, this);
+        bound.accept(this);
       }
     }
     for (var parameter in type.parameters) {
-      DartTypeVisitor.visit(parameter.type, this);
+      parameter.type.accept(this);
     }
-    DartTypeVisitor.visit(type.returnType, this);
+    type.returnType.accept(this);
   }
 
   @override
   void visitInterfaceType(InterfaceType type) {
     for (var typeArgument in type.typeArguments) {
-      DartTypeVisitor.visit(typeArgument, this);
+      typeArgument.accept(this);
     }
   }
 
   @override
-  void visitNeverType(NeverTypeImpl type) {}
+  void visitNeverType(NeverType type) {}
 
   @override
   void visitTypeParameterType(TypeParameterType type) {
diff --git a/pkg/analyzer/test/src/dart/element/type_visitor_test.dart b/pkg/analyzer/test/src/dart/element/type_visitor_test.dart
index 7043e7f..40352a8 100644
--- a/pkg/analyzer/test/src/dart/element/type_visitor_test.dart
+++ b/pkg/analyzer/test/src/dart/element/type_visitor_test.dart
@@ -27,7 +27,7 @@
   }
 
   void test_callsDefaultBehavior() {
-    expect(DartTypeVisitor.visit(intNone, visitor), true);
+    expect(intNone.accept(visitor), true);
     visitor.assertVisitedType(intNone);
   }
 
@@ -43,7 +43,7 @@
         typeFormals: [T, K],
         parameters: [a, b, c, d],
         nullabilitySuffix: NullabilitySuffix.none);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedTypes([
       dynamicType,
       intNone,
@@ -62,7 +62,7 @@
         typeFormals: [],
         parameters: [a],
         nullabilitySuffix: NullabilitySuffix.none);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedType(intNone);
   }
 
@@ -72,7 +72,7 @@
         typeFormals: [],
         parameters: [],
         nullabilitySuffix: NullabilitySuffix.none);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedType(intNone);
   }
 
@@ -83,7 +83,7 @@
         typeFormals: [T],
         parameters: [],
         nullabilitySuffix: NullabilitySuffix.none);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedTypes([dynamicType, intNone]);
   }
 
@@ -94,26 +94,26 @@
         typeFormals: [T],
         parameters: [],
         nullabilitySuffix: NullabilitySuffix.none);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedType(dynamicType);
   }
 
   void test_interfaceType_typeParameter() {
     final type = typeProvider.listType2(intNone);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedType(intNone);
   }
 
   void test_interfaceType_typeParameters() {
     final type = typeProvider.mapType2(intNone, stringNone);
-    expect(DartTypeVisitor.visit(type, visitor), true);
+    expect(type.accept(visitor), true);
     visitor.assertVisitedTypes([intNone, stringNone]);
   }
 
   void test_interfaceType_typeParameters_nested() {
     final innerList = typeProvider.listType2(intNone);
     final outerList = typeProvider.listType2(innerList);
-    expect(DartTypeVisitor.visit(outerList, visitor), true);
+    expect(outerList.accept(visitor), true);
     visitor.assertVisitedType(intNone);
   }
 
@@ -130,7 +130,7 @@
         parameters: [a, b, c, d],
         nullabilitySuffix: NullabilitySuffix.none);
     visitor.stopOnType = dynamicType;
-    expect(DartTypeVisitor.visit(type, visitor), false);
+    expect(type.accept(visitor), false);
     visitor.assertNotVisitedTypes(
         [intNone, stringNone, numNone, doubleNone, voidNone, objectNone]);
   }
@@ -148,7 +148,7 @@
         parameters: [a, b, c, d],
         nullabilitySuffix: NullabilitySuffix.none);
     visitor.stopOnType = intNone;
-    expect(DartTypeVisitor.visit(type, visitor), false);
+    expect(type.accept(visitor), false);
     visitor.assertNotVisitedTypes([stringNone, voidNone, objectNone]);
   }
 
@@ -156,7 +156,7 @@
     final innerType = typeProvider.mapType2(intNone, stringNone);
     final outerList = typeProvider.listType2(innerType);
     visitor.stopOnType = intNone;
-    expect(DartTypeVisitor.visit(outerList, visitor), false);
+    expect(outerList.accept(visitor), false);
     visitor.assertNotVisitedType(stringNone);
   }
 
@@ -165,14 +165,14 @@
     final innerTypeSkipped = typeProvider.listType2(stringNone);
     final outerType = typeProvider.mapType2(innerTypeStop, innerTypeSkipped);
     visitor.stopOnType = intNone;
-    expect(DartTypeVisitor.visit(outerType, visitor), false);
+    expect(outerType.accept(visitor), false);
     visitor.assertNotVisitedType(stringNone);
   }
 
   void test_stopVisiting_typeParameters() {
     final type = typeProvider.mapType2(intNone, stringNone);
     visitor.stopOnType = intNone;
-    expect(DartTypeVisitor.visit(type, visitor), false);
+    expect(type.accept(visitor), false);
     visitor.assertVisitedType(intNone);
     visitor.assertNotVisitedType(stringNone);
   }
@@ -197,7 +197,7 @@
       types.forEach(assertVisitedType);
 
   @override
-  bool defaultDartType(DartType type) {
+  bool visitDartType(DartType type) {
     expect(type, isNotNull);
     visitedTypes.add(type);
     return type != stopOnType;
diff --git a/pkg/analyzer/test/src/dart/element/upper_lower_bound_test.dart b/pkg/analyzer/test/src/dart/element/upper_lower_bound_test.dart
index 072e3ef..19d5cef 100644
--- a/pkg/analyzer/test/src/dart/element/upper_lower_bound_test.dart
+++ b/pkg/analyzer/test/src/dart/element/upper_lower_bound_test.dart
@@ -6,6 +6,7 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
+import 'package:analyzer/dart/element/type_visitor.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_schema.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
@@ -113,7 +114,7 @@
     // BOTTOM(Never) is true
     isBottom(neverNone);
     isNotBottom(neverQuestion);
-    isNotBottom(neverStar);
+    isBottom(neverStar);
 
     // BOTTOM(X&T) is true iff BOTTOM(T)
     T = typeParameter('T', bound: objectQuestion);
@@ -2266,7 +2267,7 @@
     var typeStr = '';
 
     var typeParameterCollector = _TypeParameterCollector();
-    DartTypeVisitor.visit(type, typeParameterCollector);
+    type.accept(typeParameterCollector);
     for (var typeParameter in typeParameterCollector.typeParameters) {
       typeStr += ', $typeParameter';
     }
@@ -2280,7 +2281,8 @@
   }
 }
 
-class _TypeParameterCollector extends DartTypeVisitor<void> {
+class _TypeParameterCollector
+    implements TypeVisitor<void>, InferenceTypeVisitor<void> {
   final Set<String> typeParameters = {};
 
   /// We don't need to print bounds for these type parameters, because
@@ -2289,12 +2291,7 @@
   final Set<TypeParameterElement> functionTypeParameters = {};
 
   @override
-  void defaultDartType(DartType type) {
-    throw UnimplementedError('(${type.runtimeType}) $type');
-  }
-
-  @override
-  void visitDynamicType(DynamicTypeImpl type) {}
+  void visitDynamicType(DynamicType type) {}
 
   @override
   void visitFunctionType(FunctionType type) {
@@ -2302,24 +2299,24 @@
     for (var typeParameter in type.typeFormals) {
       var bound = typeParameter.bound;
       if (bound != null) {
-        DartTypeVisitor.visit(bound, this);
+        bound.accept(this);
       }
     }
     for (var parameter in type.parameters) {
-      DartTypeVisitor.visit(parameter.type, this);
+      parameter.type.accept(this);
     }
-    DartTypeVisitor.visit(type.returnType, this);
+    type.returnType.accept(this);
   }
 
   @override
   void visitInterfaceType(InterfaceType type) {
     for (var typeArgument in type.typeArguments) {
-      DartTypeVisitor.visit(typeArgument, this);
+      typeArgument.accept(this);
     }
   }
 
   @override
-  void visitNeverType(NeverTypeImpl type) {}
+  void visitNeverType(NeverType type) {}
 
   @override
   void visitTypeParameterType(TypeParameterType type) {
diff --git a/pkg/analyzer/test/src/dart/micro/simple_file_resolver_test.dart b/pkg/analyzer/test/src/dart/micro/simple_file_resolver_test.dart
index f0b0b9d..e431824 100644
--- a/pkg/analyzer/test/src/dart/micro/simple_file_resolver_test.dart
+++ b/pkg/analyzer/test/src/dart/micro/simple_file_resolver_test.dart
@@ -260,7 +260,7 @@
     // Still has cached, will be not resolved.
     createFileResolver();
     expect(getTestErrors().errors, hasLength(1));
-    expect(fileResolver.testView.resolvedFiles, []);
+    expect(fileResolver.testView.resolvedFiles, <Object>[]);
 
     // Change the file, new resolver.
     // With changed file the previously cached result cannot be used.
@@ -273,7 +273,7 @@
     // Still has cached, will be not resolved.
     createFileResolver();
     expect(getTestErrors().errors, hasLength(1));
-    expect(fileResolver.testView.resolvedFiles, []);
+    expect(fileResolver.testView.resolvedFiles, <Object>[]);
   }
 
   test_getErrors_reuse_changeDependency() {
@@ -313,7 +313,7 @@
     // Still has cached, will be not resolved.
     createFileResolver();
     expect(getTestErrors().errors, hasLength(1));
-    expect(fileResolver.testView.resolvedFiles, []);
+    expect(fileResolver.testView.resolvedFiles, <Object>[]);
   }
 
   test_hint() async {
diff --git a/pkg/analyzer/test/src/dart/resolution/await_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/await_expression_test.dart
index 74b5b02..456b8a8 100644
--- a/pkg/analyzer/test/src/dart/resolution/await_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/await_expression_test.dart
@@ -2,12 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -44,16 +42,8 @@
 }
 
 @reflectiveTest
-class AwaitExpressionResolutionWithNullSafetyTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class AwaitExpressionResolutionWithNullSafetyTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_futureOrQ() async {
     await assertNoErrorsInCode(r'''
 import 'dart:async';
diff --git a/pkg/analyzer/test/src/dart/resolution/binary_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/binary_expression_test.dart
index 2c276d8..8fd3389 100644
--- a/pkg/analyzer/test/src/dart/resolution/binary_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/binary_expression_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -232,17 +230,8 @@
 }
 
 @reflectiveTest
-class BinaryExpressionResolutionWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class BinaryExpressionResolutionWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_ifNull_left_nullableContext() async {
     await assertNoErrorsInCode(r'''
 T f<T>(T t) => t;
diff --git a/pkg/analyzer/test/src/dart/resolution/constant_test.dart b/pkg/analyzer/test/src/dart/resolution/constant_test.dart
index a535f95..4a9651e 100644
--- a/pkg/analyzer/test/src/dart/resolution/constant_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/constant_test.dart
@@ -2,19 +2,17 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/constant/value.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/find_element.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -238,17 +236,8 @@
 }
 
 @reflectiveTest
-class ConstantResolutionWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ConstantResolutionWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_context_eliminateTypeVariables() async {
     await assertNoErrorsInCode(r'''
 class A<T> {
diff --git a/pkg/analyzer/test/src/dart/resolution/constructor_test.dart b/pkg/analyzer/test/src/dart/resolution/constructor_test.dart
index 6f190ac..efb4867 100644
--- a/pkg/analyzer/test/src/dart/resolution/constructor_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/constructor_test.dart
@@ -44,6 +44,28 @@
     assertType(B_int_redirect.returnType, 'A<int>');
   }
 
+  test_formalParameterScope_type() async {
+    await assertNoErrorsInCode('''
+class a {}
+
+class B {
+  B(a a) {
+    a;
+  }
+}
+''');
+
+    assertElement(
+      findNode.simple('a a'),
+      findElement.class_('a'),
+    );
+
+    assertElement(
+      findNode.simple('a;'),
+      findElement.parameter('a'),
+    );
+  }
+
   test_initializer_field_functionExpression_blockBody() async {
     await resolveTestCode(r'''
 class C {
diff --git a/pkg/analyzer/test/src/dart/resolution/driver_resolution.dart b/pkg/analyzer/test/src/dart/resolution/driver_resolution.dart
index 8503999..45021c6 100644
--- a/pkg/analyzer/test/src/dart/resolution/driver_resolution.dart
+++ b/pkg/analyzer/test/src/dart/resolution/driver_resolution.dart
@@ -4,12 +4,15 @@
 
 import 'dart:async';
 
+import 'package:analyzer/dart/analysis/context_locator.dart' as api;
 import 'package:analyzer/dart/analysis/results.dart';
 import 'package:analyzer/file_system/file_system.dart';
 import 'package:analyzer/src/context/context_root.dart';
 import 'package:analyzer/src/context/packages.dart';
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
+import 'package:analyzer/src/dart/analysis/driver_based_analysis_context.dart'
+    as api;
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/performance_logger.dart';
 import 'package:analyzer/src/generated/engine.dart' show AnalysisOptionsImpl;
@@ -18,6 +21,7 @@
 import 'package:analyzer/src/source/package_map_resolver.dart';
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
+import 'package:meta/meta.dart';
 
 import 'resolution.dart';
 
@@ -40,6 +44,25 @@
 
   bool get enableIndex => false;
 
+  void configureWorkspace({@required String root}) {
+    newFolder(root);
+
+    var apiContextRoots = api.ContextLocator(
+      resourceProvider: resourceProvider,
+    ).locateRoots(
+      includedPaths: [convertPath(root)],
+      excludedPaths: [],
+    );
+
+    driver.configure(
+      analysisContext: api.DriverBasedAnalysisContext(
+        resourceProvider,
+        apiContextRoots.first,
+        driver,
+      ),
+    );
+  }
+
   @override
   Future<ResolvedUnitResult> resolveFile(String path) async {
     return await driver.getResult(path);
@@ -82,6 +105,8 @@
         enableIndex: enableIndex,
         packages: Packages.empty);
 
+    configureWorkspace(root: '/test');
+
     scheduler.start();
   }
 }
diff --git a/pkg/analyzer/test/src/dart/resolution/extension_method_test.dart b/pkg/analyzer/test/src/dart/resolution/extension_method_test.dart
index 1c9f147..96eb57a 100644
--- a/pkg/analyzer/test/src/dart/resolution/extension_method_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/extension_method_test.dart
@@ -2,16 +2,15 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -316,15 +315,8 @@
 /// Tests that show that extension declarations and the members inside them are
 /// resolved correctly.
 @reflectiveTest
-class ExtensionMethodsDeclarationWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ExtensionMethodsDeclarationWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_this_type_interface() async {
     await assertNoErrorsInCode('''
 extension E on int {
@@ -484,15 +476,7 @@
 
 @reflectiveTest
 class ExtensionMethodsExtendedTypeWithNnbdTest
-    extends ExtensionMethodsExtendedTypeTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+    extends ExtensionMethodsExtendedTypeTest with WithNullSafetyMixin {}
 
 /// Tests that extension members can be correctly resolved when referenced
 /// by code external to the extension declaration.
@@ -1437,15 +1421,7 @@
 
 @reflectiveTest
 class ExtensionMethodsExternalReferenceWithNnbdTest
-    extends ExtensionMethodsExternalReferenceTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends ExtensionMethodsExternalReferenceTest with WithNullSafetyMixin {
   test_instance_getter_fromInstance_Never() async {
     await assertNoErrorsInCode('''
 extension E on Never {
@@ -1615,10 +1591,10 @@
 }
 
 f(int? a) {
-  a?.[0];
+  a?[0];
 }
 ''');
-    var index = findNode.index('a?.[0]');
+    var index = findNode.index('a?[0]');
     assertElement(index, findElement.method('[]'));
   }
 
@@ -2243,12 +2219,4 @@
 
 @reflectiveTest
 class ExtensionMethodsInternalReferenceWithNnbdTest
-    extends ExtensionMethodsInternalReferenceTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+    extends ExtensionMethodsInternalReferenceTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/dart/resolution/extension_override_test.dart b/pkg/analyzer/test/src/dart/resolution/extension_override_test.dart
index cbb0bde..32287ad 100644
--- a/pkg/analyzer/test/src/dart/resolution/extension_override_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/extension_override_test.dart
@@ -10,8 +10,8 @@
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../constant/potentially_constant_test.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -614,7 +614,7 @@
 }
 
 void f(int? a) {
-  E(a)?.[0];
+  E(a)?[0];
 }
 ''');
 
@@ -633,7 +633,7 @@
 }
 
 void f(int? a) {
-  E(a)?.[0] = 1;
+  E(a)?[0] = 1;
 }
 ''');
 
diff --git a/pkg/analyzer/test/src/dart/resolution/field_test.dart b/pkg/analyzer/test/src/dart/resolution/field_test.dart
index 274d030..715c86b 100644
--- a/pkg/analyzer/test/src/dart/resolution/field_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/field_test.dart
@@ -4,8 +4,8 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../constant/potentially_constant_test.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/resolution/for_element_test.dart b/pkg/analyzer/test/src/dart/resolution/for_element_test.dart
index 7dc6aef..11f1fd0e 100644
--- a/pkg/analyzer/test/src/dart/resolution/for_element_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/for_element_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -51,12 +50,8 @@
 }
 
 @reflectiveTest
-class ForEachElementWithNnbdTest extends ForEachElementTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
+class ForEachElementWithNnbdTest extends ForEachElementTest
+    with WithNullSafetyMixin {
   test_optIn_fromOptOut() async {
     newFile('/test/lib/a.dart', content: r'''
 class A implements Iterable<int> {
diff --git a/pkg/analyzer/test/src/dart/resolution/function_declaration_test.dart b/pkg/analyzer/test/src/dart/resolution/function_declaration_test.dart
new file mode 100644
index 0000000..29e10c6
--- /dev/null
+++ b/pkg/analyzer/test/src/dart/resolution/function_declaration_test.dart
@@ -0,0 +1,50 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(FunctionDeclarationResolutionTest);
+  });
+}
+
+@reflectiveTest
+class FunctionDeclarationResolutionTest extends DriverResolutionTest {
+  test_formalParameterScope_defaultValue() async {
+    await assertNoErrorsInCode('''
+const foo = 0;
+
+void bar([int foo = foo + 1]) {
+}
+''');
+
+    assertElement(
+      findNode.simple('foo + 1'),
+      findElement.topGet('foo'),
+    );
+  }
+
+  test_formalParameterScope_type() async {
+    await assertNoErrorsInCode('''
+class a {}
+
+void bar(a a) {
+  a;
+}
+''');
+
+    assertElement(
+      findNode.simple('a a'),
+      findElement.class_('a'),
+    );
+
+    assertElement(
+      findNode.simple('a;'),
+      findElement.parameter('a'),
+    );
+  }
+}
diff --git a/pkg/analyzer/test/src/dart/resolution/function_expression_invocation_test.dart b/pkg/analyzer/test/src/dart/resolution/function_expression_invocation_test.dart
index 03d250f..1bb0387 100644
--- a/pkg/analyzer/test/src/dart/resolution/function_expression_invocation_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/function_expression_invocation_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -53,17 +51,8 @@
 }
 
 @reflectiveTest
-class FunctionExpressionInvocationWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class FunctionExpressionInvocationWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_call_infer_fromArguments() async {
     await assertNoErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/if_element_test.dart b/pkg/analyzer/test/src/dart/resolution/if_element_test.dart
index 83b70b9..2b32f17 100644
--- a/pkg/analyzer/test/src/dart/resolution/if_element_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/if_element_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -35,9 +34,4 @@
 }
 
 @reflectiveTest
-class IfElementWithNnbdTest extends IfElementTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-}
+class IfElementWithNnbdTest extends IfElementTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/dart/resolution/index_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/index_expression_test.dart
index 80d9ab1..a4df0ce 100644
--- a/pkg/analyzer/test/src/dart/resolution/index_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/index_expression_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -238,15 +237,8 @@
 }
 
 @reflectiveTest
-class IndexExpressionWithNnbdTest extends IndexExpressionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class IndexExpressionWithNnbdTest extends IndexExpressionTest
+    with WithNullSafetyMixin {
   test_read_cascade_nullShorting() async {
     await assertNoErrorsInCode(r'''
 class A {
@@ -299,28 +291,6 @@
     );
   }
 
-  test_read_nullable_questionDotIndex() async {
-    await assertNoErrorsInCode(r'''
-class A {
-  bool operator[](int index) => false;
-}
-
-main(A? a) {
-  a?.[0];
-}
-''');
-
-    var indexElement = findElement.method('[]');
-
-    var indexExpression = findNode.index('a?.[0]');
-    assertIndexExpression(
-      indexExpression,
-      readElement: indexElement,
-      writeElement: null,
-      type: 'bool?',
-    );
-  }
-
   test_readWrite_nullable() async {
     await assertNoErrorsInCode(r'''
 class A {
@@ -361,46 +331,6 @@
     );
   }
 
-  test_readWrite_nullable_questionDotIndex() async {
-    await assertNoErrorsInCode(r'''
-class A {
-  num operator[](int index) => 0;
-  void operator[]=(int index, num value) {}
-}
-
-main(A? a) {
-  a?.[0] += 1.2;
-}
-''');
-
-    var indexElement = findElement.method('[]');
-    var indexEqElement = findElement.method('[]=');
-    var numPlusElement = numElement.getMethod('+');
-
-    var indexExpression = findNode.index('a?.[0]');
-    assertIndexExpression(
-      indexExpression,
-      readElement: indexElement,
-      writeElement: indexEqElement,
-      type: 'num',
-    );
-    assertParameterElement(
-      indexExpression.index,
-      indexEqElement.parameters[0],
-    );
-
-    var assignment = indexExpression.parent as AssignmentExpression;
-    assertAssignment(
-      assignment,
-      operatorElement: numPlusElement,
-      type: 'num?',
-    );
-    assertParameterElement(
-      assignment.rightHandSide,
-      numPlusElement.parameters[0],
-    );
-  }
-
   test_write_cascade_nullShorting() async {
     await assertNoErrorsInCode(r'''
 class A {
@@ -464,38 +394,4 @@
     );
     assertParameterElement(assignment.rightHandSide, null);
   }
-
-  test_write_nullable_questionDotIndex() async {
-    await assertNoErrorsInCode(r'''
-class A {
-  void operator[]=(int index, num value) {}
-}
-
-main(A? a) {
-  a?.[0] = 1.2;
-}
-''');
-
-    var indexEqElement = findElement.method('[]=');
-
-    var indexExpression = findNode.index('a?.[0]');
-    assertIndexExpression(
-      indexExpression,
-      readElement: null,
-      writeElement: indexEqElement,
-      type: null,
-    );
-    assertParameterElement(
-      indexExpression.index,
-      indexEqElement.parameters[0],
-    );
-
-    var assignment = indexExpression.parent as AssignmentExpression;
-    assertAssignment(
-      assignment,
-      operatorElement: null,
-      type: 'double?',
-    );
-    assertParameterElement(assignment.rightHandSide, null);
-  }
 }
diff --git a/pkg/analyzer/test/src/dart/resolution/instance_member_inference_class_test.dart b/pkg/analyzer/test/src/dart/resolution/instance_member_inference_class_test.dart
index 42b09ff..f25e552 100644
--- a/pkg/analyzer/test/src/dart/resolution/instance_member_inference_class_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/instance_member_inference_class_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -916,15 +915,7 @@
 
 @reflectiveTest
 class InstanceMemberInferenceClassWithNullSafetyTest
-    extends InstanceMemberInferenceClassTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends InstanceMemberInferenceClassTest with WithNullSafetyMixin {
   test_field_multiple_gettersSetters_final_nonNullify() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.7
diff --git a/pkg/analyzer/test/src/dart/resolution/instance_member_inference_mixin_test.dart b/pkg/analyzer/test/src/dart/resolution/instance_member_inference_mixin_test.dart
index 0f6a4a8..15d4bf4 100644
--- a/pkg/analyzer/test/src/dart/resolution/instance_member_inference_mixin_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/instance_member_inference_mixin_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -323,15 +322,7 @@
 
 @reflectiveTest
 class InstanceMemberInferenceClassWithNullSafetyTest
-    extends InstanceMemberInferenceClassTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends InstanceMemberInferenceClassTest with WithNullSafetyMixin {
   test_method_parameter_required_multiple_different_merge() async {
     await resolveTestCode('''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/interpolation_string_test.dart b/pkg/analyzer/test/src/dart/resolution/interpolation_string_test.dart
new file mode 100644
index 0000000..9cd883a
--- /dev/null
+++ b/pkg/analyzer/test/src/dart/resolution/interpolation_string_test.dart
@@ -0,0 +1,123 @@
+// Copyright (c) 2017, 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 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/src/dart/error/syntactic_errors.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InterpolationStringTest);
+  });
+}
+
+@reflectiveTest
+class InterpolationStringTest extends DriverResolutionTest {
+  void test_contents() async {
+    var code = r'''
+var bar;
+var f = "foo$bar";
+''';
+    await assertNoErrorsInCode(code);
+    final string = findNode.stringInterpolation(r'"foo$bar"');
+
+    expect(string.elements, hasLength(3));
+
+    final foo = string.elements[0] as InterpolationString;
+    var quoteOffset = code.indexOf('"');
+    expect(foo.contents.lexeme, '"foo');
+    expect(foo.contents.offset, quoteOffset);
+    expect(foo.contents.end, quoteOffset + '"foo'.length);
+  }
+
+  void test_contentsOffset() async {
+    var code = r'''
+var bar;
+var f = "foo${bar}baz";
+''';
+    await assertNoErrorsInCode(code);
+    final string = findNode.stringInterpolation(r'"foo${bar}baz"');
+    expect(string.elements, hasLength(3));
+    var quoteOffset = code.indexOf('"');
+
+    final foo = string.elements[0] as InterpolationString;
+    expect(foo.contentsOffset, quoteOffset + '"'.length);
+    expect(foo.contentsEnd, quoteOffset + '"foo'.length);
+
+    final bar = string.elements[2] as InterpolationString;
+    expect(bar.contentsOffset, quoteOffset + r'"foo${bar}'.length);
+    expect(bar.contentsEnd, quoteOffset + r'"foo${bar}baz'.length);
+  }
+
+  void test_contentsOffset_emptyEnd() async {
+    var code = r'''
+var bar;
+var f = "foo${bar}";
+''';
+    await assertNoErrorsInCode(code);
+    final string = findNode.stringInterpolation(r'"foo${bar}"');
+    expect(string.elements, hasLength(3));
+
+    final end = string.elements[2] as InterpolationString;
+    final endStringOffset = code.indexOf('";');
+    expect(end.contentsOffset, endStringOffset);
+    expect(end.contentsEnd, endStringOffset);
+  }
+
+  void test_contentsOffset_unterminated() async {
+    var code = r'''
+var bar;
+var f = "foo${bar}
+// deliberately unclosed
+;
+''';
+    await assertErrorsInCode(code, [
+      error(ScannerErrorCode.UNTERMINATED_STRING_LITERAL, code.indexOf('}'), 1)
+    ]);
+    final string = findNode.stringInterpolation(r'"foo${bar}');
+    expect(string.elements, hasLength(3));
+
+    final end = string.elements[2] as InterpolationString;
+    final endStringOffset = code.indexOf('}') + 1;
+    expect(end.contentsOffset, endStringOffset);
+    expect(end.contentsEnd, endStringOffset);
+  }
+
+  @FailingTest(issue: 'https://github.com/dart-lang/sdk/issues/42634')
+  void test_contentsOffset_unterminated_wrongQuote() async {
+    var code = r'''
+var bar;
+var f = "foo${bar}'
+// deliberately closed with wrong quote
+;
+''';
+    await assertErrorsInCode(code, [
+      error(ScannerErrorCode.UNTERMINATED_STRING_LITERAL, code.indexOf("'"), 1),
+    ]);
+    final string = findNode.stringInterpolation('"foo\${bar}\'');
+    expect(string.elements, hasLength(3));
+
+    final end = string.elements[2] as InterpolationString;
+    expect(end.value, "'");
+    final endStringOffset = code.indexOf("'") + 1;
+    expect(end.contentsOffset, endStringOffset);
+    expect(end.contentsEnd, endStringOffset);
+  }
+
+  void test_value() async {
+    var code = r'''
+var bar;
+var f = "foo\n$bar";
+''';
+    await assertNoErrorsInCode(code);
+    final string = findNode.stringInterpolation(r'"foo\n$bar"');
+    expect(string.elements, hasLength(3));
+
+    final foo = string.elements[0] as InterpolationString;
+    expect(foo.value, "foo\n");
+  }
+}
diff --git a/pkg/analyzer/test/src/dart/resolution/language_version_test.dart b/pkg/analyzer/test/src/dart/resolution/language_version_test.dart
index 2d30010..2391856 100644
--- a/pkg/analyzer/test/src/dart/resolution/language_version_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/language_version_test.dart
@@ -2,18 +2,16 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/context/packages.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/find_element.dart';
 import 'package:analyzer/src/test_utilities/find_node.dart';
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -24,16 +22,8 @@
 }
 
 @reflectiveTest
-class NullSafetyExperimentGlobalTest extends _FeaturesTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class NullSafetyExperimentGlobalTest extends _FeaturesTest
+    with WithNullSafetyMixin {
   test_jsonConfig_legacyContext_nonNullDependency() async {
     _configureTestWithJsonConfig('''
 {
@@ -141,10 +131,10 @@
     assertErrorsInList(result.errors, []);
     assertType(findElement.topVar('x').type, 'int*');
 
-    // Upgrade the language version to `2.9`, so enabled Null Safety.
+    // Upgrade the language version to `2.10`, so enabled Null Safety.
     driver.changeFile(path);
     await _resolveFile(path, r'''
-// @dart = 2.9
+// @dart = 2.10
 var x = 0;
 ''');
     assertType(findElement.topVar('x').type, 'int');
@@ -172,10 +162,10 @@
 ''');
     assertType(findElement.topVar('x').type, 'int*');
 
-    // Upgrade the language version to `2.9`, so enabled Null Safety.
+    // Upgrade the language version to `2.10`, so enabled Null Safety.
     _changeTestFile();
     await assertNoErrorsInCode('''
-// @dart = 2.9
+// @dart = 2.10
 var x = 0;
 ''');
     assertType(findElement.topVar('x').type, 'int');
diff --git a/pkg/analyzer/test/src/dart/resolution/library_element_test.dart b/pkg/analyzer/test/src/dart/resolution/library_element_test.dart
index 15bef67..0a5c22b 100644
--- a/pkg/analyzer/test/src/dart/resolution/library_element_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/library_element_test.dart
@@ -123,6 +123,255 @@
     await _assertLanguageVersionCurrent('package:aaa/c.dart');
   }
 
+  test_scope_lookup2() async {
+    await assertNoErrorsInCode(r'''
+int foo;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      scope.lookup2('foo').getter,
+      findElement.topGet('foo'),
+    );
+    assertElement(
+      scope.lookup2('foo').setter,
+      findElement.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup2_implicitCoreImport() async {
+    await assertNoErrorsInCode('');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      scope.lookup2('int').getter,
+      intElement,
+    );
+  }
+
+  test_scope_lookup2_notFound() async {
+    await assertNoErrorsInCode('');
+
+    var scope = result.libraryElement.scope;
+
+    assertElementNull(
+      scope.lookup2('noSuchGetter').getter,
+    );
+
+    assertElementNull(
+      scope.lookup2('noSuchSetter').setter,
+    );
+  }
+
+  test_scope_lookup2_prefersLocal() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math';
+
+int sin() => 3;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      scope.lookup2('sin').getter,
+      findElement.topFunction('sin'),
+    );
+
+    assertElement(
+      scope.lookup2('cos').getter,
+      findElement.importFind('dart:math').topFunction('cos'),
+    );
+  }
+
+  test_scope_lookup2_prefix() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      scope.lookup2('math').getter,
+      findElement.prefix('math'),
+    );
+  }
+
+  test_scope_lookup2_respectsCombinator_hide() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' hide sin;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElementNull(
+      scope.lookup2('sin').getter,
+    );
+
+    var mathFind = findElement.importFind('dart:math');
+    assertElement(
+      scope.lookup2('cos').getter,
+      mathFind.topFunction('cos'),
+    );
+    assertElement(
+      scope.lookup2('tan').getter,
+      mathFind.topFunction('tan'),
+    );
+  }
+
+  test_scope_lookup2_respectsCombinator_show() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' show sin;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      scope.lookup2('sin').getter,
+      findElement.importFind('dart:math').topFunction('sin'),
+    );
+
+    assertElementNull(
+      scope.lookup2('cos').getter,
+    );
+  }
+
+  test_scope_lookup_implicitCoreImport() async {
+    await assertNoErrorsInCode('');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'int', setter: false),
+      intElement,
+    );
+  }
+
+  test_scope_lookup_lookup() async {
+    await assertNoErrorsInCode(r'''
+int foo;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: false),
+      findElement.topGet('foo'),
+    );
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: true),
+      findElement.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup_notFound() async {
+    await assertNoErrorsInCode('');
+
+    var scope = result.libraryElement.scope;
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'noSuchGetter', setter: false),
+    );
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'noSuchSetter', setter: true),
+    );
+  }
+
+  test_scope_lookup_prefersLocal() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math';
+
+int sin() => 3;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'sin', setter: false),
+      findElement.topFunction('sin'),
+    );
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'cos', setter: false),
+      findElement.importFind('dart:math').topFunction('cos'),
+    );
+  }
+
+  test_scope_lookup_prefix() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'math', setter: false),
+      findElement.prefix('math'),
+    );
+  }
+
+  test_scope_lookup_respectsCombinator_hide() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' hide sin;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'sin', setter: false),
+    );
+
+    var mathFind = findElement.importFind('dart:math');
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'cos', setter: false),
+      mathFind.topFunction('cos'),
+    );
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'tan', setter: false),
+      mathFind.topFunction('tan'),
+    );
+  }
+
+  test_scope_lookup_respectsCombinator_show() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' show sin;
+''');
+
+    var scope = result.libraryElement.scope;
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'sin', setter: false),
+      findElement.importFind('dart:math').topFunction('sin'),
+    );
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'cos', setter: false),
+    );
+  }
+
   Future<void> _assertLanguageVersion({
     @required String uriStr,
     @required Version package,
diff --git a/pkg/analyzer/test/src/dart/resolution/local_variable_test.dart b/pkg/analyzer/test/src/dart/resolution/local_variable_test.dart
index 84d0e75..143af81 100644
--- a/pkg/analyzer/test/src/dart/resolution/local_variable_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/local_variable_test.dart
@@ -8,8 +8,8 @@
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../constant/potentially_constant_test.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/resolution/metadata_test.dart b/pkg/analyzer/test/src/dart/resolution/metadata_test.dart
index e1ba156..eb2d918 100644
--- a/pkg/analyzer/test/src/dart/resolution/metadata_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/metadata_test.dart
@@ -2,11 +2,9 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/constant/value.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/find_element.dart';
 import 'package:meta/meta.dart';
 import 'package:test/test.dart';
@@ -14,6 +12,7 @@
 
 import '../../summary/resolved_ast_printer.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -183,19 +182,12 @@
 }
 
 @reflectiveTest
-class MetadataResolutionWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+class MetadataResolutionWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   ImportFindElement get import_a {
     return findElement.importFind('package:test/a.dart');
   }
 
-  @override
-  bool get typeToStringWithNullability => true;
-
   test_optIn_fromOptOut_class() async {
     newFile('/test/lib/a.dart', content: r'''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/method_declaration_test.dart b/pkg/analyzer/test/src/dart/resolution/method_declaration_test.dart
new file mode 100644
index 0000000..96e12be
--- /dev/null
+++ b/pkg/analyzer/test/src/dart/resolution/method_declaration_test.dart
@@ -0,0 +1,54 @@
+// 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 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(MethodDeclarationResolutionTest);
+  });
+}
+
+@reflectiveTest
+class MethodDeclarationResolutionTest extends DriverResolutionTest {
+  test_formalParameterScope_defaultValue() async {
+    await assertNoErrorsInCode('''
+class A {
+  static const foo = 0;
+
+  void bar([int foo = foo + 1]) {
+  }
+}
+''');
+
+    assertElement(
+      findNode.simple('foo + 1'),
+      findElement.getter('foo', of: 'A'),
+    );
+  }
+
+  test_formalParameterScope_type() async {
+    await assertNoErrorsInCode('''
+class a {}
+
+class B {
+  void bar(a a) {
+    a;
+  }
+}
+''');
+
+    assertElement(
+      findNode.simple('a a'),
+      findElement.class_('a'),
+    );
+
+    assertElement(
+      findNode.simple('a;'),
+      findElement.parameter('a'),
+    );
+  }
+}
diff --git a/pkg/analyzer/test/src/dart/resolution/method_invocation_test.dart b/pkg/analyzer/test/src/dart/resolution/method_invocation_test.dart
index 096e13c..c9a42b04 100644
--- a/pkg/analyzer/test/src/dart/resolution/method_invocation_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/method_invocation_test.dart
@@ -2,16 +2,14 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -1721,16 +1719,8 @@
 }
 
 @reflectiveTest
-class MethodInvocationResolutionWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class MethodInvocationResolutionWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_hasReceiver_deferredImportPrefix_loadLibrary_optIn_fromOptOut() async {
     newFile('/test/lib/a.dart', content: r'''
 class A {}
diff --git a/pkg/analyzer/test/src/dart/resolution/namespace_test.dart b/pkg/analyzer/test/src/dart/resolution/namespace_test.dart
index 2a0e9d0..e3dff26 100644
--- a/pkg/analyzer/test/src/dart/resolution/namespace_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/namespace_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -30,9 +29,5 @@
 }
 
 @reflectiveTest
-class ImportResolutionWithNnbdTest extends ImportResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-}
+class ImportResolutionWithNnbdTest extends ImportResolutionTest
+    with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/dart/resolution/non_nullable_test.dart b/pkg/analyzer/test/src/dart/resolution/non_nullable_test.dart
index a312c17..b8f394f 100644
--- a/pkg/analyzer/test/src/dart/resolution/non_nullable_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/non_nullable_test.dart
@@ -2,16 +2,14 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/dart/error/hint_codes.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -21,17 +19,7 @@
 }
 
 @reflectiveTest
-class NonNullableTest extends DriverResolutionTest {
-  // TODO(danrubel): Implement a more fine grained way to specify non-nullable.
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class NonNullableTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_class_hierarchy() async {
     await assertNoErrorsInCode('''
 class A {}
diff --git a/pkg/analyzer/test/src/dart/resolution/postfix_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/postfix_expression_test.dart
index e80dec7..aac113d 100644
--- a/pkg/analyzer/test/src/dart/resolution/postfix_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/postfix_expression_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/element/type.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -84,16 +82,7 @@
 
 @reflectiveTest
 class PostfixExpressionResolutionWithNnbdTest
-    extends PostfixExpressionResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends PostfixExpressionResolutionTest with WithNullSafetyMixin {
   test_inc_localVariable_depromote() async {
     await assertNoErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/prefix_element_test.dart b/pkg/analyzer/test/src/dart/resolution/prefix_element_test.dart
new file mode 100644
index 0000000..73b9d2b
--- /dev/null
+++ b/pkg/analyzer/test/src/dart/resolution/prefix_element_test.dart
@@ -0,0 +1,513 @@
+// 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 'package:analyzer/dart/element/element.dart';
+import 'package:analyzer/src/dart/element/element.dart';
+import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import 'driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(PrefixElementTest);
+  });
+}
+
+@reflectiveTest
+class PrefixElementTest extends DriverResolutionTest {
+  test_scope_lookup() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: false),
+      importFind.topGet('foo'),
+    );
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: true),
+      importFind.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup2() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      scope.lookup2('foo').getter,
+      importFind.topGet('foo'),
+    );
+
+    assertElement(
+      scope.lookup2('foo').setter,
+      importFind.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup2_ambiguous_notSdk_both() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+var foo = 1.2;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+
+    var aImport = findElement.importFind('package:test/a.dart');
+    var bImport = findElement.importFind('package:test/b.dart');
+
+    _assertMultiplyDefinedElement(
+      scope.lookup2('foo').getter,
+      [
+        aImport.topGet('foo'),
+        bImport.topGet('foo'),
+      ],
+    );
+
+    _assertMultiplyDefinedElement(
+      scope.lookup2('foo').setter,
+      [
+        aImport.topSet('foo'),
+        bImport.topSet('foo'),
+      ],
+    );
+  }
+
+  test_scope_lookup2_ambiguous_notSdk_first() async {
+    newFile('/test/lib/a.dart', content: r'''
+var pi = 4;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'dart:math' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var aImport = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      scope.lookup2('pi').getter,
+      aImport.topGet('pi'),
+    );
+  }
+
+  test_scope_lookup2_ambiguous_notSdk_second() async {
+    newFile('/test/lib/a.dart', content: r'''
+var pi = 4;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as prefix;
+
+// ignore:unused_import
+import 'a.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var aImport = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      scope.lookup2('pi').getter,
+      aImport.topGet('pi'),
+    );
+  }
+
+  test_scope_lookup2_ambiguous_same() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+export 'a.dart';
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      scope.lookup2('foo').getter,
+      importFind.topGet('foo'),
+    );
+
+    assertElement(
+      scope.lookup2('foo').setter,
+      importFind.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup2_differentPrefix() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+var bar = 0;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix2;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      scope.lookup2('foo').getter,
+      importFind.topGet('foo'),
+    );
+    assertElement(
+      scope.lookup2('foo').setter,
+      importFind.topSet('foo'),
+    );
+
+    assertElementNull(
+      scope.lookup2('bar').getter,
+    );
+    assertElementNull(
+      scope.lookup2('bar').setter,
+    );
+  }
+
+  test_scope_lookup2_notFound() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math;
+''');
+
+    var scope = findElement.prefix('math').scope;
+
+    assertElementNull(
+      scope.lookup2('noSuchGetter').getter,
+    );
+
+    assertElementNull(
+      scope.lookup2('noSuchSetter').setter,
+    );
+  }
+
+  test_scope_lookup2_respectsCombinator_hide() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math hide sin;
+''');
+
+    var scope = findElement.prefix('math').scope;
+    var mathFind = findElement.importFind('dart:math');
+
+    assertElementNull(
+      scope.lookup2('sin').getter,
+    );
+
+    assertElement(
+      scope.lookup2('cos').getter,
+      mathFind.topFunction('cos'),
+    );
+    assertElement(
+      scope.lookup2('tan').getter,
+      mathFind.topFunction('tan'),
+    );
+  }
+
+  test_scope_lookup2_respectsCombinator_show() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math show sin;
+''');
+
+    var scope = findElement.prefix('math').scope;
+    var mathFind = findElement.importFind('dart:math');
+
+    assertElement(
+      scope.lookup2('sin').getter,
+      mathFind.topFunction('sin'),
+    );
+
+    assertElementNull(
+      scope.lookup2('cos').getter,
+    );
+  }
+
+  test_scope_lookup_ambiguous_notSdk_both() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+var foo = 1.2;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+
+    var aImport = findElement.importFind('package:test/a.dart');
+    var bImport = findElement.importFind('package:test/b.dart');
+
+    _assertMultiplyDefinedElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: false),
+      [
+        aImport.topGet('foo'),
+        bImport.topGet('foo'),
+      ],
+    );
+
+    _assertMultiplyDefinedElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: true),
+      [
+        aImport.topSet('foo'),
+        bImport.topSet('foo'),
+      ],
+    );
+  }
+
+  test_scope_lookup_ambiguous_notSdk_first() async {
+    newFile('/test/lib/a.dart', content: r'''
+var pi = 4;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'dart:math' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var aImport = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'pi', setter: false),
+      aImport.topGet('pi'),
+    );
+  }
+
+  test_scope_lookup_ambiguous_notSdk_second() async {
+    newFile('/test/lib/a.dart', content: r'''
+var pi = 4;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as prefix;
+
+// ignore:unused_import
+import 'a.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var aImport = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'pi', setter: false),
+      aImport.topGet('pi'),
+    );
+  }
+
+  test_scope_lookup_ambiguous_same() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+export 'a.dart';
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: false),
+      importFind.topGet('foo'),
+    );
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: true),
+      importFind.topSet('foo'),
+    );
+  }
+
+  test_scope_lookup_differentPrefix() async {
+    newFile('/test/lib/a.dart', content: r'''
+var foo = 0;
+''');
+
+    newFile('/test/lib/b.dart', content: r'''
+var bar = 0;
+''');
+
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'a.dart' as prefix;
+
+// ignore:unused_import
+import 'b.dart' as prefix2;
+''');
+
+    var scope = findElement.prefix('prefix').scope;
+    var importFind = findElement.importFind('package:test/a.dart');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: false),
+      importFind.topGet('foo'),
+    );
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'foo', setter: true),
+      importFind.topSet('foo'),
+    );
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'bar', setter: false),
+    );
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'bar', setter: true),
+    );
+  }
+
+  test_scope_lookup_notFound() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math;
+''');
+
+    var scope = findElement.prefix('math').scope;
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'noSuchGetter', setter: false),
+    );
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'noSuchSetter', setter: true),
+    );
+  }
+
+  test_scope_lookup_respectsCombinator_hide() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math hide sin;
+''');
+
+    var scope = findElement.prefix('math').scope;
+    var mathFind = findElement.importFind('dart:math');
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'sin', setter: false),
+    );
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'cos', setter: false),
+      mathFind.topFunction('cos'),
+    );
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'tan', setter: false),
+      mathFind.topFunction('tan'),
+    );
+  }
+
+  test_scope_lookup_respectsCombinator_show() async {
+    await assertNoErrorsInCode(r'''
+// ignore:unused_import
+import 'dart:math' as math show sin;
+''');
+
+    var scope = findElement.prefix('math').scope;
+    var mathFind = findElement.importFind('dart:math');
+
+    assertElement(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'sin', setter: false),
+      mathFind.topFunction('sin'),
+    );
+
+    assertElementNull(
+      // ignore: deprecated_member_use_from_same_package
+      scope.lookup(id: 'cos', setter: false),
+    );
+  }
+
+  void _assertMultiplyDefinedElement(
+    MultiplyDefinedElementImpl element,
+    List<Element> expected,
+  ) {
+    expect(element.conflictingElements, unorderedEquals(expected));
+  }
+}
diff --git a/pkg/analyzer/test/src/dart/resolution/prefix_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/prefix_expression_test.dart
index 1ca28c5..a22daf3 100644
--- a/pkg/analyzer/test/src/dart/resolution/prefix_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/prefix_expression_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -175,17 +173,7 @@
 
 @reflectiveTest
 class PrefixExpressionResolutionWithNnbdTest
-    extends PrefixExpressionResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends PrefixExpressionResolutionTest with WithNullSafetyMixin {
   test_plusPlus_depromote() async {
     await assertNoErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/prefixed_identifier_test.dart b/pkg/analyzer/test/src/dart/resolution/prefixed_identifier_test.dart
index 8998675..8d0dcac 100644
--- a/pkg/analyzer/test/src/dart/resolution/prefixed_identifier_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/prefixed_identifier_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -61,15 +60,7 @@
 
 @reflectiveTest
 class PrefixedIdentifierResolutionWithNnbdTest
-    extends PrefixedIdentifierResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends PrefixedIdentifierResolutionTest with WithNullSafetyMixin {
   test_deferredImportPrefix_loadLibrary_optIn_fromOptOut() async {
     newFile('/test/lib/a.dart', content: r'''
 class A {}
diff --git a/pkg/analyzer/test/src/dart/resolution/property_access_test.dart b/pkg/analyzer/test/src/dart/resolution/property_access_test.dart
index 41e7bea..7930914 100644
--- a/pkg/analyzer/test/src/dart/resolution/property_access_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/property_access_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -36,16 +35,8 @@
 }
 
 @reflectiveTest
-class PropertyAccessResolutionWithNnbdTest
-    extends PropertyAccessResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class PropertyAccessResolutionWithNnbdTest extends PropertyAccessResolutionTest
+    with WithNullSafetyMixin {
   test_implicitCall_tearOff_nullable() async {
     await assertErrorsInCode('''
 class A {
diff --git a/pkg/analyzer/test/src/dart/resolution/resolution.dart b/pkg/analyzer/test/src/dart/resolution/resolution.dart
index 63c6e6d..df4940b 100644
--- a/pkg/analyzer/test/src/dart/resolution/resolution.dart
+++ b/pkg/analyzer/test/src/dart/resolution/resolution.dart
@@ -206,9 +206,15 @@
     }
   }
 
-  void assertElementNull(Expression node) {
-    Element actual = getNodeElement(node);
-    expect(actual, isNull);
+  void assertElementNull(Object nodeOrElement) {
+    Element element;
+    if (nodeOrElement is AstNode) {
+      element = getNodeElement(nodeOrElement);
+    } else {
+      element = nodeOrElement as Element;
+    }
+
+    expect(element, isNull);
   }
 
   void assertElementString(Element element, String expected) {
@@ -257,6 +263,16 @@
     return result;
   }
 
+  Future<void> assertErrorsInFile2(
+    String path,
+    List<ExpectedError> expectedErrors,
+  ) async {
+    path = convertPath(path);
+
+    var result = await resolveFile(path);
+    assertErrorsInResolvedUnit(result, expectedErrors);
+  }
+
   void assertErrorsInList(
     List<AnalysisError> errors,
     List<ExpectedError> expectedErrors,
diff --git a/pkg/analyzer/test/src/dart/resolution/simple_identifier_test.dart b/pkg/analyzer/test/src/dart/resolution/simple_identifier_test.dart
index a79a25e..3723684 100644
--- a/pkg/analyzer/test/src/dart/resolution/simple_identifier_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/simple_identifier_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -115,15 +114,7 @@
 
 @reflectiveTest
 class SimpleIdentifierResolutionWithNnbdTest
-    extends SimpleIdentifierResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends SimpleIdentifierResolutionTest with WithNullSafetyMixin {
   test_functionReference() async {
     await assertErrorsInCode('''
 // @dart = 2.7
diff --git a/pkg/analyzer/test/src/dart/resolution/test_all.dart b/pkg/analyzer/test/src/dart/resolution/test_all.dart
index 33cdc60..1b33b1b 100644
--- a/pkg/analyzer/test/src/dart/resolution/test_all.dart
+++ b/pkg/analyzer/test/src/dart/resolution/test_all.dart
@@ -20,6 +20,7 @@
 import 'field_test.dart' as field;
 import 'for_element_test.dart' as for_element;
 import 'for_statement_test.dart' as for_in;
+import 'function_declaration_test.dart' as function_declaration;
 import 'function_expression_invocation_test.dart'
     as function_expression_invocation;
 import 'function_type_alias_test.dart' as function_type_alias;
@@ -35,17 +36,20 @@
     as instance_member_inference_class;
 import 'instance_member_inference_mixin_test.dart'
     as instance_member_inference_mixin;
+import 'interpolation_string_test.dart' as interpolation_string;
 import 'language_version_test.dart' as language_version;
 import 'library_element_test.dart' as library_element;
 import 'local_function_test.dart' as local_function;
 import 'local_variable_test.dart' as local_variable;
 import 'metadata_test.dart' as metadata;
+import 'method_declaration_test.dart' as method_declaration;
 import 'method_invocation_test.dart' as method_invocation;
 import 'mixin_test.dart' as mixin_resolution;
 import 'namespace_test.dart' as namespace;
 import 'non_nullable_test.dart' as non_nullable;
 import 'optional_const_test.dart' as optional_const;
 import 'postfix_expression_test.dart' as postfix_expression;
+import 'prefix_element_test.dart' as prefix_element;
 import 'prefix_expression_test.dart' as prefix_expression;
 import 'prefixed_identifier_test.dart' as prefixed_identifier;
 import 'property_access_test.dart' as property_access;
@@ -75,6 +79,7 @@
     field.main();
     for_element.main();
     for_in.main();
+    function_declaration.main();
     function_expression_invocation.main();
     function_type_alias.main();
     generic_function_type.main();
@@ -87,17 +92,20 @@
     instance_creation.main();
     instance_member_inference_class.main();
     instance_member_inference_mixin.main();
+    interpolation_string.main();
     language_version.main();
     library_element.main();
     local_function.main();
     local_variable.main();
     metadata.main();
+    method_declaration.main();
     method_invocation.main();
     mixin_resolution.main();
     namespace.main();
     non_nullable.main();
     optional_const.main();
     postfix_expression.main();
+    prefix_element.main();
     prefix_expression.main();
     prefixed_identifier.main();
     property_access.main();
diff --git a/pkg/analyzer/test/src/dart/resolution/top_level_variable_test.dart b/pkg/analyzer/test/src/dart/resolution/top_level_variable_test.dart
index 8640cb0..009a713 100644
--- a/pkg/analyzer/test/src/dart/resolution/top_level_variable_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/top_level_variable_test.dart
@@ -4,8 +4,8 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../constant/potentially_constant_test.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/resolution/try_statement_test.dart b/pkg/analyzer/test/src/dart/resolution/try_statement_test.dart
index 2b544e6..781cbf9 100644
--- a/pkg/analyzer/test/src/dart/resolution/try_statement_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/try_statement_test.dart
@@ -5,8 +5,8 @@
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../constant/potentially_constant_test.dart';
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/collection_elements_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/collection_elements_test.dart
index 33f1c6b..d099eeb 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/collection_elements_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/collection_elements_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,15 +16,8 @@
 }
 
 @reflectiveTest
-class ForElementWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ForElementWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_list_awaitForIn_dynamic_downward() async {
     await resolveTestCode('''
 void f() async {
@@ -202,15 +194,8 @@
 }
 
 @reflectiveTest
-class IfElementWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class IfElementWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_list_downward() async {
     await resolveTestCode('''
 void f() {
@@ -246,15 +231,8 @@
 }
 
 @reflectiveTest
-class SpreadElementWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class SpreadElementWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_list_downward() async {
     await resolveTestCode('''
 void f() {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/conditional_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/conditional_expression_test.dart
index 6f28467..5064cc4 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/conditional_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/conditional_expression_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -29,15 +28,8 @@
 }
 
 @reflectiveTest
-class ConditionalExpressionWithNnbdTest extends ConditionalExpressionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ConditionalExpressionWithNnbdTest extends ConditionalExpressionTest
+    with WithNullSafetyMixin {
   @failingTest
   test_downward() async {
     await resolveTestCode('''
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/equality_expressions_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/equality_expressions_test.dart
index ddbebd7..000757f 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/equality_expressions_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/equality_expressions_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -31,15 +30,7 @@
 }
 
 @reflectiveTest
-class EqualWithNnbdTest extends EqualTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+class EqualWithNnbdTest extends EqualTest with WithNullSafetyMixin {}
 
 @reflectiveTest
 class NotEqualTest extends DriverResolutionTest {
@@ -55,12 +46,4 @@
 }
 
 @reflectiveTest
-class NotEqualWithNnbdTest extends NotEqualTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+class NotEqualWithNnbdTest extends NotEqualTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/function_expression_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/function_expression_test.dart
index 2c08363..ab68f20 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/function_expression_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/function_expression_test.dart
@@ -2,11 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
+import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,6 +17,50 @@
 
 @reflectiveTest
 class FunctionExpressionTest extends DriverResolutionTest {
+  test_contextFunctionType_returnType_async_blockBody_futureOrVoid() async {
+    var expectedErrors = expectedErrorsByNullability(
+      nullable: [
+        error(StaticTypeWarningCode.RETURN_OF_INVALID_TYPE_FROM_CLOSURE, 72, 1),
+      ],
+      legacy: [],
+    );
+    await assertErrorsInCode('''
+import 'dart:async';
+
+FutureOr<void> Function() v = () async {
+  return 0;
+};
+''', expectedErrors);
+    _assertReturnType(
+      '() async {',
+      typeStringByNullability(
+        nullable: 'Future<void>',
+        legacy: 'Future<int>',
+      ),
+    );
+  }
+
+  test_contextFunctionType_returnType_async_blockBody_futureVoid() async {
+    var expectedErrors = expectedErrorsByNullability(
+      nullable: [
+        error(StaticTypeWarningCode.RETURN_OF_INVALID_TYPE_FROM_CLOSURE, 48, 1),
+      ],
+      legacy: [],
+    );
+    await assertErrorsInCode('''
+Future<void> Function() v = () async {
+  return 0;
+};
+''', expectedErrors);
+    _assertReturnType(
+      '() async {',
+      typeStringByNullability(
+        nullable: 'Future<void>',
+        legacy: 'Future<int>',
+      ),
+    );
+  }
+
   test_contextFunctionType_returnType_async_expressionBody() async {
     await assertNoErrorsInCode('''
 Future<num> Function() v = () async => 0;
@@ -118,6 +162,24 @@
     _assertReturnType('() {', 'int');
   }
 
+  test_contextFunctionType_returnType_sync_blockBody_void() async {
+    var expectedErrors = expectedErrorsByNullability(nullable: [
+      error(StaticTypeWarningCode.RETURN_OF_INVALID_TYPE_FROM_CLOSURE, 34, 1),
+    ], legacy: []);
+    await assertErrorsInCode('''
+void Function() v = () {
+  return 0;
+};
+''', expectedErrors);
+    _assertReturnType(
+      '() {',
+      typeStringByNullability(
+        nullable: 'void',
+        legacy: 'int',
+      ),
+    );
+  }
+
   test_contextFunctionType_returnType_sync_expressionBody() async {
     await assertNoErrorsInCode('''
 num Function() v = () => 0;
@@ -398,15 +460,8 @@
 }
 
 @reflectiveTest
-class FunctionExpressionWithNnbdTest extends FunctionExpressionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class FunctionExpressionWithNnbdTest extends FunctionExpressionTest
+    with WithNullSafetyMixin {
   test_contextFunctionType_nonNullify() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.7
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/list_literal_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/list_literal_test.dart
index d287dbd..05da0da 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/list_literal_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/list_literal_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -319,15 +318,7 @@
 }
 
 @reflectiveTest
-class ListLiteralWithNnbdTest extends ListLiteralTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ListLiteralWithNnbdTest extends ListLiteralTest with WithNullSafetyMixin {
   test_context_spread_nullAware() async {
     await assertNoErrorsInCode('''
 T f<T>(T t) => t;
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/local_variable_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/local_variable_test.dart
index 48ebf3e..a68d785 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/local_variable_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/local_variable_test.dart
@@ -4,8 +4,8 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../../constant/potentially_constant_test.dart';
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/logical_boolean_expressions_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/logical_boolean_expressions_test.dart
index 02eedf3..e291cd3 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/logical_boolean_expressions_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/logical_boolean_expressions_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -31,15 +30,7 @@
 }
 
 @reflectiveTest
-class LogicalAndWithNnbdTest extends LogicalAndTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class LogicalAndWithNnbdTest extends LogicalAndTest with WithNullSafetyMixin {
   @failingTest
   test_downward() async {
     await resolveTestCode('''
@@ -69,15 +60,7 @@
 }
 
 @reflectiveTest
-class LogicalOrWithNnbdTest extends LogicalOrTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class LogicalOrWithNnbdTest extends LogicalOrTest with WithNullSafetyMixin {
   @failingTest
   test_downward() async {
     await resolveTestCode('''
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/map_literal_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/map_literal_test.dart
index 6f441c5..d76fc15 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/map_literal_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/map_literal_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -366,16 +364,7 @@
 }
 
 @reflectiveTest
-class MapLiteralWithNnbdTest extends MapLiteralTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class MapLiteralWithNnbdTest extends MapLiteralTest with WithNullSafetyMixin {
   test_context_noTypeArgs_noEntries_typeParameterNullable() async {
     await resolveTestCode('''
 class C<T extends Object?> {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/set_literal_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/set_literal_test.dart
index 0711c83..3a6ef21 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/set_literal_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/set_literal_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -278,16 +276,7 @@
 }
 
 @reflectiveTest
-class SetLiteralWithNnbdTest extends SetLiteralTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class SetLiteralWithNnbdTest extends SetLiteralTest with WithNullSafetyMixin {
   AstNode setOrMapLiteral(String search) => findNode.setOrMapLiteral(search);
 
   test_context_noTypeArgs_noEntries() async {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/statements_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/statements_test.dart
index 025800d..8c83c92 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/statements_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/statements_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -19,15 +18,7 @@
 }
 
 @reflectiveTest
-class AssertWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class AssertWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_downward() async {
     await resolveTestCode('''
 void f() {
@@ -40,15 +31,7 @@
 }
 
 @reflectiveTest
-class DoWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class DoWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_downward() async {
     await resolveTestCode('''
 void f() {
@@ -61,15 +44,7 @@
 }
 
 @reflectiveTest
-class ForWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ForWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_awaitForIn_dynamic_downward() async {
     await resolveTestCode('''
 void f() async {
@@ -125,15 +100,7 @@
 }
 
 @reflectiveTest
-class IfWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class IfWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_downward() async {
     await resolveTestCode('''
 void f() {
@@ -146,15 +113,7 @@
 }
 
 @reflectiveTest
-class WhileWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class WhileWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_downward() async {
     await resolveTestCode('''
 void f() {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/throw_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/throw_test.dart
index d8a978c..e0e5e47 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/throw_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/throw_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -15,15 +14,7 @@
 }
 
 @reflectiveTest
-class ThrowWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ThrowWithNnbdTest extends DriverResolutionTest with WithNullSafetyMixin {
   test_downward() async {
     await resolveTestCode('''
 void f() {
diff --git a/pkg/analyzer/test/src/dart/resolution/type_inference/type_test_expressions_test.dart b/pkg/analyzer/test/src/dart/resolution/type_inference/type_test_expressions_test.dart
index f90d562..35a0efc 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_inference/type_test_expressions_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_inference/type_test_expressions_test.dart
@@ -2,11 +2,10 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../driver_resolution.dart';
+import '../with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -31,15 +30,7 @@
 }
 
 @reflectiveTest
-class IsNotWithNnbdTest extends IsNotTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+class IsNotWithNnbdTest extends IsNotTest with WithNullSafetyMixin {}
 
 @reflectiveTest
 class IsTest extends DriverResolutionTest {
@@ -55,12 +46,4 @@
 }
 
 @reflectiveTest
-class IsWithNnbdTest extends IsTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+class IsWithNnbdTest extends IsTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/dart/resolution/type_name_test.dart b/pkg/analyzer/test/src/dart/resolution/type_name_test.dart
index 89f9a8e..e907e3c 100644
--- a/pkg/analyzer/test/src/dart/resolution/type_name_test.dart
+++ b/pkg/analyzer/test/src/dart/resolution/type_name_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/find_element.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'driver_resolution.dart';
+import 'with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -256,12 +255,8 @@
 }
 
 @reflectiveTest
-class TypeNameResolutionWithNnbdTest extends TypeNameResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+class TypeNameResolutionWithNnbdTest extends TypeNameResolutionTest
+    with WithNullSafetyMixin {
   ImportFindElement get import_a {
     return findElement.importFind('package:test/a.dart');
   }
diff --git a/pkg/analyzer/test/src/dart/resolution/with_null_safety_mixin.dart b/pkg/analyzer/test/src/dart/resolution/with_null_safety_mixin.dart
new file mode 100644
index 0000000..300f0a6
--- /dev/null
+++ b/pkg/analyzer/test/src/dart/resolution/with_null_safety_mixin.dart
@@ -0,0 +1,20 @@
+// 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 'package:analyzer/dart/analysis/features.dart';
+import 'package:analyzer/src/dart/analysis/experiments.dart';
+import 'package:analyzer/src/generated/engine.dart';
+
+import 'driver_resolution.dart';
+
+mixin WithNullSafetyMixin on DriverResolutionTest {
+  @override
+  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
+    ..contextFeatures = FeatureSet.fromEnableFlags(
+      [EnableString.non_nullable],
+    );
+
+  @override
+  bool get typeToStringWithNullability => true;
+}
diff --git a/pkg/analyzer/test/src/diagnostics/abstract_class_member_test.dart b/pkg/analyzer/test/src/diagnostics/abstract_class_member_test.dart
new file mode 100644
index 0000000..482f4f7
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/abstract_class_member_test.dart
@@ -0,0 +1,59 @@
+// 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 'package:analyzer/src/dart/error/syntactic_errors.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AbstractClassMemberTest);
+    defineReflectiveTests(AbstractClassMemberTest_NNBD);
+  });
+}
+
+@reflectiveTest
+class AbstractClassMemberTest extends DriverResolutionTest {
+  test_abstract_field_dynamic() async {
+    await assertErrorsInCode(
+        '''
+abstract class A {
+  abstract dynamic x;
+}
+''',
+        expectedErrorsByNullability(nullable: [], legacy: [
+          error(ParserErrorCode.ABSTRACT_CLASS_MEMBER, 21, 8),
+        ]));
+  }
+
+  test_abstract_field_untyped() async {
+    await assertErrorsInCode(
+        '''
+abstract class A {
+  abstract var x;
+}
+''',
+        expectedErrorsByNullability(nullable: [], legacy: [
+          error(ParserErrorCode.ABSTRACT_CLASS_MEMBER, 21, 8),
+        ]));
+  }
+
+  test_abstract_field_untyped_covariant() async {
+    await assertErrorsInCode(
+        '''
+abstract class A {
+  abstract covariant var x;
+}
+''',
+        expectedErrorsByNullability(nullable: [], legacy: [
+          error(ParserErrorCode.ABSTRACT_CLASS_MEMBER, 21, 8),
+        ]));
+  }
+}
+
+@reflectiveTest
+class AbstractClassMemberTest_NNBD extends AbstractClassMemberTest
+    with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/access_private_enum_field_test.dart b/pkg/analyzer/test/src/diagnostics/access_private_enum_field_test.dart
new file mode 100644
index 0000000..51f67e5
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/access_private_enum_field_test.dart
@@ -0,0 +1,29 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AccessPrivateEnumFieldTest);
+  });
+}
+
+@reflectiveTest
+class AccessPrivateEnumFieldTest extends DriverResolutionTest {
+  @failingTest
+  test_name() async {
+    await assertErrorsInCode(r'''
+enum E { ONE }
+String name(E e) {
+  return e._name;
+}
+''', [
+      error(CompileTimeErrorCode.ACCESS_PRIVATE_ENUM_FIELD, 45, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/ambiguous_set_or_map_literal_test.dart b/pkg/analyzer/test/src/diagnostics/ambiguous_set_or_map_literal_test.dart
index 873f765..9c0e858 100644
--- a/pkg/analyzer/test/src/diagnostics/ambiguous_set_or_map_literal_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/ambiguous_set_or_map_literal_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -65,12 +64,7 @@
 
 @reflectiveTest
 class AmbiguousSetOrMapLiteralBothWithNnbdTest
-    extends AmbiguousSetOrMapLiteralBothTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends AmbiguousSetOrMapLiteralBothTest with WithNullSafetyMixin {
   test_map_keyNonNullable_valueNullable() async {
     await assertNoErrorsInCode('''
 f(Map<int, int?> map) {
@@ -138,9 +132,4 @@
 
 @reflectiveTest
 class AmbiguousSetOrMapLiteralEitherWithNnbdTest
-    extends AmbiguousSetOrMapLiteralEitherTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-}
+    extends AmbiguousSetOrMapLiteralEitherTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/annotation_with_non_class_test.dart b/pkg/analyzer/test/src/diagnostics/annotation_with_non_class_test.dart
new file mode 100644
index 0000000..c7efb9f
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/annotation_with_non_class_test.dart
@@ -0,0 +1,53 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AnnotationWithNonClassTest);
+  });
+}
+
+@reflectiveTest
+class AnnotationWithNonClassTest extends DriverResolutionTest {
+  test_instance() async {
+    await assertErrorsInCode('''
+class Property {
+  final int value;
+  const Property(this.value);
+}
+
+const Property property = const Property(42);
+
+@property(123)
+main() {
+}
+''', [
+      error(CompileTimeErrorCode.ANNOTATION_WITH_NON_CLASS, 117, 8),
+    ]);
+  }
+
+  test_prefixed() async {
+    newFile("/test/lib/annotations.dart", content: r'''
+class Property {
+  final int value;
+  const Property(this.value);
+}
+
+const Property property = const Property(42);
+''');
+    await assertErrorsInCode('''
+import 'annotations.dart' as pref;
+@pref.property(123)
+main() {
+}
+''', [
+      error(CompileTimeErrorCode.ANNOTATION_WITH_NON_CLASS, 36, 13),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/argument_type_not_assignable_test.dart b/pkg/analyzer/test/src/diagnostics/argument_type_not_assignable_test.dart
index 3fd011e..f8c9440 100644
--- a/pkg/analyzer/test/src/diagnostics/argument_type_not_assignable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/argument_type_not_assignable_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -180,15 +178,53 @@
     ]);
   }
 
-  test_index() async {
+  test_index_invalidRead() async {
     await assertErrorsInCode('''
 class A {
-  operator [](int index) {}
+  int operator [](int index) => 0;
 }
 f(A a) {
   a['0'];
 }''', [
-      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 53, 3),
+      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 60, 3),
+    ]);
+  }
+
+  test_index_invalidRead_validWrite() async {
+    await assertErrorsInCode('''
+class A {
+  int operator [](int index) => 0;
+  operator []=(String index, int value) {}
+}
+f(A a) {
+  a['0'] += 0;
+}''', [
+      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 103, 3),
+    ]);
+  }
+
+  test_index_invalidWrite() async {
+    await assertErrorsInCode('''
+class A {
+  operator []=(int index, int value) {}
+}
+f(A a) {
+  a['0'] = 0;
+}''', [
+      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 65, 3),
+    ]);
+  }
+
+  test_index_validRead_invalidWrite() async {
+    await assertErrorsInCode('''
+class A {
+  int operator [](String index) => 0;
+  operator []=(int index, int value) {}
+}
+f(A a) {
+  a['0'] += 0;
+}''', [
+      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 103, 3),
     ]);
   }
 
@@ -251,12 +287,25 @@
 
   test_invocation_functionTypes_optional() async {
     await assertErrorsInCode('''
-void acceptFunNumOptBool(void funNumOptBool([bool b])) {}
-void funNumBool(bool b) {}
+void acceptFunOptBool(void funNumOptBool([bool b])) {}
+void funBool(bool b) {}
 main() {
-  acceptFunNumOptBool(funNumBool);
+  acceptFunOptBool(funBool);
 }''', [
-      error(StrongModeCode.INVALID_CAST_FUNCTION, 116, 10),
+      error(CompileTimeErrorCode.INVALID_CAST_FUNCTION, 107, 7),
+    ]);
+  }
+
+  test_invocation_functionTypes_optional_method() async {
+    await assertErrorsInCode('''
+void acceptFunOptBool(void funOptBool([bool b])) {}
+class C {
+  static void funBool(bool b) {}
+}
+main() {
+  acceptFunOptBool(C.funBool);
+}''', [
+      error(CompileTimeErrorCode.INVALID_CAST_METHOD, 125, 9),
     ]);
   }
 
@@ -387,13 +436,8 @@
 }
 
 @reflectiveTest
-class ArgumentTypeNotAssignableTest_NNBD extends ArgumentTypeNotAssignableTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class ArgumentTypeNotAssignableTest_NNBD extends ArgumentTypeNotAssignableTest
+    with WithNullSafetyMixin {
   test_binary_eqEq_covariantParameterType() async {
     await assertErrorsInCode(r'''
 class A {
@@ -453,4 +497,18 @@
     // The test is currently generating an error where none is expected.
     await super.test_invocation_functionTypes_optional();
   }
+
+  @override
+  test_invocation_functionTypes_optional_method() async {
+    await assertErrorsInCode('''
+void acceptFunOptBool(void funOptBool([bool b])) {}
+class C {
+  static void funBool(bool b) {}
+}
+main() {
+  acceptFunOptBool(C.funBool);
+}''', [
+      error(StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, 125, 9),
+    ]);
+  }
 }
diff --git a/pkg/analyzer/test/src/diagnostics/assignment_to_final_local_test.dart b/pkg/analyzer/test/src/diagnostics/assignment_to_final_local_test.dart
index cec3b98..9186e08 100644
--- a/pkg/analyzer/test/src/diagnostics/assignment_to_final_local_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/assignment_to_final_local_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/dart/error/hint_codes.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -138,12 +137,8 @@
 }
 
 @reflectiveTest
-class AssignmentToFinalLocalWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class AssignmentToFinalLocalWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_localVariable_late() async {
     await assertNoErrorsInCode('''
 void f() {
diff --git a/pkg/analyzer/test/src/diagnostics/assignment_to_final_test.dart b/pkg/analyzer/test/src/diagnostics/assignment_to_final_test.dart
index f1e2dfa..b566feb 100644
--- a/pkg/analyzer/test/src/diagnostics/assignment_to_final_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/assignment_to_final_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -46,12 +45,8 @@
 }
 
 @reflectiveTest
-class AssignmentToFinalWithNnbdTest extends AssignmentToFinalTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class AssignmentToFinalWithNnbdTest extends AssignmentToFinalTest
+    with WithNullSafetyMixin {
   test_field_late() async {
     await assertNoErrorsInCode('''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/async_for_in_wrong_context_test.dart b/pkg/analyzer/test/src/diagnostics/async_for_in_wrong_context_test.dart
new file mode 100644
index 0000000..bc68e84
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/async_for_in_wrong_context_test.dart
@@ -0,0 +1,29 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AsyncForInWrongContextTest);
+  });
+}
+
+@reflectiveTest
+class AsyncForInWrongContextTest extends DriverResolutionTest {
+  test_syncFunction() async {
+    await assertErrorsInCode(r'''
+f(list) {
+  await for (var e in list) {
+  }
+}
+''', [
+      error(HintCode.UNUSED_LOCAL_VARIABLE, 27, 1),
+      error(CompileTimeErrorCode.ASYNC_FOR_IN_WRONG_CONTEXT, 29, 2),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/await_in_late_local_variable_initializer_test.dart b/pkg/analyzer/test/src/diagnostics/await_in_late_local_variable_initializer_test.dart
index 0dd2f98..15e3574 100644
--- a/pkg/analyzer/test/src/diagnostics/await_in_late_local_variable_initializer_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/await_in_late_local_variable_initializer_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,15 +15,11 @@
 }
 
 @reflectiveTest
-class AwaitInLateLocalVariableInitializerTest extends DriverResolutionTest {
+class AwaitInLateLocalVariableInitializerTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   static const _errorCode =
       CompileTimeErrorCode.AWAIT_IN_LATE_LOCAL_VARIABLE_INITIALIZER;
 
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
   test_closure_late_await() async {
     await assertErrorsInCode('''
 main() {
diff --git a/pkg/analyzer/test/src/diagnostics/await_in_wrong_context_test.dart b/pkg/analyzer/test/src/diagnostics/await_in_wrong_context_test.dart
new file mode 100644
index 0000000..d3184df
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/await_in_wrong_context_test.dart
@@ -0,0 +1,44 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(AwaitInWrongContextTest);
+  });
+}
+
+@reflectiveTest
+class AwaitInWrongContextTest extends DriverResolutionTest {
+  @failingTest
+  test_sync() async {
+    // This test requires better error recovery than we currently have. In
+    // particular, we need to be able to distinguish between an await expression
+    // in the wrong context, and the use of 'await' as an identifier.
+    await assertErrorsInCode(r'''
+f(x) {
+  return await x;
+}
+''', [
+      error(CompileTimeErrorCode.AWAIT_IN_WRONG_CONTEXT, 16, 5),
+    ]);
+  }
+
+  test_syncStar() async {
+    // This test requires better error recovery than we currently have. In
+    // particular, we need to be able to distinguish between an await expression
+    // in the wrong context, and the use of 'await' as an identifier.
+    await assertErrorsInCode(r'''
+f(x) sync* {
+  yield await x;
+}
+''', [
+      error(CompileTimeErrorCode.AWAIT_IN_WRONG_CONTEXT, 21, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/body_might_complete_normally_test.dart b/pkg/analyzer/test/src/diagnostics/body_might_complete_normally_test.dart
index c19c96d..4581677 100644
--- a/pkg/analyzer/test/src/diagnostics/body_might_complete_normally_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/body_might_complete_normally_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,12 +15,8 @@
 }
 
 @reflectiveTest
-class BodyMayCompleteNormallyTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+class BodyMayCompleteNormallyTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_factoryConstructor_named_blockBody() async {
     await assertErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/case_expression_type_implements_equals_test.dart b/pkg/analyzer/test/src/diagnostics/case_expression_type_implements_equals_test.dart
index d6b69ce..a44e629 100644
--- a/pkg/analyzer/test/src/diagnostics/case_expression_type_implements_equals_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/case_expression_type_implements_equals_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -108,12 +107,7 @@
 
 @reflectiveTest
 class CaseExpressionTypeImplementsEqualsWithNnbdTest
-    extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends DriverResolutionTest with WithNullSafetyMixin {
   test_declares() async {
     await assertNoErrorsInCode(r'''
 abstract class A {
diff --git a/pkg/analyzer/test/src/diagnostics/case_expression_type_is_not_switch_expression_subtype_test.dart b/pkg/analyzer/test/src/diagnostics/case_expression_type_is_not_switch_expression_subtype_test.dart
index 1561646..741cb7e 100644
--- a/pkg/analyzer/test/src/diagnostics/case_expression_type_is_not_switch_expression_subtype_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/case_expression_type_is_not_switch_expression_subtype_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,12 +16,7 @@
 
 @reflectiveTest
 class CaseExpressionTypeIsNotSswitchExpressionSubtype
-    extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends DriverResolutionTest with WithNullSafetyMixin {
   CompileTimeErrorCode get _errorCode {
     return CompileTimeErrorCode
         .CASE_EXPRESSION_TYPE_IS_NOT_SWITCH_EXPRESSION_SUBTYPE;
diff --git a/pkg/analyzer/test/src/diagnostics/conflicting_generic_interfaces_test.dart b/pkg/analyzer/test/src/diagnostics/conflicting_generic_interfaces_test.dart
index 2364d00..9bd6ec2 100644
--- a/pkg/analyzer/test/src/diagnostics/conflicting_generic_interfaces_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/conflicting_generic_interfaces_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -74,12 +73,7 @@
 
 @reflectiveTest
 class ConflictingGenericInterfacesWithNnbdTest
-    extends ConflictingGenericInterfacesTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends ConflictingGenericInterfacesTest with WithNullSafetyMixin {
   test_class_extends_implements_never() async {
     await assertNoErrorsInCode('''
 class I<T> {}
diff --git a/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_const_super_test.dart b/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_const_super_test.dart
new file mode 100644
index 0000000..6c7f9c3
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_const_super_test.dart
@@ -0,0 +1,43 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstConstructorWithNonConstSuperTest);
+  });
+}
+
+@reflectiveTest
+class ConstConstructorWithNonConstSuperTest extends DriverResolutionTest {
+  test_explicit() async {
+    await assertErrorsInCode(r'''
+class A {
+  A();
+}
+class B extends A {
+  const B(): super();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 52, 7),
+    ]);
+  }
+
+  test_implicit() async {
+    await assertErrorsInCode(r'''
+class A {
+  A();
+}
+class B extends A {
+  const B();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 47, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_final_field_test.dart b/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_final_field_test.dart
new file mode 100644
index 0000000..6162be7
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_constructor_with_non_final_field_test.dart
@@ -0,0 +1,68 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstConstructorWithNonFinalFieldTest);
+  });
+}
+
+@reflectiveTest
+class ConstConstructorWithNonFinalFieldTest extends DriverResolutionTest {
+  test_mixin() async {
+    await assertErrorsInCode(r'''
+class A {
+  var a;
+}
+class B extends Object with A {
+  const B();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 61, 1),
+      error(
+          CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_MIXIN_WITH_FIELD, 61, 1),
+    ]);
+  }
+
+  test_super() async {
+    await assertErrorsInCode(r'''
+class A {
+  var a;
+}
+class B extends A {
+  const B();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 49, 1),
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_CONST_SUPER, 49, 1),
+    ]);
+  }
+
+  test_this_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  int x;
+  const A.a();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 27, 3),
+    ]);
+  }
+
+  test_this_unnamed() async {
+    await assertErrorsInCode(r'''
+class A {
+  int x;
+  const A();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_CONSTRUCTOR_WITH_NON_FINAL_FIELD, 27, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_deferred_class_test.dart b/pkg/analyzer/test/src/diagnostics/const_deferred_class_test.dart
new file mode 100644
index 0000000..194f0a4
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_deferred_class_test.dart
@@ -0,0 +1,51 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstDeferredClassTest);
+  });
+}
+
+@reflectiveTest
+class ConstDeferredClassTest extends DriverResolutionTest {
+  test_namedConstructor() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+class A {
+  const A.b();
+}''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+main() {
+  const a.A.b();
+}''', [
+      error(CompileTimeErrorCode.CONST_DEFERRED_CLASS, 65, 5),
+    ]);
+  }
+
+  test_unnamed() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+class A {
+  const A();
+}
+''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+main() {
+  const a.A();
+}
+''', [
+      error(CompileTimeErrorCode.CONST_DEFERRED_CLASS, 65, 3),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_eval_throws_exception_test.dart b/pkg/analyzer/test/src/diagnostics/const_eval_throws_exception_test.dart
index c688c88..9a1dbd5 100644
--- a/pkg/analyzer/test/src/diagnostics/const_eval_throws_exception_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/const_eval_throws_exception_test.dart
@@ -9,8 +9,8 @@
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_num_string_test.dart b/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_num_string_test.dart
new file mode 100644
index 0000000..529707d
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_num_string_test.dart
@@ -0,0 +1,50 @@
+// 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 'package:analyzer/src/dart/analysis/experiments.dart';
+import 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstEvalTypeBoolNumStringTest);
+  });
+}
+
+@reflectiveTest
+class ConstEvalTypeBoolNumStringTest extends DriverResolutionTest {
+  test_equal() async {
+    await assertErrorsInCode(
+        r'''
+class A {
+  const A();
+}
+
+const num a = 0;
+const b = a == const A();
+''',
+        IsEnabledByDefault.constant_update_2018
+            ? []
+            : [
+                error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL_NUM_STRING, 53,
+                    14),
+              ]);
+  }
+
+  test_notEqual() async {
+    await assertErrorsInCode(r'''
+class A {
+  const A();
+}
+
+const num a = 0;
+const _ = a != const A();
+''', [
+      error(HintCode.UNUSED_ELEMENT, 49, 1),
+      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL_NUM_STRING, 53, 14),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_test.dart b/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_test.dart
new file mode 100644
index 0000000..711122d
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_eval_type_bool_test.dart
@@ -0,0 +1,54 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstEvalTypeBoolTest);
+  });
+}
+
+@reflectiveTest
+class ConstEvalTypeBoolTest extends DriverResolutionTest {
+  test_binary_and() async {
+    await assertErrorsInCode('''
+const c = true && '';
+''', [
+      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL, 10, 10),
+      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 18, 2),
+    ]);
+  }
+
+  test_binary_leftTrue() async {
+    await assertErrorsInCode('''
+const c = (true || 0);
+''', [
+      error(HintCode.DEAD_CODE, 19, 1),
+      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 19, 1),
+    ]);
+  }
+
+  test_binary_or() async {
+    await assertErrorsInCode(r'''
+const c = false || '';
+''', [
+      error(CompileTimeErrorCode.CONST_EVAL_TYPE_BOOL, 10, 11),
+      error(StaticTypeWarningCode.NON_BOOL_OPERAND, 19, 2),
+    ]);
+  }
+
+  test_logicalOr_trueLeftOperand() async {
+    await assertNoErrorsInCode(r'''
+class C {
+  final int x;
+  const C({this.x}) : assert(x == null || x >= 0);
+}
+const c = const C();
+''');
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_formal_parameter_test.dart b/pkg/analyzer/test/src/diagnostics/const_formal_parameter_test.dart
new file mode 100644
index 0000000..4c1abe8
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_formal_parameter_test.dart
@@ -0,0 +1,39 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstFormalParameterTest);
+  });
+}
+
+@reflectiveTest
+class ConstFormalParameterTest extends DriverResolutionTest {
+  test_fieldFormalParameter() async {
+    await assertErrorsInCode(r'''
+class A {
+  var x;
+  A(const this.x) {}
+}
+''', [
+      error(CompileTimeErrorCode.CONST_FORMAL_PARAMETER, 23, 12),
+      error(ParserErrorCode.EXTRANEOUS_MODIFIER, 23, 5),
+    ]);
+  }
+
+  test_simpleFormalParameter() async {
+    await assertErrorsInCode('''
+f(const x) {}
+''', [
+      error(CompileTimeErrorCode.CONST_FORMAL_PARAMETER, 2, 7),
+      error(ParserErrorCode.EXTRANEOUS_MODIFIER, 2, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_from_deferred_library_test.dart b/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_from_deferred_library_test.dart
new file mode 100644
index 0000000..21a3c81
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_from_deferred_library_test.dart
@@ -0,0 +1,55 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(
+        ConstInitializedWithNonConstantValueFromDeferredLibraryTest);
+  });
+}
+
+@reflectiveTest
+class ConstInitializedWithNonConstantValueFromDeferredLibraryTest
+    extends DriverResolutionTest {
+  test_deferred() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+const V = 1;
+''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+const B = a.V;
+''', [
+      error(
+          CompileTimeErrorCode
+              .CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE_FROM_DEFERRED_LIBRARY,
+          58,
+          3),
+    ]);
+  }
+
+  test_nested() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+const V = 1;
+''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+const B = a.V + 1;
+''', [
+      error(
+          CompileTimeErrorCode
+              .CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE_FROM_DEFERRED_LIBRARY,
+          58,
+          7),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_test.dart b/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_test.dart
new file mode 100644
index 0000000..4801257
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_initialized_with_non_constant_value_test.dart
@@ -0,0 +1,104 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstInitializedWithNonConstantValueTest);
+  });
+}
+
+@reflectiveTest
+class ConstInitializedWithNonConstantValueTest extends DriverResolutionTest {
+  test_dynamic() async {
+    await assertErrorsInCode(r'''
+f(p) {
+  const c = p;
+}
+''', [
+      error(HintCode.UNUSED_LOCAL_VARIABLE, 15, 1),
+      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 19,
+          1),
+    ]);
+  }
+
+  test_finalField() async {
+    // Regression test for bug #25526; previously, two errors were reported.
+    await assertErrorsInCode(r'''
+class Foo {
+  final field = 0;
+  foo([int x = field]) {}
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 46, 5),
+    ]);
+  }
+
+  test_missingConstInListLiteral() async {
+    await assertNoErrorsInCode('''
+const List L = [0];
+''');
+  }
+
+  test_missingConstInMapLiteral() async {
+    await assertNoErrorsInCode('''
+const Map M = {'a' : 0};
+''');
+  }
+
+  test_newInstance_constConstructor() async {
+    await assertErrorsInCode(r'''
+class A {
+  const A();
+}
+const a = new A();
+''', [
+      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 35,
+          7),
+    ]);
+  }
+
+  test_newInstance_externalFactoryConstConstructor() async {
+    // We can't evaluate "const A()" because its constructor is external.  But
+    // the code is correct--we shouldn't report an error.
+    await assertNoErrorsInCode(r'''
+class A {
+  external const factory A();
+}
+const x = const A();
+''');
+  }
+
+  test_nonStaticField_inGenericClass() async {
+    await assertErrorsInCode('''
+class C<T> {
+  const C();
+  T get t => null;
+}
+
+const x = const C().t;
+''', [
+      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 58,
+          11),
+    ]);
+  }
+
+  test_propertyExtraction_targetNotConst() async {
+    await assertErrorsInCode(r'''
+class A {
+  const A();
+  int m() => 0;
+}
+final a = const A();
+const c = a.m;
+''', [
+      error(CompileTimeErrorCode.CONST_INITIALIZED_WITH_NON_CONSTANT_VALUE, 72,
+          1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_instance_field_test.dart b/pkg/analyzer/test/src/diagnostics/const_instance_field_test.dart
new file mode 100644
index 0000000..45a9fc1
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_instance_field_test.dart
@@ -0,0 +1,37 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstInstanceFieldTest);
+  });
+}
+
+@reflectiveTest
+class ConstInstanceFieldTest extends DriverResolutionTest {
+  test_class() async {
+    await assertErrorsInCode(r'''
+class C {
+  const int f = 0;
+}
+''', [
+      error(CompileTimeErrorCode.CONST_INSTANCE_FIELD, 12, 5),
+    ]);
+  }
+
+  test_mixin() async {
+    await assertErrorsInCode(r'''
+mixin C {
+  const int f = 0;
+}
+''', [
+      error(CompileTimeErrorCode.CONST_INSTANCE_FIELD, 12, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/const_not_initialized_test.dart b/pkg/analyzer/test/src/diagnostics/const_not_initialized_test.dart
index 9617d6f..2ee2f94 100644
--- a/pkg/analyzer/test/src/diagnostics/const_not_initialized_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/const_not_initialized_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -58,9 +57,5 @@
 }
 
 @reflectiveTest
-class ConstNotInitializedWithNnbdTest extends ConstNotInitializedTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-}
+class ConstNotInitializedWithNnbdTest extends ConstNotInitializedTest
+    with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/const_with_non_const_test.dart b/pkg/analyzer/test/src/diagnostics/const_with_non_const_test.dart
new file mode 100644
index 0000000..50ce2ea
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/const_with_non_const_test.dart
@@ -0,0 +1,95 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(ConstWithNonConstTest);
+  });
+}
+
+@reflectiveTest
+class ConstWithNonConstTest extends DriverResolutionTest {
+  test_inConstContext() async {
+    await assertErrorsInCode(r'''
+class A {
+  const A(x);
+}
+class B {
+}
+main() {
+  const A(B());
+}
+''', [
+      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 57, 3),
+    ]);
+  }
+
+  test_mixinApplication_constSuperConstructor() async {
+    await assertNoErrorsInCode(r'''
+mixin M {}
+class A {
+  const A();
+}
+class B = A with M;
+const b = const B();
+''');
+  }
+
+  test_mixinApplication_constSuperConstructor_field() async {
+    await assertErrorsInCode(r'''
+mixin M {
+  int i = 0;
+}
+class A {
+  const A();
+}
+class B = A with M;
+var b = const B();
+''', [
+      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 78, 5),
+    ]);
+  }
+
+  test_mixinApplication_constSuperConstructor_getter() async {
+    await assertNoErrorsInCode(r'''
+mixin M {
+  int get i => 0;
+}
+class A {
+  const A();
+}
+class B = A with M;
+var b = const B();
+''');
+  }
+
+  test_mixinApplication_constSuperConstructor_setter() async {
+    await assertNoErrorsInCode(r'''
+mixin M {
+  set(int i) {}
+}
+class A {
+  const A();
+}
+class B = A with M;
+var b = const B();
+''');
+  }
+
+  test_nonConst() async {
+    await assertErrorsInCode(r'''
+class T {
+  T(a, b, {c, d}) {}
+}
+f() { return const T(0, 1, c: 2, d: 3); }
+''', [
+      error(CompileTimeErrorCode.CONST_WITH_NON_CONST, 46, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/dead_code_test.dart b/pkg/analyzer/test/src/diagnostics/dead_code_test.dart
index 088a0a8..8c097ab 100644
--- a/pkg/analyzer/test/src/diagnostics/dead_code_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/dead_code_test.dart
@@ -6,8 +6,8 @@
 import 'package:analyzer/src/test_utilities/package_mixin.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/dead_null_aware_expression_test.dart b/pkg/analyzer/test/src/diagnostics/dead_null_aware_expression_test.dart
index 939300f..8b0a323 100644
--- a/pkg/analyzer/test/src/diagnostics/dead_null_aware_expression_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/dead_null_aware_expression_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class DeadNullAwareExpressionTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class DeadNullAwareExpressionTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_assignCompound_legacy() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.5
diff --git a/pkg/analyzer/test/src/diagnostics/default_list_constructor_test.dart b/pkg/analyzer/test/src/diagnostics/default_list_constructor_test.dart
index 5609204d..a629db8 100644
--- a/pkg/analyzer/test/src/diagnostics/default_list_constructor_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/default_list_constructor_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,12 +15,8 @@
 }
 
 @reflectiveTest
-class DefaultListConstructorMismatch extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class DefaultListConstructorMismatch extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_inferredType() async {
     await assertErrorsInCode('''
 List<int> v = List(5);
diff --git a/pkg/analyzer/test/src/diagnostics/default_value_on_required_parameter_test.dart b/pkg/analyzer/test/src/diagnostics/default_value_on_required_parameter_test.dart
index 8700979..ac7337c 100644
--- a/pkg/analyzer/test/src/diagnostics/default_value_on_required_parameter_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/default_value_on_required_parameter_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,12 +15,8 @@
 }
 
 @reflectiveTest
-class DefaultValueOnRequiredParameterTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class DefaultValueOnRequiredParameterTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_function_notRequired_default() async {
     await assertNoErrorsInCode('''
 void log({String message: 'no message'}) {}
diff --git a/pkg/analyzer/test/src/diagnostics/definitely_unassigned_late_local_variable_test.dart b/pkg/analyzer/test/src/diagnostics/definitely_unassigned_late_local_variable_test.dart
index 24bb1e0..792e766 100644
--- a/pkg/analyzer/test/src/diagnostics/definitely_unassigned_late_local_variable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/definitely_unassigned_late_local_variable_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class DefinitelyUnassignedLateLocalVariableTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class DefinitelyUnassignedLateLocalVariableTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   CompileTimeErrorCode get _errorCode {
     return CompileTimeErrorCode.DEFINITELY_UNASSIGNED_LATE_LOCAL_VARIABLE;
   }
diff --git a/pkg/analyzer/test/src/diagnostics/deprecated_member_use_test.dart b/pkg/analyzer/test/src/diagnostics/deprecated_member_use_test.dart
index f2493f1..8a43e70 100644
--- a/pkg/analyzer/test/src/diagnostics/deprecated_member_use_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/deprecated_member_use_test.dart
@@ -18,6 +18,8 @@
 @reflectiveTest
 class DeprecatedMemberUseFromSamePackageTest extends DriverResolutionTest {
   test_basicWorkspace() async {
+    configureWorkspace(root: '/workspace');
+
     newFile('/workspace/lib/deprecated_library.dart', content: r'''
 @deprecated
 library deprecated_library;
@@ -33,6 +35,8 @@
   }
 
   test_bazelWorkspace() async {
+    configureWorkspace(root: '/workspace');
+
     newFile('/workspace/WORKSPACE');
     newFile('/workspace/project/BUILD');
     newFolder('/workspace/bazel-genfiles');
@@ -123,6 +127,8 @@
   }
 
   test_gnWorkspace() async {
+    configureWorkspace(root: '/workspace');
+
     newFolder('/workspace/.jiri_root');
     newFile('/workspace/project/pubspec.yaml');
     newFile('/workspace/project/BUILD.gn');
@@ -353,6 +359,8 @@
   }
 
   test_packageBuildWorkspace() async {
+    configureWorkspace(root: '/workspace');
+
     newFolder('/workspace/.dart_tool/build/generated/project/lib');
     newFileWithBytes('/workspace/pubspec.yaml', 'name: project'.codeUnits);
     newFileWithBytes('/workspace/.packages', 'project:lib/'.codeUnits);
diff --git a/pkg/analyzer/test/src/diagnostics/equal_elements_in_const_set_test.dart b/pkg/analyzer/test/src/diagnostics/equal_elements_in_const_set_test.dart
index 69b5728..eeb763d 100644
--- a/pkg/analyzer/test/src/diagnostics/equal_elements_in_const_set_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/equal_elements_in_const_set_test.dart
@@ -24,9 +24,7 @@
 var c = const {1, 2, 1};
 ''', [
       error(CompileTimeErrorCode.EQUAL_ELEMENTS_IN_CONST_SET, 21, 1,
-          contextMessages: [
-            message(resourceProvider.convertPath('/test/lib/test.dart'), 15, 1)
-          ]),
+          contextMessages: [message('/test/lib/test.dart', 15, 1)]),
     ]);
   }
 
@@ -38,12 +36,7 @@
         analysisOptions.experimentStatus.constant_update_2018
             ? [
                 error(CompileTimeErrorCode.EQUAL_ELEMENTS_IN_CONST_SET, 36, 1,
-                    contextMessages: [
-                      message(
-                          resourceProvider.convertPath('/test/lib/test.dart'),
-                          15,
-                          1)
-                    ]),
+                    contextMessages: [message('/test/lib/test.dart', 15, 1)]),
               ]
             : [
                 error(CompileTimeErrorCode.NON_CONSTANT_SET_ELEMENT, 18, 19),
@@ -106,12 +99,7 @@
         analysisOptions.experimentStatus.constant_update_2018
             ? [
                 error(CompileTimeErrorCode.EQUAL_ELEMENTS_IN_CONST_SET, 29, 1,
-                    contextMessages: [
-                      message(
-                          resourceProvider.convertPath('/test/lib/test.dart'),
-                          15,
-                          1)
-                    ]),
+                    contextMessages: [message('/test/lib/test.dart', 15, 1)]),
               ]
             : [
                 error(CompileTimeErrorCode.NON_CONSTANT_SET_ELEMENT, 18, 12),
@@ -127,9 +115,7 @@
 var c = const {const A<int>(), const A<int>()};
 ''', [
       error(CompileTimeErrorCode.EQUAL_ELEMENTS_IN_CONST_SET, 60, 14,
-          contextMessages: [
-            message(resourceProvider.convertPath('/test/lib/test.dart'), 44, 14)
-          ]),
+          contextMessages: [message('/test/lib/test.dart', 44, 14)]),
     ]);
   }
 
@@ -164,12 +150,7 @@
         analysisOptions.experimentStatus.constant_update_2018
             ? [
                 error(CompileTimeErrorCode.EQUAL_ELEMENTS_IN_CONST_SET, 21, 3,
-                    contextMessages: [
-                      message(
-                          resourceProvider.convertPath('/test/lib/test.dart'),
-                          15,
-                          1)
-                    ]),
+                    contextMessages: [message('/test/lib/test.dart', 15, 1)]),
               ]
             : [
                 error(CompileTimeErrorCode.NON_CONSTANT_SET_ELEMENT, 18, 6),
diff --git a/pkg/analyzer/test/src/diagnostics/export_duplicated_library_named_test.dart b/pkg/analyzer/test/src/diagnostics/export_duplicated_library_named_test.dart
deleted file mode 100644
index b76689c..0000000
--- a/pkg/analyzer/test/src/diagnostics/export_duplicated_library_named_test.dart
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright (c) 2019, 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 'package:analyzer/src/error/codes.dart';
-import 'package:test_reflective_loader/test_reflective_loader.dart';
-
-import '../dart/resolution/driver_resolution.dart';
-
-main() {
-  defineReflectiveSuite(() {
-    defineReflectiveTests(ExportDuplicatedLibraryNamedTest);
-  });
-}
-
-@reflectiveTest
-class ExportDuplicatedLibraryNamedTest extends DriverResolutionTest {
-  test_no_duplication() async {
-    newFile("/test/lib/lib1.dart");
-    newFile("/test/lib/lib2.dart");
-    await assertNoErrorsInCode(r'''
-library test;
-export 'lib1.dart';
-export 'lib2.dart';
-''');
-  }
-
-  test_sameNames() async {
-    newFile("/test/lib/lib1.dart", content: "library lib;");
-    newFile("/test/lib/lib2.dart", content: "library lib;");
-    await assertErrorsInCode('''
-export 'lib1.dart';
-export 'lib2.dart';
-''', [
-      error(StaticWarningCode.EXPORT_DUPLICATED_LIBRARY_NAMED, 20, 19),
-    ]);
-  }
-}
diff --git a/pkg/analyzer/test/src/diagnostics/export_legacy_symbol_test.dart b/pkg/analyzer/test/src/diagnostics/export_legacy_symbol_test.dart
index 364015d..833cdff 100644
--- a/pkg/analyzer/test/src/diagnostics/export_legacy_symbol_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/export_legacy_symbol_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,15 +15,8 @@
 }
 
 @reflectiveTest
-class ExportLegacySymbolTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class ExportLegacySymbolTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_exportDartAsync() async {
     await assertNoErrorsInCode(r'''
 export 'dart:async';
diff --git a/pkg/analyzer/test/src/diagnostics/extends_non_class_test.dart b/pkg/analyzer/test/src/diagnostics/extends_non_class_test.dart
index 784bb3e..9569e82 100644
--- a/pkg/analyzer/test/src/diagnostics/extends_non_class_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/extends_non_class_test.dart
@@ -2,16 +2,15 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
-//    defineReflectiveTests(ExtendsNonClassTest);
+    defineReflectiveTests(ExtendsNonClassTest);
     defineReflectiveTests(ExtendsNonClassWithNnbdTest);
   });
 }
@@ -20,12 +19,8 @@
 class ExtendsNonClassTest extends DriverResolutionTest {}
 
 @reflectiveTest
-class ExtendsNonClassWithNnbdTest extends ExtendsNonClassTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class ExtendsNonClassWithNnbdTest extends ExtendsNonClassTest
+    with WithNullSafetyMixin {
   test_Never() async {
     await assertErrorsInCode('''
 class A extends Never {}
diff --git a/pkg/analyzer/test/src/diagnostics/extension_override_argument_not_assignable_test.dart b/pkg/analyzer/test/src/diagnostics/extension_override_argument_not_assignable_test.dart
index c8f44a9..a872eea 100644
--- a/pkg/analyzer/test/src/diagnostics/extension_override_argument_not_assignable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/extension_override_argument_not_assignable_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -64,12 +63,7 @@
 
 @reflectiveTest
 class ExtensionOverrideArgumentNotAssignableWithNNBDTest
-    extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends DriverResolutionTest with WithNullSafetyMixin {
   test_override_onNonNullable() async {
     await assertErrorsInCode(r'''
 extension E on String {
diff --git a/pkg/analyzer/test/src/diagnostics/final_not_initialized_test.dart b/pkg/analyzer/test/src/diagnostics/final_not_initialized_test.dart
index fb6002e..02074c4 100644
--- a/pkg/analyzer/test/src/diagnostics/final_not_initialized_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/final_not_initialized_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/dart/error/hint_codes.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -85,12 +84,8 @@
 }
 
 @reflectiveTest
-class FinalNotInitializedWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class FinalNotInitializedWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_field_noConstructor_initializer() async {
     await assertNoErrorsInCode('''
 class C {
diff --git a/pkg/analyzer/test/src/diagnostics/for_in_of_invalid_type_test.dart b/pkg/analyzer/test/src/diagnostics/for_in_of_invalid_type_test.dart
index 7fe09d4..4e25160 100644
--- a/pkg/analyzer/test/src/diagnostics/for_in_of_invalid_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/for_in_of_invalid_type_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -64,12 +63,8 @@
 }
 
 @reflectiveTest
-class ForInOfInvalidTypeWithNnbdTest extends ForInOfInvalidTypeTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class ForInOfInvalidTypeWithNnbdTest extends ForInOfInvalidTypeTest
+    with WithNullSafetyMixin {
   test_awaitForIn_never() async {
     await assertErrorsInCode('''
 f(Never e) async {
diff --git a/pkg/analyzer/test/src/diagnostics/getter_not_subtype_setter_types_test.dart b/pkg/analyzer/test/src/diagnostics/getter_not_subtype_setter_types_test.dart
index 8cbbe24..db070e3 100644
--- a/pkg/analyzer/test/src/diagnostics/getter_not_subtype_setter_types_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/getter_not_subtype_setter_types_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,15 +15,8 @@
 }
 
 @reflectiveTest
-class GetterNotSubtypeSetterTypesTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class GetterNotSubtypeSetterTypesTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_class_instance() async {
     await assertErrorsInCode('''
 class C {
diff --git a/pkg/analyzer/test/src/diagnostics/illegal_async_generator_return_type_test.dart b/pkg/analyzer/test/src/diagnostics/illegal_async_generator_return_type_test.dart
new file mode 100644
index 0000000..2e7c537
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/illegal_async_generator_return_type_test.dart
@@ -0,0 +1,81 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(IllegalAsyncGeneratorReturnTypeTest);
+  });
+}
+
+@reflectiveTest
+class IllegalAsyncGeneratorReturnTypeTest extends DriverResolutionTest {
+  test_function_nonStream() async {
+    await assertErrorsInCode('''
+int f() async* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 3),
+    ]);
+  }
+
+  test_function_stream() async {
+    await assertNoErrorsInCode('''
+Stream<void> f() async* {}
+''');
+  }
+
+  test_function_subtypeOfStream() async {
+    await assertErrorsInCode('''
+import 'dart:async';
+abstract class SubStream<T> implements Stream<T> {}
+SubStream<int> f() async* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 73, 14),
+    ]);
+  }
+
+  test_function_void() async {
+    await assertErrorsInCode('''
+void f() async* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 4),
+    ]);
+  }
+
+  test_method_nonStream() async {
+    await assertErrorsInCode('''
+class C {
+  int f() async* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 12, 3),
+    ]);
+  }
+
+  test_method_subtypeOfStream() async {
+    await assertErrorsInCode('''
+import 'dart:async';
+abstract class SubStream<T> implements Stream<T> {}
+class C {
+  SubStream<int> f() async* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 85, 14),
+    ]);
+  }
+
+  test_method_void() async {
+    await assertErrorsInCode('''
+class C {
+  void f() async* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 12, 4),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/illegal_async_return_type_test.dart b/pkg/analyzer/test/src/diagnostics/illegal_async_return_type_test.dart
index a6ceffd..a5d8ce9 100644
--- a/pkg/analyzer/test/src/diagnostics/illegal_async_return_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/illegal_async_return_type_test.dart
@@ -23,6 +23,12 @@
     ]);
   }
 
+  test_function_nonFuture_void() async {
+    await assertNoErrorsInCode('''
+void f() async {}
+''');
+  }
+
   test_function_nonFuture_withReturn() async {
     await assertErrorsInCode('''
 int f() async {
@@ -55,6 +61,14 @@
     ]);
   }
 
+  test_method_nonFuture_void() async {
+    await assertNoErrorsInCode('''
+class C {
+  void m() async {}
+}
+''');
+  }
+
   test_method_subtypeOfFuture() async {
     await assertErrorsInCode('''
 import 'dart:async';
diff --git a/pkg/analyzer/test/src/diagnostics/illegal_sync_generator_return_type_test.dart b/pkg/analyzer/test/src/diagnostics/illegal_sync_generator_return_type_test.dart
new file mode 100644
index 0000000..f8d48e3
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/illegal_sync_generator_return_type_test.dart
@@ -0,0 +1,79 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(IllegalSyncGeneratorReturnTypeTest);
+  });
+}
+
+@reflectiveTest
+class IllegalSyncGeneratorReturnTypeTest extends DriverResolutionTest {
+  test_function_iterator() async {
+    await assertNoErrorsInCode('''
+Iterable<void> f() sync* {}
+''');
+  }
+
+  test_function_nonIterator() async {
+    await assertErrorsInCode('''
+int f() sync* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 0, 3),
+    ]);
+  }
+
+  test_function_subclassOfIterator() async {
+    await assertErrorsInCode('''
+abstract class SubIterator<T> implements Iterator<T> {}
+SubIterator<int> f() sync* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 56, 16),
+    ]);
+  }
+
+  test_function_void() async {
+    await assertErrorsInCode('''
+void f() sync* {}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 0, 4),
+    ]);
+  }
+
+  test_method_nonIterator() async {
+    await assertErrorsInCode('''
+class C {
+  int f() sync* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 12, 3),
+    ]);
+  }
+
+  test_method_subclassOfIterator() async {
+    await assertErrorsInCode('''
+abstract class SubIterator<T> implements Iterator<T> {}
+class C {
+  SubIterator<int> f() sync* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 68, 16),
+    ]);
+  }
+
+  test_method_void() async {
+    await assertErrorsInCode('''
+class C {
+  void f() sync* {}
+}
+''', [
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 12, 4),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/implements_non_class_test.dart b/pkg/analyzer/test/src/diagnostics/implements_non_class_test.dart
index fb3c2a5..23f2aea 100644
--- a/pkg/analyzer/test/src/diagnostics/implements_non_class_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/implements_non_class_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -57,12 +56,8 @@
 }
 
 @reflectiveTest
-class ImplementsNonClassWithNnbdTest extends ImplementsNonClassTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class ImplementsNonClassWithNnbdTest extends ImplementsNonClassTest
+    with WithNullSafetyMixin {
   test_Never() async {
     await assertErrorsInCode('''
 class A implements Never {}
diff --git a/pkg/analyzer/test/src/diagnostics/implicit_this_reference_in_initializer_test.dart b/pkg/analyzer/test/src/diagnostics/implicit_this_reference_in_initializer_test.dart
index aa3745b..033d8bb 100644
--- a/pkg/analyzer/test/src/diagnostics/implicit_this_reference_in_initializer_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/implicit_this_reference_in_initializer_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -250,12 +249,7 @@
 
 @reflectiveTest
 class ImplicitThisReferenceInInitializerWithNnbdTest
-    extends ImplicitThisReferenceInInitializerTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends ImplicitThisReferenceInInitializerTest with WithNullSafetyMixin {
   test_class_field_late_invokeInstanceMethod() async {
     await assertNoErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/import_duplicated_library_named_test.dart b/pkg/analyzer/test/src/diagnostics/import_duplicated_library_named_test.dart
deleted file mode 100644
index af61f3b..0000000
--- a/pkg/analyzer/test/src/diagnostics/import_duplicated_library_named_test.dart
+++ /dev/null
@@ -1,35 +0,0 @@
-// Copyright (c) 2019, 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 'package:analyzer/src/error/codes.dart';
-import 'package:test_reflective_loader/test_reflective_loader.dart';
-
-import '../dart/resolution/driver_resolution.dart';
-
-main() {
-  defineReflectiveSuite(() {
-    defineReflectiveTests(ImportDuplicatedLibraryNamedTest);
-  });
-}
-
-@reflectiveTest
-class ImportDuplicatedLibraryNamedTest extends DriverResolutionTest {
-  test_duplicate() async {
-    newFile("/test/lib/lib1.dart", content: '''
-library lib;
-class A {}
-''');
-    newFile("/test/lib/lib2.dart", content: '''
-library lib;
-class B {}
-''');
-    await assertErrorsInCode('''
-import 'lib1.dart';
-import 'lib2.dart';
-class C implements A, B {}
-''', [
-      error(StaticWarningCode.IMPORT_DUPLICATED_LIBRARY_NAMED, 20, 19),
-    ]);
-  }
-}
diff --git a/pkg/analyzer/test/src/diagnostics/inconsistent_case_expression_types_test.dart b/pkg/analyzer/test/src/diagnostics/inconsistent_case_expression_types_test.dart
index 9dee843..675931b 100644
--- a/pkg/analyzer/test/src/diagnostics/inconsistent_case_expression_types_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/inconsistent_case_expression_types_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/inconsistent_language_version_override_test.dart b/pkg/analyzer/test/src/diagnostics/inconsistent_language_version_override_test.dart
new file mode 100644
index 0000000..9e8bee8
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/inconsistent_language_version_override_test.dart
@@ -0,0 +1,111 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:meta/meta.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../../generated/test_support.dart';
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InconsistentLanguageVersionOverrideTest);
+  });
+}
+
+@reflectiveTest
+class InconsistentLanguageVersionOverrideTest extends DriverResolutionTest {
+  CompileTimeErrorCode get _errorCode =>
+      CompileTimeErrorCode.INCONSISTENT_LANGUAGE_VERSION_OVERRIDE;
+
+  test_both_different() async {
+    await _checkLibraryAndPart(
+      libraryContent: r'''
+// @dart = 2.5
+part 'b.dart';
+''',
+      partContent: r'''
+// @dart = 2.6
+part of 'a.dart';
+''',
+      partErrors: [
+        error(_errorCode, 0, 14),
+      ],
+    );
+  }
+
+  test_both_same() async {
+    await _checkLibraryAndPart(
+      libraryContent: r'''
+// @dart = 2.5
+part 'b.dart';
+''',
+      partContent: r'''
+// @dart = 2.5
+part of 'a.dart';
+''',
+      partErrors: [],
+    );
+  }
+
+  test_none() async {
+    await _checkLibraryAndPart(
+      libraryContent: r'''
+part 'b.dart';
+''',
+      partContent: r'''
+part of 'a.dart';
+''',
+      partErrors: [],
+    );
+  }
+
+  test_onlyLibrary() async {
+    await _checkLibraryAndPart(
+      libraryContent: r'''
+// @dart = 2.5
+part 'b.dart';
+''',
+      partContent: r'''
+part of 'a.dart';
+''',
+      partErrors: [
+        error(_errorCode, 0, 7),
+      ],
+    );
+  }
+
+  test_onlyPart() async {
+    await _checkLibraryAndPart(
+      libraryContent: r'''
+part 'b.dart';
+''',
+      partContent: r'''
+// @dart = 2.5
+part of 'a.dart';
+''',
+      partErrors: [
+        error(_errorCode, 0, 14),
+      ],
+    );
+  }
+
+  Future<void> _checkLibraryAndPart({
+    @required String libraryContent,
+    @required String partContent,
+    @required List<ExpectedError> partErrors,
+  }) async {
+    var libraryPath = convertPath('/test/lib/a.dart');
+    var partPath = convertPath('/test/lib/b.dart');
+
+    newFile(libraryPath, content: libraryContent);
+
+    newFile(partPath, content: partContent);
+
+    await resolveFile(libraryPath);
+
+    await assertErrorsInFile2(partPath, partErrors);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/inference_failure_on_uninitialized_variable_test.dart b/pkg/analyzer/test/src/diagnostics/inference_failure_on_uninitialized_variable_test.dart
index 846fd9c..93714bb 100644
--- a/pkg/analyzer/test/src/diagnostics/inference_failure_on_uninitialized_variable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/inference_failure_on_uninitialized_variable_test.dart
@@ -6,7 +6,7 @@
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../../generated/resolver_test_case.dart';
+import '../dart/resolution/driver_resolution.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,8 +17,7 @@
 /// Tests of HintCode.INFERENCE_FAILURE_ON_UNINITIALIZED_VARIABLE with the
 /// "strict-inference" static analysis option.
 @reflectiveTest
-class InferenceFailureOnUninitializedVariableTest
-    extends StaticTypeAnalyzer2TestShared {
+class InferenceFailureOnUninitializedVariableTest extends DriverResolutionTest {
   @override
   AnalysisOptionsImpl get analysisOptions =>
       AnalysisOptionsImpl()..strictInference = true;
diff --git a/pkg/analyzer/test/src/diagnostics/inference_failure_on_untyped_parameter_test.dart b/pkg/analyzer/test/src/diagnostics/inference_failure_on_untyped_parameter_test.dart
index 6a6614e..da96679 100644
--- a/pkg/analyzer/test/src/diagnostics/inference_failure_on_untyped_parameter_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/inference_failure_on_untyped_parameter_test.dart
@@ -6,7 +6,7 @@
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../../generated/resolver_test_case.dart';
+import '../dart/resolution/driver_resolution.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,8 +17,7 @@
 /// Tests of HintCode.INFERENCE_FAILURE_ON_UNTYPED_PARAMETER with the
 /// "strict-inference" static analysis option.
 @reflectiveTest
-class InferenceFailureOnUntypedParameterTest
-    extends StaticTypeAnalyzer2TestShared {
+class InferenceFailureOnUntypedParameterTest extends DriverResolutionTest {
   @override
   AnalysisOptionsImpl get analysisOptions =>
       AnalysisOptionsImpl()..strictInference = true;
diff --git a/pkg/analyzer/test/src/diagnostics/initializer_for_non_existent_field_test.dart b/pkg/analyzer/test/src/diagnostics/initializer_for_non_existent_field_test.dart
new file mode 100644
index 0000000..723dbb1
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/initializer_for_non_existent_field_test.dart
@@ -0,0 +1,40 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InitializerForNonExistentFieldTest);
+  });
+}
+
+@reflectiveTest
+class InitializerForNonExistentFieldTest extends DriverResolutionTest {
+  test_const() async {
+    // Check that the absence of a matching field doesn't cause a
+    // crash during constant evaluation.
+    await assertErrorsInCode(r'''
+class A {
+  const A() : x = 'foo';
+}
+A a = const A();
+''', [
+      error(CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD, 24, 9),
+    ]);
+  }
+
+  test_initializer() async {
+    await assertErrorsInCode(r'''
+class A {
+  A() : x = 0 {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZER_FOR_NON_EXISTENT_FIELD, 18, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/initializer_for_static_field_test.dart b/pkg/analyzer/test/src/diagnostics/initializer_for_static_field_test.dart
new file mode 100644
index 0000000..792cbd5
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/initializer_for_static_field_test.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.
+
+import 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InitializerForStaticFieldTest);
+  });
+}
+
+@reflectiveTest
+class InitializerForStaticFieldTest extends DriverResolutionTest {
+  test_static() async {
+    await assertErrorsInCode(r'''
+class A {
+  static int x;
+  A() : x = 0 {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZER_FOR_STATIC_FIELD, 34, 5),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/initializing_formal_for_non_existent_field_test.dart b/pkg/analyzer/test/src/diagnostics/initializing_formal_for_non_existent_field_test.dart
new file mode 100644
index 0000000..971ba67
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/initializing_formal_for_non_existent_field_test.dart
@@ -0,0 +1,65 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InitializingFormalForNonExistentFieldTest);
+  });
+}
+
+@reflectiveTest
+class InitializingFormalForNonExistentFieldTest extends DriverResolutionTest {
+  test_nonExistent() async {
+    await assertErrorsInCode(r'''
+class A {
+  A(this.x) {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 14,
+          6),
+    ]);
+  }
+
+  test_notInEnclosingClass() async {
+    await assertErrorsInCode(r'''
+class A {
+int x;
+}
+class B extends A {
+  B(this.x) {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 43,
+          6),
+    ]);
+  }
+
+  test_optional() async {
+    await assertErrorsInCode(r'''
+class A {
+  A([this.x]) {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 15,
+          6),
+    ]);
+  }
+
+  test_synthetic() async {
+    await assertErrorsInCode(r'''
+class A {
+  int get x => 1;
+  A(this.x) {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_NON_EXISTENT_FIELD, 32,
+          6),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/initializing_formal_for_static_field_test.dart b/pkg/analyzer/test/src/diagnostics/initializing_formal_for_static_field_test.dart
new file mode 100644
index 0000000..b6b4238
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/initializing_formal_for_static_field_test.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.
+
+import 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InitializingFormalForStaticFieldTest);
+  });
+}
+
+@reflectiveTest
+class InitializingFormalForStaticFieldTest extends DriverResolutionTest {
+  test_static() async {
+    await assertErrorsInCode(r'''
+class A {
+  static int x;
+  A([this.x]) {}
+}
+''', [
+      error(CompileTimeErrorCode.INITIALIZING_FORMAL_FOR_STATIC_FIELD, 31, 6),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/instance_access_to_static_member_test.dart b/pkg/analyzer/test/src/diagnostics/instance_access_to_static_member_test.dart
index 0f8682b..a409b21 100644
--- a/pkg/analyzer/test/src/diagnostics/instance_access_to_static_member_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/instance_access_to_static_member_test.dart
@@ -75,4 +75,56 @@
       findElement.setter('a'),
     );
   }
+
+  test_method_reference() async {
+    await assertErrorsInCode(r'''
+class A {
+  static m() {}
+}
+main(A a) {
+  a.m;
+}
+''', [
+      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 44, 1),
+    ]);
+  }
+
+  test_propertyAccess_field() async {
+    await assertErrorsInCode(r'''
+class A {
+  static var f;
+}
+main(A a) {
+  a.f;
+}
+''', [
+      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 44, 1),
+    ]);
+  }
+
+  test_propertyAccess_getter() async {
+    await assertErrorsInCode(r'''
+class A {
+  static get f => 42;
+}
+main(A a) {
+  a.f;
+}
+''', [
+      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 50, 1),
+    ]);
+  }
+
+  test_propertyAccess_setter() async {
+    await assertErrorsInCode(r'''
+class A {
+  static set f(x) {}
+}
+main(A a) {
+  a.f = 42;
+}
+''', [
+      error(StaticTypeWarningCode.INSTANCE_ACCESS_TO_STATIC_MEMBER, 49, 1),
+    ]);
+  }
 }
diff --git a/pkg/analyzer/test/src/diagnostics/instance_member_access_from_factory_test.dart b/pkg/analyzer/test/src/diagnostics/instance_member_access_from_factory_test.dart
new file mode 100644
index 0000000..d5d6125
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/instance_member_access_from_factory_test.dart
@@ -0,0 +1,47 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InstanceMemberAccessFromFactoryTest);
+  });
+}
+
+@reflectiveTest
+class InstanceMemberAccessFromFactoryTest extends DriverResolutionTest {
+  test_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  m() {}
+  A();
+  factory A.make() {
+    m();
+    return new A();
+  }
+}
+''', [
+      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_FACTORY, 51, 1),
+    ]);
+  }
+
+  test_unnamed() async {
+    await assertErrorsInCode(r'''
+class A {
+  m() {}
+  A._();
+  factory A() {
+    m();
+    return new A._();
+  }
+}
+''', [
+      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_FACTORY, 48, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/instance_member_access_from_static_test.dart b/pkg/analyzer/test/src/diagnostics/instance_member_access_from_static_test.dart
index c54e3fd..af6fa96 100644
--- a/pkg/analyzer/test/src/diagnostics/instance_member_access_from_static_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/instance_member_access_from_static_test.dart
@@ -15,21 +15,7 @@
 
 @reflectiveTest
 class InstanceMemberAccessFromStaticTest extends DriverResolutionTest {
-  test_class_field() async {
-    await assertErrorsInCode(r'''
-class A {
-  int foo;
-
-  static void bar() {
-    foo;
-  }
-}
-''', [
-      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_STATIC, 48, 3),
-    ]);
-  }
-
-  test_class_getter() async {
+  test_class_getter_fromMethod() async {
     await assertErrorsInCode(r'''
 class A {
   int get foo => 0;
@@ -43,7 +29,23 @@
     ]);
   }
 
-  test_class_method() async {
+  test_class_getter_fromMethod_fromClosure() async {
+    await assertErrorsInCode(r'''
+class A {
+  int get foo => 0;
+
+  static Object bar() {
+    return () {
+      foo;
+    };
+  }
+}
+''', [
+      error(CompileTimeErrorCode.INSTANCE_MEMBER_ACCESS_FROM_STATIC, 77, 3),
+    ]);
+  }
+
+  test_class_method_fromMethod() async {
     await assertErrorsInCode(r'''
 class A {
   void foo() {}
@@ -57,7 +59,7 @@
     ]);
   }
 
-  test_class_setter() async {
+  test_class_setter_fromMethod() async {
     await assertErrorsInCode(r'''
 class A {
   set foo(int _) {}
@@ -71,7 +73,7 @@
     ]);
   }
 
-  test_extension_external_getter() async {
+  test_extension_external_getter_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on A {
   int get foo => 0;
@@ -87,7 +89,7 @@
     ]);
   }
 
-  test_extension_external_method() async {
+  test_extension_external_method_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on A {
   void foo() {}
@@ -103,7 +105,7 @@
     ]);
   }
 
-  test_extension_external_setter() async {
+  test_extension_external_setter_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on A {
   set foo(int _) {}
@@ -119,7 +121,7 @@
     ]);
   }
 
-  test_extension_internal_getter() async {
+  test_extension_internal_getter_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on int {
   int get foo => 0;
@@ -133,7 +135,7 @@
     ]);
   }
 
-  test_extension_internal_method() async {
+  test_extension_internal_method_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on int {
   void foo() {}
@@ -147,7 +149,7 @@
     ]);
   }
 
-  test_extension_internal_setter() async {
+  test_extension_internal_setter_fromMethod() async {
     await assertErrorsInCode(r'''
 extension E on int {
   set foo(int _) {}
diff --git a/pkg/analyzer/test/src/diagnostics/instantiate_enum_test.dart b/pkg/analyzer/test/src/diagnostics/instantiate_enum_test.dart
new file mode 100644
index 0000000..46856fe
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/instantiate_enum_test.dart
@@ -0,0 +1,39 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InstantiateEnumTest);
+  });
+}
+
+@reflectiveTest
+class InstantiateEnumTest extends DriverResolutionTest {
+  test_const() async {
+    await assertErrorsInCode(r'''
+enum E { ONE }
+E e(String name) {
+  return const E();
+}
+''', [
+      error(CompileTimeErrorCode.INSTANTIATE_ENUM, 49, 1),
+    ]);
+  }
+
+  test_new() async {
+    await assertErrorsInCode(r'''
+enum E { ONE }
+E e(String name) {
+  return new E();
+}
+''', [
+      error(CompileTimeErrorCode.INSTANTIATE_ENUM, 47, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/integer_literal_imprecise_as_double_test.dart b/pkg/analyzer/test/src/diagnostics/integer_literal_imprecise_as_double_test.dart
new file mode 100644
index 0000000..9d96bc5
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/integer_literal_imprecise_as_double_test.dart
@@ -0,0 +1,53 @@
+// 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 'package:analyzer/error/error.dart';
+import 'package:analyzer/src/error/codes.dart';
+import 'package:test/test.dart' show expect;
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(IntegerLiteralImpreciseAsDoubleTest);
+  });
+}
+
+@reflectiveTest
+class IntegerLiteralImpreciseAsDoubleTest extends DriverResolutionTest {
+  test_excessiveExponent() async {
+    await assertErrorsInCode(
+        'double x = 0xfffffffffffff80000000000000000000000000000000000000000000'
+        '0000000000000000000000000000000000000000000000000000000000000000000000'
+        '0000000000000000000000000000000000000000000000000000000000000000000000'
+        '000000000000000000000000000000000000000000000000000000000000;',
+        [
+          error(CompileTimeErrorCode.INTEGER_LITERAL_IMPRECISE_AS_DOUBLE, 11,
+              259),
+        ]);
+    AnalysisError firstError = result.errors[0];
+
+    // Check that we suggest the max double instead.
+    expect(
+        true,
+        firstError.correction.contains(
+            '179769313486231570814527423731704356798070567525844996598917476803'
+            '157260780028538760589558632766878171540458953514382464234321326889'
+            '464182768467546703537516986049910576551282076245490090389328944075'
+            '868508455133942304583236903222948165808559332123348274797826204144'
+            '723168738177180919299881250404026184124858368'));
+  }
+
+  test_excessiveMantissa() async {
+    await assertErrorsInCode('''
+double x = 9223372036854775809;
+''', [
+      error(CompileTimeErrorCode.INTEGER_LITERAL_IMPRECISE_AS_DOUBLE, 11, 19),
+    ]);
+    AnalysisError firstError = result.errors[0];
+    // Check that we suggest a valid double instead.
+    expect(true, firstError.correction.contains('9223372036854775808'));
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/integer_literal_out_of_range_test.dart b/pkg/analyzer/test/src/diagnostics/integer_literal_out_of_range_test.dart
new file mode 100644
index 0000000..1a2991c
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/integer_literal_out_of_range_test.dart
@@ -0,0 +1,33 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(IntegerLiteralOutOfRangeTest);
+  });
+}
+
+@reflectiveTest
+class IntegerLiteralOutOfRangeTest extends DriverResolutionTest {
+  test_negative() async {
+    await assertErrorsInCode('''
+int x = -9223372036854775809;
+''', [
+      error(CompileTimeErrorCode.INTEGER_LITERAL_OUT_OF_RANGE, 9, 19),
+    ]);
+  }
+
+  test_positive() async {
+    await assertErrorsInCode('''
+int x = 9223372036854775808;
+''', [
+      error(CompileTimeErrorCode.INTEGER_LITERAL_OUT_OF_RANGE, 8, 19),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_assignment_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_assignment_test.dart
index 6137d28f..348b422 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_assignment_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_assignment_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,12 +16,8 @@
 }
 
 @reflectiveTest
-class InvalidAssignmentNnbdTest extends InvalidAssignmentTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+class InvalidAssignmentNnbdTest extends InvalidAssignmentTest
+    with WithNullSafetyMixin {
   @override
   test_ifNullAssignment() async {
     await assertErrorsInCode('''
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_cast_new_expr_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_cast_new_expr_test.dart
index 88a6917..e963c1f 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_cast_new_expr_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_cast_new_expr_test.dart
@@ -26,7 +26,7 @@
 }
 ''', [
       error(StaticWarningCode.LIST_ELEMENT_TYPE_NOT_ASSIGNABLE, 14, 3),
-      error(StrongModeCode.INVALID_CAST_NEW_EXPR, 14, 3),
+      error(CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, 14, 3),
     ]);
   }
 
@@ -40,7 +40,7 @@
   const B();
 }
 ''', [
-      error(StrongModeCode.INVALID_CAST_NEW_EXPR, 12, 3),
+      error(CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, 12, 3),
     ]);
   }
 
@@ -55,7 +55,7 @@
 }
 ''', [
       error(StaticWarningCode.SET_ELEMENT_TYPE_NOT_ASSIGNABLE, 14, 3),
-      error(StrongModeCode.INVALID_CAST_NEW_EXPR, 14, 3),
+      error(CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, 14, 3),
     ]);
   }
 
@@ -69,7 +69,7 @@
   const B();
 }
 ''', [
-      error(StrongModeCode.INVALID_CAST_NEW_EXPR, 12, 3),
+      error(CompileTimeErrorCode.INVALID_CAST_NEW_EXPR, 12, 3),
     ]);
   }
 }
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_constant_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_constant_test.dart
index ef14538a..cefb793 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_constant_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_constant_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_language_override_greater_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_language_override_greater_test.dart
index 301431e..53609b5 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_language_override_greater_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_language_override_greater_test.dart
@@ -11,8 +11,8 @@
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -40,12 +40,12 @@
   test_greaterThanPackage() async {
     _configureTestPackageLanguageVersion('2.5');
     await assertNoErrorsInCode(r'''
-// @dart = 2.9
+// @dart = 2.10
 int? a;
 ''');
     _assertUnitLanguageVersion(
       package: Version.parse('2.5.0'),
-      override: Version.parse('2.9.0'),
+      override: Version.parse('2.10.0'),
     );
   }
 
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_language_override_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_language_override_test.dart
index 1495c82..ce3819f 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_language_override_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_language_override_test.dart
@@ -24,9 +24,9 @@
     ]);
   }
 
-  test_correct_2_10() async {
+  test_correct_2_19() async {
     await assertErrorsInCode(r'''
-// @dart = 2.10
+// @dart = 2.19
 int i = 0;
 ''', [
       error(HintCode.INVALID_LANGUAGE_VERSION_OVERRIDE_GREATER, 0, 15),
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_modifier_on_setter_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_modifier_on_setter_test.dart
new file mode 100644
index 0000000..11e9f5e
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/invalid_modifier_on_setter_test.dart
@@ -0,0 +1,79 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InvalidModifierOnSetterTest);
+  });
+}
+
+@reflectiveTest
+class InvalidModifierOnSetterTest extends DriverResolutionTest {
+  test_member_async() async {
+    // TODO(danrubel): Investigate why error message is duplicated when
+    // using fasta parser.
+    await assertErrorsInCode(r'''
+class A {
+  set x(v) async {}
+}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
+    ]);
+  }
+
+  test_member_asyncStar() async {
+    await assertErrorsInCode(r'''
+class A {
+  set x(v) async* {}
+}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 5),
+    ]);
+  }
+
+  test_member_syncStar() async {
+    await assertErrorsInCode(r'''
+class A {
+  set x(v) sync* {}
+}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 4),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 21, 4),
+    ]);
+  }
+
+  test_topLevel_async() async {
+    await assertErrorsInCode('''
+set x(v) async {}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
+    ]);
+  }
+
+  test_topLevel_asyncStar() async {
+    await assertErrorsInCode('''
+set x(v) async* {}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 5),
+    ]);
+  }
+
+  test_topLevel_syncStar() async {
+    await assertErrorsInCode('''
+set x(v) sync* {}
+''', [
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 4),
+      error(CompileTimeErrorCode.INVALID_MODIFIER_ON_SETTER, 9, 4),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_null_aware_operator_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_null_aware_operator_test.dart
index d36cb8f..3227770 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_null_aware_operator_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_null_aware_operator_test.dart
@@ -2,28 +2,93 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
+    defineReflectiveTests(InvalidNullAwareOperatorAfterShortCircuitTest);
     defineReflectiveTests(InvalidNullAwareOperatorTest);
   });
 }
 
 @reflectiveTest
-class InvalidNullAwareOperatorTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
+class InvalidNullAwareOperatorAfterShortCircuitTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
+  Future<void> test_getter_previousTarget() async {
+    await assertErrorsInCode('''
+void f(String? s) {
+  s?.length?.isEven;
+}
+''', [
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          31, 2,
+          contextMessages: [message('/test/lib/test.dart', 23, 2)]),
+    ]);
+  }
 
+  Future<void> test_index_previousTarget() async {
+    await assertErrorsInCode('''
+void f(String? s) {
+  s?[4]?.length;
+}
+''', [
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          27, 2,
+          contextMessages: [message('/test/lib/test.dart', 23, 1)]),
+    ]);
+  }
+
+  Future<void> test_methodInvocation_noTarget() async {
+    await assertErrorsInCode('''
+class C {
+  C? m1() => this;
+  C m2() => this;
+  void m3() {
+    m1()?.m2()?.m2();
+  }
+}
+''', [
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          75, 2,
+          contextMessages: [message('/test/lib/test.dart', 69, 2)]),
+    ]);
+  }
+
+  Future<void> test_methodInvocation_previousTarget() async {
+    await assertErrorsInCode('''
+void f(String? s) {
+  s?.substring(0, 5)?.length;
+}
+''', [
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          40, 2,
+          contextMessages: [message('/test/lib/test.dart', 23, 2)]),
+    ]);
+  }
+
+  Future<void> test_methodInvocation_previousTwoTargets() async {
+    await assertErrorsInCode('''
+void f(String? s) {
+  s?.substring(0, 5)?.toLowerCase()?.length;
+}
+''', [
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          40, 2,
+          contextMessages: [message('/test/lib/test.dart', 23, 2)]),
+      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR_AFTER_SHORT_CIRCUIT,
+          55, 2,
+          contextMessages: [message('/test/lib/test.dart', 23, 2)]),
+    ]);
+  }
+}
+
+@reflectiveTest
+class InvalidNullAwareOperatorTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_getter_class() async {
     await assertNoErrorsInCode('''
 class C {
@@ -126,7 +191,6 @@
 
 f() {
   x?[0];
-  x?.[0];
   x?..[0];
 }
 ''');
@@ -136,13 +200,11 @@
     await assertErrorsInCode('''
 f(List<int> x) {
   x?[0];
-  x?.[0];
   x?..[0];
 }
 ''', [
       error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR, 20, 2),
       error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR, 29, 3),
-      error(StaticWarningCode.INVALID_NULL_AWARE_OPERATOR, 39, 3),
     ]);
   }
 
@@ -150,7 +212,6 @@
     await assertNoErrorsInCode('''
 f(List<int>? x) {
   x?[0];
-  x?.[0];
   x?..[0];
 }
 ''');
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_named_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_named_test.dart
index 8db5d07..f9949d7 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_named_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_named_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -301,17 +299,8 @@
 
 @reflectiveTest
 class InvalidOverrideDifferentDefaultValuesNamedWithNnbdTest
-    extends InvalidOverrideDifferentDefaultValuesNamedTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends InvalidOverrideDifferentDefaultValuesNamedTest
+    with WithNullSafetyMixin {
   test_concrete_equal_optIn_extends_optOut() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.7
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_positional_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_positional_test.dart
index 1c00700..3955adb 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_positional_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_override_different_default_values_positional_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -316,17 +314,8 @@
 
 @reflectiveTest
 class InvalidOverrideDifferentDefaultValuesPositionalWithNnbdTest
-    extends InvalidOverrideDifferentDefaultValuesPositionalTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends InvalidOverrideDifferentDefaultValuesPositionalTest
+    with WithNullSafetyMixin {
   test_concrete_equal_optIn_extends_optOut() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.7
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_override_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_override_test.dart
index b46af7a..f5987fd 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_override_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_override_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -563,17 +561,8 @@
 }
 
 @reflectiveTest
-class InvalidOverrideWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    )
-    ..implicitCasts = false;
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class InvalidOverrideWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_method_parameter_functionTyped_optOut_extends_optIn() async {
     newFile('/test/lib/a.dart', content: r'''
 abstract class A {
diff --git a/pkg/analyzer/test/src/diagnostics/invalid_reference_to_this_test.dart b/pkg/analyzer/test/src/diagnostics/invalid_reference_to_this_test.dart
index d294200..00fc44d 100644
--- a/pkg/analyzer/test/src/diagnostics/invalid_reference_to_this_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/invalid_reference_to_this_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -137,13 +135,8 @@
 }
 
 @reflectiveTest
-class InvalidReferenceToThisTest_NNBD extends InvalidReferenceToThisTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class InvalidReferenceToThisTest_NNBD extends InvalidReferenceToThisTest
+    with WithNullSafetyMixin {
   test_instanceVariableInitializer_inDeclaration_late() async {
     await assertNoErrorsInCode(r'''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/invocation_of_non_function_expression_test.dart b/pkg/analyzer/test/src/diagnostics/invocation_of_non_function_expression_test.dart
new file mode 100644
index 0000000..0554340
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/invocation_of_non_function_expression_test.dart
@@ -0,0 +1,27 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(InvocationOfNonFunctionExpressionTest);
+  });
+}
+
+@reflectiveTest
+class InvocationOfNonFunctionExpressionTest extends DriverResolutionTest {
+  test_invocationOfNonFunctionExpression_literal() async {
+    await assertErrorsInCode(r'''
+f() {
+  3(5);
+}
+''', [
+      error(StaticTypeWarningCode.INVOCATION_OF_NON_FUNCTION_EXPRESSION, 8, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/label_undefined_test.dart b/pkg/analyzer/test/src/diagnostics/label_undefined_test.dart
index 503c009..366d06d 100644
--- a/pkg/analyzer/test/src/diagnostics/label_undefined_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/label_undefined_test.dart
@@ -6,8 +6,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/late_final_field_with_const_constructor_test.dart b/pkg/analyzer/test/src/diagnostics/late_final_field_with_const_constructor_test.dart
index 58d3572..00da73f 100644
--- a/pkg/analyzer/test/src/diagnostics/late_final_field_with_const_constructor_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/late_final_field_with_const_constructor_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,15 +15,11 @@
 }
 
 @reflectiveTest
-class LateFinalFieldWithConstConstructorTest extends DriverResolutionTest {
+class LateFinalFieldWithConstConstructorTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   static const _errorCode =
       CompileTimeErrorCode.LATE_FINAL_FIELD_WITH_CONST_CONSTRUCTOR;
 
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
   test_class_hasConstConstructor_instance_hasInitializer() async {
     await assertErrorsInCode('''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/late_final_local_already_assigned_test.dart b/pkg/analyzer/test/src/diagnostics/late_final_local_already_assigned_test.dart
index bfae4d0..2e4f1d4 100644
--- a/pkg/analyzer/test/src/diagnostics/late_final_local_already_assigned_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/late_final_local_already_assigned_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,15 +15,8 @@
 }
 
 @reflectiveTest
-class LateFinalLocalAlreadyAssignedTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class LateFinalLocalAlreadyAssignedTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_assignmentExpression_compound() async {
     await assertErrorsInCode('''
 main() {
diff --git a/pkg/analyzer/test/src/diagnostics/missing_default_value_for_parameter_test.dart b/pkg/analyzer/test/src/diagnostics/missing_default_value_for_parameter_test.dart
index b78b72b..664ef40 100644
--- a/pkg/analyzer/test/src/diagnostics/missing_default_value_for_parameter_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/missing_default_value_for_parameter_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,12 +16,8 @@
 }
 
 @reflectiveTest
-class MissingDefaultValueForParameterTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class MissingDefaultValueForParameterTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_constructor_externalFactory_nonNullable_named_optional_noDefault() async {
     await assertNoErrorsInCode('''
 class C {
diff --git a/pkg/analyzer/test/src/diagnostics/missing_enum_constant_in_switch_test.dart b/pkg/analyzer/test/src/diagnostics/missing_enum_constant_in_switch_test.dart
index 8e7ff2e..7065eda 100644
--- a/pkg/analyzer/test/src/diagnostics/missing_enum_constant_in_switch_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/missing_enum_constant_in_switch_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -84,12 +83,7 @@
 
 @reflectiveTest
 class MissingEnumConstantInSwitchWithNnbdTest
-    extends MissingEnumConstantInSwitchTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends MissingEnumConstantInSwitchTest with WithNullSafetyMixin {
   test_nullable() async {
     await assertErrorsInCode('''
 enum E { one, two }
diff --git a/pkg/analyzer/test/src/diagnostics/missing_required_param_test.dart b/pkg/analyzer/test/src/diagnostics/missing_required_param_test.dart
index 8cc3c98..dfc42f9 100644
--- a/pkg/analyzer/test/src/diagnostics/missing_required_param_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/missing_required_param_test.dart
@@ -2,14 +2,13 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/package_mixin.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../../generated/test_support.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -246,12 +245,8 @@
 }
 
 @reflectiveTest
-class MissingRequiredParamWithNnbdTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class MissingRequiredParamWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_constructor_argumentGiven() async {
     await assertNoErrorsInCode(r'''
 class C {
diff --git a/pkg/analyzer/test/src/diagnostics/mixin_of_non_class_test.dart b/pkg/analyzer/test/src/diagnostics/mixin_of_non_class_test.dart
index 937abac..6f7275d 100644
--- a/pkg/analyzer/test/src/diagnostics/mixin_of_non_class_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/mixin_of_non_class_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -60,12 +59,8 @@
 }
 
 @reflectiveTest
-class MixinOfNonClassWithNnbdTest extends MixinOfNonClassTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class MixinOfNonClassWithNnbdTest extends MixinOfNonClassTest
+    with WithNullSafetyMixin {
   test_Never() async {
     await assertErrorsInCode('''
 class A with Never {}
diff --git a/pkg/analyzer/test/src/diagnostics/mixin_on_sealed_class_test.dart b/pkg/analyzer/test/src/diagnostics/mixin_on_sealed_class_test.dart
index aefd37f..74a169e 100644
--- a/pkg/analyzer/test/src/diagnostics/mixin_on_sealed_class_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/mixin_on_sealed_class_test.dart
@@ -107,6 +107,7 @@
   /// that [root] is the root of a PubWorkspace, and a PubWorkspacePackage.
   void _newPubPackageRoot(String root) {
     newFile('$root/pubspec.yaml');
+    configureWorkspace(root: root);
   }
 
   /// Resolve the file with the given [path].
diff --git a/pkg/analyzer/test/src/diagnostics/mixin_super_class_constraint_non_interface_test.dart b/pkg/analyzer/test/src/diagnostics/mixin_super_class_constraint_non_interface_test.dart
index cb304c57..3b00377 100644
--- a/pkg/analyzer/test/src/diagnostics/mixin_super_class_constraint_non_interface_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/mixin_super_class_constraint_non_interface_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -21,12 +20,7 @@
 
 @reflectiveTest
 class MixinSuperClassConstraintNonInterfaceWithNnbdTest
-    extends MixinSuperClassConstraintNonInterfaceTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends MixinSuperClassConstraintNonInterfaceTest with WithNullSafetyMixin {
   test_Never() async {
     await assertErrorsInCode('''
 mixin M on Never {}
diff --git a/pkg/analyzer/test/src/diagnostics/mixins_super_class_test.dart b/pkg/analyzer/test/src/diagnostics/mixins_super_class_test.dart
new file mode 100644
index 0000000..88807fb
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/mixins_super_class_test.dart
@@ -0,0 +1,35 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(MixinsSuperClassTest);
+  });
+}
+
+@reflectiveTest
+class MixinsSuperClassTest extends DriverResolutionTest {
+  test_class() async {
+    await assertErrorsInCode(r'''
+class A {}
+class B extends A with A {}
+''', [
+      error(CompileTimeErrorCode.MIXINS_SUPER_CLASS, 34, 1),
+    ]);
+  }
+
+  test_classAlias() async {
+    await assertErrorsInCode(r'''
+class A {}
+class B = A with A;
+''', [
+      error(CompileTimeErrorCode.MIXINS_SUPER_CLASS, 28, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/multiple_redirecting_constructor_invocations_test.dart b/pkg/analyzer/test/src/diagnostics/multiple_redirecting_constructor_invocations_test.dart
new file mode 100644
index 0000000..fbe553e
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/multiple_redirecting_constructor_invocations_test.dart
@@ -0,0 +1,31 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(MultipleRedirectingConstructorInvocationsTest);
+  });
+}
+
+@reflectiveTest
+class MultipleRedirectingConstructorInvocationsTest
+    extends DriverResolutionTest {
+  test_twoNamedConstructorInvocations() async {
+    await assertErrorsInCode(r'''
+class A {
+  A() : this.a(), this.b();
+  A.a() {}
+  A.b() {}
+}
+''', [
+      error(CompileTimeErrorCode.MULTIPLE_REDIRECTING_CONSTRUCTOR_INVOCATIONS,
+          28, 8),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/multiple_super_initializers_test.dart b/pkg/analyzer/test/src/diagnostics/multiple_super_initializers_test.dart
new file mode 100644
index 0000000..6423c0d
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/multiple_super_initializers_test.dart
@@ -0,0 +1,29 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(MultipleSuperInitializersTest);
+  });
+}
+
+@reflectiveTest
+class MultipleSuperInitializersTest extends DriverResolutionTest {
+  test_twoSuperInitializers() async {
+    await assertErrorsInCode(r'''
+class A {}
+class B extends A {
+  B() : super(), super() {}
+}
+''', [
+      error(StrongModeCode.INVALID_SUPER_INVOCATION, 39, 7),
+      error(CompileTimeErrorCode.MULTIPLE_SUPER_INITIALIZERS, 48, 7),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/native_clause_in_non_sdk_code_test.dart b/pkg/analyzer/test/src/diagnostics/native_clause_in_non_sdk_code_test.dart
new file mode 100644
index 0000000..878ee80
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/native_clause_in_non_sdk_code_test.dart
@@ -0,0 +1,25 @@
+// 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 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NativeClauseInNonSdkCodeTest);
+  });
+}
+
+@reflectiveTest
+class NativeClauseInNonSdkCodeTest extends DriverResolutionTest {
+  test_nativeClauseInNonSDKCode() async {
+    await assertErrorsInCode('''
+class A native 'string' {}
+''', [
+      error(ParserErrorCode.NATIVE_CLAUSE_IN_NON_SDK_CODE, 8, 15),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/native_function_body_in_non_sdk_code_test.dart b/pkg/analyzer/test/src/diagnostics/native_function_body_in_non_sdk_code_test.dart
new file mode 100644
index 0000000..186022e
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/native_function_body_in_non_sdk_code_test.dart
@@ -0,0 +1,45 @@
+// 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 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NativeFunctionBodyInNonSdkCodeTest);
+  });
+}
+
+@reflectiveTest
+class NativeFunctionBodyInNonSdkCodeTest extends DriverResolutionTest {
+  test_function() async {
+    await assertErrorsInCode('''
+int m(a) native 'string';
+''', [
+      error(ParserErrorCode.NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE, 9, 16),
+    ]);
+  }
+
+  test_method() async {
+    await assertErrorsInCode(r'''
+class A {
+  static int m(a) native 'string';
+}
+''', [
+      error(ParserErrorCode.NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE, 28, 16),
+    ]);
+  }
+
+  test_mixinMethod() async {
+    await assertErrorsInCode(r'''
+mixin A {
+  static int m(a) native 'string';
+}
+''', [
+      error(ParserErrorCode.NATIVE_FUNCTION_BODY_IN_NON_SDK_CODE, 28, 16),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/new_with_non_type_test.dart b/pkg/analyzer/test/src/diagnostics/new_with_non_type_test.dart
index 758cb1f..04bd897d 100644
--- a/pkg/analyzer/test/src/diagnostics/new_with_non_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/new_with_non_type_test.dart
@@ -51,6 +51,19 @@
     ]);
   }
 
+  test_malformed_constructor_call() async {
+    await assertErrorsInCode('''
+class C {
+  C.x();
+}
+main() {
+  new C.x.y();
+}
+''', [
+      error(StaticWarningCode.NEW_WITH_NON_TYPE, 36, 3),
+    ]);
+  }
+
   test_typeParameter() async {
     await assertErrorsInCode('''
 void foo<T>() {
diff --git a/pkg/analyzer/test/src/diagnostics/no_annotation_constructor_arguments_test.dart b/pkg/analyzer/test/src/diagnostics/no_annotation_constructor_arguments_test.dart
new file mode 100644
index 0000000..8c6eebd
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/no_annotation_constructor_arguments_test.dart
@@ -0,0 +1,30 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NoAnnotationConstructorArgumentsTest);
+  });
+}
+
+@reflectiveTest
+class NoAnnotationConstructorArgumentsTest extends DriverResolutionTest {
+  test_missingArgumentList() async {
+    await assertErrorsInCode(r'''
+class A {
+  const A();
+}
+@A
+main() {
+}
+''', [
+      error(CompileTimeErrorCode.NO_ANNOTATION_CONSTRUCTOR_ARGUMENTS, 25, 2),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/non_bool_condition_test.dart b/pkg/analyzer/test/src/diagnostics/non_bool_condition_test.dart
index f209280..cd56b71 100644
--- a/pkg/analyzer/test/src/diagnostics/non_bool_condition_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_bool_condition_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -86,13 +84,8 @@
 }
 
 @reflectiveTest
-class NonBoolConditionTest_NNBD extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NonBoolConditionTest_NNBD extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_if_null() async {
     await assertErrorsInCode(r'''
 m() {
diff --git a/pkg/analyzer/test/src/diagnostics/non_bool_negation_expression_test.dart b/pkg/analyzer/test/src/diagnostics/non_bool_negation_expression_test.dart
index d8d9af0..5c76c36 100644
--- a/pkg/analyzer/test/src/diagnostics/non_bool_negation_expression_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_bool_negation_expression_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -31,13 +29,8 @@
 }
 
 @reflectiveTest
-class NonBoolNegationExpressionTest_NNBD extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NonBoolNegationExpressionTest_NNBD extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_null() async {
     await assertErrorsInCode(r'''
 m() {
diff --git a/pkg/analyzer/test/src/diagnostics/non_bool_operand_test.dart b/pkg/analyzer/test/src/diagnostics/non_bool_operand_test.dart
index f322a56..25168ff 100644
--- a/pkg/analyzer/test/src/diagnostics/non_bool_operand_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_bool_operand_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -61,13 +59,8 @@
 }
 
 @reflectiveTest
-class NonBoolOperandTest_NNBD extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NonBoolOperandTest_NNBD extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_and_null() async {
     await assertErrorsInCode(r'''
 m() {
diff --git a/pkg/analyzer/test/src/diagnostics/non_constant_annotation_constructor_test.dart b/pkg/analyzer/test/src/diagnostics/non_constant_annotation_constructor_test.dart
new file mode 100644
index 0000000..74caf13
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/non_constant_annotation_constructor_test.dart
@@ -0,0 +1,43 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NonConstantAnnotationConstructorTest);
+  });
+}
+
+@reflectiveTest
+class NonConstantAnnotationConstructorTest extends DriverResolutionTest {
+  test_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  A.fromInt() {}
+}
+@A.fromInt()
+main() {
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_ANNOTATION_CONSTRUCTOR, 29, 12),
+    ]);
+  }
+
+  test_unnamed() async {
+    await assertErrorsInCode(r'''
+class A {
+  A() {}
+}
+@A()
+main() {
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_ANNOTATION_CONSTRUCTOR, 21, 4),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/non_constant_case_expression_test.dart b/pkg/analyzer/test/src/diagnostics/non_constant_case_expression_test.dart
index 4203442..30c5ffb 100644
--- a/pkg/analyzer/test/src/diagnostics/non_constant_case_expression_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_constant_case_expression_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -68,9 +67,4 @@
 
 @reflectiveTest
 class NonConstantCaseExpressionWithNnbdTest
-    extends NonConstantCaseExpressionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-}
+    extends NonConstantCaseExpressionTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/non_constant_default_value_from_deferred_library_test.dart b/pkg/analyzer/test/src/diagnostics/non_constant_default_value_from_deferred_library_test.dart
new file mode 100644
index 0000000..fa1d97b
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/non_constant_default_value_from_deferred_library_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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NonConstantDefaultValueFromDeferredLibraryTest);
+  });
+}
+
+@reflectiveTest
+class NonConstantDefaultValueFromDeferredLibraryTest
+    extends DriverResolutionTest {
+  test_deferred() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+const V = 1;
+''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+f({x : a.V}) {}
+''', [
+      error(
+          CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE_FROM_DEFERRED_LIBRARY,
+          55,
+          3),
+    ]);
+  }
+
+  test_nested() async {
+    newFile('/test/lib/lib1.dart', content: '''
+library lib1;
+const V = 1;
+''');
+    await assertErrorsInCode('''
+library root;
+import 'lib1.dart' deferred as a;
+f({x : a.V + 1}) {}
+''', [
+      error(
+          CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE_FROM_DEFERRED_LIBRARY,
+          55,
+          7),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/non_constant_default_value_test.dart b/pkg/analyzer/test/src/diagnostics/non_constant_default_value_test.dart
index e3ba1db..7898167 100644
--- a/pkg/analyzer/test/src/diagnostics/non_constant_default_value_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_constant_default_value_test.dart
@@ -61,6 +61,68 @@
 ''', [ExpectedError(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 67, 1)]);
   }
 
+  test_constructor_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  int y;
+  A({x : y}) {}
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
+    ]);
+  }
+
+  test_constructor_positional() async {
+    await assertErrorsInCode(r'''
+class A {
+  int y;
+  A([x = y]) {}
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
+    ]);
+  }
+
+  test_function_named() async {
+    await assertErrorsInCode(r'''
+int y;
+f({x : y}) {}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 14, 1),
+    ]);
+  }
+
+  test_function_positional() async {
+    await assertErrorsInCode(r'''
+int y;
+f([x = y]) {}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 14, 1),
+    ]);
+  }
+
+  test_method_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  int y;
+  m({x : y}) {}
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
+    ]);
+  }
+
+  test_method_positional() async {
+    await assertErrorsInCode(r'''
+class A {
+  int y;
+  m([x = y]) {}
+}
+''', [
+      error(CompileTimeErrorCode.NON_CONSTANT_DEFAULT_VALUE, 28, 1),
+    ]);
+  }
+
   test_noAppliedTypeParameters_defaultConstructorValue_dynamic() async {
     await assertNoErrorsInCode(r'''
 void f<T>(T t) => t;
diff --git a/pkg/analyzer/test/src/diagnostics/non_null_opt_out_test.dart b/pkg/analyzer/test/src/diagnostics/non_null_opt_out_test.dart
index b72081b..3c0f17e 100644
--- a/pkg/analyzer/test/src/diagnostics/non_null_opt_out_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/non_null_opt_out_test.dart
@@ -3,17 +3,16 @@
 // BSD-style license that can be found in the LICENSE file.
 
 //import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/member.dart';
 import 'package:analyzer/src/dart/error/syntactic_errors.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/test_utilities/find_element.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -22,15 +21,7 @@
 }
 
 @reflectiveTest
-class NonNullOptOutTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class NonNullOptOutTest extends DriverResolutionTest with WithNullSafetyMixin {
   ImportFindElement get _import_a {
     return findElement.importFind('package:test/a.dart');
   }
diff --git a/pkg/analyzer/test/src/diagnostics/non_type_as_type_argument_test.dart b/pkg/analyzer/test/src/diagnostics/non_type_as_type_argument_test.dart
new file mode 100644
index 0000000..82e57ab
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/non_type_as_type_argument_test.dart
@@ -0,0 +1,36 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NonTypeAsTypeArgumentTest);
+  });
+}
+
+@reflectiveTest
+class NonTypeAsTypeArgumentTest extends DriverResolutionTest {
+  test_notAType() async {
+    await assertErrorsInCode(r'''
+int A;
+class B<E> {}
+f(B<A> b) {}
+''', [
+      error(StaticTypeWarningCode.NON_TYPE_AS_TYPE_ARGUMENT, 25, 1),
+    ]);
+  }
+
+  test_undefinedIdentifier() async {
+    await assertErrorsInCode(r'''
+class B<E> {}
+f(B<A> b) {}
+''', [
+      error(StaticTypeWarningCode.NON_TYPE_AS_TYPE_ARGUMENT, 18, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/not_assigned_potentially_non_nullable_local_variable_test.dart b/pkg/analyzer/test/src/diagnostics/not_assigned_potentially_non_nullable_local_variable_test.dart
index 480726c..ec53808 100644
--- a/pkg/analyzer/test/src/diagnostics/not_assigned_potentially_non_nullable_local_variable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/not_assigned_potentially_non_nullable_local_variable_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../../generated/test_support.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -21,13 +19,7 @@
 
 @reflectiveTest
 class NotInitializedPotentiallyNonNullableLocalVariableTest
-    extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+    extends DriverResolutionTest with WithNullSafetyMixin {
   test_assignment_leftExpression() async {
     await assertErrorsInCode(r'''
 void f() {
diff --git a/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_instance_field_test.dart b/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_instance_field_test.dart
index 1ef6b33..c1c0a58 100644
--- a/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_instance_field_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_instance_field_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NotInitializedNonNullableInstanceFieldTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NotInitializedNonNullableInstanceFieldTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_class_factoryConstructor() async {
     await assertNoErrorsInCode('''
 class A {
diff --git a/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_variable_test.dart b/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_variable_test.dart
index d606353..34a730b 100644
--- a/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_variable_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/not_initialized_non_nullable_variable_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NotInitializedNonNullableVariableTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NotInitializedNonNullableVariableTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_staticField_futureOr_questionArgument_none() async {
     await assertNoErrorsInCode('''
 import 'dart:async';
diff --git a/pkg/analyzer/test/src/diagnostics/not_instantiated_bound_test.dart b/pkg/analyzer/test/src/diagnostics/not_instantiated_bound_test.dart
new file mode 100644
index 0000000..74d5464
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/not_instantiated_bound_test.dart
@@ -0,0 +1,179 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(NotInstantiatedBoundTest);
+  });
+}
+
+@reflectiveTest
+class NotInstantiatedBoundTest extends DriverResolutionTest {
+  test_argument_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends List<K>> {}
+class C<T extends A> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 51, 1),
+    ]);
+  }
+
+  test_argumentDeep_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends List<List<K>>> {}
+class C<T extends A> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 57, 1),
+    ]);
+  }
+
+  test_class_bound_argument_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class A<T> {}
+class B<T extends int> {}
+class C<T extends A<B>> {}
+''');
+  }
+
+  test_class_bound_argument_recursive_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class A<K, V> {}
+class B<T extends int> {}
+class C<T extends A<B, B>> {}
+''');
+  }
+
+  test_class_bound_bound_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class A<T> {}
+class C<T extends A<int>> {}
+class D<T extends C> {}
+''');
+  }
+
+  test_class_function_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class A<T extends void Function()> {}
+class B<T extends A> {}
+''');
+  }
+
+  test_class_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class A<T extends int> {}
+class C1<T extends A> {}
+class C2<T extends List<A>> {}
+''');
+  }
+
+  test_class_recursion_boundArgument_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<T extends B<A>> {}
+class B<T extends A<B>> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 20, 1),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 47, 1),
+    ]);
+  }
+
+  test_class_recursion_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<T extends B> {} // points to a
+class B<T extends A> {} // points to b
+class C<T extends A> {} // points to a cyclical type
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 18, 1),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 57, 1),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 96, 1),
+    ]);
+  }
+
+  test_class_recursion_typedef_notInstantiated() async {
+    await assertErrorsInCode(r'''
+typedef F(C value);
+class C<T extends F> {}
+class D<T extends C> {}
+''', [
+      error(CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, 0, 19),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 38, 1),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 62, 1),
+    ]);
+  }
+
+  test_class_typedef_instantiated() async {
+    await assertNoErrorsInCode(r'''
+typedef void F<T extends int>();
+class C<T extends F> {}
+''');
+  }
+
+  test_direct_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends K> {}
+class C<T extends A> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 45, 1),
+    ]);
+  }
+
+  test_functionType_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<T extends Function(T)> {}
+class B<T extends T Function()> {}
+class C<T extends A> {}
+class D<T extends B> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 87, 1),
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 111, 1),
+    ]);
+  }
+
+  test_indirect_notInstantiatedt() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends K> {}
+class C<T extends List<A>> {}
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 50, 1),
+    ]);
+  }
+
+  test_typedef_argument_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends List<K>> {}
+typedef void F<T extends A>();
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 58, 1),
+    ]);
+  }
+
+  test_typedef_argumentDeep_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends List<List<K>>> {}
+typedef void F<T extends A>();
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 64, 1),
+    ]);
+  }
+
+  test_typedef_class_instantiated() async {
+    await assertNoErrorsInCode(r'''
+class C<T extends int> {}
+typedef void F<T extends C>();
+''');
+  }
+
+  test_typedef_direct_notInstantiated() async {
+    await assertErrorsInCode(r'''
+class A<K, V extends K> {}
+typedef void F<T extends A>();
+''', [
+      error(CompileTimeErrorCode.NOT_INSTANTIATED_BOUND, 52, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/not_iterable_spread_test.dart b/pkg/analyzer/test/src/diagnostics/not_iterable_spread_test.dart
index 06f4f23..bddd56a 100644
--- a/pkg/analyzer/test/src/diagnostics/not_iterable_spread_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/not_iterable_spread_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,15 +16,8 @@
 }
 
 @reflectiveTest
-class NotIterableSpreadNullSafetyTest extends NotIterableSpreadTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class NotIterableSpreadNullSafetyTest extends NotIterableSpreadTest
+    with WithNullSafetyMixin {
   test_iterable_typeParameter_bound_listQuestion() async {
     await assertNoErrorsInCode('''
 void f<T extends List<int>?>(T a) {
diff --git a/pkg/analyzer/test/src/diagnostics/not_map_spread_test.dart b/pkg/analyzer/test/src/diagnostics/not_map_spread_test.dart
index 98ccc0d..be66c57 100644
--- a/pkg/analyzer/test/src/diagnostics/not_map_spread_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/not_map_spread_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,15 +16,8 @@
 }
 
 @reflectiveTest
-class NotMapSpreadNullSafetyTest extends NotMapSpreadTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class NotMapSpreadNullSafetyTest extends NotMapSpreadTest
+    with WithNullSafetyMixin {
   test_map_typeParameter_bound_mapQuestion() async {
     await assertNoErrorsInCode('''
 void f<T extends Map<int, String>?>(T a) {
diff --git a/pkg/analyzer/test/src/diagnostics/nullable_type_in_catch_clause_test.dart b/pkg/analyzer/test/src/diagnostics/nullable_type_in_catch_clause_test.dart
index 10b129c..2816817 100644
--- a/pkg/analyzer/test/src/diagnostics/nullable_type_in_catch_clause_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/nullable_type_in_catch_clause_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/nullable_type_in_extends_clause_test.dart b/pkg/analyzer/test/src/diagnostics/nullable_type_in_extends_clause_test.dart
index afd262c..1a8847d 100644
--- a/pkg/analyzer/test/src/diagnostics/nullable_type_in_extends_clause_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/nullable_type_in_extends_clause_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NullableTypeInExtendsClauseTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NullableTypeInExtendsClauseTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_class_nonNullable() async {
     await assertNoErrorsInCode('''
 class A {}
diff --git a/pkg/analyzer/test/src/diagnostics/nullable_type_in_implements_clause_test.dart b/pkg/analyzer/test/src/diagnostics/nullable_type_in_implements_clause_test.dart
index 6ce28aa..7bcc751 100644
--- a/pkg/analyzer/test/src/diagnostics/nullable_type_in_implements_clause_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/nullable_type_in_implements_clause_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NullableTypeInImplementsClauseTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NullableTypeInImplementsClauseTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_class_nonNullable() async {
     await assertNoErrorsInCode('''
 class A {}
diff --git a/pkg/analyzer/test/src/diagnostics/nullable_type_in_on_clause_test.dart b/pkg/analyzer/test/src/diagnostics/nullable_type_in_on_clause_test.dart
index 84a72c0..d4b131f 100644
--- a/pkg/analyzer/test/src/diagnostics/nullable_type_in_on_clause_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/nullable_type_in_on_clause_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NullableTypeInOnClauseTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NullableTypeInOnClauseTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_nonNullable() async {
     await assertNoErrorsInCode('''
 class A {}
diff --git a/pkg/analyzer/test/src/diagnostics/nullable_type_in_with_clause_test.dart b/pkg/analyzer/test/src/diagnostics/nullable_type_in_with_clause_test.dart
index ec4d29c..e560da2 100644
--- a/pkg/analyzer/test/src/diagnostics/nullable_type_in_with_clause_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/nullable_type_in_with_clause_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class NullableTypeInWithClauseTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class NullableTypeInWithClauseTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_class_nonNullable() async {
     await assertNoErrorsInCode('''
 class A {}
diff --git a/pkg/analyzer/test/src/diagnostics/prefix_shadowed_by_local_declaration_test.dart b/pkg/analyzer/test/src/diagnostics/prefix_shadowed_by_local_declaration_test.dart
new file mode 100644
index 0000000..b70ac85
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/prefix_shadowed_by_local_declaration_test.dart
@@ -0,0 +1,69 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(PrefixShadowedByLocalDeclarationTest);
+  });
+}
+
+@reflectiveTest
+class PrefixShadowedByLocalDeclarationTest extends DriverResolutionTest {
+  test_function_return_type_not_shadowed_by_parameter() async {
+    await assertNoErrorsInCode('''
+import 'dart:async' as a;
+a.Future f(int a) {
+  return null;
+}
+''');
+  }
+
+  test_local_variable_type_inside_function_with_shadowing_parameter() async {
+    await assertErrorsInCode('''
+import 'dart:async' as a;
+f(int a) {
+  a.Future x = null;
+  return x;
+}
+''', [
+      error(HintCode.UNUSED_IMPORT, 7, 12),
+      error(CompileTimeErrorCode.PREFIX_SHADOWED_BY_LOCAL_DECLARATION, 39, 1),
+    ]);
+  }
+
+  test_local_variable_type_inside_function_with_shadowing_variable_after() async {
+    await assertErrorsInCode('''
+import 'dart:async' as a;
+f() {
+  a.Future x = null;
+  int a = 0;
+  return [x, a];
+}
+''', [
+      error(HintCode.UNUSED_IMPORT, 7, 12),
+      error(CompileTimeErrorCode.REFERENCED_BEFORE_DECLARATION, 34, 1,
+          contextMessages: [message('/test/lib/test.dart', 59, 1)]),
+      error(CompileTimeErrorCode.PREFIX_SHADOWED_BY_LOCAL_DECLARATION, 34, 1),
+    ]);
+  }
+
+  test_local_variable_type_inside_function_with_shadowing_variable_before() async {
+    await assertErrorsInCode('''
+import 'dart:async' as a;
+f() {
+  int a = 0;
+  a.Future x = null;
+  return [x, a];
+}
+''', [
+      error(HintCode.UNUSED_IMPORT, 7, 12),
+      error(CompileTimeErrorCode.PREFIX_SHADOWED_BY_LOCAL_DECLARATION, 47, 1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/private_collision_in_mixin_application_test.dart b/pkg/analyzer/test/src/diagnostics/private_collision_in_mixin_application_test.dart
index 689ae85..8e840e0 100644
--- a/pkg/analyzer/test/src/diagnostics/private_collision_in_mixin_application_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/private_collision_in_mixin_application_test.dart
@@ -147,22 +147,6 @@
     ]);
   }
 
-  test_class_superclassAndMixin_same() async {
-    newFile('/test/lib/a.dart', content: r'''
-class A {
-  void _foo() {}
-}
-''');
-
-    await assertErrorsInCode('''
-import 'a.dart';
-
-class C extends A with A {}
-''', [
-      error(CompileTimeErrorCode.PRIVATE_COLLISION_IN_MIXIN_APPLICATION, 41, 1),
-    ]);
-  }
-
   test_class_superclassAndMixin_sameLibrary() async {
     await assertErrorsInCode('''
 class A {
@@ -260,24 +244,4 @@
       error(CompileTimeErrorCode.PRIVATE_COLLISION_IN_MIXIN_APPLICATION, 35, 1),
     ]);
   }
-
-  test_classTypeAlias_superclassAndMixin_same() async {
-    newFile('/test/lib/a.dart', content: r'''
-class A {
-  void _foo() {}
-}
-
-class B {
-  void _foo() {}
-}
-''');
-
-    await assertErrorsInCode('''
-import 'a.dart';
-
-class C = A with A;
-''', [
-      error(CompileTimeErrorCode.PRIVATE_COLLISION_IN_MIXIN_APPLICATION, 35, 1),
-    ]);
-  }
 }
diff --git a/pkg/analyzer/test/src/diagnostics/private_setter_test.dart b/pkg/analyzer/test/src/diagnostics/private_setter_test.dart
new file mode 100644
index 0000000..9566d3c
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/private_setter_test.dart
@@ -0,0 +1,113 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(PrivateSetterTest);
+  });
+}
+
+@reflectiveTest
+class PrivateSetterTest extends DriverResolutionTest {
+  test_typeLiteral_privateField_differentLibrary() async {
+    newFile('/test/lib/a.dart', content: r'''
+class A {
+  static int _foo = 0;
+}
+''');
+    await assertErrorsInCode(r'''
+import 'a.dart';
+
+main() {
+  A._foo = 0;
+}
+''', [
+      error(CompileTimeErrorCode.PRIVATE_SETTER, 31, 4),
+    ]);
+
+    var aImport = findElement.importFind('package:test/a.dart');
+    assertElement(
+      findNode.simple('_foo = 0'),
+      aImport.setter('_foo'),
+    );
+  }
+
+  test_typeLiteral_privateField_sameLibrary() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  // ignore:unused_field
+  static int _foo = 0;
+}
+
+main() {
+  A._foo = 0;
+}
+''');
+  }
+
+  test_typeLiteral_privateSetter__sameLibrary() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  static set _foo(int _) {}
+}
+
+main() {
+  A._foo = 0;
+}
+''');
+  }
+
+  test_typeLiteral_privateSetter_differentLibrary_hasGetter() async {
+    newFile('/test/lib/a.dart', content: r'''
+class A {
+  static set _foo(int _) {}
+  
+  static int get _foo => 0;
+}
+''');
+    await assertErrorsInCode(r'''
+import 'a.dart';
+
+main() {
+  A._foo = 0;
+}
+''', [
+      error(CompileTimeErrorCode.PRIVATE_SETTER, 31, 4),
+    ]);
+
+    var aImport = findElement.importFind('package:test/a.dart');
+    assertElement(
+      findNode.simple('_foo = 0'),
+      aImport.setter('_foo'),
+    );
+  }
+
+  test_typeLiteral_privateSetter_differentLibrary_noGetter() async {
+    newFile('/test/lib/a.dart', content: r'''
+class A {
+  static set _foo(int _) {}
+}
+''');
+    await assertErrorsInCode(r'''
+import 'a.dart';
+
+main() {
+  A._foo = 0;
+}
+''', [
+      error(CompileTimeErrorCode.PRIVATE_SETTER, 31, 4),
+    ]);
+
+    var aImport = findElement.importFind('package:test/a.dart');
+    assertElement(
+      findNode.simple('_foo = 0'),
+      aImport.setter('_foo'),
+    );
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/receiver_of_type_never_test.dart b/pkg/analyzer/test/src/diagnostics/receiver_of_type_never_test.dart
index 3c4b65e..c466333 100644
--- a/pkg/analyzer/test/src/diagnostics/receiver_of_type_never_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/receiver_of_type_never_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -18,16 +16,8 @@
 }
 
 @reflectiveTest
-class InvalidUseOfNeverTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class InvalidUseOfNeverTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_binaryExpression_never_eqEq() async {
     await assertErrorsInCode(r'''
 void main(Never x) {
diff --git a/pkg/analyzer/test/src/diagnostics/return_of_invalid_type_test.dart b/pkg/analyzer/test/src/diagnostics/return_of_invalid_type_test.dart
index f078f04..74f3305 100644
--- a/pkg/analyzer/test/src/diagnostics/return_of_invalid_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/return_of_invalid_type_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/return_without_value_test.dart b/pkg/analyzer/test/src/diagnostics/return_without_value_test.dart
index 1d5efe5..be13d13 100644
--- a/pkg/analyzer/test/src/diagnostics/return_without_value_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/return_without_value_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/sdk_version_never_test.dart b/pkg/analyzer/test/src/diagnostics/sdk_version_never_test.dart
index ecbfa36..443e5d00 100644
--- a/pkg/analyzer/test/src/diagnostics/sdk_version_never_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/sdk_version_never_test.dart
@@ -7,6 +7,7 @@
 import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
+import '../dart/resolution/with_null_safety_mixin.dart';
 import 'sdk_constraint_verifier_support.dart';
 
 main() {
@@ -32,12 +33,8 @@
 }
 
 @reflectiveTest
-class SdkVersionNeverWithNnbdTest extends SdkConstraintVerifierTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures =
-        FeatureSet.forTesting(additionalFeatures: [Feature.non_nullable]);
-
+class SdkVersionNeverWithNnbdTest extends SdkConstraintVerifierTest
+    with WithNullSafetyMixin {
   test_experimentEnabled() async {
     await verifyVersion('2.7.0', r'''
 Never foo = (throw 42);
diff --git a/pkg/analyzer/test/src/diagnostics/subtype_of_sealed_class_test.dart b/pkg/analyzer/test/src/diagnostics/subtype_of_sealed_class_test.dart
index cf50d59..1ac4382 100644
--- a/pkg/analyzer/test/src/diagnostics/subtype_of_sealed_class_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/subtype_of_sealed_class_test.dart
@@ -206,6 +206,7 @@
   /// that [root] is the root of a PubWorkspace, and a PubWorkspacePackage.
   void _newPubPackageRoot(String root) {
     newFile('$root/pubspec.yaml');
+    configureWorkspace(root: root);
   }
 
   /// Resolve the file with the given [path].
diff --git a/pkg/analyzer/test/src/diagnostics/switch_case_completes_normally_test.dart b/pkg/analyzer/test/src/diagnostics/switch_case_completes_normally_test.dart
index 2060b19..6209d99 100644
--- a/pkg/analyzer/test/src/diagnostics/switch_case_completes_normally_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/switch_case_completes_normally_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -16,12 +15,8 @@
 }
 
 @reflectiveTest
-class SwitchCaseCompletesNormallyTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+class SwitchCaseCompletesNormallyTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_break() async {
     await assertNoErrorsInCode(r'''
 void f(int a) {
diff --git a/pkg/analyzer/test/src/diagnostics/test_all.dart b/pkg/analyzer/test/src/diagnostics/test_all.dart
index 496937e..170a1f0 100644
--- a/pkg/analyzer/test/src/diagnostics/test_all.dart
+++ b/pkg/analyzer/test/src/diagnostics/test_all.dart
@@ -4,14 +4,17 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
+import 'abstract_class_member_test.dart' as abstract_class_member;
 import 'abstract_super_member_reference_test.dart'
     as abstract_super_member_reference;
+import 'access_private_enum_field_test.dart' as access_private_enum_field;
 import 'ambiguous_export_test.dart' as ambiguous_export;
 import 'ambiguous_extension_member_access_test.dart'
     as ambiguous_extension_member_access;
 import 'ambiguous_import_test.dart' as ambiguous_import;
 import 'ambiguous_set_or_map_literal_test.dart' as ambiguous_set_or_map_literal;
 import 'annotation_on_pointer_field_test.dart' as annotation_on_pointer_field;
+import 'annotation_with_non_class_test.dart' as annotation_with_non_class;
 import 'argument_type_not_assignable_test.dart' as argument_type_not_assignable;
 import 'assert_in_redirecting_constructor_test.dart'
     as assert_in_redirecting_constructor;
@@ -23,10 +26,12 @@
 import 'assignment_to_function_test.dart' as assignment_to_function;
 import 'assignment_to_method_test.dart' as assignment_to_method;
 import 'assignment_to_type_test.dart' as assignment_to_type;
+import 'async_for_in_wrong_context_test.dart' as async_for_in_wrong_context;
 import 'async_keyword_used_as_identifier_test.dart'
     as async_keyword_used_as_identifier;
 import 'await_in_late_local_variable_initializer_test.dart'
     as await_in_late_local_variable_initializer;
+import 'await_in_wrong_context_test.dart' as await_in_wrong_context;
 import 'body_might_complete_normally_test.dart' as body_might_complete_normally;
 import 'built_in_identifier_as_extension_name_test.dart'
     as built_in_as_extension_name;
@@ -60,7 +65,21 @@
     as const_constructor_with_field_initialized_by_non_const;
 import 'const_constructor_with_mixin_with_field_test.dart'
     as const_constructor_with_mixin_with_field;
+import 'const_constructor_with_non_const_super_test.dart'
+    as const_constructor_with_non_const_super;
+import 'const_constructor_with_non_final_field_test.dart'
+    as const_constructor_with_non_final_field;
+import 'const_deferred_class_test.dart' as const_deferred_class;
 import 'const_eval_throws_exception_test.dart' as const_eval_throws_exception;
+import 'const_eval_type_bool_num_string_test.dart'
+    as const_eval_type_bool_num_string;
+import 'const_eval_type_bool_test.dart' as const_eval_type_bool;
+import 'const_formal_parameter_test.dart' as const_formal_parameter;
+import 'const_initialized_with_non_constant_value_from_deferred_library_test.dart'
+    as const_initialized_with_non_constant_value_from_deferred_library;
+import 'const_initialized_with_non_constant_value_test.dart'
+    as const_initialized_with_non_constant_value;
+import 'const_instance_field_test.dart' as const_instance_field;
 import 'const_map_key_expression_type_implements_equals_test.dart'
     as const_map_key_expression_type_implements_equals;
 import 'const_not_initialized_test.dart' as const_not_initialized;
@@ -69,6 +88,7 @@
 import 'const_spread_expected_list_or_set_test.dart'
     as const_spread_expected_list_or_set;
 import 'const_spread_expected_map_test.dart' as const_spread_expected_map;
+import 'const_with_non_const_test.dart' as const_with_non_const;
 import 'dead_code_test.dart' as dead_code;
 import 'dead_null_aware_expression_test.dart' as dead_null_aware_expression;
 import 'default_list_constructor_test.dart' as default_list_constructor;
@@ -107,8 +127,6 @@
     as expected_one_set_type_arguments;
 import 'expected_two_map_type_arguments_test.dart'
     as expected_two_map_type_arguments;
-import 'export_duplicated_library_named_test.dart'
-    as export_duplicated_library_named;
 import 'export_internal_library_test.dart' as export_internal_library;
 import 'export_legacy_symbol_test.dart' as export_legacy_symbol;
 import 'export_of_non_library_test.dart' as export_of_non_library;
@@ -174,7 +192,11 @@
     as getter_not_subtype_setter_types;
 import 'if_element_condition_from_deferred_library_test.dart'
     as if_element_condition_from_deferred_library;
+import 'illegal_async_generator_return_type_test.dart'
+    as illegal_async_generator_return_type;
 import 'illegal_async_return_type_test.dart' as illegal_async_return_type;
+import 'illegal_sync_generator_return_type_test.dart'
+    as illegal_sync_generator_return_type;
 import 'implements_deferred_class_test.dart' as implements_deferred_class;
 import 'implements_disallowed_class_test.dart' as implements_disallowed_class;
 import 'implements_non_class_test.dart' as implements_non_class;
@@ -183,14 +205,14 @@
     as implicit_this_reference_in_initializer;
 import 'import_deferred_library_with_load_function_test.dart'
     as import_deferred_library_with_load_function;
-import 'import_duplicated_library_named_test.dart'
-    as import_duplicated_library_named;
 import 'import_of_non_library_test.dart' as import_of_non_library;
 import 'inconsistent_case_expression_types_test.dart'
     as inconsistent_case_expression_types;
 import 'inconsistent_inheritance_getter_and_method_test.dart'
     as inconsistent_inheritance_getter_and_method;
 import 'inconsistent_inheritance_test.dart' as inconsistent_inheritance;
+import 'inconsistent_language_version_override_test.dart'
+    as inconsistent_language_version_override;
 import 'inference_failure_on_collection_literal_test.dart'
     as inference_failure_on_collection_literal;
 import 'inference_failure_on_function_return_type_test.dart'
@@ -199,11 +221,24 @@
     as inference_failure_on_uninitialized_variable;
 import 'inference_failure_on_untyped_parameter_test.dart'
     as inference_failure_on_untyped_parameter;
+import 'initializer_for_non_existent_field_test.dart'
+    as initializer_for_non_existent_field;
+import 'initializer_for_static_field_test.dart' as initializer_for_static_field;
+import 'initializing_formal_for_non_existent_field_test.dart'
+    as initializing_formal_for_non_existent_field;
+import 'initializing_formal_for_static_field_test.dart'
+    as initializing_formal_for_static_field;
 import 'instance_access_to_static_member_test.dart'
     as instance_access_to_static_member;
+import 'instance_member_access_from_factory_test.dart'
+    as instance_member_access_from_factory;
 import 'instance_member_access_from_static_test.dart'
     as instance_member_access_from_static;
 import 'instantiate_abstract_class_test.dart' as instantiate_abstract_class;
+import 'instantiate_enum_test.dart' as instantiate_enum;
+import 'integer_literal_imprecise_as_double_test.dart'
+    as integer_literal_imprecise_as_double;
+import 'integer_literal_out_of_range_test.dart' as integer_literal_out_of_range;
 import 'invalid_annotation_from_deferred_library_test.dart'
     as invalid_annotation_from_deferred_library;
 import 'invalid_annotation_getter_test.dart' as invalid_annotation_getter;
@@ -227,6 +262,7 @@
 import 'invalid_literal_annotation_test.dart' as invalid_literal_annotation;
 import 'invalid_modifier_on_constructor_test.dart'
     as invalid_modifier_on_constructor;
+import 'invalid_modifier_on_setter_test.dart' as invalid_modifier_on_setter;
 import 'invalid_non_virtual_annotation_test.dart'
     as invalid_non_virtual_annotation;
 import 'invalid_null_aware_operator_test.dart' as invalid_null_aware_operator;
@@ -263,6 +299,8 @@
     as invalid_visibility_annotation;
 import 'invocation_of_extension_without_call_test.dart'
     as invocation_of_extension_without_call;
+import 'invocation_of_non_function_expression_test.dart'
+    as invocation_of_non_function_expression;
 import 'is_double_test.dart' as is_double;
 import 'is_int_test.dart' as is_int;
 import 'is_not_double_test.dart' as is_not_double;
@@ -308,14 +346,24 @@
     as mixin_super_class_constraint_non_interface;
 import 'mixin_with_non_class_superclass_test.dart'
     as mixin_with_non_class_superclass;
+import 'mixins_super_class_test.dart' as mixins_super_class;
+import 'multiple_redirecting_constructor_invocations_test.dart'
+    as multiple_redirecting_constructor_invocations;
+import 'multiple_super_initializers_test.dart' as multiple_super_initializers;
 import 'must_be_a_native_function_type_test.dart'
     as must_be_a_native_function_type;
 import 'must_be_a_subtype_test.dart' as must_be_a_subtype;
 import 'must_be_immutable_test.dart' as must_be_immutable;
 import 'must_call_super_test.dart' as must_call_super;
+import 'native_clause_in_non_sdk_code_test.dart'
+    as native_clause_in_non_sdk_code;
+import 'native_function_body_in_non_sdk_code_test.dart'
+    as native_function_body_in_non_sdk_code;
 import 'new_with_non_type_test.dart' as new_with_non_type;
 import 'new_with_undefined_constructor_test.dart'
     as new_with_undefined_constructor;
+import 'no_annotation_constructor_arguments_test.dart'
+    as no_annotation_constructor_arguments;
 import 'no_combined_super_signature_test.dart' as no_combined_super_signature;
 import 'no_default_super_constructor_test.dart' as no_default_super_constructor;
 import 'non_abstract_class_inherits_abstract_member_test.dart'
@@ -324,9 +372,13 @@
 import 'non_bool_expression_test.dart' as non_bool_expression;
 import 'non_bool_negation_expression_test.dart' as non_bool_negation_expression;
 import 'non_bool_operand_test.dart' as non_bool_operand;
+import 'non_constant_annotation_constructor_test.dart'
+    as non_constant_annotation_constructor;
 import 'non_constant_case_expression_from_deferred_library_test.dart'
     as non_constant_case_expression_from_deferred_library;
 import 'non_constant_case_expression_test.dart' as non_constant_case_expression;
+import 'non_constant_default_value_from_deferred_library_test.dart'
+    as non_constant_default_value_from_deferred_library;
 import 'non_constant_default_value_test.dart' as non_constant_default_value;
 import 'non_constant_list_element_from_deferred_library_test.dart'
     as non_constant_list_element_from_deferred_library;
@@ -344,6 +396,7 @@
 import 'non_native_function_type_argument_to_pointer_test.dart'
     as non_native_function_type_argument_to_pointer;
 import 'non_null_opt_out_test.dart' as non_null_opt_out;
+import 'non_type_as_type_argument_test.dart' as non_type_as_type_argument;
 import 'non_type_in_catch_clause_test.dart' as non_type_in_catch_clause;
 import 'non_void_return_for_operator_test.dart' as non_void_return_for_operator;
 import 'non_void_return_for_setter_test.dart' as non_void_return_for_setter;
@@ -356,6 +409,7 @@
     as not_initialized_non_nullable_instance_field;
 import 'not_initialized_non_nullable_variable_test.dart'
     as not_initialized_non_nullable_variable;
+import 'not_instantiated_bound_test.dart' as not_instantiated_bound;
 import 'not_iterable_spread_test.dart' as not_iterable_spread;
 import 'not_map_spread_test.dart' as not_map_spread;
 import 'not_null_aware_null_spread_test.dart' as not_null_aware_null_spread;
@@ -391,9 +445,12 @@
     as prefix_collides_with_top_level_member;
 import 'prefix_identifier_not_followed_by_dot_test.dart'
     as prefix_identifier_not_followed_by_dot;
+import 'prefix_shadowed_by_local_declaration_test.dart'
+    as prefix_shadowed_by_local_declaration;
 import 'private_collision_in_mixin_application_test.dart'
     as private_collision_in_mixin_application;
 import 'private_optional_parameter_test.dart' as private_optional_parameter;
+import 'private_setter_test.dart' as private_setter;
 import 'receiver_of_type_never_test.dart' as receiver_of_type_never;
 import 'recursive_compile_time_constant_test.dart'
     as recursive_compile_time_constant;
@@ -479,6 +536,8 @@
 import 'type_check_is_null_test.dart' as type_check_is_null;
 import 'type_parameter_referenced_by_static_test.dart'
     as type_parameter_referenced_by_static;
+import 'type_parameter_supertype_of_its_bound_test.dart'
+    as type_parameter_supertype_of_its_bound;
 import 'type_test_with_non_type_test.dart' as type_test_with_non_type;
 import 'type_test_with_undefined_name_test.dart'
     as type_test_with_undefined_name;
@@ -510,6 +569,8 @@
     as unnecessary_non_null_assertion;
 import 'unnecessary_null_comparison_test.dart' as unnecessary_null_comparison;
 import 'unnecessary_type_check_test.dart' as unnecessary_type_check;
+import 'unqualified_reference_to_non_local_static_member_test.dart'
+    as unqualified_reference_to_non_local_static_member;
 import 'unqualified_reference_to_static_member_of_extended_type_test.dart'
     as unqualified_reference_to_static_member_of_extended_type;
 import 'unused_catch_clause_test.dart' as unused_catch_clause;
@@ -540,12 +601,15 @@
 
 main() {
   defineReflectiveSuite(() {
+    abstract_class_member.main();
     abstract_super_member_reference.main();
+    access_private_enum_field.main();
     ambiguous_export.main();
     ambiguous_extension_member_access.main();
     ambiguous_import.main();
     ambiguous_set_or_map_literal.main();
     annotation_on_pointer_field.main();
+    annotation_with_non_class.main();
     argument_type_not_assignable.main();
     assert_in_redirecting_constructor.main();
     assignment_to_const.main();
@@ -555,8 +619,10 @@
     assignment_to_function.main();
     assignment_to_method.main();
     assignment_to_type.main();
+    async_for_in_wrong_context.main();
     async_keyword_used_as_identifier.main();
     await_in_late_local_variable_initializer.main();
+    await_in_wrong_context.main();
     body_might_complete_normally.main();
     built_in_as_extension_name.main();
     built_in_as_prefix_name.main();
@@ -576,12 +642,22 @@
     const_constructor_param_type_mismatch.main();
     const_constructor_with_field_initialized_by_non_const.main();
     const_constructor_with_mixin_with_field.main();
+    const_constructor_with_non_const_super.main();
+    const_constructor_with_non_final_field.main();
+    const_deferred_class.main();
     const_eval_throws_exception.main();
+    const_eval_type_bool_num_string.main();
+    const_eval_type_bool.main();
+    const_formal_parameter.main();
+    const_initialized_with_non_constant_value_from_deferred_library.main();
+    const_initialized_with_non_constant_value.main();
+    const_instance_field.main();
     const_map_key_expression_type_implements_equals.main();
     const_not_initialized.main();
     const_set_element_type_implements_equals.main();
     const_spread_expected_list_or_set.main();
     const_spread_expected_map.main();
+    const_with_non_const.main();
     dead_code.main();
     dead_null_aware_expression.main();
     default_list_constructor.main();
@@ -610,7 +686,6 @@
     expected_one_list_type_arguments.main();
     expected_one_set_type_arguments.main();
     expected_two_map_type_arguments.main();
-    export_duplicated_library_named.main();
     export_internal_library.main();
     export_legacy_symbol.main();
     export_of_non_library.main();
@@ -651,25 +726,35 @@
     getter_not_assignable_setter_types.main();
     getter_not_subtype_setter_types.main();
     if_element_condition_from_deferred_library.main();
+    illegal_async_generator_return_type.main();
     illegal_async_return_type.main();
+    illegal_sync_generator_return_type.main();
     implements_deferred_class.main();
     implements_disallowed_class.main();
     implements_non_class.main();
     implements_super_class.main();
     implicit_this_reference_in_initializer.main();
     import_deferred_library_with_load_function.main();
-    import_duplicated_library_named.main();
     import_of_non_library.main();
     inconsistent_case_expression_types.main();
     inconsistent_inheritance_getter_and_method.main();
     inconsistent_inheritance.main();
+    inconsistent_language_version_override.main();
     inference_failure_on_collection_literal.main();
     inference_failure_on_function_return_type.main();
     inference_failure_on_uninitialized_variable.main();
     inference_failure_on_untyped_parameter.main();
+    initializer_for_non_existent_field.main();
+    initializer_for_static_field.main();
+    initializing_formal_for_non_existent_field.main();
+    initializing_formal_for_static_field.main();
     instance_access_to_static_member.main();
+    instance_member_access_from_factory.main();
     instance_member_access_from_static.main();
     instantiate_abstract_class.main();
+    instantiate_enum.main();
+    integer_literal_imprecise_as_double.main();
+    integer_literal_out_of_range.main();
     invalid_annotation.main();
     invalid_annotation_from_deferred_library.main();
     invalid_annotation_getter.main();
@@ -688,6 +773,7 @@
     invalid_language_override.main();
     invalid_literal_annotation.main();
     invalid_modifier_on_constructor.main();
+    invalid_modifier_on_setter.main();
     invalid_non_virtual_annotation.main();
     invalid_null_aware_operator.main();
     invalid_override_different_default_values_named.main();
@@ -709,6 +795,7 @@
     invalid_use_of_visible_for_testing_member.main();
     invalid_visibility_annotation.main();
     invocation_of_extension_without_call.main();
+    invocation_of_non_function_expression.main();
     is_double.main();
     is_int.main();
     is_not_double.main();
@@ -741,12 +828,18 @@
     mixin_on_sealed_class.main();
     mixin_super_class_constraint_non_interface.main();
     mixin_with_non_class_superclass.main();
+    mixins_super_class.main();
+    multiple_redirecting_constructor_invocations.main();
+    multiple_super_initializers.main();
     must_be_a_native_function_type.main();
     must_be_a_subtype.main();
     must_be_immutable.main();
     must_call_super.main();
+    native_clause_in_non_sdk_code.main();
+    native_function_body_in_non_sdk_code.main();
     new_with_non_type.main();
     new_with_undefined_constructor.main();
+    no_annotation_constructor_arguments.main();
     no_combined_super_signature.main();
     no_default_super_constructor.main();
     non_abstract_class_inherits_abstract_member.main();
@@ -754,9 +847,12 @@
     non_bool_expression.main();
     non_bool_negation_expression.main();
     non_bool_operand.main();
+    non_constant_annotation_constructor.main();
     non_constant_list_element.main();
     non_constant_case_expression_from_deferred_library.main();
     non_constant_case_expression.main();
+    non_constant_default_value_from_deferred_library.main();
+    non_constant_default_value.main();
     non_constant_list_element_from_deferred_library.main();
     non_constant_map_key.main();
     non_constant_map_key_from_deferred_library.main();
@@ -768,6 +864,7 @@
     non_generative_constructor.main();
     non_native_function_type_argument_to_pointer.main();
     non_null_opt_out.main();
+    non_type_as_type_argument.main();
     non_type_in_catch_clause.main();
     non_void_return_for_operator.main();
     non_void_return_for_setter.main();
@@ -776,6 +873,7 @@
     not_enough_positional_arguments.main();
     not_initialized_non_nullable_instance_field.main();
     not_initialized_non_nullable_variable.main();
+    not_instantiated_bound.main();
     not_iterable_spread.main();
     not_map_spread.main();
     not_null_aware_null_spread.main();
@@ -798,8 +896,10 @@
     part_of_non_part.main();
     prefix_collides_with_top_level_member.main();
     prefix_identifier_not_followed_by_dot.main();
+    prefix_shadowed_by_local_declaration.main();
     private_collision_in_mixin_application.main();
     private_optional_parameter.main();
+    private_setter.main();
     receiver_of_type_never.main();
     recursive_compile_time_constant.main();
     recursive_constructor_redirect.main();
@@ -855,6 +955,7 @@
     type_check_is_not_null.main();
     type_check_is_null.main();
     type_parameter_referenced_by_static.main();
+    type_parameter_supertype_of_its_bound.main();
     type_test_with_non_type.main();
     type_test_with_undefined_name.main();
     undefined_annotation.main();
@@ -877,12 +978,12 @@
     undefined_prefixed_name.main();
     undefined_setter.main();
     undefined_shown_name.main();
-    non_constant_default_value.main();
     unnecessary_cast.main();
     unnecessary_no_such_method.main();
     unnecessary_non_null_assertion.main();
     unnecessary_null_comparison.main();
     unnecessary_type_check.main();
+    unqualified_reference_to_non_local_static_member.main();
     unqualified_reference_to_static_member_of_extended_type.main();
     unused_catch_clause.main();
     unused_catch_stack.main();
diff --git a/pkg/analyzer/test/src/diagnostics/throw_of_invalid_type_test.dart b/pkg/analyzer/test/src/diagnostics/throw_of_invalid_type_test.dart
index 448719d..388aa99 100644
--- a/pkg/analyzer/test/src/diagnostics/throw_of_invalid_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/throw_of_invalid_type_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class ThrowOfInvalidTypeTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class ThrowOfInvalidTypeTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_dynamic() async {
     await assertNoErrorsInCode('''
 f(dynamic a) {
diff --git a/pkg/analyzer/test/src/diagnostics/type_alias_cannot_reference_itself_test.dart b/pkg/analyzer/test/src/diagnostics/type_alias_cannot_reference_itself_test.dart
index 176e1fc..a1993f5 100644
--- a/pkg/analyzer/test/src/diagnostics/type_alias_cannot_reference_itself_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/type_alias_cannot_reference_itself_test.dart
@@ -39,10 +39,9 @@
 
   test_infiniteParameterBoundCycle() async {
     await assertErrorsInCode(r'''
-typedef F<X extends F> = F Function();
+typedef F<X extends F<X>> = F Function();
 ''', [
-      error(CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, 0, 38),
-      error(StrongModeCode.NOT_INSTANTIATED_BOUND, 20, 1),
+      error(CompileTimeErrorCode.TYPE_ALIAS_CANNOT_REFERENCE_ITSELF, 0, 41),
     ]);
   }
 
diff --git a/pkg/analyzer/test/src/diagnostics/type_argument_not_matching_bounds_test.dart b/pkg/analyzer/test/src/diagnostics/type_argument_not_matching_bounds_test.dart
index 212c026..3d380ff 100644
--- a/pkg/analyzer/test/src/diagnostics/type_argument_not_matching_bounds_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/type_argument_not_matching_bounds_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart' show AnalysisOptionsImpl;
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -403,12 +402,7 @@
 
 @reflectiveTest
 class TypeArgumentNotMatchingBoundsWithNnbdTest
-    extends TypeArgumentNotMatchingBoundsTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends TypeArgumentNotMatchingBoundsTest with WithNullSafetyMixin {
   test_extends_optIn_fromOptOut_Null() async {
     newFile('/test/lib/a.dart', content: r'''
 class A<X extends int> {}
diff --git a/pkg/analyzer/test/src/diagnostics/type_parameter_referenced_by_static_test.dart b/pkg/analyzer/test/src/diagnostics/type_parameter_referenced_by_static_test.dart
index 2b54d51..7678cc3 100644
--- a/pkg/analyzer/test/src/diagnostics/type_parameter_referenced_by_static_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/type_parameter_referenced_by_static_test.dart
@@ -2,7 +2,6 @@
 // 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 'package:analyzer/src/dart/error/hint_codes.dart';
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -16,64 +15,7 @@
 
 @reflectiveTest
 class TypeParameterReferencedByStaticTest extends DriverResolutionTest {
-  test_field() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static K k;
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
-    ]);
-  }
-
-  test_getter() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static K get k => null;
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
-    ]);
-  }
-
-  test_methodBodyReference() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static m() {
-    K k;
-  }
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 32, 1),
-      error(HintCode.UNUSED_LOCAL_VARIABLE, 34, 1),
-    ]);
-  }
-
-  test_methodParameter() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static m(K k) {}
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 24, 1),
-    ]);
-  }
-
-  test_methodReturn() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static K m() { return null; }
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
-    ]);
-  }
-
-  test_setter() async {
-    await assertErrorsInCode('''
-class A<K> {
-  static set s(K k) {}
-}''', [
-      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 28, 1),
-    ]);
-  }
-
-  test_simpleIdentifier() async {
+  test_expression_method() async {
     await assertErrorsInCode('''
 class A<T> {
   static foo() {
@@ -84,4 +26,81 @@
       error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 34, 1),
     ]);
   }
+
+  test_type_field() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static T foo;
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
+    ]);
+  }
+
+  test_type_getter() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static T get foo => null;
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
+    ]);
+  }
+
+  test_type_method_bodyReference() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static foo() {
+    // ignore:unused_local_variable
+    T v;
+  }
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 70, 1),
+    ]);
+  }
+
+  test_type_method_closure() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static Object foo() {
+    return (T a) {};
+  }
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 49, 1),
+    ]);
+  }
+
+  test_type_method_parameter() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static foo(T a) {}
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 26, 1),
+    ]);
+  }
+
+  test_type_method_return() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static T foo() {
+    throw 0;
+  }
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 22, 1),
+    ]);
+  }
+
+  test_type_setter() async {
+    await assertErrorsInCode('''
+class A<T> {
+  static set foo(T _) {}
+}
+''', [
+      error(StaticWarningCode.TYPE_PARAMETER_REFERENCED_BY_STATIC, 30, 1),
+    ]);
+  }
 }
diff --git a/pkg/analyzer/test/src/diagnostics/type_parameter_supertype_of_its_bound_test.dart b/pkg/analyzer/test/src/diagnostics/type_parameter_supertype_of_its_bound_test.dart
new file mode 100644
index 0000000..bf4c60e
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/type_parameter_supertype_of_its_bound_test.dart
@@ -0,0 +1,55 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(TypeParameterSupertypeOfItsBoundTest);
+    defineReflectiveTests(TypeParameterSupertypeOfItsBoundWithNullSafetyTest);
+  });
+}
+
+@reflectiveTest
+class TypeParameterSupertypeOfItsBoundTest extends DriverResolutionTest {
+  test_1of1() async {
+    await assertErrorsInCode(r'''
+class A<T extends T> {
+}
+''', [
+      error(StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 8, 11),
+    ]);
+  }
+
+  test_1of1_used() async {
+    await assertErrorsInCode('''
+class A<T extends T> {
+  void foo(x) {
+    x is T;
+  }
+}
+''', [
+      error(StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 8, 11),
+    ]);
+  }
+
+  test_2of3() async {
+    await assertErrorsInCode(r'''
+class A<T1 extends T3, T2, T3 extends T1> {
+}
+''', [
+      error(StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 8, 13),
+      error(
+          StaticTypeWarningCode.TYPE_PARAMETER_SUPERTYPE_OF_ITS_BOUND, 27, 13),
+    ]);
+  }
+}
+
+@reflectiveTest
+class TypeParameterSupertypeOfItsBoundWithNullSafetyTest
+    extends TypeParameterSupertypeOfItsBoundTest with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/undefined_hidden_name_test.dart b/pkg/analyzer/test/src/diagnostics/undefined_hidden_name_test.dart
index 014866b..8de5d0b 100644
--- a/pkg/analyzer/test/src/diagnostics/undefined_hidden_name_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/undefined_hidden_name_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/undefined_identifier_test.dart b/pkg/analyzer/test/src/diagnostics/undefined_identifier_test.dart
index 20a5cd5..24e3567 100644
--- a/pkg/analyzer/test/src/diagnostics/undefined_identifier_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/undefined_identifier_test.dart
@@ -2,13 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:analyzer/src/generated/parser.dart' show ParserErrorCode;
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -177,9 +176,5 @@
 }
 
 @reflectiveTest
-class UndefinedIdentifierWithNnbdTest extends UndefinedIdentifierTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.6.0', additionalFeatures: [Feature.non_nullable]);
-}
+class UndefinedIdentifierWithNnbdTest extends UndefinedIdentifierTest
+    with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/diagnostics/undefined_shown_name_test.dart b/pkg/analyzer/test/src/diagnostics/undefined_shown_name_test.dart
index e671e33..0c57c5d 100644
--- a/pkg/analyzer/test/src/diagnostics/undefined_shown_name_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/undefined_shown_name_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/unnecessary_cast_test.dart b/pkg/analyzer/test/src/diagnostics/unnecessary_cast_test.dart
index 544a047..2ca0bb1 100644
--- a/pkg/analyzer/test/src/diagnostics/unnecessary_cast_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/unnecessary_cast_test.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/src/error/codes.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/unnecessary_non_null_assertion_test.dart b/pkg/analyzer/test/src/diagnostics/unnecessary_non_null_assertion_test.dart
index 112b3da..715f033 100644
--- a/pkg/analyzer/test/src/diagnostics/unnecessary_non_null_assertion_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/unnecessary_non_null_assertion_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -17,13 +15,8 @@
 }
 
 @reflectiveTest
-class UnnecessaryNonNullAssertionTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class UnnecessaryNonNullAssertionTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_legacy() async {
     newFile('/test/lib/a.dart', content: r'''
 // @dart = 2.5
diff --git a/pkg/analyzer/test/src/diagnostics/unnecessary_null_comparison_test.dart b/pkg/analyzer/test/src/diagnostics/unnecessary_null_comparison_test.dart
index bc58a11..a7b5d7c 100644
--- a/pkg/analyzer/test/src/diagnostics/unnecessary_null_comparison_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/unnecessary_null_comparison_test.dart
@@ -2,13 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -18,13 +16,8 @@
 }
 
 @reflectiveTest
-class UnnecessaryNullComparisonFalseTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class UnnecessaryNullComparisonFalseTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_equal_intLiteral() async {
     await assertNoErrorsInCode('''
 f(int a, int? b) {
@@ -85,13 +78,8 @@
 }
 
 @reflectiveTest
-class UnnecessaryNullComparisonTrueTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class UnnecessaryNullComparisonTrueTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_notEqual_intLiteral() async {
     await assertNoErrorsInCode('''
 f(int a, int? b) {
diff --git a/pkg/analyzer/test/src/diagnostics/unnecessary_type_check_test.dart b/pkg/analyzer/test/src/diagnostics/unnecessary_type_check_test.dart
index 0a21ca9..9403b54 100644
--- a/pkg/analyzer/test/src/diagnostics/unnecessary_type_check_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/unnecessary_type_check_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/dart/error/hint_codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -51,12 +50,7 @@
 
 @reflectiveTest
 class UnnecessaryTypeCheckFalseWithNnbdTest
-    extends UnnecessaryTypeCheckFalseTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+    extends UnnecessaryTypeCheckFalseTest with WithNullSafetyMixin {
   @override
   test_type_not_object() async {
     await assertNoErrorsInCode(r'''
@@ -109,13 +103,8 @@
 }
 
 @reflectiveTest
-class UnnecessaryTypeCheckTrueWithNnbdTest
-    extends UnnecessaryTypeCheckTrueTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.3.0', additionalFeatures: [Feature.non_nullable]);
-
+class UnnecessaryTypeCheckTrueWithNnbdTest extends UnnecessaryTypeCheckTrueTest
+    with WithNullSafetyMixin {
   @override
   test_type_is_object() async {
     await assertNoErrorsInCode(r'''
diff --git a/pkg/analyzer/test/src/diagnostics/unqualified_reference_to_non_local_static_member_test.dart b/pkg/analyzer/test/src/diagnostics/unqualified_reference_to_non_local_static_member_test.dart
new file mode 100644
index 0000000..52ed3ad
--- /dev/null
+++ b/pkg/analyzer/test/src/diagnostics/unqualified_reference_to_non_local_static_member_test.dart
@@ -0,0 +1,76 @@
+// 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 'package:analyzer/src/error/codes.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
+
+import '../dart/resolution/driver_resolution.dart';
+
+main() {
+  defineReflectiveSuite(() {
+    defineReflectiveTests(UnqualifiedReferenceToNonLocalStaticMemberTest);
+  });
+}
+
+@reflectiveTest
+class UnqualifiedReferenceToNonLocalStaticMemberTest
+    extends DriverResolutionTest {
+  test_getter() async {
+    await assertErrorsInCode(r'''
+class A {
+  static int get a => 0;
+}
+class B extends A {
+  int b() {
+    return a;
+  }
+}
+''', [
+      error(
+          StaticTypeWarningCode
+              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
+          80,
+          1),
+    ]);
+  }
+
+  test_getter_invokeTarget() async {
+    await assertErrorsInCode(r'''
+class A {
+  static int foo;
+}
+
+class B extends A {
+  static bar() {
+    foo.abs();
+  }
+}
+''', [
+      error(
+          StaticTypeWarningCode
+              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
+          72,
+          3),
+    ]);
+  }
+
+  test_setter() async {
+    await assertErrorsInCode(r'''
+class A {
+  static set a(x) {}
+}
+class B extends A {
+  b(y) {
+    a = y;
+  }
+}
+''', [
+      error(
+          StaticTypeWarningCode
+              .UNQUALIFIED_REFERENCE_TO_NON_LOCAL_STATIC_MEMBER,
+          66,
+          1),
+    ]);
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/unused_element_test.dart b/pkg/analyzer/test/src/diagnostics/unused_element_test.dart
index 7756ea0..bf0abe7 100644
--- a/pkg/analyzer/test/src/diagnostics/unused_element_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/unused_element_test.dart
@@ -6,10 +6,12 @@
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
     defineReflectiveTests(UnusedElementTest);
+    defineReflectiveTests(UnusedElementWithNnbdTest);
   });
 }
 
@@ -108,6 +110,7 @@
 }
 ''', [
       error(HintCode.UNUSED_ELEMENT, 6, 2),
+      error(HintCode.UNUSED_ELEMENT, 26, 5),
     ]);
   }
 
@@ -937,6 +940,267 @@
     ]);
   }
 
+  test_optionalParameter_constructor_named_notUsed() async {
+    await assertErrorsInCode(r'''
+class A {
+  A._([int a]);
+}
+f() => A._();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 21, 1),
+    ]);
+  }
+
+  test_optionalParameter_constructor_unnamed_notUsed() async {
+    await assertErrorsInCode(r'''
+class _A {
+  _A([int a]);
+}
+f() => _A();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 21, 1),
+    ]);
+  }
+
+  test_optionalParameter_isUsed_functionTearoff() async {
+    await assertNoErrorsInCode(r'''
+f() {
+  void _m([int a]) {}
+  _m;
+}
+''');
+  }
+
+  test_optionalParameter_isUsed_local() async {
+    await assertNoErrorsInCode(r'''
+f() {
+  void _m([int a]) {}
+  _m(1);
+}
+''');
+  }
+
+  test_optionalParameter_isUsed_methodTearoff() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+f() => A()._m;
+''');
+  }
+
+  test_optionalParameter_isUsed_named() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m({int a = 0}) {}
+}
+f() => A()._m(a: 0);
+''');
+  }
+
+  test_optionalParameter_isUsed_overridden() async {
+    await assertErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+class B implements A {
+  void _m([int a]) {}
+}
+f() {
+  A()._m();
+  B()._m(0);
+}
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 25, 1),
+    ]);
+  }
+
+  test_optionalParameter_isUsed_override() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+class B implements A {
+  void _m([int a]) {}
+}
+f() => A()._m(0);
+''');
+  }
+
+  test_optionalParameter_isUsed_override_renamed() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+class B implements A {
+  void _m([int b]) {}
+}
+f() => A()._m(0);
+''');
+  }
+
+  test_optionalParameter_isUsed_overrideRequired() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m(int a) {}
+}
+class B implements A {
+  void _m([int a]) {}
+}
+f() => A()._m(0);
+''');
+  }
+
+  test_optionalParameter_isUsed_positional() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+f() => A()._m(0);
+''');
+  }
+
+  test_optionalParameter_isUsed_publicMethod() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void m([int a]) {}
+}
+f() => A().m();
+''');
+  }
+
+  test_optionalParameter_isUsed_publicMethod_extension() async {
+    await assertNoErrorsInCode(r'''
+extension E on String {
+  void m([int a]) {}
+}
+f() => "hello".m();
+''');
+  }
+
+  test_optionalParameter_isUsed_requiredPositional() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m(int a) {}
+}
+f() => A()._m(0);
+''');
+  }
+
+  test_optionalParameter_notUsed_extension() async {
+    await assertErrorsInCode(r'''
+extension E on String {
+  void _m([int a]) {}
+}
+f() => "hello"._m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 39, 1),
+    ]);
+  }
+
+  test_optionalParameter_notUsed_named() async {
+    await assertErrorsInCode(r'''
+class A {
+  void _m({int a}) {}
+}
+f() => A()._m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 25, 1),
+    ]);
+  }
+
+  test_optionalParameter_notUsed_override_added() async {
+    await assertErrorsInCode(r'''
+class A {
+  void _m() {}
+}
+class B implements A {
+  void _m([int a]) {}
+}
+f() => A()._m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 65, 1),
+    ]);
+  }
+
+  test_optionalParameter_notUsed_positional() async {
+    await assertErrorsInCode(r'''
+class A {
+  void _m([int a]) {}
+}
+f() => A()._m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 25, 1),
+    ]);
+  }
+
+  test_optionalParameter_notUsed_publicMethod_privateExtension() async {
+    await assertErrorsInCode(r'''
+extension _E on String {
+  void m([int a]) {}
+}
+f() => "hello".m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 39, 1),
+    ]);
+  }
+
+  test_optionalParameter_notUsed_publicMethod_unnamedExtension() async {
+    await assertErrorsInCode(r'''
+extension on String {
+  void m([int a]) {}
+}
+f() => "hello".m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 36, 1),
+    ]);
+  }
+
+  test_optionalParameter_static_notUsed() async {
+    await assertErrorsInCode(r'''
+class A {
+  static void _m([int a]) {}
+}
+f() => A._m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 32, 1),
+    ]);
+  }
+
+  test_optionalParameter_staticPublic_notUsed_privateClass() async {
+    await assertErrorsInCode(r'''
+class _A {
+  static void m([int a]) {}
+}
+f() => _A.m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 32, 1),
+    ]);
+  }
+
+  test_optionalParameter_topLevel_isUsed() async {
+    await assertNoErrorsInCode(r'''
+void _m([int a]) {}
+f() => _m(1);
+''');
+  }
+
+  test_optionalParameter_topLevel_notUsed() async {
+    await assertErrorsInCode(r'''
+void _m([int a]) {}
+f() => _m();
+''', [
+      error(HintCode.UNUSED_ELEMENT_PARAMETER, 13, 1),
+    ]);
+  }
+
+  test_optionalParameter_topLevelPublic_isUsed() async {
+    await assertNoErrorsInCode(r'''
+void m([int a]) {}
+f() => m();
+''');
+  }
+
   test_publicStaticMethod_privateClass_isUsed() async {
     await assertNoErrorsInCode(r'''
 class _A {
@@ -1067,6 +1331,16 @@
     ]);
   }
 
+  test_topLevelAccessors_isUsed_questionQuestionEqual() async {
+    await assertNoErrorsInCode(r'''
+int get _c => 1;
+void set _c(int x) {}
+int f() {
+  return _c ??= 7;
+}
+''');
+  }
+
   test_topLevelVariable_isUsed() async {
     await assertNoErrorsInCode(r'''
 int _a = 1;
@@ -1086,6 +1360,15 @@
 ''');
   }
 
+  test_topLevelVariable_isUsed_questionQuestionEqual() async {
+    await assertNoErrorsInCode(r'''
+int _a;
+f() {
+  _a ??= 1;
+}
+''');
+  }
+
   test_topLevelVariable_notUsed() async {
     await assertErrorsInCode(r'''
 int _a = 1;
@@ -1097,6 +1380,17 @@
     ]);
   }
 
+  test_topLevelVariable_notUsed_compoundAssign() async {
+    await assertErrorsInCode(r'''
+int _a = 1;
+f() {
+  _a += 1;
+}
+''', [
+      error(HintCode.UNUSED_ELEMENT, 4, 2),
+    ]);
+  }
+
   test_topLevelVariable_notUsed_referenceInComment() async {
     await assertErrorsInCode(r'''
 /// [_a] is a great variable.
@@ -1106,3 +1400,19 @@
     ]);
   }
 }
+
+@reflectiveTest
+class UnusedElementWithNnbdTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
+  test_optionalParameter_isUsed_overrideRequiredNamed() async {
+    await assertNoErrorsInCode(r'''
+class A {
+  void _m({required int a}) {}
+}
+class B implements A {
+  void _m({int a = 0}) {}
+}
+f() => A()._m(a: 0);
+''');
+  }
+}
diff --git a/pkg/analyzer/test/src/diagnostics/use_of_nullable_value_test.dart b/pkg/analyzer/test/src/diagnostics/use_of_nullable_value_test.dart
index 4cc8770..66842d8 100644
--- a/pkg/analyzer/test/src/diagnostics/use_of_nullable_value_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/use_of_nullable_value_test.dart
@@ -2,14 +2,12 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
-import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -20,13 +18,8 @@
 }
 
 @reflectiveTest
-class InvalidUseOfNullValueTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
+class InvalidUseOfNullValueTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_as() async {
     await assertNoErrorsInCode(r'''
 m() {
@@ -132,16 +125,7 @@
 
 @reflectiveTest
 class UncheckedUseOfNullableValueInsideExtensionTest
-    extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+    extends DriverResolutionTest with WithNullSafetyMixin {
   test_indexExpression_nonNullable() async {
     await assertNoErrorsInCode(r'''
 class A {
@@ -171,15 +155,15 @@
 extension E on A? {
   void bar() {
     this[0];
-    this?.[0];
+    this?[0];
 
     this[0] = 0;
-    this?.[0] = 0;
+    this?[0] = 0;
   }
 }
 ''', [
       error(StaticWarningCode.UNCHECKED_USE_OF_NULLABLE_VALUE, 126, 4),
-      error(StaticWarningCode.UNCHECKED_USE_OF_NULLABLE_VALUE, 155, 4),
+      error(StaticWarningCode.UNCHECKED_USE_OF_NULLABLE_VALUE, 154, 4),
     ]);
   }
 
@@ -346,16 +330,8 @@
 }
 
 @reflectiveTest
-class UncheckedUseOfNullableValueTest extends DriverResolutionTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.fromEnableFlags(
-      [EnableString.non_nullable],
-    );
-
-  @override
-  bool get typeToStringWithNullability => true;
-
+class UncheckedUseOfNullableValueTest extends DriverResolutionTest
+    with WithNullSafetyMixin {
   test_and_nonNullable() async {
     await assertNoErrorsInCode(r'''
 m() {
diff --git a/pkg/analyzer/test/src/diagnostics/use_of_void_result_test.dart b/pkg/analyzer/test/src/diagnostics/use_of_void_result_test.dart
index d702f89..805c65a 100644
--- a/pkg/analyzer/test/src/diagnostics/use_of_void_result_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/use_of_void_result_test.dart
@@ -6,8 +6,8 @@
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../../generated/test_support.dart';
-import '../dart/constant/potentially_constant_test.dart';
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
diff --git a/pkg/analyzer/test/src/diagnostics/yield_of_invalid_type_test.dart b/pkg/analyzer/test/src/diagnostics/yield_of_invalid_type_test.dart
index 8963c73..ba8cc06 100644
--- a/pkg/analyzer/test/src/diagnostics/yield_of_invalid_type_test.dart
+++ b/pkg/analyzer/test/src/diagnostics/yield_of_invalid_type_test.dart
@@ -2,12 +2,11 @@
 // 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 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/src/error/codes.dart';
-import 'package:analyzer/src/generated/engine.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import '../dart/resolution/driver_resolution.dart';
+import '../dart/resolution/with_null_safety_mixin.dart';
 
 main() {
   defineReflectiveSuite(() {
@@ -39,7 +38,7 @@
   yield 0;
 }
 ''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 3),
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 3),
       error(StaticTypeWarningCode.YIELD_OF_INVALID_TYPE, 25, 1),
     ]);
   }
@@ -58,7 +57,7 @@
   yield 0;
 }
 ''', [
-      error(StaticTypeWarningCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 13),
+      error(CompileTimeErrorCode.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE, 0, 13),
       error(StaticTypeWarningCode.YIELD_OF_INVALID_TYPE, 35, 1),
     ]);
   }
@@ -122,7 +121,7 @@
   yield 0;
 }
 ''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 0, 3),
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 0, 3),
       error(StaticTypeWarningCode.YIELD_OF_INVALID_TYPE, 24, 1),
     ]);
   }
@@ -169,7 +168,7 @@
   yield 0;
 }
 ''', [
-      error(StaticTypeWarningCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 22, 11),
+      error(CompileTimeErrorCode.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE, 22, 11),
       error(StaticTypeWarningCode.YIELD_OF_INVALID_TYPE, 54, 1),
     ]);
   }
@@ -440,12 +439,5 @@
 }
 
 @reflectiveTest
-class YieldOfInvalidTypeTest2 extends YieldOfInvalidTypeTest {
-  @override
-  AnalysisOptionsImpl get analysisOptions => AnalysisOptionsImpl()
-    ..contextFeatures = FeatureSet.forTesting(
-        sdkVersion: '2.7.0', additionalFeatures: [Feature.non_nullable]);
-
-  @override
-  bool get typeToStringWithNullability => true;
-}
+class YieldOfInvalidTypeTest2 extends YieldOfInvalidTypeTest
+    with WithNullSafetyMixin {}
diff --git a/pkg/analyzer/test/src/services/available_declarations_test.dart b/pkg/analyzer/test/src/services/available_declarations_test.dart
index f179e21..e21ccd8 100644
--- a/pkg/analyzer/test/src/services/available_declarations_test.dart
+++ b/pkg/analyzer/test/src/services/available_declarations_test.dart
@@ -500,7 +500,7 @@
       ),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
 
     newFile(filePath, content: 'class B {}');
@@ -515,7 +515,7 @@
       ),
       'B',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::B'],
     );
   }
 
@@ -550,7 +550,7 @@
       ),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:aaa/a.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:aaa/a.dart::A'],
     );
 
     newFile(filePath, content: 'class B {}');
@@ -565,7 +565,7 @@
       ),
       'B',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:aaa/a.dart::B'],
+      relevanceTags: ['ElementKind.CLASS', 'package:aaa/a.dart::B'],
     );
   }
 
@@ -587,7 +587,7 @@
       ),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['dart:math::A'],
+      relevanceTags: ['ElementKind.CLASS', 'dart:math::A'],
     );
 
     newFile(filePath, content: 'class B {}');
@@ -602,7 +602,7 @@
       ),
       'B',
       DeclarationKind.CLASS,
-      relevanceTags: ['dart:math::B'],
+      relevanceTags: ['ElementKind.CLASS', 'dart:math::B'],
     );
   }
 
@@ -1129,21 +1129,21 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
       'B',
       DeclarationKind.CLASS,
       isAbstract: true,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::B'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'C'),
       'C',
       DeclarationKind.CLASS,
       isDeprecated: true,
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::C'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'D'),
@@ -1151,7 +1151,7 @@
       DeclarationKind.CLASS,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb\nccc ccc',
-      relevanceTags: ['package:test/test.dart::D'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::D'],
     );
   }
 
@@ -1192,7 +1192,7 @@
       'f1',
       DeclarationKind.FIELD,
       isStatic: true,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1201,7 +1201,7 @@
       DeclarationKind.FIELD,
       isFinal: true,
       isStatic: true,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1210,14 +1210,18 @@
       DeclarationKind.FIELD,
       isConst: true,
       isStatic: true,
-      relevanceTags: ['dart:core::int', 'isConst'],
+      relevanceTags: [
+        'ElementKind.FIELD',
+        'ElementKind.FIELD+const',
+        'dart:core::int',
+      ],
       returnType: 'int',
     );
     _assertDeclaration(
       _getDeclaration(classDeclaration.children, 'f4'),
       'f4',
       DeclarationKind.FIELD,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1225,7 +1229,7 @@
       'f5',
       DeclarationKind.FIELD,
       isFinal: true,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1233,7 +1237,7 @@
       'f6',
       DeclarationKind.FIELD,
       isDeprecated: true,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1242,7 +1246,7 @@
       DeclarationKind.FIELD,
       isDeprecated: true,
       isFinal: true,
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1251,7 +1255,7 @@
       DeclarationKind.FIELD,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
-      relevanceTags: ['dart:core::int'],
+      relevanceTags: ['ElementKind.FIELD', 'dart:core::int'],
       returnType: 'int',
     );
   }
@@ -1284,12 +1288,14 @@
       'g1',
       DeclarationKind.GETTER,
       isStatic: true,
+      relevanceTags: ['ElementKind.FIELD'],
       returnType: 'int',
     );
     _assertDeclaration(
       _getDeclaration(classDeclaration.children, 'g2'),
       'g2',
       DeclarationKind.GETTER,
+      relevanceTags: ['ElementKind.FIELD'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1297,6 +1303,7 @@
       'g3',
       DeclarationKind.GETTER,
       isDeprecated: true,
+      relevanceTags: ['ElementKind.FIELD'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -1305,6 +1312,7 @@
       DeclarationKind.GETTER,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
+      relevanceTags: ['ElementKind.FIELD'],
       returnType: 'int',
     );
   }
@@ -1342,6 +1350,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.METHOD'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1352,6 +1361,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.METHOD'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1364,6 +1374,7 @@
       parameters: '(int a)',
       parameterNames: ['a'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.METHOD'],
       requiredParameterCount: 1,
       returnType: 'void',
     );
@@ -1375,6 +1386,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.METHOD'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1387,6 +1399,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.METHOD'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1423,6 +1436,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FIELD'],
       requiredParameterCount: 1,
     );
     _assertDeclaration(
@@ -1432,6 +1446,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FIELD'],
       requiredParameterCount: 1,
     );
     _assertDeclaration(
@@ -1442,6 +1457,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FIELD'],
       requiredParameterCount: 1,
     );
     _assertDeclaration(
@@ -1453,6 +1469,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FIELD'],
       requiredParameterCount: 1,
     );
   }
@@ -1480,14 +1497,14 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.CLASS_TYPE_ALIAS,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
       'B',
       DeclarationKind.CLASS_TYPE_ALIAS,
       isDeprecated: true,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::B'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'C'),
@@ -1495,7 +1512,7 @@
       DeclarationKind.CLASS_TYPE_ALIAS,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::C'],
     );
   }
 
@@ -1536,7 +1553,7 @@
       parameterNames: [],
       parameters: '()',
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 0,
       returnType: 'C',
     );
@@ -1547,7 +1564,7 @@
       parameterNames: [],
       parameters: '()',
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 0,
       returnType: 'C',
     );
@@ -1559,7 +1576,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 0,
       returnType: 'C',
     );
@@ -1572,7 +1589,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 0,
       returnType: 'C',
     );
@@ -1585,7 +1602,7 @@
       parameters: '(Map<String, int> p1, int p2, {double p3})',
       parameterNames: ['p1', 'p2', 'p3'],
       parameterTypes: ['Map<String, int>', 'int', 'double'],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 2,
       returnType: 'C',
     );
@@ -1598,7 +1615,7 @@
       parameters: '(this.f1, this.f2)',
       parameterNames: ['f1', 'f2'],
       parameterTypes: ['', ''],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.CONSTRUCTOR', 'package:test/test.dart::C'],
       requiredParameterCount: 2,
       returnType: 'C',
     );
@@ -1625,14 +1642,14 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.ENUM,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.ENUM', 'package:test/test.dart::A'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
       'B',
       DeclarationKind.ENUM,
       isDeprecated: true,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.ENUM', 'package:test/test.dart::B'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'C'),
@@ -1640,7 +1657,7 @@
       DeclarationKind.ENUM,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.ENUM', 'package:test/test.dart::C'],
     );
   }
 
@@ -1669,14 +1686,22 @@
       _getDeclaration(enumDeclaration.children, 'a'),
       'a',
       DeclarationKind.ENUM_CONSTANT,
-      relevanceTags: ['package:test/test.dart::MyEnum'],
+      relevanceTags: [
+        'ElementKind.ENUM_CONSTANT',
+        'ElementKind.ENUM_CONSTANT+const',
+        'package:test/test.dart::MyEnum'
+      ],
     );
     _assertDeclaration(
       _getDeclaration(enumDeclaration.children, 'b'),
       'b',
       DeclarationKind.ENUM_CONSTANT,
       isDeprecated: true,
-      relevanceTags: ['package:test/test.dart::MyEnum'],
+      relevanceTags: [
+        'ElementKind.ENUM_CONSTANT',
+        'ElementKind.ENUM_CONSTANT+const',
+        'package:test/test.dart::MyEnum'
+      ],
     );
     _assertDeclaration(
       _getDeclaration(enumDeclaration.children, 'c'),
@@ -1684,7 +1709,11 @@
       DeclarationKind.ENUM_CONSTANT,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
-      relevanceTags: ['package:test/test.dart::MyEnum'],
+      relevanceTags: [
+        'ElementKind.ENUM_CONSTANT',
+        'ElementKind.ENUM_CONSTANT+const',
+        'package:test/test.dart::MyEnum'
+      ],
     );
   }
 
@@ -1713,12 +1742,14 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.EXTENSION,
+      relevanceTags: ['ElementKind.EXTENSION'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
       'B',
       DeclarationKind.EXTENSION,
       isDeprecated: true,
+      relevanceTags: ['ElementKind.EXTENSION'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'C'),
@@ -1726,6 +1757,7 @@
       DeclarationKind.EXTENSION,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb\nccc ccc',
+      relevanceTags: ['ElementKind.EXTENSION'],
     );
   }
 
@@ -1757,6 +1789,7 @@
       parameterNames: [],
       parameters: '()',
       parameterTypes: [],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1768,6 +1801,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1780,6 +1814,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1792,6 +1827,7 @@
       parameters: '(Map<String, int> p1, int p2, {double p3})',
       parameterNames: ['p1', 'p2', 'p3'],
       parameterTypes: ['Map<String, int>', 'int', 'double'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 2,
       returnType: 'List<String>',
     );
@@ -1802,6 +1838,7 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 0,
       returnType: 'void',
       typeParameters: '<T extends num, U>',
@@ -1830,6 +1867,7 @@
       parameterNames: [],
       parameters: '()',
       parameterTypes: [],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1842,6 +1880,7 @@
       parameters: '(int a, double bb, String ccc)',
       parameterNames: ['a', 'bb', 'ccc'],
       parameterTypes: ['int', 'double', 'String'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 3,
       returnType: 'void',
     );
@@ -1854,6 +1893,7 @@
       parameters: '(int a, [double b, String c])',
       parameterNames: ['a', 'b', 'c'],
       parameterTypes: ['int', 'double', 'String'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 1,
       returnType: 'void',
     );
@@ -1866,6 +1906,7 @@
       parameters: '(int a, {int b, @required int c, @required int d, int e})',
       parameterNames: ['a', 'b', 'c', 'd', 'e'],
       parameterTypes: ['int', 'int', 'int', 'int', 'int'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 1,
       returnType: 'void',
     );
@@ -1901,7 +1942,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::A'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1913,7 +1957,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::B'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1926,7 +1973,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::C'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -1937,7 +1987,10 @@
       parameters: '(int p1, [double p2, String p3])',
       parameterNames: ['p1', 'p2', 'p3'],
       parameterTypes: ['int', 'double', 'String'],
-      relevanceTags: ['package:test/test.dart::D'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::D'
+      ],
       requiredParameterCount: 1,
       returnType: 'int',
     );
@@ -1948,7 +2001,10 @@
       parameters: '(int, double, {String p3})',
       parameterNames: ['', '', 'p3'],
       parameterTypes: ['int', 'double', 'String'],
-      relevanceTags: ['package:test/test.dart::E'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::E'
+      ],
       requiredParameterCount: 2,
       returnType: 'void',
     );
@@ -1960,7 +2016,10 @@
       parameterNames: [],
       parameterTypes: [],
       requiredParameterCount: 0,
-      relevanceTags: ['package:test/test.dart::F'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::F'
+      ],
       returnType: 'void',
       typeParameters: '<T extends num, U>',
     );
@@ -2008,7 +2067,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::A'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -2020,7 +2082,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::B'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -2033,7 +2098,10 @@
       parameters: '()',
       parameterNames: [],
       parameterTypes: [],
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::C'
+      ],
       requiredParameterCount: 0,
       returnType: 'void',
     );
@@ -2044,7 +2112,10 @@
       parameters: '(int p1, [double p2, String p3])',
       parameterNames: ['p1', 'p2', 'p3'],
       parameterTypes: ['int', 'double', 'String'],
-      relevanceTags: ['package:test/test.dart::D'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::D'
+      ],
       requiredParameterCount: 1,
       returnType: 'int',
     );
@@ -2055,7 +2126,10 @@
       parameters: '(int p1, double p2, {String p3})',
       parameterNames: ['p1', 'p2', 'p3'],
       parameterTypes: ['int', 'double', 'String'],
-      relevanceTags: ['package:test/test.dart::E'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::E'
+      ],
       requiredParameterCount: 2,
       returnType: 'void',
     );
@@ -2067,7 +2141,10 @@
       parameterNames: [],
       parameterTypes: [],
       requiredParameterCount: 0,
-      relevanceTags: ['package:test/test.dart::F'],
+      relevanceTags: [
+        'ElementKind.FUNCTION_TYPE_ALIAS',
+        'package:test/test.dart::F'
+      ],
       returnType: 'void',
       typeParameters: '<T extends num, U>',
     );
@@ -2094,6 +2171,7 @@
       _getDeclaration(library.declarations, 'a'),
       'a',
       DeclarationKind.GETTER,
+      relevanceTags: ['ElementKind.FUNCTION'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -2101,6 +2179,7 @@
       'b',
       DeclarationKind.GETTER,
       isDeprecated: true,
+      relevanceTags: ['ElementKind.FUNCTION'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -2109,6 +2188,7 @@
       DeclarationKind.GETTER,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
+      relevanceTags: ['ElementKind.FUNCTION'],
       returnType: 'int',
     );
   }
@@ -2147,7 +2227,7 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
   }
 
@@ -2166,7 +2246,7 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.CLASS,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
   }
 
@@ -2268,7 +2348,7 @@
       locationPath: testPath,
       locationStartColumn: 7,
       locationStartLine: 1,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::A'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
@@ -2278,7 +2358,7 @@
       locationPath: testPath,
       locationStartColumn: 7,
       locationStartLine: 3,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.CLASS', 'package:test/test.dart::B'],
     );
   }
 
@@ -2304,14 +2384,14 @@
       _getDeclaration(library.declarations, 'A'),
       'A',
       DeclarationKind.MIXIN,
-      relevanceTags: ['package:test/test.dart::A'],
+      relevanceTags: ['ElementKind.MIXIN', 'package:test/test.dart::A'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'B'),
       'B',
       DeclarationKind.MIXIN,
       isDeprecated: true,
-      relevanceTags: ['package:test/test.dart::B'],
+      relevanceTags: ['ElementKind.MIXIN', 'package:test/test.dart::B'],
     );
     _assertDeclaration(
       _getDeclaration(library.declarations, 'C'),
@@ -2319,7 +2399,7 @@
       DeclarationKind.MIXIN,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb\nccc ccc',
-      relevanceTags: ['package:test/test.dart::C'],
+      relevanceTags: ['ElementKind.MIXIN', 'package:test/test.dart::C'],
     );
   }
 
@@ -2347,6 +2427,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 1,
     );
     _assertDeclaration(
@@ -2357,6 +2438,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 1,
     );
     _assertDeclaration(
@@ -2368,6 +2450,7 @@
       parameters: '(int value)',
       parameterNames: ['value'],
       parameterTypes: ['int'],
+      relevanceTags: ['ElementKind.FUNCTION'],
       requiredParameterCount: 1,
     );
   }
@@ -2397,6 +2480,7 @@
       _getDeclaration(library.declarations, 'a'),
       'a',
       DeclarationKind.VARIABLE,
+      relevanceTags: ['ElementKind.TOP_LEVEL_VARIABLE'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -2404,6 +2488,7 @@
       'b',
       DeclarationKind.VARIABLE,
       isDeprecated: true,
+      relevanceTags: ['ElementKind.TOP_LEVEL_VARIABLE'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -2412,6 +2497,7 @@
       DeclarationKind.VARIABLE,
       docSummary: 'aaa',
       docComplete: 'aaa\n\nbbb bbb',
+      relevanceTags: ['ElementKind.TOP_LEVEL_VARIABLE'],
       returnType: 'int',
     );
     _assertDeclaration(
@@ -2419,7 +2505,11 @@
       'd',
       DeclarationKind.VARIABLE,
       isConst: true,
-      relevanceTags: ['dart:core::int', 'isConst'],
+      relevanceTags: [
+        'ElementKind.TOP_LEVEL_VARIABLE',
+        'ElementKind.TOP_LEVEL_VARIABLE+const',
+        'dart:core::int',
+      ],
       returnType: '',
     );
     _assertDeclaration(
@@ -2427,7 +2517,7 @@
       'e',
       DeclarationKind.VARIABLE,
       isFinal: true,
-      relevanceTags: ['dart:core::double'],
+      relevanceTags: ['ElementKind.TOP_LEVEL_VARIABLE', 'dart:core::double'],
       returnType: 'double',
     );
   }
@@ -2435,6 +2525,20 @@
 
 @reflectiveTest
 class ExportTest extends _Base {
+  test_classTypeAlias() async {
+    newFile('/home/test/lib/test.dart', content: r'''
+mixin M {}
+class A = Object with M;
+''');
+    tracker.addContext(testAnalysisContext);
+
+    await _doAllTrackerWork();
+    _assertHasLibrary('package:test/test.dart', declarations: [
+      _ExpectedDeclaration.mixin('M'),
+      _ExpectedDeclaration.classTypeAlias('A'),
+    ]);
+  }
+
   test_combinators_hide() async {
     newFile('/home/test/lib/a.dart', content: r'''
 class A {}
@@ -2570,6 +2674,32 @@
     ]);
   }
 
+  test_function() async {
+    newFile('/home/test/lib/test.dart', content: r'''
+int foo() => 0;
+int bar() => 0;
+''');
+    tracker.addContext(testAnalysisContext);
+
+    await _doAllTrackerWork();
+    _assertHasLibrary('package:test/test.dart', declarations: [
+      _ExpectedDeclaration.function('foo'),
+      _ExpectedDeclaration.function('bar'),
+    ]);
+  }
+
+  test_functionTypeAlias() async {
+    newFile('/home/test/lib/test.dart', content: r'''
+typedef F = int Function();
+''');
+    tracker.addContext(testAnalysisContext);
+
+    await _doAllTrackerWork();
+    _assertHasLibrary('package:test/test.dart', declarations: [
+      _ExpectedDeclaration.functionTypeAlias('F'),
+    ]);
+  }
+
   test_missing() async {
     newFile('/home/test/lib/test.dart', content: r'''
 export 'a.dart';
@@ -2674,6 +2804,18 @@
       ]),
     ]);
   }
+
+  test_variable() async {
+    newFile('/home/test/lib/test.dart', content: r'''
+int foo = 0;
+''');
+    tracker.addContext(testAnalysisContext);
+
+    await _doAllTrackerWork();
+    _assertHasLibrary('package:test/test.dart', declarations: [
+      _ExpectedDeclaration.variable('foo'),
+    ]);
+  }
 }
 
 @reflectiveTest
diff --git a/pkg/analyzer/test/src/summary/resynthesize_ast2_test.dart b/pkg/analyzer/test/src/summary/resynthesize_ast2_test.dart
index 5e594b8..34bf484 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_ast2_test.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_ast2_test.dart
@@ -4,6 +4,7 @@
 
 import 'package:analyzer/dart/analysis/features.dart';
 import 'package:analyzer/dart/ast/ast.dart';
+import 'package:analyzer/dart/element/null_safety_understanding_flag.dart';
 import 'package:analyzer/src/context/context.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
 import 'package:analyzer/src/dart/element/class_hierarchy.dart';
@@ -108,9 +109,13 @@
       LinkedBundleContext(elementFactory, sdkBundle),
     );
 
-    var linkResult = link(
-      elementFactory,
-      inputLibraries,
+    var linkResult = NullSafetyUnderstandingFlag.enableNullSafetyTypes(
+      () {
+        return link(
+          elementFactory,
+          inputLibraries,
+        );
+      },
     );
 
     elementFactory.addBundle(
diff --git a/pkg/analyzer/test/src/summary/resynthesize_common.dart b/pkg/analyzer/test/src/summary/resynthesize_common.dart
index 0380e45..ce8cd1c 100644
--- a/pkg/analyzer/test/src/summary/resynthesize_common.dart
+++ b/pkg/analyzer/test/src/summary/resynthesize_common.dart
@@ -16,6 +16,7 @@
 import 'package:analyzer/src/test_utilities/mock_sdk.dart';
 import 'package:analyzer/src/test_utilities/resource_provider_mixin.dart';
 import 'package:test/test.dart';
+import 'package:test_reflective_loader/test_reflective_loader.dart';
 
 import 'element_text.dart';
 import 'test_strategies.dart';
@@ -1684,6 +1685,30 @@
 ''');
   }
 
+  test_class_type_parameters_cycle_1of1() async {
+    var library = await checkLibrary('class C<T extends T> {}');
+    checkElementText(
+        library,
+        r'''
+notSimplyBounded class C<T extends dynamic> {
+}
+''',
+        withTypes: true);
+  }
+
+  test_class_type_parameters_cycle_2of3() async {
+    var library = await checkLibrary(r'''
+class C<T extends V, U, V extends T> {}
+''');
+    checkElementText(
+        library,
+        r'''
+notSimplyBounded class C<T extends dynamic, U, V extends dynamic> {
+}
+''',
+        withTypes: true);
+  }
+
   test_class_type_parameters_f_bound_complex() async {
     var library = await checkLibrary('class C<T extends List<U>, U> {}');
     checkElementText(library, r'''
@@ -9348,6 +9373,93 @@
 ''');
   }
 
+  test_mixin_inference_legacy() async {
+    var library = await checkLibrary(r'''
+class A<T> {}
+mixin M<U> on A<U> {}
+class B extends A<int> with M {}
+''');
+    checkElementText(
+        library,
+        r'''
+class A<T> {
+}
+class B extends A<int*>* with M<int*>* {
+  synthetic B();
+}
+mixin M<U> on A<U*>* {
+}
+''',
+        annotateNullability: true);
+  }
+
+  test_mixin_inference_nullSafety() async {
+    featureSet = enableNnbd;
+    var library = await checkLibrary(r'''
+class A<T> {}
+mixin M<U> on A<U> {}
+class B extends A<int> with M {}
+''');
+    checkElementText(
+        library,
+        r'''
+class A<T> {
+}
+class B extends A<int> with M<int> {
+  synthetic B();
+}
+mixin M<U> on A<U> {
+}
+''',
+        annotateNullability: true);
+  }
+
+  test_mixin_inference_nullSafety_mixed_inOrder() async {
+    featureSet = enableNnbd;
+    addLibrarySource('/a.dart', r'''
+class A<T> {}
+mixin M<U> on A<U> {}
+''');
+    var library = await checkLibrary(r'''
+// @dart = 2.8
+import 'a.dart';
+class B extends A<int> with M {}
+''');
+    checkElementText(
+        library,
+        r'''
+import 'a.dart';
+class B extends A<int*>* with M<int*>* {
+  synthetic B();
+}
+''',
+        annotateNullability: true);
+  }
+
+  @FailingTest(reason: 'Out-of-order inference is not specified yet')
+  test_mixin_inference_nullSafety_mixed_outOfOrder() async {
+    featureSet = enableNnbd;
+    addLibrarySource('/a.dart', r'''
+// @dart = 2.8
+class A<T> {}
+mixin M<U> on A<U> {}
+''');
+    var library = await checkLibrary(r'''
+import 'a.dart';
+
+class B extends A<int> with M {}
+''');
+    checkElementText(
+        library,
+        r'''
+import 'a.dart';
+class B extends A<int> with M<int> {
+  synthetic B();
+}
+''',
+        annotateNullability: true);
+  }
+
   test_mixin_method_namedAsConstraint() async {
     var library = await checkLibrary(r'''
 class A {}
diff --git a/pkg/analyzer/test/src/task/options_test.dart b/pkg/analyzer/test/src/task/options_test.dart
index 557aef8..ff939fc 100644
--- a/pkg/analyzer/test/src/task/options_test.dart
+++ b/pkg/analyzer/test/src/task/options_test.dart
@@ -484,7 +484,7 @@
 }
 
 class TestRule extends LintRule {
-  TestRule() : super(name: 'fantastic_test_rule');
+  TestRule() : super(name: 'fantastic_test_rule', description: '');
 
-  TestRule.withName(String name) : super(name: name);
+  TestRule.withName(String name) : super(name: name, description: '');
 }
diff --git a/pkg/analyzer/test/src/test_all.dart b/pkg/analyzer/test/src/test_all.dart
index 80fbf6b..6fd19dc 100644
--- a/pkg/analyzer/test/src/test_all.dart
+++ b/pkg/analyzer/test/src/test_all.dart
@@ -4,6 +4,7 @@
 
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
+import 'clients/test_all.dart' as clients;
 import 'command_line/test_all.dart' as command_line;
 import 'context/test_all.dart' as context;
 import 'dart/test_all.dart' as dart;
@@ -25,6 +26,7 @@
 
 main() {
   defineReflectiveSuite(() {
+    clients.main();
     command_line.main();
     context.main();
     dart.main();
diff --git a/pkg/analyzer/test/src/workspace/bazel_test.dart b/pkg/analyzer/test/src/workspace/bazel_test.dart
index f267f85..6bc5fb9 100644
--- a/pkg/analyzer/test/src/workspace/bazel_test.dart
+++ b/pkg/analyzer/test/src/workspace/bazel_test.dart
@@ -130,6 +130,58 @@
         exists: true);
   }
 
+  void test_resolveAbsolute_file_bin_to_genfiles() {
+    _addResources([
+      '/workspace/WORKSPACE',
+      '/workspace/bazel-genfiles/my/foo/test/foo1.dart',
+      '/workspace/bazel-bin/'
+    ]);
+    _assertResolve('file:///workspace/bazel-bin/my/foo/test/foo1.dart',
+        '/workspace/bazel-genfiles/my/foo/test/foo1.dart',
+        restore: false);
+  }
+
+  void test_resolveAbsolute_file_genfiles_to_workspace() {
+    _addResources([
+      '/workspace/WORKSPACE',
+      '/workspace/bazel-genfiles/',
+      '/workspace/my/foo/test/foo1.dart'
+    ]);
+    _assertResolve('file:///workspace/bazel-genfiles/my/foo/test/foo1.dart',
+        '/workspace/my/foo/test/foo1.dart',
+        restore: false);
+  }
+
+  void test_resolveAbsolute_file_not_in_workspace() {
+    _addResources([
+      '/workspace/WORKSPACE',
+      '/workspace/bazel-genfiles/',
+      '/other/my/foo/test/foo1.dart'
+    ]);
+    _assertNoResolve('file:///other/my/foo/test/foo1.dart');
+  }
+
+  void test_resolveAbsolute_file_readonly_to_workspace() {
+    _addResources([
+      '/workspace/WORKSPACE',
+      '/READONLY/workspace/',
+      '/workspace/my/foo/test/foo1.dart'
+    ]);
+    _assertResolve('file:///READONLY/workspace/my/foo/test/foo1.dart',
+        '/workspace/my/foo/test/foo1.dart',
+        restore: false);
+  }
+
+  void test_resolveAbsolute_file_workspace_to_genfiles() {
+    _addResources([
+      '/workspace/WORKSPACE',
+      '/workspace/bazel-genfiles/my/foo/test/foo1.dart'
+    ]);
+    _assertResolve('file:///workspace/my/foo/test/foo1.dart',
+        '/workspace/bazel-genfiles/my/foo/test/foo1.dart',
+        restore: false);
+  }
+
   void test_resolveAbsolute_genfiles() {
     _addResources([
       '/workspace/WORKSPACE',
@@ -465,6 +517,11 @@
     resolver = BazelPackageUriResolver(workspace);
   }
 
+  void _assertNoResolve(String uriStr) {
+    var uri = Uri.parse(uriStr);
+    expect(resolver.resolveAbsolute(uri), isNull);
+  }
+
   void _assertResolve(String uriStr, String posixPath,
       {bool exists = true, bool restore = true}) {
     Uri uri = Uri.parse(uriStr);
diff --git a/pkg/analyzer/test/util/id_testing_helper.dart b/pkg/analyzer/test/util/id_testing_helper.dart
index be77c72..c393ad8 100644
--- a/pkg/analyzer/test/util/id_testing_helper.dart
+++ b/pkg/analyzer/test/util/id_testing_helper.dart
@@ -129,7 +129,7 @@
   MemberAnnotations<IdValue> memberAnnotations =
       testData.expectedMaps[config.marker];
   var resourceProvider = MemoryResourceProvider();
-  var testUris = [];
+  var testUris = <Uri>[];
   for (var entry in testData.memorySourceFiles.entries) {
     var testUri = _toTestUri(entry.key);
     testUris.add(testUri);
diff --git a/pkg/analyzer/test/utils.dart b/pkg/analyzer/test/utils.dart
index 5dce8862..2e00258 100644
--- a/pkg/analyzer/test/utils.dart
+++ b/pkg/analyzer/test/utils.dart
@@ -220,7 +220,7 @@
   Asserter<DartType> isFunction2Of(
           Asserter<DartType> argType, Asserter<DartType> returnType) =>
       (DartType type) {
-        FunctionType fType = (type as FunctionType);
+        FunctionType fType = type as FunctionType;
         argType(fType.normalParameterTypes[0]);
         returnType(fType.returnType);
       };
@@ -230,7 +230,7 @@
   AsserterBuilder<List<Asserter<DartType>>, DartType> isInstantiationOf(
           Asserter<DartType> baseAssert) =>
       (List<Asserter<DartType>> argAsserts) => (DartType type) {
-            InterfaceType t = (type as InterfaceType);
+            InterfaceType t = type as InterfaceType;
             baseAssert(t);
             List<DartType> typeArguments = t.typeArguments;
             expect(typeArguments, hasLength(argAsserts.length));
diff --git a/pkg/analyzer/tool/diagnostics/diagnostics.md b/pkg/analyzer/tool/diagnostics/diagnostics.md
index 88b7aee..baec4b4 100644
--- a/pkg/analyzer/tool/diagnostics/diagnostics.md
+++ b/pkg/analyzer/tool/diagnostics/diagnostics.md
@@ -3439,6 +3439,9 @@
 
 ### invalid_null_aware_operator
 
+_The target expression can't be null because of short-circuiting, so the
+null-aware operator '{0}' can't be used._
+
 _The target expression can't be null, so the null-aware operator '{0}' can't be
 used._
 
@@ -8101,6 +8104,8 @@
 
 ### unused_element
 
+_A value for optional parameter '{0}' isn't ever given._
+
 _The declaration '{0}' isn't referenced._
 
 #### Description
diff --git a/pkg/analyzer/tool/experiments/generate.dart b/pkg/analyzer/tool/experiments/generate.dart
index 231851f..02b1a0e 100644
--- a/pkg/analyzer/tool/experiments/generate.dart
+++ b/pkg/analyzer/tool/experiments/generate.dart
@@ -107,26 +107,15 @@
         out.writeln('IsEnabledByDefault.$id,');
       }
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-      false, // bogus-disabled
-      true, // bogus-enabled
     ];
 ''');
   }
 
   void generateSection_CurrentState() {
-    // TODO(danrubel): Remove bogus entries
     out.write('''
 
 mixin _CurrentState {
-  /// Current state for the flag "bogus-disabled"
-  @deprecated
-  bool get bogus_disabled => isEnabled(ExperimentalFeatures.bogus_disabled);
-
-  /// Current state for the flag "bogus-enabled"
-  @deprecated
-  bool get bogus_enabled => isEnabled(ExperimentalFeatures.bogus_enabled);
 ''');
     for (var key in keysSorted) {
       var id = keyToIdentifier(key);
@@ -164,16 +153,7 @@
       static const String ${keyToIdentifier(key)} = '$key';
     ''');
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-
-      /// String to enable the experiment "bogus-disabled"
-      @deprecated
-      static const String bogus_disabled = 'bogus-disabled';
-
-      /// String to enable the experiment "bogus-enabled"
-      @deprecated
-      static const String bogus_enabled = 'bogus-enabled';
     }''');
   }
 
@@ -205,30 +185,7 @@
       out.writeln(');');
       ++index;
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-
-      @deprecated
-      static const bogus_disabled = ExperimentalFeature(
-        index: $index,
-        // ignore: deprecated_member_use_from_same_package
-        enableString: EnableString.bogus_disabled,
-        isEnabledByDefault: IsEnabledByDefault.bogus_disabled,
-        isExpired: IsExpired.bogus_disabled,
-        documentation: null,
-        firstSupportedVersion: null,
-      );
-
-      @deprecated
-      static const bogus_enabled = ExperimentalFeature(
-        index: ${index + 1},
-        // ignore: deprecated_member_use_from_same_package
-        enableString: EnableString.bogus_enabled,
-        isEnabledByDefault: IsEnabledByDefault.bogus_enabled,
-        isExpired: IsExpired.bogus_enabled,
-        documentation: null,
-        firstSupportedVersion: '1.0.0',
-      );
     }''');
   }
 
@@ -247,16 +204,7 @@
       static const bool ${keyToIdentifier(key)} = $shipped;
     ''');
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-
-      /// Default state of the experiment "bogus-disabled"
-      @deprecated
-      static const bool bogus_disabled = false;
-
-      /// Default state of the experiment "bogus-enabled"
-      @deprecated
-      static const bool bogus_enabled = true;
     }''');
   }
 
@@ -280,14 +228,7 @@
         throw 'Cannot mark shipped feature as "expired: false"';
       }
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-
-      /// Expiration status of the experiment "bogus-disabled"
-      static const bool bogus_disabled = true;
-
-      /// Expiration status of the experiment "bogus-enabled"
-      static const bool bogus_enabled = true;
     }''');
   }
 
@@ -303,13 +244,7 @@
   EnableString.$id: ExperimentalFeatures.$id,
     ''');
     }
-    // TODO(danrubel): Remove bogus entries
     out.write('''
-
-  // ignore: deprecated_member_use_from_same_package
-  EnableString.bogus_disabled: ExperimentalFeatures.bogus_disabled,
-  // ignore: deprecated_member_use_from_same_package
-  EnableString.bogus_enabled: ExperimentalFeatures.bogus_enabled,
 };
 ''');
   }
diff --git a/pkg/analyzer/tool/summary/build_sdk_summaries.dart b/pkg/analyzer/tool/summary/build_sdk_summaries.dart
index 515fb5d..9d76bc7 100644
--- a/pkg/analyzer/tool/summary/build_sdk_summaries.dart
+++ b/pkg/analyzer/tool/summary/build_sdk_summaries.dart
@@ -6,7 +6,7 @@
 
 import 'package:analyzer/dart/sdk/build_sdk_summary.dart';
 import 'package:analyzer/file_system/physical_file_system.dart';
-import 'package:analyzer/src/dart/sdk/sdk.dart';
+import 'package:cli_util/cli_util.dart';
 
 void main(List<String> args) {
   String command;
@@ -28,9 +28,7 @@
   //
   // Validate the SDK path.
   //
-  sdkPath ??=
-      FolderBasedDartSdk.defaultSdkDirectory(PhysicalResourceProvider.INSTANCE)
-          .path;
+  sdkPath ??= getSdkPath();
   if (!FileSystemEntity.isDirectorySync('$sdkPath/lib')) {
     print("'$sdkPath/lib' does not exist.");
     _printUsage();
diff --git a/pkg/analyzer_cli/analysis_options.yaml b/pkg/analyzer_cli/analysis_options.yaml
index eb5e7f0..a8a1d4b 100644
--- a/pkg/analyzer_cli/analysis_options.yaml
+++ b/pkg/analyzer_cli/analysis_options.yaml
@@ -6,6 +6,8 @@
   errors:
     # Increase the severity of the unused_import hint.
     unused_import: warning
+  language:
+    strict-inference: true
   exclude:
     - test/data/**
 linter:
diff --git a/pkg/analyzer_cli/lib/src/analyzer_impl.dart b/pkg/analyzer_cli/lib/src/analyzer_impl.dart
index 7bb46af..e72299a 100644
--- a/pkg/analyzer_cli/lib/src/analyzer_impl.dart
+++ b/pkg/analyzer_cli/lib/src/analyzer_impl.dart
@@ -276,7 +276,7 @@
   }
 
   @override
-  void logInfo(String message, [exception]) {
+  void logInfo(String message, [Object exception]) {
     outSink.writeln(message);
     if (exception != null) {
       outSink.writeln(exception);
diff --git a/pkg/analyzer_cli/lib/src/batch_mode.dart b/pkg/analyzer_cli/lib/src/batch_mode.dart
index f147d64..3a34b88 100644
--- a/pkg/analyzer_cli/lib/src/batch_mode.dart
+++ b/pkg/analyzer_cli/lib/src/batch_mode.dart
@@ -13,8 +13,8 @@
 /// Provides a framework to read command line options from stdin and feed them
 /// to a callback.
 class BatchRunner {
-  final outSink;
-  final errorSink;
+  final StringSink outSink;
+  final StringSink errorSink;
 
   BatchRunner(this.outSink, this.errorSink);
 
diff --git a/pkg/analyzer_cli/lib/src/build_mode.dart b/pkg/analyzer_cli/lib/src/build_mode.dart
index bf9eeb1..57b4ef2 100644
--- a/pkg/analyzer_cli/lib/src/build_mode.dart
+++ b/pkg/analyzer_cli/lib/src/build_mode.dart
@@ -6,6 +6,7 @@
 import 'dart:io' as io;
 import 'dart:isolate';
 
+import 'package:analyzer/dart/analysis/context_locator.dart' as api;
 import 'package:analyzer/dart/analysis/declared_variables.dart';
 import 'package:analyzer/dart/analysis/results.dart';
 import 'package:analyzer/dart/ast/ast.dart';
@@ -16,6 +17,8 @@
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/cache.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
+import 'package:analyzer/src/dart/analysis/driver_based_analysis_context.dart'
+    as api;
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/performance_logger.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
@@ -432,6 +435,8 @@
       packages: packages,
     );
 
+    _setAnalysisDriverAnalysisContext(rootPath);
+
     declaredVariables = DeclaredVariables.fromMap(options.definedVariables);
     analysisDriver.declaredVariables = declaredVariables;
 
@@ -540,6 +545,31 @@
       }
     });
   }
+
+  void _setAnalysisDriverAnalysisContext(String rootPath) {
+    if (rootPath == null) {
+      return;
+    }
+
+    var apiContextRoots = api.ContextLocator(
+      resourceProvider: resourceProvider,
+    ).locateRoots(
+      includedPaths: [rootPath],
+      excludedPaths: [],
+    );
+
+    if (apiContextRoots.isEmpty) {
+      return;
+    }
+
+    analysisDriver.configure(
+      analysisContext: api.DriverBasedAnalysisContext(
+        resourceProvider,
+        apiContextRoots.first,
+        analysisDriver,
+      ),
+    );
+  }
 }
 
 /// Tracks paths to dependencies, really just a thin api around a Set<String>.
diff --git a/pkg/analyzer_cli/lib/src/driver.dart b/pkg/analyzer_cli/lib/src/driver.dart
index a78cc89..9a619af 100644
--- a/pkg/analyzer_cli/lib/src/driver.dart
+++ b/pkg/analyzer_cli/lib/src/driver.dart
@@ -6,6 +6,7 @@
 import 'dart:io' as io;
 import 'dart:isolate';
 
+import 'package:analyzer/dart/analysis/context_locator.dart' as api;
 import 'package:analyzer/dart/sdk/build_sdk_summary.dart';
 import 'package:analyzer/error/error.dart';
 import 'package:analyzer/file_system/file_system.dart';
@@ -15,6 +16,8 @@
 import 'package:analyzer/src/context/packages.dart';
 import 'package:analyzer/src/dart/analysis/byte_store.dart';
 import 'package:analyzer/src/dart/analysis/driver.dart';
+import 'package:analyzer/src/dart/analysis/driver_based_analysis_context.dart'
+    as api;
 import 'package:analyzer/src/dart/analysis/file_state.dart';
 import 'package:analyzer/src/dart/analysis/performance_logger.dart';
 import 'package:analyzer/src/dart/analysis/results.dart';
@@ -574,6 +577,7 @@
         packages: packageInfo.packages);
     analysisDriver.results.listen((_) {});
     analysisDriver.exceptions.listen((_) {});
+    _setAnalysisDriverAnalysisContext(source);
     scheduler.start();
   }
 
@@ -627,6 +631,27 @@
     return analyzer.analyze(formatter);
   }
 
+  void _setAnalysisDriverAnalysisContext(String rootPath) {
+    var apiContextRoots = api.ContextLocator(
+      resourceProvider: resourceProvider,
+    ).locateRoots(
+      includedPaths: [rootPath],
+      excludedPaths: [],
+    );
+
+    if (apiContextRoots.isEmpty) {
+      return;
+    }
+
+    analysisDriver.configure(
+      analysisContext: api.DriverBasedAnalysisContext(
+        resourceProvider,
+        apiContextRoots.first,
+        analysisDriver,
+      ),
+    );
+  }
+
   void _setupSdk(CommandLineOptions options, AnalysisOptions analysisOptions) {
     if (sdk == null) {
       if (options.dartSdkSummaryPath != null) {
diff --git a/pkg/analyzer_cli/lib/src/error_formatter.dart b/pkg/analyzer_cli/lib/src/error_formatter.dart
index e7a39af..a807955 100644
--- a/pkg/analyzer_cli/lib/src/error_formatter.dart
+++ b/pkg/analyzer_cli/lib/src/error_formatter.dart
@@ -137,10 +137,9 @@
   bool get isWarning => severity == 'warning';
 
   @override
-  bool operator ==(other) {
-    if (other is! CLIError) return false;
-
-    return severity == other.severity &&
+  bool operator ==(Object other) {
+    return other is CLIError &&
+        severity == other.severity &&
         sourcePath == other.sourcePath &&
         errorCode == other.errorCode &&
         offset == other.offset;
diff --git a/pkg/analyzer_cli/lib/src/options.dart b/pkg/analyzer_cli/lib/src/options.dart
index fd0f95d..b4314f9 100644
--- a/pkg/analyzer_cli/lib/src/options.dart
+++ b/pkg/analyzer_cli/lib/src/options.dart
@@ -215,7 +215,7 @@
   /// analyzer options. In case of a format error, calls [printAndFail], which
   /// by default prints an error message to stderr and exits.
   static CommandLineOptions parse(List<String> args,
-      {Function(String msg) printAndFail = printAndFail}) {
+      {void Function(String msg) printAndFail = printAndFail}) {
     var options = _parse(args);
 
     /// Only happens in testing.
diff --git a/pkg/analyzer_cli/test/build_mode_test.dart b/pkg/analyzer_cli/test/build_mode_test.dart
index c2db753..aee3830 100644
--- a/pkg/analyzer_cli/test/build_mode_test.dart
+++ b/pkg/analyzer_cli/test/build_mode_test.dart
@@ -28,7 +28,8 @@
       : super(MemoryResourceProvider(), connection);
 
   @override
-  Future<void> analyze(CommandLineOptions options, inputs) async {
+  Future<void> analyze(
+      CommandLineOptions options, Map<String, WorkerInput> inputs) async {
     if (_analyze != null) {
       _analyze(options);
     }
diff --git a/pkg/analyzer_cli/test/data/file_with_assert_initializers.dart b/pkg/analyzer_cli/test/data/file_with_assert_initializers.dart
index 46b7c0c..1f30a88 100644
--- a/pkg/analyzer_cli/test/data/file_with_assert_initializers.dart
+++ b/pkg/analyzer_cli/test/data/file_with_assert_initializers.dart
@@ -2,6 +2,6 @@
   int _x, _y;
   C(x, y)
       : _x = x,
-        assert (x < y),
+        assert(x < y),
         _y = y;
 }
diff --git a/pkg/analyzer_cli/test/driver_test.dart b/pkg/analyzer_cli/test/driver_test.dart
index 4735d87..fe60337 100644
--- a/pkg/analyzer_cli/test/driver_test.dart
+++ b/pkg/analyzer_cli/test/driver_test.dart
@@ -38,6 +38,23 @@
 }
 
 class AbstractBuildModeTest extends BaseTest {
+  List<String> get _sdkSummaryArguments {
+    var sdkPath = path.dirname(
+      path.dirname(
+        Platform.resolvedExecutable,
+      ),
+    );
+
+    var dartSdkSummaryPath = path.join(
+      sdkPath,
+      'lib',
+      '_internal',
+      'strong.sum',
+    );
+
+    return ['--dart-sdk-summary', dartSdkSummaryPath];
+  }
+
   Future<void> _doDrive(
     String filePath, {
     String sourceArgument,
@@ -54,24 +71,7 @@
     args.add('--build-mode');
     args.add('--format=machine');
 
-    {
-      var sdkPath = path.dirname(
-        path.dirname(
-          Platform.resolvedExecutable,
-        ),
-      );
-
-      var dartSdkSummaryPath = path.join(
-        sdkPath,
-        'lib',
-        '_internal',
-        'strong.sum',
-      );
-
-      args.add('--dart-sdk-summary');
-      args.add(dartSdkSummaryPath);
-    }
-
+    args.addAll(_sdkSummaryArguments);
     args.addAll(additionalArgs);
 
     if (sourceArgument == null) {
@@ -97,7 +97,7 @@
   bool get usePreviewDart2 => false;
 
   /// Normalize text with bullets.
-  String bulletToDash(item) => '$item'.replaceAll('•', '-');
+  String bulletToDash(StringSink item) => '$item'.replaceAll('•', '-');
 
   /// Start a driver for the given [source], optionally providing additional
   /// [args] and an [options] file path. The value of [options] defaults to an
@@ -587,6 +587,25 @@
     expect(exitCode, isNot(0));
   }
 
+  Future<void> test_noInputs() async {
+    await withTempDirAsync((tempDir) async {
+      var outputPath = path.join(tempDir, 'test.sum');
+
+      await driveMany([], args: [
+        '--build-mode',
+        '--format=machine',
+        ..._sdkSummaryArguments,
+        '--build-summary-only',
+        '--build-summary-output=$outputPath',
+      ]);
+
+      var output = File(outputPath);
+      expect(output.existsSync(), isTrue);
+
+      expect(exitCode, 0);
+    });
+  }
+
   Future<void> test_noStatistics() async {
     await _doDrive(path.join('data', 'test_file.dart'));
     // Should not print statistics summary.
@@ -721,6 +740,7 @@
 
 @reflectiveTest
 class ExitCodesTest extends BaseTest {
+  @SkippedTest(reason: 'Fails on bots, passes locally. Do not know why.')
   Future<void> test_bazelWorkspace_relativePath() async {
     // Copy to temp dir so that existing analysis options
     // in the test directory hierarchy do not interfere
diff --git a/pkg/analyzer_cli/test/options_test.dart b/pkg/analyzer_cli/test/options_test.dart
index 6b81425..573233a 100644
--- a/pkg/analyzer_cli/test/options_test.dart
+++ b/pkg/analyzer_cli/test/options_test.dart
@@ -253,7 +253,7 @@
       });
 
       test('bad SDK dir', () {
-        var failureMessage;
+        String failureMessage;
         CommandLineOptions.parse(['--dart-sdk', '&&&&&', 'foo.dart'],
             printAndFail: (msg) => failureMessage = msg);
         expect(failureMessage, equals('Invalid Dart SDK path: &&&&&'));
diff --git a/pkg/analyzer_plugin/CHANGELOG.md b/pkg/analyzer_plugin/CHANGELOG.md
index 14f32e9..60d65bb 100644
--- a/pkg/analyzer_plugin/CHANGELOG.md
+++ b/pkg/analyzer_plugin/CHANGELOG.md
@@ -1,3 +1,16 @@
+## 0.3.1-dev
+- Deprecated the class `DartChangeBuilder` and enhanced `ChangeBuilder` to be
+  the replacement for it.
+- Deprecated the method `ChangeBuilder.addFileEdit` and introduced
+  `ChangeBuilder.addDartFileEdit` and `ChangeBuilder.addGenericFileEdit` to be
+  the replacements for it.
+
+## 0.3.0
+- Removed deprecated `Plugin.getResolveResult`. Use `getResolvedUnitResult`.
+
+## 0.2.5
+- Change supported analyzer version to `^0.39.12`
+
 ## 0.2.4
 - Exposed method `AnalyzerConverter.locationFromElement` (was previously
   private).
diff --git a/pkg/analyzer_plugin/doc/tutorial/assists.md b/pkg/analyzer_plugin/doc/tutorial/assists.md
index ade51d6..b71e33d 100644
--- a/pkg/analyzer_plugin/doc/tutorial/assists.md
+++ b/pkg/analyzer_plugin/doc/tutorial/assists.md
@@ -80,7 +80,7 @@
   }
 
   void _wrapInIf() {
-    ChangeBuilder builder = new DartChangeBuilder(session);
+    ChangeBuilder builder = new ChangeBuilder(session: session);
     // TODO Build the edit to wrap the selection in a 'if' statement.
     addAssist(wrapInIf, builder);
   }
diff --git a/pkg/analyzer_plugin/doc/tutorial/creating_edits.md b/pkg/analyzer_plugin/doc/tutorial/creating_edits.md
index 223786e..d3aabce 100644
--- a/pkg/analyzer_plugin/doc/tutorial/creating_edits.md
+++ b/pkg/analyzer_plugin/doc/tutorial/creating_edits.md
@@ -9,27 +9,28 @@
 your plugin, but will ensure a consistent user experience in terms of the code
 being generated by the analysis server.
 
-## `DartChangeBuilder`
+## `ChangeBuilder`
 
-The class used to create a `SourceChange` is `DartChangeBuilder`, defined in
-`package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart`.
-You can create a `DartChangeBuilder` with the following:
+The class used to create a `SourceChange` is `ChangeBuilder`, defined in
+`package:analyzer_plugin/utilities/change_builder/change_builder_core.dart`.
+You can create a `ChangeBuilder` with the following:
 
 ```dart
-DartChangeBuilder changeBuilder = new DartChangeBuilder(session);
+ChangeBuilder changeBuilder = new ChangeBuilder(session: session);
 ```
 
-The constructor required an instance of the class `AnalysisSession`. How you get
+The constructor requires an instance of the class `AnalysisSession`. How you get
 the correct instance depends on where the constructor is being invoked.
 
 A `SourceChange` can contain edits that are to be applied to multiple files. The
-edits for a single file are created by invoking the method `addFileEdit`, as
+edits for a single file are created by invoking the method `addDartFileEdit`, as
 illustrated by the following:
 
 ```dart
-changeBuilder.addFileEdit(path, (DartFileEditBuilder fileEditBuilder) {
+await changeBuilder.addDartFileEdit(path,
+    (DartFileEditBuilder fileEditBuilder) {
   // ...
-}
+});
 ```
 
 where the `path` is the path to the file to which the edits will be applied.
@@ -170,7 +171,7 @@
 A `SourceChange` also allows you to specify where the cursor should be placed
 after the edits are applied. There are two ways to specify this.
 
-The first is by invoking the method `setSelection` on a `DartChangeBuilder`.
+The first is by invoking the method `setSelection` on a `ChangeBuilder`.
 The method takes a `Position`, which encapsulates an offset in a particular
 file. This can be difficult to get right because the offset is required to be
 the offset *after* all of the edits for that file have been applied.
diff --git a/pkg/analyzer_plugin/doc/tutorial/fixes.md b/pkg/analyzer_plugin/doc/tutorial/fixes.md
index c81548c..920ed30 100644
--- a/pkg/analyzer_plugin/doc/tutorial/fixes.md
+++ b/pkg/analyzer_plugin/doc/tutorial/fixes.md
@@ -95,7 +95,7 @@
   void _defineComponent(AnalysisError error) {
     // TODO Get the name from the source code.
     String componentName = null;
-    ChangeBuilder builder = new DartChangeBuilder(session);
+    ChangeBuilder builder = new ChangeBuilder(session: session);
     // TODO Build the edit to insert the definition of the component.
     addFix(error, defineComponent, builder, args: [componentName]);
   }
diff --git a/pkg/analyzer_plugin/lib/plugin/plugin.dart b/pkg/analyzer_plugin/lib/plugin/plugin.dart
index 6147731..4e8f153 100644
--- a/pkg/analyzer_plugin/lib/plugin/plugin.dart
+++ b/pkg/analyzer_plugin/lib/plugin/plugin.dart
@@ -173,14 +173,6 @@
     return result;
   }
 
-  /// Return the result of analyzing the file with the given [path].
-  ///
-  /// Throw a [RequestFailure] is the file cannot be analyzed or if the driver
-  /// associated with the file is not an [AnalysisDriver].
-  @deprecated
-  Future<ResolveResult> getResolveResult(String path) =>
-      getResolvedUnitResult(path);
-
   /// Handle an 'analysis.getNavigation' request.
   ///
   /// Throw a [RequestFailure] if the request could not be handled.
@@ -412,7 +404,7 @@
         FileByteStore(byteStorePath,
             tempNameSuffix: DateTime.now().millisecondsSinceEpoch.toString()),
         64 * M);
-    _sdkManager = DartSdkManager(sdkPath, true);
+    _sdkManager = DartSdkManager(sdkPath);
     return PluginVersionCheckResult(
         isCompatibleWith(serverVersion), name, version, fileGlobsToAnalyze,
         contactInfo: contactInfo);
diff --git a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_core.dart b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_core.dart
index eea528e..38904ba 100644
--- a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_core.dart
+++ b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_core.dart
@@ -6,12 +6,22 @@
 import 'dart:collection';
 import 'dart:math' as math;
 
+import 'package:analyzer/dart/analysis/results.dart';
+import 'package:analyzer/dart/analysis/session.dart';
+import 'package:analyzer/exception/exception.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
+import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
 import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_workspace.dart';
 
 /// A builder used to build a [SourceChange].
 class ChangeBuilderImpl implements ChangeBuilder {
+  /// The workspace in which the change builder should operate, or `null` if no
+  /// Dart files will be changed.
+  final ChangeWorkspace workspace;
+
   /// The end-of-line marker used in the file being edited, or `null` if the
   /// default marker should be used.
   String eol;
@@ -31,11 +41,18 @@
   /// should not be updated in result of inserting this builder.
   final Set<Position> _lockedPositions = HashSet<Position>.identity();
 
-  /// A map of absolute normalized path to file edit builder.
-  final _fileEditBuilders = <String, FileEditBuilderImpl>{};
+  /// A map of absolute normalized path to generic file edit builders.
+  final Map<String, FileEditBuilderImpl> _genericFileEditBuilders = {};
 
-  /// Initialize a newly created change builder.
-  ChangeBuilderImpl();
+  /// A map of absolute normalized path to Dart file edit builders.
+  final Map<String, DartFileEditBuilderImpl> _dartFileEditBuilders = {};
+
+  /// Initialize a newly created change builder. If the builder will be used to
+  /// create changes for Dart files, then either a [session] or a [workspace]
+  /// must be provided (but not both).
+  ChangeBuilderImpl({AnalysisSession session, ChangeWorkspace workspace})
+      : assert(session == null || workspace == null),
+        workspace = workspace ?? _SingleSessionWorkspace(session);
 
   @override
   SourceRange get selectionRange => _selectionRange;
@@ -43,7 +60,13 @@
   @override
   SourceChange get sourceChange {
     var change = SourceChange('');
-    for (var builder in _fileEditBuilders.values) {
+    for (var builder in _genericFileEditBuilders.values) {
+      if (builder.hasEdits) {
+        change.addFileEdit(builder.fileEdit);
+        builder.finalize();
+      }
+    }
+    for (var builder in _dartFileEditBuilders.values) {
       if (builder.hasEdits) {
         change.addFileEdit(builder.fileEdit);
         builder.finalize();
@@ -59,13 +82,45 @@
   }
 
   @override
+  Future<void> addDartFileEdit(
+      String path, void Function(DartFileEditBuilder builder) buildFileEdit,
+      {ImportPrefixGenerator importPrefixGenerator}) async {
+    if (_genericFileEditBuilders.containsKey(path)) {
+      throw StateError("Can't create both a generic file edit and a dart file "
+          'edit for the same file');
+    }
+    var builder = _dartFileEditBuilders[path];
+    if (builder == null) {
+      builder = await createDartFileEditBuilder(path);
+      if (builder != null) {
+        _dartFileEditBuilders[path] = builder;
+      }
+    }
+    if (builder != null) {
+      builder.importPrefixGenerator = importPrefixGenerator;
+      buildFileEdit(builder);
+    }
+  }
+
+  @Deprecated('Use either addDartFileEdit or addGenericFileEdit')
+  @override
   Future<void> addFileEdit(
       String path, void Function(FileEditBuilder builder) buildFileEdit) async {
-    var builder = _fileEditBuilders[path];
+    return addGenericFileEdit(path, buildFileEdit);
+  }
+
+  @override
+  Future<void> addGenericFileEdit(
+      String path, void Function(FileEditBuilder builder) buildFileEdit) async {
+    if (_dartFileEditBuilders.containsKey(path)) {
+      throw StateError("Can't create both a generic file edit and a dart file "
+          'edit for the same file');
+    }
+    var builder = _genericFileEditBuilders[path];
     if (builder == null) {
-      builder = await createFileEditBuilder(path);
+      builder = await createGenericFileEditBuilder(path);
       if (builder != null) {
-        _fileEditBuilders[path] = builder;
+        _genericFileEditBuilders[path] = builder;
       }
     }
     if (builder != null) {
@@ -73,11 +128,47 @@
     }
   }
 
+  /// Create and return a [DartFileEditBuilder] that can be used to build edits
+  /// to the Dart file with the given [path].
+  Future<DartFileEditBuilderImpl> createDartFileEditBuilder(String path) async {
+    // TODO(brianwilkerson) Make this method private when
+    //  `DartChangeBuilderImpl` is removed.
+    if (workspace == null) {
+      throw StateError("Can't create a DartFileEditBuilder without providing "
+          'either a session or a workspace');
+    }
+    if (!workspace.containsFile(path)) {
+      return null;
+    }
+
+    var session = workspace.getSession(path);
+    var result = await session.getResolvedUnit(path);
+    var state = result?.state ?? ResultState.INVALID_FILE_TYPE;
+    if (state == ResultState.INVALID_FILE_TYPE) {
+      throw AnalysisException('Cannot analyze "$path"');
+    }
+    var timeStamp = state == ResultState.VALID ? 0 : -1;
+
+    var declaredUnit = result.unit.declaredElement;
+    var libraryUnit = declaredUnit.library.definingCompilationUnit;
+
+    DartFileEditBuilderImpl libraryEditBuilder;
+    if (libraryUnit != declaredUnit) {
+      // If the receiver is a part file builder, then proactively cache the
+      // library file builder so that imports can be finalized synchronously.
+      await addDartFileEdit(libraryUnit.source.fullName, (builder) {
+        libraryEditBuilder = builder as DartFileEditBuilderImpl;
+      });
+    }
+
+    return DartFileEditBuilderImpl(this, result, timeStamp, libraryEditBuilder);
+  }
+
   /// Create and return a [FileEditBuilder] that can be used to build edits to
-  /// the file with the given [path] and [timeStamp].
-  Future<FileEditBuilderImpl> createFileEditBuilder(String path) async {
-    // TODO(brianwilkerson) Determine whether this await is necessary.
-    await null;
+  /// the file with the given [path].
+  Future<FileEditBuilderImpl> createGenericFileEditBuilder(String path) async {
+    // TODO(brianwilkerson) Make this method private when
+    //  `DartChangeBuilderImpl` is removed.
     return FileEditBuilderImpl(this, path, 0);
   }
 
@@ -419,3 +510,24 @@
     editBuilder.writeln(string);
   }
 }
+
+/// Workspace that wraps a single [AnalysisSession].
+class _SingleSessionWorkspace extends ChangeWorkspace {
+  final AnalysisSession session;
+
+  _SingleSessionWorkspace(this.session);
+
+  @override
+  bool containsFile(String path) {
+    var analysisContext = session.analysisContext;
+    return analysisContext.contextRoot.isAnalyzed(path);
+  }
+
+  @override
+  AnalysisSession getSession(String path) {
+    if (containsFile(path)) {
+      return session;
+    }
+    throw StateError('Not in a context root: $path');
+  }
+}
diff --git a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
index f35f707..d1c08d5 100644
--- a/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
+++ b/pkg/analyzer_plugin/lib/src/utilities/change_builder/change_builder_dart.dart
@@ -12,7 +12,6 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
-import 'package:analyzer/exception/exception.dart';
 import 'package:analyzer/src/dart/ast/utilities.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/generated/source.dart';
@@ -28,59 +27,30 @@
 import 'package:dart_style/dart_style.dart';
 
 /// A [ChangeBuilder] used to build changes in Dart files.
+@Deprecated('Use ChangeBuilder')
 class DartChangeBuilderImpl extends ChangeBuilderImpl
     implements DartChangeBuilder {
-  /// The analysis session in which the files are analyzed and edited.
-  final ChangeWorkspace workspace;
-
   /// Initialize a newly created change builder.
-  DartChangeBuilderImpl(AnalysisSession session)
-      : this.forWorkspace(_SingleSessionWorkspace(session));
+  @Deprecated('Use ChangeBuilder(session: session)')
+  DartChangeBuilderImpl(AnalysisSession session) : super(session: session);
 
-  DartChangeBuilderImpl.forWorkspace(this.workspace);
+  @Deprecated('Use ChangeBuilder(workspace: workspace)')
+  DartChangeBuilderImpl.forWorkspace(ChangeWorkspace workspace)
+      : super(workspace: workspace);
 
+  @Deprecated('Use ChangeBuilder.addDartFileEdit')
   @override
   Future<void> addFileEdit(
       String path, void Function(DartFileEditBuilder builder) buildFileEdit,
       {ImportPrefixGenerator importPrefixGenerator}) {
-    return super.addFileEdit(path, (builder) {
-      var dartBuilder = builder as DartFileEditBuilderImpl;
-      dartBuilder.importPrefixGenerator = importPrefixGenerator;
-      buildFileEdit(dartBuilder);
-    });
+    return super.addDartFileEdit(path, buildFileEdit,
+        importPrefixGenerator: importPrefixGenerator);
   }
 
   @override
-  Future<DartFileEditBuilderImpl> createFileEditBuilder(String path) async {
-    // TODO(brianwilkerson) Determine whether this await is necessary.
-    await null;
-
-    if (!workspace.containsFile(path)) {
-      return null;
-    }
-
-    var session = workspace.getSession(path);
-    var result = await session.getResolvedUnit(path);
-    var state = result?.state ?? ResultState.INVALID_FILE_TYPE;
-    if (state == ResultState.INVALID_FILE_TYPE) {
-      throw AnalysisException('Cannot analyze "$path"');
-    }
-    var timeStamp = state == ResultState.VALID ? 0 : -1;
-
-    var declaredUnit = result.unit.declaredElement;
-    var libraryUnit = declaredUnit.library.definingCompilationUnit;
-
-    DartFileEditBuilderImpl libraryEditBuilder;
-    if (libraryUnit != declaredUnit) {
-      // If the receiver is a part file builder, then proactively cache the
-      // library file builder so that imports can be finalized synchronously.
-      await addFileEdit(libraryUnit.source.fullName,
-          (DartFileEditBuilder builder) {
-        libraryEditBuilder = builder as DartFileEditBuilderImpl;
-      });
-    }
-
-    return DartFileEditBuilderImpl(this, result, timeStamp, libraryEditBuilder);
+  Future<DartFileEditBuilderImpl> createGenericFileEditBuilder(
+      String path) async {
+    return super.createDartFileEditBuilder(path);
   }
 }
 
@@ -922,10 +892,12 @@
       }
     } else if (expression is IndexExpression) {
       name = _getBaseNameFromExpression(expression.realTarget);
-      if (name.endsWith('es')) {
-        name = name.substring(0, name.length - 2);
-      } else if (name.endsWith('s')) {
-        name = name.substring(0, name.length - 1);
+      if (name != null) {
+        if (name.endsWith('es')) {
+          name = name.substring(0, name.length - 2);
+        } else if (name.endsWith('s')) {
+          name = name.substring(0, name.length - 1);
+        }
       }
     }
     // strip known prefixes
@@ -1207,8 +1179,8 @@
   /// Initialize a newly created builder to build a source file edit within the
   /// change being built by the given [changeBuilder]. The file being edited has
   /// the given [resolvedUnit] and [timeStamp].
-  DartFileEditBuilderImpl(DartChangeBuilderImpl changeBuilder,
-      this.resolvedUnit, int timeStamp, this.libraryChangeBuilder)
+  DartFileEditBuilderImpl(ChangeBuilderImpl changeBuilder, this.resolvedUnit,
+      int timeStamp, this.libraryChangeBuilder)
       : super(changeBuilder, resolvedUnit.path, timeStamp);
 
   @override
@@ -1686,24 +1658,3 @@
         other.prefix == prefix;
   }
 }
-
-/// Workspace that wraps a single [AnalysisSession].
-class _SingleSessionWorkspace extends ChangeWorkspace {
-  final AnalysisSession session;
-
-  _SingleSessionWorkspace(this.session);
-
-  @override
-  bool containsFile(String path) {
-    var analysisContext = session.analysisContext;
-    return analysisContext.contextRoot.isAnalyzed(path);
-  }
-
-  @override
-  AnalysisSession getSession(String path) {
-    if (containsFile(path)) {
-      return session;
-    }
-    throw StateError('Not in a context root: $path');
-  }
-}
diff --git a/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_core.dart b/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_core.dart
index 2d2fa0e..7dd762e 100644
--- a/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_core.dart
+++ b/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_core.dart
@@ -4,32 +4,58 @@
 
 import 'dart:async';
 
+import 'package:analyzer/dart/analysis/session.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_core.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_workspace.dart';
 
 /// A builder used to build a [SourceChange].
 ///
 /// Clients may not extend, implement or mix-in this class.
 abstract class ChangeBuilder {
-  /// Initialize a newly created change builder.
-  factory ChangeBuilder() = ChangeBuilderImpl;
+  /// Initialize a newly created change builder. If the builder will be used to
+  /// create changes for Dart files, then either a [session] or a [workspace]
+  /// must be provided (but not both).
+  factory ChangeBuilder({AnalysisSession session, ChangeWorkspace workspace}) =
+      ChangeBuilderImpl;
 
   /// Return the range of the selection for the change being built, or `null` if
   /// there is no selection.
   SourceRange get selectionRange;
 
   /// Return the source change that was built. The source change will not be
-  /// complete until all of the futures returned by [addFileEdit] have
-  /// completed.
+  /// complete until all of the futures returned by the add*FileEdit methods
+  /// have completed.
   SourceChange get sourceChange;
 
   /// Use the [buildFileEdit] function to create a collection of edits to the
   /// file with the given [path]. The edits will be added to the source change
   /// that is being built.
+  ///
+  /// The builder passed to the [buildFileEdit] function has additional support
+  /// for working with Dart source files.
+  Future<void> addDartFileEdit(
+      String path, void Function(DartFileEditBuilder builder) buildFileEdit,
+      {ImportPrefixGenerator importPrefixGenerator});
+
+  /// Use the [buildFileEdit] function to create a collection of edits to the
+  /// file with the given [path]. The edits will be added to the source change
+  /// that is being built.
+  @Deprecated('Use either addDartFileEdit or addGenericFileEdit')
   Future<void> addFileEdit(
       String path, void Function(FileEditBuilder builder) buildFileEdit);
 
+  /// Use the [buildFileEdit] function to create a collection of edits to the
+  /// file with the given [path]. The edits will be added to the source change
+  /// that is being built.
+  ///
+  /// The builder passed to the [buildFileEdit] function has no special support
+  /// for any particular kind of file.
+  Future<void> addGenericFileEdit(
+      String path, void Function(FileEditBuilder builder) buildFileEdit);
+
   /// Set the selection for the change being built to the given [position].
   void setSelection(Position position);
 }
diff --git a/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_dart.dart b/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_dart.dart
index 15ba518..1da71f5 100644
--- a/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_dart.dart
+++ b/pkg/analyzer_plugin/lib/utilities/change_builder/change_builder_dart.dart
@@ -19,10 +19,10 @@
 /// A [ChangeBuilder] used to build changes in Dart files.
 ///
 /// Clients may not extend, implement or mix-in this class.
+@Deprecated('Use ChangeBuilder')
 abstract class DartChangeBuilder implements ChangeBuilder {
   /// Initialize a newly created change builder.
-  ///
-  /// TODO(scheglov) Replace this constructor with using workspace.
+  @Deprecated('Use ChangeBuilder(session: session)')
   factory DartChangeBuilder(AnalysisSession session) = DartChangeBuilderImpl;
 
   /// Use the [buildFileEdit] function to create a collection of edits to the
@@ -31,6 +31,7 @@
   ///
   /// If [importPrefixGenerator] is provided, it will be asked to generate an
   /// import prefix for every newly imported library.
+  @Deprecated('Use ChangeBuilder.addDartFileEdit')
   @override
   Future<void> addFileEdit(
       String path, void Function(DartFileEditBuilder builder) buildFileEdit,
diff --git a/pkg/analyzer_plugin/lib/utilities/completion/relevance.dart b/pkg/analyzer_plugin/lib/utilities/completion/relevance.dart
index db06369..3d9bbd2 100644
--- a/pkg/analyzer_plugin/lib/utilities/completion/relevance.dart
+++ b/pkg/analyzer_plugin/lib/utilities/completion/relevance.dart
@@ -101,9 +101,5 @@
 
   /// The relevance boost used when suggesting an enum constant from an
   /// available declaration set.
-  static const int availableEnumConstant = 100;
-
-  /// The relevance boost used when suggesting a constant value / constructor
-  /// from an available declaration set in a constant context.
-  static const int constInConstantContext = 200;
+  static const int availableEnumConstant = 250;
 }
diff --git a/pkg/analyzer_plugin/pubspec.yaml b/pkg/analyzer_plugin/pubspec.yaml
index 85b313d3..df17df9 100644
--- a/pkg/analyzer_plugin/pubspec.yaml
+++ b/pkg/analyzer_plugin/pubspec.yaml
@@ -1,6 +1,6 @@
 name: analyzer_plugin
 description: A framework and support code for building plugins for the analysis server.
-version: 0.2.4
+version: 0.3.0
 author: Dart Team <misc@dartlang.org>
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/analyzer_plugin
 
@@ -8,7 +8,7 @@
   sdk: '>=2.3.0 <3.0.0'
 
 dependencies:
-  analyzer: '^0.39.0'
+  analyzer: '^0.39.12'
   charcode: '^1.1.0'
   dart_style: '^1.2.0'
   html: '>=0.13.1 <0.15.0'
diff --git a/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_core_test.dart b/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_core_test.dart
index 866a7a2..711cf55 100644
--- a/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_core_test.dart
+++ b/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_core_test.dart
@@ -23,7 +23,7 @@
   Future<void> test_createFileEditBuilder() async {
     var builder = ChangeBuilderImpl();
     var path = '/test.dart';
-    var fileEditBuilder = await builder.createFileEditBuilder(path);
+    var fileEditBuilder = await builder.createGenericFileEditBuilder(path);
     expect(fileEditBuilder, const TypeMatcher<FileEditBuilder>());
     var fileEdit = fileEditBuilder.fileEdit;
     expect(fileEdit.file, path);
@@ -46,7 +46,7 @@
   void test_sourceChange_emptyEdit() async {
     var builder = ChangeBuilderImpl();
     var path = '/test.dart';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {});
+    await builder.addGenericFileEdit(path, (builder) {});
     var sourceChange = builder.sourceChange;
     expect(sourceChange, isNotNull);
     expect(sourceChange.edits, isEmpty);
@@ -68,7 +68,7 @@
   Future<void> test_sourceChange_oneChange() async {
     var builder = ChangeBuilderImpl();
     var path = '/test.dart';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addSimpleInsertion(0, '_');
     });
     builder.getLinkedEditGroup('a');
@@ -89,9 +89,9 @@
     var builder = ChangeBuilderImpl();
     var offset = 10;
     var text = 'content';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
-        builder.addLinkedEdit('a', (LinkedEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
+        builder.addLinkedEdit('a', (builder) {
           builder.write(text);
         });
         var sourceEdit = (builder as EditBuilderImpl).sourceEdit;
@@ -114,8 +114,8 @@
     var builder = ChangeBuilderImpl();
     var offset = 10;
     var text = 'content';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
         builder.addSimpleLinkedEdit('a', text);
         var sourceEdit = (builder as EditBuilderImpl).sourceEdit;
         expect(sourceEdit.replacement, text);
@@ -135,8 +135,8 @@
 
   Future<void> test_createLinkedEditBuilder() async {
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
         var linkBuilder =
             (builder as EditBuilderImpl).createLinkedEditBuilder();
         expect(linkBuilder, const TypeMatcher<LinkedEditBuilder>());
@@ -146,7 +146,7 @@
 
   Future<void> test_selectHere() async {
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addInsertion(10, (EditBuilder builder) {
         builder.selectHere();
       });
@@ -158,8 +158,8 @@
     var builder = ChangeBuilderImpl();
     var offset = 10;
     var text = 'write';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(offset, (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(offset, (builder) {
         builder.write(text);
       });
     });
@@ -186,9 +186,8 @@
     var builder = ChangeBuilderImpl();
     var offset = 52;
     var length = 12;
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addReplacement(SourceRange(offset, length),
-          (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addReplacement(SourceRange(offset, length), (builder) {
         builder.writeln();
       });
     });
@@ -216,9 +215,8 @@
     var offset = 52;
     var length = 12;
     var text = 'writeln';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addReplacement(SourceRange(offset, length),
-          (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addReplacement(SourceRange(offset, length), (builder) {
         builder.writeln(text);
       });
     });
@@ -251,7 +249,7 @@
     var offset = 23;
     var length = 7;
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addDeletion(SourceRange(offset, length));
     });
     var edits = builder.sourceChange.edits[0].edits;
@@ -263,8 +261,8 @@
 
   Future<void> test_addInsertion() async {
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
         expect(builder, isNotNull);
       });
     });
@@ -273,7 +271,7 @@
   Future<void> test_addLinkedPosition() async {
     var builder = ChangeBuilderImpl();
     var groupName = 'a';
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addLinkedPosition(SourceRange(3, 6), groupName);
     });
 
@@ -288,8 +286,8 @@
 
   Future<void> test_addReplacement() async {
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addReplacement(SourceRange(4, 5), (EditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addReplacement(SourceRange(4, 5), (builder) {
         expect(builder, isNotNull);
       });
     });
@@ -299,7 +297,7 @@
     var offset = 23;
     var text = 'xyz';
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addSimpleInsertion(offset, text);
     });
     var edits = builder.sourceChange.edits[0].edits;
@@ -314,7 +312,7 @@
     var length = 7;
     var text = 'xyz';
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       builder.addSimpleReplacement(SourceRange(offset, length), text);
     });
     var edits = builder.sourceChange.edits[0].edits;
@@ -326,7 +324,7 @@
 
   Future<void> test_createEditBuilder() async {
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
       var offset = 4;
       var length = 5;
       var editBuilder =
@@ -347,9 +345,9 @@
   Future<void> test_addSuggestion() async {
     var groupName = 'a';
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
-        builder.addLinkedEdit(groupName, (LinkedEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
+        builder.addLinkedEdit(groupName, (builder) {
           builder.write('A');
           builder.addSuggestion(LinkedEditSuggestionKind.TYPE, 'B');
         });
@@ -363,9 +361,9 @@
   Future<void> test_addSuggestion_zeroLength() async {
     var groupName = 'a';
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
-        builder.addLinkedEdit(groupName, (LinkedEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
+        builder.addLinkedEdit(groupName, (builder) {
           builder.addSuggestion(LinkedEditSuggestionKind.TYPE, 'A');
         });
       });
@@ -377,9 +375,9 @@
   Future<void> test_addSuggestions() async {
     var groupName = 'a';
     var builder = ChangeBuilderImpl();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(10, (EditBuilder builder) {
-        builder.addLinkedEdit(groupName, (LinkedEditBuilder builder) {
+    await builder.addGenericFileEdit(path, (builder) {
+      builder.addInsertion(10, (builder) {
+        builder.addLinkedEdit(groupName, (builder) {
           builder.write('A');
           builder.addSuggestions(LinkedEditSuggestionKind.TYPE, ['B', 'C']);
         });
diff --git a/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_dart_test.dart b/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_dart_test.dart
index 86904fb..3c84ed8 100644
--- a/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_dart_test.dart
+++ b/pkg/analyzer_plugin/test/src/utilities/change_builder/change_builder_dart_test.dart
@@ -12,9 +12,8 @@
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer/src/test_utilities/find_node.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart'
+    show DartLinkedEditBuilderImpl;
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -23,7 +22,6 @@
 
 void main() {
   defineReflectiveSuite(() {
-    defineReflectiveTests(DartChangeBuilderImplTest);
     defineReflectiveTests(DartEditBuilderImplTest);
     defineReflectiveTests(DartFileEditBuilderImplTest);
     defineReflectiveTests(DartLinkedEditBuilderImplTest);
@@ -33,20 +31,6 @@
 }
 
 @reflectiveTest
-class DartChangeBuilderImplTest extends AbstractContextTest
-    with DartChangeBuilderMixin {
-  Future<void> test_createFileEditBuilder() async {
-    var path = convertPath('/home/test/lib/test.dart');
-    addSource(path, 'library test;');
-    var builder = newBuilder();
-    var fileEditBuilder = await builder.createFileEditBuilder(path);
-    expect(fileEditBuilder, const TypeMatcher<DartFileEditBuilder>());
-    var fileEdit = fileEditBuilder.fileEdit;
-    expect(fileEdit.file, path);
-  }
-}
-
-@reflectiveTest
 class DartEditBuilderImplTest extends AbstractContextTest
     with DartChangeBuilderMixin {
   Future<void> test_writeClassDeclaration_interfaces() async {
@@ -55,10 +39,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeClassDeclaration('C', interfaces: [typeA]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', interfaces: [typeA]);
       });
     });
     var edit = getEdit(builder);
@@ -71,10 +54,9 @@
     addSource(path, '');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeClassDeclaration('C', isAbstract: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', isAbstract: true);
       });
     });
     var edit = getEdit(builder);
@@ -86,10 +68,9 @@
     addSource(path, '');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeClassDeclaration('C',
-            membersWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', membersWriter: () {
           builder.write('/**/');
         });
       });
@@ -104,10 +85,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeClassDeclaration('C', mixins: [typeA]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', mixins: [typeA]);
       });
     });
     var edit = getEdit(builder);
@@ -122,10 +102,9 @@
     DartType typeB = await _getType(path, 'B');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeClassDeclaration('C', mixins: [typeB], superclass: typeA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', mixins: [typeB], superclass: typeA);
       });
     });
     var edit = getEdit(builder);
@@ -138,10 +117,9 @@
     addSource(path, '');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeClassDeclaration('C', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -160,9 +138,9 @@
     DartType typeB = await _getType(path, 'B');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeClassDeclaration('C',
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeClassDeclaration('C',
             superclass: typeB, superclassGroupName: 'superclass');
       });
     });
@@ -181,8 +159,8 @@
     addSource(path, 'class C {}');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(9, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(9, (builder) {
         builder.writeConstructorDeclaration('A', bodyWriter: () {
           builder.write(' { print(42); }');
         });
@@ -202,8 +180,8 @@
 ''');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(42, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(42, (builder) {
         builder.writeConstructorDeclaration('A', fieldNames: ['a', 'bb']);
       });
     });
@@ -216,8 +194,8 @@
     addSource(path, 'class C {}');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(9, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(9, (builder) {
         builder.writeConstructorDeclaration('A', initializerWriter: () {
           builder.write('super()');
         });
@@ -232,8 +210,8 @@
     addSource(path, 'class C {}');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(9, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(9, (builder) {
         builder.writeConstructorDeclaration('A', parameterWriter: () {
           builder.write('int a, {this.b}');
         });
@@ -249,10 +227,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFieldDeclaration('f',
-            initializerWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', initializerWriter: () {
           builder.write('e');
         });
       });
@@ -267,9 +244,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFieldDeclaration('f', isConst: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isConst: true);
       });
     });
     var edit = getEdit(builder);
@@ -282,10 +259,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFieldDeclaration('f', isConst: true, isFinal: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isConst: true, isFinal: true);
       });
     });
     var edit = getEdit(builder);
@@ -299,10 +275,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFieldDeclaration('f', isConst: true, type: typeA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isConst: true, type: typeA);
       });
     });
     var edit = getEdit(builder);
@@ -315,9 +290,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFieldDeclaration('f', isFinal: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isFinal: true);
       });
     });
     var edit = getEdit(builder);
@@ -331,10 +306,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFieldDeclaration('f', isFinal: true, type: typeA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isFinal: true, type: typeA);
       });
     });
     var edit = getEdit(builder);
@@ -347,9 +321,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFieldDeclaration('f', isStatic: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', isStatic: true);
       });
     });
     var edit = getEdit(builder);
@@ -362,10 +336,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFieldDeclaration('f', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -387,10 +360,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFieldDeclaration('f', type: typeA, typeGroupName: 'type');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeFieldDeclaration('f', type: typeA, typeGroupName: 'type');
       });
     });
     var edit = getEdit(builder);
@@ -412,10 +384,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFunctionDeclaration('fib',
-            bodyWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeFunctionDeclaration('fib', bodyWriter: () {
           builder.write('{ ... }');
         });
       });
@@ -431,10 +402,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeFunctionDeclaration('fib', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeFunctionDeclaration('fib', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -454,10 +424,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFunctionDeclaration('fib',
-            parameterWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeFunctionDeclaration('fib', parameterWriter: () {
           builder.write('p, q, r');
         });
       });
@@ -475,9 +444,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeFunctionDeclaration('fib',
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeFunctionDeclaration('fib',
             returnType: typeA, returnTypeGroupName: 'type');
       });
     });
@@ -497,10 +466,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeGetterDeclaration('g',
-            bodyWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeGetterDeclaration('g', bodyWriter: () {
           builder.write('{}');
         });
       });
@@ -515,10 +483,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeGetterDeclaration('g', isStatic: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeGetterDeclaration('g', isStatic: true);
       });
     });
     var edit = getEdit(builder);
@@ -531,10 +498,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeGetterDeclaration('g', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeGetterDeclaration('g', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -556,9 +522,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeGetterDeclaration('g',
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeGetterDeclaration('g',
             returnType: typeA, returnTypeGroupName: 'returnType');
       });
     });
@@ -584,10 +550,9 @@
     await driver.getResult(path);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeLocalVariableDeclaration('foo',
-            initializerWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration('foo', initializerWriter: () {
           builder.write('null');
         });
       });
@@ -606,10 +571,9 @@
     await driver.getResult(path);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeLocalVariableDeclaration('foo', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration('foo', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -633,10 +597,9 @@
     await driver.getResult(path);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeLocalVariableDeclaration('foo', isConst: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration('foo', isConst: true);
       });
     });
     var edit = getEdit(builder);
@@ -654,10 +617,9 @@
     await driver.getResult(path);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeLocalVariableDeclaration('foo', isFinal: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration('foo', isFinal: true);
       });
     });
     var edit = getEdit(builder);
@@ -677,9 +639,9 @@
     var A = unit.declarations[1] as ClassDeclaration;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeLocalVariableDeclaration(
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration(
           'foo',
           initializerWriter: () {
             builder.write('null');
@@ -708,9 +670,9 @@
     var A = unit.declarations[1] as ClassDeclaration;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeLocalVariableDeclaration(
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration(
           'foo',
           type: A.declaredElement.instantiate(
             typeArguments: [],
@@ -744,9 +706,9 @@
     var A = unit.declarations[1] as ClassDeclaration;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(11, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeLocalVariableDeclaration(
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(11, (builder) {
+        builder.writeLocalVariableDeclaration(
           'foo',
           isFinal: true,
           type: A.declaredElement.instantiate(
@@ -773,10 +735,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeMixinDeclaration('M', interfaces: [typeA]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeMixinDeclaration('M', interfaces: [typeA]);
       });
     });
     var edit = getEdit(builder);
@@ -792,9 +753,9 @@
     DartType typeB = await _getType(path, 'B');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeMixinDeclaration('M',
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeMixinDeclaration('M',
             interfaces: [typeA], superclassConstraints: [typeB]);
       });
     });
@@ -808,10 +769,9 @@
     addSource(path, '');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeMixinDeclaration('M',
-            membersWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeMixinDeclaration('M', membersWriter: () {
           builder.write('/**/');
         });
       });
@@ -825,10 +785,9 @@
     addSource(path, '');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeMixinDeclaration('M', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeMixinDeclaration('M', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -847,10 +806,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(0, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeMixinDeclaration('M', superclassConstraints: [typeA]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(0, (builder) {
+        builder.writeMixinDeclaration('M', superclassConstraints: [typeA]);
       });
     });
     var edit = getEdit(builder);
@@ -863,9 +821,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeParameter('a');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParameter('a');
       });
     });
     var edit = getEdit(builder);
@@ -879,9 +837,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeParameter('a', type: typeA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParameter('a', type: typeA);
       });
     });
     var edit = getEdit(builder);
@@ -906,10 +864,9 @@
     var argument = invocation.argumentList.arguments[0];
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(2, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeParameterMatchingArgument(argument, 0, <String>{});
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(2, (builder) {
+        builder.writeParameterMatchingArgument(argument, 0, <String>{});
       });
     });
     var edit = getEdit(builder);
@@ -927,9 +884,9 @@
     var elements = parameters.parameters.map((p) => p.declaredElement);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeParameters(elements);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParameters(elements);
       });
     });
     var edit = getEdit(builder);
@@ -947,9 +904,9 @@
     var elements = parameters.parameters.map((p) => p.declaredElement);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeParameters(elements);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParameters(elements);
       });
     });
     var edit = getEdit(builder);
@@ -967,9 +924,9 @@
     var elements = parameters.parameters.map((p) => p.declaredElement);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeParameters(elements);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParameters(elements);
       });
     });
     var edit = getEdit(builder);
@@ -990,10 +947,9 @@
     var invocation = statement.expression as MethodInvocation;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeParametersMatchingArguments(invocation.argumentList);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParametersMatchingArguments(invocation.argumentList);
       });
     });
     var edit = getEdit(builder);
@@ -1014,10 +970,9 @@
     var invocation = statement.expression as MethodInvocation;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeParametersMatchingArguments(invocation.argumentList);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeParametersMatchingArguments(invocation.argumentList);
       });
     });
     var edit = getEdit(builder);
@@ -1042,8 +997,8 @@
     var fooElement = aElement.methods[0];
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         builder.writeReference(fooElement);
       });
     });
@@ -1064,8 +1019,8 @@
     var aElement = await _getTopLevelAccessorElement(aPath, 'a');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         builder.writeReference(aElement);
       });
     });
@@ -1086,8 +1041,8 @@
     var aElement = await _getTopLevelAccessorElement(aPath, 'a');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         builder.writeReference(aElement);
       });
     });
@@ -1106,8 +1061,8 @@
     var aElement = await _getTopLevelAccessorElement(aPath, 'a');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (DartEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         builder.writeReference(aElement);
       });
     });
@@ -1123,10 +1078,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeSetterDeclaration('s',
-            bodyWriter: () {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeSetterDeclaration('s', bodyWriter: () {
           builder.write('{/* TODO */}');
         });
       });
@@ -1141,10 +1095,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeSetterDeclaration('s', isStatic: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeSetterDeclaration('s', isStatic: true);
       });
     });
     var edit = getEdit(builder);
@@ -1157,10 +1110,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeSetterDeclaration('s', nameGroupName: 'name');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeSetterDeclaration('s', nameGroupName: 'name');
       });
     });
     var edit = getEdit(builder);
@@ -1182,9 +1134,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeSetterDeclaration('s',
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeSetterDeclaration('s',
             parameterType: typeA, parameterTypeGroupName: 'returnType');
       });
     });
@@ -1207,10 +1159,10 @@
     var unit = (await driver.getResult(path))?.unit;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         var typeProvider = unit.declaredElement.library.typeProvider;
-        (builder as DartEditBuilder).writeType(typeProvider.dynamicType);
+        builder.writeType(typeProvider.dynamicType);
       });
     });
     var edit = getEdit(builder);
@@ -1249,9 +1201,9 @@
     var typeBofA = await _getType(path, 'B', typeArguments: [typeA]);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(typeBofA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(typeBofA);
       });
     });
     var edit = getEdit(builder);
@@ -1265,9 +1217,9 @@
     DartType typeC = await _getType(path, 'C');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(typeC, groupName: 'type');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(typeC, groupName: 'type');
       });
     });
     var edit = getEdit(builder);
@@ -1286,10 +1238,10 @@
     DartType typeC = await _getType(path, 'C');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder)
-            .writeType(typeC, addSupertypeProposals: true, groupName: 'type');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(typeC,
+            addSupertypeProposals: true, groupName: 'type');
       });
     });
     var edit = getEdit(builder);
@@ -1321,7 +1273,7 @@
     );
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       builder.addInsertion(content.length, (builder) {
         // "T" cannot be written, because we are outside of "A".
         // So, we also should not create linked groups.
@@ -1345,9 +1297,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(null);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(null);
       });
     });
     var edit = getEdit(builder);
@@ -1380,7 +1332,7 @@
     }
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       builder.addInsertion(content.length - 1, (builder) {
         builder.writeType(a1.instantiate(
           typeArguments: [],
@@ -1420,11 +1372,10 @@
     var unit = (await driver.getResult(path))?.unit;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
         var typeProvider = unit.declaredElement.library.typeProvider;
-        (builder as DartEditBuilder)
-            .writeType(typeProvider.dynamicType, required: true);
+        builder.writeType(typeProvider.dynamicType, required: true);
       });
     });
     var edit = getEdit(builder);
@@ -1438,9 +1389,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(typeA, required: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(typeA, required: true);
       });
     });
     var edit = getEdit(builder);
@@ -1453,9 +1404,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(null, required: true);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(null, required: true);
       });
     });
     var edit = getEdit(builder);
@@ -1469,9 +1420,9 @@
     DartType typeA = await _getType(path, 'A');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeType(typeA);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeType(typeA);
       });
     });
     var edit = getEdit(builder);
@@ -1493,9 +1444,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilderImpl).writeTypes([]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeTypes([]);
       });
     });
     var edit = getEdit(builder);
@@ -1510,9 +1461,9 @@
     DartType typeB = await _getType(path, 'B');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilderImpl).writeTypes([typeA, typeB]);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeTypes([typeA, typeB]);
       });
     });
     var edit = getEdit(builder);
@@ -1525,9 +1476,9 @@
     addSource(path, content);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilderImpl).writeTypes(null);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeTypes(null);
       });
     });
     var edit = getEdit(builder);
@@ -1542,10 +1493,9 @@
     DartType typeB = await _getType(path, 'B');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 1, (EditBuilder builder) {
-        (builder as DartEditBuilderImpl)
-            .writeTypes([typeA, typeB], prefix: 'implements ');
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 1, (builder) {
+        builder.writeTypes([typeA, typeB], prefix: 'implements ');
       });
     });
     var edit = getEdit(builder);
@@ -1560,7 +1510,7 @@
     var f = await _getTopLevelAccessorElement(path, 'v');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       builder.addInsertion(content.length - 1, (builder) {
         builder.writeType(f.returnType);
       });
@@ -1605,9 +1555,8 @@
     var body = findNode.functionBody('{}');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      (builder as DartFileEditBuilder)
-          .convertFunctionFromSyncToAsync(body, resolvedUnit.typeProvider);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.convertFunctionFromSyncToAsync(body, resolvedUnit.typeProvider);
     });
     var edits = getEdits(builder);
     expect(edits, hasLength(1));
@@ -1623,9 +1572,8 @@
     var body = findNode.functionBody('{}');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      (builder as DartFileEditBuilder)
-          .convertFunctionFromSyncToAsync(body, resolvedUnit.typeProvider);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.convertFunctionFromSyncToAsync(body, resolvedUnit.typeProvider);
     });
     var edits = getEdits(builder);
     expect(edits, hasLength(2));
@@ -1633,23 +1581,6 @@
     expect(edits[1].replacement, equalsIgnoringWhitespace('Future<String>'));
   }
 
-  Future<void> test_createEditBuilder() async {
-    var path = convertPath('/home/test/lib/test.dart');
-    addSource(path, 'library test;');
-    var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      var offset = 4;
-      var length = 5;
-      var editBuilder = (builder as DartFileEditBuilderImpl)
-          .createEditBuilder(offset, length);
-      expect(editBuilder, const TypeMatcher<DartEditBuilder>());
-      var sourceEdit = editBuilder.sourceEdit;
-      expect(sourceEdit.length, length);
-      expect(sourceEdit.offset, offset);
-      expect(sourceEdit.replacement, isEmpty);
-    });
-  }
-
   Future<void> test_format_hasEdits() async {
     var initialCode = r'''
 void functionBefore() {
@@ -1670,7 +1601,7 @@
     newFile(path, content: initialCode);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       builder.addInsertion(34, (builder) {
         builder.writeln('  3 +  4;');
       });
@@ -1722,7 +1653,7 @@
     newFile(path, content: initialCode);
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       builder.format(SourceRange(37, 39));
     });
 
@@ -1754,9 +1685,8 @@
     var type = findNode.typeAnnotation('String');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      (builder as DartFileEditBuilder)
-          .replaceTypeWithFuture(type, resolvedUnit.typeProvider);
+    await builder.addDartFileEdit(path, (builder) {
+      builder.replaceTypeWithFuture(type, resolvedUnit.typeProvider);
     });
     var edits = getEdits(builder);
     expect(edits, hasLength(1));
@@ -2237,7 +2167,7 @@
     var path = convertPath('/home/test/lib/test.dart');
     addSource(path, initialCode);
     var builder = newBuilder();
-    await builder.addFileEdit(path, (DartFileEditBuilder builder) {
+    await builder.addDartFileEdit(path, (builder) {
       for (var i = 0; i < uriList.length; ++i) {
         var uri = Uri.parse(uriList[i]);
         builder.importLibrary(uri);
@@ -2812,9 +2742,9 @@
     var displayBuffer = displayText != null ? StringBuffer() : null;
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (FileEditBuilder builder) {
-      builder.addInsertion(content.length - 2, (EditBuilder builder) {
-        (builder as DartEditBuilder).writeOverride(
+    await builder.addDartFileEdit(path, (builder) {
+      builder.addInsertion(content.length - 2, (builder) {
+        builder.writeOverride(
           inherited,
           displayTextBuffer: displayBuffer,
           invokeSuper: invokeSuper,
diff --git a/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/dart_change_builder_mixin.dart b/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/dart_change_builder_mixin.dart
index 91e9152..9bff4bb 100644
--- a/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/dart_change_builder_mixin.dart
+++ b/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/dart_change_builder_mixin.dart
@@ -3,20 +3,19 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
-import 'package:analyzer_plugin/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:test/test.dart';
 
 import '../../../../support/abstract_context.dart';
 
 mixin DartChangeBuilderMixin implements AbstractContextTest {
-  SourceEdit getEdit(DartChangeBuilder builder) {
+  SourceEdit getEdit(ChangeBuilder builder) {
     var edits = getEdits(builder);
     expect(edits, hasLength(1));
     return edits[0];
   }
 
-  List<SourceEdit> getEdits(DartChangeBuilder builder) {
+  List<SourceEdit> getEdits(ChangeBuilder builder) {
     var sourceChange = builder.sourceChange;
     expect(sourceChange, isNotNull);
 
@@ -29,6 +28,5 @@
   }
 
   /// Return a newly created Dart change builder.
-  DartChangeBuilderImpl newBuilder() =>
-      DartChangeBuilder(session) as DartChangeBuilderImpl;
+  ChangeBuilder newBuilder() => ChangeBuilder(session: session);
 }
diff --git a/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/import_library_element_test.dart b/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/import_library_element_test.dart
index 6f04e0f..f108f1c 100644
--- a/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/import_library_element_test.dart
+++ b/pkg/analyzer_plugin/test/src/utilities/change_builder/dart/import_library_element_test.dart
@@ -5,7 +5,7 @@
 import 'dart:async';
 
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
-import 'package:analyzer_plugin/src/utilities/change_builder/change_builder_dart.dart';
+import 'package:analyzer_plugin/utilities/change_builder/change_builder_core.dart';
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
 
@@ -446,7 +446,7 @@
 }
 
 class _Base extends AbstractContextTest with DartChangeBuilderMixin {
-  void _assertEmptyChange(DartChangeBuilderImpl builder) {
+  void _assertEmptyChange(ChangeBuilder builder) {
     var change = builder.sourceChange;
     expect(change, isNotNull);
     expect(change.edits, isEmpty);
@@ -474,7 +474,7 @@
     expect(requestedElement, isNotNull, reason: '`$name` in $uriStr');
 
     var builder = newBuilder();
-    await builder.addFileEdit(path, (builder) {
+    await builder.addDartFileEdit(path, (builder) {
       var uri = Uri.parse(uriStr);
       var result = builder.importLibraryElement(uri);
       expect(result.prefix, expectedPrefix);
diff --git a/pkg/dev_compiler/LICENSE.md b/pkg/build_integration/LICENSE
similarity index 83%
copy from pkg/dev_compiler/LICENSE.md
copy to pkg/build_integration/LICENSE
index bab6a8c..c4dc9ba 100644
--- a/pkg/dev_compiler/LICENSE.md
+++ b/pkg/build_integration/LICENSE
@@ -1,13 +1,4 @@
-This license applies to all files contained here with the following
-exceptions:
-
-- All code in test/js_test_tools is externally maintained with
-  corresponding licenses in those individual files and directories.
-
----
-
-Copyright 2015, the Dart project authors. All rights reserved.
-
+Copyright 2018, the Dart project authors. All rights reserved.
 Redistribution and use in source and binary forms, with or without
 modification, are permitted provided that the following conditions are
 met:
diff --git a/pkg/compiler/lib/src/commandline_options.dart b/pkg/compiler/lib/src/commandline_options.dart
index 563d438..d508b6b 100644
--- a/pkg/compiler/lib/src/commandline_options.dart
+++ b/pkg/compiler/lib/src/commandline_options.dart
@@ -28,6 +28,8 @@
   static const String experimentalAllocationsPath =
       '--experimental-allocations-path';
 
+  static const String experimentalPowersets = '--experimental-powersets';
+
   // Temporary experiment for code generation of locals for frequently used
   // 'this' and constants.
   static const String experimentLocalNames = '--experiment-code-1';
diff --git a/pkg/compiler/lib/src/compiler.dart b/pkg/compiler/lib/src/compiler.dart
index 7e909f2..5bb3660 100644
--- a/pkg/compiler/lib/src/compiler.dart
+++ b/pkg/compiler/lib/src/compiler.dart
@@ -135,9 +135,11 @@
     options.deriveOptions();
     options.validate();
 
-    abstractValueStrategy = options.useTrivialAbstractValueDomain
-        ? const TrivialAbstractValueStrategy()
-        : const TypeMaskStrategy();
+    abstractValueStrategy = options.experimentalPowersets
+        ? throw UnimplementedError('Powerset abstract value domain')
+        : options.useTrivialAbstractValueDomain
+            ? const TrivialAbstractValueStrategy()
+            : const TypeMaskStrategy();
     CompilerTask kernelFrontEndTask;
     selfTask = new GenericTask('self', measurer);
     _outputProvider = new _CompilerOutput(this, outputProvider);
diff --git a/pkg/compiler/lib/src/constants/constant_system.dart b/pkg/compiler/lib/src/constants/constant_system.dart
index afbb8f4..11ac356 100644
--- a/pkg/compiler/lib/src/constants/constant_system.dart
+++ b/pkg/compiler/lib/src/constants/constant_system.dart
@@ -40,6 +40,7 @@
 const truncatingDivide = const TruncatingDivideOperation();
 const codeUnitAt = const CodeUnitAtOperation();
 const round = const RoundOperation();
+const toInt = const ToIntOperation();
 const abs = const UnfoldedUnaryOperation('abs');
 
 /// Returns true if [value] will turn into NaN or infinity
@@ -959,6 +960,32 @@
   }
 }
 
+class ToIntOperation implements UnaryOperation {
+  @override
+  final String name = 'toInt';
+
+  const ToIntOperation();
+
+  @override
+  ConstantValue fold(ConstantValue constant) {
+    if (constant is IntConstantValue) {
+      double value = constant.doubleValue;
+      // The code below is written to work for any `double`, even though
+      // IntConstantValue uses `BigInt`.
+      // TODO(sra): IntConstantValue should wrap a `double` since we consider
+      // infinities and negative zero to be `is int`.
+      if (!value.isFinite) return null;
+      // Ensure `(-0.0).toInt()` --> `0`.
+      if (value == 0) return createIntFromInt(0);
+      return constant;
+    }
+    // TODO(sra): Handle doubles. Note that integral-valued doubles are
+    // canonicalized to IntConstantValue, so we are only missing `toInt()`
+    // operations that truncate.
+    return null;
+  }
+}
+
 class UnfoldedUnaryOperation implements UnaryOperation {
   @override
   final String name;
diff --git a/pkg/compiler/lib/src/dart2js.dart b/pkg/compiler/lib/src/dart2js.dart
index 22bd612..ac41334 100644
--- a/pkg/compiler/lib/src/dart2js.dart
+++ b/pkg/compiler/lib/src/dart2js.dart
@@ -445,6 +445,7 @@
     new OptionHandler(Flags.disableProgramSplit, passThrough),
     new OptionHandler(Flags.disableTypeInference, passThrough),
     new OptionHandler(Flags.useTrivialAbstractValueDomain, passThrough),
+    new OptionHandler(Flags.experimentalPowersets, passThrough),
     new OptionHandler(Flags.disableRtiOptimization, passThrough),
     new OptionHandler(Flags.terse, passThrough),
     new OptionHandler('--deferred-map=.+', passThrough),
diff --git a/pkg/compiler/lib/src/diagnostics/messages.dart b/pkg/compiler/lib/src/diagnostics/messages.dart
index 33d7b23..db613ff 100644
--- a/pkg/compiler/lib/src/diagnostics/messages.dart
+++ b/pkg/compiler/lib/src/diagnostics/messages.dart
@@ -247,27 +247,6 @@
               """
           ]),
 
-      MessageKind.JS_INTEROP_METHOD_WITH_NAMED_ARGUMENTS: const MessageTemplate(
-          MessageKind.JS_INTEROP_METHOD_WITH_NAMED_ARGUMENTS,
-          "Js-interop method '#{method}' has named arguments but is not "
-          "a factory constructor of an @anonymous @JS class.",
-          howToFix: "Remove all named arguments from js-interop method or "
-              "in the case of a factory constructor annotate the class "
-              "as @anonymous.",
-          examples: const [
-            """
-              import 'package:js/js.dart';
-
-              @JS()
-              class Foo {
-                external bar(foo, {baz});
-              }
-
-              main() {
-                new Foo().bar(4, baz: 5);
-              }
-              """
-          ]),
       MessageKind.IMPLICIT_JS_INTEROP_FIELD_NOT_SUPPORTED:
           const MessageTemplate(
               MessageKind.IMPLICIT_JS_INTEROP_FIELD_NOT_SUPPORTED,
diff --git a/pkg/compiler/lib/src/elements/types.dart b/pkg/compiler/lib/src/elements/types.dart
index ce038a9..8ae41d3 100644
--- a/pkg/compiler/lib/src/elements/types.dart
+++ b/pkg/compiler/lib/src/elements/types.dart
@@ -2114,12 +2114,14 @@
                 String sName = sNamed[sIndex++];
                 int comparison = sName.compareTo(tName);
                 if (comparison > 0) return false;
-                bool sIsRequired = sRequiredNamed.contains(sName);
+                bool sIsRequired =
+                    !useLegacySubtyping && sRequiredNamed.contains(sName);
                 if (comparison < 0) {
                   if (sIsRequired) return false;
                   continue;
                 }
-                bool tIsRequired = tRequiredNamed.contains(tName);
+                bool tIsRequired =
+                    !useLegacySubtyping && tRequiredNamed.contains(tName);
                 if (sIsRequired && !tIsRequired) return false;
                 if (!_isSubtype(
                     tNamedTypes[tIndex], sNamedTypes[sIndex - 1], env))
@@ -2127,8 +2129,10 @@
                 break;
               }
             }
-            while (sIndex < sNamedLength) {
-              if (sRequiredNamed.contains(sNamed[sIndex++])) return false;
+            if (!useLegacySubtyping) {
+              while (sIndex < sNamedLength) {
+                if (sRequiredNamed.contains(sNamed[sIndex++])) return false;
+              }
             }
             return true;
           } finally {
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/constants.dart b/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
index 0994564..24626cd 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/constants.dart
@@ -10,19 +10,21 @@
 import 'masks.dart';
 
 /// Computes the [TypeMask] for the constant [value].
-TypeMask computeTypeMask(JClosedWorld closedWorld, ConstantValue value) {
-  return value.accept(const ConstantValueTypeMasks(), closedWorld);
+TypeMask computeTypeMask(CommonMasks abstractValueDomain,
+    JClosedWorld closedWorld, ConstantValue value) {
+  return value.accept(ConstantValueTypeMasks(abstractValueDomain), closedWorld);
 }
 
 class ConstantValueTypeMasks
     extends ConstantValueVisitor<TypeMask, JClosedWorld> {
-  const ConstantValueTypeMasks();
+  final CommonMasks _abstractValueDomain;
+  const ConstantValueTypeMasks(this._abstractValueDomain);
 
   @override
   TypeMask visitConstructed(
       ConstructedConstantValue constant, JClosedWorld closedWorld) {
     if (closedWorld.interceptorData.isInterceptedClass(constant.type.element)) {
-      return closedWorld.abstractValueDomain.nonNullType;
+      return _abstractValueDomain.nonNullType;
     }
     return new TypeMask.nonNullExact(constant.type.element, closedWorld);
   }
@@ -38,13 +40,13 @@
     // We have to recognize double constants that are 'is int'.
     if (constant_system.isInt(constant)) {
       if (constant.isMinusZero) {
-        return closedWorld.abstractValueDomain.uint31Type;
+        return _abstractValueDomain.uint31Type;
       } else {
         assert(constant.isPositiveInfinity || constant.isNegativeInfinity);
-        return closedWorld.abstractValueDomain.intType;
+        return _abstractValueDomain.intType;
       }
     }
-    return closedWorld.abstractValueDomain.doubleType;
+    return _abstractValueDomain.doubleType;
   }
 
   @override
@@ -56,79 +58,78 @@
   @override
   TypeMask visitUnreachable(
       UnreachableConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.emptyType;
+    return _abstractValueDomain.emptyType;
   }
 
   @override
   TypeMask visitJsName(JsNameConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.stringType;
+    return _abstractValueDomain.stringType;
   }
 
   @override
   TypeMask visitBool(BoolConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.boolType;
+    return _abstractValueDomain.boolType;
   }
 
   @override
   TypeMask visitFunction(
       FunctionConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.functionType;
+    return _abstractValueDomain.functionType;
   }
 
   @override
   TypeMask visitInstantiation(
       InstantiationConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.functionType;
+    return _abstractValueDomain.functionType;
   }
 
   @override
   TypeMask visitInt(IntConstantValue constant, JClosedWorld closedWorld) {
-    if (constant.isUInt31()) return closedWorld.abstractValueDomain.uint31Type;
-    if (constant.isUInt32()) return closedWorld.abstractValueDomain.uint32Type;
-    if (constant.isPositive())
-      return closedWorld.abstractValueDomain.positiveIntType;
-    return closedWorld.abstractValueDomain.intType;
+    if (constant.isUInt31()) return _abstractValueDomain.uint31Type;
+    if (constant.isUInt32()) return _abstractValueDomain.uint32Type;
+    if (constant.isPositive()) return _abstractValueDomain.positiveIntType;
+    return _abstractValueDomain.intType;
   }
 
   @override
   TypeMask visitInterceptor(
       InterceptorConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.nonNullType;
+    return _abstractValueDomain.nonNullType;
   }
 
   @override
   TypeMask visitList(ListConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.constListType;
+    return _abstractValueDomain.constListType;
   }
 
   @override
   TypeMask visitSet(SetConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.constSetType;
+    return _abstractValueDomain.constSetType;
   }
 
   @override
   TypeMask visitMap(MapConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.constMapType;
+    return _abstractValueDomain.constMapType;
   }
 
   @override
   TypeMask visitNull(NullConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.nullType;
+    return _abstractValueDomain.nullType;
   }
 
   @override
   TypeMask visitNonConstant(
       NonConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.nullType;
+    return _abstractValueDomain.nullType;
   }
 
   @override
   TypeMask visitString(StringConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.stringType;
+    return _abstractValueDomain.stringType;
   }
 
   @override
   TypeMask visitType(TypeConstantValue constant, JClosedWorld closedWorld) {
-    return closedWorld.abstractValueDomain.typeType;
+    return _abstractValueDomain.typeType;
   }
 }
diff --git a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
index 61b0825..b6944b1 100644
--- a/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
+++ b/pkg/compiler/lib/src/inferrer/typemasks/masks.dart
@@ -690,7 +690,7 @@
 
   @override
   AbstractValue computeAbstractValueForConstant(ConstantValue value) {
-    return computeTypeMask(_closedWorld, value);
+    return computeTypeMask(this, _closedWorld, value);
   }
 
   @override
diff --git a/pkg/compiler/lib/src/ir/impact_data.dart b/pkg/compiler/lib/src/ir/impact_data.dart
index 7276ae4..a76ff95 100644
--- a/pkg/compiler/lib/src/ir/impact_data.dart
+++ b/pkg/compiler/lib/src/ir/impact_data.dart
@@ -1363,30 +1363,11 @@
 }
 
 class _ConstInstantiation {
-  static const String tag = '_ConstInstantiation';
-
   final ir.Class cls;
   final List<ir.DartType> typeArguments;
   final ir.LibraryDependency import;
 
   _ConstInstantiation(this.cls, this.typeArguments, this.import);
-
-  factory _ConstInstantiation.fromDataSource(DataSource source) {
-    source.begin(tag);
-    ir.Class cls = source.readClassNode();
-    List<ir.DartType> typeArguments = source.readDartTypeNodes();
-    ir.LibraryDependency import = source.readLibraryDependencyNodeOrNull();
-    source.end(tag);
-    return new _ConstInstantiation(cls, typeArguments, import);
-  }
-
-  void toDataSink(DataSink sink) {
-    sink.begin(tag);
-    sink.writeClassNode(cls);
-    sink.writeDartTypeNodes(typeArguments);
-    sink.writeLibraryDependencyNodeOrNull(import);
-    sink.end(tag);
-  }
 }
 
 enum _Feature {
@@ -1620,8 +1601,6 @@
 }
 
 class _ForInData {
-  static const String tag = '_ForInData';
-
   final ir.DartType iterableType;
   final ir.DartType iteratorType;
   final ClassRelation iteratorClassRelation;
@@ -1629,23 +1608,4 @@
 
   _ForInData(this.iterableType, this.iteratorType, this.iteratorClassRelation,
       {this.isAsync});
-
-  factory _ForInData.fromDataSource(DataSource source) {
-    source.begin(tag);
-    ir.DartType iterableType = source.readDartTypeNode();
-    ir.DartType iteratorType = source.readDartTypeNode(allowNull: true);
-    ClassRelation iteratorClassRelation = source.readEnum(ClassRelation.values);
-    bool isAsync = source.readBool();
-    return new _ForInData(iterableType, iteratorType, iteratorClassRelation,
-        isAsync: isAsync);
-  }
-
-  void toDataSink(DataSink sink) {
-    sink.begin(tag);
-    sink.writeDartTypeNode(iterableType);
-    sink.writeDartTypeNode(iteratorType);
-    sink.writeEnum(iteratorClassRelation);
-    sink.writeBool(isAsync);
-    sink.end(tag);
-  }
 }
diff --git a/pkg/compiler/lib/src/ir/visitors.dart b/pkg/compiler/lib/src/ir/visitors.dart
index 6ff419b..bd1929e 100644
--- a/pkg/compiler/lib/src/ir/visitors.dart
+++ b/pkg/compiler/lib/src/ir/visitors.dart
@@ -130,12 +130,10 @@
             .skip(node.requiredParameterCount)
             .toList()),
         node.namedParameters.map((n) => n.name).toList(),
-        _options.useLegacySubtyping
-            ? const <String>{}
-            : node.namedParameters
-                .where((n) => n.isRequired)
-                .map((n) => n.name)
-                .toSet(),
+        node.namedParameters
+            .where((n) => n.isRequired)
+            .map((n) => n.name)
+            .toSet(),
         node.namedParameters.map((n) => visitType(n.type)).toList(),
         typeVariables ?? const <FunctionTypeVariable>[]);
     DartType type = _convertNullability(functionType, node.nullability);
diff --git a/pkg/compiler/lib/src/js_backend/namer.dart b/pkg/compiler/lib/src/js_backend/namer.dart
index e44beff..5ebc469 100644
--- a/pkg/compiler/lib/src/js_backend/namer.dart
+++ b/pkg/compiler/lib/src/js_backend/namer.dart
@@ -681,7 +681,8 @@
       String invocationName = operatorNameToIdentifier(function.name);
       // TODO(sra): If the generator is for a closure's 'call' method, we don't
       // need to incorporate the enclosing class.
-      String className = method.enclosingClass.name.replaceAll('&', '_');
+      String className =
+          method.enclosingClass.name.replaceAll(_nonIdentifierRE, '_');
       return '${invocationName}\$body\$${className}';
     });
   }
diff --git a/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart b/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
index a54322d..e4508fe 100644
--- a/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
+++ b/pkg/compiler/lib/src/js_emitter/program_builder/program_builder.dart
@@ -163,6 +163,8 @@
 
   Set<Class> _unneededNativeClasses;
 
+  List<StubMethod> _jsInteropIsChecks = [];
+
   /// Classes that have been allocated during a profile run.
   ///
   /// These classes should not be soft-deferred.
@@ -492,6 +494,8 @@
     // a method in the case where there exist multiple JavaScript classes
     // that conflict on whether the member is a getter or a method.
     Class interceptorClass = _classes[_commonElements.jsJavaScriptObjectClass];
+
+    interceptorClass?.isChecks?.addAll(_jsInteropIsChecks);
     Set<String> stubNames = {};
     librariesMap
         .forEach((LibraryEntity library, List<ClassEntity> classElements, _) {
@@ -750,9 +754,7 @@
       // Currently we generate duplicates if a class is implemented by multiple
       // js-interop classes.
       typeTests.forEachProperty(_sorter, (js.Name name, js.Node code) {
-        _classes[_commonElements.jsJavaScriptObjectClass]
-            .isChecks
-            .add(_buildStubMethod(name, code));
+        _jsInteropIsChecks.add(_buildStubMethod(name, code));
       });
     } else {
       for (Field field in instanceFields) {
diff --git a/pkg/compiler/lib/src/js_model/element_map_impl.dart b/pkg/compiler/lib/src/js_model/element_map_impl.dart
index e92f9f1..c4437cd 100644
--- a/pkg/compiler/lib/src/js_model/element_map_impl.dart
+++ b/pkg/compiler/lib/src/js_model/element_map_impl.dart
@@ -917,7 +917,7 @@
     for (ir.VariableDeclaration variable in sortedNamedParameters) {
       namedParameters.add(variable.name);
       namedParameterTypes.add(getParameterType(variable));
-      if (variable.isRequired && !options.useLegacySubtyping) {
+      if (variable.isRequired) {
         requiredNamedParameters.add(variable.name);
       }
     }
diff --git a/pkg/compiler/lib/src/kernel/element_map_impl.dart b/pkg/compiler/lib/src/kernel/element_map_impl.dart
index 386f119..0c1c106 100644
--- a/pkg/compiler/lib/src/kernel/element_map_impl.dart
+++ b/pkg/compiler/lib/src/kernel/element_map_impl.dart
@@ -539,7 +539,7 @@
     for (ir.VariableDeclaration variable in sortedNamedParameters) {
       namedParameters.add(variable.name);
       namedParameterTypes.add(getParameterType(variable));
-      if (variable.isRequired && !options.useLegacySubtyping) {
+      if (variable.isRequired) {
         requiredNamedParameters.add(variable.name);
       }
     }
diff --git a/pkg/compiler/lib/src/kernel/native_basic_data.dart b/pkg/compiler/lib/src/kernel/native_basic_data.dart
index f4e35a2..f7a7e97 100644
--- a/pkg/compiler/lib/src/kernel/native_basic_data.dart
+++ b/pkg/compiler/lib/src/kernel/native_basic_data.dart
@@ -47,15 +47,6 @@
     return annotationName;
   }
 
-  void checkFunctionParameters(FunctionEntity function) {
-    if (function.parameterStructure.namedParameters.isNotEmpty) {
-      elementMap.reporter.reportErrorMessage(
-          function,
-          MessageKind.JS_INTEROP_METHOD_WITH_NAMED_ARGUMENTS,
-          {'method': function.name});
-    }
-  }
-
   @override
   void extractJsInteropAnnotations(LibraryEntity library) {
     DiagnosticReporter reporter = elementMap.reporter;
@@ -90,7 +81,6 @@
                 function, MessageKind.JS_INTEROP_NON_EXTERNAL_MEMBER);*/
           } else {
             _nativeBasicDataBuilder.markAsJsInteropMember(function, memberName);
-            checkFunctionParameters(function);
             // TODO(johnniwinther): It is unclear whether library can be
             // implicitly js-interop. For now we allow it.
             isJsLibrary = true;
@@ -144,8 +134,6 @@
                   MessageKind.JS_INTEROP_CLASS_NON_EXTERNAL_MEMBER,
                   {'cls': cls.name, 'member': member.name});
             }
-
-            checkFunctionParameters(function);
           }
         });
         elementEnvironment.forEachConstructor(cls,
@@ -172,8 +160,6 @@
                       .JS_OBJECT_LITERAL_CONSTRUCTOR_WITH_POSITIONAL_ARGUMENTS,
                   {'cls': cls.name});
             }
-          } else {
-            checkFunctionParameters(constructor);
           }
         });
       } else {
diff --git a/pkg/compiler/lib/src/options.dart b/pkg/compiler/lib/src/options.dart
index 2f719b0..a1b0a83 100644
--- a/pkg/compiler/lib/src/options.dart
+++ b/pkg/compiler/lib/src/options.dart
@@ -193,6 +193,9 @@
   /// Whether to use the trivial abstract value domain.
   bool useTrivialAbstractValueDomain = false;
 
+  /// Whether to use the powerset abstract value domain (experimental).
+  bool experimentalPowersets = false;
+
   /// Whether to disable optimization for need runtime type information.
   bool disableRtiOptimization = false;
 
@@ -428,6 +431,7 @@
       ..disableTypeInference = _hasOption(options, Flags.disableTypeInference)
       ..useTrivialAbstractValueDomain =
           _hasOption(options, Flags.useTrivialAbstractValueDomain)
+      ..experimentalPowersets = _hasOption(options, Flags.experimentalPowersets)
       ..disableRtiOptimization =
           _hasOption(options, Flags.disableRtiOptimization)
       ..dumpInfo = _hasOption(options, Flags.dumpInfo)
diff --git a/pkg/compiler/lib/src/ssa/builder_kernel.dart b/pkg/compiler/lib/src/ssa/builder_kernel.dart
index 02e6e5c..703c2d0 100644
--- a/pkg/compiler/lib/src/ssa/builder_kernel.dart
+++ b/pkg/compiler/lib/src/ssa/builder_kernel.dart
@@ -3603,13 +3603,6 @@
           }
         }
         assert(namedValues.isEmpty);
-      } else {
-        // Throw an error because JS cannot handle named parameters.
-        reporter.reportErrorMessage(
-            _elementMap.getSpannable(targetElement, target),
-            MessageKind.JS_INTEROP_METHOD_WITH_NAMED_ARGUMENTS,
-            {'method': function.name});
-        return null;
       }
     }
     return values;
@@ -6689,7 +6682,7 @@
   final bool enableUserAssertions;
   final bool omitImplicitCasts;
 
-  final InlineData data = new InlineData();
+  final InlineData data = InlineData();
   bool seenReturn = false;
 
   /// Whether node-count is collector to determine if a function can be
@@ -6714,6 +6707,11 @@
   // TODO(25231): Make larger string constants eligible by sharing references.
   bool countReductiveNode = true;
 
+  // When handling a generative constructor factory, the super constructor calls
+  // are 'inlined', so tend to reuse the same parameters. [discountParameters]
+  // is true to avoid double-counting these parameters.
+  bool discountParameters = false;
+
   InlineWeeder(
       {this.enableUserAssertions: false, this.omitImplicitCasts: false});
 
@@ -6724,17 +6722,18 @@
         enableUserAssertions: enableUserAssertions,
         omitImplicitCasts: omitImplicitCasts);
     ir.FunctionNode node = getFunctionNode(elementMap, function);
-    node.accept(visitor);
     if (function.isConstructor) {
       visitor.data.isConstructor = true;
       MemberDefinition definition = elementMap.getMemberDefinition(function);
-      visitor.skipReductiveNodes(() {
-        ir.Node node = definition.node;
-        if (node is ir.Constructor) {
-          visitor.visitList(node.initializers);
-        }
-      });
+      ir.Node node = definition.node;
+      if (node is ir.Constructor) {
+        visitor.skipReductiveNodes(() {
+          visitor.handleGenerativeConstructorFactory(node);
+        });
+        return visitor.data;
+      }
     }
+    node.accept(visitor);
     return visitor.data;
   }
 
@@ -6752,9 +6751,9 @@
     countReductiveNode = oldCountReductiveNode;
   }
 
-  void registerRegularNode() {
+  void registerRegularNode([int count = 1]) {
     if (countRegularNode) {
-      data.regularNodeCount++;
+      data.regularNodeCount += count;
       if (seenReturn) {
         data.codeAfterReturn = true;
       }
@@ -6986,6 +6985,7 @@
 
   @override
   visitVariableGet(ir.VariableGet node) {
+    if (discountParameters && node.variable.parent is ir.FunctionNode) return;
     registerRegularNode();
     registerReductiveNode();
     skipReductiveNodes(() => visit(node.promotedType));
@@ -7097,4 +7097,175 @@
     node.visitChildren(this);
     data.hasIf = true;
   }
+
+  void handleGenerativeConstructorFactory(ir.Constructor node) {
+    // Generative constructors are compiled to a factory constructor which
+    // contains inlined all the initializations up the inheritance chain and
+    // then call each of the constructor bodies down the inheritance chain.
+    ir.Constructor constructor = node;
+
+    Set<ir.Field> initializedFields = {};
+    bool hasCallToSomeConstructorBody = false;
+
+    inheritance_loop:
+    while (constructor != null) {
+      ir.Constructor superConstructor;
+      for (var initializer in constructor.initializers) {
+        if (initializer is ir.RedirectingInitializer) {
+          // Discount the size of the arguments by references that are
+          // pass-through.
+          // TODO(sra): Need to add size of defaulted arguments.
+          var discountParametersOld = discountParameters;
+          discountParameters = true;
+          initializer.arguments.accept(this);
+          discountParameters = discountParametersOld;
+          constructor = initializer.target;
+          continue inheritance_loop;
+        } else if (initializer is ir.SuperInitializer) {
+          superConstructor = initializer.target;
+          // Discount the size of the arguments by references that are
+          // pass-through.
+          // TODO(sra): Need to add size of defaulted arguments.
+          var discountParametersOld = discountParameters;
+          discountParameters = true;
+          initializer.arguments.accept(this);
+          discountParameters = discountParametersOld;
+        } else if (initializer is ir.FieldInitializer) {
+          initializedFields.add(initializer.field);
+          initializer.value.accept(this);
+        } else if (initializer is ir.AssertInitializer) {
+          if (enableUserAssertions) {
+            initializer.accept(this);
+          }
+        } else {
+          initializer.accept(this);
+        }
+      }
+
+      _handleFields(constructor.enclosingClass, initializedFields);
+
+      // There will be a call to the constructor's body, which might be empty
+      // and inlined away.
+      var function = constructor.function;
+      var body = function.body;
+      if (!isEmptyBody(body)) {
+        // All of the parameters are passed to the body.
+        int parameterCount = function.positionalParameters.length +
+            function.namedParameters.length +
+            function.typeParameters.length;
+
+        hasCallToSomeConstructorBody = true;
+        registerCall();
+        // A body call looks like "t.Body$(arguments);", i.e. an expression
+        // statement with an instance member call, but the receiver is not
+        // counted in the arguments. I'm guessing about 6 nodes for this.
+        registerRegularNode(
+            6 + parameterCount * INLINING_NODES_OUTSIDE_LOOP_ARG_FACTOR);
+
+        // We can't inline a generative constructor factory when one of the
+        // bodies rewrites the environment to put locals or parameters into a
+        // box. The box is created in the generative constructor factory since
+        // the box may be shared between closures in the initializer list and
+        // closures in the constructor body.
+        var bodyVisitor = InlineWeederBodyClosure();
+        body.accept(bodyVisitor);
+        if (bodyVisitor.tooDifficult) {
+          data.hasClosure = true;
+        }
+      }
+
+      if (superConstructor != null) {
+        // The class of the super-constructor may not be the supertype class. In
+        // this case, we must go up the class hierarchy until we reach the class
+        // containing the super-constructor.
+        ir.Supertype supertype = constructor.enclosingClass.supertype;
+        while (supertype.classNode != superConstructor.enclosingClass) {
+          _handleFields(supertype.classNode, initializedFields);
+          supertype = supertype.classNode.supertype;
+        }
+      }
+      constructor = superConstructor;
+    }
+
+    // In addition to the initializer expressions and body calls, there is an
+    // allocator call.
+    if (hasCallToSomeConstructorBody) {
+      // A temporary is requried so we have
+      //
+      //     t=new ...;
+      //     ...;
+      //     use(t);
+      //
+      // I'm guessing it takes about 4 nodes to introduce the temporary and
+      // assign it.
+      registerRegularNode(4); // A temporary is requried.
+    }
+    // The initial field values are passed to the allocator.
+    registerRegularNode(
+        initializedFields.length * INLINING_NODES_OUTSIDE_LOOP_ARG_FACTOR);
+  }
+
+  void _handleFields(ir.Class cls, Set<ir.Field> initializedFields) {
+    for (ir.Field field in cls.fields) {
+      if (!field.isInstanceMember) continue;
+      ir.Expression initializer = field.initializer;
+      if (initializer == null ||
+          initializer is ir.ConstantExpression &&
+              initializer.constant is ir.PrimitiveConstant ||
+          initializer is ir.BasicLiteral) {
+        // Simple field initializers happen in the allocator, so do not
+        // contribute to the size of the generative constructor factory.
+        // TODO(sra): Use FieldInfo which tells us if the field is elided or
+        // initialized in the allocator.
+        continue;
+      }
+      if (!initializedFields.add(field)) continue;
+      initializer.accept(this);
+    }
+    // If [cls] is a mixin application, include fields from mixed in class.
+    if (cls.mixedInType != null) {
+      _handleFields(cls.mixedInType.classNode, initializedFields);
+    }
+  }
+
+  bool isEmptyBody(ir.Statement body) {
+    if (body is ir.EmptyStatement) return true;
+    if (body is ir.Block) return body.statements.every(isEmptyBody);
+    if (body is ir.AssertStatement && !enableUserAssertions) return true;
+    return false;
+  }
+}
+
+/// Visitor to detect environment-rewriting that prevents inlining
+/// (e.g. closures).
+class InlineWeederBodyClosure extends ir.Visitor<void> {
+  bool tooDifficult = false;
+
+  InlineWeederBodyClosure();
+
+  @override
+  defaultNode(ir.Node node) {
+    if (tooDifficult) return;
+    node.visitChildren(this);
+  }
+
+  @override
+  void visitFunctionExpression(ir.FunctionExpression node) {
+    tooDifficult = true;
+  }
+
+  @override
+  void visitFunctionDeclaration(ir.FunctionDeclaration node) {
+    tooDifficult = true;
+  }
+
+  @override
+  void visitFunctionNode(ir.FunctionNode node) {
+    assert(false);
+    if (node.asyncMarker != ir.AsyncMarker.Sync) {
+      tooDifficult = true;
+      return;
+    }
+    node.visitChildren(this);
+  }
 }
diff --git a/pkg/compiler/lib/src/ssa/codegen.dart b/pkg/compiler/lib/src/ssa/codegen.dart
index dc5adf4..85de782 100644
--- a/pkg/compiler/lib/src/ssa/codegen.dart
+++ b/pkg/compiler/lib/src/ssa/codegen.dart
@@ -2172,8 +2172,9 @@
     }
 
     if (superElement.isField) {
+      // TODO(sra): We can lower these in the simplifier.
       js.Name fieldName = _namer.instanceFieldPropertyName(superElement);
-      use(node.inputs[0]);
+      use(node.getDartReceiver(_closedWorld));
       js.PropertyAccess access = new js.PropertyAccess(pop(), fieldName)
           .withSourceInformation(node.sourceInformation);
       if (node.isSetter) {
diff --git a/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart b/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
index c981aa7..49e534a 100644
--- a/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
+++ b/pkg/compiler/lib/src/ssa/invoke_dynamic_specializers.dart
@@ -85,6 +85,7 @@
         if (argumentCount == 0) {
           if (name == 'abs') return const AbsSpecializer();
           if (name == 'round') return const RoundSpecializer();
+          if (name == 'toInt') return const ToIntSpecializer();
           if (name == 'trim') return const TrimSpecializer();
         } else if (argumentCount == 1) {
           if (name == 'codeUnitAt') return const CodeUnitAtSpecializer();
@@ -108,6 +109,39 @@
   }
 }
 
+bool canBeNegativeZero(HInstruction input) {
+  bool canBePositiveZero(HInstruction input) {
+    if (input is HConstant) {
+      ConstantValue value = input.constant;
+      if (value is DoubleConstantValue && value.isZero) return true;
+      if (value is IntConstantValue && value.isZero) return true;
+      return false;
+    }
+    return true;
+  }
+
+  if (input is HConstant) {
+    ConstantValue value = input.constant;
+    if (value is DoubleConstantValue && value.isMinusZero) return true;
+    return false;
+  }
+  if (input is HAdd) {
+    // '+' can only generate -0.0 when both inputs are -0.0.
+    return canBeNegativeZero(input.left) && canBeNegativeZero(input.right);
+  }
+  if (input is HSubtract) {
+    // '-' can only generate -0.0 for inputs `-0.0` and `0`.
+    return canBeNegativeZero(input.left) && canBePositiveZero(input.right);
+  }
+  if (input is HPhi) {
+    if (input.inputs.any((phiInput) => phiInput.block.id > input.block.id)) {
+      return true; // Assume back-edge may be negative zero.
+    }
+    return input.inputs.any(canBeNegativeZero);
+  }
+  return true;
+}
+
 class IndexAssignSpecializer extends InvokeDynamicSpecializer {
   const IndexAssignSpecializer();
 
@@ -548,42 +582,10 @@
     // cannot be -0.0.  Note that -0.0 is considered to be an int, so until we
     // track -0.0 precisely, we have to syntatically filter inputs that cannot
     // generate -0.0.
-    bool canBePositiveZero(HInstruction input) {
-      if (input is HConstant) {
-        ConstantValue value = input.constant;
-        if (value is DoubleConstantValue && value.isZero) return true;
-        if (value is IntConstantValue && value.isZero) return true;
-        return false;
-      }
-      return true;
-    }
 
-    bool inPhi = false;
-    bool canBeNegativeZero(HInstruction input) {
-      if (input is HConstant) {
-        ConstantValue value = input.constant;
-        if (value is DoubleConstantValue && value.isMinusZero) return true;
-        return false;
-      }
-      if (input is HAdd) {
-        // '+' can only generate -0.0 when both inputs are -0.0.
-        return canBeNegativeZero(input.left) && canBeNegativeZero(input.right);
-      }
-      if (input is HSubtract) {
-        return canBeNegativeZero(input.left) && canBePositiveZero(input.right);
-      }
-      if (input is HPhi) {
-        if (inPhi) return true;
-        inPhi = true;
-        bool result = input.inputs.any(canBeNegativeZero);
-        inPhi = false;
-        return result;
-      }
-      return true;
-    }
-
+    HInstruction receiver = instruction.getDartReceiver(closedWorld);
     if (inputsArePositiveIntegers(instruction, closedWorld) &&
-        !canBeNegativeZero(instruction.getDartReceiver(closedWorld))) {
+        !canBeNegativeZero(receiver)) {
       return new HRemainder(instruction.inputs[1], instruction.inputs[2],
           computeTypeFromInputTypes(instruction, results, closedWorld));
     }
@@ -1434,9 +1436,7 @@
   const RoundSpecializer();
 
   @override
-  constant_system.UnaryOperation operation() {
-    return constant_system.round;
-  }
+  constant_system.UnaryOperation operation() => constant_system.round;
 
   @override
   HInstruction tryConvertToBuiltin(
@@ -1458,3 +1458,36 @@
     return null;
   }
 }
+
+class ToIntSpecializer extends InvokeDynamicSpecializer {
+  const ToIntSpecializer();
+
+  @override
+  constant_system.UnaryOperation operation() => constant_system.toInt;
+
+  @override
+  HInstruction tryConvertToBuiltin(
+      HInvokeDynamic instruction,
+      HGraph graph,
+      GlobalTypeInferenceResults results,
+      JCommonElements commonElements,
+      JClosedWorld closedWorld,
+      OptimizationTestLog log) {
+    HInstruction receiver = instruction.getDartReceiver(closedWorld);
+
+    // We would like to reduce `x.toInt()` to `x`. The web platform considers
+    // infinities to be `int` values, but it is too hard to tell if an input is
+    // a finite integral value. Further `(-0.0).toInt()` returns `0`, so
+    // `toInt()` is not strictly an identity on finite integral values.
+
+    if (receiver
+        .isNumberOrNull(closedWorld.abstractValueDomain)
+        .isDefinitelyTrue) {
+      // Even if there is no builtin equivalent instruction, we know the
+      // instruction does not have any side effect, and that it can be GVN'ed.
+      clearAllSideEffects(instruction);
+      log?.registerToInt(instruction);
+    }
+    return null;
+  }
+}
diff --git a/pkg/compiler/lib/src/ssa/logging.dart b/pkg/compiler/lib/src/ssa/logging.dart
index c60de58..e857648 100644
--- a/pkg/compiler/lib/src/ssa/logging.dart
+++ b/pkg/compiler/lib/src/ssa/logging.dart
@@ -231,6 +231,10 @@
     _registerSpecializer(original, null, null, 'Round');
   }
 
+  void registerToInt(HInvokeDynamic original) {
+    _registerSpecializer(original, null, null, 'ToInt');
+  }
+
   void registerPrimitiveCheck(HInstruction original, HPrimitiveCheck check) {
     Features features = new Features();
 
diff --git a/pkg/compiler/test/inlining/data/static_initializer.dart b/pkg/compiler/test/inlining/data/static_initializer.dart
index 91880ca..e293b16 100644
--- a/pkg/compiler/test/inlining/data/static_initializer.dart
+++ b/pkg/compiler/test/inlining/data/static_initializer.dart
@@ -40,7 +40,7 @@
 
 var _var3 = <int>[Foo().a, (Foo()..a).a];
 
-/*member: Foo.:[]*/
+/*member: Foo.:[_var3:Foo]*/
 class Foo {
   int z = 99;
   /*member: Foo.a:[_var3]*/
diff --git a/pkg/compiler/test/inlining/data/type_variables.dart b/pkg/compiler/test/inlining/data/type_variables.dart
index a757dfe..5863e69 100644
--- a/pkg/compiler/test/inlining/data/type_variables.dart
+++ b/pkg/compiler/test/inlining/data/type_variables.dart
@@ -9,12 +9,12 @@
   inlineTypeTests();
 }
 
-/*member: Mixin1.:[inlineTypeTests:Mixin1<int*>]*/
+/*member: Mixin1.:closure*/
 class Mixin1<S> {
   var field = /*[]*/ (S s) => null;
 }
 
-/*member: Class1.:[inlineTypeTests:Class1<int*>]*/
+/*member: Class1.:closure*/
 class Class1<T> extends Object with Mixin1<T> {}
 
 /*member: _inlineTypeTests:[inlineTypeTests]*/
diff --git a/pkg/compiler/test/jsinterop/declaration_test.dart b/pkg/compiler/test/jsinterop/declaration_test.dart
index 72c7d23..878d20b 100644
--- a/pkg/compiler/test/jsinterop/declaration_test.dart
+++ b/pkg/compiler/test/jsinterop/declaration_test.dart
@@ -14,7 +14,7 @@
 
 const List<Test> TESTS = const <Test>[
   const Test('Empty js-interop class.', '''
-@JS() 
+@JS()
 library test;
 
 import 'package:js/js.dart';
@@ -81,19 +81,6 @@
 
 main() => new A();
 '''),
-  const Test('Js-interop class with external method with named parameters.', '''
-@JS()
-library test;
-
-import 'package:js/js.dart';
-
-@JS()
-class A {
-  external method({a, b});
-}
-
-main() => new A();
-''', errors: const [MessageKind.JS_INTEROP_METHOD_WITH_NAMED_ARGUMENTS]),
   const Test('Js-interop class with static method.', '''
 @JS()
 library test;
diff --git a/pkg/compiler/test/optimization/data/arithmetic.dart b/pkg/compiler/test/optimization/data/arithmetic.dart
index bc1843b..53f5bcb 100644
--- a/pkg/compiler/test/optimization/data/arithmetic.dart
+++ b/pkg/compiler/test/optimization/data/arithmetic.dart
@@ -114,6 +114,14 @@
   roundNull(null);
   roundString(1);
   roundString('');
+
+  toInt(1);
+  toIntNum(1);
+  toIntNum(1.5);
+  toIntNull(1);
+  toIntNull(null);
+  toIntString(1);
+  toIntString('');
 }
 
 ////////////////////////////////////////////////////////////////////////////////
@@ -489,3 +497,31 @@
 roundString(o) {
   return o.round();
 }
+
+////////////////////////////////////////////////////////////////////////////////
+// .toInt()
+////////////////////////////////////////////////////////////////////////////////
+
+/*member: toInt:Specializer=[ToInt]*/
+@pragma('dart2js:noInline')
+toInt(o) {
+  return o.toInt();
+}
+
+/*member: toIntNum:Specializer=[ToInt]*/
+@pragma('dart2js:noInline')
+toIntNum(o) {
+  return o.toInt();
+}
+
+/*member: toIntNull:Specializer=[ToInt]*/
+@pragma('dart2js:noInline')
+toIntNull(o) {
+  return o.toInt();
+}
+
+/*member: toIntString:Specializer=[!ToInt]*/
+@pragma('dart2js:noInline')
+toIntString(o) {
+  return o.toInt();
+}
diff --git a/pkg/dartdev/bin/dartdev.dart b/pkg/dartdev/bin/dartdev.dart
index 1a314e6..4e0f939 100644
--- a/pkg/dartdev/bin/dartdev.dart
+++ b/pkg/dartdev/bin/dartdev.dart
@@ -2,18 +2,12 @@
 // 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:io';
+import 'dart:async';
+import 'dart:isolate';
 
 import 'package:dartdev/dartdev.dart';
-import 'package:pedantic/pedantic.dart' show unawaited;
 
 /// The entry point for dartdev.
-Future<void> main(List<String> args) async {
-  // Ignore SIGINT to ensure DartDev doesn't exit before any of its
-  // spawned children. Draining the stream returned by watch() effectively
-  // sends the signals to the void.
-  //
-  // See https://github.com/dart-lang/sdk/issues/42092 for context.
-  unawaited(ProcessSignal.sigint.watch().drain());
-  await runDartdev(args);
+Future<void> main(List<String> args, SendPort port) async {
+  await runDartdev(args, port);
 }
diff --git a/pkg/dartdev/lib/dartdev.dart b/pkg/dartdev/lib/dartdev.dart
index 3d7bb9c..b21d5ab 100644
--- a/pkg/dartdev/lib/dartdev.dart
+++ b/pkg/dartdev/lib/dartdev.dart
@@ -3,10 +3,12 @@
 // BSD-style license that can be found in the LICENSE file.
 
 import 'dart:io' as io;
+import 'dart:isolate';
 
 import 'package:analyzer/src/dart/analysis/experiments.dart';
 import 'package:args/args.dart';
 import 'package:args/command_runner.dart';
+import 'package:dart_style/src/cli/format_command.dart';
 import 'package:cli_util/cli_logging.dart';
 import 'package:nnbd_migration/migration_cli.dart';
 import 'package:usage/usage.dart';
@@ -15,17 +17,18 @@
 import 'src/commands/analyze.dart';
 import 'src/commands/compile.dart';
 import 'src/commands/create.dart';
-import 'src/commands/format.dart';
 import 'src/commands/pub.dart';
 import 'src/commands/run.dart';
 import 'src/commands/test.dart';
 import 'src/core.dart';
 import 'src/experiments.dart';
+import 'src/vm_interop_handler.dart';
 
 /// This is typically called from bin/, but given the length of the method and
 /// analytics logic, it has been moved here. Also note that this method calls
 /// [io.exit(code)] directly.
-Future<void> runDartdev(List<String> args) async {
+Future<void> runDartdev(List<String> args, SendPort port) async {
+  VmInteropHandler.initialize(port);
   final stopwatch = Stopwatch();
   int result;
 
@@ -68,6 +71,12 @@
     io.exit(0);
   }
 
+  // --launch-dds is provided by the VM if the VM service is to be enabled. In
+  // that case, we need to launch DDS as well.
+  // TODO(bkonyi): add support for pub run (#42726)
+  if (args.contains('--launch-dds')) {
+    RunCommand.launchDds = true;
+  }
   String commandName;
 
   try {
@@ -79,6 +88,12 @@
       args = List.from(args)..remove('--disable-dartdev-analytics');
     }
 
+    // Run also can't be called with '--launch-dds', remove it if it's
+    // contained in args.
+    if (args.contains('--launch-dds')) {
+      args = List.from(args)..remove('--launch-dds');
+    }
+
     // Before calling to run, send the first ping to analytics to have the first
     // ping, as well as the command itself, running in parallel.
     if (analytics.enabled) {
@@ -133,7 +148,7 @@
       analytics.enabled = true;
     }
     analytics.close();
-    io.exit(exitCode);
+    VmInteropHandler.exit(exitCode);
   }
 }
 
@@ -166,6 +181,11 @@
         help: 'Disable anonymous analytics for this `dart *` run',
         hide: true);
 
+    // Another hidden flag used by the VM to indicate that DDS should be
+    // launched. Should be removed for all commands other than `run`.
+    argParser.addFlag('launch-dds',
+        negatable: false, hide: true, help: 'Launch DDS.');
+
     addCommand(AnalyzeCommand());
     addCommand(CreateCommand(verbose: verbose));
     addCommand(CompileCommand());
@@ -192,7 +212,7 @@
         io.stderr.writeln(
             "Error when reading '$firstArg': No such file or directory.");
         // This is the exit code used by the frontend.
-        io.exit(254);
+        VmInteropHandler.exit(254);
       }
     }
 
diff --git a/pkg/dartdev/lib/src/commands/analyze.dart b/pkg/dartdev/lib/src/commands/analyze.dart
index 57d83a5..e78e881 100644
--- a/pkg/dartdev/lib/src/commands/analyze.dart
+++ b/pkg/dartdev/lib/src/commands/analyze.dart
@@ -73,7 +73,7 @@
     });
 
     await analysisCompleter.future;
-
+    await server.dispose();
     progress.finish(showTiming: true);
 
     errors.sort();
diff --git a/pkg/dartdev/lib/src/commands/compile.dart b/pkg/dartdev/lib/src/commands/compile.dart
index d79265b..87f9480 100644
--- a/pkg/dartdev/lib/src/commands/compile.dart
+++ b/pkg/dartdev/lib/src/commands/compile.dart
@@ -159,12 +159,12 @@
       )
       ..addMultiOption('define', abbr: 'D', valueHelp: 'key=value', help: '''
 Set values of environment variables. To specify multiple variables, use multiple options or use commas to separate key-value pairs.
-E.g.: dart2native -Da=1,b=2 main.dart''')
+E.g.: dart compile $commandName -Da=1,b=2 main.dart''')
       ..addFlag('enable-asserts',
           negatable: false, help: 'Enable assert statements.')
       ..addOption('packages', abbr: 'p', valueHelp: 'path', help: '''
 Get package locations from the specified file instead of .packages. <path> can be relative or absolute.
-E.g.: dart2native --packages=/tmp/pkgs main.dart
+E.g.: dart compile $commandName --packages=/tmp/pkgs main.dart
 ''')
       ..addOption('save-debugging-info', abbr: 'S', valueHelp: 'path', help: '''
 Remove debugging information from the output and save it separately to the specified file. <path> can be relative or absolute.
diff --git a/pkg/dartdev/lib/src/commands/format.dart b/pkg/dartdev/lib/src/commands/format.dart
deleted file mode 100644
index c1dfc60..0000000
--- a/pkg/dartdev/lib/src/commands/format.dart
+++ /dev/null
@@ -1,52 +0,0 @@
-// 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 '../core.dart';
-import '../sdk.dart';
-
-class FormatCommand extends DartdevCommand {
-  FormatCommand() : super('format', 'Format Dart source code.') {
-    // TODO(jwren) When https://github.com/dart-lang/dart_style/issues/889
-    //  is resolved, have dart_style provide the ArgParser, instead of creating
-    // one here.
-    argParser
-      ..addFlag('dry-run',
-          abbr: 'n',
-          help: 'Show which files would be modified but make no changes.')
-      ..addFlag('set-exit-if-changed',
-          help: 'Return exit code 1 if there are any formatting changes.')
-      ..addFlag('machine',
-          abbr: 'm', help: 'Produce machine-readable JSON output.')
-      ..addOption('line-length',
-          abbr: 'l',
-          help:
-              'Wrap lines longer than this length. Defaults to 80 characters.',
-          defaultsTo: '80');
-  }
-
-  @override
-  FutureOr<int> run() async {
-    List<String> args = List.from(argResults.arguments);
-
-    // By printing and returning if there are no arguments, this changes the
-    // default unix-pipe behavior of dartfmt:
-    if (args.isEmpty) {
-      printUsage();
-      return 0;
-    }
-
-    // By always adding '--overwrite', the default behavior of dartfmt by
-    // is changed to have the UX of 'flutter format *'.  The flag is not added
-    // if 'dry-run' has been passed as they are not compatible.
-    if (!argResults['dry-run']) {
-      args.add('--overwrite');
-    }
-
-    var process = await startProcess(sdk.dartfmt, args);
-    routeToStdout(process);
-    return process.exitCode;
-  }
-}
diff --git a/pkg/dartdev/lib/src/commands/run.dart b/pkg/dartdev/lib/src/commands/run.dart
index 6ba76e0..9649377 100644
--- a/pkg/dartdev/lib/src/commands/run.dart
+++ b/pkg/dartdev/lib/src/commands/run.dart
@@ -4,18 +4,20 @@
 
 import 'dart:async';
 import 'dart:convert';
+import 'dart:developer';
 import 'dart:io';
 
 import 'package:args/args.dart';
-import 'package:dds/dds.dart';
 import 'package:path/path.dart';
 
 import '../core.dart';
 import '../experiments.dart';
 import '../sdk.dart';
 import '../utils.dart';
+import '../vm_interop_handler.dart';
 
 class RunCommand extends DartdevCommand<int> {
+  static bool launchDds = false;
   @override
   final ArgParser argParser = ArgParser.allowAnything();
 
@@ -60,21 +62,19 @@
     // The command line arguments after 'run'
     var args = argResults.arguments.toList();
 
-    var argsContainFileOrHelp = false;
+    var argsContainFile = false;
     for (var arg in args) {
       // The arg.contains('.') matches a file name pattern, i.e. some 'foo.dart'
-      if (arg.contains('.') ||
-          arg == '--help' ||
-          arg == '-h' ||
-          arg == 'help') {
-        argsContainFileOrHelp = true;
-        break;
+      if (arg.contains('.')) {
+        argsContainFile = true;
+      } else if (arg == '--help' || arg == '-h' || arg == 'help') {
+        printUsage();
+        return 0;
       }
     }
 
     final cwd = Directory.current;
-
-    if (!argsContainFileOrHelp && cwd.existsSync()) {
+    if (!argsContainFile && cwd.existsSync()) {
       var foundImplicitFileToRun = false;
       var cwdName = cwd.name;
       for (var entity in cwd.listSync(followLinks: false)) {
@@ -100,6 +100,8 @@
           'Could not find the implicit file to run: '
           'bin$separator$cwdName.dart.',
         );
+        // Error exit code, as defined in runtime/bin/error_exit.h
+        return 255;
       }
     }
 
@@ -117,213 +119,43 @@
     // service intermediary which implements the VM service protocol and
     // provides non-VM specific extensions (e.g., log caching, client
     // synchronization).
-    if (args.any((element) =>
-        element.startsWith('--observe') ||
-        element.startsWith('--enable-vm-service'))) {
-      return await _DebuggingSession(this, args).start();
-    } else {
-      // Starting in ProcessStartMode.inheritStdio mode means the child process
-      // can detect support for ansi chars.
-      final process = await Process.start(
-          sdk.dart, ['--disable-dart-dev', ...args],
-          mode: ProcessStartMode.inheritStdio);
-      return process.exitCode;
+    _DebuggingSession debugSession;
+    if (launchDds) {
+      debugSession = _DebuggingSession();
+      await debugSession.start();
     }
+
+    final script = Directory.current.uri
+        .resolve(args.firstWhere((e) => !e.startsWith('-')))
+        .toFilePath();
+    final runArgs = args.length == 1 ? <String>[] : args.sublist(1);
+    VmInteropHandler.run(script, runArgs);
+    return 0;
   }
 }
 
 class _DebuggingSession {
-  _DebuggingSession(this._runCommand, List<String> args)
-      : _args = args.toList() {
-    // Process flags that are meant to configure the VM service HTTP server or
-    // dump VM service connection information to a file. Since the VM service
-    // clients won't actually be connecting directly to the service, we'll make
-    // DDS appear as if it is the actual VM service.
-    for (final arg in _args) {
-      final isObserve = arg.startsWith('--observe');
-      if (isObserve || arg.startsWith('--enable-vm-service')) {
-        if (isObserve) {
-          _observe = true;
-        }
-        if (arg.contains('=') || arg.contains(':')) {
-          // These flags can be provided by the embedder so we need to check for
-          // both `=` and `:` separators.
-          final observatoryBindInfo =
-              (arg.contains('=') ? arg.split('=') : arg.split(':'))[1]
-                  .split('/');
-          _port = int.tryParse(observatoryBindInfo.first) ?? 0;
-          if (observatoryBindInfo.length > 1) {
-            try {
-              _bindAddress = Uri.http(observatoryBindInfo[1], '');
-            } on FormatException {
-              // TODO(bkonyi): log invalid parse? The VM service just ignores
-              // bad input flags.
-              // Ignore.
-            }
-          }
-        }
-      } else if (arg.startsWith('--write-service-info=')) {
-        try {
-          final split = arg.split('=');
-          if (split[1].isNotEmpty) {
-            _serviceInfoUri = Uri.parse(split[1]);
-          } else {
-            _runCommand.usageException(
-                'Invalid URI argument to --write-service-info: "${split[1]}"');
-          }
-        } on FormatException {
-          // TODO(bkonyi): log invalid parse? The VM service just ignores bad
-          // input flags.
-          // Ignore.
-        }
-      } else if (arg == '--disable-service-auth-codes') {
-        _disableServiceAuthCodes = true;
+  Future<void> start() async {
+    final serviceInfo = await Service.getInfo();
+    final process = await Process.start(
+        sdk.dart,
+        [
+          if (dirname(sdk.dart).endsWith('bin'))
+            sdk.ddsSnapshot
+          else
+            absolute(dirname(sdk.dart), 'gen', 'dds.dart.snapshot'),
+          serviceInfo.serverUri.toString()
+        ],
+        mode: ProcessStartMode.detachedWithStdio);
+    final completer = Completer<void>();
+    StreamSubscription sub;
+    sub = process.stderr.transform(utf8.decoder).listen((event) {
+      if (event == 'DDS started') {
+        sub.cancel();
+        completer.complete();
       }
-    }
-
-    // Strip --observe and --write-service-info from the arguments as we'll be
-    // providing our own.
-    _args.removeWhere(
-      (arg) =>
-          arg.startsWith('--observe') ||
-          arg.startsWith('--enable-vm-service') ||
-          arg.startsWith('--write-service-info'),
-    );
-  }
-
-  FutureOr<int> start() async {
-    // Output the service information for the target process to a temporary
-    // file so we can avoid scraping stderr for the service URI.
-    final serviceInfoDir =
-        await Directory.systemTemp.createTemp('dart_service');
-    final serviceInfoUri = serviceInfoDir.uri.resolve('service_info.json');
-    final serviceInfoFile = await File.fromUri(serviceInfoUri).create();
-
-    // Start using ProcessStartMode.normal and forward stdio manually as we
-    // need to filter the true VM service URI and replace it with the DDS URI.
-    _process = await Process.start(
-      sdk.dart,
-      [
-        '--disable-dart-dev',
-        // We don't care which port the VM service binds to.
-        _observe ? '--observe=0' : '--enable-vm-service=0',
-        '--write-service-info=$serviceInfoUri',
-        ..._args,
-      ],
-    );
-    _forwardAndFilterStdio(_process);
-
-    // Start DDS once the VM service has finished starting up.
-    await Future.any([
-      _waitForRemoteServiceUri(serviceInfoFile).then(_startDDS),
-      _process.exitCode,
-    ]);
-
-    return _process.exitCode.then((exitCode) async {
-      // Shutdown DDS if it was started and wait for the process' stdio streams
-      // to close so we don't truncate program output.
-      await Future.wait([
-        if (_dds != null) _dds.shutdown(),
-        _stderrDone,
-        _stdoutDone,
-      ]);
-      return exitCode;
     });
+
+    await completer.future;
   }
-
-  Future<Uri> _waitForRemoteServiceUri(File serviceInfoFile) async {
-    // Wait for VM service to write its connection info to disk.
-    while (await serviceInfoFile.length() <= 5) {
-      await Future.delayed(const Duration(milliseconds: 50));
-    }
-    final serviceInfoStr = await serviceInfoFile.readAsString();
-    return Uri.parse(jsonDecode(serviceInfoStr)['uri']);
-  }
-
-  Future<void> _startDDS(Uri remoteVmServiceUri) async {
-    _dds = await DartDevelopmentService.startDartDevelopmentService(
-      remoteVmServiceUri,
-      serviceUri: _bindAddress.replace(port: _port),
-      enableAuthCodes: !_disableServiceAuthCodes,
-    );
-    if (_serviceInfoUri != null) {
-      // Output the service connection information.
-      await File.fromUri(_serviceInfoUri).writeAsString(
-        json.encode({
-          'uri': _dds.uri.toString(),
-        }),
-      );
-    }
-    _ddsCompleter.complete();
-  }
-
-  void _forwardAndFilterStdio(Process process) {
-    // Since VM service clients cannot connect to the real VM service once DDS
-    // has started, replace all instances of the real VM service's URI with the
-    // DDS URI. Clients should only know that they are connected to DDS if they
-    // explicitly request that information via the protocol.
-    String filterObservatoryUri(String msg) {
-      if (_dds == null) {
-        return msg;
-      }
-      if (msg.contains('Observatory listening on') ||
-          msg.contains('Connect to Observatory at')) {
-        // Search for the VM service URI in the message and replace it.
-        msg = msg.replaceFirst(
-          RegExp(r'https?:\/\/(www\.)?[-a-zA-Z0-9@:%._\+~#=]{1,256}\.'
-              r'[a-zA-Z0-9()]{1,6}\b([-a-zA-Z0-9()@:%_\+.~#?&//=]*)'),
-          _dds.uri.toString(),
-        );
-      }
-      return msg;
-    }
-
-    // Wait for DDS to start before handling any stdio events from the target
-    // to ensure we don't let any unfiltered messages slip through.
-    // TODO(bkonyi): consider filtering on bytes rather than decoding the UTF8.
-    _stderrDone = process.stderr
-        .transform(const Utf8Decoder(allowMalformed: true))
-        .listen((event) async {
-      await _waitForDDS();
-      stderr.write(filterObservatoryUri(event));
-    }).asFuture();
-
-    _stdoutDone = process.stdout
-        .transform(const Utf8Decoder(allowMalformed: true))
-        .listen((event) async {
-      await _waitForDDS();
-      stdout.write(filterObservatoryUri(event));
-    }).asFuture();
-
-    stdin.listen(
-      (event) async {
-        await _waitForDDS();
-        process.stdin.add(event);
-      },
-    );
-  }
-
-  Future<void> _waitForDDS() async {
-    if (!_ddsCompleter.isCompleted) {
-      // No need to wait for DDS if the process has already exited.
-      await Future.any([
-        _ddsCompleter.future,
-        _process.exitCode,
-      ]);
-    }
-  }
-
-  Uri _bindAddress = Uri.http('127.0.0.1', '');
-  bool _disableServiceAuthCodes = false;
-  DartDevelopmentService _dds;
-  bool _observe = false;
-  int _port = 8181;
-  Process _process;
-  Uri _serviceInfoUri;
-  Future _stderrDone;
-  Future _stdoutDone;
-
-  final List<String> _args;
-  final Completer<void> _ddsCompleter = Completer();
-  final RunCommand _runCommand;
 }
diff --git a/pkg/dartdev/lib/src/sdk.dart b/pkg/dartdev/lib/src/sdk.dart
index 8481714..537089f 100644
--- a/pkg/dartdev/lib/src/sdk.dart
+++ b/pkg/dartdev/lib/src/sdk.dart
@@ -52,6 +52,9 @@
 
   String get dartfmt => path.absolute(sdkPath, 'bin', _binName('dartfmt'));
 
+  String get ddsSnapshot =>
+      path.absolute(sdkPath, 'bin', 'snapshots', 'dds.dart.snapshot');
+
   String get pub => path.absolute(sdkPath, 'bin', _binName('pub'));
 
   static String _binName(String base) =>
diff --git a/pkg/dartdev/lib/src/vm_interop_handler.dart b/pkg/dartdev/lib/src/vm_interop_handler.dart
new file mode 100644
index 0000000..3a8fea9
--- /dev/null
+++ b/pkg/dartdev/lib/src/vm_interop_handler.dart
@@ -0,0 +1,40 @@
+// 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:isolate';
+
+/// Contains methods used to communicate DartDev results back to the VM.
+abstract class VmInteropHandler {
+  /// Initializes [VmInteropHandler] to utilize [port] to communicate with the
+  /// VM.
+  static void initialize(SendPort port) => _port = port;
+
+  /// Notifies the VM to run [script] with [args] upon DartDev exit.
+  static void run(String script, List<String> args) {
+    assert(_port != null);
+    if (_port == null) return;
+    final message = List<dynamic>.filled(3, null)
+      ..[0] = _kResultRun
+      ..[1] = script
+      ..[2] = args;
+    _port.send(message);
+  }
+
+  /// Notifies the VM that DartDev has completed running. If provided a
+  /// non-zero [exitCode], the VM will terminate with the given exit code.
+  static void exit(int exitCode) {
+    assert(_port != null);
+    if (_port == null) return;
+    final message = List<dynamic>.filled(2, null)
+      ..[0] = _kResultExit
+      ..[1] = exitCode;
+    _port.send(message);
+  }
+
+  // Note: keep in sync with runtime/bin/dartdev_isolate.h
+  static const int _kResultRun = 1;
+  static const int _kResultExit = 2;
+
+  static SendPort _port;
+}
diff --git a/pkg/dartdev/test/commands/flag_test.dart b/pkg/dartdev/test/commands/flag_test.dart
index 748240f..90a9040 100644
--- a/pkg/dartdev/test/commands/flag_test.dart
+++ b/pkg/dartdev/test/commands/flag_test.dart
@@ -79,7 +79,9 @@
     var result = p.runSync('--help', ['--verbose']);
 
     expect(result.exitCode, 0);
-    expect(result.stdout, contains('migrate '));
+    expect(result.stdout, isEmpty);
+    expect(result.stderr,
+        contains('The following options are only used for VM development'));
   });
 
   test('--help -v', () {
@@ -87,6 +89,42 @@
     var result = p.runSync('--help', ['-v']);
 
     expect(result.exitCode, 0);
+    expect(result.stdout, isEmpty);
+    expect(result.stderr,
+        contains('The following options are only used for VM development'));
+  });
+
+  test('help', () {
+    p = project();
+    var result = p.runSync('help', []);
+
+    expect(result.exitCode, 0);
+    expect(result.stderr, isEmpty);
+    expect(result.stdout, contains(DartdevRunner.dartdevDescription));
+    expect(result.stdout,
+        contains('Usage: dart [<vm-flags>] <command|dart-file> [<arguments>]'));
+    expect(result.stdout, contains('Global options:'));
+    expect(result.stdout, contains('Available commands:'));
+    expect(result.stdout, contains('analyze '));
+    expect(result.stdout, contains('create '));
+    expect(result.stdout, contains('compile '));
+    expect(result.stdout, contains('format '));
+    expect(result.stdout, contains('migrate '));
+  });
+
+  test('help --verbose', () {
+    p = project();
+    var result = p.runSync('help', ['--verbose']);
+
+    expect(result.exitCode, 0);
+    expect(result.stdout, contains('migrate '));
+  });
+
+  test('help -v', () {
+    p = project();
+    var result = p.runSync('help', ['-v']);
+
+    expect(result.exitCode, 0);
     expect(result.stdout, contains('migrate '));
   });
 }
diff --git a/pkg/dartdev/test/commands/format_test.dart b/pkg/dartdev/test/commands/format_test.dart
index 1b68d98..1045907 100644
--- a/pkg/dartdev/test/commands/format_test.dart
+++ b/pkg/dartdev/test/commands/format_test.dart
@@ -17,22 +17,14 @@
 
   tearDown(() => p?.dispose());
 
-  test('implicit --help', () {
-    p = project();
-    var result = p.runSync('format', []);
-    expect(result.exitCode, 0);
-    expect(result.stderr, isEmpty);
-    expect(result.stdout, contains('Format Dart source code.'));
-    expect(result.stdout, contains('Usage: dart format [arguments]'));
-  });
-
   test('--help', () {
     p = project();
     var result = p.runSync('format', ['--help']);
     expect(result.exitCode, 0);
     expect(result.stderr, isEmpty);
-    expect(result.stdout, contains('Format Dart source code.'));
-    expect(result.stdout, contains('Usage: dart format [arguments]'));
+    expect(result.stdout, contains('Idiomatically formats Dart source code.'));
+    expect(result.stdout,
+        contains('Usage: dart format [options...] <files or directories...>'));
   });
 
   test('unchanged', () {
@@ -40,7 +32,7 @@
     ProcessResult result = p.runSync('format', [p.relativeFilePath]);
     expect(result.exitCode, 0);
     expect(result.stderr, isEmpty);
-    expect(result.stdout, startsWith('Unchanged ${p.relativeFilePath}'));
+    expect(result.stdout, startsWith('Formatted 1 file (0 changed) in '));
   });
 
   test('formatted', () {
@@ -48,25 +40,10 @@
     ProcessResult result = p.runSync('format', [p.relativeFilePath]);
     expect(result.exitCode, 0);
     expect(result.stderr, isEmpty);
-    expect(result.stdout, startsWith('Formatted ${p.relativeFilePath}'));
-  });
-
-  test('dry-run changes', () {
-    p = project(mainSrc: 'int get foo =>       1;\n');
-    ProcessResult result =
-        p.runSync('format', ['--dry-run', p.relativeFilePath]);
-    expect(result.exitCode, 0);
-    expect(result.stderr, isEmpty);
-    expect(result.stdout, startsWith(p.relativeFilePath));
-  });
-
-  test('dry-run no changes', () {
-    p = project(mainSrc: 'int get foo => 1;\n');
-    ProcessResult result =
-        p.runSync('format', ['--dry-run', p.relativeFilePath]);
-    expect(result.exitCode, 0);
-    expect(result.stderr, isEmpty);
-    expect(result.stdout, isEmpty);
+    expect(
+        result.stdout,
+        startsWith(
+            'Formatted lib/main.dart\nFormatted 1 file (1 changed) in '));
   });
 
   test('unknown file', () {
@@ -76,6 +53,6 @@
     expect(result.exitCode, 0);
     expect(result.stderr,
         startsWith('No file or directory found at "$unknownFilePath".'));
-    expect(result.stdout, isEmpty);
+    expect(result.stdout, startsWith('Formatted no files in '));
   });
 }
diff --git a/pkg/dartdev/test/utils.dart b/pkg/dartdev/test/utils.dart
index 7fd5c73..513f2dc 100644
--- a/pkg/dartdev/test/utils.dart
+++ b/pkg/dartdev/test/utils.dart
@@ -55,7 +55,6 @@
     String workingDir,
   }) {
     var arguments = [
-      absolutePathToDartdevFile,
       command,
       if (command == 'migrate')
         // TODO(srawlins): Enable `pub outdated` in tests.
@@ -64,7 +63,6 @@
     ];
 
     arguments.add('--disable-dartdev-analytics');
-
     return Process.runSync(
       Platform.resolvedExecutable,
       arguments,
diff --git a/pkg/dds/CHANGELOG.md b/pkg/dds/CHANGELOG.md
index 2884166..77142a4 100644
--- a/pkg/dds/CHANGELOG.md
+++ b/pkg/dds/CHANGELOG.md
@@ -1,3 +1,27 @@
+# 1.3.1
+
+- Fixed issue where an exception could be thrown during startup if the target
+  process had an isolate without an associated pause event.
+
+# 1.3.0
+
+- Added support for SSE connections from web-based clients.
+
+# 1.2.4
+
+- Fixed another issue where a `StateError` could be raised within `DartDevelopmentService`
+  when a client has disconnected after the target VM service has shutdown.
+
+# 1.2.3
+
+- Fixed issue where DDS was expecting a client provided implementation of
+`compileExpression` to return a response with two layers of `response` objects.
+
+# 1.2.2
+
+- Fixed issue where a `StateError` could be raised within `DartDevelopmentService`
+  when a client has disconnected after the target VM service has shutdown.
+
 # 1.2.1
 
 - Fixed issue where `evaluate` and `evaluateInFrame` were not invoking client
diff --git a/pkg/dds/README.md b/pkg/dds/README.md
index 64b0c72..ec3567b 100644
--- a/pkg/dds/README.md
+++ b/pkg/dds/README.md
@@ -2,7 +2,35 @@
 
 # Functionality
 
-Existing VM Service clients can issue both HTTP and websocket requests to a running DDS instance as if it were an instance of the VM Service itself. If a request corresponds to an RPC defined in the [VM Service Protocol][service-protocol], DDS will forward the request and return the response from the VM Service. Requests corresponding to an RPC defined in the [DDS Protocol][dds-protocol] will be handled directly by the DDS instance.
+Existing VM Service clients can issue both HTTP, websocket, and SSE requests to a running DDS instance as if it were an instance of the VM Service itself. If a request corresponds to an RPC defined in the [VM Service Protocol][service-protocol], DDS will forward the request and return the response from the VM Service. Requests corresponding to an RPC defined in the [DDS Protocol][dds-protocol] will be handled directly by the DDS instance.
+
+# SSE Support
+
+For certain web clients it may be preferrable or required to communicate with DDS using server-sent events (SSE). DDS has a SSE handler listening for requests on `/$debugHandler`.
+
+## SSE and package:vm_service example
+
+```dart
+import 'package:sse/sse.dart';
+import 'package:vm_service/vm_service.dart';
+
+void main() {
+  // Establish connection with DDS using SSE.
+  final ddsChannel = SseClient('${ddsUri}\$debugHandler');
+
+  // Wait for ddsChannel to be established
+  await ddsChannel.onOpen.first;
+
+  // Initialize VmService using the sink and stream from ddsChannel.
+  final vmService = VmService(
+    ddsChannel.stream,
+    (e) => ddsChannel.sink.add(e),
+  );
+
+  // You're ready to query DDS and the VM service!
+  print(await vmService.getVersion());
+}
+```
 
 [dds-protocol]: dds_protocol.md
 [service-protocol]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md
diff --git a/pkg/dds/bin/dds.dart b/pkg/dds/bin/dds.dart
new file mode 100644
index 0000000..476e84b
--- /dev/null
+++ b/pkg/dds/bin/dds.dart
@@ -0,0 +1,18 @@
+// 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:io';
+
+import 'package:dds/dds.dart';
+
+/// A simple program which starts a [DartDevelopmentService] instance with a
+/// basic configuration.
+///
+/// Takes the VM service URI as its single argument.
+Future<void> main(List<String> args) async {
+  if (args.isEmpty) return;
+  final remoteVmServiceUri = Uri.parse(args.first);
+  await DartDevelopmentService.startDartDevelopmentService(remoteVmServiceUri);
+  stderr.write('DDS started');
+}
diff --git a/pkg/dds/lib/dds.dart b/pkg/dds/lib/dds.dart
index 90461e6..f9c057c 100644
--- a/pkg/dds/lib/dds.dart
+++ b/pkg/dds/lib/dds.dart
@@ -21,6 +21,7 @@
 import 'package:shelf/shelf_io.dart' as io;
 import 'package:shelf_proxy/shelf_proxy.dart';
 import 'package:shelf_web_socket/shelf_web_socket.dart';
+import 'package:sse/server/sse_handler.dart';
 import 'package:stream_channel/stream_channel.dart';
 import 'package:web_socket_channel/web_socket_channel.dart';
 
@@ -111,6 +112,12 @@
   Uri get uri;
 
   /// The [Uri] VM service clients can use to communicate with this
+  /// [DartDevelopmentService] via server-sent events (SSE).
+  ///
+  /// Returns `null` if the service is not running.
+  Uri get sseUri;
+
+  /// The [Uri] VM service clients can use to communicate with this
   /// [DartDevelopmentService] via a [WebSocket].
   ///
   /// Returns `null` if the service is not running.
diff --git a/pkg/dds/lib/src/client.dart b/pkg/dds/lib/src/client.dart
index 4099128..3d796fc 100644
--- a/pkg/dds/lib/src/client.dart
+++ b/pkg/dds/lib/src/client.dart
@@ -7,24 +7,46 @@
 /// Representation of a single DDS client which manages the connection and
 /// DDS request intercepting / forwarding.
 class _DartDevelopmentServiceClient {
-  _DartDevelopmentServiceClient(
+  factory _DartDevelopmentServiceClient.fromWebSocket(
+    DartDevelopmentService dds,
+    WebSocketChannel ws,
+    json_rpc.Peer vmServicePeer,
+  ) =>
+      _DartDevelopmentServiceClient._(
+        dds,
+        ws,
+        vmServicePeer,
+      );
+
+  factory _DartDevelopmentServiceClient.fromSSEConnection(
+    DartDevelopmentService dds,
+    SseConnection sse,
+    json_rpc.Peer vmServicePeer,
+  ) =>
+      _DartDevelopmentServiceClient._(
+        dds,
+        sse,
+        vmServicePeer,
+      );
+
+  _DartDevelopmentServiceClient._(
     this.dds,
-    this.ws,
+    this.connection,
     json_rpc.Peer vmServicePeer,
   ) : _vmServicePeer = vmServicePeer {
     _clientPeer = json_rpc.Peer(
       // Manually create a StreamChannel<String> instead of calling
-      // ws.cast<String>() as cast() results in addStream() being called,
+      // .cast<String>() as cast() results in addStream() being called,
       // binding the underlying sink. This results in a StateError being thrown
       // if we try and add directly to the sink, which we do for binary events
       // in _StreamManager's streamNotify().
       StreamChannel<String>(
-        ws.stream.cast(),
+        connection.stream.cast(),
         StreamController(sync: true)
           ..stream
               .cast()
-              .listen((event) => ws.sink.add(event))
-              .onDone(() => ws.sink.close()),
+              .listen((event) => connection.sink.add(event))
+              .onDone(() => connection.sink.close()),
       ),
       strictProtocolChecks: false,
     );
@@ -231,8 +253,8 @@
   String _name;
 
   final _DartDevelopmentService dds;
+  final StreamChannel connection;
   final Map<String, String> services = {};
   final json_rpc.Peer _vmServicePeer;
-  final WebSocketChannel ws;
   json_rpc.Peer _clientPeer;
 }
diff --git a/pkg/dds/lib/src/client_manager.dart b/pkg/dds/lib/src/client_manager.dart
index 8527636..4304000 100644
--- a/pkg/dds/lib/src/client_manager.dart
+++ b/pkg/dds/lib/src/client_manager.dart
@@ -30,12 +30,26 @@
     );
     clients.add(client);
     client.listen().then((_) => removeClient(client));
+    if (clients.length == 1) {
+      dds.isolateManager.initialize().then((_) {
+        dds.streamManager.streamListen(
+          null,
+          _StreamManager.kDebugStream,
+        );
+      });
+    }
   }
 
   /// Cleanup state for a disconnected client.
   void removeClient(_DartDevelopmentServiceClient client) {
     _clearClientName(client);
     clients.remove(client);
+    if (clients.isEmpty) {
+      dds.streamManager.streamCancel(
+        null,
+        _StreamManager.kDebugStream,
+      );
+    }
   }
 
   /// Cleanup clients on DDS shutdown.
diff --git a/pkg/dds/lib/src/dds_impl.dart b/pkg/dds/lib/src/dds_impl.dart
index 221b2c9..55e9e64 100644
--- a/pkg/dds/lib/src/dds_impl.dart
+++ b/pkg/dds/lib/src/dds_impl.dart
@@ -139,10 +139,15 @@
   // Attempt to upgrade HTTP requests to a websocket before processing them as
   // standard HTTP requests. The websocket handler will fail quickly if the
   // request doesn't appear to be a websocket upgrade request.
-  Cascade _handlers() => Cascade().add(_webSocketHandler()).add(_httpHandler());
+  Cascade _handlers() {
+    return Cascade()
+        .add(_webSocketHandler())
+        .add(_sseHandler())
+        .add(_httpHandler());
+  }
 
   Handler _webSocketHandler() => webSocketHandler((WebSocketChannel ws) {
-        final client = _DartDevelopmentServiceClient(
+        final client = _DartDevelopmentServiceClient.fromWebSocket(
           this,
           ws,
           _vmServiceClient,
@@ -150,6 +155,23 @@
         clientManager.addClient(client);
       });
 
+  Handler _sseHandler() {
+    final handler = authCodesEnabled
+        ? SseHandler(Uri.parse('/$_authCode/$_kSseHandlerPath'))
+        : SseHandler(Uri.parse('/$_kSseHandlerPath'));
+
+    handler.connections.rest.listen((sseConnection) {
+      final client = _DartDevelopmentServiceClient.fromSSEConnection(
+        this,
+        sseConnection,
+        _vmServiceClient,
+      );
+      clientManager.addClient(client);
+    });
+
+    return handler.handler;
+  }
+
   Handler _httpHandler() {
     // DDS doesn't support any HTTP requests itself, so we just forward all of
     // them to the VM service.
@@ -157,10 +179,7 @@
     return cascade.handler;
   }
 
-  Uri _toWebSocket(Uri uri) {
-    if (uri == null) {
-      return null;
-    }
+  List<String> _cleanupPathSegments(Uri uri) {
     final pathSegments = <String>[];
     if (uri.pathSegments.isNotEmpty) {
       pathSegments.addAll(uri.pathSegments.where(
@@ -170,10 +189,27 @@
         (s) => s.isNotEmpty,
       ));
     }
+    return pathSegments;
+  }
+
+  Uri _toWebSocket(Uri uri) {
+    if (uri == null) {
+      return null;
+    }
+    final pathSegments = _cleanupPathSegments(uri);
     pathSegments.add('ws');
     return uri.replace(scheme: 'ws', pathSegments: pathSegments);
   }
 
+  Uri _toSse(Uri uri) {
+    if (uri == null) {
+      return null;
+    }
+    final pathSegments = _cleanupPathSegments(uri);
+    pathSegments.add(_kSseHandlerPath);
+    return uri.replace(pathSegments: pathSegments);
+  }
+
   String _getNamespace(_DartDevelopmentServiceClient client) =>
       clientManager.clients.keyOf(client);
 
@@ -186,6 +222,7 @@
   Uri _remoteVmServiceUri;
 
   Uri get uri => _uri;
+  Uri get sseUri => _toSse(_uri);
   Uri get wsUri => _toWebSocket(_uri);
   Uri _uri;
 
@@ -210,6 +247,8 @@
   _StreamManager get streamManager => _streamManager;
   _StreamManager _streamManager;
 
+  static const _kSseHandlerPath = '\$debugHandler';
+
   json_rpc.Peer _vmServiceClient;
   WebSocketChannel _vmServiceSocket;
   HttpServer _server;
diff --git a/pkg/dds/lib/src/expression_evaluator.dart b/pkg/dds/lib/src/expression_evaluator.dart
index e10af00..d514d60 100644
--- a/pkg/dds/lib/src/expression_evaluator.dart
+++ b/pkg/dds/lib/src/expression_evaluator.dart
@@ -76,7 +76,7 @@
         return (await externalClient.sendRequest(
           'compileExpression',
           compileParams,
-        ))['result']['kernelBytes'];
+        ))['kernelBytes'];
       } else {
         // Fallback to compiling using the kernel service.
         return (await dds._vmServiceClient.sendRequest(
diff --git a/pkg/dds/lib/src/isolate_manager.dart b/pkg/dds/lib/src/isolate_manager.dart
index 1ebc9f7..57711bf 100644
--- a/pkg/dds/lib/src/isolate_manager.dart
+++ b/pkg/dds/lib/src/isolate_manager.dart
@@ -85,7 +85,6 @@
     if (_resumeApprovalsByName.isEmpty) {
       return false;
     }
-
     // If all the required approvals are present, we should resume.
     return _resumeApprovalsByName.containsAll(requiredClientApprovals);
   }
@@ -171,9 +170,14 @@
       });
       final portId = isolate['number'];
       final name = isolate['name'];
-      final eventKind = isolate['pauseEvent']['kind'];
-      isolates[portId] = _RunningIsolate(this, portId, name);
-      _updateIsolateState(portId, name, eventKind);
+      if (isolate.containsKey('pauseEvent')) {
+        isolates[portId] = _RunningIsolate(this, portId, name);
+        final eventKind = isolate['pauseEvent']['kind'];
+        _updateIsolateState(portId, name, eventKind);
+      } else {
+        // If the isolate doesn't have a pauseEvent, assume it's running.
+        isolateStarted(portId, name);
+      }
     }
   }
 
diff --git a/pkg/dds/lib/src/stream_manager.dart b/pkg/dds/lib/src/stream_manager.dart
index d648d50..5704895 100644
--- a/pkg/dds/lib/src/stream_manager.dart
+++ b/pkg/dds/lib/src/stream_manager.dart
@@ -28,7 +28,7 @@
           continue;
         }
         if (isBinaryData) {
-          listener.ws.sink.add(data);
+          listener.connection.sink.add(data);
         } else {
           listener.sendNotification('streamNotify', data);
         }
@@ -117,12 +117,15 @@
   ) async {
     assert(stream != null && stream.isNotEmpty);
     if (!streamListeners.containsKey(stream)) {
-      // This will return an RPC exception if the stream doesn't exist. This
-      // will throw and the exception will be forwarded to the client.
-      final result = await dds._vmServiceClient.sendRequest('streamListen', {
-        'streamId': stream,
-      });
-      assert(result['type'] == 'Success');
+      if ((stream == kDebugStream && client == null) ||
+          stream != kDebugStream) {
+        // This will return an RPC exception if the stream doesn't exist. This
+        // will throw and the exception will be forwarded to the client.
+        final result = await dds._vmServiceClient.sendRequest('streamListen', {
+          'streamId': stream,
+        });
+        assert(result['type'] == 'Success');
+      }
       streamListeners[stream] = <_DartDevelopmentServiceClient>[];
     }
     if (streamListeners[stream].contains(client)) {
@@ -142,17 +145,23 @@
   /// send a `streamCancel` request for `stream` to the VM service.
   Future<void> streamCancel(
     _DartDevelopmentServiceClient client,
-    String stream,
-  ) async {
+    String stream, {
+    bool cancelCoreStream = false,
+  }) async {
     assert(stream != null && stream.isNotEmpty);
     final listeners = streamListeners[stream];
-    if (listeners == null || !listeners.contains(client)) {
+    if (client != null && (listeners == null || !listeners.contains(client))) {
       throw kStreamNotSubscribedException;
     }
     listeners.remove(client);
     // Don't cancel streams DDS needs to function.
-    if (listeners.isEmpty && !ddsCoreStreams.contains(stream)) {
+    if (listeners.isEmpty &&
+        (!ddsCoreStreams.contains(stream) || cancelCoreStream)) {
       streamListeners.remove(stream);
+      // Ensure the VM service hasn't shutdown.
+      if (dds._vmServiceClient.isClosed) {
+        return;
+      }
       final result = await dds._vmServiceClient.sendRequest('streamCancel', {
         'streamId': stream,
       });
@@ -167,8 +176,11 @@
     for (final streamId in streamListeners.keys.toList()) {
       streamCancel(client, streamId).catchError(
         (_) => null,
-        // Ignore 'stream not subscribed' errors.
-        test: (e) => e is json_rpc.RpcException,
+        // Ignore 'stream not subscribed' errors and StateErrors which arise
+        // when DDS is shutting down.
+        test: (e) =>
+            (e is json_rpc.RpcException) ||
+            (dds._shuttingDown && e is StateError),
       );
     }
     // Notify other service clients of service extensions that are being
diff --git a/pkg/dds/pubspec.yaml b/pkg/dds/pubspec.yaml
index 7513031..a4bccc8 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.2.1
+version: 1.3.1
 
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/dds
 
@@ -17,10 +17,13 @@
   pedantic: ^1.7.0
   shelf: ^0.7.5
   shelf_proxy: ^0.1.0+7
+  shelf_static: ^0.2.8
   shelf_web_socket: ^0.2.3
+  sse: ^3.5.0
   stream_channel: ^2.0.0
   web_socket_channel: ^1.1.0
 
 dev_dependencies:
   test: ^1.0.0
   vm_service: ^4.0.0
+  webdriver: ^2.1.2
diff --git a/pkg/dds/test/external_compilation_service_script.dart b/pkg/dds/test/external_compilation_service_script.dart
new file mode 100644
index 0000000..b01ed60
--- /dev/null
+++ b/pkg/dds/test/external_compilation_service_script.dart
@@ -0,0 +1,9 @@
+// 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:developer';
+
+main() {
+  debugger();
+}
diff --git a/pkg/dds/test/external_compilation_service_test.dart b/pkg/dds/test/external_compilation_service_test.dart
new file mode 100644
index 0000000..92e5ac8
--- /dev/null
+++ b/pkg/dds/test/external_compilation_service_test.dart
@@ -0,0 +1,81 @@
+// 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:io';
+
+import 'package:dds/dds.dart';
+import 'package:test/test.dart';
+import 'package:vm_service/vm_service_io.dart';
+import 'common/test_helper.dart';
+
+void main() {
+  group('DDS', () {
+    Process process;
+    DartDevelopmentService dds;
+
+    setUp(() async {
+      process =
+          await spawnDartProcess('external_compilation_service_script.dart');
+    });
+
+    tearDown(() async {
+      await dds?.shutdown();
+      process?.kill();
+      dds = null;
+      process = null;
+    });
+
+    test('evaluate invokes client provided compileExpression RPC', () async {
+      dds = await DartDevelopmentService.startDartDevelopmentService(
+        remoteVmServiceUri,
+      );
+      expect(dds.isRunning, true);
+      final service = await vmServiceConnectUri(dds.wsUri.toString());
+      await service.registerService(
+        'compileExpression',
+        'Custom Expression Compilation',
+      );
+      bool invokedCompileExpression = false;
+      service.registerServiceCallback('compileExpression', (params) async {
+        invokedCompileExpression = true;
+        throw 'error';
+      });
+      final vm = await service.getVM();
+      final isolate = await service.getIsolate(vm.isolates.first.id);
+      try {
+        await service.evaluate(isolate.id, isolate.libraries.first.id, '1 + 1');
+      } catch (_) {
+        // ignore error
+      }
+      expect(invokedCompileExpression, true);
+    });
+
+    test('evaluateInFrame invokes client provided compileExpression RPC',
+        () async {
+      dds = await DartDevelopmentService.startDartDevelopmentService(
+        remoteVmServiceUri,
+      );
+      expect(dds.isRunning, true);
+      final service = await vmServiceConnectUri(dds.wsUri.toString());
+      await service.registerService(
+        'compileExpression',
+        'Custom Expression Compilation',
+      );
+      bool invokedCompileExpression = false;
+      service.registerServiceCallback('compileExpression', (params) async {
+        invokedCompileExpression = true;
+        throw 'error';
+      });
+      final vm = await service.getVM();
+      final isolate = await service.getIsolate(vm.isolates.first.id);
+      await service.resume(isolate.id);
+      try {
+        await service.evaluateInFrame(isolate.id, 0, '1 + 1');
+      } catch (_) {
+        // ignore error
+      }
+      expect(invokedCompileExpression, true);
+    });
+  });
+}
diff --git a/pkg/dds/test/smoke_test.dart b/pkg/dds/test/smoke_test.dart
index 3b8cd7b..e7e5216 100644
--- a/pkg/dds/test/smoke_test.dart
+++ b/pkg/dds/test/smoke_test.dart
@@ -27,49 +27,51 @@
       process = null;
     });
 
-    bool useAuthCodes = false;
-    for (int i = 0; i < 2; ++i) {
-      test('Smoke Test with ${useAuthCodes ? "" : "no "} authentication codes',
-          () async {
-        dds = await DartDevelopmentService.startDartDevelopmentService(
-          remoteVmServiceUri,
-          enableAuthCodes: useAuthCodes,
-        );
-        expect(dds.isRunning, true);
+    void createSmokeTest(bool useAuthCodes) {
+      test(
+        'Smoke Test with ${useAuthCodes ? "" : "no "} authentication codes',
+        () async {
+          dds = await DartDevelopmentService.startDartDevelopmentService(
+            remoteVmServiceUri,
+            enableAuthCodes: useAuthCodes,
+          );
+          expect(dds.isRunning, true);
 
-        // Ensure basic websocket requests are forwarded correctly to the VM service.
-        final service = await vmServiceConnectUri(dds.wsUri.toString());
-        final version = await service.getVersion();
-        expect(version.major > 0, true);
-        expect(version.minor > 0, true);
+          // Ensure basic websocket requests are forwarded correctly to the VM service.
+          final service = await vmServiceConnectUri(dds.wsUri.toString());
+          final version = await service.getVersion();
+          expect(version.major > 0, true);
+          expect(version.minor > 0, true);
 
-        expect(
-          remoteVmServiceUri.pathSegments,
-          useAuthCodes ? isNotEmpty : isEmpty,
-        );
+          expect(
+            dds.uri.pathSegments,
+            useAuthCodes ? isNotEmpty : isEmpty,
+          );
 
-        // Ensure we can still make requests of the VM service via HTTP.
-        HttpClient client = HttpClient();
-        final request = await client.getUrl(remoteVmServiceUri.replace(
-          pathSegments: [
-            if (remoteVmServiceUri.pathSegments.isNotEmpty)
-              remoteVmServiceUri.pathSegments.first,
-            'getVersion',
-          ],
-        ));
-        final response = await request.close();
-        final Map<String, dynamic> jsonResponse = (await response
-            .transform(utf8.decoder)
-            .transform(json.decoder)
-            .single);
-        expect(jsonResponse['result']['type'], 'Version');
-        expect(jsonResponse['result']['major'] > 0, true);
-        expect(jsonResponse['result']['minor'] > 0, true);
-      });
-
-      useAuthCodes = true;
+          // Ensure we can still make requests of the VM service via HTTP.
+          HttpClient client = HttpClient();
+          final request = await client.getUrl(remoteVmServiceUri.replace(
+            pathSegments: [
+              if (remoteVmServiceUri.pathSegments.isNotEmpty)
+                remoteVmServiceUri.pathSegments.first,
+              'getVersion',
+            ],
+          ));
+          final response = await request.close();
+          final Map<String, dynamic> jsonResponse = (await response
+              .transform(utf8.decoder)
+              .transform(json.decoder)
+              .single);
+          expect(jsonResponse['result']['type'], 'Version');
+          expect(jsonResponse['result']['major'] > 0, true);
+          expect(jsonResponse['result']['minor'] > 0, true);
+        },
+      );
     }
 
+    createSmokeTest(true);
+    createSmokeTest(false);
+
     test('startup fails when VM service has existing clients', () async {
       Uri httpToWebSocketUri(Uri httpUri) {
         final segments = (httpUri.pathSegments.isNotEmpty)
diff --git a/pkg/dds/test/sse_smoke_test.dart b/pkg/dds/test/sse_smoke_test.dart
new file mode 100644
index 0000000..682fa18
--- /dev/null
+++ b/pkg/dds/test/sse_smoke_test.dart
@@ -0,0 +1,116 @@
+// 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:convert';
+import 'dart:io';
+
+import 'package:dds/dds.dart';
+import 'package:shelf/shelf.dart' as shelf;
+import 'package:shelf/shelf_io.dart' as io;
+import 'package:shelf_static/shelf_static.dart';
+import 'package:sse/server/sse_handler.dart';
+import 'package:test/test.dart';
+import 'package:vm_service/vm_service.dart' as service;
+import 'package:webdriver/io.dart';
+
+import 'common/test_helper.dart';
+
+// NOTE: this test requires that Chrome is available via PATH or CHROME_PATH
+// environment variables.
+
+void main() {
+  Process chromeDriver;
+  DartDevelopmentService dds;
+  SseHandler handler;
+  Process process;
+  HttpServer server;
+  WebDriver webdriver;
+
+  setUpAll(() async {
+    final chromedriverUri = Platform.script.resolveUri(
+        Uri.parse('../../../third_party/webdriver/chrome/chromedriver'));
+    try {
+      chromeDriver = await Process.start(chromedriverUri.path, [
+        '--port=4444',
+        '--url-base=wd/hub',
+      ]);
+    } catch (e) {
+      throw StateError(
+          'Could not start ChromeDriver. Is it installed?\nError: $e');
+    }
+  });
+
+  tearDownAll(() {
+    chromeDriver.kill();
+  });
+
+  group('DDS', () {
+    setUp(() async {
+      process = await spawnDartProcess('smoke.dart');
+
+      handler = SseHandler(Uri.parse('/test'));
+      final cascade = shelf.Cascade()
+          .add(handler.handler)
+          .add(_faviconHandler)
+          .add(createStaticHandler(Platform.script.resolve('web').path,
+              listDirectories: true, defaultDocument: 'index.html'));
+
+      server = await io.serve(cascade.handler, 'localhost', 0);
+
+      final capabilities = Capabilities.chrome
+        ..addAll({
+          Capabilities.chromeOptions: {
+            'args': ['--headless'],
+            'binary': Platform.environment['CHROME_PATH'] ?? '',
+          },
+        });
+      print('Capabilities: $capabilities');
+      webdriver = await createDriver(
+        desired: capabilities,
+      );
+    });
+
+    tearDown(() async {
+      await dds?.shutdown();
+      process?.kill();
+      await webdriver.quit();
+      await server.close();
+      dds = null;
+      process = null;
+    });
+
+    void createTest(bool useAuthCodes) {
+      test(
+        'SSE Smoke Test with ${useAuthCodes ? "" : "no "}authentication codes',
+        () async {
+          dds = await DartDevelopmentService.startDartDevelopmentService(
+            remoteVmServiceUri,
+            serviceUri: Uri.parse('http://localhost:0'),
+            enableAuthCodes: useAuthCodes,
+          );
+          expect(dds.isRunning, true);
+          await webdriver.get('http://localhost:${server.port}');
+          final testeeConnection = await handler.connections.next;
+          testeeConnection.sink.add(dds.sseUri.toString());
+
+          final response = json.decode(await testeeConnection.stream.first);
+          final version = service.Version.parse(response);
+          expect(version.major > 0, isTrue);
+          expect(version.minor >= 0, isTrue);
+        },
+      );
+    }
+
+    createTest(true);
+    createTest(false);
+  });
+}
+
+FutureOr<shelf.Response> _faviconHandler(shelf.Request request) {
+  if (request.url.path.endsWith('favicon.ico')) {
+    return shelf.Response.ok('');
+  }
+  return shelf.Response.notFound('');
+}
diff --git a/pkg/dds/test/uri_test.dart b/pkg/dds/test/uri_test.dart
new file mode 100644
index 0000000..8afd523
--- /dev/null
+++ b/pkg/dds/test/uri_test.dart
@@ -0,0 +1,88 @@
+// 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:io';
+
+import 'package:dds/dds.dart';
+import 'package:test/test.dart';
+
+import 'common/test_helper.dart';
+
+void main() {
+  Process process;
+  DartDevelopmentService dds;
+  setUp(() async {
+    process = await spawnDartProcess('smoke.dart');
+  });
+
+  tearDown(() async {
+    await dds?.shutdown();
+    process?.kill();
+    dds = null;
+    process = null;
+  });
+
+  Future<int> getAvailablePort() async {
+    final tmpServer = await HttpServer.bind(InternetAddress.loopbackIPv4, 0);
+    final port = tmpServer.port;
+    await tmpServer.close();
+    return port;
+  }
+
+  group('Ensure DDS URIs are consistent', () {
+    test('without authentication codes', () async {
+      final port = await getAvailablePort();
+      final serviceUri = Uri.parse('http://127.0.0.1:$port/');
+      dds = await DartDevelopmentService.startDartDevelopmentService(
+        remoteVmServiceUri,
+        serviceUri: serviceUri,
+        enableAuthCodes: false,
+      );
+
+      expect(dds.uri, serviceUri);
+      expect(
+        dds.sseUri,
+        serviceUri.replace(
+          pathSegments: ['\$debugHandler'],
+        ),
+      );
+      expect(
+        dds.wsUri,
+        serviceUri.replace(
+          scheme: 'ws',
+          pathSegments: ['ws'],
+        ),
+      );
+    });
+
+    test('with authentication codes', () async {
+      final port = await getAvailablePort();
+      final serviceUri = Uri.parse('http://127.0.0.1:$port/');
+      dds = await DartDevelopmentService.startDartDevelopmentService(
+        remoteVmServiceUri,
+        serviceUri: serviceUri,
+      );
+
+      // We need to pull the authentication code out of the main DDS URI, so
+      // just make sure that it's at the right address and port.
+      expect(dds.uri.toString().contains(serviceUri.toString()), isTrue);
+
+      expect(dds.uri.pathSegments, isNotEmpty);
+      final authCode = dds.uri.pathSegments.first;
+      expect(
+        dds.sseUri,
+        serviceUri.replace(
+          pathSegments: [authCode, '\$debugHandler'],
+        ),
+      );
+      expect(
+        dds.wsUri,
+        serviceUri.replace(
+          scheme: 'ws',
+          pathSegments: [authCode, 'ws'],
+        ),
+      );
+    });
+  });
+}
diff --git a/pkg/dds/test/web/index.html b/pkg/dds/test/web/index.html
new file mode 100644
index 0000000..27d3952
--- /dev/null
+++ b/pkg/dds/test/web/index.html
@@ -0,0 +1,12 @@
+<!DOCTYPE html>
+<html>
+
+<head>
+    <title>DDS SSE Smoke Test</title>
+</head>
+
+<body>
+    <script type="application/javascript" src="sse_smoke_driver.dart.js"></script>
+</body>
+
+</html>
\ No newline at end of file
diff --git a/pkg/dds/test/web/sse_smoke_driver.dart b/pkg/dds/test/web/sse_smoke_driver.dart
new file mode 100644
index 0000000..66ef20c
--- /dev/null
+++ b/pkg/dds/test/web/sse_smoke_driver.dart
@@ -0,0 +1,37 @@
+// 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.
+
+// This file must be compiled for changes to be picked up.
+//
+// Run the following command from the root of this package if this file is
+// updated:
+//
+// dart2js -o test/web/sse_smoke_driver.dart.js test/web/sse_smoke_driver.dart
+
+import 'dart:convert';
+
+import 'package:async/async.dart';
+import 'package:sse/client/sse_client.dart';
+import 'package:vm_service/vm_service.dart';
+
+Future<void> main() async {
+  // Connect to test server
+  final channel = SseClient('/test');
+  final testerStream = StreamQueue<String>(channel.stream);
+
+  // Connect to DDS
+  final ddsUri = await testerStream.next;
+  final ddsChannel = SseClient(ddsUri);
+
+  // Wait for ddsChannel to be established.
+  await ddsChannel.onOpen.first;
+
+  final vmService = VmService(
+    ddsChannel.stream,
+    (e) => ddsChannel.sink.add(e),
+  );
+  final version = await vmService.getVersion();
+  channel.sink.add(json.encode(version.json));
+  ddsChannel.close();
+}
diff --git a/pkg/dds/test/web/sse_smoke_driver.dart.js b/pkg/dds/test/web/sse_smoke_driver.dart.js
new file mode 100644
index 0000000..1fc9758
--- /dev/null
+++ b/pkg/dds/test/web/sse_smoke_driver.dart.js
@@ -0,0 +1,14723 @@
+// Generated by dart2js (fast startup emitter, strong), the Dart to JavaScript compiler version: 2.9.0-edge.9d8087a399ebe62f6a93f21ec20f56d39dbcf1a2.
+// The code supports the following hooks:
+// dartPrint(message):
+//    if this function is defined it is called instead of the Dart [print]
+//    method.
+//
+// dartMainRunner(main, args):
+//    if this function is defined, the Dart [main] method will not be invoked
+//    directly. Instead, a closure that will invoke [main], and its arguments
+//    [args] is passed to [dartMainRunner].
+//
+// dartDeferredLibraryLoader(uri, successCallback, errorCallback):
+//    if this function is defined, it will be called when a deferred library
+//    is loaded. It should load and eval the javascript of `uri`, and call
+//    successCallback. If it fails to do so, it should call errorCallback with
+//    an error.
+//
+// dartCallInstrumentation(id, qualifiedName):
+//    if this function is defined, it will be called at each entry of a
+//    method or constructor. Used only when compiling programs with
+//    --experiment-call-instrumentation.
+(function dartProgram() {
+  function copyProperties(from, to) {
+    var keys = Object.keys(from);
+    for (var i = 0; i < keys.length; i++) {
+      var key = keys[i];
+      to[key] = from[key];
+    }
+  }
+  var supportsDirectProtoAccess = function() {
+    var cls = function() {
+    };
+    cls.prototype = {p: {}};
+    var object = new cls();
+    if (!(object.__proto__ && object.__proto__.p === cls.prototype.p))
+      return false;
+    try {
+      if (typeof navigator != "undefined" && typeof navigator.userAgent == "string" && navigator.userAgent.indexOf("Chrome/") >= 0)
+        return true;
+      if (typeof version == "function" && version.length == 0) {
+        var v = version();
+        if (/^\d+\.\d+\.\d+\.\d+$/.test(v))
+          return true;
+      }
+    } catch (_) {
+    }
+    return false;
+  }();
+  function setFunctionNamesIfNecessary(holders) {
+    function t() {
+    }
+    ;
+    if (typeof t.name == "string")
+      return;
+    for (var i = 0; i < holders.length; i++) {
+      var holder = holders[i];
+      var keys = Object.keys(holder);
+      for (var j = 0; j < keys.length; j++) {
+        var key = keys[j];
+        var f = holder[key];
+        if (typeof f == 'function')
+          f.name = key;
+      }
+    }
+  }
+  function inherit(cls, sup) {
+    cls.prototype.constructor = cls;
+    cls.prototype["$is" + cls.name] = cls;
+    if (sup != null) {
+      if (supportsDirectProtoAccess) {
+        cls.prototype.__proto__ = sup.prototype;
+        return;
+      }
+      var clsPrototype = Object.create(sup.prototype);
+      copyProperties(cls.prototype, clsPrototype);
+      cls.prototype = clsPrototype;
+    }
+  }
+  function inheritMany(sup, classes) {
+    for (var i = 0; i < classes.length; i++)
+      inherit(classes[i], sup);
+  }
+  function mixin(cls, mixin) {
+    copyProperties(mixin.prototype, cls.prototype);
+    cls.prototype.constructor = cls;
+  }
+  function lazy(holder, name, getterName, initializer) {
+    var uninitializedSentinel = holder;
+    holder[name] = uninitializedSentinel;
+    holder[getterName] = function() {
+      holder[getterName] = function() {
+        H.throwCyclicInit(name);
+      };
+      var result;
+      var sentinelInProgress = initializer;
+      try {
+        if (holder[name] === uninitializedSentinel) {
+          result = holder[name] = sentinelInProgress;
+          result = holder[name] = initializer();
+        } else
+          result = holder[name];
+      } finally {
+        if (result === sentinelInProgress)
+          holder[name] = null;
+        holder[getterName] = function() {
+          return this[name];
+        };
+      }
+      return result;
+    };
+  }
+  function makeConstList(list) {
+    list.immutable$list = Array;
+    list.fixed$length = Array;
+    return list;
+  }
+  function convertToFastObject(properties) {
+    function t() {
+    }
+    t.prototype = properties;
+    new t();
+    return properties;
+  }
+  function convertAllToFastObject(arrayOfObjects) {
+    for (var i = 0; i < arrayOfObjects.length; ++i)
+      convertToFastObject(arrayOfObjects[i]);
+  }
+  var functionCounter = 0;
+  function tearOffGetter(funcs, applyTrampolineIndex, reflectionInfo, name, isIntercepted) {
+    return isIntercepted ? new Function("funcs", "applyTrampolineIndex", "reflectionInfo", "name", "H", "c", "return function tearOff_" + name + functionCounter++ + "(receiver) {" + "if (c === null) c = " + "H.closureFromTearOff" + "(" + "this, funcs, applyTrampolineIndex, reflectionInfo, false, true, name);" + "return new c(this, funcs[0], receiver, name);" + "}")(funcs, applyTrampolineIndex, reflectionInfo, name, H, null) : new Function("funcs", "applyTrampolineIndex", "reflectionInfo", "name", "H", "c", "return function tearOff_" + name + functionCounter++ + "() {" + "if (c === null) c = " + "H.closureFromTearOff" + "(" + "this, funcs, applyTrampolineIndex, reflectionInfo, false, false, name);" + "return new c(this, funcs[0], null, name);" + "}")(funcs, applyTrampolineIndex, reflectionInfo, name, H, null);
+  }
+  function tearOff(funcs, applyTrampolineIndex, reflectionInfo, isStatic, name, isIntercepted) {
+    var cache = null;
+    return isStatic ? function() {
+      if (cache === null)
+        cache = H.closureFromTearOff(this, funcs, applyTrampolineIndex, reflectionInfo, true, false, name).prototype;
+      return cache;
+    } : tearOffGetter(funcs, applyTrampolineIndex, reflectionInfo, name, isIntercepted);
+  }
+  var typesOffset = 0;
+  function installTearOff(container, getterName, isStatic, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) {
+    var funs = [];
+    for (var i = 0; i < funsOrNames.length; i++) {
+      var fun = funsOrNames[i];
+      if (typeof fun == 'string')
+        fun = container[fun];
+      fun.$callName = callNames[i];
+      funs.push(fun);
+    }
+    var fun = funs[0];
+    fun.$requiredArgCount = requiredParameterCount;
+    fun.$defaultValues = optionalParameterDefaultValues;
+    var reflectionInfo = funType;
+    if (typeof reflectionInfo == "number")
+      reflectionInfo += typesOffset;
+    var name = funsOrNames[0];
+    fun.$stubName = name;
+    var getterFunction = tearOff(funs, applyIndex || 0, reflectionInfo, isStatic, name, isIntercepted);
+    container[getterName] = getterFunction;
+    if (isStatic)
+      fun.$tearOff = getterFunction;
+  }
+  function installStaticTearOff(container, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) {
+    return installTearOff(container, getterName, true, false, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex);
+  }
+  function installInstanceTearOff(container, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex) {
+    return installTearOff(container, getterName, false, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, funsOrNames, funType, applyIndex);
+  }
+  function setOrUpdateInterceptorsByTag(newTags) {
+    var tags = init.interceptorsByTag;
+    if (!tags) {
+      init.interceptorsByTag = newTags;
+      return;
+    }
+    copyProperties(newTags, tags);
+  }
+  function setOrUpdateLeafTags(newTags) {
+    var tags = init.leafTags;
+    if (!tags) {
+      init.leafTags = newTags;
+      return;
+    }
+    copyProperties(newTags, tags);
+  }
+  function updateTypes(newTypes) {
+    var types = init.types;
+    var length = types.length;
+    types.push.apply(types, newTypes);
+    return length;
+  }
+  function updateHolder(holder, newHolder) {
+    copyProperties(newHolder, holder);
+    return holder;
+  }
+  var hunkHelpers = function() {
+    var mkInstance = function(isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) {
+        return function(container, getterName, name, funType) {
+          return installInstanceTearOff(container, getterName, isIntercepted, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex);
+        };
+      },
+      mkStatic = function(requiredParameterCount, optionalParameterDefaultValues, callNames, applyIndex) {
+        return function(container, getterName, name, funType) {
+          return installStaticTearOff(container, getterName, requiredParameterCount, optionalParameterDefaultValues, callNames, [name], funType, applyIndex);
+        };
+      };
+    return {inherit: inherit, inheritMany: inheritMany, mixin: mixin, installStaticTearOff: installStaticTearOff, installInstanceTearOff: installInstanceTearOff, _instance_0u: mkInstance(0, 0, null, ["call$0"], 0), _instance_1u: mkInstance(0, 1, null, ["call$1"], 0), _instance_2u: mkInstance(0, 2, null, ["call$2"], 0), _instance_0i: mkInstance(1, 0, null, ["call$0"], 0), _instance_1i: mkInstance(1, 1, null, ["call$1"], 0), _instance_2i: mkInstance(1, 2, null, ["call$2"], 0), _static_0: mkStatic(0, null, ["call$0"], 0), _static_1: mkStatic(1, null, ["call$1"], 0), _static_2: mkStatic(2, null, ["call$2"], 0), makeConstList: makeConstList, lazy: lazy, updateHolder: updateHolder, convertToFastObject: convertToFastObject, setFunctionNamesIfNecessary: setFunctionNamesIfNecessary, updateTypes: updateTypes, setOrUpdateInterceptorsByTag: setOrUpdateInterceptorsByTag, setOrUpdateLeafTags: setOrUpdateLeafTags};
+  }();
+  function initializeDeferredHunk(hunk) {
+    typesOffset = init.types.length;
+    hunk(hunkHelpers, init, holders, $);
+  }
+  function getGlobalFromName(name) {
+    for (var i = 0; i < holders.length; i++) {
+      if (holders[i] == C)
+        continue;
+      if (holders[i][name])
+        return holders[i][name];
+    }
+  }
+  var C = {},
+  H = {JS_CONST: function JS_CONST() {
+    },
+    MappedIterable_MappedIterable: function(iterable, $function, $S, $T) {
+      if (type$.EfficientLengthIterable_dynamic._is(iterable))
+        return new H.EfficientLengthMappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("EfficientLengthMappedIterable<1,2>"));
+      return new H.MappedIterable(iterable, $function, $S._eval$1("@<0>")._bind$1($T)._eval$1("MappedIterable<1,2>"));
+    },
+    IterableElementError_noElement: function() {
+      return new P.StateError("No element");
+    },
+    IterableElementError_tooFew: function() {
+      return new P.StateError("Too few elements");
+    },
+    EfficientLengthIterable: function EfficientLengthIterable() {
+    },
+    ListIterable: function ListIterable() {
+    },
+    ListIterator: function ListIterator(t0, t1, t2) {
+      var _ = this;
+      _._iterable = t0;
+      _.__internal$_length = t1;
+      _._index = 0;
+      _._current = null;
+      _.$ti = t2;
+    },
+    MappedIterable: function MappedIterable(t0, t1, t2) {
+      this._iterable = t0;
+      this._f = t1;
+      this.$ti = t2;
+    },
+    EfficientLengthMappedIterable: function EfficientLengthMappedIterable(t0, t1, t2) {
+      this._iterable = t0;
+      this._f = t1;
+      this.$ti = t2;
+    },
+    MappedIterator: function MappedIterator(t0, t1, t2) {
+      var _ = this;
+      _._current = null;
+      _._iterator = t0;
+      _._f = t1;
+      _.$ti = t2;
+    },
+    MappedListIterable: function MappedListIterable(t0, t1, t2) {
+      this.__internal$_source = t0;
+      this._f = t1;
+      this.$ti = t2;
+    },
+    FixedLengthListMixin: function FixedLengthListMixin() {
+    },
+    Symbol: function Symbol(t0) {
+      this.__internal$_name = t0;
+    },
+    ConstantMap__throwUnmodifiable: function() {
+      throw H.wrapException(P.UnsupportedError$("Cannot modify unmodifiable Map"));
+    },
+    unminifyOrTag: function(rawClassName) {
+      var preserved = H.unmangleGlobalNameIfPreservedAnyways(rawClassName);
+      if (preserved != null)
+        return preserved;
+      return rawClassName;
+    },
+    isJsIndexable: function(object, record) {
+      var result;
+      if (record != null) {
+        result = record.x;
+        if (result != null)
+          return result;
+      }
+      return type$.JavaScriptIndexingBehavior_dynamic._is(object);
+    },
+    S: function(value) {
+      var res;
+      if (typeof value == "string")
+        return value;
+      if (typeof value == "number") {
+        if (value !== 0)
+          return "" + value;
+      } else if (true === value)
+        return "true";
+      else if (false === value)
+        return "false";
+      else if (value == null)
+        return "null";
+      res = J.toString$0$(value);
+      if (typeof res != "string")
+        throw H.wrapException(H.argumentErrorValue(value));
+      return res;
+    },
+    Primitives_objectHashCode: function(object) {
+      var hash = object.$identityHash;
+      if (hash == null) {
+        hash = Math.random() * 0x3fffffff | 0;
+        object.$identityHash = hash;
+      }
+      return hash;
+    },
+    Primitives_parseInt: function(source, radix) {
+      var match, decimalMatch;
+      if (typeof source != "string")
+        H.throwExpression(H.argumentErrorValue(source));
+      match = /^\s*[+-]?((0x[a-f0-9]+)|(\d+)|([a-z0-9]+))\s*$/i.exec(source);
+      if (match == null)
+        return null;
+      if (3 >= match.length)
+        return H.ioore(match, 3);
+      decimalMatch = match[3];
+      if (decimalMatch != null)
+        return parseInt(source, 10);
+      if (match[2] != null)
+        return parseInt(source, 16);
+      return null;
+    },
+    Primitives_objectTypeName: function(object) {
+      var t1 = H.Primitives__objectTypeNameNewRti(object);
+      return t1;
+    },
+    Primitives__objectTypeNameNewRti: function(object) {
+      var dispatchName, $constructor, constructorName;
+      if (object instanceof P.Object)
+        return H._rtiToString(H.instanceType(object), null);
+      if (J.getInterceptor$(object) === C.Interceptor_methods || type$.UnknownJavaScriptObject._is(object)) {
+        dispatchName = C.C_JS_CONST(object);
+        if (H.Primitives__saneNativeClassName(dispatchName))
+          return dispatchName;
+        $constructor = object.constructor;
+        if (typeof $constructor == "function") {
+          constructorName = $constructor.name;
+          if (typeof constructorName == "string" && H.Primitives__saneNativeClassName(constructorName))
+            return constructorName;
+        }
+      }
+      return H._rtiToString(H.instanceType(object), null);
+    },
+    Primitives__saneNativeClassName: function($name) {
+      var t1 = $name !== "Object" && $name !== "";
+      return t1;
+    },
+    Primitives__fromCharCodeApply: function(array) {
+      var result, i, i0, chunkEnd,
+        end = array.length;
+      if (end <= 500)
+        return String.fromCharCode.apply(null, array);
+      for (result = "", i = 0; i < end; i = i0) {
+        i0 = i + 500;
+        chunkEnd = i0 < end ? i0 : end;
+        result += String.fromCharCode.apply(null, array.slice(i, chunkEnd));
+      }
+      return result;
+    },
+    Primitives_stringFromCodePoints: function(codePoints) {
+      var t1, _i, i,
+        a = H.setRuntimeTypeInfo([], type$.JSArray_int);
+      for (t1 = codePoints.length, _i = 0; _i < codePoints.length; codePoints.length === t1 || (0, H.throwConcurrentModificationError)(codePoints), ++_i) {
+        i = codePoints[_i];
+        if (!H._isInt(i))
+          throw H.wrapException(H.argumentErrorValue(i));
+        if (i <= 65535)
+          C.JSArray_methods.add$1(a, i);
+        else if (i <= 1114111) {
+          C.JSArray_methods.add$1(a, 55296 + (C.JSInt_methods._shrOtherPositive$1(i - 65536, 10) & 1023));
+          C.JSArray_methods.add$1(a, 56320 + (i & 1023));
+        } else
+          throw H.wrapException(H.argumentErrorValue(i));
+      }
+      return H.Primitives__fromCharCodeApply(a);
+    },
+    Primitives_stringFromCharCodes: function(charCodes) {
+      var t1, _i, i;
+      for (t1 = charCodes.length, _i = 0; _i < t1; ++_i) {
+        i = charCodes[_i];
+        if (!H._isInt(i))
+          throw H.wrapException(H.argumentErrorValue(i));
+        if (i < 0)
+          throw H.wrapException(H.argumentErrorValue(i));
+        if (i > 65535)
+          return H.Primitives_stringFromCodePoints(charCodes);
+      }
+      return H.Primitives__fromCharCodeApply(charCodes);
+    },
+    Primitives_stringFromNativeUint8List: function(charCodes, start, end) {
+      var i, result, i0, chunkEnd;
+      if (end <= 500 && start === 0 && end === charCodes.length)
+        return String.fromCharCode.apply(null, charCodes);
+      for (i = start, result = ""; i < end; i = i0) {
+        i0 = i + 500;
+        chunkEnd = i0 < end ? i0 : end;
+        result += String.fromCharCode.apply(null, charCodes.subarray(i, chunkEnd));
+      }
+      return result;
+    },
+    Primitives_stringFromCharCode: function(charCode) {
+      var bits;
+      if (charCode <= 65535)
+        return String.fromCharCode(charCode);
+      if (charCode <= 1114111) {
+        bits = charCode - 65536;
+        return String.fromCharCode((55296 | C.JSInt_methods._shrOtherPositive$1(bits, 10)) >>> 0, 56320 | bits & 1023);
+      }
+      throw H.wrapException(P.RangeError$range(charCode, 0, 1114111, null, null));
+    },
+    Primitives_lazyAsJsDate: function(receiver) {
+      if (receiver.date === void 0)
+        receiver.date = new Date(receiver._value);
+      return receiver.date;
+    },
+    Primitives_getYear: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCFullYear() + 0 : H.Primitives_lazyAsJsDate(receiver).getFullYear() + 0;
+    },
+    Primitives_getMonth: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMonth() + 1 : H.Primitives_lazyAsJsDate(receiver).getMonth() + 1;
+    },
+    Primitives_getDay: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCDate() + 0 : H.Primitives_lazyAsJsDate(receiver).getDate() + 0;
+    },
+    Primitives_getHours: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCHours() + 0 : H.Primitives_lazyAsJsDate(receiver).getHours() + 0;
+    },
+    Primitives_getMinutes: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMinutes() + 0 : H.Primitives_lazyAsJsDate(receiver).getMinutes() + 0;
+    },
+    Primitives_getSeconds: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCSeconds() + 0 : H.Primitives_lazyAsJsDate(receiver).getSeconds() + 0;
+    },
+    Primitives_getMilliseconds: function(receiver) {
+      return receiver.isUtc ? H.Primitives_lazyAsJsDate(receiver).getUTCMilliseconds() + 0 : H.Primitives_lazyAsJsDate(receiver).getMilliseconds() + 0;
+    },
+    Primitives_functionNoSuchMethod: function($function, positionalArguments, namedArguments) {
+      var $arguments, namedArgumentList, t1 = {};
+      t1.argumentCount = 0;
+      $arguments = [];
+      namedArgumentList = [];
+      t1.argumentCount = positionalArguments.length;
+      C.JSArray_methods.addAll$1($arguments, positionalArguments);
+      t1.names = "";
+      if (namedArguments != null && !namedArguments.get$isEmpty(namedArguments))
+        namedArguments.forEach$1(0, new H.Primitives_functionNoSuchMethod_closure(t1, namedArgumentList, $arguments));
+      "" + t1.argumentCount;
+      return J.noSuchMethod$1$($function, new H.JSInvocationMirror(C.Symbol_call, 0, $arguments, namedArgumentList, 0));
+    },
+    Primitives_applyFunction: function($function, positionalArguments, namedArguments) {
+      var t1, $arguments, argumentCount, jsStub;
+      if (positionalArguments instanceof Array)
+        t1 = namedArguments == null || namedArguments.get$isEmpty(namedArguments);
+      else
+        t1 = false;
+      if (t1) {
+        $arguments = positionalArguments;
+        argumentCount = $arguments.length;
+        if (argumentCount === 0) {
+          if (!!$function.call$0)
+            return $function.call$0();
+        } else if (argumentCount === 1) {
+          if (!!$function.call$1)
+            return $function.call$1($arguments[0]);
+        } else if (argumentCount === 2) {
+          if (!!$function.call$2)
+            return $function.call$2($arguments[0], $arguments[1]);
+        } else if (argumentCount === 3) {
+          if (!!$function.call$3)
+            return $function.call$3($arguments[0], $arguments[1], $arguments[2]);
+        } else if (argumentCount === 4) {
+          if (!!$function.call$4)
+            return $function.call$4($arguments[0], $arguments[1], $arguments[2], $arguments[3]);
+        } else if (argumentCount === 5)
+          if (!!$function.call$5)
+            return $function.call$5($arguments[0], $arguments[1], $arguments[2], $arguments[3], $arguments[4]);
+        jsStub = $function["call" + "$" + argumentCount];
+        if (jsStub != null)
+          return jsStub.apply($function, $arguments);
+      }
+      return H.Primitives__genericApplyFunction2($function, positionalArguments, namedArguments);
+    },
+    Primitives__genericApplyFunction2: function($function, positionalArguments, namedArguments) {
+      var $arguments, argumentCount, requiredParameterCount, defaultValuesClosure, t1, defaultValues, interceptor, jsFunction, keys, _i, defaultValue, used, key;
+      if (positionalArguments != null)
+        $arguments = positionalArguments instanceof Array ? positionalArguments : P.List_List$from(positionalArguments, true, type$.dynamic);
+      else
+        $arguments = [];
+      argumentCount = $arguments.length;
+      requiredParameterCount = $function.$requiredArgCount;
+      if (argumentCount < requiredParameterCount)
+        return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+      defaultValuesClosure = $function.$defaultValues;
+      t1 = defaultValuesClosure == null;
+      defaultValues = !t1 ? defaultValuesClosure() : null;
+      interceptor = J.getInterceptor$($function);
+      jsFunction = interceptor["call*"];
+      if (typeof jsFunction == "string")
+        jsFunction = interceptor[jsFunction];
+      if (t1) {
+        if (namedArguments != null && namedArguments.get$isNotEmpty(namedArguments))
+          return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+        if (argumentCount === requiredParameterCount)
+          return jsFunction.apply($function, $arguments);
+        return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+      }
+      if (defaultValues instanceof Array) {
+        if (namedArguments != null && namedArguments.get$isNotEmpty(namedArguments))
+          return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+        if (argumentCount > requiredParameterCount + defaultValues.length)
+          return H.Primitives_functionNoSuchMethod($function, $arguments, null);
+        C.JSArray_methods.addAll$1($arguments, defaultValues.slice(argumentCount - requiredParameterCount));
+        return jsFunction.apply($function, $arguments);
+      } else {
+        if (argumentCount > requiredParameterCount)
+          return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+        keys = Object.keys(defaultValues);
+        if (namedArguments == null)
+          for (t1 = keys.length, _i = 0; _i < keys.length; keys.length === t1 || (0, H.throwConcurrentModificationError)(keys), ++_i) {
+            defaultValue = defaultValues[H._asStringS(keys[_i])];
+            if (C.C__Required === defaultValue)
+              return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+            C.JSArray_methods.add$1($arguments, defaultValue);
+          }
+        else {
+          for (t1 = keys.length, used = 0, _i = 0; _i < keys.length; keys.length === t1 || (0, H.throwConcurrentModificationError)(keys), ++_i) {
+            key = H._asStringS(keys[_i]);
+            if (namedArguments.containsKey$1(key)) {
+              ++used;
+              C.JSArray_methods.add$1($arguments, namedArguments.$index(0, key));
+            } else {
+              defaultValue = defaultValues[key];
+              if (C.C__Required === defaultValue)
+                return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+              C.JSArray_methods.add$1($arguments, defaultValue);
+            }
+          }
+          if (used !== namedArguments.get$length(namedArguments))
+            return H.Primitives_functionNoSuchMethod($function, $arguments, namedArguments);
+        }
+        return jsFunction.apply($function, $arguments);
+      }
+    },
+    iae: function(argument) {
+      throw H.wrapException(H.argumentErrorValue(argument));
+    },
+    ioore: function(receiver, index) {
+      if (receiver == null)
+        J.get$length$asx(receiver);
+      throw H.wrapException(H.diagnoseIndexError(receiver, index));
+    },
+    diagnoseIndexError: function(indexable, index) {
+      var $length, t1, _s5_ = "index";
+      if (!H._isInt(index))
+        return new P.ArgumentError(true, index, _s5_, null);
+      $length = H._asIntS(J.get$length$asx(indexable));
+      if (!(index < 0)) {
+        if (typeof $length !== "number")
+          return H.iae($length);
+        t1 = index >= $length;
+      } else
+        t1 = true;
+      if (t1)
+        return P.IndexError$(index, indexable, _s5_, null, $length);
+      return P.RangeError$value(index, _s5_);
+    },
+    argumentErrorValue: function(object) {
+      return new P.ArgumentError(true, object, null, null);
+    },
+    checkBool: function(value) {
+      return value;
+    },
+    wrapException: function(ex) {
+      var wrapper, t1;
+      if (ex == null)
+        ex = new P.NullThrownError();
+      wrapper = new Error();
+      wrapper.dartException = ex;
+      t1 = H.toStringWrapper;
+      if ("defineProperty" in Object) {
+        Object.defineProperty(wrapper, "message", {get: t1});
+        wrapper.name = "";
+      } else
+        wrapper.toString = t1;
+      return wrapper;
+    },
+    toStringWrapper: function() {
+      return J.toString$0$(this.dartException);
+    },
+    throwExpression: function(ex) {
+      throw H.wrapException(ex);
+    },
+    throwConcurrentModificationError: function(collection) {
+      throw H.wrapException(P.ConcurrentModificationError$(collection));
+    },
+    TypeErrorDecoder_extractPattern: function(message) {
+      var match, $arguments, argumentsExpr, expr, method, receiver;
+      message = H.quoteStringForRegExp(message.replace(String({}), '$receiver$'));
+      match = message.match(/\\\$[a-zA-Z]+\\\$/g);
+      if (match == null)
+        match = H.setRuntimeTypeInfo([], type$.JSArray_String);
+      $arguments = match.indexOf("\\$arguments\\$");
+      argumentsExpr = match.indexOf("\\$argumentsExpr\\$");
+      expr = match.indexOf("\\$expr\\$");
+      method = match.indexOf("\\$method\\$");
+      receiver = match.indexOf("\\$receiver\\$");
+      return new H.TypeErrorDecoder(message.replace(new RegExp('\\\\\\$arguments\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$argumentsExpr\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$expr\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$method\\\\\\$', 'g'), '((?:x|[^x])*)').replace(new RegExp('\\\\\\$receiver\\\\\\$', 'g'), '((?:x|[^x])*)'), $arguments, argumentsExpr, expr, method, receiver);
+    },
+    TypeErrorDecoder_provokeCallErrorOn: function(expression) {
+      return function($expr$) {
+        var $argumentsExpr$ = '$arguments$';
+        try {
+          $expr$.$method$($argumentsExpr$);
+        } catch (e) {
+          return e.message;
+        }
+      }(expression);
+    },
+    TypeErrorDecoder_provokePropertyErrorOn: function(expression) {
+      return function($expr$) {
+        try {
+          $expr$.$method$;
+        } catch (e) {
+          return e.message;
+        }
+      }(expression);
+    },
+    NullError$: function(_message, match) {
+      return new H.NullError(_message, match == null ? null : match.method);
+    },
+    JsNoSuchMethodError$: function(_message, match) {
+      var t1 = match == null,
+        t2 = t1 ? null : match.method;
+      return new H.JsNoSuchMethodError(_message, t2, t1 ? null : match.receiver);
+    },
+    unwrapException: function(ex) {
+      if (ex == null)
+        return new H.NullThrownFromJavaScriptException(ex);
+      if (ex instanceof H.ExceptionAndStackTrace)
+        return H.saveStackTrace(ex, ex.dartException);
+      if (typeof ex !== "object")
+        return ex;
+      if ("dartException" in ex)
+        return H.saveStackTrace(ex, ex.dartException);
+      return H._unwrapNonDartException(ex);
+    },
+    saveStackTrace: function(ex, error) {
+      if (type$.Error._is(error))
+        if (error.$thrownJsError == null)
+          error.$thrownJsError = ex;
+      return error;
+    },
+    _unwrapNonDartException: function(ex) {
+      var message, number, ieErrorCode, nsme, notClosure, nullCall, nullLiteralCall, undefCall, undefLiteralCall, nullProperty, undefProperty, undefLiteralProperty, match, t1, _null = null;
+      if (!("message" in ex))
+        return ex;
+      message = ex.message;
+      if ("number" in ex && typeof ex.number == "number") {
+        number = ex.number;
+        ieErrorCode = number & 65535;
+        if ((C.JSInt_methods._shrOtherPositive$1(number, 16) & 8191) === 10)
+          switch (ieErrorCode) {
+            case 438:
+              return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H.S(message) + " (Error " + ieErrorCode + ")", _null));
+            case 445:
+            case 5007:
+              return H.saveStackTrace(ex, H.NullError$(H.S(message) + " (Error " + ieErrorCode + ")", _null));
+          }
+      }
+      if (ex instanceof TypeError) {
+        nsme = $.$get$TypeErrorDecoder_noSuchMethodPattern();
+        notClosure = $.$get$TypeErrorDecoder_notClosurePattern();
+        nullCall = $.$get$TypeErrorDecoder_nullCallPattern();
+        nullLiteralCall = $.$get$TypeErrorDecoder_nullLiteralCallPattern();
+        undefCall = $.$get$TypeErrorDecoder_undefinedCallPattern();
+        undefLiteralCall = $.$get$TypeErrorDecoder_undefinedLiteralCallPattern();
+        nullProperty = $.$get$TypeErrorDecoder_nullPropertyPattern();
+        $.$get$TypeErrorDecoder_nullLiteralPropertyPattern();
+        undefProperty = $.$get$TypeErrorDecoder_undefinedPropertyPattern();
+        undefLiteralProperty = $.$get$TypeErrorDecoder_undefinedLiteralPropertyPattern();
+        match = nsme.matchTypeError$1(message);
+        if (match != null)
+          return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H._asStringS(message), match));
+        else {
+          match = notClosure.matchTypeError$1(message);
+          if (match != null) {
+            match.method = "call";
+            return H.saveStackTrace(ex, H.JsNoSuchMethodError$(H._asStringS(message), match));
+          } else {
+            match = nullCall.matchTypeError$1(message);
+            if (match == null) {
+              match = nullLiteralCall.matchTypeError$1(message);
+              if (match == null) {
+                match = undefCall.matchTypeError$1(message);
+                if (match == null) {
+                  match = undefLiteralCall.matchTypeError$1(message);
+                  if (match == null) {
+                    match = nullProperty.matchTypeError$1(message);
+                    if (match == null) {
+                      match = nullLiteralCall.matchTypeError$1(message);
+                      if (match == null) {
+                        match = undefProperty.matchTypeError$1(message);
+                        if (match == null) {
+                          match = undefLiteralProperty.matchTypeError$1(message);
+                          t1 = match != null;
+                        } else
+                          t1 = true;
+                      } else
+                        t1 = true;
+                    } else
+                      t1 = true;
+                  } else
+                    t1 = true;
+                } else
+                  t1 = true;
+              } else
+                t1 = true;
+            } else
+              t1 = true;
+            if (t1)
+              return H.saveStackTrace(ex, H.NullError$(H._asStringS(message), match));
+          }
+        }
+        return H.saveStackTrace(ex, new H.UnknownJsTypeError(typeof message == "string" ? message : ""));
+      }
+      if (ex instanceof RangeError) {
+        if (typeof message == "string" && message.indexOf("call stack") !== -1)
+          return new P.StackOverflowError();
+        message = function(ex) {
+          try {
+            return String(ex);
+          } catch (e) {
+          }
+          return null;
+        }(ex);
+        return H.saveStackTrace(ex, new P.ArgumentError(false, _null, _null, typeof message == "string" ? message.replace(/^RangeError:\s*/, "") : message));
+      }
+      if (typeof InternalError == "function" && ex instanceof InternalError)
+        if (typeof message == "string" && message === "too much recursion")
+          return new P.StackOverflowError();
+      return ex;
+    },
+    getTraceFromException: function(exception) {
+      var trace;
+      if (exception instanceof H.ExceptionAndStackTrace)
+        return exception.stackTrace;
+      if (exception == null)
+        return new H._StackTrace(exception);
+      trace = exception.$cachedTrace;
+      if (trace != null)
+        return trace;
+      return exception.$cachedTrace = new H._StackTrace(exception);
+    },
+    fillLiteralMap: function(keyValuePairs, result) {
+      var index, index0, index1,
+        $length = keyValuePairs.length;
+      for (index = 0; index < $length; index = index1) {
+        index0 = index + 1;
+        index1 = index0 + 1;
+        result.$indexSet(0, keyValuePairs[index], keyValuePairs[index0]);
+      }
+      return result;
+    },
+    invokeClosure: function(closure, numberOfArguments, arg1, arg2, arg3, arg4) {
+      type$.Function._as(closure);
+      switch (H._asIntS(numberOfArguments)) {
+        case 0:
+          return closure.call$0();
+        case 1:
+          return closure.call$1(arg1);
+        case 2:
+          return closure.call$2(arg1, arg2);
+        case 3:
+          return closure.call$3(arg1, arg2, arg3);
+        case 4:
+          return closure.call$4(arg1, arg2, arg3, arg4);
+      }
+      throw H.wrapException(P.Exception_Exception("Unsupported number of arguments for wrapped closure"));
+    },
+    convertDartClosureToJS: function(closure, arity) {
+      var $function;
+      if (closure == null)
+        return null;
+      $function = closure.$identity;
+      if (!!$function)
+        return $function;
+      $function = function(closure, arity, invoke) {
+        return function(a1, a2, a3, a4) {
+          return invoke(closure, arity, a1, a2, a3, a4);
+        };
+      }(closure, arity, H.invokeClosure);
+      closure.$identity = $function;
+      return $function;
+    },
+    Closure_fromTearOff: function(receiver, functions, applyTrampolineIndex, reflectionInfo, isStatic, isIntercepted, propertyName) {
+      var $constructor, t1, trampoline, signatureFunction, applyTrampoline, i, stub, stubCallName,
+        $function = functions[0],
+        callName = $function.$callName,
+        $prototype = isStatic ? Object.create(new H.StaticClosure().constructor.prototype) : Object.create(new H.BoundClosure(null, null, null, "").constructor.prototype);
+      $prototype.$initialize = $prototype.constructor;
+      if (isStatic)
+        $constructor = function static_tear_off() {
+          this.$initialize();
+        };
+      else {
+        t1 = $.Closure_functionCounter;
+        if (typeof t1 !== "number")
+          return t1.$add();
+        $.Closure_functionCounter = t1 + 1;
+        t1 = new Function("a,b,c,d" + t1, "this.$initialize(a,b,c,d" + t1 + ")");
+        $constructor = t1;
+      }
+      $prototype.constructor = $constructor;
+      $constructor.prototype = $prototype;
+      if (!isStatic) {
+        trampoline = H.Closure_forwardCallTo(receiver, $function, isIntercepted);
+        trampoline.$reflectionInfo = reflectionInfo;
+      } else {
+        $prototype.$static_name = propertyName;
+        trampoline = $function;
+      }
+      signatureFunction = H.Closure__computeSignatureFunctionNewRti(reflectionInfo, isStatic, isIntercepted);
+      $prototype.$signature = signatureFunction;
+      $prototype[callName] = trampoline;
+      for (applyTrampoline = trampoline, i = 1; i < functions.length; ++i) {
+        stub = functions[i];
+        stubCallName = stub.$callName;
+        if (stubCallName != null) {
+          stub = isStatic ? stub : H.Closure_forwardCallTo(receiver, stub, isIntercepted);
+          $prototype[stubCallName] = stub;
+        }
+        if (i === applyTrampolineIndex) {
+          stub.$reflectionInfo = reflectionInfo;
+          applyTrampoline = stub;
+        }
+      }
+      $prototype["call*"] = applyTrampoline;
+      $prototype.$requiredArgCount = $function.$requiredArgCount;
+      $prototype.$defaultValues = $function.$defaultValues;
+      return $constructor;
+    },
+    Closure__computeSignatureFunctionNewRti: function(functionType, isStatic, isIntercepted) {
+      var typeEvalMethod;
+      if (typeof functionType == "number")
+        return function(getType, t) {
+          return function() {
+            return getType(t);
+          };
+        }(H.getTypeFromTypesTable, functionType);
+      if (typeof functionType == "string") {
+        if (isStatic)
+          throw H.wrapException("Cannot compute signature for static tearoff.");
+        typeEvalMethod = isIntercepted ? H.BoundClosure_evalRecipeIntercepted : H.BoundClosure_evalRecipe;
+        return function(recipe, evalOnReceiver) {
+          return function() {
+            return evalOnReceiver(this, recipe);
+          };
+        }(functionType, typeEvalMethod);
+      }
+      throw H.wrapException("Error in functionType of tearoff");
+    },
+    Closure_cspForwardCall: function(arity, isSuperCall, stubName, $function) {
+      var getSelf = H.BoundClosure_selfOf;
+      switch (isSuperCall ? -1 : arity) {
+        case 0:
+          return function(n, S) {
+            return function() {
+              return S(this)[n]();
+            };
+          }(stubName, getSelf);
+        case 1:
+          return function(n, S) {
+            return function(a) {
+              return S(this)[n](a);
+            };
+          }(stubName, getSelf);
+        case 2:
+          return function(n, S) {
+            return function(a, b) {
+              return S(this)[n](a, b);
+            };
+          }(stubName, getSelf);
+        case 3:
+          return function(n, S) {
+            return function(a, b, c) {
+              return S(this)[n](a, b, c);
+            };
+          }(stubName, getSelf);
+        case 4:
+          return function(n, S) {
+            return function(a, b, c, d) {
+              return S(this)[n](a, b, c, d);
+            };
+          }(stubName, getSelf);
+        case 5:
+          return function(n, S) {
+            return function(a, b, c, d, e) {
+              return S(this)[n](a, b, c, d, e);
+            };
+          }(stubName, getSelf);
+        default:
+          return function(f, s) {
+            return function() {
+              return f.apply(s(this), arguments);
+            };
+          }($function, getSelf);
+      }
+    },
+    Closure_forwardCallTo: function(receiver, $function, isIntercepted) {
+      var stubName, arity, lookedUpFunction, t1, t2, selfName, $arguments;
+      if (isIntercepted)
+        return H.Closure_forwardInterceptedCallTo(receiver, $function);
+      stubName = $function.$stubName;
+      arity = $function.length;
+      lookedUpFunction = receiver[stubName];
+      t1 = $function == null ? lookedUpFunction == null : $function === lookedUpFunction;
+      t2 = !t1 || arity >= 27;
+      if (t2)
+        return H.Closure_cspForwardCall(arity, !t1, stubName, $function);
+      if (arity === 0) {
+        t1 = $.Closure_functionCounter;
+        if (typeof t1 !== "number")
+          return t1.$add();
+        $.Closure_functionCounter = t1 + 1;
+        selfName = "self" + t1;
+        return new Function("return function(){var " + selfName + " = this." + H.S(H.BoundClosure_selfFieldName()) + ";return " + selfName + "." + H.S(stubName) + "();}")();
+      }
+      $arguments = "abcdefghijklmnopqrstuvwxyz".split("").splice(0, arity).join(",");
+      t1 = $.Closure_functionCounter;
+      if (typeof t1 !== "number")
+        return t1.$add();
+      $.Closure_functionCounter = t1 + 1;
+      $arguments += t1;
+      return new Function("return function(" + $arguments + "){return this." + H.S(H.BoundClosure_selfFieldName()) + "." + H.S(stubName) + "(" + $arguments + ");}")();
+    },
+    Closure_cspForwardInterceptedCall: function(arity, isSuperCall, $name, $function) {
+      var getSelf = H.BoundClosure_selfOf,
+        getReceiver = H.BoundClosure_receiverOf;
+      switch (isSuperCall ? -1 : arity) {
+        case 0:
+          throw H.wrapException(H.RuntimeError$("Intercepted function with no arguments."));
+        case 1:
+          return function(n, s, r) {
+            return function() {
+              return s(this)[n](r(this));
+            };
+          }($name, getSelf, getReceiver);
+        case 2:
+          return function(n, s, r) {
+            return function(a) {
+              return s(this)[n](r(this), a);
+            };
+          }($name, getSelf, getReceiver);
+        case 3:
+          return function(n, s, r) {
+            return function(a, b) {
+              return s(this)[n](r(this), a, b);
+            };
+          }($name, getSelf, getReceiver);
+        case 4:
+          return function(n, s, r) {
+            return function(a, b, c) {
+              return s(this)[n](r(this), a, b, c);
+            };
+          }($name, getSelf, getReceiver);
+        case 5:
+          return function(n, s, r) {
+            return function(a, b, c, d) {
+              return s(this)[n](r(this), a, b, c, d);
+            };
+          }($name, getSelf, getReceiver);
+        case 6:
+          return function(n, s, r) {
+            return function(a, b, c, d, e) {
+              return s(this)[n](r(this), a, b, c, d, e);
+            };
+          }($name, getSelf, getReceiver);
+        default:
+          return function(f, s, r, a) {
+            return function() {
+              a = [r(this)];
+              Array.prototype.push.apply(a, arguments);
+              return f.apply(s(this), a);
+            };
+          }($function, getSelf, getReceiver);
+      }
+    },
+    Closure_forwardInterceptedCallTo: function(receiver, $function) {
+      var stubName, arity, lookedUpFunction, t1, t2, $arguments,
+        selfField = H.BoundClosure_selfFieldName(),
+        receiverField = $.BoundClosure_receiverFieldNameCache;
+      if (receiverField == null)
+        receiverField = $.BoundClosure_receiverFieldNameCache = H.BoundClosure_computeFieldNamed("receiver");
+      stubName = $function.$stubName;
+      arity = $function.length;
+      lookedUpFunction = receiver[stubName];
+      t1 = $function == null ? lookedUpFunction == null : $function === lookedUpFunction;
+      t2 = !t1 || arity >= 28;
+      if (t2)
+        return H.Closure_cspForwardInterceptedCall(arity, !t1, stubName, $function);
+      if (arity === 1) {
+        t1 = "return function(){return this." + H.S(selfField) + "." + H.S(stubName) + "(this." + receiverField + ");";
+        t2 = $.Closure_functionCounter;
+        if (typeof t2 !== "number")
+          return t2.$add();
+        $.Closure_functionCounter = t2 + 1;
+        return new Function(t1 + t2 + "}")();
+      }
+      $arguments = "abcdefghijklmnopqrstuvwxyz".split("").splice(0, arity - 1).join(",");
+      t1 = "return function(" + $arguments + "){return this." + H.S(selfField) + "." + H.S(stubName) + "(this." + receiverField + ", " + $arguments + ");";
+      t2 = $.Closure_functionCounter;
+      if (typeof t2 !== "number")
+        return t2.$add();
+      $.Closure_functionCounter = t2 + 1;
+      return new Function(t1 + t2 + "}")();
+    },
+    closureFromTearOff: function(receiver, functions, applyTrampolineIndex, reflectionInfo, isStatic, isIntercepted, $name) {
+      return H.Closure_fromTearOff(receiver, functions, applyTrampolineIndex, reflectionInfo, !!isStatic, !!isIntercepted, $name);
+    },
+    BoundClosure_evalRecipe: function(closure, recipe) {
+      return H._Universe_evalInEnvironment(init.typeUniverse, H.instanceType(closure._self), recipe);
+    },
+    BoundClosure_evalRecipeIntercepted: function(closure, recipe) {
+      return H._Universe_evalInEnvironment(init.typeUniverse, H.instanceType(closure._receiver), recipe);
+    },
+    BoundClosure_selfOf: function(closure) {
+      return closure._self;
+    },
+    BoundClosure_receiverOf: function(closure) {
+      return closure._receiver;
+    },
+    BoundClosure_selfFieldName: function() {
+      var t1 = $.BoundClosure_selfFieldNameCache;
+      return t1 == null ? $.BoundClosure_selfFieldNameCache = H.BoundClosure_computeFieldNamed("self") : t1;
+    },
+    BoundClosure_computeFieldNamed: function(fieldName) {
+      var t1, i, $name,
+        template = new H.BoundClosure("self", "target", "receiver", "name"),
+        names = J.JSArray_markFixedList(Object.getOwnPropertyNames(template), type$.dynamic);
+      for (t1 = names.length, i = 0; i < t1; ++i) {
+        $name = names[i];
+        if (template[$name] === fieldName)
+          return $name;
+      }
+      throw H.wrapException(P.ArgumentError$("Field name " + fieldName + " not found."));
+    },
+    boolConversionCheck: function(value) {
+      if (value == null)
+        H.assertThrow("boolean expression must not be null");
+      return value;
+    },
+    assertThrow: function(message) {
+      throw H.wrapException(new H._AssertionError(message));
+    },
+    throwCyclicInit: function(staticName) {
+      throw H.wrapException(new P.CyclicInitializationError(staticName));
+    },
+    RuntimeError$: function(message) {
+      return new H.RuntimeError(message);
+    },
+    getIsolateAffinityTag: function($name) {
+      return init.getIsolateTag($name);
+    },
+    setRuntimeTypeInfo: function(target, rti) {
+      target[init.arrayRti] = rti;
+      return target;
+    },
+    getRuntimeTypeInfo: function(target) {
+      if (target == null)
+        return null;
+      return target.$ti;
+    },
+    getRuntimeTypeArguments: function(interceptor, object, substitutionName) {
+      return H.substitute(interceptor["$as" + H.S(substitutionName)], H.getRuntimeTypeInfo(object));
+    },
+    getRuntimeType: function(object) {
+      var rti = object instanceof H.Closure ? H.closureFunctionType(object) : null;
+      return H.createRuntimeType(rti == null ? H.instanceType(object) : rti);
+    },
+    substitute: function(substitution, $arguments) {
+      if (substitution == null)
+        return $arguments;
+      substitution = substitution.apply(null, $arguments);
+      if (substitution == null)
+        return null;
+      if (Array.isArray(substitution))
+        return substitution;
+      if (typeof substitution == "function")
+        return substitution.apply(null, $arguments);
+      return $arguments;
+    },
+    computeSignature: function(signature, context, contextName) {
+      return signature.apply(context, H.getRuntimeTypeArguments(J.getInterceptor$(context), context, contextName));
+    },
+    defineProperty: function(obj, property, value) {
+      Object.defineProperty(obj, property, {value: value, enumerable: false, writable: true, configurable: true});
+    },
+    lookupAndCacheInterceptor: function(obj) {
+      var interceptor, interceptorClass, altTag, mark, t1,
+        tag = H._asStringS($.getTagFunction.call$1(obj)),
+        record = $.dispatchRecordsForInstanceTags[tag];
+      if (record != null) {
+        Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
+        return record.i;
+      }
+      interceptor = $.interceptorsForUncacheableTags[tag];
+      if (interceptor != null)
+        return interceptor;
+      interceptorClass = init.interceptorsByTag[tag];
+      if (interceptorClass == null) {
+        altTag = H._asStringQ($.alternateTagFunction.call$2(obj, tag));
+        if (altTag != null) {
+          record = $.dispatchRecordsForInstanceTags[altTag];
+          if (record != null) {
+            Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
+            return record.i;
+          }
+          interceptor = $.interceptorsForUncacheableTags[altTag];
+          if (interceptor != null)
+            return interceptor;
+          interceptorClass = init.interceptorsByTag[altTag];
+          tag = altTag;
+        }
+      }
+      if (interceptorClass == null)
+        return null;
+      interceptor = interceptorClass.prototype;
+      mark = tag[0];
+      if (mark === "!") {
+        record = H.makeLeafDispatchRecord(interceptor);
+        $.dispatchRecordsForInstanceTags[tag] = record;
+        Object.defineProperty(obj, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
+        return record.i;
+      }
+      if (mark === "~") {
+        $.interceptorsForUncacheableTags[tag] = interceptor;
+        return interceptor;
+      }
+      if (mark === "-") {
+        t1 = H.makeLeafDispatchRecord(interceptor);
+        Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true});
+        return t1.i;
+      }
+      if (mark === "+")
+        return H.patchInteriorProto(obj, interceptor);
+      if (mark === "*")
+        throw H.wrapException(P.UnimplementedError$(tag));
+      if (init.leafTags[tag] === true) {
+        t1 = H.makeLeafDispatchRecord(interceptor);
+        Object.defineProperty(Object.getPrototypeOf(obj), init.dispatchPropertyName, {value: t1, enumerable: false, writable: true, configurable: true});
+        return t1.i;
+      } else
+        return H.patchInteriorProto(obj, interceptor);
+    },
+    patchInteriorProto: function(obj, interceptor) {
+      var proto = Object.getPrototypeOf(obj);
+      Object.defineProperty(proto, init.dispatchPropertyName, {value: J.makeDispatchRecord(interceptor, proto, null, null), enumerable: false, writable: true, configurable: true});
+      return interceptor;
+    },
+    makeLeafDispatchRecord: function(interceptor) {
+      return J.makeDispatchRecord(interceptor, false, null, !!interceptor.$isJavaScriptIndexingBehavior);
+    },
+    makeDefaultDispatchRecord: function(tag, interceptorClass, proto) {
+      var interceptor = interceptorClass.prototype;
+      if (init.leafTags[tag] === true)
+        return H.makeLeafDispatchRecord(interceptor);
+      else
+        return J.makeDispatchRecord(interceptor, proto, null, null);
+    },
+    initNativeDispatch: function() {
+      if (true === $.initNativeDispatchFlag)
+        return;
+      $.initNativeDispatchFlag = true;
+      H.initNativeDispatchContinue();
+    },
+    initNativeDispatchContinue: function() {
+      var map, tags, fun, i, tag, proto, record, interceptorClass;
+      $.dispatchRecordsForInstanceTags = Object.create(null);
+      $.interceptorsForUncacheableTags = Object.create(null);
+      H.initHooks();
+      map = init.interceptorsByTag;
+      tags = Object.getOwnPropertyNames(map);
+      if (typeof window != "undefined") {
+        window;
+        fun = function() {
+        };
+        for (i = 0; i < tags.length; ++i) {
+          tag = tags[i];
+          proto = $.prototypeForTagFunction.call$1(tag);
+          if (proto != null) {
+            record = H.makeDefaultDispatchRecord(tag, map[tag], proto);
+            if (record != null) {
+              Object.defineProperty(proto, init.dispatchPropertyName, {value: record, enumerable: false, writable: true, configurable: true});
+              fun.prototype = proto;
+            }
+          }
+        }
+      }
+      for (i = 0; i < tags.length; ++i) {
+        tag = tags[i];
+        if (/^[A-Za-z_]/.test(tag)) {
+          interceptorClass = map[tag];
+          map["!" + tag] = interceptorClass;
+          map["~" + tag] = interceptorClass;
+          map["-" + tag] = interceptorClass;
+          map["+" + tag] = interceptorClass;
+          map["*" + tag] = interceptorClass;
+        }
+      }
+    },
+    initHooks: function() {
+      var transformers, i, transformer, getTag, getUnknownTag, prototypeForTag,
+        hooks = C.C_JS_CONST0();
+      hooks = H.applyHooksTransformer(C.C_JS_CONST1, H.applyHooksTransformer(C.C_JS_CONST2, H.applyHooksTransformer(C.C_JS_CONST3, H.applyHooksTransformer(C.C_JS_CONST3, H.applyHooksTransformer(C.C_JS_CONST4, H.applyHooksTransformer(C.C_JS_CONST5, H.applyHooksTransformer(C.C_JS_CONST6(C.C_JS_CONST), hooks)))))));
+      if (typeof dartNativeDispatchHooksTransformer != "undefined") {
+        transformers = dartNativeDispatchHooksTransformer;
+        if (typeof transformers == "function")
+          transformers = [transformers];
+        if (transformers.constructor == Array)
+          for (i = 0; i < transformers.length; ++i) {
+            transformer = transformers[i];
+            if (typeof transformer == "function")
+              hooks = transformer(hooks) || hooks;
+          }
+      }
+      getTag = hooks.getTag;
+      getUnknownTag = hooks.getUnknownTag;
+      prototypeForTag = hooks.prototypeForTag;
+      $.getTagFunction = new H.initHooks_closure(getTag);
+      $.alternateTagFunction = new H.initHooks_closure0(getUnknownTag);
+      $.prototypeForTagFunction = new H.initHooks_closure1(prototypeForTag);
+    },
+    applyHooksTransformer: function(transformer, hooks) {
+      return transformer(hooks) || hooks;
+    },
+    quoteStringForRegExp: function(string) {
+      if (/[[\]{}()*+?.\\^$|]/.test(string))
+        return string.replace(/[[\]{}()*+?.\\^$|]/g, "\\$&");
+      return string;
+    },
+    ConstantMapView: function ConstantMapView(t0, t1) {
+      this._collection$_map = t0;
+      this.$ti = t1;
+    },
+    ConstantMap: function ConstantMap() {
+    },
+    ConstantMap_map_closure: function ConstantMap_map_closure(t0, t1, t2) {
+      this.$this = t0;
+      this.transform = t1;
+      this.result = t2;
+    },
+    ConstantStringMap: function ConstantStringMap(t0, t1, t2, t3) {
+      var _ = this;
+      _._length = t0;
+      _._jsObject = t1;
+      _._keys = t2;
+      _.$ti = t3;
+    },
+    _ConstantMapKeyIterable: function _ConstantMapKeyIterable(t0, t1) {
+      this._map = t0;
+      this.$ti = t1;
+    },
+    JSInvocationMirror: function JSInvocationMirror(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _._memberName = t0;
+      _.__js_helper$_kind = t1;
+      _._arguments = t2;
+      _._namedArgumentNames = t3;
+      _._typeArgumentCount = t4;
+    },
+    Primitives_functionNoSuchMethod_closure: function Primitives_functionNoSuchMethod_closure(t0, t1, t2) {
+      this._box_0 = t0;
+      this.namedArgumentList = t1;
+      this.$arguments = t2;
+    },
+    TypeErrorDecoder: function TypeErrorDecoder(t0, t1, t2, t3, t4, t5) {
+      var _ = this;
+      _._pattern = t0;
+      _._arguments = t1;
+      _._argumentsExpr = t2;
+      _._expr = t3;
+      _._method = t4;
+      _._receiver = t5;
+    },
+    NullError: function NullError(t0, t1) {
+      this._message = t0;
+      this._method = t1;
+    },
+    JsNoSuchMethodError: function JsNoSuchMethodError(t0, t1, t2) {
+      this._message = t0;
+      this._method = t1;
+      this._receiver = t2;
+    },
+    UnknownJsTypeError: function UnknownJsTypeError(t0) {
+      this._message = t0;
+    },
+    NullThrownFromJavaScriptException: function NullThrownFromJavaScriptException(t0) {
+      this._irritant = t0;
+    },
+    ExceptionAndStackTrace: function ExceptionAndStackTrace(t0, t1) {
+      this.dartException = t0;
+      this.stackTrace = t1;
+    },
+    _StackTrace: function _StackTrace(t0) {
+      this._exception = t0;
+      this._trace = null;
+    },
+    Closure: function Closure() {
+    },
+    TearOffClosure: function TearOffClosure() {
+    },
+    StaticClosure: function StaticClosure() {
+    },
+    BoundClosure: function BoundClosure(t0, t1, t2, t3) {
+      var _ = this;
+      _._self = t0;
+      _.__js_helper$_target = t1;
+      _._receiver = t2;
+      _._name = t3;
+    },
+    RuntimeError: function RuntimeError(t0) {
+      this.message = t0;
+    },
+    _AssertionError: function _AssertionError(t0) {
+      this.message = t0;
+    },
+    _Required: function _Required() {
+    },
+    JsLinkedHashMap: function JsLinkedHashMap(t0) {
+      var _ = this;
+      _._length = 0;
+      _._last = _._first = _.__js_helper$_rest = _._nums = _._strings = null;
+      _._modifications = 0;
+      _.$ti = t0;
+    },
+    JsLinkedHashMap_addAll_closure: function JsLinkedHashMap_addAll_closure(t0) {
+      this.$this = t0;
+    },
+    LinkedHashMapCell: function LinkedHashMapCell(t0, t1) {
+      var _ = this;
+      _.hashMapCellKey = t0;
+      _.hashMapCellValue = t1;
+      _._previous = _._next = null;
+    },
+    LinkedHashMapKeyIterable: function LinkedHashMapKeyIterable(t0, t1) {
+      this._map = t0;
+      this.$ti = t1;
+    },
+    LinkedHashMapKeyIterator: function LinkedHashMapKeyIterator(t0, t1, t2) {
+      var _ = this;
+      _._map = t0;
+      _._modifications = t1;
+      _.__js_helper$_current = _._cell = null;
+      _.$ti = t2;
+    },
+    initHooks_closure: function initHooks_closure(t0) {
+      this.getTag = t0;
+    },
+    initHooks_closure0: function initHooks_closure0(t0) {
+      this.getUnknownTag = t0;
+    },
+    initHooks_closure1: function initHooks_closure1(t0) {
+      this.prototypeForTag = t0;
+    },
+    _checkViewArguments: function(buffer, offsetInBytes, $length) {
+    },
+    _ensureNativeList: function(list) {
+      var t1, result, i;
+      if (type$.JSIndexable_dynamic._is(list))
+        return list;
+      t1 = J.getInterceptor$asx(list);
+      result = P.List_List$filled(t1.get$length(list), null, false, type$.dynamic);
+      for (i = 0; i < t1.get$length(list); ++i)
+        C.JSArray_methods.$indexSet(result, i, t1.$index(list, i));
+      return result;
+    },
+    NativeByteData_NativeByteData$view: function(buffer, offsetInBytes, $length) {
+      H._checkViewArguments(buffer, offsetInBytes, $length);
+      return $length == null ? new DataView(buffer, offsetInBytes) : new DataView(buffer, offsetInBytes, $length);
+    },
+    _checkValidIndex: function(index, list, $length) {
+      if (index >>> 0 !== index || index >= $length)
+        throw H.wrapException(H.diagnoseIndexError(list, index));
+    },
+    NativeByteBuffer: function NativeByteBuffer() {
+    },
+    NativeTypedData: function NativeTypedData() {
+    },
+    NativeByteData: function NativeByteData() {
+    },
+    NativeTypedArray: function NativeTypedArray() {
+    },
+    NativeTypedArrayOfDouble: function NativeTypedArrayOfDouble() {
+    },
+    NativeTypedArrayOfInt: function NativeTypedArrayOfInt() {
+    },
+    NativeFloat32List: function NativeFloat32List() {
+    },
+    NativeFloat64List: function NativeFloat64List() {
+    },
+    NativeInt16List: function NativeInt16List() {
+    },
+    NativeInt32List: function NativeInt32List() {
+    },
+    NativeInt8List: function NativeInt8List() {
+    },
+    NativeUint16List: function NativeUint16List() {
+    },
+    NativeUint32List: function NativeUint32List() {
+    },
+    NativeUint8ClampedList: function NativeUint8ClampedList() {
+    },
+    NativeUint8List: function NativeUint8List() {
+    },
+    _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin() {
+    },
+    _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin() {
+    },
+    _NativeTypedArrayOfInt_NativeTypedArray_ListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin() {
+    },
+    _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin: function _NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin() {
+    },
+    Rti__getQuestionFromStar: function(universe, rti) {
+      var question = rti._precomputed1;
+      return question == null ? rti._precomputed1 = H._Universe__lookupQuestionRti(universe, rti._primary, true) : question;
+    },
+    Rti__getFutureFromFutureOr: function(universe, rti) {
+      var future = rti._precomputed1;
+      return future == null ? rti._precomputed1 = H._Universe__lookupInterfaceRti(universe, "Future", [rti._primary]) : future;
+    },
+    Rti__isUnionOfFunctionType: function(rti) {
+      var kind = rti._kind;
+      if (kind === 6 || kind === 7 || kind === 8)
+        return H.Rti__isUnionOfFunctionType(rti._primary);
+      return kind === 11 || kind === 12;
+    },
+    Rti__getCanonicalRecipe: function(rti) {
+      return rti._canonicalRecipe;
+    },
+    findType: function(recipe) {
+      return H._Universe_eval(init.typeUniverse, recipe, false);
+    },
+    _substitute: function(universe, rti, typeArguments, depth) {
+      var baseType, substitutedBaseType, interfaceTypeArguments, substitutedInterfaceTypeArguments, base, substitutedBase, $arguments, substitutedArguments, returnType, substitutedReturnType, functionParameters, substitutedFunctionParameters, bounds, substitutedBounds, index, argument,
+        kind = rti._kind;
+      switch (kind) {
+        case 5:
+        case 1:
+        case 2:
+        case 3:
+        case 4:
+          return rti;
+        case 6:
+          baseType = rti._primary;
+          substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth);
+          if (substitutedBaseType === baseType)
+            return rti;
+          return H._Universe__lookupStarRti(universe, substitutedBaseType, true);
+        case 7:
+          baseType = rti._primary;
+          substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth);
+          if (substitutedBaseType === baseType)
+            return rti;
+          return H._Universe__lookupQuestionRti(universe, substitutedBaseType, true);
+        case 8:
+          baseType = rti._primary;
+          substitutedBaseType = H._substitute(universe, baseType, typeArguments, depth);
+          if (substitutedBaseType === baseType)
+            return rti;
+          return H._Universe__lookupFutureOrRti(universe, substitutedBaseType, true);
+        case 9:
+          interfaceTypeArguments = rti._rest;
+          substitutedInterfaceTypeArguments = H._substituteArray(universe, interfaceTypeArguments, typeArguments, depth);
+          if (substitutedInterfaceTypeArguments === interfaceTypeArguments)
+            return rti;
+          return H._Universe__lookupInterfaceRti(universe, rti._primary, substitutedInterfaceTypeArguments);
+        case 10:
+          base = rti._primary;
+          substitutedBase = H._substitute(universe, base, typeArguments, depth);
+          $arguments = rti._rest;
+          substitutedArguments = H._substituteArray(universe, $arguments, typeArguments, depth);
+          if (substitutedBase === base && substitutedArguments === $arguments)
+            return rti;
+          return H._Universe__lookupBindingRti(universe, substitutedBase, substitutedArguments);
+        case 11:
+          returnType = rti._primary;
+          substitutedReturnType = H._substitute(universe, returnType, typeArguments, depth);
+          functionParameters = rti._rest;
+          substitutedFunctionParameters = H._substituteFunctionParameters(universe, functionParameters, typeArguments, depth);
+          if (substitutedReturnType === returnType && substitutedFunctionParameters === functionParameters)
+            return rti;
+          return H._Universe__lookupFunctionRti(universe, substitutedReturnType, substitutedFunctionParameters);
+        case 12:
+          bounds = rti._rest;
+          depth += bounds.length;
+          substitutedBounds = H._substituteArray(universe, bounds, typeArguments, depth);
+          base = rti._primary;
+          substitutedBase = H._substitute(universe, base, typeArguments, depth);
+          if (substitutedBounds === bounds && substitutedBase === base)
+            return rti;
+          return H._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, true);
+        case 13:
+          index = rti._primary;
+          if (index < depth)
+            return rti;
+          argument = typeArguments[index - depth];
+          if (argument == null)
+            return rti;
+          return argument;
+        default:
+          throw H.wrapException(P.AssertionError$("Attempted to substitute unexpected RTI kind " + kind));
+      }
+    },
+    _substituteArray: function(universe, rtiArray, typeArguments, depth) {
+      var changed, i, rti, substitutedRti,
+        $length = rtiArray.length,
+        result = [];
+      for (changed = false, i = 0; i < $length; ++i) {
+        rti = rtiArray[i];
+        substitutedRti = H._substitute(universe, rti, typeArguments, depth);
+        if (substitutedRti !== rti)
+          changed = true;
+        result.push(substitutedRti);
+      }
+      return changed ? result : rtiArray;
+    },
+    _substituteNamed: function(universe, namedArray, typeArguments, depth) {
+      var changed, i, t1, t2, rti, substitutedRti,
+        $length = namedArray.length,
+        result = [];
+      for (changed = false, i = 0; i < $length; i += 3) {
+        t1 = namedArray[i];
+        t2 = namedArray[i + 1];
+        rti = namedArray[i + 2];
+        substitutedRti = H._substitute(universe, rti, typeArguments, depth);
+        if (substitutedRti !== rti)
+          changed = true;
+        result.push(t1);
+        result.push(t2);
+        result.push(substitutedRti);
+      }
+      return changed ? result : namedArray;
+    },
+    _substituteFunctionParameters: function(universe, functionParameters, typeArguments, depth) {
+      var result,
+        requiredPositional = functionParameters._requiredPositional,
+        substitutedRequiredPositional = H._substituteArray(universe, requiredPositional, typeArguments, depth),
+        optionalPositional = functionParameters._optionalPositional,
+        substitutedOptionalPositional = H._substituteArray(universe, optionalPositional, typeArguments, depth),
+        named = functionParameters._named,
+        substitutedNamed = H._substituteNamed(universe, named, typeArguments, depth);
+      if (substitutedRequiredPositional === requiredPositional && substitutedOptionalPositional === optionalPositional && substitutedNamed === named)
+        return functionParameters;
+      result = new H._FunctionParameters();
+      result._requiredPositional = substitutedRequiredPositional;
+      result._optionalPositional = substitutedOptionalPositional;
+      result._named = substitutedNamed;
+      return result;
+    },
+    closureFunctionType: function(closure) {
+      var signature = closure.$signature;
+      if (signature != null) {
+        if (typeof signature == "number")
+          return H.getTypeFromTypesTable(signature);
+        return closure.$signature();
+      }
+      return null;
+    },
+    instanceOrFunctionType: function(object, testRti) {
+      var rti;
+      if (H.Rti__isUnionOfFunctionType(testRti))
+        if (object instanceof H.Closure) {
+          rti = H.closureFunctionType(object);
+          if (rti != null)
+            return rti;
+        }
+      return H.instanceType(object);
+    },
+    instanceType: function(object) {
+      var rti;
+      if (object instanceof P.Object) {
+        rti = object.$ti;
+        return rti != null ? rti : H._instanceTypeFromConstructor(object);
+      }
+      if (Array.isArray(object))
+        return H._arrayInstanceType(object);
+      return H._instanceTypeFromConstructor(J.getInterceptor$(object));
+    },
+    _arrayInstanceType: function(object) {
+      var rti = object[init.arrayRti],
+        defaultRti = type$.JSArray_dynamic;
+      if (rti == null)
+        return defaultRti;
+      if (rti.constructor !== defaultRti.constructor)
+        return defaultRti;
+      return rti;
+    },
+    _instanceType: function(object) {
+      var rti = object.$ti;
+      return rti != null ? rti : H._instanceTypeFromConstructor(object);
+    },
+    _instanceTypeFromConstructor: function(instance) {
+      var $constructor = instance.constructor,
+        probe = $constructor.$ccache;
+      if (probe != null)
+        return probe;
+      return H._instanceTypeFromConstructorMiss(instance, $constructor);
+    },
+    _instanceTypeFromConstructorMiss: function(instance, $constructor) {
+      var effectiveConstructor = instance instanceof H.Closure ? instance.__proto__.__proto__.constructor : $constructor,
+        rti = H._Universe_findErasedType(init.typeUniverse, effectiveConstructor.name);
+      $constructor.$ccache = rti;
+      return rti;
+    },
+    getTypeFromTypesTable: function(index) {
+      var table, type, rti;
+      H._asIntS(index);
+      table = init.types;
+      type = table[index];
+      if (typeof type == "string") {
+        rti = H._Universe_eval(init.typeUniverse, type, false);
+        table[index] = rti;
+        return rti;
+      }
+      return type;
+    },
+    createRuntimeType: function(rti) {
+      var recipe, starErasedRecipe, starErasedRti,
+        type = rti._cachedRuntimeType;
+      if (type != null)
+        return type;
+      recipe = rti._canonicalRecipe;
+      starErasedRecipe = recipe.replace(/\*/g, "");
+      if (starErasedRecipe === recipe)
+        return rti._cachedRuntimeType = new H._Type(rti);
+      starErasedRti = H._Universe_eval(init.typeUniverse, starErasedRecipe, true);
+      type = starErasedRti._cachedRuntimeType;
+      return rti._cachedRuntimeType = type == null ? starErasedRti._cachedRuntimeType = new H._Type(starErasedRti) : type;
+    },
+    typeLiteral: function(recipe) {
+      return H.createRuntimeType(H._Universe_eval(init.typeUniverse, recipe, false));
+    },
+    _installSpecializedIsTest: function(object) {
+      var unstarred, isFn, testRti = this,
+        t1 = type$.Object;
+      if (testRti === t1)
+        return H._finishIsFn(testRti, object, H._isObject);
+      if (!H.isStrongTopType(testRti))
+        if (!(testRti === type$.legacy_Object))
+          t1 = testRti === t1;
+        else
+          t1 = true;
+      else
+        t1 = true;
+      if (t1)
+        return H._finishIsFn(testRti, object, H._isTop);
+      t1 = testRti._kind;
+      unstarred = t1 === 6 ? testRti._primary : testRti;
+      if (unstarred === type$.int)
+        isFn = H._isInt;
+      else if (unstarred === type$.double || unstarred === type$.num)
+        isFn = H._isNum;
+      else if (unstarred === type$.String)
+        isFn = H._isString;
+      else
+        isFn = unstarred === type$.bool ? H._isBool : null;
+      if (isFn != null)
+        return H._finishIsFn(testRti, object, isFn);
+      if (unstarred._kind === 9) {
+        t1 = unstarred._primary;
+        if (unstarred._rest.every(H.isTopType)) {
+          testRti._specializedTestResource = "$is" + t1;
+          return H._finishIsFn(testRti, object, H._isTestViaProperty);
+        }
+      } else if (t1 === 7)
+        return H._finishIsFn(testRti, object, H._generalNullableIsTestImplementation);
+      return H._finishIsFn(testRti, object, H._generalIsTestImplementation);
+    },
+    _finishIsFn: function(testRti, object, isFn) {
+      testRti._is = isFn;
+      return testRti._is(object);
+    },
+    _installSpecializedAsCheck: function(object) {
+      var t1, asFn, testRti = this;
+      if (!H.isStrongTopType(testRti))
+        if (!(testRti === type$.legacy_Object))
+          t1 = testRti === type$.Object;
+        else
+          t1 = true;
+      else
+        t1 = true;
+      if (t1)
+        asFn = H._asTop;
+      else if (testRti === type$.Object)
+        asFn = H._asObject;
+      else
+        asFn = H._generalNullableAsCheckImplementation;
+      testRti._as = asFn;
+      return testRti._as(object);
+    },
+    _nullIs: function(testRti) {
+      var t2,
+        t1 = testRti._kind;
+      if (!H.isStrongTopType(testRti))
+        if (!(testRti === type$.legacy_Object))
+          t2 = testRti === type$.Object;
+        else
+          t2 = true;
+      else
+        t2 = true;
+      return t2 || testRti === type$.legacy_Never || t1 === 7 || testRti === type$.Null || testRti === type$.JSNull;
+    },
+    _generalIsTestImplementation: function(object) {
+      var testRti = this;
+      if (object == null)
+        return H._nullIs(testRti);
+      return H._isSubtype(init.typeUniverse, H.instanceOrFunctionType(object, testRti), null, testRti, null);
+    },
+    _generalNullableIsTestImplementation: function(object) {
+      if (object == null)
+        return true;
+      return this._primary._is(object);
+    },
+    _isTestViaProperty: function(object) {
+      var t1 = this,
+        tag = t1._specializedTestResource;
+      if (object instanceof P.Object)
+        return !!object[tag];
+      return !!J.getInterceptor$(object)[tag];
+    },
+    _generalAsCheckImplementation: function(object) {
+      var testRti = this;
+      if (object == null)
+        return object;
+      else if (testRti._is(object))
+        return object;
+      H._failedAsCheck(object, testRti);
+    },
+    _generalNullableAsCheckImplementation: function(object) {
+      var testRti = this;
+      if (object == null)
+        return object;
+      else if (testRti._is(object))
+        return object;
+      H._failedAsCheck(object, testRti);
+    },
+    _failedAsCheck: function(object, testRti) {
+      throw H.wrapException(H._TypeError$fromMessage(H._Error_compose(object, H.instanceOrFunctionType(object, testRti), H._rtiToString(testRti, null))));
+    },
+    _Error_compose: function(object, objectRti, checkedTypeDescription) {
+      var objectDescription = P.Error_safeToString(object),
+        objectTypeDescription = H._rtiToString(objectRti == null ? H.instanceType(object) : objectRti, null);
+      return objectDescription + ": type '" + H.S(objectTypeDescription) + "' is not a subtype of type '" + H.S(checkedTypeDescription) + "'";
+    },
+    _TypeError$fromMessage: function(message) {
+      return new H._TypeError("TypeError: " + message);
+    },
+    _TypeError__TypeError$forType: function(object, type) {
+      return new H._TypeError("TypeError: " + H._Error_compose(object, null, type));
+    },
+    _isObject: function(object) {
+      return object != null;
+    },
+    _asObject: function(object) {
+      return object;
+    },
+    _isTop: function(object) {
+      return true;
+    },
+    _asTop: function(object) {
+      return object;
+    },
+    _isBool: function(object) {
+      return true === object || false === object;
+    },
+    _asBool: function(object) {
+      if (true === object || false === object)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "bool"));
+    },
+    _asBoolS: function(object) {
+      if (true === object || false === object)
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "bool"));
+    },
+    _asBoolQ: function(object) {
+      if (true === object || false === object)
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "bool?"));
+    },
+    _asDouble: function(object) {
+      if (typeof object == "number")
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "double"));
+    },
+    _asDoubleS: function(object) {
+      if (typeof object == "number")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "double"));
+    },
+    _asDoubleQ: function(object) {
+      if (typeof object == "number")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "double?"));
+    },
+    _isInt: function(object) {
+      return typeof object == "number" && Math.floor(object) === object;
+    },
+    _asInt: function(object) {
+      if (typeof object == "number" && Math.floor(object) === object)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "int"));
+    },
+    _asIntS: function(object) {
+      if (typeof object == "number" && Math.floor(object) === object)
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "int"));
+    },
+    _asIntQ: function(object) {
+      if (typeof object == "number" && Math.floor(object) === object)
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "int?"));
+    },
+    _isNum: function(object) {
+      return typeof object == "number";
+    },
+    _asNum: function(object) {
+      if (typeof object == "number")
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "num"));
+    },
+    _asNumS: function(object) {
+      if (typeof object == "number")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "num"));
+    },
+    _asNumQ: function(object) {
+      if (typeof object == "number")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "num?"));
+    },
+    _isString: function(object) {
+      return typeof object == "string";
+    },
+    _asString: function(object) {
+      if (typeof object == "string")
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "String"));
+    },
+    _asStringS: function(object) {
+      if (typeof object == "string")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "String"));
+    },
+    _asStringQ: function(object) {
+      if (typeof object == "string")
+        return object;
+      if (object == null)
+        return object;
+      throw H.wrapException(H._TypeError__TypeError$forType(object, "String?"));
+    },
+    _rtiArrayToString: function(array, genericContext) {
+      var s, sep, i;
+      for (s = "", sep = "", i = 0; i < array.length; ++i, sep = ", ")
+        s += C.JSString_methods.$add(sep, H._rtiToString(array[i], genericContext));
+      return s;
+    },
+    _functionRtiToString: function(functionType, genericContext, bounds) {
+      var boundsLength, outerContextLength, offset, i, t1, t2, t3, typeParametersText, typeSep, t4, t5, boundRti, kind, parameters, requiredPositional, requiredPositionalLength, optionalPositional, optionalPositionalLength, named, namedLength, returnTypeText, argumentsText, sep, _s2_ = ", ";
+      if (bounds != null) {
+        boundsLength = bounds.length;
+        if (genericContext == null) {
+          genericContext = H.setRuntimeTypeInfo([], type$.JSArray_String);
+          outerContextLength = null;
+        } else
+          outerContextLength = genericContext.length;
+        offset = genericContext.length;
+        for (i = boundsLength; i > 0; --i)
+          C.JSArray_methods.add$1(genericContext, "T" + (offset + i));
+        for (t1 = type$.nullable_Object, t2 = type$.legacy_Object, t3 = type$.Object, typeParametersText = "<", typeSep = "", i = 0; i < boundsLength; ++i, typeSep = _s2_) {
+          typeParametersText += typeSep;
+          t4 = genericContext.length;
+          t5 = t4 - 1 - i;
+          if (t5 < 0)
+            return H.ioore(genericContext, t5);
+          typeParametersText = C.JSString_methods.$add(typeParametersText, genericContext[t5]);
+          boundRti = bounds[i];
+          kind = boundRti._kind;
+          if (!(kind === 2 || kind === 3 || kind === 4 || kind === 5 || boundRti === t1))
+            if (!(boundRti === t2))
+              t4 = boundRti === t3;
+            else
+              t4 = true;
+          else
+            t4 = true;
+          if (!t4)
+            typeParametersText += C.JSString_methods.$add(" extends ", H._rtiToString(boundRti, genericContext));
+        }
+        typeParametersText += ">";
+      } else {
+        typeParametersText = "";
+        outerContextLength = null;
+      }
+      t1 = functionType._primary;
+      parameters = functionType._rest;
+      requiredPositional = parameters._requiredPositional;
+      requiredPositionalLength = requiredPositional.length;
+      optionalPositional = parameters._optionalPositional;
+      optionalPositionalLength = optionalPositional.length;
+      named = parameters._named;
+      namedLength = named.length;
+      returnTypeText = H._rtiToString(t1, genericContext);
+      for (argumentsText = "", sep = "", i = 0; i < requiredPositionalLength; ++i, sep = _s2_)
+        argumentsText += C.JSString_methods.$add(sep, H._rtiToString(requiredPositional[i], genericContext));
+      if (optionalPositionalLength > 0) {
+        argumentsText += sep + "[";
+        for (sep = "", i = 0; i < optionalPositionalLength; ++i, sep = _s2_)
+          argumentsText += C.JSString_methods.$add(sep, H._rtiToString(optionalPositional[i], genericContext));
+        argumentsText += "]";
+      }
+      if (namedLength > 0) {
+        argumentsText += sep + "{";
+        for (sep = "", i = 0; i < namedLength; i += 3, sep = _s2_) {
+          argumentsText += sep;
+          if (named[i + 1])
+            argumentsText += "required ";
+          argumentsText += J.$add$ansx(H._rtiToString(named[i + 2], genericContext), " ") + named[i];
+        }
+        argumentsText += "}";
+      }
+      if (outerContextLength != null) {
+        genericContext.toString;
+        genericContext.length = outerContextLength;
+      }
+      return typeParametersText + "(" + argumentsText + ") => " + H.S(returnTypeText);
+    },
+    _rtiToString: function(rti, genericContext) {
+      var s, questionArgument, argumentKind, $name, $arguments, t1, t2,
+        kind = rti._kind;
+      if (kind === 5)
+        return "erased";
+      if (kind === 2)
+        return "dynamic";
+      if (kind === 3)
+        return "void";
+      if (kind === 1)
+        return "Never";
+      if (kind === 4)
+        return "any";
+      if (kind === 6) {
+        s = H._rtiToString(rti._primary, genericContext);
+        return s;
+      }
+      if (kind === 7) {
+        questionArgument = rti._primary;
+        s = H._rtiToString(questionArgument, genericContext);
+        argumentKind = questionArgument._kind;
+        return J.$add$ansx(argumentKind === 11 || argumentKind === 12 ? C.JSString_methods.$add("(", s) + ")" : s, "?");
+      }
+      if (kind === 8)
+        return "FutureOr<" + H.S(H._rtiToString(rti._primary, genericContext)) + ">";
+      if (kind === 9) {
+        $name = H._unminifyOrTag(rti._primary);
+        $arguments = rti._rest;
+        return $arguments.length !== 0 ? $name + ("<" + H._rtiArrayToString($arguments, genericContext) + ">") : $name;
+      }
+      if (kind === 11)
+        return H._functionRtiToString(rti, genericContext, null);
+      if (kind === 12)
+        return H._functionRtiToString(rti._primary, genericContext, rti._rest);
+      if (kind === 13) {
+        genericContext.toString;
+        t1 = rti._primary;
+        t2 = genericContext.length;
+        t1 = t2 - 1 - t1;
+        if (t1 < 0 || t1 >= t2)
+          return H.ioore(genericContext, t1);
+        return genericContext[t1];
+      }
+      return "?";
+    },
+    _unminifyOrTag: function(rawClassName) {
+      var preserved = H.unmangleGlobalNameIfPreservedAnyways(rawClassName);
+      if (preserved != null)
+        return preserved;
+      return rawClassName;
+    },
+    _Universe_findRule: function(universe, targetType) {
+      var rule = universe.tR[targetType];
+      for (; typeof rule == "string";)
+        rule = universe.tR[rule];
+      return rule;
+    },
+    _Universe_findErasedType: function(universe, cls) {
+      var $length, erased, $arguments, i, $interface,
+        metadata = universe.eT,
+        probe = metadata[cls];
+      if (probe == null)
+        return H._Universe_eval(universe, cls, false);
+      else if (typeof probe == "number") {
+        $length = probe;
+        erased = H._Universe__lookupTerminalRti(universe, 5, "#");
+        $arguments = [];
+        for (i = 0; i < $length; ++i)
+          $arguments.push(erased);
+        $interface = H._Universe__lookupInterfaceRti(universe, cls, $arguments);
+        metadata[cls] = $interface;
+        return $interface;
+      } else
+        return probe;
+    },
+    _Universe_addRules: function(universe, rules) {
+      return H._Utils_objectAssign(universe.tR, rules);
+    },
+    _Universe_addErasedTypes: function(universe, types) {
+      return H._Utils_objectAssign(universe.eT, types);
+    },
+    _Universe_eval: function(universe, recipe, normalize) {
+      var rti,
+        cache = universe.eC,
+        probe = cache.get(recipe);
+      if (probe != null)
+        return probe;
+      rti = H._Parser_parse(H._Parser_create(universe, null, recipe, normalize));
+      cache.set(recipe, rti);
+      return rti;
+    },
+    _Universe_evalInEnvironment: function(universe, environment, recipe) {
+      var probe, rti,
+        cache = environment._evalCache;
+      if (cache == null)
+        cache = environment._evalCache = new Map();
+      probe = cache.get(recipe);
+      if (probe != null)
+        return probe;
+      rti = H._Parser_parse(H._Parser_create(universe, environment, recipe, true));
+      cache.set(recipe, rti);
+      return rti;
+    },
+    _Universe_bind: function(universe, environment, argumentsRti) {
+      var argumentsRecipe, probe, rti,
+        cache = environment._bindCache;
+      if (cache == null)
+        cache = environment._bindCache = new Map();
+      argumentsRecipe = argumentsRti._canonicalRecipe;
+      probe = cache.get(argumentsRecipe);
+      if (probe != null)
+        return probe;
+      rti = H._Universe__lookupBindingRti(universe, environment, argumentsRti._kind === 10 ? argumentsRti._rest : [argumentsRti]);
+      cache.set(argumentsRecipe, rti);
+      return rti;
+    },
+    _Universe__installTypeTests: function(universe, rti) {
+      rti._as = H._installSpecializedAsCheck;
+      rti._is = H._installSpecializedIsTest;
+      return rti;
+    },
+    _Universe__lookupTerminalRti: function(universe, kind, key) {
+      var rti, t1,
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      rti = new H.Rti(null, null);
+      rti._kind = kind;
+      rti._canonicalRecipe = key;
+      t1 = H._Universe__installTypeTests(universe, rti);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__lookupStarRti: function(universe, baseType, normalize) {
+      var t1,
+        key = baseType._canonicalRecipe + "*",
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      t1 = H._Universe__createStarRti(universe, baseType, key, normalize);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__createStarRti: function(universe, baseType, key, normalize) {
+      var baseKind, t1, rti;
+      if (normalize) {
+        baseKind = baseType._kind;
+        if (!H.isStrongTopType(baseType))
+          t1 = baseType === type$.Null || baseType === type$.JSNull || baseKind === 7 || baseKind === 6;
+        else
+          t1 = true;
+        if (t1)
+          return baseType;
+      }
+      rti = new H.Rti(null, null);
+      rti._kind = 6;
+      rti._primary = baseType;
+      rti._canonicalRecipe = key;
+      return H._Universe__installTypeTests(universe, rti);
+    },
+    _Universe__lookupQuestionRti: function(universe, baseType, normalize) {
+      var t1,
+        key = baseType._canonicalRecipe + "?",
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      t1 = H._Universe__createQuestionRti(universe, baseType, key, normalize);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__createQuestionRti: function(universe, baseType, key, normalize) {
+      var baseKind, t1, starArgument, rti;
+      if (normalize) {
+        baseKind = baseType._kind;
+        if (!H.isStrongTopType(baseType))
+          if (!(baseType === type$.Null || baseType === type$.JSNull))
+            if (baseKind !== 7)
+              t1 = baseKind === 8 && H.isNullable(baseType._primary);
+            else
+              t1 = true;
+          else
+            t1 = true;
+        else
+          t1 = true;
+        if (t1)
+          return baseType;
+        else if (baseKind === 1 || baseType === type$.legacy_Never)
+          return type$.Null;
+        else if (baseKind === 6) {
+          starArgument = baseType._primary;
+          if (starArgument._kind === 8 && H.isNullable(starArgument._primary))
+            return starArgument;
+          else
+            return H.Rti__getQuestionFromStar(universe, baseType);
+        }
+      }
+      rti = new H.Rti(null, null);
+      rti._kind = 7;
+      rti._primary = baseType;
+      rti._canonicalRecipe = key;
+      return H._Universe__installTypeTests(universe, rti);
+    },
+    _Universe__lookupFutureOrRti: function(universe, baseType, normalize) {
+      var t1,
+        key = baseType._canonicalRecipe + "/",
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      t1 = H._Universe__createFutureOrRti(universe, baseType, key, normalize);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__createFutureOrRti: function(universe, baseType, key, normalize) {
+      var t1, t2, rti;
+      if (normalize) {
+        t1 = baseType._kind;
+        if (!H.isStrongTopType(baseType))
+          if (!(baseType === type$.legacy_Object))
+            t2 = baseType === type$.Object;
+          else
+            t2 = true;
+        else
+          t2 = true;
+        if (t2 || baseType === type$.Object)
+          return baseType;
+        else if (t1 === 1)
+          return H._Universe__lookupInterfaceRti(universe, "Future", [baseType]);
+        else if (baseType === type$.Null || baseType === type$.JSNull)
+          return type$.nullable_Future_Null;
+      }
+      rti = new H.Rti(null, null);
+      rti._kind = 8;
+      rti._primary = baseType;
+      rti._canonicalRecipe = key;
+      return H._Universe__installTypeTests(universe, rti);
+    },
+    _Universe__lookupGenericFunctionParameterRti: function(universe, index) {
+      var rti, t1,
+        key = "" + index + "^",
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      rti = new H.Rti(null, null);
+      rti._kind = 13;
+      rti._primary = index;
+      rti._canonicalRecipe = key;
+      t1 = H._Universe__installTypeTests(universe, rti);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__canonicalRecipeJoin: function($arguments) {
+      var s, sep, i,
+        $length = $arguments.length;
+      for (s = "", sep = "", i = 0; i < $length; ++i, sep = ",")
+        s += sep + $arguments[i]._canonicalRecipe;
+      return s;
+    },
+    _Universe__canonicalRecipeJoinNamed: function($arguments) {
+      var s, sep, i, t1, nameSep, s0,
+        $length = $arguments.length;
+      for (s = "", sep = "", i = 0; i < $length; i += 3, sep = ",") {
+        t1 = $arguments[i];
+        nameSep = $arguments[i + 1] ? "!" : ":";
+        s0 = $arguments[i + 2]._canonicalRecipe;
+        s += sep + t1 + nameSep + s0;
+      }
+      return s;
+    },
+    _Universe__lookupInterfaceRti: function(universe, $name, $arguments) {
+      var probe, rti, t1,
+        s = $name;
+      if ($arguments.length !== 0)
+        s += "<" + H._Universe__canonicalRecipeJoin($arguments) + ">";
+      probe = universe.eC.get(s);
+      if (probe != null)
+        return probe;
+      rti = new H.Rti(null, null);
+      rti._kind = 9;
+      rti._primary = $name;
+      rti._rest = $arguments;
+      if ($arguments.length > 0)
+        rti._precomputed1 = $arguments[0];
+      rti._canonicalRecipe = s;
+      t1 = H._Universe__installTypeTests(universe, rti);
+      universe.eC.set(s, t1);
+      return t1;
+    },
+    _Universe__lookupBindingRti: function(universe, base, $arguments) {
+      var newBase, newArguments, key, probe, rti, t1;
+      if (base._kind === 10) {
+        newBase = base._primary;
+        newArguments = base._rest.concat($arguments);
+      } else {
+        newArguments = $arguments;
+        newBase = base;
+      }
+      key = newBase._canonicalRecipe + (";<" + H._Universe__canonicalRecipeJoin(newArguments) + ">");
+      probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      rti = new H.Rti(null, null);
+      rti._kind = 10;
+      rti._primary = newBase;
+      rti._rest = newArguments;
+      rti._canonicalRecipe = key;
+      t1 = H._Universe__installTypeTests(universe, rti);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__lookupFunctionRti: function(universe, returnType, parameters) {
+      var sep, t1, key, probe, rti,
+        s = returnType._canonicalRecipe,
+        requiredPositional = parameters._requiredPositional,
+        requiredPositionalLength = requiredPositional.length,
+        optionalPositional = parameters._optionalPositional,
+        optionalPositionalLength = optionalPositional.length,
+        named = parameters._named,
+        namedLength = named.length,
+        recipe = "(" + H._Universe__canonicalRecipeJoin(requiredPositional);
+      if (optionalPositionalLength > 0) {
+        sep = requiredPositionalLength > 0 ? "," : "";
+        t1 = H._Universe__canonicalRecipeJoin(optionalPositional);
+        recipe += sep + "[" + t1 + "]";
+      }
+      if (namedLength > 0) {
+        sep = requiredPositionalLength > 0 ? "," : "";
+        t1 = H._Universe__canonicalRecipeJoinNamed(named);
+        recipe += sep + "{" + t1 + "}";
+      }
+      key = s + (recipe + ")");
+      probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      rti = new H.Rti(null, null);
+      rti._kind = 11;
+      rti._primary = returnType;
+      rti._rest = parameters;
+      rti._canonicalRecipe = key;
+      t1 = H._Universe__installTypeTests(universe, rti);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__lookupGenericFunctionRti: function(universe, baseFunctionType, bounds, normalize) {
+      var t1,
+        key = baseFunctionType._canonicalRecipe + ("<" + H._Universe__canonicalRecipeJoin(bounds) + ">"),
+        probe = universe.eC.get(key);
+      if (probe != null)
+        return probe;
+      t1 = H._Universe__createGenericFunctionRti(universe, baseFunctionType, bounds, key, normalize);
+      universe.eC.set(key, t1);
+      return t1;
+    },
+    _Universe__createGenericFunctionRti: function(universe, baseFunctionType, bounds, key, normalize) {
+      var $length, typeArguments, count, i, bound, substitutedBase, substitutedBounds, rti;
+      if (normalize) {
+        $length = bounds.length;
+        typeArguments = new Array($length);
+        for (count = 0, i = 0; i < $length; ++i) {
+          bound = bounds[i];
+          if (bound._kind === 1) {
+            typeArguments[i] = bound;
+            ++count;
+          }
+        }
+        if (count > 0) {
+          substitutedBase = H._substitute(universe, baseFunctionType, typeArguments, 0);
+          substitutedBounds = H._substituteArray(universe, bounds, typeArguments, 0);
+          return H._Universe__lookupGenericFunctionRti(universe, substitutedBase, substitutedBounds, bounds !== substitutedBounds);
+        }
+      }
+      rti = new H.Rti(null, null);
+      rti._kind = 12;
+      rti._primary = baseFunctionType;
+      rti._rest = bounds;
+      rti._canonicalRecipe = key;
+      return H._Universe__installTypeTests(universe, rti);
+    },
+    _Parser_create: function(universe, environment, recipe, normalize) {
+      return {u: universe, e: environment, r: recipe, s: [], p: 0, n: normalize};
+    },
+    _Parser_parse: function(parser) {
+      var t1, i, ch, universe, array, head, base, u, parameters, optionalPositional, named, item,
+        source = parser.r,
+        stack = parser.s;
+      for (t1 = source.length, i = 0; i < t1;) {
+        ch = source.charCodeAt(i);
+        if (ch >= 48 && ch <= 57)
+          i = H._Parser_handleDigit(i + 1, ch, source, stack);
+        else if ((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36)
+          i = H._Parser_handleIdentifier(parser, i, source, stack, false);
+        else if (ch === 46)
+          i = H._Parser_handleIdentifier(parser, i, source, stack, true);
+        else {
+          ++i;
+          switch (ch) {
+            case 44:
+              break;
+            case 58:
+              stack.push(false);
+              break;
+            case 33:
+              stack.push(true);
+              break;
+            case 59:
+              stack.push(H._Parser_toType(parser.u, parser.e, stack.pop()));
+              break;
+            case 94:
+              stack.push(H._Universe__lookupGenericFunctionParameterRti(parser.u, stack.pop()));
+              break;
+            case 35:
+              stack.push(H._Universe__lookupTerminalRti(parser.u, 5, "#"));
+              break;
+            case 64:
+              stack.push(H._Universe__lookupTerminalRti(parser.u, 2, "@"));
+              break;
+            case 126:
+              stack.push(H._Universe__lookupTerminalRti(parser.u, 3, "~"));
+              break;
+            case 60:
+              stack.push(parser.p);
+              parser.p = stack.length;
+              break;
+            case 62:
+              universe = parser.u;
+              array = stack.splice(parser.p);
+              H._Parser_toTypes(parser.u, parser.e, array);
+              parser.p = stack.pop();
+              head = stack.pop();
+              if (typeof head == "string")
+                stack.push(H._Universe__lookupInterfaceRti(universe, head, array));
+              else {
+                base = H._Parser_toType(universe, parser.e, head);
+                switch (base._kind) {
+                  case 11:
+                    stack.push(H._Universe__lookupGenericFunctionRti(universe, base, array, parser.n));
+                    break;
+                  default:
+                    stack.push(H._Universe__lookupBindingRti(universe, base, array));
+                    break;
+                }
+              }
+              break;
+            case 38:
+              H._Parser_handleExtendedOperations(parser, stack);
+              break;
+            case 42:
+              u = parser.u;
+              stack.push(H._Universe__lookupStarRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n));
+              break;
+            case 63:
+              u = parser.u;
+              stack.push(H._Universe__lookupQuestionRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n));
+              break;
+            case 47:
+              u = parser.u;
+              stack.push(H._Universe__lookupFutureOrRti(u, H._Parser_toType(u, parser.e, stack.pop()), parser.n));
+              break;
+            case 40:
+              stack.push(parser.p);
+              parser.p = stack.length;
+              break;
+            case 41:
+              universe = parser.u;
+              parameters = new H._FunctionParameters();
+              optionalPositional = universe.sEA;
+              named = universe.sEA;
+              head = stack.pop();
+              if (typeof head == "number")
+                switch (head) {
+                  case -1:
+                    optionalPositional = stack.pop();
+                    break;
+                  case -2:
+                    named = stack.pop();
+                    break;
+                  default:
+                    stack.push(head);
+                    break;
+                }
+              else
+                stack.push(head);
+              array = stack.splice(parser.p);
+              H._Parser_toTypes(parser.u, parser.e, array);
+              parser.p = stack.pop();
+              parameters._requiredPositional = array;
+              parameters._optionalPositional = optionalPositional;
+              parameters._named = named;
+              stack.push(H._Universe__lookupFunctionRti(universe, H._Parser_toType(universe, parser.e, stack.pop()), parameters));
+              break;
+            case 91:
+              stack.push(parser.p);
+              parser.p = stack.length;
+              break;
+            case 93:
+              array = stack.splice(parser.p);
+              H._Parser_toTypes(parser.u, parser.e, array);
+              parser.p = stack.pop();
+              stack.push(array);
+              stack.push(-1);
+              break;
+            case 123:
+              stack.push(parser.p);
+              parser.p = stack.length;
+              break;
+            case 125:
+              array = stack.splice(parser.p);
+              H._Parser_toTypesNamed(parser.u, parser.e, array);
+              parser.p = stack.pop();
+              stack.push(array);
+              stack.push(-2);
+              break;
+            default:
+              throw "Bad character " + ch;
+          }
+        }
+      }
+      item = stack.pop();
+      return H._Parser_toType(parser.u, parser.e, item);
+    },
+    _Parser_handleDigit: function(i, digit, source, stack) {
+      var t1, ch,
+        value = digit - 48;
+      for (t1 = source.length; i < t1; ++i) {
+        ch = source.charCodeAt(i);
+        if (!(ch >= 48 && ch <= 57))
+          break;
+        value = value * 10 + (ch - 48);
+      }
+      stack.push(value);
+      return i;
+    },
+    _Parser_handleIdentifier: function(parser, start, source, stack, hasPeriod) {
+      var t1, ch, t2, string, environment, recipe,
+        i = start + 1;
+      for (t1 = source.length; i < t1; ++i) {
+        ch = source.charCodeAt(i);
+        if (ch === 46) {
+          if (hasPeriod)
+            break;
+          hasPeriod = true;
+        } else {
+          if (!((((ch | 32) >>> 0) - 97 & 65535) < 26 || ch === 95 || ch === 36))
+            t2 = ch >= 48 && ch <= 57;
+          else
+            t2 = true;
+          if (!t2)
+            break;
+        }
+      }
+      string = source.substring(start, i);
+      if (hasPeriod) {
+        t1 = parser.u;
+        environment = parser.e;
+        if (environment._kind === 10)
+          environment = environment._primary;
+        recipe = H._Universe_findRule(t1, environment._primary)[string];
+        if (recipe == null)
+          H.throwExpression('No "' + string + '" in "' + H.Rti__getCanonicalRecipe(environment) + '"');
+        stack.push(H._Universe_evalInEnvironment(t1, environment, recipe));
+      } else
+        stack.push(string);
+      return i;
+    },
+    _Parser_handleExtendedOperations: function(parser, stack) {
+      var $top = stack.pop();
+      if (0 === $top) {
+        stack.push(H._Universe__lookupTerminalRti(parser.u, 1, "0&"));
+        return;
+      }
+      if (1 === $top) {
+        stack.push(H._Universe__lookupTerminalRti(parser.u, 4, "1&"));
+        return;
+      }
+      throw H.wrapException(P.AssertionError$("Unexpected extended operation " + H.S($top)));
+    },
+    _Parser_toType: function(universe, environment, item) {
+      if (typeof item == "string")
+        return H._Universe__lookupInterfaceRti(universe, item, universe.sEA);
+      else if (typeof item == "number")
+        return H._Parser_indexToType(universe, environment, item);
+      else
+        return item;
+    },
+    _Parser_toTypes: function(universe, environment, items) {
+      var i,
+        $length = items.length;
+      for (i = 0; i < $length; ++i)
+        items[i] = H._Parser_toType(universe, environment, items[i]);
+    },
+    _Parser_toTypesNamed: function(universe, environment, items) {
+      var i,
+        $length = items.length;
+      for (i = 2; i < $length; i += 3)
+        items[i] = H._Parser_toType(universe, environment, items[i]);
+    },
+    _Parser_indexToType: function(universe, environment, index) {
+      var typeArguments, len,
+        kind = environment._kind;
+      if (kind === 10) {
+        if (index === 0)
+          return environment._primary;
+        typeArguments = environment._rest;
+        len = typeArguments.length;
+        if (index <= len)
+          return typeArguments[index - 1];
+        index -= len;
+        environment = environment._primary;
+        kind = environment._kind;
+      } else if (index === 0)
+        return environment;
+      if (kind !== 9)
+        throw H.wrapException(P.AssertionError$("Indexed base must be an interface type"));
+      typeArguments = environment._rest;
+      if (index <= typeArguments.length)
+        return typeArguments[index - 1];
+      throw H.wrapException(P.AssertionError$("Bad index " + index + " for " + environment.toString$0(0)));
+    },
+    _isSubtype: function(universe, s, sEnv, t, tEnv) {
+      var t1, sKind, leftTypeVariable, tKind, sBounds, tBounds, sLength, i, sBound, tBound;
+      if (s === t)
+        return true;
+      if (!H.isStrongTopType(t))
+        if (!(t === type$.legacy_Object))
+          t1 = t === type$.Object;
+        else
+          t1 = true;
+      else
+        t1 = true;
+      if (t1)
+        return true;
+      sKind = s._kind;
+      if (sKind === 4)
+        return true;
+      if (H.isStrongTopType(s))
+        return false;
+      if (s._kind !== 1)
+        t1 = s === type$.Null || s === type$.JSNull;
+      else
+        t1 = true;
+      if (t1)
+        return true;
+      leftTypeVariable = sKind === 13;
+      if (leftTypeVariable)
+        if (H._isSubtype(universe, sEnv[s._primary], sEnv, t, tEnv))
+          return true;
+      tKind = t._kind;
+      if (sKind === 6)
+        return H._isSubtype(universe, s._primary, sEnv, t, tEnv);
+      if (tKind === 6) {
+        t1 = t._primary;
+        return H._isSubtype(universe, s, sEnv, t1, tEnv);
+      }
+      if (sKind === 8) {
+        if (!H._isSubtype(universe, s._primary, sEnv, t, tEnv))
+          return false;
+        return H._isSubtype(universe, H.Rti__getFutureFromFutureOr(universe, s), sEnv, t, tEnv);
+      }
+      if (sKind === 7) {
+        t1 = H._isSubtype(universe, s._primary, sEnv, t, tEnv);
+        return t1;
+      }
+      if (tKind === 8) {
+        if (H._isSubtype(universe, s, sEnv, t._primary, tEnv))
+          return true;
+        return H._isSubtype(universe, s, sEnv, H.Rti__getFutureFromFutureOr(universe, t), tEnv);
+      }
+      if (tKind === 7) {
+        t1 = H._isSubtype(universe, s, sEnv, t._primary, tEnv);
+        return t1;
+      }
+      if (leftTypeVariable)
+        return false;
+      t1 = sKind !== 11;
+      if ((!t1 || sKind === 12) && t === type$.Function)
+        return true;
+      if (tKind === 12) {
+        if (s === type$.JavaScriptFunction)
+          return true;
+        if (sKind !== 12)
+          return false;
+        sBounds = s._rest;
+        tBounds = t._rest;
+        sLength = sBounds.length;
+        if (sLength !== tBounds.length)
+          return false;
+        sEnv = sEnv == null ? sBounds : sBounds.concat(sEnv);
+        tEnv = tEnv == null ? tBounds : tBounds.concat(tEnv);
+        for (i = 0; i < sLength; ++i) {
+          sBound = sBounds[i];
+          tBound = tBounds[i];
+          if (!H._isSubtype(universe, sBound, sEnv, tBound, tEnv) || !H._isSubtype(universe, tBound, tEnv, sBound, sEnv))
+            return false;
+        }
+        return H._isFunctionSubtype(universe, s._primary, sEnv, t._primary, tEnv);
+      }
+      if (tKind === 11) {
+        if (s === type$.JavaScriptFunction)
+          return true;
+        if (t1)
+          return false;
+        return H._isFunctionSubtype(universe, s, sEnv, t, tEnv);
+      }
+      if (sKind === 9) {
+        if (tKind !== 9)
+          return false;
+        return H._isInterfaceSubtype(universe, s, sEnv, t, tEnv);
+      }
+      return false;
+    },
+    _isFunctionSubtype: function(universe, s, sEnv, t, tEnv) {
+      var sParameters, tParameters, sRequiredPositional, tRequiredPositional, sRequiredPositionalLength, tRequiredPositionalLength, requiredPositionalDelta, sOptionalPositional, tOptionalPositional, sOptionalPositionalLength, tOptionalPositionalLength, i, t1, sNamed, tNamed, sNamedLength, tNamedLength, sIndex, tIndex, tName, sName, sIsRequired;
+      if (!H._isSubtype(universe, s._primary, sEnv, t._primary, tEnv))
+        return false;
+      sParameters = s._rest;
+      tParameters = t._rest;
+      sRequiredPositional = sParameters._requiredPositional;
+      tRequiredPositional = tParameters._requiredPositional;
+      sRequiredPositionalLength = sRequiredPositional.length;
+      tRequiredPositionalLength = tRequiredPositional.length;
+      if (sRequiredPositionalLength > tRequiredPositionalLength)
+        return false;
+      requiredPositionalDelta = tRequiredPositionalLength - sRequiredPositionalLength;
+      sOptionalPositional = sParameters._optionalPositional;
+      tOptionalPositional = tParameters._optionalPositional;
+      sOptionalPositionalLength = sOptionalPositional.length;
+      tOptionalPositionalLength = tOptionalPositional.length;
+      if (sRequiredPositionalLength + sOptionalPositionalLength < tRequiredPositionalLength + tOptionalPositionalLength)
+        return false;
+      for (i = 0; i < sRequiredPositionalLength; ++i) {
+        t1 = sRequiredPositional[i];
+        if (!H._isSubtype(universe, tRequiredPositional[i], tEnv, t1, sEnv))
+          return false;
+      }
+      for (i = 0; i < requiredPositionalDelta; ++i) {
+        t1 = sOptionalPositional[i];
+        if (!H._isSubtype(universe, tRequiredPositional[sRequiredPositionalLength + i], tEnv, t1, sEnv))
+          return false;
+      }
+      for (i = 0; i < tOptionalPositionalLength; ++i) {
+        t1 = sOptionalPositional[requiredPositionalDelta + i];
+        if (!H._isSubtype(universe, tOptionalPositional[i], tEnv, t1, sEnv))
+          return false;
+      }
+      sNamed = sParameters._named;
+      tNamed = tParameters._named;
+      sNamedLength = sNamed.length;
+      tNamedLength = tNamed.length;
+      for (sIndex = 0, tIndex = 0; tIndex < tNamedLength; tIndex += 3) {
+        tName = tNamed[tIndex];
+        for (; true;) {
+          if (sIndex >= sNamedLength)
+            return false;
+          sName = sNamed[sIndex];
+          sIndex += 3;
+          if (tName < sName)
+            return false;
+          sIsRequired = sNamed[sIndex - 2];
+          if (sName < tName) {
+            if (sIsRequired)
+              return false;
+            continue;
+          }
+          t1 = tNamed[tIndex + 1];
+          if (sIsRequired && !t1)
+            return false;
+          t1 = sNamed[sIndex - 1];
+          if (!H._isSubtype(universe, tNamed[tIndex + 2], tEnv, t1, sEnv))
+            return false;
+          break;
+        }
+      }
+      for (; sIndex < sNamedLength;) {
+        if (sNamed[sIndex + 1])
+          return false;
+        sIndex += 3;
+      }
+      return true;
+    },
+    _isInterfaceSubtype: function(universe, s, sEnv, t, tEnv) {
+      var sArgs, tArgs, $length, i, t1, t2, rule, supertypeArgs,
+        sName = s._primary,
+        tName = t._primary;
+      if (sName === tName) {
+        sArgs = s._rest;
+        tArgs = t._rest;
+        $length = sArgs.length;
+        for (i = 0; i < $length; ++i) {
+          t1 = sArgs[i];
+          t2 = tArgs[i];
+          if (!H._isSubtype(universe, t1, sEnv, t2, tEnv))
+            return false;
+        }
+        return true;
+      }
+      if (t === type$.Object)
+        return true;
+      rule = H._Universe_findRule(universe, sName);
+      if (rule == null)
+        return false;
+      supertypeArgs = rule[tName];
+      if (supertypeArgs == null)
+        return false;
+      $length = supertypeArgs.length;
+      tArgs = t._rest;
+      for (i = 0; i < $length; ++i)
+        if (!H._isSubtype(universe, H._Universe_evalInEnvironment(universe, s, supertypeArgs[i]), sEnv, tArgs[i], tEnv))
+          return false;
+      return true;
+    },
+    isNullable: function(t) {
+      var t1,
+        kind = t._kind;
+      if (!(t === type$.Null || t === type$.JSNull))
+        if (!H.isStrongTopType(t))
+          if (kind !== 7)
+            if (!(kind === 6 && H.isNullable(t._primary)))
+              t1 = kind === 8 && H.isNullable(t._primary);
+            else
+              t1 = true;
+          else
+            t1 = true;
+        else
+          t1 = true;
+      else
+        t1 = true;
+      return t1;
+    },
+    isTopType: function(t) {
+      var t1;
+      if (!H.isStrongTopType(t))
+        if (!(t === type$.legacy_Object))
+          t1 = t === type$.Object;
+        else
+          t1 = true;
+      else
+        t1 = true;
+      return t1;
+    },
+    isStrongTopType: function(t) {
+      var kind = t._kind;
+      return kind === 2 || kind === 3 || kind === 4 || kind === 5 || t === type$.nullable_Object;
+    },
+    _Utils_objectAssign: function(o, other) {
+      var i, key,
+        keys = Object.keys(other),
+        $length = keys.length;
+      for (i = 0; i < $length; ++i) {
+        key = keys[i];
+        o[key] = other[key];
+      }
+    },
+    Rti: function Rti(t0, t1) {
+      var _ = this;
+      _._as = t0;
+      _._is = t1;
+      _._cachedRuntimeType = _._specializedTestResource = _._precomputed1 = null;
+      _._kind = 0;
+      _._canonicalRecipe = _._bindCache = _._evalCache = _._rest = _._primary = null;
+    },
+    _FunctionParameters: function _FunctionParameters() {
+      this._named = this._optionalPositional = this._requiredPositional = null;
+    },
+    _Type: function _Type(t0) {
+      this._rti = t0;
+    },
+    _Error: function _Error() {
+    },
+    _TypeError: function _TypeError(t0) {
+      this.__rti$_message = t0;
+    },
+    unmangleGlobalNameIfPreservedAnyways: function($name) {
+      return init.mangledGlobalNames[$name];
+    }
+  },
+  J = {
+    makeDispatchRecord: function(interceptor, proto, extension, indexability) {
+      return {i: interceptor, p: proto, e: extension, x: indexability};
+    },
+    getNativeInterceptor: function(object) {
+      var proto, objectProto, $constructor, interceptor,
+        record = object[init.dispatchPropertyName];
+      if (record == null)
+        if ($.initNativeDispatchFlag == null) {
+          H.initNativeDispatch();
+          record = object[init.dispatchPropertyName];
+        }
+      if (record != null) {
+        proto = record.p;
+        if (false === proto)
+          return record.i;
+        if (true === proto)
+          return object;
+        objectProto = Object.getPrototypeOf(object);
+        if (proto === objectProto)
+          return record.i;
+        if (record.e === objectProto)
+          throw H.wrapException(P.UnimplementedError$("Return interceptor for " + H.S(proto(object, record))));
+      }
+      $constructor = object.constructor;
+      interceptor = $constructor == null ? null : $constructor[J.JS_INTEROP_INTERCEPTOR_TAG()];
+      if (interceptor != null)
+        return interceptor;
+      interceptor = H.lookupAndCacheInterceptor(object);
+      if (interceptor != null)
+        return interceptor;
+      if (typeof object == "function")
+        return C.JavaScriptFunction_methods;
+      proto = Object.getPrototypeOf(object);
+      if (proto == null)
+        return C.PlainJavaScriptObject_methods;
+      if (proto === Object.prototype)
+        return C.PlainJavaScriptObject_methods;
+      if (typeof $constructor == "function") {
+        Object.defineProperty($constructor, J.JS_INTEROP_INTERCEPTOR_TAG(), {value: C.UnknownJavaScriptObject_methods, enumerable: false, writable: true, configurable: true});
+        return C.UnknownJavaScriptObject_methods;
+      }
+      return C.UnknownJavaScriptObject_methods;
+    },
+    JS_INTEROP_INTERCEPTOR_TAG: function() {
+      var t1 = $._JS_INTEROP_INTERCEPTOR_TAG;
+      return t1 == null ? $._JS_INTEROP_INTERCEPTOR_TAG = init.getIsolateTag("_$dart_js") : t1;
+    },
+    JSArray_JSArray$fixed: function($length, $E) {
+      if (!H._isInt($length))
+        throw H.wrapException(P.ArgumentError$value($length, "length", "is not an integer"));
+      if ($length < 0 || $length > 4294967295)
+        throw H.wrapException(P.RangeError$range($length, 0, 4294967295, "length", null));
+      return J.JSArray_JSArray$markFixed(new Array($length), $E);
+    },
+    JSArray_JSArray$growable: function($length, $E) {
+      if (!H._isInt($length) || $length < 0)
+        throw H.wrapException(P.ArgumentError$("Length must be a non-negative integer: " + H.S($length)));
+      return H.setRuntimeTypeInfo(new Array($length), $E._eval$1("JSArray<0>"));
+    },
+    JSArray_JSArray$markFixed: function(allocation, $E) {
+      return J.JSArray_markFixedList(H.setRuntimeTypeInfo(allocation, $E._eval$1("JSArray<0>")), $E);
+    },
+    JSArray_markFixedList: function(list, $T) {
+      list.fixed$length = Array;
+      return list;
+    },
+    getInterceptor$: function(receiver) {
+      if (typeof receiver == "number") {
+        if (Math.floor(receiver) == receiver)
+          return J.JSInt.prototype;
+        return J.JSDouble.prototype;
+      }
+      if (typeof receiver == "string")
+        return J.JSString.prototype;
+      if (receiver == null)
+        return J.JSNull.prototype;
+      if (typeof receiver == "boolean")
+        return J.JSBool.prototype;
+      if (receiver.constructor == Array)
+        return J.JSArray.prototype;
+      if (typeof receiver != "object") {
+        if (typeof receiver == "function")
+          return J.JavaScriptFunction.prototype;
+        return receiver;
+      }
+      if (receiver instanceof P.Object)
+        return receiver;
+      return J.getNativeInterceptor(receiver);
+    },
+    getInterceptor$ansx: function(receiver) {
+      if (typeof receiver == "number")
+        return J.JSNumber.prototype;
+      if (typeof receiver == "string")
+        return J.JSString.prototype;
+      if (receiver == null)
+        return receiver;
+      if (receiver.constructor == Array)
+        return J.JSArray.prototype;
+      if (typeof receiver != "object") {
+        if (typeof receiver == "function")
+          return J.JavaScriptFunction.prototype;
+        return receiver;
+      }
+      if (receiver instanceof P.Object)
+        return receiver;
+      return J.getNativeInterceptor(receiver);
+    },
+    getInterceptor$asx: function(receiver) {
+      if (typeof receiver == "string")
+        return J.JSString.prototype;
+      if (receiver == null)
+        return receiver;
+      if (receiver.constructor == Array)
+        return J.JSArray.prototype;
+      if (typeof receiver != "object") {
+        if (typeof receiver == "function")
+          return J.JavaScriptFunction.prototype;
+        return receiver;
+      }
+      if (receiver instanceof P.Object)
+        return receiver;
+      return J.getNativeInterceptor(receiver);
+    },
+    getInterceptor$ax: function(receiver) {
+      if (receiver == null)
+        return receiver;
+      if (receiver.constructor == Array)
+        return J.JSArray.prototype;
+      if (typeof receiver != "object") {
+        if (typeof receiver == "function")
+          return J.JavaScriptFunction.prototype;
+        return receiver;
+      }
+      if (receiver instanceof P.Object)
+        return receiver;
+      return J.getNativeInterceptor(receiver);
+    },
+    getInterceptor$bn: function(receiver) {
+      if (typeof receiver == "number")
+        return J.JSNumber.prototype;
+      if (receiver == null)
+        return receiver;
+      if (typeof receiver == "boolean")
+        return J.JSBool.prototype;
+      if (!(receiver instanceof P.Object))
+        return J.UnknownJavaScriptObject.prototype;
+      return receiver;
+    },
+    getInterceptor$n: function(receiver) {
+      if (typeof receiver == "number")
+        return J.JSNumber.prototype;
+      if (receiver == null)
+        return receiver;
+      if (!(receiver instanceof P.Object))
+        return J.UnknownJavaScriptObject.prototype;
+      return receiver;
+    },
+    getInterceptor$s: function(receiver) {
+      if (typeof receiver == "string")
+        return J.JSString.prototype;
+      if (receiver == null)
+        return receiver;
+      if (!(receiver instanceof P.Object))
+        return J.UnknownJavaScriptObject.prototype;
+      return receiver;
+    },
+    getInterceptor$x: function(receiver) {
+      if (receiver == null)
+        return receiver;
+      if (typeof receiver != "object") {
+        if (typeof receiver == "function")
+          return J.JavaScriptFunction.prototype;
+        return receiver;
+      }
+      if (receiver instanceof P.Object)
+        return receiver;
+      return J.getNativeInterceptor(receiver);
+    },
+    get$hashCode$: function(receiver) {
+      return J.getInterceptor$(receiver).get$hashCode(receiver);
+    },
+    get$iterator$ax: function(receiver) {
+      return J.getInterceptor$ax(receiver).get$iterator(receiver);
+    },
+    get$length$asx: function(receiver) {
+      return J.getInterceptor$asx(receiver).get$length(receiver);
+    },
+    get$runtimeType$: function(receiver) {
+      return J.getInterceptor$(receiver).get$runtimeType(receiver);
+    },
+    $add$ansx: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return receiver + a0;
+      return J.getInterceptor$ansx(receiver).$add(receiver, a0);
+    },
+    $and$bn: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return (receiver & a0) >>> 0;
+      return J.getInterceptor$bn(receiver).$and(receiver, a0);
+    },
+    $div$n: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return receiver / a0;
+      return J.getInterceptor$n(receiver).$div(receiver, a0);
+    },
+    $eq$: function(receiver, a0) {
+      if (receiver == null)
+        return a0 == null;
+      if (typeof receiver != "object")
+        return a0 != null && receiver === a0;
+      return J.getInterceptor$(receiver).$eq(receiver, a0);
+    },
+    $ge$n: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return receiver >= a0;
+      return J.getInterceptor$n(receiver).$ge(receiver, a0);
+    },
+    $index$asx: function(receiver, a0) {
+      if (typeof a0 === "number")
+        if (receiver.constructor == Array || typeof receiver == "string" || H.isJsIndexable(receiver, receiver[init.dispatchPropertyName]))
+          if (a0 >>> 0 === a0 && a0 < receiver.length)
+            return receiver[a0];
+      return J.getInterceptor$asx(receiver).$index(receiver, a0);
+    },
+    $indexSet$ax: function(receiver, a0, a1) {
+      return J.getInterceptor$ax(receiver).$indexSet(receiver, a0, a1);
+    },
+    $or$bn: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return (receiver | a0) >>> 0;
+      return J.getInterceptor$bn(receiver).$or(receiver, a0);
+    },
+    $shl$n: function(receiver, a0) {
+      return J.getInterceptor$n(receiver).$shl(receiver, a0);
+    },
+    $sub$n: function(receiver, a0) {
+      if (typeof receiver == "number" && typeof a0 == "number")
+        return receiver - a0;
+      return J.getInterceptor$n(receiver).$sub(receiver, a0);
+    },
+    _removeEventListener$3$x: function(receiver, a0, a1, a2) {
+      return J.getInterceptor$x(receiver)._removeEventListener$3(receiver, a0, a1, a2);
+    },
+    addEventListener$3$x: function(receiver, a0, a1, a2) {
+      return J.getInterceptor$x(receiver).addEventListener$3(receiver, a0, a1, a2);
+    },
+    elementAt$1$ax: function(receiver, a0) {
+      return J.getInterceptor$ax(receiver).elementAt$1(receiver, a0);
+    },
+    map$1$ax: function(receiver, a0) {
+      return J.getInterceptor$ax(receiver).map$1(receiver, a0);
+    },
+    map$1$1$ax: function(receiver, a0, $T1) {
+      return J.getInterceptor$ax(receiver).map$1$1(receiver, a0, $T1);
+    },
+    noSuchMethod$1$: function(receiver, a0) {
+      return J.getInterceptor$(receiver).noSuchMethod$1(receiver, a0);
+    },
+    toList$0$ax: function(receiver) {
+      return J.getInterceptor$ax(receiver).toList$0(receiver);
+    },
+    toString$0$: function(receiver) {
+      return J.getInterceptor$(receiver).toString$0(receiver);
+    },
+    Interceptor: function Interceptor() {
+    },
+    JSBool: function JSBool() {
+    },
+    JSNull: function JSNull() {
+    },
+    JSObject: function JSObject() {
+    },
+    JavaScriptObject: function JavaScriptObject() {
+    },
+    PlainJavaScriptObject: function PlainJavaScriptObject() {
+    },
+    UnknownJavaScriptObject: function UnknownJavaScriptObject() {
+    },
+    JavaScriptFunction: function JavaScriptFunction() {
+    },
+    JSArray: function JSArray(t0) {
+      this.$ti = t0;
+    },
+    JSUnmodifiableArray: function JSUnmodifiableArray(t0) {
+      this.$ti = t0;
+    },
+    ArrayIterator: function ArrayIterator(t0, t1, t2) {
+      var _ = this;
+      _.__interceptors$_iterable = t0;
+      _.__interceptors$_length = t1;
+      _.__interceptors$_index = 0;
+      _.__interceptors$_current = null;
+      _.$ti = t2;
+    },
+    JSNumber: function JSNumber() {
+    },
+    JSInt: function JSInt() {
+    },
+    JSDouble: function JSDouble() {
+    },
+    JSString: function JSString() {
+    }
+  },
+  P = {
+    _AsyncRun__initializeScheduleImmediate: function() {
+      var div, span, t1 = {};
+      if (self.scheduleImmediate != null)
+        return P.async__AsyncRun__scheduleImmediateJsOverride$closure();
+      if (self.MutationObserver != null && self.document != null) {
+        div = self.document.createElement("div");
+        span = self.document.createElement("span");
+        t1.storedCallback = null;
+        new self.MutationObserver(H.convertDartClosureToJS(new P._AsyncRun__initializeScheduleImmediate_internalCallback(t1), 1)).observe(div, {childList: true});
+        return new P._AsyncRun__initializeScheduleImmediate_closure(t1, div, span);
+      } else if (self.setImmediate != null)
+        return P.async__AsyncRun__scheduleImmediateWithSetImmediate$closure();
+      return P.async__AsyncRun__scheduleImmediateWithTimer$closure();
+    },
+    _AsyncRun__scheduleImmediateJsOverride: function(callback) {
+      self.scheduleImmediate(H.convertDartClosureToJS(new P._AsyncRun__scheduleImmediateJsOverride_internalCallback(type$.void_Function._as(callback)), 0));
+    },
+    _AsyncRun__scheduleImmediateWithSetImmediate: function(callback) {
+      self.setImmediate(H.convertDartClosureToJS(new P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(type$.void_Function._as(callback)), 0));
+    },
+    _AsyncRun__scheduleImmediateWithTimer: function(callback) {
+      P.Timer__createTimer(C.Duration_0, type$.void_Function._as(callback));
+    },
+    Timer__createTimer: function(duration, callback) {
+      var milliseconds = C.JSInt_methods._tdivFast$1(duration._duration, 1000);
+      return P._TimerImpl$(milliseconds < 0 ? 0 : milliseconds, callback);
+    },
+    _TimerImpl$: function(milliseconds, callback) {
+      var t1 = new P._TimerImpl();
+      t1._TimerImpl$2(milliseconds, callback);
+      return t1;
+    },
+    _makeAsyncAwaitCompleter: function($T) {
+      return new P._AsyncAwaitCompleter(new P._Future($.Zone__current, $T._eval$1("_Future<0>")), $T._eval$1("_AsyncAwaitCompleter<0>"));
+    },
+    _asyncStartSync: function(bodyFunction, completer) {
+      bodyFunction.call$2(0, null);
+      completer.isSync = true;
+      return completer._future;
+    },
+    _asyncAwait: function(object, bodyFunction) {
+      P._awaitOnObject(object, bodyFunction);
+    },
+    _asyncReturn: function(object, completer) {
+      completer.complete$1(object);
+    },
+    _asyncRethrow: function(object, completer) {
+      completer.completeError$2(H.unwrapException(object), H.getTraceFromException(object));
+    },
+    _awaitOnObject: function(object, bodyFunction) {
+      var t1, future,
+        thenCallback = new P._awaitOnObject_closure(bodyFunction),
+        errorCallback = new P._awaitOnObject_closure0(bodyFunction);
+      if (object instanceof P._Future)
+        object._thenAwait$1$2(thenCallback, errorCallback, type$.dynamic);
+      else {
+        t1 = type$.dynamic;
+        if (type$.Future_dynamic._is(object))
+          object.then$1$2$onError(thenCallback, errorCallback, t1);
+        else {
+          future = new P._Future($.Zone__current, type$._Future_dynamic);
+          future._state = 4;
+          future._resultOrListeners = object;
+          future._thenAwait$1$2(thenCallback, errorCallback, t1);
+        }
+      }
+    },
+    _wrapJsFunctionForAsync: function($function) {
+      var $protected = function(fn, ERROR) {
+        return function(errorCode, result) {
+          while (true)
+            try {
+              fn(errorCode, result);
+              break;
+            } catch (error) {
+              result = error;
+              errorCode = ERROR;
+            }
+        };
+      }($function, 1);
+      return $.Zone__current.registerBinaryCallback$3$1(new P._wrapJsFunctionForAsync_closure($protected), type$.Null, type$.int, type$.dynamic);
+    },
+    _Future$zoneValue: function(value, _zone, $T) {
+      var t1 = new P._Future(_zone, $T._eval$1("_Future<0>"));
+      $T._as(value);
+      t1._state = 4;
+      t1._resultOrListeners = value;
+      return t1;
+    },
+    _Future__chainForeignFuture: function(source, target) {
+      var e, s, exception;
+      target._state = 1;
+      try {
+        source.then$1$2$onError(new P._Future__chainForeignFuture_closure(target), new P._Future__chainForeignFuture_closure0(target), type$.Null);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        P.scheduleMicrotask(new P._Future__chainForeignFuture_closure1(target, e, s));
+      }
+    },
+    _Future__chainCoreFuture: function(source, target) {
+      var t1, t2, listeners;
+      for (t1 = type$._Future_dynamic; t2 = source._state, t2 === 2;)
+        source = t1._as(source._resultOrListeners);
+      if (t2 >= 4) {
+        listeners = target._removeListeners$0();
+        target._state = source._state;
+        target._resultOrListeners = source._resultOrListeners;
+        P._Future__propagateToListeners(target, listeners);
+      } else {
+        listeners = type$.nullable__FutureListener_dynamic_dynamic._as(target._resultOrListeners);
+        target._state = 2;
+        target._resultOrListeners = source;
+        source._prependListeners$1(listeners);
+      }
+    },
+    _Future__propagateToListeners: function(source, listeners) {
+      var t2, t3, t4, _box_0, hasError, asyncError, nextListener, nextListener0, t5, sourceResult, t6, t7, zone, oldZone, result, current, _null = null, _box_1 = {},
+        t1 = _box_1.source = source;
+      for (t2 = type$.AsyncError, t3 = type$.nullable__FutureListener_dynamic_dynamic, t4 = type$.Future_dynamic; true;) {
+        _box_0 = {};
+        hasError = t1._state === 8;
+        if (listeners == null) {
+          if (hasError) {
+            asyncError = t2._as(t1._resultOrListeners);
+            P._rootHandleUncaughtError(_null, _null, t1._zone, asyncError.error, asyncError.stackTrace);
+          }
+          return;
+        }
+        _box_0.listener = listeners;
+        nextListener = listeners._nextListener;
+        for (t1 = listeners; nextListener != null; t1 = nextListener, nextListener = nextListener0) {
+          t1._nextListener = null;
+          P._Future__propagateToListeners(_box_1.source, t1);
+          _box_0.listener = nextListener;
+          nextListener0 = nextListener._nextListener;
+        }
+        t5 = _box_1.source;
+        sourceResult = t5._resultOrListeners;
+        _box_0.listenerHasError = hasError;
+        _box_0.listenerValueOrError = sourceResult;
+        t6 = !hasError;
+        if (t6) {
+          t7 = t1.state;
+          t7 = (t7 & 1) !== 0 || (t7 & 15) === 8;
+        } else
+          t7 = true;
+        if (t7) {
+          zone = t1.result._zone;
+          if (hasError) {
+            t7 = t5._zone === zone;
+            t7 = !(t7 || t7);
+          } else
+            t7 = false;
+          if (t7) {
+            t2._as(sourceResult);
+            P._rootHandleUncaughtError(_null, _null, t5._zone, sourceResult.error, sourceResult.stackTrace);
+            return;
+          }
+          oldZone = $.Zone__current;
+          if (oldZone !== zone)
+            $.Zone__current = zone;
+          else
+            oldZone = _null;
+          t1 = t1.state;
+          if ((t1 & 15) === 8)
+            new P._Future__propagateToListeners_handleWhenCompleteCallback(_box_0, _box_1, hasError).call$0();
+          else if (t6) {
+            if ((t1 & 1) !== 0)
+              new P._Future__propagateToListeners_handleValueCallback(_box_0, sourceResult).call$0();
+          } else if ((t1 & 2) !== 0)
+            new P._Future__propagateToListeners_handleError(_box_1, _box_0).call$0();
+          if (oldZone != null)
+            $.Zone__current = oldZone;
+          t1 = _box_0.listenerValueOrError;
+          if (t4._is(t1)) {
+            result = _box_0.listener.result;
+            if (t1._state >= 4) {
+              current = t3._as(result._resultOrListeners);
+              result._resultOrListeners = null;
+              listeners = result._reverseListeners$1(current);
+              result._state = t1._state;
+              result._resultOrListeners = t1._resultOrListeners;
+              _box_1.source = t1;
+              continue;
+            } else
+              P._Future__chainCoreFuture(t1, result);
+            return;
+          }
+        }
+        result = _box_0.listener.result;
+        current = t3._as(result._resultOrListeners);
+        result._resultOrListeners = null;
+        listeners = result._reverseListeners$1(current);
+        t1 = _box_0.listenerHasError;
+        t5 = _box_0.listenerValueOrError;
+        if (!t1) {
+          result.$ti._precomputed1._as(t5);
+          result._state = 4;
+          result._resultOrListeners = t5;
+        } else {
+          t2._as(t5);
+          result._state = 8;
+          result._resultOrListeners = t5;
+        }
+        _box_1.source = result;
+        t1 = result;
+      }
+    },
+    _registerErrorHandler: function(errorHandler, zone) {
+      var t1;
+      if (type$.dynamic_Function_Object_StackTrace._is(errorHandler))
+        return zone.registerBinaryCallback$3$1(errorHandler, type$.dynamic, type$.Object, type$.StackTrace);
+      t1 = type$.dynamic_Function_Object;
+      if (t1._is(errorHandler))
+        return t1._as(errorHandler);
+      throw H.wrapException(P.ArgumentError$value(errorHandler, "onError", "Error handler must accept one Object or one Object and a StackTrace as arguments, and return a a valid result"));
+    },
+    _microtaskLoop: function() {
+      var entry, next;
+      for (entry = $._nextCallback; entry != null; entry = $._nextCallback) {
+        $._lastPriorityCallback = null;
+        next = entry.next;
+        $._nextCallback = next;
+        if (next == null)
+          $._lastCallback = null;
+        entry.callback.call$0();
+      }
+    },
+    _startMicrotaskLoop: function() {
+      $._isInCallbackLoop = true;
+      try {
+        P._microtaskLoop();
+      } finally {
+        $._lastPriorityCallback = null;
+        $._isInCallbackLoop = false;
+        if ($._nextCallback != null)
+          $.$get$_AsyncRun__scheduleImmediateClosure().call$1(P.async___startMicrotaskLoop$closure());
+      }
+    },
+    _scheduleAsyncCallback: function(callback) {
+      var newEntry = new P._AsyncCallbackEntry(callback),
+        lastCallback = $._lastCallback;
+      if (lastCallback == null) {
+        $._nextCallback = $._lastCallback = newEntry;
+        if (!$._isInCallbackLoop)
+          $.$get$_AsyncRun__scheduleImmediateClosure().call$1(P.async___startMicrotaskLoop$closure());
+      } else
+        $._lastCallback = lastCallback.next = newEntry;
+    },
+    _schedulePriorityAsyncCallback: function(callback) {
+      var entry, lastPriorityCallback, next,
+        t1 = $._nextCallback;
+      if (t1 == null) {
+        P._scheduleAsyncCallback(callback);
+        $._lastPriorityCallback = $._lastCallback;
+        return;
+      }
+      entry = new P._AsyncCallbackEntry(callback);
+      lastPriorityCallback = $._lastPriorityCallback;
+      if (lastPriorityCallback == null) {
+        entry.next = t1;
+        $._nextCallback = $._lastPriorityCallback = entry;
+      } else {
+        next = lastPriorityCallback.next;
+        entry.next = next;
+        $._lastPriorityCallback = lastPriorityCallback.next = entry;
+        if (next == null)
+          $._lastCallback = entry;
+      }
+    },
+    scheduleMicrotask: function(callback) {
+      var _null = null,
+        currentZone = $.Zone__current;
+      if (C.C__RootZone === currentZone) {
+        P._rootScheduleMicrotask(_null, _null, C.C__RootZone, callback);
+        return;
+      }
+      P._rootScheduleMicrotask(_null, _null, currentZone, type$.void_Function._as(currentZone.bindCallbackGuarded$1(callback)));
+    },
+    StreamIterator_StreamIterator: function(stream, $T) {
+      P.ArgumentError_checkNotNull(stream, "stream", $T._eval$1("Stream<0>"));
+      return new P._StreamIterator(stream, $T._eval$1("_StreamIterator<0>"));
+    },
+    StreamController_StreamController: function($T) {
+      var _null = null;
+      return new P._AsyncStreamController(_null, _null, _null, _null, $T._eval$1("_AsyncStreamController<0>"));
+    },
+    StreamController_StreamController$broadcast: function(sync, $T) {
+      var _null = null;
+      return sync ? new P._SyncBroadcastStreamController(_null, _null, $T._eval$1("_SyncBroadcastStreamController<0>")) : new P._AsyncBroadcastStreamController(_null, _null, $T._eval$1("_AsyncBroadcastStreamController<0>"));
+    },
+    _runGuarded: function(notificationHandler) {
+      return;
+    },
+    _BufferingStreamSubscription__registerDataHandler: function(zone, handleData, $T) {
+      var t1 = handleData == null ? P.async___nullDataHandler$closure() : handleData;
+      return type$.$env_1_1_void._bind$1($T)._eval$1("1(2)")._as(t1);
+    },
+    _BufferingStreamSubscription__registerErrorHandler: function(zone, handleError) {
+      if (handleError == null)
+        handleError = P.async___nullErrorHandler$closure();
+      if (type$.void_Function_Object_StackTrace._is(handleError))
+        return zone.registerBinaryCallback$3$1(handleError, type$.dynamic, type$.Object, type$.StackTrace);
+      if (type$.void_Function_Object._is(handleError))
+        return type$.dynamic_Function_Object._as(handleError);
+      throw H.wrapException(P.ArgumentError$("handleError callback must take either an Object (the error), or both an Object (the error) and a StackTrace."));
+    },
+    _BufferingStreamSubscription__registerDoneHandler: function(zone, handleDone) {
+      return type$.void_Function._as(handleDone);
+    },
+    _nullDataHandler: function(value) {
+    },
+    _nullErrorHandler: function(error, stackTrace) {
+      P._rootHandleUncaughtError(null, null, $.Zone__current, error, stackTrace);
+    },
+    _cancelAndValue: function(subscription, future, value) {
+      var cancelFuture = subscription.cancel$0();
+      if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture())
+        cancelFuture.whenComplete$1(new P._cancelAndValue_closure(future, value));
+      else
+        future._complete$1(value);
+    },
+    Timer_Timer: function(duration, callback) {
+      var t1 = $.Zone__current;
+      if (t1 === C.C__RootZone)
+        return P.Timer__createTimer(duration, type$.void_Function._as(callback));
+      return P.Timer__createTimer(duration, type$.void_Function._as(t1.bindCallbackGuarded$1(callback)));
+    },
+    AsyncError$: function(error, stackTrace) {
+      var t1 = stackTrace == null ? P.AsyncError_defaultStackTrace(error) : stackTrace;
+      P.ArgumentError_checkNotNull(error, "error", type$.Object);
+      return new P.AsyncError(error, t1);
+    },
+    AsyncError_defaultStackTrace: function(error) {
+      var stackTrace;
+      if (type$.Error._is(error)) {
+        stackTrace = error.get$stackTrace();
+        if (stackTrace != null)
+          return stackTrace;
+      }
+      return C.C__StringStackTrace;
+    },
+    _rootHandleUncaughtError: function($self, $parent, zone, error, stackTrace) {
+      P._schedulePriorityAsyncCallback(new P._rootHandleUncaughtError_closure(error, stackTrace));
+    },
+    _rootRun: function($self, $parent, zone, f, $R) {
+      var old,
+        t1 = $.Zone__current;
+      if (t1 === zone)
+        return f.call$0();
+      $.Zone__current = zone;
+      old = t1;
+      try {
+        t1 = f.call$0();
+        return t1;
+      } finally {
+        $.Zone__current = old;
+      }
+    },
+    _rootRunUnary: function($self, $parent, zone, f, arg, $R, $T) {
+      var old,
+        t1 = $.Zone__current;
+      if (t1 === zone)
+        return f.call$1(arg);
+      $.Zone__current = zone;
+      old = t1;
+      try {
+        t1 = f.call$1(arg);
+        return t1;
+      } finally {
+        $.Zone__current = old;
+      }
+    },
+    _rootRunBinary: function($self, $parent, zone, f, arg1, arg2, $R, T1, T2) {
+      var old,
+        t1 = $.Zone__current;
+      if (t1 === zone)
+        return f.call$2(arg1, arg2);
+      $.Zone__current = zone;
+      old = t1;
+      try {
+        t1 = f.call$2(arg1, arg2);
+        return t1;
+      } finally {
+        $.Zone__current = old;
+      }
+    },
+    _rootScheduleMicrotask: function($self, $parent, zone, f) {
+      var t1;
+      type$.void_Function._as(f);
+      t1 = C.C__RootZone !== zone;
+      if (t1)
+        f = !(!t1 || false) ? zone.bindCallbackGuarded$1(f) : zone.bindCallback$1$1(f, type$.void);
+      P._scheduleAsyncCallback(f);
+    },
+    _AsyncRun__initializeScheduleImmediate_internalCallback: function _AsyncRun__initializeScheduleImmediate_internalCallback(t0) {
+      this._box_0 = t0;
+    },
+    _AsyncRun__initializeScheduleImmediate_closure: function _AsyncRun__initializeScheduleImmediate_closure(t0, t1, t2) {
+      this._box_0 = t0;
+      this.div = t1;
+      this.span = t2;
+    },
+    _AsyncRun__scheduleImmediateJsOverride_internalCallback: function _AsyncRun__scheduleImmediateJsOverride_internalCallback(t0) {
+      this.callback = t0;
+    },
+    _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback: function _AsyncRun__scheduleImmediateWithSetImmediate_internalCallback(t0) {
+      this.callback = t0;
+    },
+    _TimerImpl: function _TimerImpl() {
+      this._handle = null;
+    },
+    _TimerImpl_internalCallback: function _TimerImpl_internalCallback(t0, t1) {
+      this.$this = t0;
+      this.callback = t1;
+    },
+    _AsyncAwaitCompleter: function _AsyncAwaitCompleter(t0, t1) {
+      this._future = t0;
+      this.isSync = false;
+      this.$ti = t1;
+    },
+    _awaitOnObject_closure: function _awaitOnObject_closure(t0) {
+      this.bodyFunction = t0;
+    },
+    _awaitOnObject_closure0: function _awaitOnObject_closure0(t0) {
+      this.bodyFunction = t0;
+    },
+    _wrapJsFunctionForAsync_closure: function _wrapJsFunctionForAsync_closure(t0) {
+      this.$protected = t0;
+    },
+    _BroadcastSubscription: function _BroadcastSubscription(t0, t1, t2, t3, t4, t5, t6) {
+      var _ = this;
+      _._eventState = 0;
+      _._async$_previous = _._async$_next = null;
+      _._controller = t0;
+      _._async$_onData = t1;
+      _._onError = t2;
+      _._onDone = t3;
+      _._zone = t4;
+      _._state = t5;
+      _._pending = _._cancelFuture = null;
+      _.$ti = t6;
+    },
+    _BroadcastStreamController: function _BroadcastStreamController() {
+    },
+    _SyncBroadcastStreamController: function _SyncBroadcastStreamController(t0, t1, t2) {
+      var _ = this;
+      _.onListen = t0;
+      _.onCancel = t1;
+      _._state = 0;
+      _._doneFuture = _._addStreamState = _._lastSubscription = _._firstSubscription = null;
+      _.$ti = t2;
+    },
+    _SyncBroadcastStreamController__sendData_closure: function _SyncBroadcastStreamController__sendData_closure(t0, t1) {
+      this.$this = t0;
+      this.data = t1;
+    },
+    _AsyncBroadcastStreamController: function _AsyncBroadcastStreamController(t0, t1, t2) {
+      var _ = this;
+      _.onListen = t0;
+      _.onCancel = t1;
+      _._state = 0;
+      _._doneFuture = _._addStreamState = _._lastSubscription = _._firstSubscription = null;
+      _.$ti = t2;
+    },
+    Future: function Future() {
+    },
+    Completer: function Completer() {
+    },
+    _Completer: function _Completer() {
+    },
+    _AsyncCompleter: function _AsyncCompleter(t0, t1) {
+      this.future = t0;
+      this.$ti = t1;
+    },
+    _FutureListener: function _FutureListener(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _._nextListener = null;
+      _.result = t0;
+      _.state = t1;
+      _.callback = t2;
+      _.errorCallback = t3;
+      _.$ti = t4;
+    },
+    _Future: function _Future(t0, t1) {
+      var _ = this;
+      _._state = 0;
+      _._zone = t0;
+      _._resultOrListeners = null;
+      _.$ti = t1;
+    },
+    _Future__addListener_closure: function _Future__addListener_closure(t0, t1) {
+      this.$this = t0;
+      this.listener = t1;
+    },
+    _Future__prependListeners_closure: function _Future__prependListeners_closure(t0, t1) {
+      this._box_0 = t0;
+      this.$this = t1;
+    },
+    _Future__chainForeignFuture_closure: function _Future__chainForeignFuture_closure(t0) {
+      this.target = t0;
+    },
+    _Future__chainForeignFuture_closure0: function _Future__chainForeignFuture_closure0(t0) {
+      this.target = t0;
+    },
+    _Future__chainForeignFuture_closure1: function _Future__chainForeignFuture_closure1(t0, t1, t2) {
+      this.target = t0;
+      this.e = t1;
+      this.s = t2;
+    },
+    _Future__asyncCompleteWithValue_closure: function _Future__asyncCompleteWithValue_closure(t0, t1) {
+      this.$this = t0;
+      this.value = t1;
+    },
+    _Future__chainFuture_closure: function _Future__chainFuture_closure(t0, t1) {
+      this.$this = t0;
+      this.value = t1;
+    },
+    _Future__asyncCompleteError_closure: function _Future__asyncCompleteError_closure(t0, t1, t2) {
+      this.$this = t0;
+      this.error = t1;
+      this.stackTrace = t2;
+    },
+    _Future__propagateToListeners_handleWhenCompleteCallback: function _Future__propagateToListeners_handleWhenCompleteCallback(t0, t1, t2) {
+      this._box_0 = t0;
+      this._box_1 = t1;
+      this.hasError = t2;
+    },
+    _Future__propagateToListeners_handleWhenCompleteCallback_closure: function _Future__propagateToListeners_handleWhenCompleteCallback_closure(t0) {
+      this.originalSource = t0;
+    },
+    _Future__propagateToListeners_handleValueCallback: function _Future__propagateToListeners_handleValueCallback(t0, t1) {
+      this._box_0 = t0;
+      this.sourceResult = t1;
+    },
+    _Future__propagateToListeners_handleError: function _Future__propagateToListeners_handleError(t0, t1) {
+      this._box_1 = t0;
+      this._box_0 = t1;
+    },
+    _AsyncCallbackEntry: function _AsyncCallbackEntry(t0) {
+      this.callback = t0;
+      this.next = null;
+    },
+    Stream: function Stream() {
+    },
+    Stream_length_closure: function Stream_length_closure(t0, t1) {
+      this._box_0 = t0;
+      this.$this = t1;
+    },
+    Stream_length_closure0: function Stream_length_closure0(t0, t1) {
+      this._box_0 = t0;
+      this.future = t1;
+    },
+    Stream_first_closure: function Stream_first_closure(t0) {
+      this.future = t0;
+    },
+    Stream_first_closure0: function Stream_first_closure0(t0, t1, t2) {
+      this.$this = t0;
+      this.subscription = t1;
+      this.future = t2;
+    },
+    StreamSubscription: function StreamSubscription() {
+    },
+    StreamTransformerBase: function StreamTransformerBase() {
+    },
+    StreamController: function StreamController() {
+    },
+    _StreamController: function _StreamController() {
+    },
+    _StreamController__subscribe_closure: function _StreamController__subscribe_closure(t0) {
+      this.$this = t0;
+    },
+    _StreamController__recordCancel_complete: function _StreamController__recordCancel_complete(t0) {
+      this.$this = t0;
+    },
+    _AsyncStreamControllerDispatch: function _AsyncStreamControllerDispatch() {
+    },
+    _AsyncStreamController: function _AsyncStreamController(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _._varData = null;
+      _._state = 0;
+      _._doneFuture = null;
+      _.onListen = t0;
+      _.onPause = t1;
+      _.onResume = t2;
+      _.onCancel = t3;
+      _.$ti = t4;
+    },
+    _ControllerStream: function _ControllerStream(t0, t1) {
+      this._controller = t0;
+      this.$ti = t1;
+    },
+    _ControllerSubscription: function _ControllerSubscription(t0, t1, t2, t3, t4, t5, t6) {
+      var _ = this;
+      _._controller = t0;
+      _._async$_onData = t1;
+      _._onError = t2;
+      _._onDone = t3;
+      _._zone = t4;
+      _._state = t5;
+      _._pending = _._cancelFuture = null;
+      _.$ti = t6;
+    },
+    _StreamSinkWrapper: function _StreamSinkWrapper(t0, t1) {
+      this._async$_target = t0;
+      this.$ti = t1;
+    },
+    _BufferingStreamSubscription: function _BufferingStreamSubscription() {
+    },
+    _BufferingStreamSubscription__sendError_sendError: function _BufferingStreamSubscription__sendError_sendError(t0, t1, t2) {
+      this.$this = t0;
+      this.error = t1;
+      this.stackTrace = t2;
+    },
+    _BufferingStreamSubscription__sendDone_sendDone: function _BufferingStreamSubscription__sendDone_sendDone(t0) {
+      this.$this = t0;
+    },
+    _StreamImpl: function _StreamImpl() {
+    },
+    _DelayedEvent: function _DelayedEvent() {
+    },
+    _DelayedData: function _DelayedData(t0, t1) {
+      this.value = t0;
+      this.next = null;
+      this.$ti = t1;
+    },
+    _DelayedError: function _DelayedError(t0, t1) {
+      this.error = t0;
+      this.stackTrace = t1;
+      this.next = null;
+    },
+    _DelayedDone: function _DelayedDone() {
+    },
+    _PendingEvents: function _PendingEvents() {
+    },
+    _PendingEvents_schedule_closure: function _PendingEvents_schedule_closure(t0, t1) {
+      this.$this = t0;
+      this.dispatch = t1;
+    },
+    _StreamImplEvents: function _StreamImplEvents(t0) {
+      var _ = this;
+      _.lastPendingEvent = _.firstPendingEvent = null;
+      _._state = 0;
+      _.$ti = t0;
+    },
+    _DoneStreamSubscription: function _DoneStreamSubscription(t0, t1, t2) {
+      var _ = this;
+      _._zone = t0;
+      _._state = 0;
+      _._onDone = t1;
+      _.$ti = t2;
+    },
+    _StreamIterator: function _StreamIterator(t0, t1) {
+      var _ = this;
+      _._async$_subscription = null;
+      _._stateData = t0;
+      _._isPaused = false;
+      _.$ti = t1;
+    },
+    _cancelAndValue_closure: function _cancelAndValue_closure(t0, t1) {
+      this.future = t0;
+      this.value = t1;
+    },
+    _ForwardingStream: function _ForwardingStream() {
+    },
+    _ForwardingStreamSubscription: function _ForwardingStreamSubscription(t0, t1, t2, t3, t4, t5, t6) {
+      var _ = this;
+      _._stream = t0;
+      _._async$_subscription = null;
+      _._async$_onData = t1;
+      _._onError = t2;
+      _._onDone = t3;
+      _._zone = t4;
+      _._state = t5;
+      _._pending = _._cancelFuture = null;
+      _.$ti = t6;
+    },
+    _MapStream: function _MapStream(t0, t1, t2) {
+      this._transform = t0;
+      this._async$_source = t1;
+      this.$ti = t2;
+    },
+    AsyncError: function AsyncError(t0, t1) {
+      this.error = t0;
+      this.stackTrace = t1;
+    },
+    _Zone: function _Zone() {
+    },
+    _rootHandleUncaughtError_closure: function _rootHandleUncaughtError_closure(t0, t1) {
+      this.error = t0;
+      this.stackTrace = t1;
+    },
+    _RootZone: function _RootZone() {
+    },
+    _RootZone_bindCallback_closure: function _RootZone_bindCallback_closure(t0, t1, t2) {
+      this.$this = t0;
+      this.f = t1;
+      this.R = t2;
+    },
+    _RootZone_bindCallbackGuarded_closure: function _RootZone_bindCallbackGuarded_closure(t0, t1) {
+      this.$this = t0;
+      this.f = t1;
+    },
+    _RootZone_bindUnaryCallbackGuarded_closure: function _RootZone_bindUnaryCallbackGuarded_closure(t0, t1, t2) {
+      this.$this = t0;
+      this.f = t1;
+      this.T = t2;
+    },
+    LinkedHashMap_LinkedHashMap: function($K, $V) {
+      return new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"));
+    },
+    LinkedHashMap_LinkedHashMap$_literal: function(keyValuePairs, $K, $V) {
+      return $K._eval$1("@<0>")._bind$1($V)._eval$1("LinkedHashMap<1,2>")._as(H.fillLiteralMap(keyValuePairs, new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"))));
+    },
+    LinkedHashMap_LinkedHashMap$_empty: function($K, $V) {
+      return new H.JsLinkedHashMap($K._eval$1("@<0>")._bind$1($V)._eval$1("JsLinkedHashMap<1,2>"));
+    },
+    LinkedHashSet_LinkedHashSet: function($E) {
+      return new P._LinkedHashSet($E._eval$1("_LinkedHashSet<0>"));
+    },
+    _LinkedHashSet__newHashTable: function() {
+      var table = Object.create(null);
+      table["<non-identifier-key>"] = table;
+      delete table["<non-identifier-key>"];
+      return table;
+    },
+    IterableBase_iterableToShortString: function(iterable, leftDelimiter, rightDelimiter) {
+      var parts, t1;
+      if (P._isToStringVisiting(iterable)) {
+        if (leftDelimiter === "(" && rightDelimiter === ")")
+          return "(...)";
+        return leftDelimiter + "..." + rightDelimiter;
+      }
+      parts = H.setRuntimeTypeInfo([], type$.JSArray_String);
+      C.JSArray_methods.add$1($._toStringVisiting, iterable);
+      try {
+        P._iterablePartsToStrings(iterable, parts);
+      } finally {
+        if (0 >= $._toStringVisiting.length)
+          return H.ioore($._toStringVisiting, -1);
+        $._toStringVisiting.pop();
+      }
+      t1 = P.StringBuffer__writeAll(leftDelimiter, type$.Iterable_dynamic._as(parts), ", ") + rightDelimiter;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    },
+    IterableBase_iterableToFullString: function(iterable, leftDelimiter, rightDelimiter) {
+      var buffer, t1;
+      if (P._isToStringVisiting(iterable))
+        return leftDelimiter + "..." + rightDelimiter;
+      buffer = new P.StringBuffer(leftDelimiter);
+      C.JSArray_methods.add$1($._toStringVisiting, iterable);
+      try {
+        t1 = buffer;
+        t1._contents = P.StringBuffer__writeAll(t1._contents, iterable, ", ");
+      } finally {
+        if (0 >= $._toStringVisiting.length)
+          return H.ioore($._toStringVisiting, -1);
+        $._toStringVisiting.pop();
+      }
+      buffer._contents += rightDelimiter;
+      t1 = buffer._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    },
+    _isToStringVisiting: function(o) {
+      var t1, i;
+      for (t1 = $._toStringVisiting.length, i = 0; i < t1; ++i)
+        if (o === $._toStringVisiting[i])
+          return true;
+      return false;
+    },
+    _iterablePartsToStrings: function(iterable, parts) {
+      var next, ultimateString, penultimateString, penultimate, ultimate, ultimate0, elision,
+        it = iterable.get$iterator(iterable),
+        $length = 0, count = 0;
+      while (true) {
+        if (!($length < 80 || count < 3))
+          break;
+        if (!it.moveNext$0())
+          return;
+        next = H.S(it.get$current());
+        C.JSArray_methods.add$1(parts, next);
+        $length += next.length + 2;
+        ++count;
+      }
+      if (!it.moveNext$0()) {
+        if (count <= 5)
+          return;
+        if (0 >= parts.length)
+          return H.ioore(parts, -1);
+        ultimateString = parts.pop();
+        if (0 >= parts.length)
+          return H.ioore(parts, -1);
+        penultimateString = parts.pop();
+      } else {
+        penultimate = it.get$current();
+        ++count;
+        if (!it.moveNext$0()) {
+          if (count <= 4) {
+            C.JSArray_methods.add$1(parts, H.S(penultimate));
+            return;
+          }
+          ultimateString = H.S(penultimate);
+          if (0 >= parts.length)
+            return H.ioore(parts, -1);
+          penultimateString = parts.pop();
+          $length += ultimateString.length + 2;
+        } else {
+          ultimate = it.get$current();
+          ++count;
+          for (; it.moveNext$0(); penultimate = ultimate, ultimate = ultimate0) {
+            ultimate0 = it.get$current();
+            ++count;
+            if (count > 100) {
+              while (true) {
+                if (!($length > 75 && count > 3))
+                  break;
+                if (0 >= parts.length)
+                  return H.ioore(parts, -1);
+                $length -= parts.pop().length + 2;
+                --count;
+              }
+              C.JSArray_methods.add$1(parts, "...");
+              return;
+            }
+          }
+          penultimateString = H.S(penultimate);
+          ultimateString = H.S(ultimate);
+          $length += ultimateString.length + penultimateString.length + 4;
+        }
+      }
+      if (count > parts.length + 2) {
+        $length += 5;
+        elision = "...";
+      } else
+        elision = null;
+      while (true) {
+        if (!($length > 80 && parts.length > 3))
+          break;
+        if (0 >= parts.length)
+          return H.ioore(parts, -1);
+        $length -= parts.pop().length + 2;
+        if (elision == null) {
+          $length += 5;
+          elision = "...";
+        }
+      }
+      if (elision != null)
+        C.JSArray_methods.add$1(parts, elision);
+      C.JSArray_methods.add$1(parts, penultimateString);
+      C.JSArray_methods.add$1(parts, ultimateString);
+    },
+    LinkedHashMap_LinkedHashMap$of: function(other, $K, $V) {
+      var t1 = P.LinkedHashMap_LinkedHashMap($K, $V);
+      t1.addAll$1(0, other);
+      return t1;
+    },
+    MapBase_mapToString: function(m) {
+      var result, t1 = {};
+      if (P._isToStringVisiting(m))
+        return "{...}";
+      result = new P.StringBuffer("");
+      try {
+        C.JSArray_methods.add$1($._toStringVisiting, m);
+        result._contents += "{";
+        t1.first = true;
+        m.forEach$1(0, new P.MapBase_mapToString_closure(t1, result));
+        result._contents += "}";
+      } finally {
+        if (0 >= $._toStringVisiting.length)
+          return H.ioore($._toStringVisiting, -1);
+        $._toStringVisiting.pop();
+      }
+      t1 = result._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    },
+    ListQueue__calculateCapacity: function(initialCapacity) {
+      return 8;
+    },
+    _LinkedHashSet: function _LinkedHashSet(t0) {
+      var _ = this;
+      _._collection$_length = 0;
+      _._collection$_last = _._collection$_first = _._collection$_rest = _._collection$_nums = _._collection$_strings = null;
+      _._collection$_modifications = 0;
+      _.$ti = t0;
+    },
+    _LinkedHashSetCell: function _LinkedHashSetCell(t0) {
+      this._element = t0;
+      this._collection$_next = null;
+    },
+    _LinkedHashSetIterator: function _LinkedHashSetIterator(t0, t1, t2) {
+      var _ = this;
+      _._set = t0;
+      _._collection$_modifications = t1;
+      _._collection$_current = _._collection$_cell = null;
+      _.$ti = t2;
+    },
+    ListMixin: function ListMixin() {
+    },
+    MapBase: function MapBase() {
+    },
+    MapBase_mapToString_closure: function MapBase_mapToString_closure(t0, t1) {
+      this._box_0 = t0;
+      this.result = t1;
+    },
+    MapMixin: function MapMixin() {
+    },
+    _UnmodifiableMapMixin: function _UnmodifiableMapMixin() {
+    },
+    MapView: function MapView() {
+    },
+    UnmodifiableMapView: function UnmodifiableMapView() {
+    },
+    ListQueue: function ListQueue(t0, t1) {
+      var _ = this;
+      _._collection$_table = t0;
+      _._modificationCount = _._tail = _._head = 0;
+      _.$ti = t1;
+    },
+    _ListQueueIterator: function _ListQueueIterator(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _._queue = t0;
+      _._end = t1;
+      _._modificationCount = t2;
+      _._position = t3;
+      _._collection$_current = null;
+      _.$ti = t4;
+    },
+    _SetBase: function _SetBase() {
+    },
+    _UnmodifiableMapView_MapView__UnmodifiableMapMixin: function _UnmodifiableMapView_MapView__UnmodifiableMapMixin() {
+    },
+    _parseJson: function(source, reviver) {
+      var parsed, e, exception, t1;
+      if (typeof source != "string")
+        throw H.wrapException(H.argumentErrorValue(source));
+      parsed = null;
+      try {
+        parsed = JSON.parse(source);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        t1 = P.FormatException$(String(e), null, null);
+        throw H.wrapException(t1);
+      }
+      t1 = P._convertJsonToDartLazy(parsed);
+      return t1;
+    },
+    _convertJsonToDartLazy: function(object) {
+      var i;
+      if (object == null)
+        return null;
+      if (typeof object != "object")
+        return object;
+      if (Object.getPrototypeOf(object) !== Array.prototype)
+        return new P._JsonMap(object, Object.create(null));
+      for (i = 0; i < object.length; ++i)
+        object[i] = P._convertJsonToDartLazy(object[i]);
+      return object;
+    },
+    Utf8Decoder__convertIntercepted: function(allowMalformed, codeUnits, start, end) {
+      var casted, result;
+      if (codeUnits instanceof Uint8Array) {
+        casted = codeUnits;
+        end = casted.length;
+        if (end - start < 15)
+          return null;
+        result = P.Utf8Decoder__convertInterceptedUint8List(allowMalformed, casted, start, end);
+        if (result != null && allowMalformed)
+          if (result.indexOf("\ufffd") >= 0)
+            return null;
+        return result;
+      }
+      return null;
+    },
+    Utf8Decoder__convertInterceptedUint8List: function(allowMalformed, codeUnits, start, end) {
+      var decoder = allowMalformed ? $.$get$Utf8Decoder__decoderNonfatal() : $.$get$Utf8Decoder__decoder();
+      if (decoder == null)
+        return null;
+      if (0 === start && end === codeUnits.length)
+        return P.Utf8Decoder__useTextDecoder(decoder, codeUnits);
+      return P.Utf8Decoder__useTextDecoder(decoder, codeUnits.subarray(start, P.RangeError_checkValidRange(start, end, codeUnits.length)));
+    },
+    Utf8Decoder__useTextDecoder: function(decoder, codeUnits) {
+      var t1, exception;
+      try {
+        t1 = decoder.decode(codeUnits);
+        return t1;
+      } catch (exception) {
+        H.unwrapException(exception);
+      }
+      return null;
+    },
+    JsonUnsupportedObjectError$: function(unsupportedObject, cause, partialResult) {
+      return new P.JsonUnsupportedObjectError(unsupportedObject, cause);
+    },
+    _defaultToEncodable: function(object) {
+      return object.toJson$0();
+    },
+    _JsonStringStringifier_stringify: function(object, toEncodable, indent) {
+      var t1,
+        output = new P.StringBuffer(""),
+        stringifier = new P._JsonStringStringifier(output, [], P.convert___defaultToEncodable$closure());
+      stringifier.writeObject$1(object);
+      t1 = output._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    },
+    _Utf8Decoder_errorDescription: function(state) {
+      switch (state) {
+        case 65:
+          return "Missing extension byte";
+        case 67:
+          return "Unexpected extension byte";
+        case 69:
+          return "Invalid UTF-8 byte";
+        case 71:
+          return "Overlong encoding";
+        case 73:
+          return "Out of unicode range";
+        case 75:
+          return "Encoded surrogate";
+        case 77:
+          return "Unfinished UTF-8 octet sequence";
+        default:
+          return "";
+      }
+    },
+    _JsonMap: function _JsonMap(t0, t1) {
+      this._original = t0;
+      this._processed = t1;
+      this._data = null;
+    },
+    _JsonMapKeyIterable: function _JsonMapKeyIterable(t0) {
+      this._parent = t0;
+    },
+    Utf8Decoder_closure: function Utf8Decoder_closure() {
+    },
+    Utf8Decoder_closure0: function Utf8Decoder_closure0() {
+    },
+    Codec: function Codec() {
+    },
+    Converter: function Converter() {
+    },
+    JsonUnsupportedObjectError: function JsonUnsupportedObjectError(t0, t1) {
+      this.unsupportedObject = t0;
+      this.cause = t1;
+    },
+    JsonCyclicError: function JsonCyclicError(t0, t1) {
+      this.unsupportedObject = t0;
+      this.cause = t1;
+    },
+    JsonCodec: function JsonCodec() {
+    },
+    JsonEncoder: function JsonEncoder(t0) {
+      this._toEncodable = t0;
+    },
+    JsonDecoder: function JsonDecoder(t0) {
+      this._reviver = t0;
+    },
+    _JsonStringifier: function _JsonStringifier() {
+    },
+    _JsonStringifier_writeMap_closure: function _JsonStringifier_writeMap_closure(t0, t1) {
+      this._box_0 = t0;
+      this.keyValueList = t1;
+    },
+    _JsonStringStringifier: function _JsonStringStringifier(t0, t1, t2) {
+      this._sink = t0;
+      this._seen = t1;
+      this._toEncodable = t2;
+    },
+    Utf8Decoder: function Utf8Decoder(t0) {
+      this._allowMalformed = t0;
+    },
+    _Utf8Decoder: function _Utf8Decoder(t0) {
+      this.allowMalformed = t0;
+      this._convert$_state = 16;
+      this._charOrIndex = 0;
+    },
+    _symbolMapToStringMap: function(map) {
+      var result = new H.JsLinkedHashMap(type$.JsLinkedHashMap_String_dynamic);
+      map.forEach$1(0, new P._symbolMapToStringMap_closure(result));
+      return result;
+    },
+    Function_apply: function($function, positionalArguments, namedArguments) {
+      return H.Primitives_applyFunction($function, positionalArguments, namedArguments == null ? null : P._symbolMapToStringMap(namedArguments));
+    },
+    int_parse: function(source) {
+      var value = H.Primitives_parseInt(source, null);
+      if (value != null)
+        return value;
+      throw H.wrapException(P.FormatException$(source, null, null));
+    },
+    Error__objectToString: function(object) {
+      if (object instanceof H.Closure)
+        return object.toString$0(0);
+      return "Instance of '" + H.S(H.Primitives_objectTypeName(object)) + "'";
+    },
+    List_List$filled: function($length, fill, growable, $E) {
+      var i,
+        result = growable ? J.JSArray_JSArray$growable($length, $E) : J.JSArray_JSArray$fixed($length, $E);
+      if ($length !== 0 && fill != null)
+        for (i = 0; i < result.length; ++i)
+          result[i] = fill;
+      return result;
+    },
+    List_List$from: function(elements, growable, $E) {
+      var t1,
+        list = H.setRuntimeTypeInfo([], $E._eval$1("JSArray<0>"));
+      for (t1 = J.get$iterator$ax(elements); t1.moveNext$0();)
+        C.JSArray_methods.add$1(list, $E._as(t1.get$current()));
+      return list;
+    },
+    String_String$fromCharCodes: function(charCodes, start, end) {
+      var array, len, t1;
+      if (Array.isArray(charCodes)) {
+        array = charCodes;
+        len = array.length;
+        end = P.RangeError_checkValidRange(start, end, len);
+        return H.Primitives_stringFromCharCodes(start > 0 || end < len ? array.slice(start, end) : array);
+      }
+      t1 = H.Primitives_stringFromNativeUint8List(charCodes, start, P.RangeError_checkValidRange(start, end, charCodes.length));
+      return t1;
+    },
+    StringBuffer__writeAll: function(string, objects, separator) {
+      var iterator = J.get$iterator$ax(objects);
+      if (!iterator.moveNext$0())
+        return string;
+      if (separator.length === 0) {
+        do
+          string += H.S(iterator.get$current());
+        while (iterator.moveNext$0());
+      } else {
+        string += H.S(iterator.get$current());
+        for (; iterator.moveNext$0();)
+          string = string + separator + H.S(iterator.get$current());
+      }
+      return string;
+    },
+    NoSuchMethodError$: function(receiver, memberName, positionalArguments, namedArguments) {
+      return new P.NoSuchMethodError(receiver, memberName, positionalArguments, namedArguments);
+    },
+    StackTrace_current: function() {
+      var stackTrace, exception;
+      if (H.boolConversionCheck($.$get$_hasErrorStackProperty()))
+        return H.getTraceFromException(new Error());
+      try {
+        throw H.wrapException("");
+      } catch (exception) {
+        H.unwrapException(exception);
+        stackTrace = H.getTraceFromException(exception);
+        return stackTrace;
+      }
+    },
+    DateTime__fourDigits: function(n) {
+      var absN = Math.abs(n),
+        sign = n < 0 ? "-" : "";
+      if (absN >= 1000)
+        return "" + n;
+      if (absN >= 100)
+        return sign + "0" + absN;
+      if (absN >= 10)
+        return sign + "00" + absN;
+      return sign + "000" + absN;
+    },
+    DateTime__threeDigits: function(n) {
+      if (n >= 100)
+        return "" + n;
+      if (n >= 10)
+        return "0" + n;
+      return "00" + n;
+    },
+    DateTime__twoDigits: function(n) {
+      if (n >= 10)
+        return "" + n;
+      return "0" + n;
+    },
+    Error_safeToString: function(object) {
+      if (typeof object == "number" || H._isBool(object) || null == object)
+        return J.toString$0$(object);
+      if (typeof object == "string")
+        return JSON.stringify(object);
+      return P.Error__objectToString(object);
+    },
+    AssertionError$: function(message) {
+      return new P.AssertionError(message);
+    },
+    ArgumentError$: function(message) {
+      return new P.ArgumentError(false, null, null, message);
+    },
+    ArgumentError$value: function(value, $name, message) {
+      return new P.ArgumentError(true, value, $name, message);
+    },
+    ArgumentError_checkNotNull: function(argument, $name, $T) {
+      if (argument == null)
+        throw H.wrapException(new P.ArgumentError(false, null, $name, "Must not be null"));
+      return argument;
+    },
+    RangeError$: function(message) {
+      var _null = null;
+      return new P.RangeError(_null, _null, false, _null, _null, message);
+    },
+    RangeError$value: function(value, $name) {
+      return new P.RangeError(null, null, true, value, $name, "Value not in range");
+    },
+    RangeError$range: function(invalidValue, minValue, maxValue, $name, message) {
+      return new P.RangeError(minValue, maxValue, true, invalidValue, $name, "Invalid value");
+    },
+    RangeError_checkValidRange: function(start, end, $length) {
+      if (0 > start || start > $length)
+        throw H.wrapException(P.RangeError$range(start, 0, $length, "start", null));
+      if (end != null) {
+        if (start > end || end > $length)
+          throw H.wrapException(P.RangeError$range(end, start, $length, "end", null));
+        return end;
+      }
+      return $length;
+    },
+    RangeError_checkNotNegative: function(value, $name) {
+      if (value < 0)
+        throw H.wrapException(P.RangeError$range(value, 0, null, $name, null));
+      return value;
+    },
+    IndexError$: function(invalidValue, indexable, $name, message, $length) {
+      var t1 = H._asIntS($length == null ? J.get$length$asx(indexable) : $length);
+      return new P.IndexError(t1, true, invalidValue, $name, "Index out of range");
+    },
+    UnsupportedError$: function(message) {
+      return new P.UnsupportedError(message);
+    },
+    UnimplementedError$: function(message) {
+      return new P.UnimplementedError(message);
+    },
+    StateError$: function(message) {
+      return new P.StateError(message);
+    },
+    ConcurrentModificationError$: function(modifiedObject) {
+      return new P.ConcurrentModificationError(modifiedObject);
+    },
+    Exception_Exception: function(message) {
+      return new P._Exception(message);
+    },
+    FormatException$: function(message, source, offset) {
+      return new P.FormatException(message, source, offset);
+    },
+    _symbolMapToStringMap_closure: function _symbolMapToStringMap_closure(t0) {
+      this.result = t0;
+    },
+    NoSuchMethodError_toString_closure: function NoSuchMethodError_toString_closure(t0, t1) {
+      this._box_0 = t0;
+      this.sb = t1;
+    },
+    bool: function bool() {
+    },
+    DateTime: function DateTime(t0, t1) {
+      this._value = t0;
+      this.isUtc = t1;
+    },
+    double: function double() {
+    },
+    Duration: function Duration(t0) {
+      this._duration = t0;
+    },
+    Duration_toString_sixDigits: function Duration_toString_sixDigits() {
+    },
+    Duration_toString_twoDigits: function Duration_toString_twoDigits() {
+    },
+    Error0: function Error0() {
+    },
+    AssertionError: function AssertionError(t0) {
+      this.message = t0;
+    },
+    NullThrownError: function NullThrownError() {
+    },
+    ArgumentError: function ArgumentError(t0, t1, t2, t3) {
+      var _ = this;
+      _._hasValue = t0;
+      _.invalidValue = t1;
+      _.name = t2;
+      _.message = t3;
+    },
+    RangeError: function RangeError(t0, t1, t2, t3, t4, t5) {
+      var _ = this;
+      _.start = t0;
+      _.end = t1;
+      _._hasValue = t2;
+      _.invalidValue = t3;
+      _.name = t4;
+      _.message = t5;
+    },
+    IndexError: function IndexError(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _.length = t0;
+      _._hasValue = t1;
+      _.invalidValue = t2;
+      _.name = t3;
+      _.message = t4;
+    },
+    NoSuchMethodError: function NoSuchMethodError(t0, t1, t2, t3) {
+      var _ = this;
+      _._core$_receiver = t0;
+      _._core$_memberName = t1;
+      _._core$_arguments = t2;
+      _._namedArguments = t3;
+    },
+    UnsupportedError: function UnsupportedError(t0) {
+      this.message = t0;
+    },
+    UnimplementedError: function UnimplementedError(t0) {
+      this.message = t0;
+    },
+    StateError: function StateError(t0) {
+      this.message = t0;
+    },
+    ConcurrentModificationError: function ConcurrentModificationError(t0) {
+      this.modifiedObject = t0;
+    },
+    OutOfMemoryError: function OutOfMemoryError() {
+    },
+    StackOverflowError: function StackOverflowError() {
+    },
+    CyclicInitializationError: function CyclicInitializationError(t0) {
+      this.variableName = t0;
+    },
+    _Exception: function _Exception(t0) {
+      this.message = t0;
+    },
+    FormatException: function FormatException(t0, t1, t2) {
+      this.message = t0;
+      this.source = t1;
+      this.offset = t2;
+    },
+    Function: function Function() {
+    },
+    int: function int() {
+    },
+    Iterable: function Iterable() {
+    },
+    Iterator: function Iterator() {
+    },
+    List: function List() {
+    },
+    Map: function Map() {
+    },
+    MapEntry: function MapEntry() {
+    },
+    Null: function Null() {
+    },
+    num: function num() {
+    },
+    Object: function Object() {
+    },
+    StackTrace: function StackTrace() {
+    },
+    _StringStackTrace: function _StringStackTrace() {
+    },
+    String: function String() {
+    },
+    StringBuffer: function StringBuffer(t0) {
+      this._contents = t0;
+    },
+    Symbol0: function Symbol0() {
+    },
+    convertDartToNative_Dictionary: function(dict) {
+      var object = {};
+      dict.forEach$1(0, new P.convertDartToNative_Dictionary_closure(object));
+      return object;
+    },
+    _AcceptStructuredClone: function _AcceptStructuredClone() {
+    },
+    _AcceptStructuredClone_walk_closure: function _AcceptStructuredClone_walk_closure(t0, t1) {
+      this._box_0 = t0;
+      this.$this = t1;
+    },
+    convertDartToNative_Dictionary_closure: function convertDartToNative_Dictionary_closure(t0) {
+      this.object = t0;
+    },
+    _AcceptStructuredCloneDart2Js: function _AcceptStructuredCloneDart2Js(t0, t1) {
+      this.values = t0;
+      this.copies = t1;
+      this.mustCopy = false;
+    },
+    promiseToFuture: function(jsPromise, $T) {
+      var t1 = new P._Future($.Zone__current, $T._eval$1("_Future<0>")),
+        completer = new P._AsyncCompleter(t1, $T._eval$1("_AsyncCompleter<0>"));
+      jsPromise.then(H.convertDartClosureToJS(new P.promiseToFuture_closure(completer, $T), 1), H.convertDartClosureToJS(new P.promiseToFuture_closure0(completer), 1));
+      return t1;
+    },
+    promiseToFuture_closure: function promiseToFuture_closure(t0, t1) {
+      this.completer = t0;
+      this.T = t1;
+    },
+    promiseToFuture_closure0: function promiseToFuture_closure0(t0) {
+      this.completer = t0;
+    },
+    _JSRandom: function _JSRandom() {
+    },
+    ByteBuffer: function ByteBuffer() {
+    },
+    ByteData: function ByteData() {
+    },
+    Int8List: function Int8List() {
+    },
+    Uint8List: function Uint8List() {
+    },
+    Uint8ClampedList: function Uint8ClampedList() {
+    },
+    Int16List: function Int16List() {
+    },
+    Uint16List: function Uint16List() {
+    },
+    Int32List: function Int32List() {
+    },
+    Uint32List: function Uint32List() {
+    },
+    Float32List: function Float32List() {
+    },
+    Float64List: function Float64List() {
+    }
+  },
+  W = {
+    EventSource__factoryEventSource: function(url, eventSourceInitDict) {
+      var t1 = new EventSource(url, P.convertDartToNative_Dictionary(eventSourceInitDict));
+      return t1;
+    },
+    HttpRequest_request: function(url, method, sendData, withCredentials) {
+      var t2, t3, t4,
+        t1 = new P._Future($.Zone__current, type$._Future_HttpRequest),
+        completer = new P._AsyncCompleter(t1, type$._AsyncCompleter_HttpRequest),
+        xhr = new XMLHttpRequest();
+      C.HttpRequest_methods.open$3$async(xhr, method, url, true);
+      xhr.withCredentials = true;
+      t2 = type$.nullable_void_Function_legacy_ProgressEvent;
+      t3 = t2._as(new W.HttpRequest_request_closure(xhr, completer));
+      type$.nullable_void_Function._as(null);
+      t4 = type$.legacy_ProgressEvent;
+      W._EventStreamSubscription$(xhr, "load", t3, false, t4);
+      W._EventStreamSubscription$(xhr, "error", t2._as(completer.get$completeError()), false, t4);
+      xhr.send(sendData);
+      return t1;
+    },
+    _EventStreamSubscription$: function(_target, _eventType, onData, _useCapture, $T) {
+      var t1 = onData == null ? null : W._wrapZone(new W._EventStreamSubscription_closure(onData), type$.Event);
+      t1 = new W._EventStreamSubscription(_target, _eventType, t1, false, $T._eval$1("_EventStreamSubscription<0>"));
+      t1._tryResume$0();
+      return t1;
+    },
+    _wrapZone: function(callback, $T) {
+      var t1 = $.Zone__current;
+      if (t1 === C.C__RootZone)
+        return callback;
+      return t1.bindUnaryCallbackGuarded$1$1(callback, $T);
+    },
+    DomException: function DomException() {
+    },
+    Event0: function Event0() {
+    },
+    EventSource: function EventSource() {
+    },
+    EventTarget: function EventTarget() {
+    },
+    HttpRequest: function HttpRequest() {
+    },
+    HttpRequest_request_closure: function HttpRequest_request_closure(t0, t1) {
+      this.xhr = t0;
+      this.completer = t1;
+    },
+    HttpRequestEventTarget: function HttpRequestEventTarget() {
+    },
+    MessageEvent: function MessageEvent() {
+    },
+    ProgressEvent: function ProgressEvent() {
+    },
+    EventStreamProvider: function EventStreamProvider(t0, t1) {
+      this._eventType = t0;
+      this.$ti = t1;
+    },
+    _EventStream: function _EventStream(t0, t1, t2, t3) {
+      var _ = this;
+      _._target = t0;
+      _._eventType = t1;
+      _._useCapture = t2;
+      _.$ti = t3;
+    },
+    _EventStreamSubscription: function _EventStreamSubscription(t0, t1, t2, t3, t4) {
+      var _ = this;
+      _._pauseCount = 0;
+      _._target = t0;
+      _._eventType = t1;
+      _._onData = t2;
+      _._useCapture = t3;
+      _.$ti = t4;
+    },
+    _EventStreamSubscription_closure: function _EventStreamSubscription_closure(t0) {
+      this.onData = t0;
+    },
+    _EventStreamSubscription_onData_closure: function _EventStreamSubscription_onData_closure(t0) {
+      this.handleData = t0;
+    }
+  },
+  V = {ErrorResult: function ErrorResult(t0, t1) {
+      this.error = t0;
+      this.stackTrace = t1;
+    }},
+  E = {Result: function Result() {
+    },
+    main: function() {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.void),
+        ddsChannel, vmService, id, message, channel, t1, t2, t3, $async$temp1, $async$temp2, $async$temp3;
+      var $async$main = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1)
+          return P._asyncRethrow($async$result, $async$completer);
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              channel = M.SseClient$("/test");
+              t1 = channel._incomingController;
+              t2 = new Q.QueueList(type$.QueueList_legacy_Result_legacy_String);
+              t3 = new Array(8);
+              t3.fixed$length = Array;
+              t2.set$_table(H.setRuntimeTypeInfo(t3, type$.JSArray_legacy_Result_legacy_String));
+              $async$temp1 = M;
+              $async$goto = 2;
+              return P._asyncAwait(new G.StreamQueue(new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>")), t2, new P.ListQueue(P.List_List$filled(P.ListQueue__calculateCapacity(null), null, false, type$.nullable__EventRequest_dynamic), type$.ListQueue_legacy__EventRequest_dynamic), type$.StreamQueue_legacy_String).get$next(), $async$main);
+            case 2:
+              // returning from await.
+              ddsChannel = $async$temp1.SseClient$($async$result);
+              t2 = new W._EventStream(ddsChannel._eventSource, "open", false, type$._EventStream_legacy_Event);
+              $async$goto = 3;
+              return P._asyncAwait(t2.get$first(t2), $async$main);
+            case 3:
+              // returning from await.
+              t2 = ddsChannel._incomingController;
+              vmService = Q.VmService$(new P._ControllerStream(t2, H._instanceType(t2)._eval$1("_ControllerStream<1>")), new E.main_closure(ddsChannel));
+              id = "" + ++vmService._id;
+              t2 = new P._Future($.Zone__current, type$._Future_legacy_Version);
+              vmService._completers.$indexSet(0, id, new P._AsyncCompleter(t2, type$._AsyncCompleter_legacy_Version));
+              vmService._methodCalls.$indexSet(0, id, "getVersion");
+              t1 = type$.dynamic;
+              message = C.C_JsonCodec.encode$2$toEncodable(P.LinkedHashMap_LinkedHashMap$_literal(["jsonrpc", "2.0", "id", id, "method", "getVersion", "params", C.Map_empty], t1, t1), null);
+              vmService._onSend.add$1(0, message);
+              vmService._writeMessage.call$1(message);
+              t1 = channel._outgoingController;
+              $async$temp1 = t1;
+              $async$temp2 = H._instanceType(t1)._precomputed1;
+              $async$temp3 = C.C_JsonCodec;
+              $async$goto = 4;
+              return P._asyncAwait(t2, $async$main);
+            case 4:
+              // returning from await.
+              $async$temp1.add$1(0, $async$temp2._as($async$temp3.encode$1($async$result.json)));
+              ddsChannel.close$0(0);
+              // implicit return
+              return P._asyncReturn(null, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$main, $async$completer);
+    },
+    main_closure: function main_closure(t0) {
+      this.ddsChannel = t0;
+    }
+  },
+  F = {ValueResult: function ValueResult(t0, t1) {
+      this.value = t0;
+      this.$ti = t1;
+    },
+    Logger_Logger: function($name) {
+      return $.Logger__loggers.putIfAbsent$2($name, new F.Logger_Logger_closure($name));
+    },
+    Logger: function Logger(t0, t1, t2) {
+      var _ = this;
+      _.name = t0;
+      _.parent = t1;
+      _._level = null;
+      _._children = t2;
+    },
+    Logger_Logger_closure: function Logger_Logger_closure(t0) {
+      this.name = t0;
+    }
+  },
+  G = {StreamQueue: function StreamQueue(t0, t1, t2, t3) {
+      var _ = this;
+      _._source = t0;
+      _._subscription = null;
+      _._isDone = false;
+      _._eventsReceived = 0;
+      _._eventQueue = t1;
+      _._requestQueue = t2;
+      _.$ti = t3;
+    }, StreamQueue__ensureListening_closure: function StreamQueue__ensureListening_closure(t0) {
+      this.$this = t0;
+    }, StreamQueue__ensureListening_closure1: function StreamQueue__ensureListening_closure1(t0) {
+      this.$this = t0;
+    }, StreamQueue__ensureListening_closure0: function StreamQueue__ensureListening_closure0(t0) {
+      this.$this = t0;
+    }, _EventRequest: function _EventRequest() {
+    }, _NextRequest: function _NextRequest(t0, t1) {
+      this._completer = t0;
+      this.$ti = t1;
+    }},
+  Q = {QueueList: function QueueList(t0) {
+      var _ = this;
+      _._table = null;
+      _._queue_list$_tail = _._queue_list$_head = 0;
+      _.$ti = t0;
+    }, _QueueList_Object_ListMixin: function _QueueList_Object_ListMixin() {
+    },
+    createServiceObject: function(json, expectedTypes) {
+      var t1, type, _null = null;
+      if (json == null)
+        return _null;
+      if (type$.legacy_List_dynamic._is(json)) {
+        t1 = J.map$1$1$ax(json, new Q.createServiceObject_closure(expectedTypes), type$.legacy_Object);
+        return P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"));
+      } else if (type$.legacy_Map_dynamic_dynamic._is(json)) {
+        type = H._asStringS(json.$index(0, "type"));
+        if (type == null)
+          if (expectedTypes.length === 1)
+            type = (expectedTypes && C.JSArray_methods).get$first(expectedTypes);
+          else
+            return _null;
+        else if (J.$eq$(json.$index(0, "type"), "@Instance") && J.$eq$(json.$index(0, "kind"), "Null") && !(expectedTypes && C.JSArray_methods).contains$1(expectedTypes, type))
+          return _null;
+        if ($._typeFactories.$index(0, type) == null)
+          return _null;
+        else
+          return $._typeFactories.$index(0, type).call$1(json);
+      } else
+        return json;
+    },
+    _createSpecificObject: function(json, creator) {
+      var t1, t2, key;
+      if (json == null)
+        return null;
+      if (type$.legacy_List_dynamic._is(json)) {
+        t1 = J.map$1$1$ax(json, new Q._createSpecificObject_closure(creator), type$.dynamic);
+        return P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E"));
+      } else if (type$.legacy_Map_dynamic_dynamic._is(json)) {
+        t1 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic);
+        for (t2 = json.get$keys(), t2 = t2.get$iterator(t2); t2.moveNext$0();) {
+          key = H._asStringS(t2.get$current());
+          t1.$indexSet(0, key, json.$index(0, key));
+        }
+        return creator.call$1(t1);
+      } else
+        return json;
+    },
+    _setIfNotNull: function(json, key, value) {
+      if (value == null)
+        return;
+      json.$indexSet(0, key, value);
+    },
+    VmService$: function(inStream, writeMessage) {
+      var t1 = type$.legacy_String;
+      t1 = new Q.VmService(P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_Completer_dynamic), P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_legacy_Future_legacy_Map_of_legacy_String_and_dynamic_Function_legacy_Map_of_legacy_String_and_dynamic), P.StreamController_StreamController$broadcast(true, t1), P.StreamController_StreamController$broadcast(true, t1), new P._AsyncCompleter(new P._Future($.Zone__current, type$._Future_dynamic), type$._AsyncCompleter_dynamic), P.LinkedHashMap_LinkedHashMap$_empty(t1, type$.legacy_StreamController_legacy_Event));
+      t1.VmService$5$disposeHandler$log$streamClosed(inStream, writeMessage, null, null, null);
+      return t1;
+    },
+    ExtensionData_parse: function(json) {
+      return json == null ? null : new Q.ExtensionData(json);
+    },
+    AllocationProfile_parse: function(json) {
+      var t1, t2,
+        _s24_ = "dateLastAccumulatorReset",
+        _s17_ = "dateLastServiceGC";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.AllocationProfile(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "members"), C.List_ClassHeapStats);
+      if (t2 == null)
+        t2 = [];
+      t1.set$members(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ClassHeapStats));
+      t1.memoryUsage = type$.legacy_MemoryUsage._as(Q.createServiceObject(json.$index(0, "memoryUsage"), C.List_MemoryUsage));
+      t1.dateLastAccumulatorReset = H._asIntS(typeof json.$index(0, _s24_) == "string" ? P.int_parse(H._asStringS(json.$index(0, _s24_))) : json.$index(0, _s24_));
+      t1.dateLastServiceGC = H._asIntS(typeof json.$index(0, _s17_) == "string" ? P.int_parse(H._asStringS(json.$index(0, _s17_))) : json.$index(0, _s17_));
+      return t1;
+    },
+    BoundField_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.BoundField();
+      t1.decl = type$.legacy_FieldRef._as(Q.createServiceObject(json.$index(0, "decl"), C.List_FieldRef));
+      t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_InstanceRef_Sentinel);
+      return t1;
+    },
+    BoundVariable_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.BoundVariable(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_PAk);
+      t1.declarationTokenPos = H._asIntS(json.$index(0, "declarationTokenPos"));
+      t1.scopeStartTokenPos = H._asIntS(json.$index(0, "scopeStartTokenPos"));
+      t1.scopeEndTokenPos = H._asIntS(json.$index(0, "scopeEndTokenPos"));
+      return t1;
+    },
+    Breakpoint_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Breakpoint(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.breakpointNumber = H._asIntS(json.$index(0, "breakpointNumber"));
+      t1.resolved = H._asBoolS(json.$index(0, "resolved"));
+      t1.isSyntheticAsyncContinuation = H._asBoolS(json.$index(0, "isSyntheticAsyncContinuation"));
+      t1.location = Q.createServiceObject(json.$index(0, "location"), C.List_oqh);
+      return t1;
+    },
+    ClassRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ClassRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    Class_parse: function(json) {
+      var t1, t2, t3, t4, t5;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Class(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.error = type$.legacy_ErrorRef._as(Q.createServiceObject(json.$index(0, "error"), C.List_ErrorRef));
+      t1.isAbstract = H._asBoolS(json.$index(0, "abstract"));
+      t1.isConst = H._asBoolS(json.$index(0, "const"));
+      t1.library = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "library"), C.List_LibraryRef));
+      t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation));
+      t2 = type$.legacy_ClassRef;
+      t1.superClass = t2._as(Q.createServiceObject(json.$index(0, "super"), C.List_ClassRef));
+      t3 = type$.legacy_InstanceRef;
+      t1.superType = t3._as(Q.createServiceObject(json.$index(0, "superType"), C.List_InstanceRef));
+      t4 = Q.createServiceObject(json.$index(0, "interfaces"), C.List_InstanceRef);
+      if (t4 == null)
+        t4 = [];
+      t5 = type$.Iterable_dynamic;
+      t1.set$interfaces(P.List_List$from(t5._as(t4), true, t3));
+      t1.mixin = t3._as(Q.createServiceObject(json.$index(0, "mixin"), C.List_InstanceRef));
+      t3 = Q.createServiceObject(json.$index(0, "fields"), C.List_FieldRef);
+      t1.set$fields(P.List_List$from(t5._as(t3 == null ? [] : t3), true, type$.legacy_FieldRef));
+      t3 = Q.createServiceObject(json.$index(0, "functions"), C.List_FuncRef);
+      t1.set$functions(P.List_List$from(t5._as(t3 == null ? [] : t3), true, type$.legacy_FuncRef));
+      t3 = Q.createServiceObject(json.$index(0, "subclasses"), C.List_ClassRef);
+      t1.set$subclasses(P.List_List$from(t5._as(t3 == null ? [] : t3), true, t2));
+      return t1;
+    },
+    ClassHeapStats_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ClassHeapStats(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.classRef = type$.legacy_ClassRef._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef));
+      t1.accumulatedSize = H._asIntS(json.$index(0, "accumulatedSize"));
+      t1.bytesCurrent = H._asIntS(json.$index(0, "bytesCurrent"));
+      t1.instancesAccumulated = H._asIntS(json.$index(0, "instancesAccumulated"));
+      t1.instancesCurrent = H._asIntS(json.$index(0, "instancesCurrent"));
+      return t1;
+    },
+    ClassList_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ClassList(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "classes"), C.List_ClassRef);
+      if (t2 == null)
+        t2 = [];
+      t1.set$classes(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ClassRef));
+      return t1;
+    },
+    ClientName_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ClientName(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    CodeRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.CodeRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      return t1;
+    },
+    Code_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Code(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      return t1;
+    },
+    ContextRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ContextRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.length = H._asIntS(json.$index(0, "length"));
+      return t1;
+    },
+    Context_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Context(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.length = H._asIntS(json.$index(0, "length"));
+      t1.parent = type$.legacy_Context._as(Q.createServiceObject(json.$index(0, "parent"), C.List_Context));
+      t2 = Q.createServiceObject(json.$index(0, "variables"), C.List_ContextElement);
+      if (t2 == null)
+        t2 = [];
+      t1.set$variables(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ContextElement));
+      return t1;
+    },
+    ContextElement_parse: function(json) {
+      var t1 = new Q.ContextElement();
+      t1.value = Q.createServiceObject(type$.legacy_Map_of_legacy_String_and_dynamic._as(json).$index(0, "value"), C.List_InstanceRef_Sentinel);
+      return t1;
+    },
+    CpuSamples_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.CpuSamples(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.samplePeriod = H._asIntS(json.$index(0, "samplePeriod"));
+      t1.maxStackDepth = H._asIntS(json.$index(0, "maxStackDepth"));
+      t1.sampleCount = H._asIntS(json.$index(0, "sampleCount"));
+      t1.timeSpan = H._asIntS(json.$index(0, "timeSpan"));
+      t1.timeOriginMicros = H._asIntS(json.$index(0, "timeOriginMicros"));
+      t1.timeExtentMicros = H._asIntS(json.$index(0, "timeExtentMicros"));
+      t1.pid = H._asIntS(json.$index(0, "pid"));
+      t2 = Q.createServiceObject(json.$index(0, "functions"), C.List_ProfileFunction);
+      if (t2 == null)
+        t2 = [];
+      t3 = type$.Iterable_dynamic;
+      t1.set$functions(P.List_List$from(t3._as(t2), true, type$.legacy_ProfileFunction));
+      t2 = Q.createServiceObject(json.$index(0, "samples"), C.List_CpuSample);
+      t1.set$samples(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_CpuSample));
+      return t1;
+    },
+    CpuSample_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.CpuSample();
+      t1.tid = H._asIntS(json.$index(0, "tid"));
+      t1.timestamp = H._asIntS(json.$index(0, "timestamp"));
+      t1.vmTag = H._asStringS(json.$index(0, "vmTag"));
+      t1.userTag = H._asStringS(json.$index(0, "userTag"));
+      t1.truncated = H._asBoolS(json.$index(0, "truncated"));
+      t1.set$stack(P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, "stack")), true, type$.legacy_int));
+      return t1;
+    },
+    ErrorRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ErrorRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.message = H._asStringS(json.$index(0, "message"));
+      return t1;
+    },
+    Error_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Error(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.message = H._asStringS(json.$index(0, "message"));
+      t2 = type$.legacy_InstanceRef;
+      t1.exception = t2._as(Q.createServiceObject(json.$index(0, "exception"), C.List_InstanceRef));
+      t1.stacktrace = t2._as(Q.createServiceObject(json.$index(0, "stacktrace"), C.List_InstanceRef));
+      return t1;
+    },
+    Event_parse: function(json) {
+      var t1, t2, _null = null,
+        _s16_ = "pauseBreakpoints",
+        _s14_ = "timelineEvents",
+        _s14_0 = "updatedStreams";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Event(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.isolate = type$.legacy_IsolateRef._as(Q.createServiceObject(json.$index(0, "isolate"), C.List_IsolateRef));
+      t1.vm = type$.legacy_VMRef._as(Q.createServiceObject(json.$index(0, "vm"), C.List_VMRef));
+      t1.timestamp = H._asIntS(json.$index(0, "timestamp"));
+      t2 = type$.legacy_Breakpoint;
+      t1.breakpoint = t2._as(Q.createServiceObject(json.$index(0, "breakpoint"), C.List_Breakpoint));
+      t1.set$pauseBreakpoints(json.$index(0, _s16_) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s16_), C.List_Breakpoint)), true, t2));
+      t1.topFrame = type$.legacy_Frame._as(Q.createServiceObject(json.$index(0, "topFrame"), C.List_Frame));
+      t2 = type$.legacy_InstanceRef;
+      t1.exception = t2._as(Q.createServiceObject(json.$index(0, "exception"), C.List_InstanceRef));
+      t1.bytes = H._asStringS(json.$index(0, "bytes"));
+      t1.inspectee = t2._as(Q.createServiceObject(json.$index(0, "inspectee"), C.List_InstanceRef));
+      t1.extensionRPC = H._asStringS(json.$index(0, "extensionRPC"));
+      t1.extensionKind = H._asStringS(json.$index(0, "extensionKind"));
+      t2 = type$.legacy_Map_dynamic_dynamic._as(json.$index(0, "extensionData"));
+      t1.extensionData = t2 == null ? _null : new Q.ExtensionData(t2);
+      t1.set$timelineEvents(json.$index(0, _s14_) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s14_), C.List_TimelineEvent)), true, type$.legacy_TimelineEvent));
+      t1.set$updatedStreams(json.$index(0, _s14_0) == null ? _null : P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, _s14_0)), true, type$.legacy_String));
+      t1.atAsyncSuspension = H._asBoolS(json.$index(0, "atAsyncSuspension"));
+      t1.status = H._asStringS(json.$index(0, "status"));
+      t1.logRecord = type$.legacy_LogRecord._as(Q.createServiceObject(json.$index(0, "logRecord"), C.List_LogRecord));
+      t1.service = H._asStringS(json.$index(0, "service"));
+      t1.method = H._asStringS(json.$index(0, "method"));
+      t1.alias = H._asStringS(json.$index(0, "alias"));
+      t1.flag = H._asStringS(json.$index(0, "flag"));
+      t1.newValue = H._asStringS(json.$index(0, "newValue"));
+      t1.last = H._asBoolS(json.$index(0, "last"));
+      t1.data = type$.legacy_ByteData._as(json.$index(0, "data"));
+      return t1;
+    },
+    FieldRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.FieldRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.owner = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "owner"), C.List_ObjRef));
+      t1.declaredType = type$.legacy_InstanceRef._as(Q.createServiceObject(json.$index(0, "declaredType"), C.List_InstanceRef));
+      t1.isConst = H._asBoolS(json.$index(0, "const"));
+      t1.isFinal = H._asBoolS(json.$index(0, "final"));
+      t1.isStatic = H._asBoolS(json.$index(0, "static"));
+      return t1;
+    },
+    Field_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Field(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.owner = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "owner"), C.List_ObjRef));
+      t2 = type$.legacy_InstanceRef;
+      t1.declaredType = t2._as(Q.createServiceObject(json.$index(0, "declaredType"), C.List_InstanceRef));
+      t1.isConst = H._asBoolS(json.$index(0, "const"));
+      t1.isFinal = H._asBoolS(json.$index(0, "final"));
+      t1.isStatic = H._asBoolS(json.$index(0, "static"));
+      t1.staticValue = t2._as(Q.createServiceObject(json.$index(0, "staticValue"), C.List_InstanceRef));
+      t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation));
+      return t1;
+    },
+    Flag_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Flag();
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.comment = H._asStringS(json.$index(0, "comment"));
+      t1.modified = H._asBoolS(json.$index(0, "modified"));
+      t1.valueAsString = H._asStringS(json.$index(0, "valueAsString"));
+      return t1;
+    },
+    FlagList_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.FlagList(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "flags"), C.List_Flag);
+      if (t2 == null)
+        t2 = [];
+      t1.set$flags(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_Flag));
+      return t1;
+    },
+    Frame_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Frame(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.index = H._asIntS(json.$index(0, "index"));
+      t1.$function = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "function"), C.List_FuncRef));
+      t1.code = type$.legacy_CodeRef._as(Q.createServiceObject(json.$index(0, "code"), C.List_CodeRef));
+      t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation));
+      t1.set$vars(json.$index(0, "vars") == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, "vars"), C.List_BoundVariable)), true, type$.legacy_BoundVariable));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      return t1;
+    },
+    FuncRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.FuncRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.owner = Q.createServiceObject(json.$index(0, "owner"), C.List_LibraryRef_ClassRef_FuncRef);
+      t1.isStatic = H._asBoolS(json.$index(0, "static"));
+      t1.isConst = H._asBoolS(json.$index(0, "const"));
+      return t1;
+    },
+    Func_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Func(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.owner = Q.createServiceObject(json.$index(0, "owner"), C.List_LibraryRef_ClassRef_FuncRef);
+      t1.isStatic = H._asBoolS(json.$index(0, "static"));
+      t1.isConst = H._asBoolS(json.$index(0, "const"));
+      t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation));
+      t1.code = type$.legacy_CodeRef._as(Q.createServiceObject(json.$index(0, "code"), C.List_CodeRef));
+      return t1;
+    },
+    InstanceRef_parse: function(json) {
+      var t1 = Q.InstanceRef$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+      return t1;
+    },
+    InstanceRef$_fromJson: function(json) {
+      var t1 = new Q.InstanceRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.InstanceRef$_fromJson$1(json);
+      return t1;
+    },
+    Instance_parse: function(json) {
+      var t1 = Q.Instance$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+      return t1;
+    },
+    Instance$_fromJson: function(json) {
+      var t1 = new Q.Instance(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.Instance$_fromJson$1(json);
+      return t1;
+    },
+    IsolateRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.IsolateRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.id = H._asStringS(json.$index(0, "id"));
+      t1.number = H._asStringS(json.$index(0, "number"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    Isolate_parse: function(json) {
+      var t1, t2, t3, t4,
+        _s13_ = "extensionRPCs";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Isolate(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.id = H._asStringS(json.$index(0, "id"));
+      t1.number = H._asStringS(json.$index(0, "number"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.startTime = H._asIntS(json.$index(0, "startTime"));
+      t1.runnable = H._asBoolS(json.$index(0, "runnable"));
+      t1.livePorts = H._asIntS(json.$index(0, "livePorts"));
+      t1.pauseOnExit = H._asBoolS(json.$index(0, "pauseOnExit"));
+      t1.pauseEvent = type$.legacy_Event._as(Q.createServiceObject(json.$index(0, "pauseEvent"), C.List_Event));
+      t2 = type$.legacy_LibraryRef;
+      t1.rootLib = t2._as(Q.createServiceObject(json.$index(0, "rootLib"), C.List_LibraryRef));
+      t3 = Q.createServiceObject(json.$index(0, "libraries"), C.List_LibraryRef);
+      if (t3 == null)
+        t3 = [];
+      t4 = type$.Iterable_dynamic;
+      t1.set$libraries(P.List_List$from(t4._as(t3), true, t2));
+      t2 = Q.createServiceObject(json.$index(0, "breakpoints"), C.List_Breakpoint);
+      t1.set$breakpoints(P.List_List$from(t4._as(t2 == null ? [] : t2), true, type$.legacy_Breakpoint));
+      t1.error = type$.legacy_Error._as(Q.createServiceObject(json.$index(0, "error"), C.List_Error));
+      t1.exceptionPauseMode = H._asStringS(json.$index(0, "exceptionPauseMode"));
+      t1.set$extensionRPCs(json.$index(0, _s13_) == null ? null : P.List_List$from(t4._as(json.$index(0, _s13_)), true, type$.legacy_String));
+      return t1;
+    },
+    IsolateGroupRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.IsolateGroupRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.id = H._asStringS(json.$index(0, "id"));
+      t1.number = H._asStringS(json.$index(0, "number"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    IsolateGroup_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.IsolateGroup(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.id = H._asStringS(json.$index(0, "id"));
+      t1.number = H._asStringS(json.$index(0, "number"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t2 = Q.createServiceObject(json.$index(0, "isolates"), C.List_IsolateRef);
+      if (t2 == null)
+        t2 = [];
+      t1.set$isolates(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_IsolateRef));
+      return t1;
+    },
+    InboundReferences_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.InboundReferences(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "references"), C.List_InboundReference);
+      if (t2 == null)
+        t2 = [];
+      t1.set$references(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_InboundReference));
+      return t1;
+    },
+    InboundReference_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.InboundReference();
+      t1.source = type$.legacy_ObjRef._as(Q.createServiceObject(json.$index(0, "source"), C.List_ObjRef));
+      t1.parentListIndex = H._asIntS(json.$index(0, "parentListIndex"));
+      t1.parentField = type$.legacy_FieldRef._as(Q.createServiceObject(json.$index(0, "parentField"), C.List_FieldRef));
+      return t1;
+    },
+    InstanceSet_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.InstanceSet(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.totalCount = H._asIntS(json.$index(0, "totalCount"));
+      t2 = json.$index(0, "instances");
+      t1.set$instances(P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(t2 == null ? json.$index(0, "samples") : t2, C.List_ObjRef)), true, type$.legacy_ObjRef));
+      return t1;
+    },
+    LibraryRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.LibraryRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.uri = H._asStringS(json.$index(0, "uri"));
+      return t1;
+    },
+    Library_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Library(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.uri = H._asStringS(json.$index(0, "uri"));
+      t1.debuggable = H._asBoolS(json.$index(0, "debuggable"));
+      t2 = type$.Iterable_dynamic;
+      t1.set$dependencies(P.List_List$from(t2._as(Q._createSpecificObject(json.$index(0, "dependencies"), Q.vm_service_LibraryDependency_parse$closure())), true, type$.legacy_LibraryDependency));
+      t3 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef);
+      t1.set$scripts(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ScriptRef));
+      t3 = Q.createServiceObject(json.$index(0, "variables"), C.List_FieldRef);
+      t1.set$variables(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_FieldRef));
+      t3 = Q.createServiceObject(json.$index(0, "functions"), C.List_FuncRef);
+      t1.set$functions(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_FuncRef));
+      t3 = Q.createServiceObject(json.$index(0, "classes"), C.List_ClassRef);
+      t1.set$classes(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ClassRef));
+      return t1;
+    },
+    LibraryDependency_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      if (json == null)
+        t1 = null;
+      else {
+        t1 = new Q.LibraryDependency();
+        t1.isImport = H._asBoolS(json.$index(0, "isImport"));
+        t1.isDeferred = H._asBoolS(json.$index(0, "isDeferred"));
+        t1.prefix = H._asStringS(json.$index(0, "prefix"));
+        t1.target = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "target"), C.List_LibraryRef));
+      }
+      return t1;
+    },
+    LogRecord_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.LogRecord(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = type$.legacy_InstanceRef;
+      t1.message = t2._as(Q.createServiceObject(json.$index(0, "message"), C.List_InstanceRef));
+      t1.time = H._asIntS(json.$index(0, "time"));
+      t1.level = H._asIntS(json.$index(0, "level"));
+      t1.sequenceNumber = H._asIntS(json.$index(0, "sequenceNumber"));
+      t1.loggerName = t2._as(Q.createServiceObject(json.$index(0, "loggerName"), C.List_InstanceRef));
+      t1.zone = t2._as(Q.createServiceObject(json.$index(0, "zone"), C.List_InstanceRef));
+      t1.error = t2._as(Q.createServiceObject(json.$index(0, "error"), C.List_InstanceRef));
+      t1.stackTrace = t2._as(Q.createServiceObject(json.$index(0, "stackTrace"), C.List_InstanceRef));
+      return t1;
+    },
+    MapAssociation_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      if (json == null)
+        t1 = null;
+      else {
+        t1 = new Q.MapAssociation();
+        t1.key = Q.createServiceObject(json.$index(0, "key"), C.List_InstanceRef_Sentinel);
+        t1.value = Q.createServiceObject(json.$index(0, "value"), C.List_InstanceRef_Sentinel);
+      }
+      return t1;
+    },
+    MemoryUsage_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.MemoryUsage(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.externalUsage = H._asIntS(json.$index(0, "externalUsage"));
+      t1.heapCapacity = H._asIntS(json.$index(0, "heapCapacity"));
+      t1.heapUsage = H._asIntS(json.$index(0, "heapUsage"));
+      return t1;
+    },
+    Message_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Message(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.index = H._asIntS(json.$index(0, "index"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.messageObjectId = H._asStringS(json.$index(0, "messageObjectId"));
+      t1.size = H._asIntS(json.$index(0, "size"));
+      t1.handler = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "handler"), C.List_FuncRef));
+      t1.location = type$.legacy_SourceLocation._as(Q.createServiceObject(json.$index(0, "location"), C.List_SourceLocation));
+      return t1;
+    },
+    NativeFunction_parse: function(json) {
+      var t1 = new Q.NativeFunction();
+      t1.name = H._asStringS(type$.legacy_Map_of_legacy_String_and_dynamic._as(json).$index(0, "name"));
+      return t1;
+    },
+    NullValRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.NullValRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.InstanceRef$_fromJson$1(json);
+      t1.NullValRef_valueAsString = H._asStringS(json.$index(0, "valueAsString"));
+      return t1;
+    },
+    NullVal_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.NullVal(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.Instance$_fromJson$1(json);
+      t1.NullVal_valueAsString = H._asStringS(json.$index(0, "valueAsString"));
+      return t1;
+    },
+    ObjRef_parse: function(json) {
+      var t1 = Q.ObjRef$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+      return t1;
+    },
+    ObjRef$_fromJson: function(json) {
+      var t1 = new Q.ObjRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      return t1;
+    },
+    Obj_parse: function(json) {
+      var t1 = Q.Obj$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+      return t1;
+    },
+    Obj$_fromJson: function(json) {
+      var t1 = new Q.Obj(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      return t1;
+    },
+    ProfileFunction_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ProfileFunction();
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.inclusiveTicks = H._asIntS(json.$index(0, "inclusiveTicks"));
+      t1.exclusiveTicks = H._asIntS(json.$index(0, "exclusiveTicks"));
+      t1.resolvedUrl = H._asStringS(json.$index(0, "resolvedUrl"));
+      t1.$function = Q.createServiceObject(json.$index(0, "function"), C.List_dynamic);
+      return t1;
+    },
+    ReloadReport_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ReloadReport(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.success = H._asBoolS(json.$index(0, "success"));
+      return t1;
+    },
+    RetainingObject_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.RetainingObject();
+      t2 = type$.legacy_ObjRef;
+      t1.value = t2._as(Q.createServiceObject(json.$index(0, "value"), C.List_ObjRef));
+      t1.parentListIndex = H._asIntS(json.$index(0, "parentListIndex"));
+      t1.parentMapKey = t2._as(Q.createServiceObject(json.$index(0, "parentMapKey"), C.List_ObjRef));
+      t1.parentField = H._asStringS(json.$index(0, "parentField"));
+      return t1;
+    },
+    RetainingPath_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.RetainingPath(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.length = H._asIntS(json.$index(0, "length"));
+      t1.gcRootType = H._asStringS(json.$index(0, "gcRootType"));
+      t2 = Q.createServiceObject(json.$index(0, "elements"), C.List_RetainingObject);
+      if (t2 == null)
+        t2 = [];
+      t1.set$elements(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_RetainingObject));
+      return t1;
+    },
+    Response_parse: function(json) {
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      return json == null ? null : Q.Response$_fromJson(json);
+    },
+    Response$_fromJson: function(json) {
+      var t1 = new Q.Response(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      return t1;
+    },
+    Sentinel_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Sentinel(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.valueAsString = H._asStringS(json.$index(0, "valueAsString"));
+      return t1;
+    },
+    Sentinel$_fromJson: function(json) {
+      var t1 = new Q.Sentinel(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.kind = H._asStringS(json.$index(0, "kind"));
+      t1.valueAsString = H._asStringS(json.$index(0, "valueAsString"));
+      return t1;
+    },
+    ScriptRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ScriptRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.uri = H._asStringS(json.$index(0, "uri"));
+      return t1;
+    },
+    Script_parse: function(json) {
+      var t1 = Q.Script$_fromJson(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+      return t1;
+    },
+    Script$_fromJson: function(json) {
+      var t1 = type$.legacy_int;
+      t1 = new Q.Script(P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), P.LinkedHashMap_LinkedHashMap$_empty(t1, t1), json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.Script$_fromJson$1(json);
+      return t1;
+    },
+    ScriptList_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.ScriptList(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef);
+      if (t2 == null)
+        t2 = [];
+      t1.set$scripts(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_ScriptRef));
+      return t1;
+    },
+    SourceLocation_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.SourceLocation(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.script = type$.legacy_ScriptRef._as(Q.createServiceObject(json.$index(0, "script"), C.List_ScriptRef));
+      t1.tokenPos = H._asIntS(json.$index(0, "tokenPos"));
+      t1.endTokenPos = H._asIntS(json.$index(0, "endTokenPos"));
+      return t1;
+    },
+    SourceReport_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.SourceReport(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = type$.Iterable_dynamic;
+      t1.set$ranges(P.List_List$from(t2._as(Q._createSpecificObject(json.$index(0, "ranges"), Q.vm_service_SourceReportRange_parse$closure())), true, type$.legacy_SourceReportRange));
+      t3 = Q.createServiceObject(json.$index(0, "scripts"), C.List_ScriptRef);
+      t1.set$scripts(P.List_List$from(t2._as(t3 == null ? [] : t3), true, type$.legacy_ScriptRef));
+      return t1;
+    },
+    SourceReportCoverage_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      if (json == null)
+        t1 = null;
+      else {
+        t1 = new Q.SourceReportCoverage();
+        t2 = type$.Iterable_dynamic;
+        t3 = type$.legacy_int;
+        t1.set$hits(P.List_List$from(t2._as(json.$index(0, "hits")), true, t3));
+        t1.set$misses(P.List_List$from(t2._as(json.$index(0, "misses")), true, t3));
+      }
+      return t1;
+    },
+    SourceReportRange_parse: function(json) {
+      var t1,
+        _s19_ = "possibleBreakpoints";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      if (json == null)
+        t1 = null;
+      else {
+        t1 = new Q.SourceReportRange();
+        t1.scriptIndex = H._asIntS(json.$index(0, "scriptIndex"));
+        t1.startPos = H._asIntS(json.$index(0, "startPos"));
+        t1.endPos = H._asIntS(json.$index(0, "endPos"));
+        t1.compiled = H._asBoolS(json.$index(0, "compiled"));
+        t1.error = type$.legacy_ErrorRef._as(Q.createServiceObject(json.$index(0, "error"), C.List_ErrorRef));
+        t1.coverage = type$.legacy_SourceReportCoverage._as(Q._createSpecificObject(json.$index(0, "coverage"), Q.vm_service_SourceReportCoverage_parse$closure()));
+        t1.set$possibleBreakpoints(json.$index(0, _s19_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(json.$index(0, _s19_)), true, type$.legacy_int));
+      }
+      return t1;
+    },
+    Stack_parse: function(json) {
+      var t1, t2, t3, t4,
+        _s17_ = "asyncCausalFrames",
+        _s13_ = "awaiterFrames";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Stack(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "frames"), C.List_Frame);
+      if (t2 == null)
+        t2 = [];
+      t3 = type$.Iterable_dynamic;
+      t4 = type$.legacy_Frame;
+      t1.set$frames(P.List_List$from(t3._as(t2), true, t4));
+      t1.set$asyncCausalFrames(json.$index(0, _s17_) == null ? null : P.List_List$from(t3._as(Q.createServiceObject(json.$index(0, _s17_), C.List_Frame)), true, t4));
+      t1.set$awaiterFrames(json.$index(0, _s13_) == null ? null : P.List_List$from(t3._as(Q.createServiceObject(json.$index(0, _s13_), C.List_Frame)), true, t4));
+      t2 = Q.createServiceObject(json.$index(0, "messages"), C.List_Message);
+      t1.set$messages(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_Message));
+      return t1;
+    },
+    Success_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Success(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      return t1;
+    },
+    Timeline_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Timeline(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t2 = Q.createServiceObject(json.$index(0, "traceEvents"), C.List_TimelineEvent);
+      if (t2 == null)
+        t2 = [];
+      t1.set$traceEvents(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_TimelineEvent));
+      t1.timeOriginMicros = H._asIntS(json.$index(0, "timeOriginMicros"));
+      t1.timeExtentMicros = H._asIntS(json.$index(0, "timeExtentMicros"));
+      return t1;
+    },
+    TimelineEvent_parse: function(json) {
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      return new Q.TimelineEvent(json);
+    },
+    TimelineFlags_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.TimelineFlags(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.recorderName = H._asStringS(json.$index(0, "recorderName"));
+      t2 = type$.Iterable_dynamic;
+      t3 = type$.legacy_String;
+      t1.set$availableStreams(P.List_List$from(t2._as(json.$index(0, "availableStreams")), true, t3));
+      t1.set$recordedStreams(P.List_List$from(t2._as(json.$index(0, "recordedStreams")), true, t3));
+      return t1;
+    },
+    Timestamp_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Timestamp(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.timestamp = H._asIntS(json.$index(0, "timestamp"));
+      return t1;
+    },
+    TypeArgumentsRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.TypeArgumentsRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.ObjRef$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    TypeArguments_parse: function(json) {
+      var t1, t2;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.TypeArguments(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.Obj$_fromJson$1(json);
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t2 = Q.createServiceObject(json.$index(0, "types"), C.List_InstanceRef);
+      if (t2 == null)
+        t2 = [];
+      t1.set$types(P.List_List$from(type$.Iterable_dynamic._as(t2), true, type$.legacy_InstanceRef));
+      return t1;
+    },
+    UnresolvedSourceLocation_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.UnresolvedSourceLocation(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.script = type$.legacy_ScriptRef._as(Q.createServiceObject(json.$index(0, "script"), C.List_ScriptRef));
+      t1.scriptUri = H._asStringS(json.$index(0, "scriptUri"));
+      t1.tokenPos = H._asIntS(json.$index(0, "tokenPos"));
+      t1.line = H._asIntS(json.$index(0, "line"));
+      t1.column = H._asIntS(json.$index(0, "column"));
+      return t1;
+    },
+    Version_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.Version(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.major = H._asIntS(json.$index(0, "major"));
+      t1.minor = H._asIntS(json.$index(0, "minor"));
+      return t1;
+    },
+    VMRef_parse: function(json) {
+      var t1;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.VMRef(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      return t1;
+    },
+    VM_parse: function(json) {
+      var t1, t2, t3;
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(json);
+      t1 = new Q.VM(json);
+      t1.type = H._asStringS(json.$index(0, "type"));
+      t1.name = H._asStringS(json.$index(0, "name"));
+      t1.architectureBits = H._asIntS(json.$index(0, "architectureBits"));
+      t1.hostCPU = H._asStringS(json.$index(0, "hostCPU"));
+      t1.operatingSystem = H._asStringS(json.$index(0, "operatingSystem"));
+      t1.targetCPU = H._asStringS(json.$index(0, "targetCPU"));
+      t1.version = H._asStringS(json.$index(0, "version"));
+      t1.pid = H._asIntS(json.$index(0, "pid"));
+      t1.startTime = H._asIntS(json.$index(0, "startTime"));
+      t2 = Q.createServiceObject(json.$index(0, "isolates"), C.List_IsolateRef);
+      if (t2 == null)
+        t2 = [];
+      t3 = type$.Iterable_dynamic;
+      t1.set$isolates(P.List_List$from(t3._as(t2), true, type$.legacy_IsolateRef));
+      t2 = Q.createServiceObject(json.$index(0, "isolateGroups"), C.List_IsolateGroupRef);
+      t1.set$isolateGroups(P.List_List$from(t3._as(t2 == null ? [] : t2), true, type$.legacy_IsolateGroupRef));
+      return t1;
+    },
+    createServiceObject_closure: function createServiceObject_closure(t0) {
+      this.expectedTypes = t0;
+    },
+    _createSpecificObject_closure: function _createSpecificObject_closure(t0) {
+      this.creator = t0;
+    },
+    VmService: function VmService(t0, t1, t2, t3, t4, t5, t6) {
+      var _ = this;
+      _._writeMessage = null;
+      _._id = 0;
+      _._completers = t0;
+      _._methodCalls = t1;
+      _._services = t2;
+      _._log = null;
+      _._onSend = t3;
+      _._onReceive = t4;
+      _._onDoneCompleter = t5;
+      _._eventControllers = t6;
+    },
+    VmService_closure: function VmService_closure(t0) {
+      this.$this = t0;
+    },
+    RPCError: function RPCError(t0, t1, t2, t3) {
+      var _ = this;
+      _.callingMethod = t0;
+      _.code = t1;
+      _.message = t2;
+      _.data = t3;
+    },
+    SentinelException: function SentinelException(t0, t1) {
+      this.callingMethod = t0;
+      this.sentinel = t1;
+    },
+    ExtensionData: function ExtensionData(t0) {
+      this.data = t0;
+    },
+    _NullLog: function _NullLog() {
+    },
+    AllocationProfile: function AllocationProfile(t0) {
+      var _ = this;
+      _.dateLastServiceGC = _.dateLastAccumulatorReset = _.memoryUsage = _.members = null;
+      _.json = t0;
+      _.type = null;
+    },
+    AllocationProfile_toJson_closure: function AllocationProfile_toJson_closure() {
+    },
+    BoundField: function BoundField() {
+      this.value = this.decl = null;
+    },
+    BoundVariable: function BoundVariable(t0) {
+      var _ = this;
+      _.scopeEndTokenPos = _.scopeStartTokenPos = _.declarationTokenPos = _.value = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Breakpoint: function Breakpoint(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.location = _.isSyntheticAsyncContinuation = _.resolved = _.breakpointNumber = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ClassRef: function ClassRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Class: function Class(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.subclasses = _.functions = _.fields = _.mixin = _.interfaces = _.superType = _.superClass = _.location = _.library = _.isConst = _.isAbstract = _.error = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Class_toJson_closure: function Class_toJson_closure() {
+    },
+    Class_toJson_closure0: function Class_toJson_closure0() {
+    },
+    Class_toJson_closure1: function Class_toJson_closure1() {
+    },
+    Class_toJson_closure2: function Class_toJson_closure2() {
+    },
+    ClassHeapStats: function ClassHeapStats(t0) {
+      var _ = this;
+      _.instancesCurrent = _.instancesAccumulated = _.bytesCurrent = _.accumulatedSize = _.classRef = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ClassList: function ClassList(t0) {
+      this.classes = null;
+      this.json = t0;
+      this.type = null;
+    },
+    ClassList_toJson_closure: function ClassList_toJson_closure() {
+    },
+    ClientName: function ClientName(t0) {
+      this.name = null;
+      this.json = t0;
+      this.type = null;
+    },
+    CodeRef: function CodeRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.kind = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Code: function Code(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.kind = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ContextRef: function ContextRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.length = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Context: function Context(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.variables = _.parent = _.length = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Context_toJson_closure: function Context_toJson_closure() {
+    },
+    ContextElement: function ContextElement() {
+      this.value = null;
+    },
+    CpuSamples: function CpuSamples(t0) {
+      var _ = this;
+      _.samples = _.functions = _.pid = _.timeExtentMicros = _.timeOriginMicros = _.timeSpan = _.sampleCount = _.maxStackDepth = _.samplePeriod = null;
+      _.json = t0;
+      _.type = null;
+    },
+    CpuSamples_toJson_closure: function CpuSamples_toJson_closure() {
+    },
+    CpuSamples_toJson_closure0: function CpuSamples_toJson_closure0() {
+    },
+    CpuSample: function CpuSample() {
+      var _ = this;
+      _.stack = _.truncated = _.userTag = _.vmTag = _.timestamp = _.tid = null;
+    },
+    CpuSample_toJson_closure: function CpuSample_toJson_closure() {
+    },
+    ErrorRef: function ErrorRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.message = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Error: function Error(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.stacktrace = _.exception = _.message = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Event: function Event(t0) {
+      var _ = this;
+      _.data = _.last = _.newValue = _.flag = _.alias = _.method = _.service = _.logRecord = _.status = _.atAsyncSuspension = _.updatedStreams = _.timelineEvents = _.extensionData = _.extensionKind = _.extensionRPC = _.inspectee = _.bytes = _.exception = _.topFrame = _.pauseBreakpoints = _.breakpoint = _.timestamp = _.vm = _.isolate = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Event_toJson_closure: function Event_toJson_closure() {
+    },
+    Event_toJson_closure0: function Event_toJson_closure0() {
+    },
+    Event_toJson_closure1: function Event_toJson_closure1() {
+    },
+    FieldRef: function FieldRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.isStatic = _.isFinal = _.isConst = _.declaredType = _.owner = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Field: function Field(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.location = _.staticValue = _.isStatic = _.isFinal = _.isConst = _.declaredType = _.owner = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Flag: function Flag() {
+      var _ = this;
+      _.valueAsString = _.modified = _.comment = _.name = null;
+    },
+    FlagList: function FlagList(t0) {
+      this.flags = null;
+      this.json = t0;
+      this.type = null;
+    },
+    FlagList_toJson_closure: function FlagList_toJson_closure() {
+    },
+    Frame: function Frame(t0) {
+      var _ = this;
+      _.kind = _.vars = _.location = _.code = _.$function = _.index = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Frame_toJson_closure: function Frame_toJson_closure() {
+    },
+    FuncRef: function FuncRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.isConst = _.isStatic = _.owner = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Func: function Func(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.code = _.location = _.isConst = _.isStatic = _.owner = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    InstanceRef: function InstanceRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.closureContext = _.closureFunction = _.pattern = _.parameterizedClass = _.typeClass = _.name = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.classRef = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Instance: function Instance(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.bound = _.targetType = _.parameterIndex = _.typeArguments = _.propertyValue = _.propertyKey = _.isMultiLine = _.isCaseSensitive = _.closureContext = _.closureFunction = _.pattern = _.mirrorReferent = _.bytes = _.associations = _.elements = _.fields = _.parameterizedClass = _.typeClass = _.name = _.count = _.offset = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.Instance_classRef = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Instance_toJson_closure: function Instance_toJson_closure() {
+    },
+    Instance_toJson_closure0: function Instance_toJson_closure0() {
+    },
+    Instance_toJson_closure1: function Instance_toJson_closure1() {
+    },
+    IsolateRef: function IsolateRef(t0) {
+      var _ = this;
+      _.name = _.number = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Isolate: function Isolate(t0) {
+      var _ = this;
+      _.extensionRPCs = _.exceptionPauseMode = _.error = _.breakpoints = _.libraries = _.rootLib = _.pauseEvent = _.pauseOnExit = _.livePorts = _.runnable = _.startTime = _.name = _.number = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Isolate_toJson_closure: function Isolate_toJson_closure() {
+    },
+    Isolate_toJson_closure0: function Isolate_toJson_closure0() {
+    },
+    Isolate_toJson_closure1: function Isolate_toJson_closure1() {
+    },
+    IsolateGroupRef: function IsolateGroupRef(t0) {
+      var _ = this;
+      _.name = _.number = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    IsolateGroup: function IsolateGroup(t0) {
+      var _ = this;
+      _.isolates = _.name = _.number = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    IsolateGroup_toJson_closure: function IsolateGroup_toJson_closure() {
+    },
+    InboundReferences: function InboundReferences(t0) {
+      this.references = null;
+      this.json = t0;
+      this.type = null;
+    },
+    InboundReferences_toJson_closure: function InboundReferences_toJson_closure() {
+    },
+    InboundReference: function InboundReference() {
+      this.parentField = this.parentListIndex = this.source = null;
+    },
+    InstanceSet: function InstanceSet(t0) {
+      var _ = this;
+      _.instances = _.totalCount = null;
+      _.json = t0;
+      _.type = null;
+    },
+    InstanceSet_toJson_closure: function InstanceSet_toJson_closure() {
+    },
+    LibraryRef: function LibraryRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.uri = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Library: function Library(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.classes = _.functions = _.variables = _.scripts = _.dependencies = _.debuggable = _.uri = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Library_toJson_closure: function Library_toJson_closure() {
+    },
+    Library_toJson_closure0: function Library_toJson_closure0() {
+    },
+    Library_toJson_closure1: function Library_toJson_closure1() {
+    },
+    Library_toJson_closure2: function Library_toJson_closure2() {
+    },
+    Library_toJson_closure3: function Library_toJson_closure3() {
+    },
+    LibraryDependency: function LibraryDependency() {
+      var _ = this;
+      _.target = _.prefix = _.isDeferred = _.isImport = null;
+    },
+    LogRecord: function LogRecord(t0) {
+      var _ = this;
+      _.stackTrace = _.error = _.zone = _.loggerName = _.sequenceNumber = _.level = _.time = _.message = null;
+      _.json = t0;
+      _.type = null;
+    },
+    MapAssociation: function MapAssociation() {
+      this.value = this.key = null;
+    },
+    MemoryUsage: function MemoryUsage(t0) {
+      var _ = this;
+      _.heapUsage = _.heapCapacity = _.externalUsage = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Message: function Message(t0) {
+      var _ = this;
+      _.location = _.handler = _.size = _.messageObjectId = _.name = _.index = null;
+      _.json = t0;
+      _.type = null;
+    },
+    NativeFunction: function NativeFunction() {
+      this.name = null;
+    },
+    NullValRef: function NullValRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.closureContext = _.closureFunction = _.pattern = _.parameterizedClass = _.typeClass = _.name = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.classRef = _.kind = _.NullValRef_valueAsString = null;
+      _.json = t0;
+      _.type = null;
+    },
+    NullVal: function NullVal(t0) {
+      var _ = this;
+      _.classRef = _.fixedId = _.id = _.bound = _.targetType = _.parameterIndex = _.typeArguments = _.propertyValue = _.propertyKey = _.isMultiLine = _.isCaseSensitive = _.closureContext = _.closureFunction = _.pattern = _.mirrorReferent = _.bytes = _.associations = _.elements = _.fields = _.parameterizedClass = _.typeClass = _.name = _.count = _.offset = _.length = _.valueAsStringIsTruncated = _.valueAsString = _.Instance_classRef = _.kind = _.NullVal_valueAsString = null;
+      _.size = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ObjRef: function ObjRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Obj: function Obj(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ProfileFunction: function ProfileFunction() {
+      var _ = this;
+      _.$function = _.resolvedUrl = _.exclusiveTicks = _.inclusiveTicks = _.kind = null;
+    },
+    ReloadReport: function ReloadReport(t0) {
+      this.success = null;
+      this.json = t0;
+      this.type = null;
+    },
+    RetainingObject: function RetainingObject() {
+      var _ = this;
+      _.parentField = _.parentMapKey = _.parentListIndex = _.value = null;
+    },
+    RetainingPath: function RetainingPath(t0) {
+      var _ = this;
+      _.elements = _.gcRootType = _.length = null;
+      _.json = t0;
+      _.type = null;
+    },
+    RetainingPath_toJson_closure: function RetainingPath_toJson_closure() {
+    },
+    Response: function Response(t0) {
+      this.json = t0;
+      this.type = null;
+    },
+    Sentinel: function Sentinel(t0) {
+      var _ = this;
+      _.valueAsString = _.kind = null;
+      _.json = t0;
+      _.type = null;
+    },
+    ScriptRef: function ScriptRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.uri = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Script: function Script(t0, t1, t2) {
+      var _ = this;
+      _._tokenToLine = t0;
+      _._tokenToColumn = t1;
+      _.size = _.classRef = _.fixedId = _.id = _.tokenPosTable = _.source = _.columnOffset = _.lineOffset = _.library = _.uri = null;
+      _.json = t2;
+      _.type = null;
+    },
+    Script$_fromJson_closure: function Script$_fromJson_closure() {
+    },
+    Script_toJson_closure: function Script_toJson_closure() {
+    },
+    ScriptList: function ScriptList(t0) {
+      this.scripts = null;
+      this.json = t0;
+      this.type = null;
+    },
+    ScriptList_toJson_closure: function ScriptList_toJson_closure() {
+    },
+    SourceLocation: function SourceLocation(t0) {
+      var _ = this;
+      _.endTokenPos = _.tokenPos = _.script = null;
+      _.json = t0;
+      _.type = null;
+    },
+    SourceReport: function SourceReport(t0) {
+      var _ = this;
+      _.scripts = _.ranges = null;
+      _.json = t0;
+      _.type = null;
+    },
+    SourceReport_toJson_closure: function SourceReport_toJson_closure() {
+    },
+    SourceReport_toJson_closure0: function SourceReport_toJson_closure0() {
+    },
+    SourceReportCoverage: function SourceReportCoverage() {
+      this.misses = this.hits = null;
+    },
+    SourceReportCoverage_toJson_closure: function SourceReportCoverage_toJson_closure() {
+    },
+    SourceReportCoverage_toJson_closure0: function SourceReportCoverage_toJson_closure0() {
+    },
+    SourceReportRange: function SourceReportRange() {
+      var _ = this;
+      _.possibleBreakpoints = _.coverage = _.error = _.compiled = _.endPos = _.startPos = _.scriptIndex = null;
+    },
+    SourceReportRange_toJson_closure: function SourceReportRange_toJson_closure() {
+    },
+    Stack: function Stack(t0) {
+      var _ = this;
+      _.messages = _.awaiterFrames = _.asyncCausalFrames = _.frames = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Stack_toJson_closure: function Stack_toJson_closure() {
+    },
+    Stack_toJson_closure0: function Stack_toJson_closure0() {
+    },
+    Stack_toJson_closure1: function Stack_toJson_closure1() {
+    },
+    Stack_toJson_closure2: function Stack_toJson_closure2() {
+    },
+    Success: function Success(t0) {
+      this.json = t0;
+      this.type = null;
+    },
+    Timeline: function Timeline(t0) {
+      var _ = this;
+      _.timeExtentMicros = _.timeOriginMicros = _.traceEvents = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Timeline_toJson_closure: function Timeline_toJson_closure() {
+    },
+    TimelineEvent: function TimelineEvent(t0) {
+      this.json = t0;
+    },
+    TimelineFlags: function TimelineFlags(t0) {
+      var _ = this;
+      _.recordedStreams = _.availableStreams = _.recorderName = null;
+      _.json = t0;
+      _.type = null;
+    },
+    TimelineFlags_toJson_closure: function TimelineFlags_toJson_closure() {
+    },
+    TimelineFlags_toJson_closure0: function TimelineFlags_toJson_closure0() {
+    },
+    Timestamp: function Timestamp(t0) {
+      this.timestamp = null;
+      this.json = t0;
+      this.type = null;
+    },
+    TypeArgumentsRef: function TypeArgumentsRef(t0) {
+      var _ = this;
+      _.fixedId = _.id = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    TypeArguments: function TypeArguments(t0) {
+      var _ = this;
+      _.size = _.classRef = _.fixedId = _.id = _.types = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    TypeArguments_toJson_closure: function TypeArguments_toJson_closure() {
+    },
+    UnresolvedSourceLocation: function UnresolvedSourceLocation(t0) {
+      var _ = this;
+      _.column = _.line = _.tokenPos = _.scriptUri = _.script = null;
+      _.json = t0;
+      _.type = null;
+    },
+    Version: function Version(t0) {
+      var _ = this;
+      _.minor = _.major = null;
+      _.json = t0;
+      _.type = null;
+    },
+    VMRef: function VMRef(t0) {
+      this.name = null;
+      this.json = t0;
+      this.type = null;
+    },
+    VM: function VM(t0) {
+      var _ = this;
+      _.isolateGroups = _.isolates = _.startTime = _.pid = _.version = _.targetCPU = _.operatingSystem = _.hostCPU = _.architectureBits = _.name = null;
+      _.json = t0;
+      _.type = null;
+    },
+    VM_toJson_closure: function VM_toJson_closure() {
+    },
+    VM_toJson_closure0: function VM_toJson_closure0() {
+    }
+  },
+  N = {HexCodec: function HexCodec() {
+    }},
+  R = {
+    _convert: function(bytes, start, end) {
+      var t1, t2, i, bufferIndex, byteOr, byte, bufferIndex0, t3,
+        buffer = new Uint8Array((end - start) * 2);
+      for (t1 = buffer.length, t2 = bytes.length, i = start, bufferIndex = 0, byteOr = 0; i < end; ++i) {
+        if (i >= t2)
+          return H.ioore(bytes, i);
+        byte = bytes[i];
+        if (typeof byte !== "number")
+          return H.iae(byte);
+        byteOr = (byteOr | byte) >>> 0;
+        bufferIndex0 = bufferIndex + 1;
+        t3 = (byte & 240) >>> 4;
+        t3 = t3 < 10 ? t3 + 48 : t3 + 97 - 10;
+        if (bufferIndex >= t1)
+          return H.ioore(buffer, bufferIndex);
+        buffer[bufferIndex] = t3;
+        bufferIndex = bufferIndex0 + 1;
+        t3 = byte & 15;
+        t3 = t3 < 10 ? t3 + 48 : t3 + 97 - 10;
+        if (bufferIndex0 >= t1)
+          return H.ioore(buffer, bufferIndex0);
+        buffer[bufferIndex0] = t3;
+      }
+      if (byteOr >= 0 && byteOr <= 255)
+        return P.String_String$fromCharCodes(buffer, 0, null);
+      for (i = start; i < end; ++i) {
+        if (i >= t2)
+          return H.ioore(bytes, i);
+        byte = bytes[i];
+        if (typeof byte !== "number")
+          return byte.$ge();
+        if (byte >= 0 && byte <= 255)
+          continue;
+        throw H.wrapException(P.FormatException$("Invalid byte " + (byte < 0 ? "-" : "") + "0x" + C.JSInt_methods.toRadixString$1(Math.abs(byte), 16) + ".", bytes, i));
+      }
+      throw H.wrapException("unreachable");
+    },
+    HexEncoder: function HexEncoder() {
+    },
+    StreamChannelMixin: function StreamChannelMixin() {
+    }
+  },
+  Y = {Level: function Level(t0, t1) {
+      this.name = t0;
+      this.value = t1;
+    }},
+  L = {LogRecord0: function LogRecord0(t0, t1, t2) {
+      this.level = t0;
+      this.message = t1;
+      this.loggerName = t2;
+    }},
+  M = {
+    SseClient$: function(serverUrl) {
+      var t1 = type$.legacy_String;
+      t1 = new M.SseClient(P.StreamController_StreamController(t1), P.StreamController_StreamController(t1), F.Logger_Logger("SseClient"), P.StreamController_StreamController(type$.dynamic));
+      t1.SseClient$1(serverUrl);
+      return t1;
+    },
+    SseClient: function SseClient(t0, t1, t2, t3) {
+      var _ = this;
+      _._incomingController = t0;
+      _._outgoingController = t1;
+      _._logger = t2;
+      _._errorTimer = _._serverUrl = _._eventSource = null;
+      _._messages = t3;
+    },
+    SseClient_closure: function SseClient_closure(t0) {
+      this.$this = t0;
+    },
+    SseClient_closure0: function SseClient_closure0(t0) {
+      this.$this = t0;
+    },
+    SseClient__closure: function SseClient__closure(t0, t1) {
+      this.$this = t0;
+      this.error = t1;
+    }
+  },
+  K = {
+    Uuid$: function() {
+      var options, t2, t1 = {};
+      t1.options = options;
+      t1.options = null;
+      t2 = new K.Uuid();
+      t2.Uuid$1$options(t1);
+      return t2;
+    },
+    Uuid: function Uuid() {
+      var _ = this;
+      _._clockSeq = _._nodeId = _._seedBytes = null;
+      _._lastNSecs = _._lastMSecs = 0;
+      _._hexToByte = _._byteToHex = null;
+    }
+  },
+  T = {
+    UuidUtil_mathRNG: function() {
+      var b, rand, i,
+        t1 = new Array(16);
+      t1.fixed$length = Array;
+      b = H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_int);
+      for (rand = null, i = 0; i < 16; ++i) {
+        t1 = i & 3;
+        if (t1 === 0)
+          rand = C.JSInt_methods.toInt$0(C.JSNumber_methods.floor$0(C.C__JSRandom.nextDouble$0() * 4294967296));
+        if (typeof rand !== "number")
+          return rand.$shr();
+        C.JSArray_methods.$indexSet(b, i, C.JSInt_methods._shrOtherPositive$1(rand, t1 << 3) & 255);
+      }
+      return b;
+    }
+  };
+  var holders = [C, H, J, P, W, V, E, F, G, Q, N, R, Y, L, M, K, T];
+  hunkHelpers.setFunctionNamesIfNecessary(holders);
+  var $ = {};
+  H.JS_CONST.prototype = {};
+  J.Interceptor.prototype = {
+    $eq: function(receiver, other) {
+      return receiver === other;
+    },
+    get$hashCode: function(receiver) {
+      return H.Primitives_objectHashCode(receiver);
+    },
+    toString$0: function(receiver) {
+      return "Instance of '" + H.S(H.Primitives_objectTypeName(receiver)) + "'";
+    },
+    noSuchMethod$1: function(receiver, invocation) {
+      type$.Invocation._as(invocation);
+      throw H.wrapException(P.NoSuchMethodError$(receiver, invocation.get$memberName(), invocation.get$positionalArguments(), invocation.get$namedArguments()));
+    },
+    get$runtimeType: function(receiver) {
+      return H.getRuntimeType(receiver);
+    }
+  };
+  J.JSBool.prototype = {
+    toString$0: function(receiver) {
+      return String(receiver);
+    },
+    $and: function(receiver, other) {
+      return H.checkBool(H._asBoolS(other)) && receiver;
+    },
+    $or: function(receiver, other) {
+      return H.checkBool(H._asBoolS(other)) || receiver;
+    },
+    get$hashCode: function(receiver) {
+      return receiver ? 519018 : 218159;
+    },
+    get$runtimeType: function(receiver) {
+      return C.Type_bool_lhE;
+    },
+    $isbool: 1
+  };
+  J.JSNull.prototype = {
+    $eq: function(receiver, other) {
+      return null == other;
+    },
+    toString$0: function(receiver) {
+      return "null";
+    },
+    get$hashCode: function(receiver) {
+      return 0;
+    },
+    get$runtimeType: function(receiver) {
+      return C.Type_Null_Yyn;
+    },
+    noSuchMethod$1: function(receiver, invocation) {
+      return this.super$Interceptor$noSuchMethod(receiver, type$.Invocation._as(invocation));
+    },
+    $isNull: 1
+  };
+  J.JSObject.prototype = {};
+  J.JavaScriptObject.prototype = {
+    get$hashCode: function(receiver) {
+      return 0;
+    },
+    get$runtimeType: function(receiver) {
+      return C.Type_JSObject_8k0;
+    },
+    toString$0: function(receiver) {
+      return String(receiver);
+    }
+  };
+  J.PlainJavaScriptObject.prototype = {};
+  J.UnknownJavaScriptObject.prototype = {};
+  J.JavaScriptFunction.prototype = {
+    toString$0: function(receiver) {
+      var dartClosure = receiver[$.$get$DART_CLOSURE_PROPERTY_NAME()];
+      if (dartClosure == null)
+        return this.super$JavaScriptObject$toString(receiver);
+      return "JavaScript function for " + H.S(J.toString$0$(dartClosure));
+    },
+    $signature: function() {
+      return {func: 1, opt: [,,,,,,,,,,,,,,,,]};
+    },
+    $isFunction: 1
+  };
+  J.JSArray.prototype = {
+    add$1: function(receiver, value) {
+      H._arrayInstanceType(receiver)._precomputed1._as(value);
+      if (!!receiver.fixed$length)
+        H.throwExpression(P.UnsupportedError$("add"));
+      receiver.push(value);
+    },
+    addAll$1: function(receiver, collection) {
+      var t1, _i;
+      H._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(collection);
+      if (!!receiver.fixed$length)
+        H.throwExpression(P.UnsupportedError$("addAll"));
+      for (t1 = collection.length, _i = 0; _i < collection.length; collection.length === t1 || (0, H.throwConcurrentModificationError)(collection), ++_i)
+        receiver.push(collection[_i]);
+    },
+    map$1$1: function(receiver, f, $T) {
+      var t1 = H._arrayInstanceType(receiver);
+      return new H.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(2)")._as(f), t1._eval$1("@<1>")._bind$1($T)._eval$1("MappedListIterable<1,2>"));
+    },
+    map$1: function($receiver, f) {
+      return this.map$1$1($receiver, f, type$.dynamic);
+    },
+    elementAt$1: function(receiver, index) {
+      if (index < 0 || index >= receiver.length)
+        return H.ioore(receiver, index);
+      return receiver[index];
+    },
+    get$first: function(receiver) {
+      if (receiver.length > 0)
+        return receiver[0];
+      throw H.wrapException(H.IterableElementError_noElement());
+    },
+    setRange$4: function(receiver, start, end, iterable, skipCount) {
+      var $length, otherList, t1, i;
+      H._arrayInstanceType(receiver)._eval$1("Iterable<1>")._as(iterable);
+      if (!!receiver.immutable$list)
+        H.throwExpression(P.UnsupportedError$("setRange"));
+      P.RangeError_checkValidRange(start, end, receiver.length);
+      $length = end - start;
+      if ($length === 0)
+        return;
+      P.RangeError_checkNotNegative(skipCount, "skipCount");
+      otherList = iterable;
+      t1 = J.getInterceptor$asx(otherList);
+      if (skipCount + $length > t1.get$length(otherList))
+        throw H.wrapException(H.IterableElementError_tooFew());
+      if (skipCount < start)
+        for (i = $length - 1; i >= 0; --i)
+          receiver[start + i] = t1.$index(otherList, skipCount + i);
+      else
+        for (i = 0; i < $length; ++i)
+          receiver[start + i] = t1.$index(otherList, skipCount + i);
+    },
+    contains$1: function(receiver, other) {
+      var i;
+      for (i = 0; i < receiver.length; ++i)
+        if (J.$eq$(receiver[i], other))
+          return true;
+      return false;
+    },
+    get$isNotEmpty: function(receiver) {
+      return receiver.length !== 0;
+    },
+    toString$0: function(receiver) {
+      return P.IterableBase_iterableToFullString(receiver, "[", "]");
+    },
+    toList$1$growable: function(receiver, growable) {
+      var t1 = H.setRuntimeTypeInfo(receiver.slice(0), H._arrayInstanceType(receiver));
+      return t1;
+    },
+    toList$0: function($receiver) {
+      return this.toList$1$growable($receiver, true);
+    },
+    get$iterator: function(receiver) {
+      return new J.ArrayIterator(receiver, receiver.length, H._arrayInstanceType(receiver)._eval$1("ArrayIterator<1>"));
+    },
+    get$hashCode: function(receiver) {
+      return H.Primitives_objectHashCode(receiver);
+    },
+    get$length: function(receiver) {
+      return receiver.length;
+    },
+    set$length: function(receiver, newLength) {
+      if (!!receiver.fixed$length)
+        H.throwExpression(P.UnsupportedError$("set length"));
+      receiver.length = newLength;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      if (!H._isInt(index))
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      if (index >= receiver.length || index < 0)
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      return receiver[index];
+    },
+    $indexSet: function(receiver, index, value) {
+      H._asIntS(index);
+      H._arrayInstanceType(receiver)._precomputed1._as(value);
+      if (!!receiver.immutable$list)
+        H.throwExpression(P.UnsupportedError$("indexed set"));
+      if (!H._isInt(index))
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      if (index >= receiver.length || index < 0)
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      receiver[index] = value;
+    },
+    $add: function(receiver, other) {
+      var t2, _i,
+        t1 = H._arrayInstanceType(receiver);
+      t1._eval$1("List<1>")._as(other);
+      t1 = H.setRuntimeTypeInfo([], t1);
+      for (t2 = receiver.length, _i = 0; _i < receiver.length; receiver.length === t2 || (0, H.throwConcurrentModificationError)(receiver), ++_i)
+        this.add$1(t1, receiver[_i]);
+      for (t2 = other.get$iterator(other); t2.moveNext$0();)
+        this.add$1(t1, t2.get$current());
+      return t1;
+    },
+    $isJSIndexable: 1,
+    $isEfficientLengthIterable: 1,
+    $isIterable: 1,
+    $isList: 1
+  };
+  J.JSUnmodifiableArray.prototype = {};
+  J.ArrayIterator.prototype = {
+    get$current: function() {
+      return this.__interceptors$_current;
+    },
+    moveNext$0: function() {
+      var t2, _this = this,
+        t1 = _this.__interceptors$_iterable,
+        $length = t1.length;
+      if (_this.__interceptors$_length !== $length)
+        throw H.wrapException(H.throwConcurrentModificationError(t1));
+      t2 = _this.__interceptors$_index;
+      if (t2 >= $length) {
+        _this.set$__interceptors$_current(null);
+        return false;
+      }
+      _this.set$__interceptors$_current(t1[t2]);
+      ++_this.__interceptors$_index;
+      return true;
+    },
+    set$__interceptors$_current: function(_current) {
+      this.__interceptors$_current = this.$ti._eval$1("1?")._as(_current);
+    },
+    $isIterator: 1
+  };
+  J.JSNumber.prototype = {
+    toInt$0: function(receiver) {
+      var t1;
+      if (receiver >= -2147483648 && receiver <= 2147483647)
+        return receiver | 0;
+      if (isFinite(receiver)) {
+        t1 = receiver < 0 ? Math.ceil(receiver) : Math.floor(receiver);
+        return t1 + 0;
+      }
+      throw H.wrapException(P.UnsupportedError$("" + receiver + ".toInt()"));
+    },
+    floor$0: function(receiver) {
+      var truncated, d;
+      if (receiver >= 0) {
+        if (receiver <= 2147483647)
+          return receiver | 0;
+      } else if (receiver >= -2147483648) {
+        truncated = receiver | 0;
+        return receiver === truncated ? truncated : truncated - 1;
+      }
+      d = Math.floor(receiver);
+      if (isFinite(d))
+        return d;
+      throw H.wrapException(P.UnsupportedError$("" + receiver + ".floor()"));
+    },
+    toRadixString$1: function(receiver, radix) {
+      var result, match, t1, exponent;
+      if (radix < 2 || radix > 36)
+        throw H.wrapException(P.RangeError$range(radix, 2, 36, "radix", null));
+      result = receiver.toString(radix);
+      if (C.JSString_methods.codeUnitAt$1(result, result.length - 1) !== 41)
+        return result;
+      match = /^([\da-z]+)(?:\.([\da-z]+))?\(e\+(\d+)\)$/.exec(result);
+      if (match == null)
+        H.throwExpression(P.UnsupportedError$("Unexpected toString result: " + result));
+      t1 = match.length;
+      if (1 >= t1)
+        return H.ioore(match, 1);
+      result = match[1];
+      if (3 >= t1)
+        return H.ioore(match, 3);
+      exponent = +match[3];
+      t1 = match[2];
+      if (t1 != null) {
+        result += t1;
+        exponent -= t1.length;
+      }
+      return result + C.JSString_methods.$mul("0", exponent);
+    },
+    toString$0: function(receiver) {
+      if (receiver === 0 && 1 / receiver < 0)
+        return "-0.0";
+      else
+        return "" + receiver;
+    },
+    get$hashCode: function(receiver) {
+      var absolute, floorLog2, factor, scaled,
+        intValue = receiver | 0;
+      if (receiver === intValue)
+        return 536870911 & intValue;
+      absolute = Math.abs(receiver);
+      floorLog2 = Math.log(absolute) / 0.6931471805599453 | 0;
+      factor = Math.pow(2, floorLog2);
+      scaled = absolute < 1 ? absolute / factor : factor / absolute;
+      return 536870911 & ((scaled * 9007199254740992 | 0) + (scaled * 3542243181176521 | 0)) * 599197 + floorLog2 * 1259;
+    },
+    $add: function(receiver, other) {
+      H._asNumS(other);
+      return receiver + other;
+    },
+    $sub: function(receiver, other) {
+      return receiver - other;
+    },
+    $div: function(receiver, other) {
+      return receiver / other;
+    },
+    $mod: function(receiver, other) {
+      var result = receiver % other;
+      if (result === 0)
+        return 0;
+      if (result > 0)
+        return result;
+      if (other < 0)
+        return result - other;
+      else
+        return result + other;
+    },
+    _tdivFast$1: function(receiver, other) {
+      return (receiver | 0) === receiver ? receiver / other | 0 : this._tdivSlow$1(receiver, other);
+    },
+    _tdivSlow$1: function(receiver, other) {
+      var quotient = receiver / other;
+      if (quotient >= -2147483648 && quotient <= 2147483647)
+        return quotient | 0;
+      if (quotient > 0) {
+        if (quotient !== 1 / 0)
+          return Math.floor(quotient);
+      } else if (quotient > -1 / 0)
+        return Math.ceil(quotient);
+      throw H.wrapException(P.UnsupportedError$("Result of truncating division is " + H.S(quotient) + ": " + H.S(receiver) + " ~/ " + other));
+    },
+    $shl: function(receiver, other) {
+      if (other < 0)
+        throw H.wrapException(H.argumentErrorValue(other));
+      return other > 31 ? 0 : receiver << other >>> 0;
+    },
+    $shr: function(receiver, other) {
+      var t1;
+      if (other < 0)
+        throw H.wrapException(H.argumentErrorValue(other));
+      if (receiver > 0)
+        t1 = this._shrBothPositive$1(receiver, other);
+      else {
+        t1 = other > 31 ? 31 : other;
+        t1 = receiver >> t1 >>> 0;
+      }
+      return t1;
+    },
+    _shrOtherPositive$1: function(receiver, other) {
+      var t1;
+      if (receiver > 0)
+        t1 = this._shrBothPositive$1(receiver, other);
+      else {
+        t1 = other > 31 ? 31 : other;
+        t1 = receiver >> t1 >>> 0;
+      }
+      return t1;
+    },
+    _shrBothPositive$1: function(receiver, other) {
+      return other > 31 ? 0 : receiver >>> other;
+    },
+    $and: function(receiver, other) {
+      return (receiver & other) >>> 0;
+    },
+    $or: function(receiver, other) {
+      H._asNumS(other);
+      if (typeof other != "number")
+        throw H.wrapException(H.argumentErrorValue(other));
+      return (receiver | other) >>> 0;
+    },
+    $lt: function(receiver, other) {
+      return receiver < other;
+    },
+    $gt: function(receiver, other) {
+      return receiver > other;
+    },
+    $ge: function(receiver, other) {
+      if (typeof other != "number")
+        throw H.wrapException(H.argumentErrorValue(other));
+      return receiver >= other;
+    },
+    get$runtimeType: function(receiver) {
+      return C.Type_num_cv7;
+    },
+    $isdouble: 1,
+    $isnum: 1
+  };
+  J.JSInt.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_int_tHn;
+    },
+    $isint: 1
+  };
+  J.JSDouble.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_double_K1J;
+    }
+  };
+  J.JSString.prototype = {
+    codeUnitAt$1: function(receiver, index) {
+      if (index < 0)
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      if (index >= receiver.length)
+        H.throwExpression(H.diagnoseIndexError(receiver, index));
+      return receiver.charCodeAt(index);
+    },
+    _codeUnitAt$1: function(receiver, index) {
+      if (index >= receiver.length)
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      return receiver.charCodeAt(index);
+    },
+    $add: function(receiver, other) {
+      H._asStringS(other);
+      if (typeof other != "string")
+        throw H.wrapException(P.ArgumentError$value(other, null, null));
+      return receiver + other;
+    },
+    startsWith$1: function(receiver, pattern) {
+      var otherLength = pattern.length;
+      if (otherLength > receiver.length)
+        return false;
+      return pattern === receiver.substring(0, otherLength);
+    },
+    substring$2: function(receiver, startIndex, endIndex) {
+      if (endIndex == null)
+        endIndex = receiver.length;
+      if (startIndex < 0)
+        throw H.wrapException(P.RangeError$value(startIndex, null));
+      if (startIndex > endIndex)
+        throw H.wrapException(P.RangeError$value(startIndex, null));
+      if (endIndex > receiver.length)
+        throw H.wrapException(P.RangeError$value(endIndex, null));
+      return receiver.substring(startIndex, endIndex);
+    },
+    substring$1: function($receiver, startIndex) {
+      return this.substring$2($receiver, startIndex, null);
+    },
+    $mul: function(receiver, times) {
+      var s, result;
+      if (0 >= times)
+        return "";
+      if (times === 1 || receiver.length === 0)
+        return receiver;
+      if (times !== times >>> 0)
+        throw H.wrapException(C.C_OutOfMemoryError);
+      for (s = receiver, result = ""; true;) {
+        if ((times & 1) === 1)
+          result = s + result;
+        times = times >>> 1;
+        if (times === 0)
+          break;
+        s += s;
+      }
+      return result;
+    },
+    lastIndexOf$1: function(receiver, pattern) {
+      var start = receiver.length,
+        t1 = pattern.length;
+      if (start + t1 > start)
+        start -= t1;
+      return receiver.lastIndexOf(pattern, start);
+    },
+    toString$0: function(receiver) {
+      return receiver;
+    },
+    get$hashCode: function(receiver) {
+      var t1, hash, i;
+      for (t1 = receiver.length, hash = 0, i = 0; i < t1; ++i) {
+        hash = 536870911 & hash + receiver.charCodeAt(i);
+        hash = 536870911 & hash + ((524287 & hash) << 10);
+        hash ^= hash >> 6;
+      }
+      hash = 536870911 & hash + ((67108863 & hash) << 3);
+      hash ^= hash >> 11;
+      return 536870911 & hash + ((16383 & hash) << 15);
+    },
+    get$runtimeType: function(receiver) {
+      return C.Type_String_k8F;
+    },
+    get$length: function(receiver) {
+      return receiver.length;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      if (index >= receiver.length || false)
+        throw H.wrapException(H.diagnoseIndexError(receiver, index));
+      return receiver[index];
+    },
+    $isJSIndexable: 1,
+    $isPattern: 1,
+    $isString: 1
+  };
+  H.EfficientLengthIterable.prototype = {};
+  H.ListIterable.prototype = {
+    get$iterator: function(_) {
+      var _this = this;
+      return new H.ListIterator(_this, _this.get$length(_this), H._instanceType(_this)._eval$1("ListIterator<ListIterable.E>"));
+    },
+    get$isEmpty: function(_) {
+      return this.get$length(this) === 0;
+    },
+    map$1: function(_, f) {
+      var t1 = H._instanceType(this);
+      return new H.MappedListIterable(this, t1._eval$1("@(ListIterable.E)")._as(f), t1._eval$1("MappedListIterable<ListIterable.E,@>"));
+    }
+  };
+  H.ListIterator.prototype = {
+    get$current: function() {
+      var cur = this._current;
+      return cur;
+    },
+    moveNext$0: function() {
+      var t3, _this = this,
+        t1 = _this._iterable,
+        t2 = J.getInterceptor$asx(t1),
+        $length = t2.get$length(t1);
+      if (_this.__internal$_length !== $length)
+        throw H.wrapException(P.ConcurrentModificationError$(t1));
+      t3 = _this._index;
+      if (t3 >= $length) {
+        _this.set$_current(null);
+        return false;
+      }
+      _this.set$_current(t2.elementAt$1(t1, t3));
+      ++_this._index;
+      return true;
+    },
+    set$_current: function(_current) {
+      this._current = this.$ti._eval$1("1?")._as(_current);
+    },
+    $isIterator: 1
+  };
+  H.MappedIterable.prototype = {
+    get$iterator: function(_) {
+      var t1 = H._instanceType(this);
+      return new H.MappedIterator(J.get$iterator$ax(this._iterable), this._f, t1._eval$1("@<1>")._bind$1(t1._rest[1])._eval$1("MappedIterator<1,2>"));
+    },
+    get$length: function(_) {
+      return J.get$length$asx(this._iterable);
+    }
+  };
+  H.EfficientLengthMappedIterable.prototype = {$isEfficientLengthIterable: 1};
+  H.MappedIterator.prototype = {
+    moveNext$0: function() {
+      var _this = this,
+        t1 = _this._iterator;
+      if (t1.moveNext$0()) {
+        _this.set$_current(_this._f.call$1(t1.get$current()));
+        return true;
+      }
+      _this.set$_current(null);
+      return false;
+    },
+    get$current: function() {
+      var cur = this._current;
+      return cur;
+    },
+    set$_current: function(_current) {
+      this._current = this.$ti._eval$1("2?")._as(_current);
+    }
+  };
+  H.MappedListIterable.prototype = {
+    get$length: function(_) {
+      return J.get$length$asx(this.__internal$_source);
+    },
+    elementAt$1: function(_, index) {
+      return this._f.call$1(J.elementAt$1$ax(this.__internal$_source, index));
+    }
+  };
+  H.FixedLengthListMixin.prototype = {};
+  H.Symbol.prototype = {
+    get$hashCode: function(_) {
+      var hash = this._hashCode;
+      if (hash != null)
+        return hash;
+      hash = 536870911 & 664597 * J.get$hashCode$(this.__internal$_name);
+      this._hashCode = hash;
+      return hash;
+    },
+    toString$0: function(_) {
+      return 'Symbol("' + H.S(this.__internal$_name) + '")';
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof H.Symbol && this.__internal$_name == other.__internal$_name;
+    },
+    $isSymbol0: 1
+  };
+  H.ConstantMapView.prototype = {};
+  H.ConstantMap.prototype = {
+    get$isEmpty: function(_) {
+      return this.get$length(this) === 0;
+    },
+    toString$0: function(_) {
+      return P.MapBase_mapToString(this);
+    },
+    $indexSet: function(_, key, val) {
+      var t1 = H._instanceType(this);
+      t1._precomputed1._as(key);
+      t1._rest[1]._as(val);
+      H.ConstantMap__throwUnmodifiable();
+    },
+    map$2$1: function(_, transform, K2, V2) {
+      var result = P.LinkedHashMap_LinkedHashMap$_empty(K2, V2);
+      this.forEach$1(0, new H.ConstantMap_map_closure(this, H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform), result));
+      return result;
+    },
+    map$1: function($receiver, transform) {
+      return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic);
+    },
+    $isMap: 1
+  };
+  H.ConstantMap_map_closure.prototype = {
+    call$2: function(key, value) {
+      var t1 = H._instanceType(this.$this),
+        entry = this.transform.call$2(t1._precomputed1._as(key), t1._rest[1]._as(value));
+      this.result.$indexSet(0, C.JSNull_methods.get$key(entry), entry.get$value());
+    },
+    $signature: function() {
+      return H._instanceType(this.$this)._eval$1("Null(1,2)");
+    }
+  };
+  H.ConstantStringMap.prototype = {
+    get$length: function(_) {
+      return this._length;
+    },
+    containsKey$1: function(key) {
+      if (typeof key != "string")
+        return false;
+      if ("__proto__" === key)
+        return false;
+      return this._jsObject.hasOwnProperty(key);
+    },
+    $index: function(_, key) {
+      if (!this.containsKey$1(key))
+        return null;
+      return this._fetch$1(key);
+    },
+    _fetch$1: function(key) {
+      return this._jsObject[H._asStringS(key)];
+    },
+    forEach$1: function(_, f) {
+      var keys, t2, i, key,
+        t1 = H._instanceType(this);
+      t1._eval$1("~(1,2)")._as(f);
+      keys = this._keys;
+      for (t2 = keys.length, t1 = t1._rest[1], i = 0; i < t2; ++i) {
+        key = keys[i];
+        f.call$2(key, t1._as(this._fetch$1(key)));
+      }
+    },
+    get$keys: function() {
+      return new H._ConstantMapKeyIterable(this, H._instanceType(this)._eval$1("_ConstantMapKeyIterable<1>"));
+    }
+  };
+  H._ConstantMapKeyIterable.prototype = {
+    get$iterator: function(_) {
+      var t1 = this._map._keys;
+      return new J.ArrayIterator(t1, t1.length, H._arrayInstanceType(t1)._eval$1("ArrayIterator<1>"));
+    },
+    get$length: function(_) {
+      return this._map._keys.length;
+    }
+  };
+  H.JSInvocationMirror.prototype = {
+    get$memberName: function() {
+      var t1 = this._memberName;
+      return t1;
+    },
+    get$positionalArguments: function() {
+      var t1, argumentCount, list, index, _this = this;
+      if (_this.__js_helper$_kind === 1)
+        return C.List_empty;
+      t1 = _this._arguments;
+      argumentCount = t1.length - _this._namedArgumentNames.length - _this._typeArgumentCount;
+      if (argumentCount === 0)
+        return C.List_empty;
+      list = [];
+      for (index = 0; index < argumentCount; ++index) {
+        if (index >= t1.length)
+          return H.ioore(t1, index);
+        list.push(t1[index]);
+      }
+      list.fixed$length = Array;
+      list.immutable$list = Array;
+      return list;
+    },
+    get$namedArguments: function() {
+      var t1, namedArgumentCount, t2, namedArgumentsStartIndex, map, i, t3, t4, _this = this;
+      if (_this.__js_helper$_kind !== 0)
+        return C.Map_empty0;
+      t1 = _this._namedArgumentNames;
+      namedArgumentCount = t1.length;
+      t2 = _this._arguments;
+      namedArgumentsStartIndex = t2.length - namedArgumentCount - _this._typeArgumentCount;
+      if (namedArgumentCount === 0)
+        return C.Map_empty0;
+      map = new H.JsLinkedHashMap(type$.JsLinkedHashMap_Symbol_dynamic);
+      for (i = 0; i < namedArgumentCount; ++i) {
+        if (i >= t1.length)
+          return H.ioore(t1, i);
+        t3 = t1[i];
+        t4 = namedArgumentsStartIndex + i;
+        if (t4 < 0 || t4 >= t2.length)
+          return H.ioore(t2, t4);
+        map.$indexSet(0, new H.Symbol(t3), t2[t4]);
+      }
+      return new H.ConstantMapView(map, type$.ConstantMapView_Symbol_dynamic);
+    },
+    $isInvocation: 1
+  };
+  H.Primitives_functionNoSuchMethod_closure.prototype = {
+    call$2: function($name, argument) {
+      var t1;
+      H._asStringS($name);
+      t1 = this._box_0;
+      t1.names = t1.names + "$" + H.S($name);
+      C.JSArray_methods.add$1(this.namedArgumentList, $name);
+      C.JSArray_methods.add$1(this.$arguments, argument);
+      ++t1.argumentCount;
+    },
+    $signature: 44
+  };
+  H.TypeErrorDecoder.prototype = {
+    matchTypeError$1: function(message) {
+      var result, t1, _this = this,
+        match = new RegExp(_this._pattern).exec(message);
+      if (match == null)
+        return null;
+      result = Object.create(null);
+      t1 = _this._arguments;
+      if (t1 !== -1)
+        result.arguments = match[t1 + 1];
+      t1 = _this._argumentsExpr;
+      if (t1 !== -1)
+        result.argumentsExpr = match[t1 + 1];
+      t1 = _this._expr;
+      if (t1 !== -1)
+        result.expr = match[t1 + 1];
+      t1 = _this._method;
+      if (t1 !== -1)
+        result.method = match[t1 + 1];
+      t1 = _this._receiver;
+      if (t1 !== -1)
+        result.receiver = match[t1 + 1];
+      return result;
+    }
+  };
+  H.NullError.prototype = {
+    toString$0: function(_) {
+      var t1 = this._method;
+      if (t1 == null)
+        return "NoSuchMethodError: " + H.S(this._message);
+      return "NoSuchMethodError: method not found: '" + t1 + "' on null";
+    }
+  };
+  H.JsNoSuchMethodError.prototype = {
+    toString$0: function(_) {
+      var t2, _this = this,
+        _s38_ = "NoSuchMethodError: method not found: '",
+        t1 = _this._method;
+      if (t1 == null)
+        return "NoSuchMethodError: " + H.S(_this._message);
+      t2 = _this._receiver;
+      if (t2 == null)
+        return _s38_ + t1 + "' (" + H.S(_this._message) + ")";
+      return _s38_ + t1 + "' on '" + t2 + "' (" + H.S(_this._message) + ")";
+    }
+  };
+  H.UnknownJsTypeError.prototype = {
+    toString$0: function(_) {
+      var t1 = this._message;
+      return t1.length === 0 ? "Error" : "Error: " + t1;
+    }
+  };
+  H.NullThrownFromJavaScriptException.prototype = {
+    toString$0: function(_) {
+      return "Throw of null ('" + (this._irritant === null ? "null" : "undefined") + "' from JavaScript)";
+    }
+  };
+  H.ExceptionAndStackTrace.prototype = {};
+  H._StackTrace.prototype = {
+    toString$0: function(_) {
+      var trace,
+        t1 = this._trace;
+      if (t1 != null)
+        return t1;
+      t1 = this._exception;
+      trace = t1 !== null && typeof t1 === "object" ? t1.stack : null;
+      return this._trace = trace == null ? "" : trace;
+    },
+    $isStackTrace: 1
+  };
+  H.Closure.prototype = {
+    toString$0: function(_) {
+      var $constructor = this.constructor,
+        $name = $constructor == null ? null : $constructor.name;
+      return "Closure '" + H.unminifyOrTag($name == null ? "unknown" : $name) + "'";
+    },
+    $isFunction: 1,
+    get$$call: function() {
+      return this;
+    },
+    "call*": "call$1",
+    $requiredArgCount: 1,
+    $defaultValues: null
+  };
+  H.TearOffClosure.prototype = {};
+  H.StaticClosure.prototype = {
+    toString$0: function(_) {
+      var $name = this.$static_name;
+      if ($name == null)
+        return "Closure of unknown static method";
+      return "Closure '" + H.unminifyOrTag($name) + "'";
+    }
+  };
+  H.BoundClosure.prototype = {
+    $eq: function(_, other) {
+      var _this = this;
+      if (other == null)
+        return false;
+      if (_this === other)
+        return true;
+      if (!(other instanceof H.BoundClosure))
+        return false;
+      return _this._self === other._self && _this.__js_helper$_target === other.__js_helper$_target && _this._receiver === other._receiver;
+    },
+    get$hashCode: function(_) {
+      var receiverHashCode,
+        t1 = this._receiver;
+      if (t1 == null)
+        receiverHashCode = H.Primitives_objectHashCode(this._self);
+      else
+        receiverHashCode = typeof t1 !== "object" ? J.get$hashCode$(t1) : H.Primitives_objectHashCode(t1);
+      return (receiverHashCode ^ H.Primitives_objectHashCode(this.__js_helper$_target)) >>> 0;
+    },
+    toString$0: function(_) {
+      var receiver = this._receiver;
+      if (receiver == null)
+        receiver = this._self;
+      return "Closure '" + H.S(this._name) + "' of " + ("Instance of '" + H.S(H.Primitives_objectTypeName(receiver)) + "'");
+    }
+  };
+  H.RuntimeError.prototype = {
+    toString$0: function(_) {
+      return "RuntimeError: " + H.S(this.message);
+    }
+  };
+  H._AssertionError.prototype = {
+    toString$0: function(_) {
+      return "Assertion failed: " + P.Error_safeToString(this.message);
+    }
+  };
+  H._Required.prototype = {};
+  H.JsLinkedHashMap.prototype = {
+    get$length: function(_) {
+      return this._length;
+    },
+    get$isEmpty: function(_) {
+      return this._length === 0;
+    },
+    get$isNotEmpty: function(_) {
+      return !this.get$isEmpty(this);
+    },
+    get$keys: function() {
+      return new H.LinkedHashMapKeyIterable(this, H._instanceType(this)._eval$1("LinkedHashMapKeyIterable<1>"));
+    },
+    containsKey$1: function(key) {
+      var strings, t1;
+      if (typeof key == "string") {
+        strings = this._strings;
+        if (strings == null)
+          return false;
+        return this._containsTableEntry$2(strings, key);
+      } else {
+        t1 = this.internalContainsKey$1(key);
+        return t1;
+      }
+    },
+    internalContainsKey$1: function(key) {
+      var _this = this,
+        rest = _this.__js_helper$_rest;
+      if (rest == null)
+        return false;
+      return _this.internalFindBucketIndex$2(_this._getTableBucket$2(rest, _this.internalComputeHashCode$1(key)), key) >= 0;
+    },
+    addAll$1: function(_, other) {
+      H._instanceType(this)._eval$1("Map<1,2>")._as(other).forEach$1(0, new H.JsLinkedHashMap_addAll_closure(this));
+    },
+    $index: function(_, key) {
+      var strings, cell, t1, nums, _this = this, _null = null;
+      if (typeof key == "string") {
+        strings = _this._strings;
+        if (strings == null)
+          return _null;
+        cell = _this._getTableCell$2(strings, key);
+        t1 = cell == null ? _null : cell.hashMapCellValue;
+        return t1;
+      } else if (typeof key == "number" && (key & 0x3ffffff) === key) {
+        nums = _this._nums;
+        if (nums == null)
+          return _null;
+        cell = _this._getTableCell$2(nums, key);
+        t1 = cell == null ? _null : cell.hashMapCellValue;
+        return t1;
+      } else
+        return _this.internalGet$1(key);
+    },
+    internalGet$1: function(key) {
+      var bucket, index, _this = this,
+        rest = _this.__js_helper$_rest;
+      if (rest == null)
+        return null;
+      bucket = _this._getTableBucket$2(rest, _this.internalComputeHashCode$1(key));
+      index = _this.internalFindBucketIndex$2(bucket, key);
+      if (index < 0)
+        return null;
+      return bucket[index].hashMapCellValue;
+    },
+    $indexSet: function(_, key, value) {
+      var strings, nums, _this = this,
+        t1 = H._instanceType(_this);
+      t1._precomputed1._as(key);
+      t1._rest[1]._as(value);
+      if (typeof key == "string") {
+        strings = _this._strings;
+        _this._addHashTableEntry$3(strings == null ? _this._strings = _this._newHashTable$0() : strings, key, value);
+      } else if (typeof key == "number" && (key & 0x3ffffff) === key) {
+        nums = _this._nums;
+        _this._addHashTableEntry$3(nums == null ? _this._nums = _this._newHashTable$0() : nums, key, value);
+      } else
+        _this.internalSet$2(key, value);
+    },
+    internalSet$2: function(key, value) {
+      var rest, hash, bucket, index, _this = this,
+        t1 = H._instanceType(_this);
+      t1._precomputed1._as(key);
+      t1._rest[1]._as(value);
+      rest = _this.__js_helper$_rest;
+      if (rest == null)
+        rest = _this.__js_helper$_rest = _this._newHashTable$0();
+      hash = _this.internalComputeHashCode$1(key);
+      bucket = _this._getTableBucket$2(rest, hash);
+      if (bucket == null)
+        _this._setTableEntry$3(rest, hash, [_this._newLinkedCell$2(key, value)]);
+      else {
+        index = _this.internalFindBucketIndex$2(bucket, key);
+        if (index >= 0)
+          bucket[index].hashMapCellValue = value;
+        else
+          bucket.push(_this._newLinkedCell$2(key, value));
+      }
+    },
+    putIfAbsent$2: function(key, ifAbsent) {
+      var value, _this = this,
+        t1 = H._instanceType(_this);
+      t1._precomputed1._as(key);
+      t1._eval$1("2()")._as(ifAbsent);
+      if (_this.containsKey$1(key))
+        return _this.$index(0, key);
+      value = ifAbsent.call$0();
+      _this.$indexSet(0, key, value);
+      return value;
+    },
+    remove$1: function(_, key) {
+      var _this = this;
+      if (typeof key == "string")
+        return _this._removeHashTableEntry$2(_this._strings, key);
+      else if (typeof key == "number" && (key & 0x3ffffff) === key)
+        return _this._removeHashTableEntry$2(_this._nums, key);
+      else
+        return _this.internalRemove$1(key);
+    },
+    internalRemove$1: function(key) {
+      var hash, bucket, index, cell, _this = this,
+        rest = _this.__js_helper$_rest;
+      if (rest == null)
+        return null;
+      hash = _this.internalComputeHashCode$1(key);
+      bucket = _this._getTableBucket$2(rest, hash);
+      index = _this.internalFindBucketIndex$2(bucket, key);
+      if (index < 0)
+        return null;
+      cell = bucket.splice(index, 1)[0];
+      _this._unlinkCell$1(cell);
+      if (bucket.length === 0)
+        _this._deleteTableEntry$2(rest, hash);
+      return cell.hashMapCellValue;
+    },
+    forEach$1: function(_, action) {
+      var cell, modifications, _this = this;
+      H._instanceType(_this)._eval$1("~(1,2)")._as(action);
+      cell = _this._first;
+      modifications = _this._modifications;
+      for (; cell != null;) {
+        action.call$2(cell.hashMapCellKey, cell.hashMapCellValue);
+        if (modifications !== _this._modifications)
+          throw H.wrapException(P.ConcurrentModificationError$(_this));
+        cell = cell._next;
+      }
+    },
+    _addHashTableEntry$3: function(table, key, value) {
+      var cell, _this = this,
+        t1 = H._instanceType(_this);
+      t1._precomputed1._as(key);
+      t1._rest[1]._as(value);
+      cell = _this._getTableCell$2(table, key);
+      if (cell == null)
+        _this._setTableEntry$3(table, key, _this._newLinkedCell$2(key, value));
+      else
+        cell.hashMapCellValue = value;
+    },
+    _removeHashTableEntry$2: function(table, key) {
+      var cell;
+      if (table == null)
+        return null;
+      cell = this._getTableCell$2(table, key);
+      if (cell == null)
+        return null;
+      this._unlinkCell$1(cell);
+      this._deleteTableEntry$2(table, key);
+      return cell.hashMapCellValue;
+    },
+    _modified$0: function() {
+      this._modifications = this._modifications + 1 & 67108863;
+    },
+    _newLinkedCell$2: function(key, value) {
+      var _this = this,
+        t1 = H._instanceType(_this),
+        cell = new H.LinkedHashMapCell(t1._precomputed1._as(key), t1._rest[1]._as(value));
+      if (_this._first == null)
+        _this._first = _this._last = cell;
+      else {
+        t1 = _this._last;
+        t1.toString;
+        cell._previous = t1;
+        _this._last = t1._next = cell;
+      }
+      ++_this._length;
+      _this._modified$0();
+      return cell;
+    },
+    _unlinkCell$1: function(cell) {
+      var _this = this,
+        previous = cell._previous,
+        next = cell._next;
+      if (previous == null)
+        _this._first = next;
+      else
+        previous._next = next;
+      if (next == null)
+        _this._last = previous;
+      else
+        next._previous = previous;
+      --_this._length;
+      _this._modified$0();
+    },
+    internalComputeHashCode$1: function(key) {
+      return J.get$hashCode$(key) & 0x3ffffff;
+    },
+    internalFindBucketIndex$2: function(bucket, key) {
+      var $length, i;
+      if (bucket == null)
+        return -1;
+      $length = bucket.length;
+      for (i = 0; i < $length; ++i)
+        if (J.$eq$(bucket[i].hashMapCellKey, key))
+          return i;
+      return -1;
+    },
+    toString$0: function(_) {
+      return P.MapBase_mapToString(this);
+    },
+    _getTableCell$2: function(table, key) {
+      return table[key];
+    },
+    _getTableBucket$2: function(table, key) {
+      return table[key];
+    },
+    _setTableEntry$3: function(table, key, value) {
+      table[key] = value;
+    },
+    _deleteTableEntry$2: function(table, key) {
+      delete table[key];
+    },
+    _containsTableEntry$2: function(table, key) {
+      return this._getTableCell$2(table, key) != null;
+    },
+    _newHashTable$0: function() {
+      var _s20_ = "<non-identifier-key>",
+        table = Object.create(null);
+      this._setTableEntry$3(table, _s20_, table);
+      this._deleteTableEntry$2(table, _s20_);
+      return table;
+    },
+    $isLinkedHashMap: 1
+  };
+  H.JsLinkedHashMap_addAll_closure.prototype = {
+    call$2: function(key, value) {
+      var t1 = this.$this,
+        t2 = H._instanceType(t1);
+      t1.$indexSet(0, t2._precomputed1._as(key), t2._rest[1]._as(value));
+    },
+    $signature: function() {
+      return H._instanceType(this.$this)._eval$1("Null(1,2)");
+    }
+  };
+  H.LinkedHashMapCell.prototype = {};
+  H.LinkedHashMapKeyIterable.prototype = {
+    get$length: function(_) {
+      return this._map._length;
+    },
+    get$isEmpty: function(_) {
+      return this._map._length === 0;
+    },
+    get$iterator: function(_) {
+      var t1 = this._map,
+        t2 = new H.LinkedHashMapKeyIterator(t1, t1._modifications, this.$ti._eval$1("LinkedHashMapKeyIterator<1>"));
+      t2._cell = t1._first;
+      return t2;
+    },
+    contains$1: function(_, element) {
+      return this._map.containsKey$1(element);
+    }
+  };
+  H.LinkedHashMapKeyIterator.prototype = {
+    get$current: function() {
+      return this.__js_helper$_current;
+    },
+    moveNext$0: function() {
+      var cell, _this = this,
+        t1 = _this._map;
+      if (_this._modifications !== t1._modifications)
+        throw H.wrapException(P.ConcurrentModificationError$(t1));
+      cell = _this._cell;
+      if (cell == null) {
+        _this.set$__js_helper$_current(null);
+        return false;
+      } else {
+        _this.set$__js_helper$_current(cell.hashMapCellKey);
+        _this._cell = cell._next;
+        return true;
+      }
+    },
+    set$__js_helper$_current: function(_current) {
+      this.__js_helper$_current = this.$ti._eval$1("1?")._as(_current);
+    },
+    $isIterator: 1
+  };
+  H.initHooks_closure.prototype = {
+    call$1: function(o) {
+      return this.getTag(o);
+    },
+    $signature: 3
+  };
+  H.initHooks_closure0.prototype = {
+    call$2: function(o, tag) {
+      return this.getUnknownTag(o, tag);
+    },
+    $signature: 31
+  };
+  H.initHooks_closure1.prototype = {
+    call$1: function(tag) {
+      return this.prototypeForTag(H._asStringS(tag));
+    },
+    $signature: 41
+  };
+  H.NativeByteBuffer.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_ByteBuffer_RkP;
+    }
+  };
+  H.NativeTypedData.prototype = {};
+  H.NativeByteData.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_ByteData_zNC;
+    },
+    _getUint32$2: function(receiver, byteOffset, littleEndian) {
+      return receiver.getUint32(byteOffset, littleEndian);
+    },
+    $isByteData: 1
+  };
+  H.NativeTypedArray.prototype = {
+    get$length: function(receiver) {
+      return receiver.length;
+    },
+    $isJSIndexable: 1,
+    $isJavaScriptIndexingBehavior: 1
+  };
+  H.NativeTypedArrayOfDouble.prototype = {
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    },
+    $indexSet: function(receiver, index, value) {
+      H._asIntS(index);
+      H._asDoubleS(value);
+      H._checkValidIndex(index, receiver, receiver.length);
+      receiver[index] = value;
+    },
+    $isEfficientLengthIterable: 1,
+    $isIterable: 1,
+    $isList: 1
+  };
+  H.NativeTypedArrayOfInt.prototype = {
+    $indexSet: function(receiver, index, value) {
+      H._asIntS(index);
+      H._asIntS(value);
+      H._checkValidIndex(index, receiver, receiver.length);
+      receiver[index] = value;
+    },
+    $isEfficientLengthIterable: 1,
+    $isIterable: 1,
+    $isList: 1
+  };
+  H.NativeFloat32List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Float32List_LB7;
+    }
+  };
+  H.NativeFloat64List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Float64List_LB7;
+    }
+  };
+  H.NativeInt16List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Int16List_uXf;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeInt32List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Int32List_O50;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeInt8List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Int8List_ekJ;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeUint16List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Uint16List_2bx;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeUint32List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Uint32List_2bx;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeUint8ClampedList.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Uint8ClampedList_Jik;
+    },
+    get$length: function(receiver) {
+      return receiver.length;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    }
+  };
+  H.NativeUint8List.prototype = {
+    get$runtimeType: function(receiver) {
+      return C.Type_Uint8List_WLA;
+    },
+    get$length: function(receiver) {
+      return receiver.length;
+    },
+    $index: function(receiver, index) {
+      H._asIntS(index);
+      H._checkValidIndex(index, receiver, receiver.length);
+      return receiver[index];
+    },
+    $isUint8List: 1
+  };
+  H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.prototype = {};
+  H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {};
+  H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.prototype = {};
+  H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.prototype = {};
+  H.Rti.prototype = {
+    _eval$1: function(recipe) {
+      return H._Universe_evalInEnvironment(init.typeUniverse, this, recipe);
+    },
+    _bind$1: function(typeOrTuple) {
+      return H._Universe_bind(init.typeUniverse, this, typeOrTuple);
+    }
+  };
+  H._FunctionParameters.prototype = {};
+  H._Type.prototype = {
+    toString$0: function(_) {
+      return H._rtiToString(this._rti, null);
+    }
+  };
+  H._Error.prototype = {
+    toString$0: function(_) {
+      return this.__rti$_message;
+    }
+  };
+  H._TypeError.prototype = {};
+  P._AsyncRun__initializeScheduleImmediate_internalCallback.prototype = {
+    call$1: function(_) {
+      var t1 = this._box_0,
+        f = t1.storedCallback;
+      t1.storedCallback = null;
+      f.call$0();
+    },
+    $signature: 11
+  };
+  P._AsyncRun__initializeScheduleImmediate_closure.prototype = {
+    call$1: function(callback) {
+      var t1, t2;
+      this._box_0.storedCallback = type$.void_Function._as(callback);
+      t1 = this.div;
+      t2 = this.span;
+      t1.firstChild ? t1.removeChild(t2) : t1.appendChild(t2);
+    },
+    $signature: 33
+  };
+  P._AsyncRun__scheduleImmediateJsOverride_internalCallback.prototype = {
+    call$0: function() {
+      this.callback.call$0();
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 1
+  };
+  P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback.prototype = {
+    call$0: function() {
+      this.callback.call$0();
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 1
+  };
+  P._TimerImpl.prototype = {
+    _TimerImpl$2: function(milliseconds, callback) {
+      if (self.setTimeout != null)
+        this._handle = self.setTimeout(H.convertDartClosureToJS(new P._TimerImpl_internalCallback(this, callback), 0), milliseconds);
+      else
+        throw H.wrapException(P.UnsupportedError$("`setTimeout()` not found."));
+    },
+    cancel$0: function() {
+      if (self.setTimeout != null) {
+        var t1 = this._handle;
+        if (t1 == null)
+          return;
+        self.clearTimeout(t1);
+        this._handle = null;
+      } else
+        throw H.wrapException(P.UnsupportedError$("Canceling a timer."));
+    },
+    $isTimer: 1
+  };
+  P._TimerImpl_internalCallback.prototype = {
+    call$0: function() {
+      this.$this._handle = null;
+      this.callback.call$0();
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 0
+  };
+  P._AsyncAwaitCompleter.prototype = {
+    complete$1: function(value) {
+      var t2, _this = this,
+        t1 = _this.$ti;
+      t1._eval$1("1/?")._as(value);
+      if (!_this.isSync)
+        _this._future._asyncComplete$1(value);
+      else {
+        t2 = _this._future;
+        if (t1._eval$1("Future<1>")._is(value))
+          t2._chainFuture$1(value);
+        else
+          t2._completeWithValue$1(t1._precomputed1._as(value));
+      }
+    },
+    completeError$2: function(e, st) {
+      var t1;
+      if (st == null)
+        st = P.AsyncError_defaultStackTrace(e);
+      t1 = this._future;
+      if (this.isSync)
+        t1._completeError$2(e, st);
+      else
+        t1._asyncCompleteError$2(e, st);
+    },
+    completeError$1: function(e) {
+      return this.completeError$2(e, null);
+    },
+    $isCompleter: 1
+  };
+  P._awaitOnObject_closure.prototype = {
+    call$1: function(result) {
+      return this.bodyFunction.call$2(0, result);
+    },
+    $signature: 2
+  };
+  P._awaitOnObject_closure0.prototype = {
+    call$2: function(error, stackTrace) {
+      this.bodyFunction.call$2(1, new H.ExceptionAndStackTrace(error, type$.StackTrace._as(stackTrace)));
+    },
+    "call*": "call$2",
+    $requiredArgCount: 2,
+    $signature: 34
+  };
+  P._wrapJsFunctionForAsync_closure.prototype = {
+    call$2: function(errorCode, result) {
+      this.$protected(H._asIntS(errorCode), result);
+    },
+    $signature: 38
+  };
+  P._BroadcastSubscription.prototype = {
+    _onPause$0: function() {
+    },
+    _onResume$0: function() {
+    },
+    set$_async$_next: function(_next) {
+      this._async$_next = this.$ti._eval$1("_BroadcastSubscription<1>?")._as(_next);
+    },
+    set$_async$_previous: function(_previous) {
+      this._async$_previous = this.$ti._eval$1("_BroadcastSubscription<1>?")._as(_previous);
+    }
+  };
+  P._BroadcastStreamController.prototype = {
+    get$_mayAddEvent: function() {
+      return this._state < 4;
+    },
+    _removeListener$1: function(subscription) {
+      var previous, next;
+      H._instanceType(this)._eval$1("_BroadcastSubscription<1>")._as(subscription);
+      previous = subscription._async$_previous;
+      next = subscription._async$_next;
+      if (previous == null)
+        this.set$_firstSubscription(next);
+      else
+        previous.set$_async$_next(next);
+      if (next == null)
+        this.set$_lastSubscription(previous);
+      else
+        next.set$_async$_previous(previous);
+      subscription.set$_async$_previous(subscription);
+      subscription.set$_async$_next(subscription);
+    },
+    _subscribe$4: function(onData, onError, onDone, cancelOnError) {
+      var t2, t3, t4, t5, subscription, oldLast, _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("~(1)?")._as(onData);
+      type$.nullable_void_Function._as(onDone);
+      if ((_this._state & 4) !== 0) {
+        t1 = new P._DoneStreamSubscription($.Zone__current, onDone, t1._eval$1("_DoneStreamSubscription<1>"));
+        t1._schedule$0();
+        return t1;
+      }
+      t2 = $.Zone__current;
+      t3 = cancelOnError ? 1 : 0;
+      t4 = P._BufferingStreamSubscription__registerDataHandler(t2, onData, t1._precomputed1);
+      t5 = P._BufferingStreamSubscription__registerErrorHandler(t2, onError);
+      t1 = t1._eval$1("_BroadcastSubscription<1>");
+      subscription = new P._BroadcastSubscription(_this, t4, t5, type$.void_Function._as(onDone), t2, t3, t1);
+      subscription.set$_async$_previous(subscription);
+      subscription.set$_async$_next(subscription);
+      t1._as(subscription);
+      subscription._eventState = _this._state & 1;
+      oldLast = _this._lastSubscription;
+      _this.set$_lastSubscription(subscription);
+      subscription.set$_async$_next(null);
+      subscription.set$_async$_previous(oldLast);
+      if (oldLast == null)
+        _this.set$_firstSubscription(subscription);
+      else
+        oldLast.set$_async$_next(subscription);
+      if (_this._firstSubscription == _this._lastSubscription)
+        P._runGuarded(_this.onListen);
+      return subscription;
+    },
+    _recordCancel$1: function(sub) {
+      var _this = this,
+        t1 = H._instanceType(_this);
+      sub = t1._eval$1("_BroadcastSubscription<1>")._as(t1._eval$1("StreamSubscription<1>")._as(sub));
+      if (sub._async$_next === sub)
+        return null;
+      t1 = sub._eventState;
+      if ((t1 & 2) !== 0)
+        sub._eventState = t1 | 4;
+      else {
+        _this._removeListener$1(sub);
+        if ((_this._state & 2) === 0 && _this._firstSubscription == null)
+          _this._callOnCancel$0();
+      }
+      return null;
+    },
+    _recordPause$1: function(subscription) {
+      H._instanceType(this)._eval$1("StreamSubscription<1>")._as(subscription);
+    },
+    _recordResume$1: function(subscription) {
+      H._instanceType(this)._eval$1("StreamSubscription<1>")._as(subscription);
+    },
+    _addEventError$0: function() {
+      if ((this._state & 4) !== 0)
+        return new P.StateError("Cannot add new events after calling close");
+      return new P.StateError("Cannot add new events while doing an addStream");
+    },
+    add$1: function(_, data) {
+      var _this = this;
+      H._instanceType(_this)._precomputed1._as(data);
+      if (!_this.get$_mayAddEvent())
+        throw H.wrapException(_this._addEventError$0());
+      _this._sendData$1(data);
+    },
+    _forEachListener$1: function(action) {
+      var t1, subscription, id, next, _this = this;
+      H._instanceType(_this)._eval$1("~(_BufferingStreamSubscription<1>)")._as(action);
+      t1 = _this._state;
+      if ((t1 & 2) !== 0)
+        throw H.wrapException(P.StateError$("Cannot fire new event. Controller is already firing an event"));
+      subscription = _this._firstSubscription;
+      if (subscription == null)
+        return;
+      id = t1 & 1;
+      _this._state = t1 ^ 3;
+      for (; subscription != null;) {
+        t1 = subscription._eventState;
+        if ((t1 & 1) === id) {
+          subscription._eventState = t1 | 2;
+          action.call$1(subscription);
+          t1 = subscription._eventState ^= 1;
+          next = subscription._async$_next;
+          if ((t1 & 4) !== 0)
+            _this._removeListener$1(subscription);
+          subscription._eventState &= 4294967293;
+          subscription = next;
+        } else
+          subscription = subscription._async$_next;
+      }
+      _this._state &= 4294967293;
+      if (_this._firstSubscription == null)
+        _this._callOnCancel$0();
+    },
+    _callOnCancel$0: function() {
+      if ((this._state & 4) !== 0) {
+        var doneFuture = this._doneFuture;
+        if (doneFuture._state === 0)
+          doneFuture._asyncComplete$1(null);
+      }
+      P._runGuarded(this.onCancel);
+    },
+    set$_firstSubscription: function(_firstSubscription) {
+      this._firstSubscription = H._instanceType(this)._eval$1("_BroadcastSubscription<1>?")._as(_firstSubscription);
+    },
+    set$_lastSubscription: function(_lastSubscription) {
+      this._lastSubscription = H._instanceType(this)._eval$1("_BroadcastSubscription<1>?")._as(_lastSubscription);
+    },
+    $isStreamController: 1,
+    $is_StreamControllerLifecycle: 1,
+    $is_EventSink: 1,
+    $is_EventDispatch: 1
+  };
+  P._SyncBroadcastStreamController.prototype = {
+    get$_mayAddEvent: function() {
+      return P._BroadcastStreamController.prototype.get$_mayAddEvent.call(this) && (this._state & 2) === 0;
+    },
+    _addEventError$0: function() {
+      if ((this._state & 2) !== 0)
+        return new P.StateError("Cannot fire new event. Controller is already firing an event");
+      return this.super$_BroadcastStreamController$_addEventError();
+    },
+    _sendData$1: function(data) {
+      var t2, _this = this,
+        t1 = _this.$ti;
+      t1._precomputed1._as(data);
+      t2 = _this._firstSubscription;
+      if (t2 == null)
+        return;
+      if (t2 === _this._lastSubscription) {
+        _this._state |= 2;
+        t1._eval$1("_BroadcastSubscription<1>")._as(t2)._add$1(data);
+        _this._state &= 4294967293;
+        if (_this._firstSubscription == null)
+          _this._callOnCancel$0();
+        return;
+      }
+      _this._forEachListener$1(new P._SyncBroadcastStreamController__sendData_closure(_this, data));
+    }
+  };
+  P._SyncBroadcastStreamController__sendData_closure.prototype = {
+    call$1: function(subscription) {
+      this.$this.$ti._eval$1("_BufferingStreamSubscription<1>")._as(subscription)._add$1(this.data);
+    },
+    $signature: function() {
+      return this.$this.$ti._eval$1("Null(_BufferingStreamSubscription<1>)");
+    }
+  };
+  P._AsyncBroadcastStreamController.prototype = {
+    _sendData$1: function(data) {
+      var subscription,
+        t1 = this.$ti;
+      t1._precomputed1._as(data);
+      for (subscription = this._firstSubscription, t1 = t1._eval$1("_DelayedData<1>"); subscription != null; subscription = subscription._async$_next)
+        subscription._addPending$1(new P._DelayedData(data, t1));
+    }
+  };
+  P.Future.prototype = {};
+  P.Completer.prototype = {};
+  P._Completer.prototype = {
+    completeError$2: function(error, stackTrace) {
+      var t1;
+      P.ArgumentError_checkNotNull(error, "error", type$.Object);
+      t1 = this.future;
+      if (t1._state !== 0)
+        throw H.wrapException(P.StateError$("Future already completed"));
+      if (stackTrace == null)
+        stackTrace = P.AsyncError_defaultStackTrace(error);
+      t1._asyncCompleteError$2(error, stackTrace);
+    },
+    completeError$1: function(error) {
+      return this.completeError$2(error, null);
+    },
+    $isCompleter: 1
+  };
+  P._AsyncCompleter.prototype = {
+    complete$1: function(value) {
+      var t2,
+        t1 = this.$ti;
+      t1._eval$1("1/?")._as(value);
+      t2 = this.future;
+      if (t2._state !== 0)
+        throw H.wrapException(P.StateError$("Future already completed"));
+      t2._asyncComplete$1(t1._eval$1("1/")._as(value));
+    },
+    complete$0: function() {
+      return this.complete$1(null);
+    }
+  };
+  P._FutureListener.prototype = {
+    matchesErrorTest$1: function(asyncError) {
+      if ((this.state & 15) !== 6)
+        return true;
+      return this.result._zone.runUnary$2$2(type$.bool_Function_Object._as(this.callback), asyncError.error, type$.bool, type$.Object);
+    },
+    handleError$1: function(asyncError) {
+      var errorCallback = this.errorCallback,
+        t1 = type$.dynamic,
+        t2 = type$.Object,
+        t3 = this.$ti._eval$1("2/"),
+        t4 = this.result._zone;
+      if (type$.dynamic_Function_Object_StackTrace._is(errorCallback))
+        return t3._as(t4.runBinary$3$3(errorCallback, asyncError.error, asyncError.stackTrace, t1, t2, type$.StackTrace));
+      else
+        return t3._as(t4.runUnary$2$2(type$.dynamic_Function_Object._as(errorCallback), asyncError.error, t1, t2));
+    }
+  };
+  P._Future.prototype = {
+    then$1$2$onError: function(f, onError, $R) {
+      var currentZone, result, t2,
+        t1 = this.$ti;
+      t1._bind$1($R)._eval$1("1/(2)")._as(f);
+      currentZone = $.Zone__current;
+      if (currentZone !== C.C__RootZone) {
+        $R._eval$1("@<0/>")._bind$1(t1._precomputed1)._eval$1("1(2)")._as(f);
+        if (onError != null)
+          onError = P._registerErrorHandler(onError, currentZone);
+      }
+      result = new P._Future($.Zone__current, $R._eval$1("_Future<0>"));
+      t2 = onError == null ? 1 : 3;
+      this._addListener$1(new P._FutureListener(result, t2, f, onError, t1._eval$1("@<1>")._bind$1($R)._eval$1("_FutureListener<1,2>")));
+      return result;
+    },
+    then$1$1: function(f, $R) {
+      return this.then$1$2$onError(f, null, $R);
+    },
+    _thenAwait$1$2: function(f, onError, $E) {
+      var result,
+        t1 = this.$ti;
+      t1._bind$1($E)._eval$1("1/(2)")._as(f);
+      result = new P._Future($.Zone__current, $E._eval$1("_Future<0>"));
+      this._addListener$1(new P._FutureListener(result, 19, f, onError, t1._eval$1("@<1>")._bind$1($E)._eval$1("_FutureListener<1,2>")));
+      return result;
+    },
+    whenComplete$1: function(action) {
+      var t1, result;
+      type$.dynamic_Function._as(action);
+      t1 = this.$ti;
+      result = new P._Future($.Zone__current, t1);
+      this._addListener$1(new P._FutureListener(result, 8, action, null, t1._eval$1("@<1>")._bind$1(t1._precomputed1)._eval$1("_FutureListener<1,2>")));
+      return result;
+    },
+    _addListener$1: function(listener) {
+      var source, _this = this,
+        t1 = _this._state;
+      if (t1 <= 1) {
+        listener._nextListener = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners);
+        _this._resultOrListeners = listener;
+      } else {
+        if (t1 === 2) {
+          source = type$._Future_dynamic._as(_this._resultOrListeners);
+          t1 = source._state;
+          if (t1 < 4) {
+            source._addListener$1(listener);
+            return;
+          }
+          _this._state = t1;
+          _this._resultOrListeners = source._resultOrListeners;
+        }
+        P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__addListener_closure(_this, listener)));
+      }
+    },
+    _prependListeners$1: function(listeners) {
+      var t1, existingListeners, next, cursor, next0, source, _this = this, _box_0 = {};
+      _box_0.listeners = listeners;
+      if (listeners == null)
+        return;
+      t1 = _this._state;
+      if (t1 <= 1) {
+        existingListeners = type$.nullable__FutureListener_dynamic_dynamic._as(_this._resultOrListeners);
+        _this._resultOrListeners = listeners;
+        if (existingListeners != null) {
+          next = listeners._nextListener;
+          for (cursor = listeners; next != null; cursor = next, next = next0)
+            next0 = next._nextListener;
+          cursor._nextListener = existingListeners;
+        }
+      } else {
+        if (t1 === 2) {
+          source = type$._Future_dynamic._as(_this._resultOrListeners);
+          t1 = source._state;
+          if (t1 < 4) {
+            source._prependListeners$1(listeners);
+            return;
+          }
+          _this._state = t1;
+          _this._resultOrListeners = source._resultOrListeners;
+        }
+        _box_0.listeners = _this._reverseListeners$1(listeners);
+        P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__prependListeners_closure(_box_0, _this)));
+      }
+    },
+    _removeListeners$0: function() {
+      var current = type$.nullable__FutureListener_dynamic_dynamic._as(this._resultOrListeners);
+      this._resultOrListeners = null;
+      return this._reverseListeners$1(current);
+    },
+    _reverseListeners$1: function(listeners) {
+      var current, prev, next;
+      for (current = listeners, prev = null; current != null; prev = current, current = next) {
+        next = current._nextListener;
+        current._nextListener = prev;
+      }
+      return prev;
+    },
+    _complete$1: function(value) {
+      var listeners, _this = this,
+        t1 = _this.$ti;
+      t1._eval$1("1/")._as(value);
+      if (t1._eval$1("Future<1>")._is(value))
+        if (t1._is(value))
+          P._Future__chainCoreFuture(value, _this);
+        else
+          P._Future__chainForeignFuture(value, _this);
+      else {
+        listeners = _this._removeListeners$0();
+        t1._precomputed1._as(value);
+        _this._state = 4;
+        _this._resultOrListeners = value;
+        P._Future__propagateToListeners(_this, listeners);
+      }
+    },
+    _completeWithValue$1: function(value) {
+      var listeners, _this = this;
+      _this.$ti._precomputed1._as(value);
+      listeners = _this._removeListeners$0();
+      _this._state = 4;
+      _this._resultOrListeners = value;
+      P._Future__propagateToListeners(_this, listeners);
+    },
+    _completeError$2: function(error, stackTrace) {
+      var listeners, t1, _this = this;
+      type$.StackTrace._as(stackTrace);
+      listeners = _this._removeListeners$0();
+      t1 = P.AsyncError$(error, stackTrace);
+      _this._state = 8;
+      _this._resultOrListeners = t1;
+      P._Future__propagateToListeners(_this, listeners);
+    },
+    _asyncComplete$1: function(value) {
+      var t1 = this.$ti;
+      t1._eval$1("1/")._as(value);
+      if (t1._eval$1("Future<1>")._is(value)) {
+        this._chainFuture$1(value);
+        return;
+      }
+      this._asyncCompleteWithValue$1(t1._precomputed1._as(value));
+    },
+    _asyncCompleteWithValue$1: function(value) {
+      var _this = this;
+      _this.$ti._precomputed1._as(value);
+      _this._state = 1;
+      P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__asyncCompleteWithValue_closure(_this, value)));
+    },
+    _chainFuture$1: function(value) {
+      var _this = this,
+        t1 = _this.$ti;
+      t1._eval$1("Future<1>")._as(value);
+      if (t1._is(value)) {
+        if (value._state === 8) {
+          _this._state = 1;
+          P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(new P._Future__chainFuture_closure(_this, value)));
+        } else
+          P._Future__chainCoreFuture(value, _this);
+        return;
+      }
+      P._Future__chainForeignFuture(value, _this);
+    },
+    _asyncCompleteError$2: function(error, stackTrace) {
+      type$.StackTrace._as(stackTrace);
+      this._state = 1;
+      P._rootScheduleMicrotask(null, null, this._zone, type$.void_Function._as(new P._Future__asyncCompleteError_closure(this, error, stackTrace)));
+    },
+    $isFuture: 1
+  };
+  P._Future__addListener_closure.prototype = {
+    call$0: function() {
+      P._Future__propagateToListeners(this.$this, this.listener);
+    },
+    $signature: 1
+  };
+  P._Future__prependListeners_closure.prototype = {
+    call$0: function() {
+      P._Future__propagateToListeners(this.$this, this._box_0.listeners);
+    },
+    $signature: 1
+  };
+  P._Future__chainForeignFuture_closure.prototype = {
+    call$1: function(value) {
+      var t1 = this.target;
+      t1._state = 0;
+      t1._complete$1(value);
+    },
+    $signature: 11
+  };
+  P._Future__chainForeignFuture_closure0.prototype = {
+    call$2: function(error, stackTrace) {
+      type$.StackTrace._as(stackTrace);
+      this.target._completeError$2(error, stackTrace);
+    },
+    "call*": "call$2",
+    $requiredArgCount: 2,
+    $signature: 27
+  };
+  P._Future__chainForeignFuture_closure1.prototype = {
+    call$0: function() {
+      this.target._completeError$2(this.e, this.s);
+    },
+    $signature: 1
+  };
+  P._Future__asyncCompleteWithValue_closure.prototype = {
+    call$0: function() {
+      this.$this._completeWithValue$1(this.value);
+    },
+    $signature: 1
+  };
+  P._Future__chainFuture_closure.prototype = {
+    call$0: function() {
+      P._Future__chainCoreFuture(this.value, this.$this);
+    },
+    $signature: 1
+  };
+  P._Future__asyncCompleteError_closure.prototype = {
+    call$0: function() {
+      this.$this._completeError$2(this.error, this.stackTrace);
+    },
+    $signature: 1
+  };
+  P._Future__propagateToListeners_handleWhenCompleteCallback.prototype = {
+    call$0: function() {
+      var e, s, t1, exception, t2, originalSource, _this = this, completeResult = null;
+      try {
+        t1 = _this._box_0.listener;
+        completeResult = t1.result._zone.run$1$1(type$.dynamic_Function._as(t1.callback), type$.dynamic);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        if (_this.hasError) {
+          t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners).error;
+          t2 = e;
+          t2 = t1 == null ? t2 == null : t1 === t2;
+          t1 = t2;
+        } else
+          t1 = false;
+        t2 = _this._box_0;
+        if (t1)
+          t2.listenerValueOrError = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
+        else
+          t2.listenerValueOrError = P.AsyncError$(e, s);
+        t2.listenerHasError = true;
+        return;
+      }
+      if (completeResult instanceof P._Future && completeResult._state >= 4) {
+        if (completeResult._state === 8) {
+          t1 = _this._box_0;
+          t1.listenerValueOrError = type$.AsyncError._as(completeResult._resultOrListeners);
+          t1.listenerHasError = true;
+        }
+        return;
+      }
+      if (type$.Future_dynamic._is(completeResult)) {
+        originalSource = _this._box_1.source;
+        t1 = _this._box_0;
+        t1.listenerValueOrError = completeResult.then$1$1(new P._Future__propagateToListeners_handleWhenCompleteCallback_closure(originalSource), type$.dynamic);
+        t1.listenerHasError = false;
+      }
+    },
+    $signature: 0
+  };
+  P._Future__propagateToListeners_handleWhenCompleteCallback_closure.prototype = {
+    call$1: function(_) {
+      return this.originalSource;
+    },
+    $signature: 28
+  };
+  P._Future__propagateToListeners_handleValueCallback.prototype = {
+    call$0: function() {
+      var e, s, t1, t2, t3, t4, t5, exception;
+      try {
+        t1 = this._box_0;
+        t2 = t1.listener;
+        t3 = t2.$ti;
+        t4 = t3._precomputed1;
+        t5 = t4._as(this.sourceResult);
+        t1.listenerValueOrError = t2.result._zone.runUnary$2$2(t3._eval$1("2/(1)")._as(t2.callback), t5, t3._eval$1("2/"), t4);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        t1 = this._box_0;
+        t1.listenerValueOrError = P.AsyncError$(e, s);
+        t1.listenerHasError = true;
+      }
+    },
+    $signature: 0
+  };
+  P._Future__propagateToListeners_handleError.prototype = {
+    call$0: function() {
+      var asyncError, e, s, t1, exception, t2, t3, t4, _this = this;
+      try {
+        asyncError = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
+        t1 = _this._box_0;
+        if (H.boolConversionCheck(t1.listener.matchesErrorTest$1(asyncError)) && t1.listener.errorCallback != null) {
+          t1.listenerValueOrError = t1.listener.handleError$1(asyncError);
+          t1.listenerHasError = false;
+        }
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        t1 = type$.AsyncError._as(_this._box_1.source._resultOrListeners);
+        t2 = t1.error;
+        t3 = e;
+        t4 = _this._box_0;
+        if (t2 == null ? t3 == null : t2 === t3)
+          t4.listenerValueOrError = t1;
+        else
+          t4.listenerValueOrError = P.AsyncError$(e, s);
+        t4.listenerHasError = true;
+      }
+    },
+    $signature: 0
+  };
+  P._AsyncCallbackEntry.prototype = {};
+  P.Stream.prototype = {
+    map$1: function(_, convert) {
+      var t1 = H._instanceType(this);
+      return new P._MapStream(t1._eval$1("@(Stream.T)")._as(convert), this, t1._eval$1("_MapStream<Stream.T,@>"));
+    },
+    get$length: function(_) {
+      var t1 = {},
+        future = new P._Future($.Zone__current, type$._Future_int);
+      t1.count = 0;
+      this.listen$4$cancelOnError$onDone$onError(new P.Stream_length_closure(t1, this), true, new P.Stream_length_closure0(t1, future), future.get$_completeError());
+      return future;
+    },
+    get$first: function(_) {
+      var future = new P._Future($.Zone__current, H._instanceType(this)._eval$1("_Future<Stream.T>")),
+        subscription = this.listen$4$cancelOnError$onDone$onError(null, true, new P.Stream_first_closure(future), future.get$_completeError());
+      subscription.onData$1(new P.Stream_first_closure0(this, subscription, future));
+      return future;
+    }
+  };
+  P.Stream_length_closure.prototype = {
+    call$1: function(_) {
+      H._instanceType(this.$this)._eval$1("Stream.T")._as(_);
+      ++this._box_0.count;
+    },
+    $signature: function() {
+      return H._instanceType(this.$this)._eval$1("Null(Stream.T)");
+    }
+  };
+  P.Stream_length_closure0.prototype = {
+    call$0: function() {
+      this.future._complete$1(this._box_0.count);
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 1
+  };
+  P.Stream_first_closure.prototype = {
+    call$0: function() {
+      var e, s, t1, exception, error, stackTrace;
+      try {
+        t1 = H.IterableElementError_noElement();
+        throw H.wrapException(t1);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        error = e;
+        stackTrace = s;
+        if (stackTrace == null)
+          stackTrace = P.AsyncError_defaultStackTrace(error);
+        this.future._completeError$2(error, stackTrace);
+      }
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 1
+  };
+  P.Stream_first_closure0.prototype = {
+    call$1: function(value) {
+      P._cancelAndValue(this.subscription, this.future, H._instanceType(this.$this)._eval$1("Stream.T")._as(value));
+    },
+    $signature: function() {
+      return H._instanceType(this.$this)._eval$1("Null(Stream.T)");
+    }
+  };
+  P.StreamSubscription.prototype = {};
+  P.StreamTransformerBase.prototype = {};
+  P.StreamController.prototype = {};
+  P._StreamController.prototype = {
+    get$_pendingEvents: function() {
+      var t1, _this = this;
+      if ((_this._state & 8) === 0)
+        return H._instanceType(_this)._eval$1("_PendingEvents<1>?")._as(_this._varData);
+      t1 = H._instanceType(_this);
+      return t1._eval$1("_PendingEvents<1>?")._as(t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).get$varData());
+    },
+    _ensurePendingEvents$0: function() {
+      var events, t1, _this = this;
+      if ((_this._state & 8) === 0) {
+        events = _this._varData;
+        if (events == null)
+          events = _this._varData = new P._StreamImplEvents(H._instanceType(_this)._eval$1("_StreamImplEvents<1>"));
+        return H._instanceType(_this)._eval$1("_StreamImplEvents<1>")._as(events);
+      }
+      t1 = H._instanceType(_this);
+      events = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).get$varData();
+      return t1._eval$1("_StreamImplEvents<1>")._as(events);
+    },
+    get$_async$_subscription: function() {
+      var varData = this._varData;
+      if ((this._state & 8) !== 0)
+        varData = type$._StreamControllerAddStreamState_nullable_Object._as(varData).get$varData();
+      return H._instanceType(this)._eval$1("_ControllerSubscription<1>")._as(varData);
+    },
+    _badEventState$0: function() {
+      if ((this._state & 4) !== 0)
+        return new P.StateError("Cannot add event after closing");
+      return new P.StateError("Cannot add event while adding a stream");
+    },
+    _ensureDoneFuture$0: function() {
+      var t1 = this._doneFuture;
+      if (t1 == null)
+        t1 = this._doneFuture = (this._state & 2) !== 0 ? $.$get$Future__nullFuture() : new P._Future($.Zone__current, type$._Future_void);
+      return t1;
+    },
+    add$1: function(_, value) {
+      var t2, _this = this,
+        t1 = H._instanceType(_this);
+      t1._precomputed1._as(value);
+      t2 = _this._state;
+      if (t2 >= 4)
+        throw H.wrapException(_this._badEventState$0());
+      if ((t2 & 1) !== 0)
+        _this._sendData$1(value);
+      else if ((t2 & 3) === 0)
+        _this._ensurePendingEvents$0().add$1(0, new P._DelayedData(value, t1._eval$1("_DelayedData<1>")));
+    },
+    close$0: function(_) {
+      var _this = this,
+        t1 = _this._state;
+      if ((t1 & 4) !== 0)
+        return _this._ensureDoneFuture$0();
+      if (t1 >= 4)
+        throw H.wrapException(_this._badEventState$0());
+      t1 = _this._state = t1 | 4;
+      if ((t1 & 1) !== 0)
+        _this._sendDone$0();
+      else if ((t1 & 3) === 0)
+        _this._ensurePendingEvents$0().add$1(0, C.C__DelayedDone);
+      return _this._ensureDoneFuture$0();
+    },
+    _subscribe$4: function(onData, onError, onDone, cancelOnError) {
+      var t2, t3, subscription, pendingEvents, addState, _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("~(1)?")._as(onData);
+      type$.nullable_void_Function._as(onDone);
+      if ((_this._state & 3) !== 0)
+        throw H.wrapException(P.StateError$("Stream has already been listened to."));
+      t2 = $.Zone__current;
+      t3 = cancelOnError ? 1 : 0;
+      subscription = new P._ControllerSubscription(_this, P._BufferingStreamSubscription__registerDataHandler(t2, onData, t1._precomputed1), P._BufferingStreamSubscription__registerErrorHandler(t2, onError), P._BufferingStreamSubscription__registerDoneHandler(t2, onDone), t2, t3, t1._eval$1("_ControllerSubscription<1>"));
+      pendingEvents = _this.get$_pendingEvents();
+      t3 = _this._state |= 1;
+      if ((t3 & 8) !== 0) {
+        addState = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData);
+        addState.set$varData(subscription);
+        addState.resume$0();
+      } else
+        _this._varData = subscription;
+      subscription._setPendingEvents$1(pendingEvents);
+      subscription._guardCallback$1(new P._StreamController__subscribe_closure(_this));
+      return subscription;
+    },
+    _recordCancel$1: function(subscription) {
+      var result, onCancel, cancelResult, e, s, exception, result0, _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("StreamSubscription<1>")._as(subscription);
+      result = null;
+      if ((_this._state & 8) !== 0)
+        result = t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).cancel$0();
+      _this._varData = null;
+      _this._state = _this._state & 4294967286 | 2;
+      onCancel = _this.onCancel;
+      if (onCancel != null)
+        if (result == null)
+          try {
+            cancelResult = onCancel.call$0();
+            if (type$.Future_void._is(cancelResult))
+              result = cancelResult;
+          } catch (exception) {
+            e = H.unwrapException(exception);
+            s = H.getTraceFromException(exception);
+            result0 = new P._Future($.Zone__current, type$._Future_void);
+            result0._asyncCompleteError$2(e, s);
+            result = result0;
+          }
+        else
+          result = result.whenComplete$1(onCancel);
+      t1 = new P._StreamController__recordCancel_complete(_this);
+      if (result != null)
+        result = result.whenComplete$1(t1);
+      else
+        t1.call$0();
+      return result;
+    },
+    _recordPause$1: function(subscription) {
+      var _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("StreamSubscription<1>")._as(subscription);
+      if ((_this._state & 8) !== 0)
+        t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).pause$0();
+      P._runGuarded(_this.onPause);
+    },
+    _recordResume$1: function(subscription) {
+      var _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("StreamSubscription<1>")._as(subscription);
+      if ((_this._state & 8) !== 0)
+        t1._eval$1("_StreamControllerAddStreamState<1>")._as(_this._varData).resume$0();
+      P._runGuarded(_this.onResume);
+    },
+    $isStreamController: 1,
+    $is_StreamControllerLifecycle: 1,
+    $is_EventSink: 1,
+    $is_EventDispatch: 1
+  };
+  P._StreamController__subscribe_closure.prototype = {
+    call$0: function() {
+      P._runGuarded(this.$this.onListen);
+    },
+    $signature: 1
+  };
+  P._StreamController__recordCancel_complete.prototype = {
+    call$0: function() {
+      var doneFuture = this.$this._doneFuture;
+      if (doneFuture != null && doneFuture._state === 0)
+        doneFuture._asyncComplete$1(null);
+    },
+    $signature: 0
+  };
+  P._AsyncStreamControllerDispatch.prototype = {
+    _sendData$1: function(data) {
+      var t1 = this.$ti;
+      t1._precomputed1._as(data);
+      this.get$_async$_subscription()._addPending$1(new P._DelayedData(data, t1._eval$1("_DelayedData<1>")));
+    },
+    _sendError$2: function(error, stackTrace) {
+      this.get$_async$_subscription()._addPending$1(new P._DelayedError(error, stackTrace));
+    },
+    _sendDone$0: function() {
+      this.get$_async$_subscription()._addPending$1(C.C__DelayedDone);
+    }
+  };
+  P._AsyncStreamController.prototype = {};
+  P._ControllerStream.prototype = {
+    get$hashCode: function(_) {
+      return (H.Primitives_objectHashCode(this._controller) ^ 892482866) >>> 0;
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      if (this === other)
+        return true;
+      return other instanceof P._ControllerStream && other._controller === this._controller;
+    }
+  };
+  P._ControllerSubscription.prototype = {
+    _onCancel$0: function() {
+      return this._controller._recordCancel$1(this);
+    },
+    _onPause$0: function() {
+      this._controller._recordPause$1(this);
+    },
+    _onResume$0: function() {
+      this._controller._recordResume$1(this);
+    }
+  };
+  P._StreamSinkWrapper.prototype = {};
+  P._BufferingStreamSubscription.prototype = {
+    _setPendingEvents$1: function(pendingEvents) {
+      var _this = this;
+      H._instanceType(_this)._eval$1("_PendingEvents<_BufferingStreamSubscription.T>?")._as(pendingEvents);
+      if (pendingEvents == null)
+        return;
+      _this.set$_pending(pendingEvents);
+      if (pendingEvents.lastPendingEvent != null) {
+        _this._state = (_this._state | 64) >>> 0;
+        pendingEvents.schedule$1(_this);
+      }
+    },
+    onData$1: function(handleData) {
+      var t1 = H._instanceType(this);
+      this.set$_async$_onData(P._BufferingStreamSubscription__registerDataHandler(this._zone, t1._eval$1("~(_BufferingStreamSubscription.T)?")._as(handleData), t1._eval$1("_BufferingStreamSubscription.T")));
+    },
+    pause$0: function() {
+      var t2, t3, _this = this,
+        t1 = _this._state;
+      if ((t1 & 8) !== 0)
+        return;
+      t2 = (t1 + 128 | 4) >>> 0;
+      _this._state = t2;
+      if (t1 < 128) {
+        t3 = _this._pending;
+        if (t3 != null)
+          if (t3._state === 1)
+            t3._state = 3;
+      }
+      if ((t1 & 4) === 0 && (t2 & 32) === 0)
+        _this._guardCallback$1(_this.get$_onPause());
+    },
+    resume$0: function() {
+      var _this = this,
+        t1 = _this._state;
+      if ((t1 & 8) !== 0)
+        return;
+      if (t1 >= 128) {
+        t1 = _this._state = t1 - 128;
+        if (t1 < 128)
+          if ((t1 & 64) !== 0 && _this._pending.lastPendingEvent != null)
+            _this._pending.schedule$1(_this);
+          else {
+            t1 = (t1 & 4294967291) >>> 0;
+            _this._state = t1;
+            if ((t1 & 32) === 0)
+              _this._guardCallback$1(_this.get$_onResume());
+          }
+      }
+    },
+    cancel$0: function() {
+      var _this = this,
+        t1 = (_this._state & 4294967279) >>> 0;
+      _this._state = t1;
+      if ((t1 & 8) === 0)
+        _this._cancel$0();
+      t1 = _this._cancelFuture;
+      return t1 == null ? $.$get$Future__nullFuture() : t1;
+    },
+    _cancel$0: function() {
+      var t2, _this = this,
+        t1 = _this._state = (_this._state | 8) >>> 0;
+      if ((t1 & 64) !== 0) {
+        t2 = _this._pending;
+        if (t2._state === 1)
+          t2._state = 3;
+      }
+      if ((t1 & 32) === 0)
+        _this.set$_pending(null);
+      _this._cancelFuture = _this._onCancel$0();
+    },
+    _add$1: function(data) {
+      var t2, _this = this,
+        t1 = H._instanceType(_this);
+      t1._eval$1("_BufferingStreamSubscription.T")._as(data);
+      t2 = _this._state;
+      if ((t2 & 8) !== 0)
+        return;
+      if (t2 < 32)
+        _this._sendData$1(data);
+      else
+        _this._addPending$1(new P._DelayedData(data, t1._eval$1("_DelayedData<_BufferingStreamSubscription.T>")));
+    },
+    _addError$2: function(error, stackTrace) {
+      var t1 = this._state;
+      if ((t1 & 8) !== 0)
+        return;
+      if (t1 < 32)
+        this._sendError$2(error, stackTrace);
+      else
+        this._addPending$1(new P._DelayedError(error, stackTrace));
+    },
+    _close$0: function() {
+      var _this = this,
+        t1 = _this._state;
+      if ((t1 & 8) !== 0)
+        return;
+      t1 = (t1 | 2) >>> 0;
+      _this._state = t1;
+      if (t1 < 32)
+        _this._sendDone$0();
+      else
+        _this._addPending$1(C.C__DelayedDone);
+    },
+    _onPause$0: function() {
+    },
+    _onResume$0: function() {
+    },
+    _onCancel$0: function() {
+      return null;
+    },
+    _addPending$1: function($event) {
+      var _this = this,
+        t1 = H._instanceType(_this),
+        pending = t1._eval$1("_StreamImplEvents<_BufferingStreamSubscription.T>?")._as(_this._pending);
+      if (pending == null)
+        pending = new P._StreamImplEvents(t1._eval$1("_StreamImplEvents<_BufferingStreamSubscription.T>"));
+      _this.set$_pending(pending);
+      pending.add$1(0, $event);
+      t1 = _this._state;
+      if ((t1 & 64) === 0) {
+        t1 = (t1 | 64) >>> 0;
+        _this._state = t1;
+        if (t1 < 128)
+          pending.schedule$1(_this);
+      }
+    },
+    _sendData$1: function(data) {
+      var t2, _this = this,
+        t1 = H._instanceType(_this)._eval$1("_BufferingStreamSubscription.T");
+      t1._as(data);
+      t2 = _this._state;
+      _this._state = (t2 | 32) >>> 0;
+      _this._zone.runUnaryGuarded$1$2(_this._async$_onData, data, t1);
+      _this._state = (_this._state & 4294967263) >>> 0;
+      _this._checkState$1((t2 & 4) !== 0);
+    },
+    _sendError$2: function(error, stackTrace) {
+      var cancelFuture, _this = this,
+        t1 = _this._state,
+        t2 = new P._BufferingStreamSubscription__sendError_sendError(_this, error, stackTrace);
+      if ((t1 & 1) !== 0) {
+        _this._state = (t1 | 16) >>> 0;
+        _this._cancel$0();
+        cancelFuture = _this._cancelFuture;
+        if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture())
+          cancelFuture.whenComplete$1(t2);
+        else
+          t2.call$0();
+      } else {
+        t2.call$0();
+        _this._checkState$1((t1 & 4) !== 0);
+      }
+    },
+    _sendDone$0: function() {
+      var cancelFuture, _this = this,
+        t1 = new P._BufferingStreamSubscription__sendDone_sendDone(_this);
+      _this._cancel$0();
+      _this._state = (_this._state | 16) >>> 0;
+      cancelFuture = _this._cancelFuture;
+      if (cancelFuture != null && cancelFuture !== $.$get$Future__nullFuture())
+        cancelFuture.whenComplete$1(t1);
+      else
+        t1.call$0();
+    },
+    _guardCallback$1: function(callback) {
+      var t1, _this = this;
+      type$.void_Function._as(callback);
+      t1 = _this._state;
+      _this._state = (t1 | 32) >>> 0;
+      callback.call$0();
+      _this._state = (_this._state & 4294967263) >>> 0;
+      _this._checkState$1((t1 & 4) !== 0);
+    },
+    _checkState$1: function(wasInputPaused) {
+      var t2, isInputPaused, _this = this,
+        t1 = _this._state;
+      if ((t1 & 64) !== 0 && _this._pending.lastPendingEvent == null) {
+        t1 = _this._state = (t1 & 4294967231) >>> 0;
+        if ((t1 & 4) !== 0)
+          if (t1 < 128) {
+            t2 = _this._pending;
+            t2 = t2 == null ? null : t2.lastPendingEvent == null;
+            t2 = t2 !== false;
+          } else
+            t2 = false;
+        else
+          t2 = false;
+        if (t2) {
+          t1 = (t1 & 4294967291) >>> 0;
+          _this._state = t1;
+        }
+      }
+      for (; true; wasInputPaused = isInputPaused) {
+        if ((t1 & 8) !== 0) {
+          _this.set$_pending(null);
+          return;
+        }
+        isInputPaused = (t1 & 4) !== 0;
+        if (wasInputPaused === isInputPaused)
+          break;
+        _this._state = (t1 ^ 32) >>> 0;
+        if (isInputPaused)
+          _this._onPause$0();
+        else
+          _this._onResume$0();
+        t1 = (_this._state & 4294967263) >>> 0;
+        _this._state = t1;
+      }
+      if ((t1 & 64) !== 0 && t1 < 128)
+        _this._pending.schedule$1(_this);
+    },
+    set$_async$_onData: function(_onData) {
+      this._async$_onData = H._instanceType(this)._eval$1("~(_BufferingStreamSubscription.T)")._as(_onData);
+    },
+    set$_pending: function(_pending) {
+      this._pending = H._instanceType(this)._eval$1("_PendingEvents<_BufferingStreamSubscription.T>?")._as(_pending);
+    },
+    $isStreamSubscription: 1,
+    $is_EventSink: 1,
+    $is_EventDispatch: 1
+  };
+  P._BufferingStreamSubscription__sendError_sendError.prototype = {
+    call$0: function() {
+      var onError, t3, t4,
+        t1 = this.$this,
+        t2 = t1._state;
+      if ((t2 & 8) !== 0 && (t2 & 16) === 0)
+        return;
+      t1._state = (t2 | 32) >>> 0;
+      onError = t1._onError;
+      t2 = this.error;
+      t3 = type$.Object;
+      t4 = t1._zone;
+      if (type$.void_Function_Object_StackTrace._is(onError))
+        t4.runBinaryGuarded$2$3(onError, t2, this.stackTrace, t3, type$.StackTrace);
+      else
+        t4.runUnaryGuarded$1$2(type$.void_Function_Object._as(onError), t2, t3);
+      t1._state = (t1._state & 4294967263) >>> 0;
+    },
+    $signature: 0
+  };
+  P._BufferingStreamSubscription__sendDone_sendDone.prototype = {
+    call$0: function() {
+      var t1 = this.$this,
+        t2 = t1._state;
+      if ((t2 & 16) === 0)
+        return;
+      t1._state = (t2 | 42) >>> 0;
+      t1._zone.runGuarded$1(t1._onDone);
+      t1._state = (t1._state & 4294967263) >>> 0;
+    },
+    $signature: 0
+  };
+  P._StreamImpl.prototype = {
+    listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) {
+      var t1 = H._instanceType(this);
+      t1._eval$1("~(1)?")._as(onData);
+      type$.nullable_void_Function._as(onDone);
+      return this._controller._subscribe$4(t1._eval$1("~(1)?")._as(onData), onError, onDone, cancelOnError === true);
+    },
+    listen$2$onDone: function(onData, onDone) {
+      return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, null);
+    },
+    listen$3$onDone$onError: function(onData, onDone, onError) {
+      return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError);
+    }
+  };
+  P._DelayedEvent.prototype = {
+    set$next: function(next) {
+      this.next = type$.nullable__DelayedEvent_dynamic._as(next);
+    },
+    get$next: function() {
+      return this.next;
+    }
+  };
+  P._DelayedData.prototype = {
+    perform$1: function(dispatch) {
+      this.$ti._eval$1("_EventDispatch<1>")._as(dispatch)._sendData$1(this.value);
+    }
+  };
+  P._DelayedError.prototype = {
+    perform$1: function(dispatch) {
+      dispatch._sendError$2(this.error, this.stackTrace);
+    }
+  };
+  P._DelayedDone.prototype = {
+    perform$1: function(dispatch) {
+      dispatch._sendDone$0();
+    },
+    get$next: function() {
+      return null;
+    },
+    set$next: function(_) {
+      throw H.wrapException(P.StateError$("No events after a done."));
+    },
+    $is_DelayedEvent: 1
+  };
+  P._PendingEvents.prototype = {
+    schedule$1: function(dispatch) {
+      var t1, _this = this;
+      _this.$ti._eval$1("_EventDispatch<1>")._as(dispatch);
+      t1 = _this._state;
+      if (t1 === 1)
+        return;
+      if (t1 >= 1) {
+        _this._state = 1;
+        return;
+      }
+      P.scheduleMicrotask(new P._PendingEvents_schedule_closure(_this, dispatch));
+      _this._state = 1;
+    }
+  };
+  P._PendingEvents_schedule_closure.prototype = {
+    call$0: function() {
+      var t2, $event, nextEvent,
+        t1 = this.$this,
+        oldState = t1._state;
+      t1._state = 0;
+      if (oldState === 3)
+        return;
+      t2 = t1.$ti._eval$1("_EventDispatch<1>")._as(this.dispatch);
+      $event = t1.firstPendingEvent;
+      nextEvent = $event.get$next();
+      t1.firstPendingEvent = nextEvent;
+      if (nextEvent == null)
+        t1.lastPendingEvent = null;
+      $event.perform$1(t2);
+    },
+    $signature: 1
+  };
+  P._StreamImplEvents.prototype = {
+    add$1: function(_, $event) {
+      var _this = this,
+        lastEvent = _this.lastPendingEvent;
+      if (lastEvent == null)
+        _this.firstPendingEvent = _this.lastPendingEvent = $event;
+      else {
+        lastEvent.set$next($event);
+        _this.lastPendingEvent = $event;
+      }
+    }
+  };
+  P._DoneStreamSubscription.prototype = {
+    _schedule$0: function() {
+      var _this = this;
+      if ((_this._state & 2) !== 0)
+        return;
+      P._rootScheduleMicrotask(null, null, _this._zone, type$.void_Function._as(_this.get$_sendDone()));
+      _this._state = (_this._state | 2) >>> 0;
+    },
+    onData$1: function(handleData) {
+      this.$ti._eval$1("~(1)?")._as(handleData);
+    },
+    pause$0: function() {
+      this._state += 4;
+    },
+    resume$0: function() {
+      var t1 = this._state;
+      if (t1 >= 4) {
+        t1 = this._state = t1 - 4;
+        if (t1 < 4 && (t1 & 1) === 0)
+          this._schedule$0();
+      }
+    },
+    cancel$0: function() {
+      return $.$get$Future__nullFuture();
+    },
+    _sendDone$0: function() {
+      var _this = this,
+        t1 = _this._state = (_this._state & 4294967293) >>> 0;
+      if (t1 >= 4)
+        return;
+      _this._state = (t1 | 1) >>> 0;
+      _this._zone.runGuarded$1(_this._onDone);
+    },
+    $isStreamSubscription: 1
+  };
+  P._StreamIterator.prototype = {
+    get$current: function() {
+      var _this = this;
+      if (_this._async$_subscription != null && _this._isPaused)
+        return _this.$ti._precomputed1._as(_this._stateData);
+      return _this.$ti._precomputed1._as(null);
+    },
+    moveNext$0: function() {
+      var future, _this = this,
+        subscription = _this._async$_subscription;
+      if (subscription != null) {
+        if (_this._isPaused) {
+          future = new P._Future($.Zone__current, type$._Future_bool);
+          _this._stateData = future;
+          _this._isPaused = false;
+          subscription.resume$0();
+          return future;
+        }
+        throw H.wrapException(P.StateError$("Already waiting for next."));
+      }
+      return _this._initializeOrDone$0();
+    },
+    _initializeOrDone$0: function() {
+      var _this = this,
+        stateData = _this._stateData;
+      if (stateData != null) {
+        _this.set$_async$_subscription(_this.$ti._eval$1("Stream<1>")._as(stateData).listen$4$cancelOnError$onDone$onError(_this.get$_async$_onData(), true, _this.get$_onDone(), _this.get$_onError()));
+        return _this._stateData = new P._Future($.Zone__current, type$._Future_bool);
+      }
+      return $.$get$Future__falseFuture();
+    },
+    cancel$0: function() {
+      var _this = this,
+        subscription = _this._async$_subscription,
+        stateData = _this._stateData;
+      _this._stateData = null;
+      if (subscription != null) {
+        _this.set$_async$_subscription(null);
+        if (!_this._isPaused)
+          type$._Future_bool._as(stateData)._asyncComplete$1(false);
+        return subscription.cancel$0();
+      }
+      return $.$get$Future__nullFuture();
+    },
+    _async$_onData$1: function(data) {
+      var moveNextFuture, t1, _this = this;
+      _this.$ti._precomputed1._as(data);
+      moveNextFuture = type$._Future_bool._as(_this._stateData);
+      _this._stateData = data;
+      _this._isPaused = true;
+      moveNextFuture._complete$1(true);
+      if (_this._isPaused) {
+        t1 = _this._async$_subscription;
+        if (t1 != null)
+          t1.pause$0();
+      }
+    },
+    _onError$2: function(error, stackTrace) {
+      var moveNextFuture;
+      type$.StackTrace._as(stackTrace);
+      moveNextFuture = type$._Future_bool._as(this._stateData);
+      this.set$_async$_subscription(null);
+      this._stateData = null;
+      moveNextFuture._completeError$2(error, stackTrace);
+    },
+    _onDone$0: function() {
+      var moveNextFuture = type$._Future_bool._as(this._stateData);
+      this.set$_async$_subscription(null);
+      this._stateData = null;
+      moveNextFuture._complete$1(false);
+    },
+    set$_async$_subscription: function(_subscription) {
+      this._async$_subscription = this.$ti._eval$1("StreamSubscription<1>?")._as(_subscription);
+    }
+  };
+  P._cancelAndValue_closure.prototype = {
+    call$0: function() {
+      return this.future._complete$1(this.value);
+    },
+    $signature: 0
+  };
+  P._ForwardingStream.prototype = {
+    listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) {
+      var t2, t3, t4, t5, t6,
+        t1 = this.$ti;
+      t1._eval$1("~(2)?")._as(onData);
+      type$.nullable_void_Function._as(onDone);
+      t2 = t1._rest[1];
+      t3 = $.Zone__current;
+      t4 = cancelOnError === true ? 1 : 0;
+      t5 = P._BufferingStreamSubscription__registerDataHandler(t3, onData, t2);
+      t6 = P._BufferingStreamSubscription__registerErrorHandler(t3, onError);
+      t1 = new P._ForwardingStreamSubscription(this, t5, t6, type$.void_Function._as(onDone), t3, t4, t1._eval$1("@<1>")._bind$1(t2)._eval$1("_ForwardingStreamSubscription<1,2>"));
+      t1.set$_async$_subscription(this._async$_source.listen$3$onDone$onError(t1.get$_handleData(), t1.get$_handleDone(), t1.get$_handleError()));
+      return t1;
+    },
+    listen$3$onDone$onError: function(onData, onDone, onError) {
+      return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError);
+    }
+  };
+  P._ForwardingStreamSubscription.prototype = {
+    _add$1: function(data) {
+      this.$ti._rest[1]._as(data);
+      if ((this._state & 2) !== 0)
+        return;
+      this.super$_BufferingStreamSubscription$_add(data);
+    },
+    _addError$2: function(error, stackTrace) {
+      if ((this._state & 2) !== 0)
+        return;
+      this.super$_BufferingStreamSubscription$_addError(error, stackTrace);
+    },
+    _onPause$0: function() {
+      var t1 = this._async$_subscription;
+      if (t1 != null)
+        t1.pause$0();
+    },
+    _onResume$0: function() {
+      var t1 = this._async$_subscription;
+      if (t1 != null)
+        t1.resume$0();
+    },
+    _onCancel$0: function() {
+      var subscription = this._async$_subscription;
+      if (subscription != null) {
+        this.set$_async$_subscription(null);
+        return subscription.cancel$0();
+      }
+      return null;
+    },
+    _handleData$1: function(data) {
+      this._stream._handleData$2(this.$ti._precomputed1._as(data), this);
+    },
+    _handleError$2: function(error, stackTrace) {
+      type$.StackTrace._as(stackTrace);
+      this._stream.$ti._eval$1("_EventSink<2>")._as(this)._addError$2(error, stackTrace);
+    },
+    _handleDone$0: function() {
+      this._stream.$ti._eval$1("_EventSink<2>")._as(this)._close$0();
+    },
+    set$_async$_subscription: function(_subscription) {
+      this._async$_subscription = this.$ti._eval$1("StreamSubscription<1>?")._as(_subscription);
+    }
+  };
+  P._MapStream.prototype = {
+    _handleData$2: function(inputEvent, sink) {
+      var outputEvent, e, s, exception,
+        t1 = this.$ti;
+      t1._precomputed1._as(inputEvent);
+      t1._eval$1("_EventSink<2>")._as(sink);
+      outputEvent = null;
+      try {
+        outputEvent = this._transform.call$1(inputEvent);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        sink._addError$2(e, s);
+        return;
+      }
+      sink._add$1(outputEvent);
+    }
+  };
+  P.AsyncError.prototype = {
+    toString$0: function(_) {
+      return H.S(this.error);
+    },
+    $isError0: 1,
+    get$stackTrace: function() {
+      return this.stackTrace;
+    }
+  };
+  P._Zone.prototype = {$isZone: 1};
+  P._rootHandleUncaughtError_closure.prototype = {
+    call$0: function() {
+      var error = H.wrapException(this.error);
+      error.stack = J.toString$0$(this.stackTrace);
+      throw error;
+    },
+    $signature: 1
+  };
+  P._RootZone.prototype = {
+    runGuarded$1: function(f) {
+      var e, s, exception, _null = null;
+      type$.void_Function._as(f);
+      try {
+        if (C.C__RootZone === $.Zone__current) {
+          f.call$0();
+          return;
+        }
+        P._rootRun(_null, _null, this, f, type$.void);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s));
+      }
+    },
+    runUnaryGuarded$1$2: function(f, arg, $T) {
+      var e, s, exception, _null = null;
+      $T._eval$1("~(0)")._as(f);
+      $T._as(arg);
+      try {
+        if (C.C__RootZone === $.Zone__current) {
+          f.call$1(arg);
+          return;
+        }
+        P._rootRunUnary(_null, _null, this, f, arg, type$.void, $T);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s));
+      }
+    },
+    runBinaryGuarded$2$3: function(f, arg1, arg2, T1, T2) {
+      var e, s, exception, _null = null;
+      T1._eval$1("@<0>")._bind$1(T2)._eval$1("~(1,2)")._as(f);
+      T1._as(arg1);
+      T2._as(arg2);
+      try {
+        if (C.C__RootZone === $.Zone__current) {
+          f.call$2(arg1, arg2);
+          return;
+        }
+        P._rootRunBinary(_null, _null, this, f, arg1, arg2, type$.void, T1, T2);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        P._rootHandleUncaughtError(_null, _null, this, e, type$.StackTrace._as(s));
+      }
+    },
+    bindCallback$1$1: function(f, $R) {
+      return new P._RootZone_bindCallback_closure(this, $R._eval$1("0()")._as(f), $R);
+    },
+    bindCallbackGuarded$1: function(f) {
+      return new P._RootZone_bindCallbackGuarded_closure(this, type$.void_Function._as(f));
+    },
+    bindUnaryCallbackGuarded$1$1: function(f, $T) {
+      return new P._RootZone_bindUnaryCallbackGuarded_closure(this, $T._eval$1("~(0)")._as(f), $T);
+    },
+    $index: function(_, key) {
+      return null;
+    },
+    run$1$1: function(f, $R) {
+      $R._eval$1("0()")._as(f);
+      if ($.Zone__current === C.C__RootZone)
+        return f.call$0();
+      return P._rootRun(null, null, this, f, $R);
+    },
+    runUnary$2$2: function(f, arg, $R, $T) {
+      $R._eval$1("@<0>")._bind$1($T)._eval$1("1(2)")._as(f);
+      $T._as(arg);
+      if ($.Zone__current === C.C__RootZone)
+        return f.call$1(arg);
+      return P._rootRunUnary(null, null, this, f, arg, $R, $T);
+    },
+    runBinary$3$3: function(f, arg1, arg2, $R, T1, T2) {
+      $R._eval$1("@<0>")._bind$1(T1)._bind$1(T2)._eval$1("1(2,3)")._as(f);
+      T1._as(arg1);
+      T2._as(arg2);
+      if ($.Zone__current === C.C__RootZone)
+        return f.call$2(arg1, arg2);
+      return P._rootRunBinary(null, null, this, f, arg1, arg2, $R, T1, T2);
+    },
+    registerBinaryCallback$3$1: function(f, $R, T1, T2) {
+      return $R._eval$1("@<0>")._bind$1(T1)._bind$1(T2)._eval$1("1(2,3)")._as(f);
+    }
+  };
+  P._RootZone_bindCallback_closure.prototype = {
+    call$0: function() {
+      return this.$this.run$1$1(this.f, this.R);
+    },
+    $signature: function() {
+      return this.R._eval$1("0()");
+    }
+  };
+  P._RootZone_bindCallbackGuarded_closure.prototype = {
+    call$0: function() {
+      return this.$this.runGuarded$1(this.f);
+    },
+    $signature: 0
+  };
+  P._RootZone_bindUnaryCallbackGuarded_closure.prototype = {
+    call$1: function(arg) {
+      var t1 = this.T;
+      return this.$this.runUnaryGuarded$1$2(this.f, t1._as(arg), t1);
+    },
+    $signature: function() {
+      return this.T._eval$1("~(0)");
+    }
+  };
+  P._LinkedHashSet.prototype = {
+    get$iterator: function(_) {
+      var _this = this,
+        t1 = new P._LinkedHashSetIterator(_this, _this._collection$_modifications, H._instanceType(_this)._eval$1("_LinkedHashSetIterator<1>"));
+      t1._collection$_cell = _this._collection$_first;
+      return t1;
+    },
+    get$length: function(_) {
+      return this._collection$_length;
+    },
+    add$1: function(_, element) {
+      var strings, nums, _this = this;
+      H._instanceType(_this)._precomputed1._as(element);
+      if (typeof element == "string" && element !== "__proto__") {
+        strings = _this._collection$_strings;
+        return _this._collection$_addHashTableEntry$2(strings == null ? _this._collection$_strings = P._LinkedHashSet__newHashTable() : strings, element);
+      } else if (typeof element == "number" && (element & 1073741823) === element) {
+        nums = _this._collection$_nums;
+        return _this._collection$_addHashTableEntry$2(nums == null ? _this._collection$_nums = P._LinkedHashSet__newHashTable() : nums, element);
+      } else
+        return _this._collection$_add$1(element);
+    },
+    _collection$_add$1: function(element) {
+      var rest, hash, bucket, _this = this;
+      H._instanceType(_this)._precomputed1._as(element);
+      rest = _this._collection$_rest;
+      if (rest == null)
+        rest = _this._collection$_rest = P._LinkedHashSet__newHashTable();
+      hash = _this._computeHashCode$1(element);
+      bucket = rest[hash];
+      if (bucket == null)
+        rest[hash] = [_this._collection$_newLinkedCell$1(element)];
+      else {
+        if (_this._findBucketIndex$2(bucket, element) >= 0)
+          return false;
+        bucket.push(_this._collection$_newLinkedCell$1(element));
+      }
+      return true;
+    },
+    _collection$_addHashTableEntry$2: function(table, element) {
+      H._instanceType(this)._precomputed1._as(element);
+      if (type$.nullable__LinkedHashSetCell._as(table[element]) != null)
+        return false;
+      table[element] = this._collection$_newLinkedCell$1(element);
+      return true;
+    },
+    _collection$_newLinkedCell$1: function(element) {
+      var _this = this,
+        cell = new P._LinkedHashSetCell(H._instanceType(_this)._precomputed1._as(element));
+      if (_this._collection$_first == null)
+        _this._collection$_first = _this._collection$_last = cell;
+      else
+        _this._collection$_last = _this._collection$_last._collection$_next = cell;
+      ++_this._collection$_length;
+      _this._collection$_modifications = 1073741823 & _this._collection$_modifications + 1;
+      return cell;
+    },
+    _computeHashCode$1: function(element) {
+      return J.get$hashCode$(element) & 1073741823;
+    },
+    _findBucketIndex$2: function(bucket, element) {
+      var $length, i;
+      if (bucket == null)
+        return -1;
+      $length = bucket.length;
+      for (i = 0; i < $length; ++i)
+        if (J.$eq$(bucket[i]._element, element))
+          return i;
+      return -1;
+    }
+  };
+  P._LinkedHashSetCell.prototype = {};
+  P._LinkedHashSetIterator.prototype = {
+    get$current: function() {
+      return this._collection$_current;
+    },
+    moveNext$0: function() {
+      var _this = this,
+        cell = _this._collection$_cell,
+        t1 = _this._set;
+      if (_this._collection$_modifications !== t1._collection$_modifications)
+        throw H.wrapException(P.ConcurrentModificationError$(t1));
+      else if (cell == null) {
+        _this.set$_collection$_current(null);
+        return false;
+      } else {
+        _this.set$_collection$_current(_this.$ti._eval$1("1?")._as(cell._element));
+        _this._collection$_cell = cell._collection$_next;
+        return true;
+      }
+    },
+    set$_collection$_current: function(_current) {
+      this._collection$_current = this.$ti._eval$1("1?")._as(_current);
+    },
+    $isIterator: 1
+  };
+  P.ListMixin.prototype = {
+    get$iterator: function(receiver) {
+      return new H.ListIterator(receiver, this.get$length(receiver), H.instanceType(receiver)._eval$1("ListIterator<ListMixin.E>"));
+    },
+    elementAt$1: function(receiver, index) {
+      return this.$index(receiver, index);
+    },
+    get$isNotEmpty: function(receiver) {
+      return this.get$length(receiver) !== 0;
+    },
+    map$1$1: function(receiver, f, $T) {
+      var t1 = H.instanceType(receiver);
+      return new H.MappedListIterable(receiver, t1._bind$1($T)._eval$1("1(ListMixin.E)")._as(f), t1._eval$1("@<ListMixin.E>")._bind$1($T)._eval$1("MappedListIterable<1,2>"));
+    },
+    map$1: function($receiver, f) {
+      return this.map$1$1($receiver, f, type$.dynamic);
+    },
+    toList$1$growable: function(receiver, growable) {
+      var t1, first, result, i, _this = this;
+      if (_this.get$length(receiver) === 0) {
+        t1 = J.JSArray_JSArray$growable(0, H.instanceType(receiver)._eval$1("ListMixin.E"));
+        return t1;
+      }
+      first = _this.$index(receiver, 0);
+      result = P.List_List$filled(_this.get$length(receiver), first, true, H.instanceType(receiver)._eval$1("ListMixin.E"));
+      for (i = 1; i < _this.get$length(receiver); ++i)
+        C.JSArray_methods.$indexSet(result, i, _this.$index(receiver, i));
+      return result;
+    },
+    toList$0: function($receiver) {
+      return this.toList$1$growable($receiver, true);
+    },
+    $add: function(receiver, other) {
+      var t2, cur,
+        t1 = H.instanceType(receiver);
+      t1._eval$1("List<ListMixin.E>")._as(other);
+      t2 = H.setRuntimeTypeInfo([], t1._eval$1("JSArray<ListMixin.E>"));
+      for (t1 = new H.ListIterator(receiver, this.get$length(receiver), t1._eval$1("ListIterator<ListMixin.E>")); t1.moveNext$0();) {
+        cur = t1._current;
+        C.JSArray_methods.add$1(t2, cur);
+      }
+      for (t1 = other.get$iterator(other); t1.moveNext$0();)
+        C.JSArray_methods.add$1(t2, t1.get$current());
+      return t2;
+    },
+    toString$0: function(receiver) {
+      return P.IterableBase_iterableToFullString(receiver, "[", "]");
+    }
+  };
+  P.MapBase.prototype = {};
+  P.MapBase_mapToString_closure.prototype = {
+    call$2: function(k, v) {
+      var t2,
+        t1 = this._box_0;
+      if (!t1.first)
+        this.result._contents += ", ";
+      t1.first = false;
+      t1 = this.result;
+      t2 = t1._contents += H.S(k);
+      t1._contents = t2 + ": ";
+      t1._contents += H.S(v);
+    },
+    $signature: 13
+  };
+  P.MapMixin.prototype = {
+    forEach$1: function(_, action) {
+      var t1, key;
+      H._instanceType(this)._eval$1("~(MapMixin.K,MapMixin.V)")._as(action);
+      for (t1 = this.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) {
+        key = t1.get$current();
+        action.call$2(key, this.$index(0, key));
+      }
+    },
+    map$2$1: function(_, transform, K2, V2) {
+      var result, t1, key, entry;
+      H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(MapMixin.K,MapMixin.V)")._as(transform);
+      result = P.LinkedHashMap_LinkedHashMap$_empty(K2, V2);
+      for (t1 = this.get$keys(), t1 = t1.get$iterator(t1); t1.moveNext$0();) {
+        key = t1.get$current();
+        entry = transform.call$2(key, this.$index(0, key));
+        result.$indexSet(0, C.JSNull_methods.get$key(entry), entry.get$value());
+      }
+      return result;
+    },
+    map$1: function($receiver, transform) {
+      return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic);
+    },
+    containsKey$1: function(key) {
+      return this.get$keys().contains$1(0, key);
+    },
+    get$length: function(_) {
+      var t1 = this.get$keys();
+      return t1.get$length(t1);
+    },
+    get$isEmpty: function(_) {
+      var t1 = this.get$keys();
+      return t1.get$isEmpty(t1);
+    },
+    toString$0: function(_) {
+      return P.MapBase_mapToString(this);
+    },
+    $isMap: 1
+  };
+  P._UnmodifiableMapMixin.prototype = {
+    $indexSet: function(_, key, value) {
+      var t1 = H._instanceType(this);
+      t1._precomputed1._as(key);
+      t1._rest[1]._as(value);
+      throw H.wrapException(P.UnsupportedError$("Cannot modify unmodifiable map"));
+    }
+  };
+  P.MapView.prototype = {
+    $index: function(_, key) {
+      return this._collection$_map.$index(0, key);
+    },
+    $indexSet: function(_, key, value) {
+      var t1 = H._instanceType(this);
+      this._collection$_map.$indexSet(0, t1._precomputed1._as(key), t1._rest[1]._as(value));
+    },
+    containsKey$1: function(key) {
+      return this._collection$_map.containsKey$1(key);
+    },
+    forEach$1: function(_, action) {
+      this._collection$_map.forEach$1(0, H._instanceType(this)._eval$1("~(1,2)")._as(action));
+    },
+    get$isEmpty: function(_) {
+      var t1 = this._collection$_map;
+      return t1.get$isEmpty(t1);
+    },
+    get$length: function(_) {
+      var t1 = this._collection$_map;
+      return t1.get$length(t1);
+    },
+    get$keys: function() {
+      return this._collection$_map.get$keys();
+    },
+    toString$0: function(_) {
+      return P.MapBase_mapToString(this._collection$_map);
+    },
+    map$2$1: function(_, transform, K2, V2) {
+      return this._collection$_map.map$2$1(0, H._instanceType(this)._bind$1(K2)._bind$1(V2)._eval$1("MapEntry<1,2>(3,4)")._as(transform), K2, V2);
+    },
+    map$1: function($receiver, transform) {
+      return this.map$2$1($receiver, transform, type$.dynamic, type$.dynamic);
+    },
+    $isMap: 1
+  };
+  P.UnmodifiableMapView.prototype = {};
+  P.ListQueue.prototype = {
+    get$iterator: function(_) {
+      var _this = this;
+      return new P._ListQueueIterator(_this, _this._tail, _this._modificationCount, _this._head, _this.$ti._eval$1("_ListQueueIterator<1>"));
+    },
+    get$isEmpty: function(_) {
+      return this._head === this._tail;
+    },
+    get$length: function(_) {
+      return (this._tail - this._head & this._collection$_table.length - 1) >>> 0;
+    },
+    elementAt$1: function(_, index) {
+      var t1, t2, t3, _this = this,
+        $length = _this.get$length(_this);
+      if (0 > index || index >= $length)
+        H.throwExpression(P.IndexError$(index, _this, "index", null, $length));
+      t1 = _this._collection$_table;
+      t2 = t1.length;
+      t3 = (_this._head + index & t2 - 1) >>> 0;
+      if (t3 < 0 || t3 >= t2)
+        return H.ioore(t1, t3);
+      return t1[t3];
+    },
+    toString$0: function(_) {
+      return P.IterableBase_iterableToFullString(this, "{", "}");
+    },
+    set$_collection$_table: function(_table) {
+      this._collection$_table = this.$ti._eval$1("List<1?>")._as(_table);
+    },
+    $isQueue: 1
+  };
+  P._ListQueueIterator.prototype = {
+    get$current: function() {
+      var cur = this._collection$_current;
+      return cur;
+    },
+    moveNext$0: function() {
+      var t2, t3, _this = this,
+        t1 = _this._queue;
+      if (_this._modificationCount !== t1._modificationCount)
+        H.throwExpression(P.ConcurrentModificationError$(t1));
+      t2 = _this._position;
+      if (t2 === _this._end) {
+        _this.set$_collection$_current(null);
+        return false;
+      }
+      t3 = t1._collection$_table;
+      if (t2 >= t3.length)
+        return H.ioore(t3, t2);
+      _this.set$_collection$_current(t3[t2]);
+      _this._position = (_this._position + 1 & t1._collection$_table.length - 1) >>> 0;
+      return true;
+    },
+    set$_collection$_current: function(_current) {
+      this._collection$_current = this.$ti._eval$1("1?")._as(_current);
+    },
+    $isIterator: 1
+  };
+  P._SetBase.prototype = {
+    map$1: function(_, f) {
+      var t1 = H._instanceType(this);
+      return new H.EfficientLengthMappedIterable(this, t1._eval$1("@(1)")._as(f), t1._eval$1("EfficientLengthMappedIterable<1,@>"));
+    },
+    toString$0: function(_) {
+      return P.IterableBase_iterableToFullString(this, "{", "}");
+    },
+    $isEfficientLengthIterable: 1,
+    $isIterable: 1
+  };
+  P._UnmodifiableMapView_MapView__UnmodifiableMapMixin.prototype = {};
+  P._JsonMap.prototype = {
+    $index: function(_, key) {
+      var result,
+        t1 = this._processed;
+      if (t1 == null)
+        return this._data.$index(0, key);
+      else if (typeof key != "string")
+        return null;
+      else {
+        result = t1[key];
+        return typeof result == "undefined" ? this._process$1(key) : result;
+      }
+    },
+    get$length: function(_) {
+      var t1;
+      if (this._processed == null) {
+        t1 = this._data;
+        t1 = t1.get$length(t1);
+      } else
+        t1 = this._computeKeys$0().length;
+      return t1;
+    },
+    get$isEmpty: function(_) {
+      return this.get$length(this) === 0;
+    },
+    get$keys: function() {
+      if (this._processed == null)
+        return this._data.get$keys();
+      return new P._JsonMapKeyIterable(this);
+    },
+    $indexSet: function(_, key, value) {
+      var processed, original, _this = this;
+      if (_this._processed == null)
+        _this._data.$indexSet(0, key, value);
+      else if (_this.containsKey$1(key)) {
+        processed = _this._processed;
+        processed[key] = value;
+        original = _this._original;
+        if (original == null ? processed != null : original !== processed)
+          original[key] = null;
+      } else
+        _this._upgrade$0().$indexSet(0, key, value);
+    },
+    containsKey$1: function(key) {
+      if (this._processed == null)
+        return this._data.containsKey$1(key);
+      return Object.prototype.hasOwnProperty.call(this._original, key);
+    },
+    forEach$1: function(_, f) {
+      var keys, i, key, value, _this = this;
+      type$.void_Function_String_dynamic._as(f);
+      if (_this._processed == null)
+        return _this._data.forEach$1(0, f);
+      keys = _this._computeKeys$0();
+      for (i = 0; i < keys.length; ++i) {
+        key = keys[i];
+        value = _this._processed[key];
+        if (typeof value == "undefined") {
+          value = P._convertJsonToDartLazy(_this._original[key]);
+          _this._processed[key] = value;
+        }
+        f.call$2(key, value);
+        if (keys !== _this._data)
+          throw H.wrapException(P.ConcurrentModificationError$(_this));
+      }
+    },
+    _computeKeys$0: function() {
+      var keys = type$.nullable_List_dynamic._as(this._data);
+      if (keys == null)
+        keys = this._data = H.setRuntimeTypeInfo(Object.keys(this._original), type$.JSArray_String);
+      return keys;
+    },
+    _upgrade$0: function() {
+      var result, keys, i, t1, key, _this = this;
+      if (_this._processed == null)
+        return _this._data;
+      result = P.LinkedHashMap_LinkedHashMap$_empty(type$.String, type$.dynamic);
+      keys = _this._computeKeys$0();
+      for (i = 0; t1 = keys.length, i < t1; ++i) {
+        key = keys[i];
+        result.$indexSet(0, key, _this.$index(0, key));
+      }
+      if (t1 === 0)
+        C.JSArray_methods.add$1(keys, "");
+      else
+        C.JSArray_methods.set$length(keys, 0);
+      _this._original = _this._processed = null;
+      return _this._data = result;
+    },
+    _process$1: function(key) {
+      var result;
+      if (!Object.prototype.hasOwnProperty.call(this._original, key))
+        return null;
+      result = P._convertJsonToDartLazy(this._original[key]);
+      return this._processed[key] = result;
+    }
+  };
+  P._JsonMapKeyIterable.prototype = {
+    get$length: function(_) {
+      var t1 = this._parent;
+      return t1.get$length(t1);
+    },
+    elementAt$1: function(_, index) {
+      var t1 = this._parent;
+      if (t1._processed == null)
+        t1 = t1.get$keys().elementAt$1(0, index);
+      else {
+        t1 = t1._computeKeys$0();
+        if (index < 0 || index >= t1.length)
+          return H.ioore(t1, index);
+        t1 = t1[index];
+      }
+      return t1;
+    },
+    get$iterator: function(_) {
+      var t1 = this._parent;
+      if (t1._processed == null) {
+        t1 = t1.get$keys();
+        t1 = t1.get$iterator(t1);
+      } else {
+        t1 = t1._computeKeys$0();
+        t1 = new J.ArrayIterator(t1, t1.length, H._arrayInstanceType(t1)._eval$1("ArrayIterator<1>"));
+      }
+      return t1;
+    },
+    contains$1: function(_, key) {
+      return this._parent.containsKey$1(key);
+    }
+  };
+  P.Utf8Decoder_closure.prototype = {
+    call$0: function() {
+      var t1, exception;
+      try {
+        t1 = new TextDecoder("utf-8", {fatal: true});
+        return t1;
+      } catch (exception) {
+        H.unwrapException(exception);
+      }
+      return null;
+    },
+    $signature: 14
+  };
+  P.Utf8Decoder_closure0.prototype = {
+    call$0: function() {
+      var t1, exception;
+      try {
+        t1 = new TextDecoder("utf-8", {fatal: false});
+        return t1;
+      } catch (exception) {
+        H.unwrapException(exception);
+      }
+      return null;
+    },
+    $signature: 14
+  };
+  P.Codec.prototype = {};
+  P.Converter.prototype = {};
+  P.JsonUnsupportedObjectError.prototype = {
+    toString$0: function(_) {
+      var safeString = P.Error_safeToString(this.unsupportedObject);
+      return (this.cause != null ? "Converting object to an encodable object failed:" : "Converting object did not return an encodable object:") + " " + safeString;
+    }
+  };
+  P.JsonCyclicError.prototype = {
+    toString$0: function(_) {
+      return "Cyclic error in JSON stringify";
+    }
+  };
+  P.JsonCodec.prototype = {
+    decode$2$reviver: function(source, reviver) {
+      var t1;
+      type$.nullable_nullable_Object_Function_2_nullable_Object_and_nullable_Object._as(reviver);
+      t1 = P._parseJson(source, this.get$decoder()._reviver);
+      return t1;
+    },
+    encode$2$toEncodable: function(value, toEncodable) {
+      var t1;
+      type$.nullable_nullable_Object_Function_dynamic._as(toEncodable);
+      t1 = P._JsonStringStringifier_stringify(value, this.get$encoder()._toEncodable, null);
+      return t1;
+    },
+    encode$1: function(value) {
+      return this.encode$2$toEncodable(value, null);
+    },
+    get$encoder: function() {
+      return C.JsonEncoder_null;
+    },
+    get$decoder: function() {
+      return C.JsonDecoder_null;
+    }
+  };
+  P.JsonEncoder.prototype = {};
+  P.JsonDecoder.prototype = {};
+  P._JsonStringifier.prototype = {
+    writeStringContent$1: function(s) {
+      var t1, t2, offset, i, charCode, t3, t4,
+        $length = s.length;
+      for (t1 = J.getInterceptor$s(s), t2 = this._sink, offset = 0, i = 0; i < $length; ++i) {
+        charCode = t1._codeUnitAt$1(s, i);
+        if (charCode > 92) {
+          if (charCode >= 55296) {
+            t3 = charCode & 64512;
+            if (t3 === 55296) {
+              t4 = i + 1;
+              t4 = !(t4 < $length && (C.JSString_methods._codeUnitAt$1(s, t4) & 64512) === 56320);
+            } else
+              t4 = false;
+            if (!t4)
+              if (t3 === 56320) {
+                t3 = i - 1;
+                t3 = !(t3 >= 0 && (C.JSString_methods.codeUnitAt$1(s, t3) & 64512) === 55296);
+              } else
+                t3 = false;
+            else
+              t3 = true;
+            if (t3) {
+              if (i > offset)
+                t2._contents += C.JSString_methods.substring$2(s, offset, i);
+              offset = i + 1;
+              t2._contents += H.Primitives_stringFromCharCode(92);
+              t2._contents += H.Primitives_stringFromCharCode(117);
+              t2._contents += H.Primitives_stringFromCharCode(100);
+              t3 = charCode >>> 8 & 15;
+              t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3);
+              t3 = charCode >>> 4 & 15;
+              t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3);
+              t3 = charCode & 15;
+              t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3);
+            }
+          }
+          continue;
+        }
+        if (charCode < 32) {
+          if (i > offset)
+            t2._contents += C.JSString_methods.substring$2(s, offset, i);
+          offset = i + 1;
+          t2._contents += H.Primitives_stringFromCharCode(92);
+          switch (charCode) {
+            case 8:
+              t2._contents += H.Primitives_stringFromCharCode(98);
+              break;
+            case 9:
+              t2._contents += H.Primitives_stringFromCharCode(116);
+              break;
+            case 10:
+              t2._contents += H.Primitives_stringFromCharCode(110);
+              break;
+            case 12:
+              t2._contents += H.Primitives_stringFromCharCode(102);
+              break;
+            case 13:
+              t2._contents += H.Primitives_stringFromCharCode(114);
+              break;
+            default:
+              t2._contents += H.Primitives_stringFromCharCode(117);
+              t2._contents += H.Primitives_stringFromCharCode(48);
+              t2._contents += H.Primitives_stringFromCharCode(48);
+              t3 = charCode >>> 4 & 15;
+              t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3);
+              t3 = charCode & 15;
+              t2._contents += H.Primitives_stringFromCharCode(t3 < 10 ? 48 + t3 : 87 + t3);
+              break;
+          }
+        } else if (charCode === 34 || charCode === 92) {
+          if (i > offset)
+            t2._contents += C.JSString_methods.substring$2(s, offset, i);
+          offset = i + 1;
+          t2._contents += H.Primitives_stringFromCharCode(92);
+          t2._contents += H.Primitives_stringFromCharCode(charCode);
+        }
+      }
+      if (offset === 0)
+        t2._contents += H.S(s);
+      else if (offset < $length)
+        t2._contents += t1.substring$2(s, offset, $length);
+    },
+    _checkCycle$1: function(object) {
+      var t1, t2, i, t3;
+      for (t1 = this._seen, t2 = t1.length, i = 0; i < t2; ++i) {
+        t3 = t1[i];
+        if (object == null ? t3 == null : object === t3)
+          throw H.wrapException(new P.JsonCyclicError(object, null));
+      }
+      C.JSArray_methods.add$1(t1, object);
+    },
+    writeObject$1: function(object) {
+      var customJson, e, t1, exception, _this = this;
+      if (_this.writeJsonValue$1(object))
+        return;
+      _this._checkCycle$1(object);
+      try {
+        customJson = _this._toEncodable.call$1(object);
+        if (!_this.writeJsonValue$1(customJson)) {
+          t1 = P.JsonUnsupportedObjectError$(object, null, _this.get$_partialResult());
+          throw H.wrapException(t1);
+        }
+        t1 = _this._seen;
+        if (0 >= t1.length)
+          return H.ioore(t1, -1);
+        t1.pop();
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        t1 = P.JsonUnsupportedObjectError$(object, e, _this.get$_partialResult());
+        throw H.wrapException(t1);
+      }
+    },
+    writeJsonValue$1: function(object) {
+      var t1, success, _this = this;
+      if (typeof object == "number") {
+        if (!isFinite(object))
+          return false;
+        _this._sink._contents += C.JSNumber_methods.toString$0(object);
+        return true;
+      } else if (object === true) {
+        _this._sink._contents += "true";
+        return true;
+      } else if (object === false) {
+        _this._sink._contents += "false";
+        return true;
+      } else if (object == null) {
+        _this._sink._contents += "null";
+        return true;
+      } else if (typeof object == "string") {
+        t1 = _this._sink;
+        t1._contents += '"';
+        _this.writeStringContent$1(object);
+        t1._contents += '"';
+        return true;
+      } else if (type$.List_dynamic._is(object)) {
+        _this._checkCycle$1(object);
+        _this.writeList$1(object);
+        t1 = _this._seen;
+        if (0 >= t1.length)
+          return H.ioore(t1, -1);
+        t1.pop();
+        return true;
+      } else if (type$.Map_dynamic_dynamic._is(object)) {
+        _this._checkCycle$1(object);
+        success = _this.writeMap$1(object);
+        t1 = _this._seen;
+        if (0 >= t1.length)
+          return H.ioore(t1, -1);
+        t1.pop();
+        return success;
+      } else
+        return false;
+    },
+    writeList$1: function(list) {
+      var t2, i,
+        t1 = this._sink;
+      t1._contents += "[";
+      t2 = J.getInterceptor$ax(list);
+      if (t2.get$isNotEmpty(list)) {
+        this.writeObject$1(t2.$index(list, 0));
+        for (i = 1; i < t2.get$length(list); ++i) {
+          t1._contents += ",";
+          this.writeObject$1(t2.$index(list, i));
+        }
+      }
+      t1._contents += "]";
+    },
+    writeMap$1: function(map) {
+      var keyValueList, i, t1, separator, t2, _this = this, _box_0 = {};
+      if (map.get$isEmpty(map)) {
+        _this._sink._contents += "{}";
+        return true;
+      }
+      keyValueList = P.List_List$filled(map.get$length(map) * 2, null, false, type$.nullable_Object);
+      i = _box_0.i = 0;
+      _box_0.allStringKeys = true;
+      map.forEach$1(0, new P._JsonStringifier_writeMap_closure(_box_0, keyValueList));
+      if (!_box_0.allStringKeys)
+        return false;
+      t1 = _this._sink;
+      t1._contents += "{";
+      for (separator = '"'; i < keyValueList.length; i += 2, separator = ',"') {
+        t1._contents += separator;
+        _this.writeStringContent$1(H._asStringS(keyValueList[i]));
+        t1._contents += '":';
+        t2 = i + 1;
+        if (t2 >= keyValueList.length)
+          return H.ioore(keyValueList, t2);
+        _this.writeObject$1(keyValueList[t2]);
+      }
+      t1._contents += "}";
+      return true;
+    }
+  };
+  P._JsonStringifier_writeMap_closure.prototype = {
+    call$2: function(key, value) {
+      var t1, t2;
+      if (typeof key != "string")
+        this._box_0.allStringKeys = false;
+      t1 = this.keyValueList;
+      t2 = this._box_0;
+      C.JSArray_methods.$indexSet(t1, t2.i++, key);
+      C.JSArray_methods.$indexSet(t1, t2.i++, value);
+    },
+    $signature: 13
+  };
+  P._JsonStringStringifier.prototype = {
+    get$_partialResult: function() {
+      var t1 = this._sink._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    }
+  };
+  P.Utf8Decoder.prototype = {
+    convert$1: function(codeUnits) {
+      var t1, result;
+      type$.List_int._as(codeUnits);
+      t1 = this._allowMalformed;
+      result = P.Utf8Decoder__convertIntercepted(t1, codeUnits, 0, null);
+      if (result != null)
+        return result;
+      return new P._Utf8Decoder(t1).convertGeneral$4(codeUnits, 0, null, true);
+    }
+  };
+  P._Utf8Decoder.prototype = {
+    convertGeneral$4: function(codeUnits, start, maybeEnd, single) {
+      var end, result, t1, message, _this = this;
+      type$.List_int._as(codeUnits);
+      end = P.RangeError_checkValidRange(start, maybeEnd, codeUnits.length);
+      if (start === end)
+        return "";
+      result = _this._convertRecursive$4(codeUnits, start, end, true);
+      t1 = _this._convert$_state;
+      if ((t1 & 1) !== 0) {
+        message = P._Utf8Decoder_errorDescription(t1);
+        _this._convert$_state = 0;
+        throw H.wrapException(P.FormatException$(message, codeUnits, _this._charOrIndex));
+      }
+      return result;
+    },
+    _convertRecursive$4: function(bytes, start, end, single) {
+      var mid, s1, _this = this;
+      if (end - start > 1000) {
+        mid = C.JSInt_methods._tdivFast$1(start + end, 2);
+        s1 = _this._convertRecursive$4(bytes, start, mid, false);
+        if ((_this._convert$_state & 1) !== 0)
+          return s1;
+        return s1 + _this._convertRecursive$4(bytes, mid, end, single);
+      }
+      return _this.decodeGeneral$4(bytes, start, end, single);
+    },
+    decodeGeneral$4: function(bytes, start, end, single) {
+      var byte, t2, type, t3, i0, markEnd, i1, m, _this = this, _65533 = 65533,
+        state = _this._convert$_state,
+        char = _this._charOrIndex,
+        buffer = new P.StringBuffer(""),
+        i = start + 1,
+        t1 = bytes.length;
+      if (start < 0 || start >= t1)
+        return H.ioore(bytes, start);
+      byte = bytes[start];
+      $label0$0:
+        for (t2 = _this.allowMalformed; true;) {
+          for (; true; i = i0) {
+            type = C.JSString_methods._codeUnitAt$1("AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFFFFFFFFFFFFFFFFGGGGGGGGGGGGGGGGHHHHHHHHHHHHHHHHHHHHHHHHHHHIHHHJEEBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBKCCCCCCCCCCCCDCLONNNMEEEEEEEEEEE", byte) & 31;
+            char = state <= 32 ? byte & 61694 >>> type : (byte & 63 | char << 6) >>> 0;
+            state = C.JSString_methods._codeUnitAt$1(" \x000:XECCCCCN:lDb \x000:XECCCCCNvlDb \x000:XECCCCCN:lDb AAAAA\x00\x00\x00\x00\x00AAAAA00000AAAAA:::::AAAAAGG000AAAAA00KKKAAAAAG::::AAAAA:IIIIAAAAA000\x800AAAAA\x00\x00\x00\x00 AAAAA", state + type);
+            if (state === 0) {
+              buffer._contents += H.Primitives_stringFromCharCode(char);
+              if (i === end)
+                break $label0$0;
+              break;
+            } else if ((state & 1) !== 0) {
+              if (t2)
+                switch (state) {
+                  case 69:
+                  case 67:
+                    buffer._contents += H.Primitives_stringFromCharCode(_65533);
+                    break;
+                  case 65:
+                    buffer._contents += H.Primitives_stringFromCharCode(_65533);
+                    --i;
+                    break;
+                  default:
+                    t3 = buffer._contents += H.Primitives_stringFromCharCode(_65533);
+                    buffer._contents = t3 + H.Primitives_stringFromCharCode(_65533);
+                    break;
+                }
+              else {
+                _this._convert$_state = state;
+                _this._charOrIndex = i - 1;
+                return "";
+              }
+              state = 0;
+            }
+            if (i === end)
+              break $label0$0;
+            i0 = i + 1;
+            if (i < 0 || i >= t1)
+              return H.ioore(bytes, i);
+            byte = bytes[i];
+          }
+          i0 = i + 1;
+          if (i < 0 || i >= t1)
+            return H.ioore(bytes, i);
+          byte = bytes[i];
+          if (byte < 128) {
+            while (true) {
+              if (!(i0 < end)) {
+                markEnd = end;
+                break;
+              }
+              i1 = i0 + 1;
+              if (i0 < 0 || i0 >= t1)
+                return H.ioore(bytes, i0);
+              byte = bytes[i0];
+              if (byte >= 128) {
+                markEnd = i1 - 1;
+                i0 = i1;
+                break;
+              }
+              i0 = i1;
+            }
+            if (markEnd - i < 20)
+              for (m = i; m < markEnd; ++m) {
+                if (m >= t1)
+                  return H.ioore(bytes, m);
+                buffer._contents += H.Primitives_stringFromCharCode(bytes[m]);
+              }
+            else
+              buffer._contents += P.String_String$fromCharCodes(bytes, i, markEnd);
+            if (markEnd === end)
+              break $label0$0;
+            i = i0;
+          } else
+            i = i0;
+        }
+      if (single && state > 32)
+        if (t2)
+          buffer._contents += H.Primitives_stringFromCharCode(_65533);
+        else {
+          _this._convert$_state = 77;
+          _this._charOrIndex = end;
+          return "";
+        }
+      _this._convert$_state = state;
+      _this._charOrIndex = char;
+      t1 = buffer._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    }
+  };
+  P._symbolMapToStringMap_closure.prototype = {
+    call$2: function(key, value) {
+      this.result.$indexSet(0, type$.Symbol._as(key).__internal$_name, value);
+    },
+    $signature: 15
+  };
+  P.NoSuchMethodError_toString_closure.prototype = {
+    call$2: function(key, value) {
+      var t1, t2, t3;
+      type$.Symbol._as(key);
+      t1 = this.sb;
+      t2 = this._box_0;
+      t1._contents += t2.comma;
+      t3 = t1._contents += H.S(key.__internal$_name);
+      t1._contents = t3 + ": ";
+      t1._contents += P.Error_safeToString(value);
+      t2.comma = ", ";
+    },
+    $signature: 15
+  };
+  P.bool.prototype = {};
+  P.DateTime.prototype = {
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof P.DateTime && this._value === other._value && this.isUtc === other.isUtc;
+    },
+    get$hashCode: function(_) {
+      var t1 = this._value;
+      return (t1 ^ C.JSInt_methods._shrOtherPositive$1(t1, 30)) & 1073741823;
+    },
+    toString$0: function(_) {
+      var _this = this,
+        y = P.DateTime__fourDigits(H.Primitives_getYear(_this)),
+        m = P.DateTime__twoDigits(H.Primitives_getMonth(_this)),
+        d = P.DateTime__twoDigits(H.Primitives_getDay(_this)),
+        h = P.DateTime__twoDigits(H.Primitives_getHours(_this)),
+        min = P.DateTime__twoDigits(H.Primitives_getMinutes(_this)),
+        sec = P.DateTime__twoDigits(H.Primitives_getSeconds(_this)),
+        ms = P.DateTime__threeDigits(H.Primitives_getMilliseconds(_this));
+      if (_this.isUtc)
+        return y + "-" + m + "-" + d + " " + h + ":" + min + ":" + sec + "." + ms + "Z";
+      else
+        return y + "-" + m + "-" + d + " " + h + ":" + min + ":" + sec + "." + ms;
+    }
+  };
+  P.double.prototype = {};
+  P.Duration.prototype = {
+    $add: function(_, other) {
+      return new P.Duration(C.JSInt_methods.$add(this._duration, type$.Duration._as(other).get$_duration()));
+    },
+    $sub: function(_, other) {
+      return new P.Duration(C.JSInt_methods.$sub(this._duration, type$.Duration._as(other).get$_duration()));
+    },
+    $lt: function(_, other) {
+      return C.JSInt_methods.$lt(this._duration, type$.Duration._as(other).get$_duration());
+    },
+    $gt: function(_, other) {
+      return C.JSInt_methods.$gt(this._duration, type$.Duration._as(other).get$_duration());
+    },
+    $ge: function(_, other) {
+      return C.JSInt_methods.$ge(this._duration, type$.Duration._as(other).get$_duration());
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof P.Duration && this._duration === other._duration;
+    },
+    get$hashCode: function(_) {
+      return C.JSInt_methods.get$hashCode(this._duration);
+    },
+    toString$0: function(_) {
+      var twoDigitMinutes, twoDigitSeconds, sixDigitUs,
+        t1 = new P.Duration_toString_twoDigits(),
+        t2 = this._duration;
+      if (t2 < 0)
+        return "-" + new P.Duration(0 - t2).toString$0(0);
+      twoDigitMinutes = t1.call$1(C.JSInt_methods._tdivFast$1(t2, 60000000) % 60);
+      twoDigitSeconds = t1.call$1(C.JSInt_methods._tdivFast$1(t2, 1000000) % 60);
+      sixDigitUs = new P.Duration_toString_sixDigits().call$1(t2 % 1000000);
+      return "" + C.JSInt_methods._tdivFast$1(t2, 3600000000) + ":" + H.S(twoDigitMinutes) + ":" + H.S(twoDigitSeconds) + "." + H.S(sixDigitUs);
+    }
+  };
+  P.Duration_toString_sixDigits.prototype = {
+    call$1: function(n) {
+      if (n >= 100000)
+        return "" + n;
+      if (n >= 10000)
+        return "0" + n;
+      if (n >= 1000)
+        return "00" + n;
+      if (n >= 100)
+        return "000" + n;
+      if (n >= 10)
+        return "0000" + n;
+      return "00000" + n;
+    },
+    $signature: 16
+  };
+  P.Duration_toString_twoDigits.prototype = {
+    call$1: function(n) {
+      if (n >= 10)
+        return "" + n;
+      return "0" + n;
+    },
+    $signature: 16
+  };
+  P.Error0.prototype = {
+    get$stackTrace: function() {
+      return H.getTraceFromException(this.$thrownJsError);
+    }
+  };
+  P.AssertionError.prototype = {
+    toString$0: function(_) {
+      var t1 = this.message;
+      if (t1 != null)
+        return "Assertion failed: " + P.Error_safeToString(t1);
+      return "Assertion failed";
+    }
+  };
+  P.NullThrownError.prototype = {
+    toString$0: function(_) {
+      return "Throw of null.";
+    }
+  };
+  P.ArgumentError.prototype = {
+    get$_errorName: function() {
+      return "Invalid argument" + (!this._hasValue ? "(s)" : "");
+    },
+    get$_errorExplanation: function() {
+      return "";
+    },
+    toString$0: function(_) {
+      var explanation, errorValue, _this = this,
+        $name = _this.name,
+        nameString = $name == null ? "" : " (" + $name + ")",
+        message = _this.message,
+        messageString = message == null ? "" : ": " + message,
+        prefix = _this.get$_errorName() + nameString + messageString;
+      if (!_this._hasValue)
+        return prefix;
+      explanation = _this.get$_errorExplanation();
+      errorValue = P.Error_safeToString(_this.invalidValue);
+      return prefix + explanation + ": " + errorValue;
+    }
+  };
+  P.RangeError.prototype = {
+    get$_errorName: function() {
+      return "RangeError";
+    },
+    get$_errorExplanation: function() {
+      var explanation,
+        start = this.start,
+        end = this.end;
+      if (start == null)
+        explanation = end != null ? ": Not less than or equal to " + H.S(end) : "";
+      else if (end == null)
+        explanation = ": Not greater than or equal to " + H.S(start);
+      else if (end > start)
+        explanation = ": Not in inclusive range " + H.S(start) + ".." + H.S(end);
+      else
+        explanation = end < start ? ": Valid value range is empty" : ": Only valid value is " + H.S(start);
+      return explanation;
+    }
+  };
+  P.IndexError.prototype = {
+    get$_errorName: function() {
+      return "RangeError";
+    },
+    get$_errorExplanation: function() {
+      var t1,
+        invalidValue = H._asIntS(this.invalidValue);
+      if (typeof invalidValue !== "number")
+        return invalidValue.$lt();
+      if (invalidValue < 0)
+        return ": index must not be negative";
+      t1 = this.length;
+      if (t1 === 0)
+        return ": no indices are valid";
+      return ": index should be less than " + H.S(t1);
+    },
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  P.NoSuchMethodError.prototype = {
+    toString$0: function(_) {
+      var $arguments, t1, _i, t2, t3, argument, receiverText, actualParameters, _this = this, _box_0 = {},
+        sb = new P.StringBuffer("");
+      _box_0.comma = "";
+      $arguments = _this._core$_arguments;
+      for (t1 = $arguments.length, _i = 0, t2 = "", t3 = ""; _i < t1; ++_i, t3 = ", ") {
+        argument = $arguments[_i];
+        sb._contents = t2 + t3;
+        t2 = sb._contents += P.Error_safeToString(argument);
+        _box_0.comma = ", ";
+      }
+      _this._namedArguments.forEach$1(0, new P.NoSuchMethodError_toString_closure(_box_0, sb));
+      receiverText = P.Error_safeToString(_this._core$_receiver);
+      actualParameters = sb.toString$0(0);
+      t1 = "NoSuchMethodError: method not found: '" + H.S(_this._core$_memberName.__internal$_name) + "'\nReceiver: " + receiverText + "\nArguments: [" + actualParameters + "]";
+      return t1;
+    }
+  };
+  P.UnsupportedError.prototype = {
+    toString$0: function(_) {
+      return "Unsupported operation: " + this.message;
+    }
+  };
+  P.UnimplementedError.prototype = {
+    toString$0: function(_) {
+      var message = this.message;
+      return message != null ? "UnimplementedError: " + message : "UnimplementedError";
+    }
+  };
+  P.StateError.prototype = {
+    toString$0: function(_) {
+      return "Bad state: " + this.message;
+    }
+  };
+  P.ConcurrentModificationError.prototype = {
+    toString$0: function(_) {
+      var t1 = this.modifiedObject;
+      if (t1 == null)
+        return "Concurrent modification during iteration.";
+      return "Concurrent modification during iteration: " + P.Error_safeToString(t1) + ".";
+    }
+  };
+  P.OutOfMemoryError.prototype = {
+    toString$0: function(_) {
+      return "Out of Memory";
+    },
+    get$stackTrace: function() {
+      return null;
+    },
+    $isError0: 1
+  };
+  P.StackOverflowError.prototype = {
+    toString$0: function(_) {
+      return "Stack Overflow";
+    },
+    get$stackTrace: function() {
+      return null;
+    },
+    $isError0: 1
+  };
+  P.CyclicInitializationError.prototype = {
+    toString$0: function(_) {
+      var variableName = this.variableName;
+      return variableName == null ? "Reading static variable during its initialization" : "Reading static variable '" + variableName + "' during its initialization";
+    }
+  };
+  P._Exception.prototype = {
+    toString$0: function(_) {
+      return "Exception: " + this.message;
+    }
+  };
+  P.FormatException.prototype = {
+    toString$0: function(_) {
+      var message = this.message,
+        report = message != null && "" !== message ? "FormatException: " + H.S(message) : "FormatException",
+        offset = this.offset;
+      return offset != null ? report + (" (at offset " + H.S(offset) + ")") : report;
+    }
+  };
+  P.Function.prototype = {};
+  P.int.prototype = {};
+  P.Iterable.prototype = {
+    map$1: function(_, f) {
+      var t1 = H._instanceType(this);
+      return H.MappedIterable_MappedIterable(this, t1._eval$1("@(Iterable.E)")._as(f), t1._eval$1("Iterable.E"), type$.dynamic);
+    },
+    get$length: function(_) {
+      var count,
+        it = this.get$iterator(this);
+      for (count = 0; it.moveNext$0();)
+        ++count;
+      return count;
+    },
+    elementAt$1: function(_, index) {
+      var t1, elementIndex, element;
+      P.RangeError_checkNotNegative(index, "index");
+      for (t1 = this.get$iterator(this), elementIndex = 0; t1.moveNext$0();) {
+        element = t1.get$current();
+        if (index === elementIndex)
+          return element;
+        ++elementIndex;
+      }
+      throw H.wrapException(P.IndexError$(index, this, "index", null, elementIndex));
+    },
+    toString$0: function(_) {
+      return P.IterableBase_iterableToShortString(this, "(", ")");
+    }
+  };
+  P.Iterator.prototype = {};
+  P.List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1};
+  P.Map.prototype = {};
+  P.MapEntry.prototype = {};
+  P.Null.prototype = {
+    get$hashCode: function(_) {
+      return P.Object.prototype.get$hashCode.call(C.JSNull_methods, this);
+    },
+    toString$0: function(_) {
+      return "null";
+    }
+  };
+  P.num.prototype = {};
+  P.Object.prototype = {constructor: P.Object, $isObject: 1,
+    $eq: function(_, other) {
+      return this === other;
+    },
+    get$hashCode: function(_) {
+      return H.Primitives_objectHashCode(this);
+    },
+    toString$0: function(_) {
+      return "Instance of '" + H.S(H.Primitives_objectTypeName(this)) + "'";
+    },
+    noSuchMethod$1: function(_, invocation) {
+      type$.Invocation._as(invocation);
+      throw H.wrapException(P.NoSuchMethodError$(this, invocation.get$memberName(), invocation.get$positionalArguments(), invocation.get$namedArguments()));
+    },
+    get$runtimeType: function(_) {
+      return H.getRuntimeType(this);
+    },
+    toString: function() {
+      return this.toString$0(this);
+    }
+  };
+  P.StackTrace.prototype = {};
+  P._StringStackTrace.prototype = {
+    toString$0: function(_) {
+      return "";
+    },
+    $isStackTrace: 1
+  };
+  P.String.prototype = {$isPattern: 1};
+  P.StringBuffer.prototype = {
+    get$length: function(_) {
+      return this._contents.length;
+    },
+    toString$0: function(_) {
+      var t1 = this._contents;
+      return t1.charCodeAt(0) == 0 ? t1 : t1;
+    },
+    $isStringSink: 1
+  };
+  P.Symbol0.prototype = {};
+  W.DomException.prototype = {
+    toString$0: function(receiver) {
+      return String(receiver);
+    }
+  };
+  W.Event0.prototype = {$isEvent0: 1};
+  W.EventSource.prototype = {$isEventSource: 1};
+  W.EventTarget.prototype = {
+    addEventListener$3: function(receiver, type, listener, useCapture) {
+      type$.nullable_dynamic_Function_Event._as(listener);
+      if (listener != null)
+        this._addEventListener$3(receiver, type, listener, useCapture);
+    },
+    addEventListener$2: function($receiver, type, listener) {
+      return this.addEventListener$3($receiver, type, listener, null);
+    },
+    _addEventListener$3: function(receiver, type, listener, options) {
+      return receiver.addEventListener(type, H.convertDartClosureToJS(type$.nullable_dynamic_Function_Event._as(listener), 1), options);
+    },
+    _removeEventListener$3: function(receiver, type, listener, options) {
+      return receiver.removeEventListener(type, H.convertDartClosureToJS(type$.nullable_dynamic_Function_Event._as(listener), 1), false);
+    },
+    $isEventTarget: 1
+  };
+  W.HttpRequest.prototype = {
+    open$3$async: function(receiver, method, url, async) {
+      return receiver.open(method, url, true);
+    },
+    $isHttpRequest: 1
+  };
+  W.HttpRequest_request_closure.prototype = {
+    call$1: function(e) {
+      var t1, t2, accepted, unknownRedirect, t3;
+      type$.ProgressEvent._as(e);
+      t1 = this.xhr;
+      t2 = t1.status;
+      if (typeof t2 !== "number")
+        return t2.$ge();
+      accepted = t2 >= 200 && t2 < 300;
+      unknownRedirect = t2 > 307 && t2 < 400;
+      t2 = accepted || t2 === 0 || t2 === 304 || unknownRedirect;
+      t3 = this.completer;
+      if (t2)
+        t3.complete$1(t1);
+      else
+        t3.completeError$1(e);
+    },
+    $signature: 40
+  };
+  W.HttpRequestEventTarget.prototype = {};
+  W.MessageEvent.prototype = {$isMessageEvent: 1};
+  W.ProgressEvent.prototype = {$isProgressEvent: 1};
+  W.EventStreamProvider.prototype = {};
+  W._EventStream.prototype = {
+    listen$4$cancelOnError$onDone$onError: function(onData, cancelOnError, onDone, onError) {
+      var t1 = this.$ti;
+      t1._eval$1("~(1)?")._as(onData);
+      type$.nullable_void_Function._as(onDone);
+      return W._EventStreamSubscription$(this._target, this._eventType, onData, false, t1._precomputed1);
+    },
+    listen$3$onDone$onError: function(onData, onDone, onError) {
+      return this.listen$4$cancelOnError$onDone$onError(onData, null, onDone, onError);
+    }
+  };
+  W._EventStreamSubscription.prototype = {
+    cancel$0: function() {
+      var _this = this;
+      if (_this._target == null)
+        return null;
+      _this._unlisten$0();
+      _this._target = null;
+      _this.set$_onData(null);
+      return null;
+    },
+    onData$1: function(handleData) {
+      var t1, _this = this;
+      _this.$ti._eval$1("~(1)?")._as(handleData);
+      if (_this._target == null)
+        throw H.wrapException(P.StateError$("Subscription has been canceled."));
+      _this._unlisten$0();
+      t1 = W._wrapZone(new W._EventStreamSubscription_onData_closure(handleData), type$.Event);
+      _this.set$_onData(t1);
+      _this._tryResume$0();
+    },
+    pause$0: function() {
+      if (this._target == null)
+        return;
+      ++this._pauseCount;
+      this._unlisten$0();
+    },
+    resume$0: function() {
+      var _this = this;
+      if (_this._target == null || _this._pauseCount <= 0)
+        return;
+      --_this._pauseCount;
+      _this._tryResume$0();
+    },
+    _tryResume$0: function() {
+      var t2, _this = this,
+        t1 = _this._onData;
+      if (t1 != null && _this._pauseCount <= 0) {
+        t2 = _this._target;
+        t2.toString;
+        J.addEventListener$3$x(t2, _this._eventType, t1, false);
+      }
+    },
+    _unlisten$0: function() {
+      var t3,
+        t1 = this._onData,
+        t2 = t1 != null;
+      if (t2) {
+        t3 = this._target;
+        t3.toString;
+        type$.nullable_dynamic_Function_Event._as(t1);
+        if (t2)
+          J._removeEventListener$3$x(t3, this._eventType, t1, false);
+      }
+    },
+    set$_onData: function(_onData) {
+      this._onData = type$.nullable_dynamic_Function_Event._as(_onData);
+    }
+  };
+  W._EventStreamSubscription_closure.prototype = {
+    call$1: function(e) {
+      return this.onData.call$1(type$.Event._as(e));
+    },
+    $signature: 17
+  };
+  W._EventStreamSubscription_onData_closure.prototype = {
+    call$1: function(e) {
+      return this.handleData.call$1(type$.Event._as(e));
+    },
+    $signature: 17
+  };
+  P._AcceptStructuredClone.prototype = {
+    findSlot$1: function(value) {
+      var i,
+        t1 = this.values,
+        $length = t1.length;
+      for (i = 0; i < $length; ++i)
+        if (t1[i] === value)
+          return i;
+      C.JSArray_methods.add$1(t1, value);
+      C.JSArray_methods.add$1(this.copies, null);
+      return $length;
+    },
+    walk$1: function(e) {
+      var millisSinceEpoch, t1, proto, slot, copy, t2, l, $length, i, _this = this, _box_0 = {};
+      if (e == null)
+        return e;
+      if (H._isBool(e))
+        return e;
+      if (typeof e == "number")
+        return e;
+      if (typeof e == "string")
+        return e;
+      if (e instanceof Date) {
+        millisSinceEpoch = e.getTime();
+        if (Math.abs(millisSinceEpoch) <= 864e13)
+          t1 = false;
+        else
+          t1 = true;
+        if (t1)
+          H.throwExpression(P.ArgumentError$("DateTime is outside valid range: " + millisSinceEpoch));
+        P.ArgumentError_checkNotNull(true, "isUtc", type$.bool);
+        return new P.DateTime(millisSinceEpoch, true);
+      }
+      if (e instanceof RegExp)
+        throw H.wrapException(P.UnimplementedError$("structured clone of RegExp"));
+      if (typeof Promise != "undefined" && e instanceof Promise)
+        return P.promiseToFuture(e, type$.dynamic);
+      proto = Object.getPrototypeOf(e);
+      if (proto === Object.prototype || proto === null) {
+        slot = _this.findSlot$1(e);
+        t1 = _this.copies;
+        if (slot >= t1.length)
+          return H.ioore(t1, slot);
+        copy = _box_0.copy = t1[slot];
+        if (copy != null)
+          return copy;
+        t2 = type$.dynamic;
+        copy = P.LinkedHashMap_LinkedHashMap$_empty(t2, t2);
+        _box_0.copy = copy;
+        C.JSArray_methods.$indexSet(t1, slot, copy);
+        _this.forEachJsField$2(e, new P._AcceptStructuredClone_walk_closure(_box_0, _this));
+        return _box_0.copy;
+      }
+      if (e instanceof Array) {
+        l = e;
+        slot = _this.findSlot$1(l);
+        t1 = _this.copies;
+        if (slot >= t1.length)
+          return H.ioore(t1, slot);
+        copy = t1[slot];
+        if (copy != null)
+          return copy;
+        t2 = J.getInterceptor$asx(l);
+        $length = t2.get$length(l);
+        copy = _this.mustCopy ? new Array($length) : l;
+        C.JSArray_methods.$indexSet(t1, slot, copy);
+        for (t1 = J.getInterceptor$ax(copy), i = 0; i < $length; ++i)
+          t1.$indexSet(copy, i, _this.walk$1(t2.$index(l, i)));
+        return copy;
+      }
+      return e;
+    },
+    convertNativeToDart_AcceptStructuredClone$2$mustCopy: function(object, mustCopy) {
+      this.mustCopy = true;
+      return this.walk$1(object);
+    }
+  };
+  P._AcceptStructuredClone_walk_closure.prototype = {
+    call$2: function(key, value) {
+      var t1 = this._box_0.copy,
+        t2 = this.$this.walk$1(value);
+      J.$indexSet$ax(t1, key, t2);
+      return t2;
+    },
+    $signature: 47
+  };
+  P.convertDartToNative_Dictionary_closure.prototype = {
+    call$2: function(key, value) {
+      this.object[key] = value;
+    },
+    $signature: 51
+  };
+  P._AcceptStructuredCloneDart2Js.prototype = {
+    forEachJsField$2: function(object, action) {
+      var t1, t2, _i, key;
+      type$.dynamic_Function_dynamic_dynamic._as(action);
+      for (t1 = Object.keys(object), t2 = t1.length, _i = 0; _i < t1.length; t1.length === t2 || (0, H.throwConcurrentModificationError)(t1), ++_i) {
+        key = t1[_i];
+        action.call$2(key, object[key]);
+      }
+    }
+  };
+  P.promiseToFuture_closure.prototype = {
+    call$1: function(r) {
+      return this.completer.complete$1(this.T._eval$1("0/?")._as(r));
+    },
+    $signature: 2
+  };
+  P.promiseToFuture_closure0.prototype = {
+    call$1: function(e) {
+      return this.completer.completeError$1(e);
+    },
+    $signature: 2
+  };
+  P._JSRandom.prototype = {
+    nextDouble$0: function() {
+      return Math.random();
+    }
+  };
+  P.ByteBuffer.prototype = {};
+  P.ByteData.prototype = {};
+  P.Int8List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Uint8List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Uint8ClampedList.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Int16List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Uint16List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Int32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Uint32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Float32List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  P.Float64List.prototype = {$isEfficientLengthIterable: 1, $isIterable: 1, $isList: 1};
+  V.ErrorResult.prototype = {
+    complete$1: function(completer) {
+      completer.completeError$2(this.error, this.stackTrace);
+    },
+    get$hashCode: function(_) {
+      return (J.get$hashCode$(this.error) ^ J.get$hashCode$(this.stackTrace) ^ 492929599) >>> 0;
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof V.ErrorResult && J.$eq$(this.error, other.error) && this.stackTrace == other.stackTrace;
+    },
+    $isResult: 1
+  };
+  E.Result.prototype = {};
+  F.ValueResult.prototype = {
+    complete$1: function(completer) {
+      this.$ti._eval$1("Completer<1*>*")._as(completer).complete$1(this.value);
+    },
+    get$hashCode: function(_) {
+      return (J.get$hashCode$(this.value) ^ 842997089) >>> 0;
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof F.ValueResult && J.$eq$(this.value, other.value);
+    },
+    $isResult: 1
+  };
+  G.StreamQueue.prototype = {
+    get$next: function() {
+      var t1 = this.$ti,
+        t2 = new P._Future($.Zone__current, t1._eval$1("_Future<1*>"));
+      this._addRequest$1(new G._NextRequest(new P._AsyncCompleter(t2, t1._eval$1("_AsyncCompleter<1*>")), t1._eval$1("_NextRequest<1*>")));
+      return t2;
+    },
+    _updateRequests$0: function() {
+      var t1, t2, t3, t4, _this = this;
+      for (t1 = _this._requestQueue, t2 = _this._eventQueue; !t1.get$isEmpty(t1);) {
+        t3 = t1._head;
+        if (t3 === t1._tail)
+          H.throwExpression(H.IterableElementError_noElement());
+        t4 = t1._collection$_table;
+        if (t3 >= t4.length)
+          return H.ioore(t4, t3);
+        if (t4[t3].update$2(t2, _this._isDone)) {
+          t3 = t1._head;
+          if (t3 === t1._tail)
+            H.throwExpression(H.IterableElementError_noElement());
+          ++t1._modificationCount;
+          t4 = t1._collection$_table;
+          if (t3 >= t4.length)
+            return H.ioore(t4, t3);
+          C.JSArray_methods.$indexSet(t4, t3, null);
+          t1._head = (t1._head + 1 & t1._collection$_table.length - 1) >>> 0;
+        } else
+          return;
+      }
+      if (!_this._isDone)
+        _this._subscription.pause$0();
+    },
+    _ensureListening$0: function() {
+      var t1, _this = this;
+      if (_this._isDone)
+        return;
+      t1 = _this._subscription;
+      if (t1 == null)
+        _this.set$_subscription(_this._source.listen$3$onDone$onError(new G.StreamQueue__ensureListening_closure(_this), new G.StreamQueue__ensureListening_closure0(_this), new G.StreamQueue__ensureListening_closure1(_this)));
+      else
+        t1.resume$0();
+    },
+    _addResult$1: function(result) {
+      var t1, _this = this;
+      _this.$ti._eval$1("Result<1*>*")._as(result);
+      ++_this._eventsReceived;
+      t1 = _this._eventQueue;
+      t1._queue_list$_add$1(t1.$ti._eval$1("1*")._as(result));
+      _this._updateRequests$0();
+    },
+    _addRequest$1: function(request) {
+      var t1, t2, t3, t4, newTable, split, _this = this;
+      _this.$ti._eval$1("_EventRequest<1*>*")._as(request);
+      t1 = _this._requestQueue;
+      if (t1._head === t1._tail) {
+        if (request.update$2(_this._eventQueue, _this._isDone))
+          return;
+        _this._ensureListening$0();
+      }
+      t2 = t1.$ti;
+      t2._precomputed1._as(request);
+      C.JSArray_methods.$indexSet(t1._collection$_table, t1._tail, request);
+      t3 = t1._tail;
+      t4 = t1._collection$_table.length;
+      t3 = (t3 + 1 & t4 - 1) >>> 0;
+      t1._tail = t3;
+      if (t1._head === t3) {
+        newTable = P.List_List$filled(t4 * 2, null, false, t2._eval$1("1?"));
+        t2 = t1._collection$_table;
+        t3 = t1._head;
+        split = t2.length - t3;
+        C.JSArray_methods.setRange$4(newTable, 0, split, t2, t3);
+        C.JSArray_methods.setRange$4(newTable, split, split + t1._head, t1._collection$_table, 0);
+        t1._head = 0;
+        t1._tail = t1._collection$_table.length;
+        t1.set$_collection$_table(newTable);
+      }
+      ++t1._modificationCount;
+    },
+    set$_subscription: function(_subscription) {
+      this._subscription = this.$ti._eval$1("StreamSubscription<1*>*")._as(_subscription);
+    }
+  };
+  G.StreamQueue__ensureListening_closure.prototype = {
+    call$1: function(data) {
+      var t1 = this.$this,
+        t2 = t1.$ti;
+      t1._addResult$1(new F.ValueResult(t2._eval$1("1*")._as(data), t2._eval$1("ValueResult<1*>")));
+    },
+    $signature: function() {
+      return this.$this.$ti._eval$1("Null(1*)");
+    }
+  };
+  G.StreamQueue__ensureListening_closure1.prototype = {
+    call$2: function(error, stackTrace) {
+      this.$this._addResult$1(new V.ErrorResult(error, type$.legacy_StackTrace._as(stackTrace)));
+    },
+    "call*": "call$2",
+    $requiredArgCount: 2,
+    $signature: 56
+  };
+  G.StreamQueue__ensureListening_closure0.prototype = {
+    call$0: function() {
+      var t1 = this.$this;
+      t1.set$_subscription(null);
+      t1._isDone = true;
+      t1._updateRequests$0();
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 1
+  };
+  G._EventRequest.prototype = {};
+  G._NextRequest.prototype = {
+    update$2: function(events, isDone) {
+      var t1, t2, result;
+      this.$ti._eval$1("QueueList<Result<1*>*>*")._as(events);
+      if (events.get$length(events) !== 0) {
+        t1 = events._queue_list$_head;
+        if (t1 === events._queue_list$_tail)
+          H.throwExpression(P.StateError$("No element"));
+        t2 = events._table;
+        if (t1 >= t2.length)
+          return H.ioore(t2, t1);
+        result = t2[t1];
+        C.JSArray_methods.$indexSet(t2, t1, null);
+        events._queue_list$_head = (events._queue_list$_head + 1 & events._table.length - 1) >>> 0;
+        result.complete$1(this._completer);
+        return true;
+      }
+      if (isDone) {
+        this._completer.completeError$2(new P.StateError("No elements"), P.StackTrace_current());
+        return true;
+      }
+      return false;
+    },
+    $is_EventRequest: 1
+  };
+  Q.QueueList.prototype = {
+    toString$0: function(_) {
+      return P.IterableBase_iterableToFullString(this, "{", "}");
+    },
+    get$length: function(_) {
+      return (this._queue_list$_tail - this._queue_list$_head & this._table.length - 1) >>> 0;
+    },
+    $index: function(_, index) {
+      var t1, t2, t3, _this = this;
+      H._asIntS(index);
+      if (index < 0 || index >= _this.get$length(_this))
+        throw H.wrapException(P.RangeError$("Index " + index + " must be in the range [0.." + _this.get$length(_this) + ")."));
+      t1 = _this._table;
+      t2 = t1.length;
+      t3 = (_this._queue_list$_head + index & t2 - 1) >>> 0;
+      if (t3 < 0 || t3 >= t2)
+        return H.ioore(t1, t3);
+      return t1[t3];
+    },
+    $indexSet: function(_, index, value) {
+      var t1, _this = this;
+      H._asIntS(index);
+      _this.$ti._eval$1("1*")._as(value);
+      if (typeof index !== "number")
+        return index.$lt();
+      if (index < 0 || index >= _this.get$length(_this))
+        throw H.wrapException(P.RangeError$("Index " + index + " must be in the range [0.." + _this.get$length(_this) + ")."));
+      t1 = _this._table;
+      C.JSArray_methods.$indexSet(t1, (_this._queue_list$_head + index & t1.length - 1) >>> 0, value);
+    },
+    _queue_list$_add$1: function(element) {
+      var t2, t3, newTable, split, _this = this,
+        t1 = _this.$ti;
+      t1._eval$1("1*")._as(element);
+      C.JSArray_methods.$indexSet(_this._table, _this._queue_list$_tail, element);
+      t2 = _this._queue_list$_tail;
+      t3 = _this._table.length;
+      t2 = (t2 + 1 & t3 - 1) >>> 0;
+      _this._queue_list$_tail = t2;
+      if (_this._queue_list$_head === t2) {
+        t2 = new Array(t3 * 2);
+        t2.fixed$length = Array;
+        newTable = H.setRuntimeTypeInfo(t2, t1._eval$1("JSArray<1*>"));
+        t1 = _this._table;
+        t2 = _this._queue_list$_head;
+        split = t1.length - t2;
+        C.JSArray_methods.setRange$4(newTable, 0, split, t1, t2);
+        C.JSArray_methods.setRange$4(newTable, split, split + _this._queue_list$_head, _this._table, 0);
+        _this._queue_list$_head = 0;
+        _this._queue_list$_tail = _this._table.length;
+        _this.set$_table(newTable);
+      }
+    },
+    set$_table: function(_table) {
+      this._table = this.$ti._eval$1("List<1*>*")._as(_table);
+    },
+    $isEfficientLengthIterable: 1,
+    $isQueue: 1,
+    $isIterable: 1,
+    $isList: 1
+  };
+  Q._QueueList_Object_ListMixin.prototype = {};
+  N.HexCodec.prototype = {
+    get$encoder: function() {
+      return C.C_HexEncoder;
+    }
+  };
+  R.HexEncoder.prototype = {
+    convert$1: function(bytes) {
+      type$.legacy_List_legacy_int._as(bytes);
+      return R._convert(bytes, 0, bytes.length);
+    }
+  };
+  Y.Level.prototype = {
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Y.Level && this.value === other.value;
+    },
+    $gt: function(_, other) {
+      return C.JSInt_methods.$gt(this.value, type$.legacy_Level._as(other).get$value());
+    },
+    $ge: function(_, other) {
+      return this.value >= type$.legacy_Level._as(other).value;
+    },
+    get$hashCode: function(_) {
+      return this.value;
+    },
+    toString$0: function(_) {
+      return this.name;
+    }
+  };
+  L.LogRecord0.prototype = {
+    toString$0: function(_) {
+      return "[" + this.level.name + "] " + this.loggerName + ": " + H.S(this.message);
+    }
+  };
+  F.Logger.prototype = {
+    get$fullName: function() {
+      var t1 = this.parent,
+        t2 = t1 == null || t1.name === "",
+        t3 = this.name;
+      return t2 ? t3 : t1.get$fullName() + "." + t3;
+    },
+    get$level: function() {
+      var effectiveLevel, t1;
+      if (this.parent == null)
+        effectiveLevel = this._level;
+      else {
+        t1 = $.$get$Logger_root();
+        effectiveLevel = t1._level;
+      }
+      return effectiveLevel;
+    },
+    log$4: function(logLevel, message, error, stackTrace) {
+      var record, _this = this,
+        t1 = logLevel.value;
+      if (t1 >= _this.get$level().value) {
+        if (t1 >= 2000) {
+          P.StackTrace_current();
+          logLevel.toString$0(0);
+        }
+        t1 = _this.get$fullName();
+        Date.now();
+        $.LogRecord__nextNumber = $.LogRecord__nextNumber + 1;
+        record = new L.LogRecord0(logLevel, message, t1);
+        if (_this.parent == null)
+          _this._publish$1(record);
+        else
+          $.$get$Logger_root()._publish$1(record);
+      }
+    },
+    _publish$1: function(record) {
+    }
+  };
+  F.Logger_Logger_closure.prototype = {
+    call$0: function() {
+      var dot, $parent, t1,
+        thisName = this.name;
+      if (C.JSString_methods.startsWith$1(thisName, "."))
+        H.throwExpression(P.ArgumentError$("name shouldn't start with a '.'"));
+      dot = C.JSString_methods.lastIndexOf$1(thisName, ".");
+      if (dot === -1)
+        $parent = thisName !== "" ? F.Logger_Logger("") : null;
+      else {
+        $parent = F.Logger_Logger(C.JSString_methods.substring$2(thisName, 0, dot));
+        thisName = C.JSString_methods.substring$1(thisName, dot + 1);
+      }
+      t1 = new F.Logger(thisName, $parent, P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.legacy_Logger));
+      if ($parent == null)
+        t1._level = C.Level_INFO_800;
+      else
+        $parent._children.$indexSet(0, thisName, t1);
+      return t1;
+    },
+    $signature: 60
+  };
+  M.SseClient.prototype = {
+    SseClient$1: function(serverUrl) {
+      var t1, t2, t3, t4, _this = this,
+        clientId = K.Uuid$().v1$0();
+      _this._eventSource = W.EventSource__factoryEventSource(H.S(serverUrl) + "?sseClientId=" + clientId, P.LinkedHashMap_LinkedHashMap$_literal(["withCredentials", true], type$.String, type$.dynamic));
+      _this._serverUrl = H.S(serverUrl) + "?sseClientId=" + clientId;
+      t1 = _this._outgoingController;
+      new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>")).listen$2$onDone(_this.get$_onOutgoingMessage(), _this.get$_onOutgoingDone());
+      C.EventSource_methods.addEventListener$2(_this._eventSource, "message", _this.get$_onIncomingMessage());
+      C.EventSource_methods.addEventListener$2(_this._eventSource, "control", _this.get$_onIncomingControlMessage());
+      t1 = _this._eventSource;
+      t2 = type$.nullable_void_Function_legacy_Event;
+      t3 = t2._as(new M.SseClient_closure(_this));
+      type$.nullable_void_Function._as(null);
+      t4 = type$.legacy_Event_2;
+      W._EventStreamSubscription$(t1, "open", t3, false, t4);
+      W._EventStreamSubscription$(_this._eventSource, "error", t2._as(new M.SseClient_closure0(_this)), false, t4);
+      _this._startPostingMessages$0();
+    },
+    close$0: function(_) {
+      this._eventSource.close();
+      this._incomingController.close$0(0);
+      this._outgoingController.close$0(0);
+    },
+    _onIncomingControlMessage$1: function(message) {
+      var data = new P._AcceptStructuredCloneDart2Js([], []).convertNativeToDart_AcceptStructuredClone$2$mustCopy(type$.legacy_MessageEvent._as(type$.legacy_Event_2._as(message)).data, true);
+      if (J.$eq$(data, "close"))
+        this.close$0(0);
+      else
+        throw H.wrapException(P.UnsupportedError$('Illegal Control Message "' + H.S(data) + '"'));
+    },
+    _onIncomingMessage$1: function(message) {
+      this._incomingController.add$1(0, H._asStringS(C.C_JsonCodec.decode$2$reviver(H._asStringS(new P._AcceptStructuredCloneDart2Js([], []).convertNativeToDart_AcceptStructuredClone$2$mustCopy(type$.legacy_MessageEvent._as(type$.legacy_Event_2._as(message)).data, true)), null)));
+    },
+    _onOutgoingDone$0: function() {
+      this.close$0(0);
+    },
+    _onOutgoingMessage$1: function(message) {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic),
+        $async$self = this;
+      var $async$_onOutgoingMessage$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1)
+          return P._asyncRethrow($async$result, $async$completer);
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              $async$self._messages.add$1(0, message);
+              // implicit return
+              return P._asyncReturn(null, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$_onOutgoingMessage$1, $async$completer);
+    },
+    _startPostingMessages$0: function() {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic),
+        $async$handler = 1, $async$currentError, $async$next = [], $async$self = this, message, e, e0, t2, exception, t3, t1, $async$exception, $async$temp1;
+      var $async$_startPostingMessages$0 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1) {
+          $async$currentError = $async$result;
+          $async$goto = $async$handler;
+        }
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              t1 = $async$self._messages;
+              t1 = new P._ControllerStream(t1, H._instanceType(t1)._eval$1("_ControllerStream<1>"));
+              t2 = new P._StreamIterator(t1, type$._StreamIterator_dynamic);
+              P.ArgumentError_checkNotNull(t1, "stream", type$.Stream_dynamic);
+              $async$handler = 2;
+              t1 = $async$self._logger;
+            case 5:
+              // for condition
+              $async$temp1 = H;
+              $async$goto = 7;
+              return P._asyncAwait(t2.moveNext$0(), $async$_startPostingMessages$0);
+            case 7:
+              // returning from await.
+              if (!$async$temp1.boolConversionCheck($async$result)) {
+                // goto after for
+                $async$goto = 6;
+                break;
+              }
+              message = t2.get$current();
+              $async$handler = 9;
+              $async$goto = 12;
+              return P._asyncAwait(W.HttpRequest_request($async$self._serverUrl, "POST", C.C_JsonCodec.encode$2$toEncodable(message, null), true), $async$_startPostingMessages$0);
+            case 12:
+              // returning from await.
+              $async$handler = 2;
+              // goto after finally
+              $async$goto = 11;
+              break;
+            case 9:
+              // catch
+              $async$handler = 8;
+              $async$exception = $async$currentError;
+              t3 = H.unwrapException($async$exception);
+              if (t3 instanceof P.JsonUnsupportedObjectError) {
+                e = t3;
+                t1.log$4(C.Level_WARNING_900, "Unable to encode outgoing message: " + H.S(e), null, null);
+              } else if (t3 instanceof P.ArgumentError) {
+                e0 = t3;
+                t1.log$4(C.Level_WARNING_900, "Invalid argument: " + H.S(e0), null, null);
+              } else
+                throw $async$exception;
+              // goto after finally
+              $async$goto = 11;
+              break;
+            case 8:
+              // uncaught
+              // goto uncaught
+              $async$goto = 2;
+              break;
+            case 11:
+              // after finally
+              // goto for condition
+              $async$goto = 5;
+              break;
+            case 6:
+              // after for
+              $async$next.push(4);
+              // goto finally
+              $async$goto = 3;
+              break;
+            case 2:
+              // uncaught
+              $async$next = [1];
+            case 3:
+              // finally
+              $async$handler = 1;
+              $async$goto = 13;
+              return P._asyncAwait(t2.cancel$0(), $async$_startPostingMessages$0);
+            case 13:
+              // returning from await.
+              // goto the next finally handler
+              $async$goto = $async$next.pop();
+              break;
+            case 4:
+              // after finally
+              // implicit return
+              return P._asyncReturn(null, $async$completer);
+            case 1:
+              // rethrow
+              return P._asyncRethrow($async$currentError, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$_startPostingMessages$0, $async$completer);
+    }
+  };
+  M.SseClient_closure.prototype = {
+    call$1: function(_) {
+      var t1 = this.$this._errorTimer;
+      if (t1 != null)
+        t1.cancel$0();
+    },
+    $signature: 19
+  };
+  M.SseClient_closure0.prototype = {
+    call$1: function(error) {
+      var t1 = this.$this,
+        t2 = t1._errorTimer;
+      t2 = t2 == null ? null : t2._handle != null;
+      if (t2 !== true)
+        t1._errorTimer = P.Timer_Timer(C.Duration_5000000, new M.SseClient__closure(t1, error));
+    },
+    $signature: 19
+  };
+  M.SseClient__closure.prototype = {
+    call$0: function() {
+      var stackTrace, t3,
+        t1 = this.$this,
+        t2 = t1._incomingController,
+        error = this.error;
+      P.ArgumentError_checkNotNull(error, "error", type$.Object);
+      if (t2._state >= 4)
+        H.throwExpression(t2._badEventState$0());
+      stackTrace = P.AsyncError_defaultStackTrace(error);
+      t3 = t2._state;
+      if ((t3 & 1) !== 0)
+        t2._sendError$2(error, stackTrace);
+      else if ((t3 & 3) === 0)
+        t2._ensurePendingEvents$0().add$1(0, new P._DelayedError(error, stackTrace));
+      t1.close$0(0);
+    },
+    $signature: 1
+  };
+  R.StreamChannelMixin.prototype = {};
+  K.Uuid.prototype = {
+    Uuid$1$options: function(_box_0) {
+      var t1, t2, i, hex, t3, v1PositionalArgs, v1NamedArgs, _this = this,
+        _s19_ = "v1rngPositionalArgs",
+        _s14_ = "v1rngNamedArgs",
+        _s18_ = "grngPositionalArgs",
+        _s13_ = "grngNamedArgs",
+        options = _box_0.options;
+      if (!(options != null))
+        options = new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_dynamic);
+      _box_0.options = options;
+      t1 = new Array(256);
+      t1.fixed$length = Array;
+      _this.set$_byteToHex(H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_String));
+      _this.set$_hexToByte(new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_legacy_int));
+      for (t1 = type$.JSArray_legacy_int, t2 = type$.HexCodec._eval$1("Codec.S"), i = 0; i < 256; ++i) {
+        hex = H.setRuntimeTypeInfo([], t1);
+        C.JSArray_methods.add$1(hex, i);
+        t3 = _this._byteToHex;
+        t2._as(hex);
+        (t3 && C.JSArray_methods).$indexSet(t3, i, C.C_HexCodec.get$encoder().convert$1(hex));
+        _this._hexToByte.$indexSet(0, _this._byteToHex[i], i);
+      }
+      v1PositionalArgs = _box_0.options.$index(0, _s19_) != null ? _box_0.options.$index(0, _s19_) : [];
+      v1NamedArgs = _box_0.options.$index(0, _s14_) != null ? type$.legacy_Map_of_legacy_Symbol_and_dynamic._as(_box_0.options.$index(0, _s14_)) : C.Map_empty0;
+      _this._seedBytes = _box_0.options.$index(0, "v1rng") != null ? P.Function_apply(type$.Function._as(_box_0.options.$index(0, "v1rng")), type$.nullable_List_dynamic._as(v1PositionalArgs), v1NamedArgs) : T.UuidUtil_mathRNG();
+      if (_box_0.options.$index(0, _s18_) != null)
+        _box_0.options.$index(0, _s18_);
+      if (_box_0.options.$index(0, _s13_) != null)
+        type$.legacy_Map_of_legacy_Symbol_and_dynamic._as(_box_0.options.$index(0, _s13_));
+      _this._nodeId = [J.$or$bn(J.$index$asx(_this._seedBytes, 0), 1), J.$index$asx(_this._seedBytes, 1), J.$index$asx(_this._seedBytes, 2), J.$index$asx(_this._seedBytes, 3), J.$index$asx(_this._seedBytes, 4), J.$index$asx(_this._seedBytes, 5)];
+      t1 = J.$shl$n(J.$index$asx(_this._seedBytes, 6), 8);
+      t2 = J.$index$asx(_this._seedBytes, 7);
+      if (typeof t2 !== "number")
+        return H.iae(t2);
+      _this._clockSeq = (t1 | t2) & 262143;
+    },
+    v1$0: function() {
+      var t1, buf, options, clockSeq, mSecs, nSecs, dt, t2, tl, tmh, node, n, _this = this,
+        _s8_ = "clockSeq",
+        _s5_ = "nSecs";
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(null);
+      t1 = new Array(16);
+      t1.fixed$length = Array;
+      buf = H.setRuntimeTypeInfo(t1, type$.JSArray_legacy_int);
+      options = new H.JsLinkedHashMap(type$.JsLinkedHashMap_of_legacy_String_and_dynamic);
+      clockSeq = options.$index(0, _s8_) != null ? options.$index(0, _s8_) : _this._clockSeq;
+      mSecs = options.$index(0, "mSecs") != null ? options.$index(0, "mSecs") : Date.now();
+      nSecs = options.$index(0, _s5_) != null ? options.$index(0, _s5_) : _this._lastNSecs + 1;
+      t1 = J.getInterceptor$n(mSecs);
+      dt = J.$add$ansx(t1.$sub(mSecs, _this._lastMSecs), J.$div$n(J.$sub$n(nSecs, _this._lastNSecs), 10000));
+      t2 = J.getInterceptor$n(dt);
+      if (t2.$lt(dt, 0) && options.$index(0, _s8_) == null)
+        clockSeq = J.$and$bn(J.$add$ansx(clockSeq, 1), 16383);
+      if ((t2.$lt(dt, 0) || t1.$gt(mSecs, _this._lastMSecs)) && options.$index(0, _s5_) == null)
+        nSecs = 0;
+      if (J.$ge$n(nSecs, 10000))
+        throw H.wrapException(P.Exception_Exception("uuid.v1(): Can't create more than 10M uuids/sec"));
+      H._asIntS(mSecs);
+      _this._lastMSecs = mSecs;
+      H._asIntS(nSecs);
+      _this._lastNSecs = nSecs;
+      _this._clockSeq = clockSeq;
+      mSecs += 122192928e5;
+      tl = C.JSInt_methods.$mod((mSecs & 268435455) * 10000 + nSecs, 4294967296);
+      C.JSArray_methods.$indexSet(buf, 0, C.JSInt_methods._shrOtherPositive$1(tl, 24) & 255);
+      C.JSArray_methods.$indexSet(buf, 1, C.JSInt_methods._shrOtherPositive$1(tl, 16) & 255);
+      C.JSArray_methods.$indexSet(buf, 2, C.JSInt_methods._shrOtherPositive$1(tl, 8) & 255);
+      C.JSArray_methods.$indexSet(buf, 3, tl & 255);
+      tmh = C.JSDouble_methods.floor$0(mSecs / 4294967296 * 10000) & 268435455;
+      C.JSArray_methods.$indexSet(buf, 4, tmh >>> 8 & 255);
+      C.JSArray_methods.$indexSet(buf, 5, tmh & 255);
+      C.JSArray_methods.$indexSet(buf, 6, tmh >>> 24 & 15 | 16);
+      C.JSArray_methods.$indexSet(buf, 7, tmh >>> 16 & 255);
+      t1 = J.getInterceptor$n(clockSeq);
+      C.JSArray_methods.$indexSet(buf, 8, (t1.$shr(clockSeq, 8) | 128) >>> 0);
+      C.JSArray_methods.$indexSet(buf, 9, H._asIntS(t1.$and(clockSeq, 255)));
+      node = options.$index(0, "node") != null ? options.$index(0, "node") : _this._nodeId;
+      for (t1 = J.getInterceptor$asx(node), n = 0; n < 6; ++n)
+        C.JSArray_methods.$indexSet(buf, 10 + n, H._asIntS(t1.$index(node, n)));
+      type$.legacy_List_legacy_int._as(buf);
+      t1 = _this._byteToHex;
+      t1 = H.S((t1 && C.JSArray_methods).$index(t1, buf[0]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[1]));
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[2]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[3])) + "-";
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[4]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[5])) + "-";
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[6]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[7])) + "-";
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[8]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[9])) + "-";
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[10]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[11]));
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[12]));
+      t2 = _this._byteToHex;
+      t2 = t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[13]));
+      t1 = _this._byteToHex;
+      t1 = t2 + H.S((t1 && C.JSArray_methods).$index(t1, buf[14]));
+      t2 = _this._byteToHex;
+      return t1 + H.S((t2 && C.JSArray_methods).$index(t2, buf[15]));
+    },
+    set$_byteToHex: function(_byteToHex) {
+      this._byteToHex = type$.legacy_List_legacy_String._as(_byteToHex);
+    },
+    set$_hexToByte: function(_hexToByte) {
+      this._hexToByte = type$.legacy_Map_of_legacy_String_and_legacy_int._as(_hexToByte);
+    }
+  };
+  Q.createServiceObject_closure.prototype = {
+    call$1: function(e) {
+      return Q.createServiceObject(e, this.expectedTypes);
+    },
+    $signature: 29
+  };
+  Q._createSpecificObject_closure.prototype = {
+    call$1: function(e) {
+      return this.creator.call$1(type$.legacy_Map_of_legacy_String_and_dynamic._as(e));
+    },
+    $signature: 3
+  };
+  Q.VmService.prototype = {
+    _getEventController$1: function(eventName) {
+      var t1 = this._eventControllers,
+        controller = t1.$index(0, eventName);
+      if (controller == null) {
+        controller = P.StreamController_StreamController$broadcast(false, type$.legacy_Event);
+        t1.$indexSet(0, eventName, controller);
+      }
+      return controller;
+    },
+    VmService$5$disposeHandler$log$streamClosed: function(inStream, writeMessage, disposeHandler, log, streamClosed) {
+      var _this = this;
+      inStream.listen$2$onDone(_this.get$_processMessage(), new Q.VmService_closure(_this));
+      _this._writeMessage = writeMessage;
+      _this._log = new Q._NullLog();
+      _this.set$_disposeHandler(disposeHandler);
+    },
+    _processMessage$1: function(message) {
+      var t1, _this = this;
+      if (typeof message == "string")
+        _this._processMessageStr$1(message);
+      else if (type$.legacy_List_legacy_int._is(message))
+        _this._processMessageByteData$1(H.NativeByteData_NativeByteData$view(new Uint8Array(H._ensureNativeList(message)).buffer, 0, null));
+      else if (type$.legacy_ByteData._is(message))
+        _this._processMessageByteData$1(message);
+      else {
+        t1 = _this._log;
+        J.get$runtimeType$(message).toString$0(0);
+        t1.toString;
+      }
+    },
+    _processMessageByteData$1: function(bytes) {
+      var t2, t3, meta, data, map, streamId, $event,
+        dataOffset = C.NativeByteData_methods._getUint32$2(bytes, 0, true),
+        metaLength = dataOffset - 4,
+        t1 = bytes.byteLength;
+      if (typeof t1 !== "number")
+        return t1.$sub();
+      t2 = bytes.buffer;
+      t3 = bytes.byteOffset;
+      if (typeof t3 !== "number")
+        return t3.$add();
+      t3 += 4;
+      H._checkViewArguments(t2, t3, metaLength);
+      t2 = new Uint8Array(t2, t3, metaLength);
+      type$.List_int._as(t2);
+      meta = C.Utf8Decoder_false.convert$1(t2);
+      t2 = bytes.buffer;
+      t3 = bytes.byteOffset;
+      if (typeof t3 !== "number")
+        return t3.$add();
+      data = H.NativeByteData_NativeByteData$view(t2, t3 + dataOffset, t1 - dataOffset);
+      map = C.C_JsonCodec.decode$2$reviver(meta, null);
+      if (map != null && J.$eq$(J.$index$asx(map, "method"), "streamNotify")) {
+        t1 = J.getInterceptor$asx(map);
+        streamId = H._asStringS(J.$index$asx(t1.$index(map, "params"), "streamId"));
+        $event = type$.legacy_Map_dynamic_dynamic._as(J.$index$asx(t1.$index(map, "params"), "event"));
+        $event.$indexSet(0, "data", data);
+        this._getEventController$1(streamId).add$1(0, type$.legacy_Event._as(Q.createServiceObject($event, C.List_Event)));
+      }
+    },
+    _processMessageStr$1: function(message) {
+      var e, s, exception, t1, t2, completer, methodName, returnTypes, result, type, _this = this, _s2_ = "id", _s5_ = "error", json = null;
+      try {
+        _this._onReceive.add$1(0, message);
+        json = C.C_JsonCodec.decode$2$reviver(message, null);
+      } catch (exception) {
+        e = H.unwrapException(exception);
+        s = H.getTraceFromException(exception);
+        t1 = _this._log;
+        H.S(e);
+        H.S(s);
+        t1.toString;
+        return;
+      }
+      if (json.containsKey$1("method")) {
+        t1 = type$.legacy_Map_of_legacy_String_and_dynamic;
+        if (json.containsKey$1(_s2_))
+          _this._processRequest$1(t1._as(json));
+        else
+          _this._processNotification$1(t1._as(json));
+      } else {
+        if (json.containsKey$1(_s2_))
+          t1 = json.containsKey$1("result") || json.containsKey$1(_s5_);
+        else
+          t1 = false;
+        if (t1) {
+          t1 = type$.legacy_Map_of_legacy_String_and_dynamic;
+          t2 = t1._as(json);
+          completer = _this._completers.remove$1(0, t2.$index(0, _s2_));
+          methodName = _this._methodCalls.remove$1(0, t2.$index(0, _s2_));
+          returnTypes = $._methodReturnTypes.$index(0, methodName);
+          if (completer == null) {
+            t1 = _this._log;
+            C.C_JsonCodec.encode$2$toEncodable(t2, null);
+            t1.toString;
+          } else if (t2.$index(0, _s5_) != null) {
+            t1 = t2.$index(0, _s5_);
+            t2 = J.getInterceptor$asx(t1);
+            completer.completeError$1(new Q.RPCError(methodName, H._asIntS(t2.$index(t1, "code")), H._asStringS(t2.$index(t1, "message")), type$.legacy_Map_dynamic_dynamic._as(t2.$index(t1, "data"))));
+          } else {
+            result = t1._as(t2.$index(0, "result"));
+            type = H._asStringS(result.$index(0, "type"));
+            if (type === "Sentinel") {
+              t1 = Q.Sentinel$_fromJson(result);
+              completer.completeError$1(new Q.SentinelException(methodName, t1));
+            } else if ($._typeFactories.$index(0, type) == null) {
+              t1 = Q.Response$_fromJson(result);
+              completer.complete$1(t1);
+            } else
+              completer.complete$1(Q.createServiceObject(result, returnTypes));
+          }
+        } else
+          _this._log.toString;
+      }
+    },
+    _processRequest$1: function(json) {
+      return this._processRequest$body$VmService(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+    },
+    _processRequest$body$VmService: function(json) {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic),
+        $async$self = this, m, message, t1, t2;
+      var $async$_processRequest$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1)
+          return P._asyncRethrow($async$result, $async$completer);
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              t1 = H._asStringS(json.$index(0, "method"));
+              t2 = json.$index(0, "params");
+              if (t2 == null)
+                t2 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic);
+              $async$goto = 2;
+              return P._asyncAwait($async$self._routeRequest$2(t1, type$.legacy_Map_of_legacy_String_and_dynamic._as(t2)), $async$_processRequest$1);
+            case 2:
+              // returning from await.
+              m = $async$result;
+              m.$indexSet(0, "id", json.$index(0, "id"));
+              m.$indexSet(0, "jsonrpc", "2.0");
+              message = C.C_JsonCodec.encode$2$toEncodable(m, null);
+              $async$self._onSend.add$1(0, message);
+              $async$self._writeMessage.call$1(message);
+              // implicit return
+              return P._asyncReturn(null, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$_processRequest$1, $async$completer);
+    },
+    _processNotification$1: function(json) {
+      return this._processNotification$body$VmService(type$.legacy_Map_of_legacy_String_and_dynamic._as(json));
+    },
+    _processNotification$body$VmService: function(json) {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.dynamic),
+        $async$self = this, method, t1;
+      var $async$_processNotification$1 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1)
+          return P._asyncRethrow($async$result, $async$completer);
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              method = H._asStringS(json.$index(0, "method"));
+              t1 = json.$index(0, "params");
+              if (t1 == null)
+                t1 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic);
+              type$.legacy_Map_dynamic_dynamic._as(t1);
+              $async$goto = method === "streamNotify" ? 2 : 4;
+              break;
+            case 2:
+              // then
+              $async$self._getEventController$1(H._asStringS(t1.$index(0, "streamId"))).add$1(0, type$.legacy_Event._as(Q.createServiceObject(t1.$index(0, "event"), C.List_Event)));
+              // goto join
+              $async$goto = 3;
+              break;
+            case 4:
+              // else
+              $async$goto = 5;
+              return P._asyncAwait($async$self._routeRequest$2(method, type$.legacy_Map_of_legacy_String_and_dynamic._as(t1)), $async$_processNotification$1);
+            case 5:
+              // returning from await.
+            case 3:
+              // join
+              // implicit return
+              return P._asyncReturn(null, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$_processNotification$1, $async$completer);
+    },
+    _routeRequest$2: function(method, params) {
+      type$.legacy_Map_of_legacy_String_and_dynamic._as(params);
+      return this._routeRequest$body$VmService(method, params);
+    },
+    _routeRequest$body$VmService: function(method, params) {
+      var $async$goto = 0,
+        $async$completer = P._makeAsyncAwaitCompleter(type$.legacy_Map_dynamic_dynamic),
+        $async$returnValue, $async$handler = 2, $async$currentError, $async$next = [], $async$self = this, e, st, error, exception, t2, t3, t4, t1, $async$exception;
+      var $async$_routeRequest$2 = P._wrapJsFunctionForAsync(function($async$errorCode, $async$result) {
+        if ($async$errorCode === 1) {
+          $async$currentError = $async$result;
+          $async$goto = $async$handler;
+        }
+        while (true)
+          switch ($async$goto) {
+            case 0:
+              // Function start
+              t1 = $async$self._services;
+              if (!t1.containsKey$1(method)) {
+                t1 = type$.dynamic;
+                $async$returnValue = P.LinkedHashMap_LinkedHashMap$_literal(["error", new Q.RPCError(method, -32601, "method not found '" + H.S(method) + "'", null).toMap$0()], t1, t1);
+                // goto return
+                $async$goto = 1;
+                break;
+              }
+              $async$handler = 4;
+              $async$goto = 7;
+              return P._asyncAwait(t1.$index(0, method).call$1(params), $async$_routeRequest$2);
+            case 7:
+              // returning from await.
+              t1 = $async$result;
+              $async$returnValue = t1;
+              // goto return
+              $async$goto = 1;
+              break;
+              $async$handler = 2;
+              // goto after finally
+              $async$goto = 6;
+              break;
+            case 4:
+              // catch
+              $async$handler = 3;
+              $async$exception = $async$currentError;
+              e = H.unwrapException($async$exception);
+              st = H.getTraceFromException($async$exception);
+              t1 = H.S(e);
+              t2 = H.S(st);
+              t3 = type$.dynamic;
+              t4 = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, t3);
+              t4.$indexSet(0, "details", t2);
+              error = new Q.RPCError(method, -32000, t1, t4);
+              $async$returnValue = P.LinkedHashMap_LinkedHashMap$_literal(["error", error.toMap$0()], t3, t3);
+              // goto return
+              $async$goto = 1;
+              break;
+              // goto after finally
+              $async$goto = 6;
+              break;
+            case 3:
+              // uncaught
+              // goto rethrow
+              $async$goto = 2;
+              break;
+            case 6:
+              // after finally
+            case 1:
+              // return
+              return P._asyncReturn($async$returnValue, $async$completer);
+            case 2:
+              // rethrow
+              return P._asyncRethrow($async$currentError, $async$completer);
+          }
+      });
+      return P._asyncStartSync($async$_routeRequest$2, $async$completer);
+    },
+    set$_disposeHandler: function(_disposeHandler) {
+      type$.legacy_legacy_Future_dynamic_Function._as(_disposeHandler);
+    }
+  };
+  Q.VmService_closure.prototype = {
+    call$0: function() {
+      return this.$this._onDoneCompleter.complete$0();
+    },
+    "call*": "call$0",
+    $requiredArgCount: 0,
+    $signature: 0
+  };
+  Q.RPCError.prototype = {
+    get$details: function() {
+      var t1 = this.data;
+      return H._asStringS(t1 == null ? null : t1.$index(0, "details"));
+    },
+    toMap$0: function() {
+      var map = P.LinkedHashMap_LinkedHashMap$_literal(["code", this.code, "message", this.message], type$.legacy_String, type$.dynamic),
+        t1 = this.data;
+      if (t1 != null)
+        map.$indexSet(0, "data", t1);
+      return map;
+    },
+    toString$0: function(_) {
+      var _this = this,
+        t1 = _this.callingMethod,
+        t2 = _this.code,
+        t3 = _this.message;
+      if (_this.get$details() == null)
+        return H.S(t1) + ": (" + H.S(t2) + ") " + H.S(t3);
+      else
+        return H.S(t1) + ": (" + H.S(t2) + ") " + H.S(t3) + "\n" + H.S(_this.get$details());
+    }
+  };
+  Q.SentinelException.prototype = {
+    toString$0: function(_) {
+      return H.S(this.sentinel) + " from " + H.S(this.callingMethod) + "()";
+    }
+  };
+  Q.ExtensionData.prototype = {
+    toString$0: function(_) {
+      return "[ExtensionData " + this.data.toString$0(0) + "]";
+    }
+  };
+  Q._NullLog.prototype = {$isLog: 1};
+  Q.AllocationProfile.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "AllocationProfile");
+      t3 = _this.members;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["members", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.AllocationProfile_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")), "memoryUsage", _this.memoryUsage.toJson$0()], t1, t2));
+      Q._setIfNotNull(json, "dateLastAccumulatorReset", _this.dateLastAccumulatorReset);
+      Q._setIfNotNull(json, "dateLastServiceGC", _this.dateLastServiceGC);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[AllocationProfile type: " + H.S(this.type) + ", members: " + H.S(this.members) + ", memoryUsage: " + H.S(this.memoryUsage) + "]";
+    },
+    set$members: function(members) {
+      this.members = type$.legacy_List_legacy_ClassHeapStats._as(members);
+    }
+  };
+  Q.AllocationProfile_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ClassHeapStats._as(f).toJson$0();
+    },
+    $signature: 30
+  };
+  Q.BoundField.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["decl", this.decl.toJson$0(), "value", this.value.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[BoundField decl: " + H.S(this.decl) + ", value: " + H.S(this.value) + "]";
+    }
+  };
+  Q.BoundVariable.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "BoundVariable");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "value", _this.value.toJson$0(), "declarationTokenPos", _this.declarationTokenPos, "scopeStartTokenPos", _this.scopeStartTokenPos, "scopeEndTokenPos", _this.scopeEndTokenPos], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[BoundVariable type: " + H.S(_this.type) + ", name: " + H.S(_this.name) + ", value: " + H.S(_this.value) + ", declarationTokenPos: " + H.S(_this.declarationTokenPos) + ", scopeStartTokenPos: " + H.S(_this.scopeStartTokenPos) + ", scopeEndTokenPos: " + H.S(_this.scopeEndTokenPos) + "]";
+    }
+  };
+  Q.Breakpoint.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Breakpoint");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["breakpointNumber", _this.breakpointNumber, "resolved", _this.resolved, "location", _this.location.toJson$0()], type$.legacy_String, type$.dynamic));
+      Q._setIfNotNull(json, "isSyntheticAsyncContinuation", _this.isSyntheticAsyncContinuation);
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Breakpoint && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Breakpoint type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", breakpointNumber: " + H.S(_this.breakpointNumber) + ", resolved: " + H.S(_this.resolved) + ", location: " + H.S(_this.location) + "]";
+    }
+  };
+  Q.ClassRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Class");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_ClassRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[ClassRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", name: " + H.S(this.name) + "]";
+    }
+  };
+  Q.Class.prototype = {
+    toJson$0: function() {
+      var t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, _this = this, _null = null,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Class");
+      t1 = _this.name;
+      t2 = _this.isAbstract;
+      t3 = _this.isConst;
+      t4 = _this.library.toJson$0();
+      t5 = _this.interfaces;
+      t5.toString;
+      t6 = H._arrayInstanceType(t5);
+      t7 = t6._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t7 = P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map<String*,@>*(1)")._as(new Q.Class_toJson_closure()), t7), true, t7._eval$1("ListIterable.E"));
+      t6 = _this.fields;
+      t6.toString;
+      t5 = H._arrayInstanceType(t6);
+      t8 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t8 = P.List_List$from(new H.MappedListIterable(t6, t5._eval$1("Map<String*,@>*(1)")._as(new Q.Class_toJson_closure0()), t8), true, t8._eval$1("ListIterable.E"));
+      t5 = _this.functions;
+      t5.toString;
+      t6 = H._arrayInstanceType(t5);
+      t9 = t6._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t9 = P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map<String*,@>*(1)")._as(new Q.Class_toJson_closure1()), t9), true, t9._eval$1("ListIterable.E"));
+      t6 = _this.subclasses;
+      t6.toString;
+      t5 = H._arrayInstanceType(t6);
+      t10 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "abstract", t2, "const", t3, "library", t4, "interfaces", t7, "fields", t8, "functions", t9, "subclasses", P.List_List$from(new H.MappedListIterable(t6, t5._eval$1("Map<String*,@>*(1)")._as(new Q.Class_toJson_closure2()), t10), true, t10._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic));
+      t10 = _this.error;
+      Q._setIfNotNull(json, "error", t10 == null ? _null : t10.toJson$0());
+      t1 = _this.location;
+      Q._setIfNotNull(json, "location", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.superClass;
+      Q._setIfNotNull(json, "super", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.superType;
+      Q._setIfNotNull(json, "superType", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.mixin;
+      Q._setIfNotNull(json, "mixin", t1 == null ? _null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Class && this.id == other.id;
+    },
+    toString$0: function(_) {
+      return "[Class]";
+    },
+    set$interfaces: function(interfaces) {
+      this.interfaces = type$.legacy_List_legacy_InstanceRef._as(interfaces);
+    },
+    set$fields: function(fields) {
+      this.fields = type$.legacy_List_legacy_FieldRef._as(fields);
+    },
+    set$functions: function(functions) {
+      this.functions = type$.legacy_List_legacy_FuncRef._as(functions);
+    },
+    set$subclasses: function(subclasses) {
+      this.subclasses = type$.legacy_List_legacy_ClassRef._as(subclasses);
+    },
+    $isClassRef: 1
+  };
+  Q.Class_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_InstanceRef._as(f).toJson$0();
+    },
+    $signature: 20
+  };
+  Q.Class_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_FieldRef._as(f).toJson$0();
+    },
+    $signature: 21
+  };
+  Q.Class_toJson_closure1.prototype = {
+    call$1: function(f) {
+      return type$.legacy_FuncRef._as(f).toJson$0();
+    },
+    $signature: 22
+  };
+  Q.Class_toJson_closure2.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ClassRef._as(f).toJson$0();
+    },
+    $signature: 8
+  };
+  Q.ClassHeapStats.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "ClassHeapStats");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["class", _this.classRef.toJson$0(), "accumulatedSize", _this.accumulatedSize, "bytesCurrent", _this.bytesCurrent, "instancesAccumulated", _this.instancesAccumulated, "instancesCurrent", _this.instancesCurrent], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[ClassHeapStats type: " + H.S(_this.type) + ", classRef: " + H.S(_this.classRef) + ", accumulatedSize: " + H.S(_this.accumulatedSize) + ", bytesCurrent: " + H.S(_this.bytesCurrent) + ", instancesAccumulated: " + H.S(_this.instancesAccumulated) + ", instancesCurrent: " + H.S(_this.instancesCurrent) + "]";
+    }
+  };
+  Q.ClassList.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "ClassList");
+      t3 = this.classes;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["classes", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.ClassList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[ClassList type: " + H.S(this.type) + ", classes: " + H.S(this.classes) + "]";
+    },
+    set$classes: function(classes) {
+      this.classes = type$.legacy_List_legacy_ClassRef._as(classes);
+    }
+  };
+  Q.ClassList_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ClassRef._as(f).toJson$0();
+    },
+    $signature: 8
+  };
+  Q.ClientName.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "ClientName");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[ClientName type: " + H.S(this.type) + ", name: " + H.S(this.name) + "]";
+    }
+  };
+  Q.CodeRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Code");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "kind", this.kind], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_CodeRef._is(other) && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[CodeRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", kind: " + H.S(_this.kind) + "]";
+    }
+  };
+  Q.Code.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "Code");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "kind", this.kind], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Code && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Code type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", kind: " + H.S(_this.kind) + "]";
+    },
+    $isCodeRef: 1
+  };
+  Q.ContextRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Context");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", this.length], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_ContextRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[ContextRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", length: " + H.S(this.length) + "]";
+    },
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  Q.Context.prototype = {
+    toJson$0: function() {
+      var t1, t2, t3, t4, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Context");
+      t1 = _this.length;
+      t2 = _this.variables;
+      t2.toString;
+      t3 = H._arrayInstanceType(t2);
+      t4 = t3._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", t1, "variables", P.List_List$from(new H.MappedListIterable(t2, t3._eval$1("Map<String*,@>*(1)")._as(new Q.Context_toJson_closure()), t4), true, t4._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic));
+      t4 = _this.parent;
+      Q._setIfNotNull(json, "parent", t4 == null ? null : t4.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Context && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Context type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", length: " + H.S(_this.length) + ", variables: " + H.S(_this.variables) + "]";
+    },
+    set$variables: function(variables) {
+      this.variables = type$.legacy_List_legacy_ContextElement._as(variables);
+    },
+    $isContextRef: 1,
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  Q.Context_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ContextElement._as(f).toJson$0();
+    },
+    $signature: 35
+  };
+  Q.ContextElement.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["value", this.value.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[ContextElement value: " + H.S(this.value) + "]";
+    }
+  };
+  Q.CpuSamples.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "CpuSamples");
+      t3 = _this.samplePeriod;
+      t4 = _this.maxStackDepth;
+      t5 = _this.sampleCount;
+      t6 = _this.timeSpan;
+      t7 = _this.timeOriginMicros;
+      t8 = _this.timeExtentMicros;
+      t9 = _this.pid;
+      t10 = _this.functions;
+      t10.toString;
+      t11 = H._arrayInstanceType(t10);
+      t12 = t11._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t12 = P.List_List$from(new H.MappedListIterable(t10, t11._eval$1("Map<String*,@>*(1)")._as(new Q.CpuSamples_toJson_closure()), t12), true, t12._eval$1("ListIterable.E"));
+      t11 = _this.samples;
+      t11.toString;
+      t10 = H._arrayInstanceType(t11);
+      t13 = t10._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["samplePeriod", t3, "maxStackDepth", t4, "sampleCount", t5, "timeSpan", t6, "timeOriginMicros", t7, "timeExtentMicros", t8, "pid", t9, "functions", t12, "samples", P.List_List$from(new H.MappedListIterable(t11, t10._eval$1("Map<String*,@>*(1)")._as(new Q.CpuSamples_toJson_closure0()), t13), true, t13._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[CpuSamples]";
+    },
+    set$functions: function(functions) {
+      this.functions = type$.legacy_List_legacy_ProfileFunction._as(functions);
+    },
+    set$samples: function(samples) {
+      this.samples = type$.legacy_List_legacy_CpuSample._as(samples);
+    }
+  };
+  Q.CpuSamples_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ProfileFunction._as(f).toJson$0();
+    },
+    $signature: 36
+  };
+  Q.CpuSamples_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_CpuSample._as(f).toJson$0();
+    },
+    $signature: 37
+  };
+  Q.CpuSample.prototype = {
+    toJson$0: function() {
+      var t6, t7, _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2),
+        t3 = _this.tid,
+        t4 = _this.timestamp,
+        t5 = _this.stack;
+      t5.toString;
+      t6 = H._arrayInstanceType(t5);
+      t7 = t6._eval$1("MappedListIterable<1,int*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["tid", t3, "timestamp", t4, "stack", P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("int*(1)")._as(new Q.CpuSample_toJson_closure()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2));
+      Q._setIfNotNull(json, "vmTag", _this.vmTag);
+      Q._setIfNotNull(json, "userTag", _this.userTag);
+      Q._setIfNotNull(json, "truncated", _this.truncated);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[CpuSample tid: " + H.S(this.tid) + ", timestamp: " + H.S(this.timestamp) + ", stack: " + H.S(this.stack) + "]";
+    },
+    set$stack: function(stack) {
+      this.stack = type$.legacy_List_legacy_int._as(stack);
+    }
+  };
+  Q.CpuSample_toJson_closure.prototype = {
+    call$1: function(f) {
+      return H._asIntS(f);
+    },
+    $signature: 4
+  };
+  Q.ErrorRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Error");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", this.kind, "message", this.message], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_ErrorRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[ErrorRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", message: " + H.S(_this.message) + "]";
+    }
+  };
+  Q.Error.prototype = {
+    toJson$0: function() {
+      var t1, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Error");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "message", _this.message], type$.legacy_String, type$.dynamic));
+      t1 = _this.exception;
+      Q._setIfNotNull(json, "exception", t1 == null ? null : t1.toJson$0());
+      t1 = _this.stacktrace;
+      Q._setIfNotNull(json, "stacktrace", t1 == null ? null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Error && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Error type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", message: " + H.S(_this.message) + "]";
+    },
+    $isErrorRef: 1
+  };
+  Q.Event.prototype = {
+    toJson$0: function() {
+      var _this = this, _null = null,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Event");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "timestamp", _this.timestamp], t1, t2));
+      t2 = _this.isolate;
+      Q._setIfNotNull(json, "isolate", t2 == null ? _null : t2.toJson$0());
+      t1 = _this.vm;
+      Q._setIfNotNull(json, "vm", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.breakpoint;
+      Q._setIfNotNull(json, "breakpoint", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.pauseBreakpoints;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Event_toJson_closure()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "pauseBreakpoints", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      t1 = _this.topFrame;
+      Q._setIfNotNull(json, "topFrame", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.exception;
+      Q._setIfNotNull(json, "exception", t1 == null ? _null : t1.toJson$0());
+      Q._setIfNotNull(json, "bytes", _this.bytes);
+      t1 = _this.inspectee;
+      Q._setIfNotNull(json, "inspectee", t1 == null ? _null : t1.toJson$0());
+      Q._setIfNotNull(json, "extensionRPC", _this.extensionRPC);
+      Q._setIfNotNull(json, "extensionKind", _this.extensionKind);
+      t1 = _this.extensionData;
+      Q._setIfNotNull(json, "extensionData", t1 == null ? _null : t1.data);
+      t1 = _this.timelineEvents;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Event_toJson_closure0()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "timelineEvents", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      t1 = _this.updatedStreams;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("String*(1)")._as(new Q.Event_toJson_closure1()), t2._eval$1("MappedListIterable<1,String*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "updatedStreams", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      Q._setIfNotNull(json, "atAsyncSuspension", _this.atAsyncSuspension);
+      Q._setIfNotNull(json, "status", _this.status);
+      t1 = _this.logRecord;
+      Q._setIfNotNull(json, "logRecord", t1 == null ? _null : t1.toJson$0());
+      Q._setIfNotNull(json, "service", _this.service);
+      Q._setIfNotNull(json, "method", _this.method);
+      Q._setIfNotNull(json, "alias", _this.alias);
+      Q._setIfNotNull(json, "flag", _this.flag);
+      Q._setIfNotNull(json, "newValue", _this.newValue);
+      Q._setIfNotNull(json, "last", _this.last);
+      Q._setIfNotNull(json, "data", _this.data);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Event type: " + H.S(this.type) + ", kind: " + H.S(this.kind) + ", timestamp: " + H.S(this.timestamp) + "]";
+    },
+    set$pauseBreakpoints: function(pauseBreakpoints) {
+      this.pauseBreakpoints = type$.legacy_List_legacy_Breakpoint._as(pauseBreakpoints);
+    },
+    set$timelineEvents: function(timelineEvents) {
+      this.timelineEvents = type$.legacy_List_legacy_TimelineEvent._as(timelineEvents);
+    },
+    set$updatedStreams: function(updatedStreams) {
+      this.updatedStreams = type$.legacy_List_legacy_String._as(updatedStreams);
+    }
+  };
+  Q.Event_toJson_closure.prototype = {
+    call$1: function(f) {
+      type$.legacy_Breakpoint._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 23
+  };
+  Q.Event_toJson_closure0.prototype = {
+    call$1: function(f) {
+      type$.legacy_TimelineEvent._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 24
+  };
+  Q.Event_toJson_closure1.prototype = {
+    call$1: function(f) {
+      return H._asStringS(f);
+    },
+    $signature: 5
+  };
+  Q.FieldRef.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        json = _this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Field");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "declaredType", _this.declaredType.toJson$0(), "const", _this.isConst, "final", _this.isFinal, "static", _this.isStatic], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_FieldRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[FieldRef]";
+    }
+  };
+  Q.Field.prototype = {
+    toJson$0: function() {
+      var t1, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Field");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "declaredType", _this.declaredType.toJson$0(), "const", _this.isConst, "final", _this.isFinal, "static", _this.isStatic], type$.legacy_String, type$.dynamic));
+      t1 = _this.staticValue;
+      Q._setIfNotNull(json, "staticValue", t1 == null ? null : t1.toJson$0());
+      t1 = _this.location;
+      Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Field && this.id == other.id;
+    },
+    toString$0: function(_) {
+      return "[Field]";
+    },
+    $isFieldRef: 1
+  };
+  Q.Flag.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "comment", _this.comment, "modified", _this.modified], t1, t2));
+      Q._setIfNotNull(json, "valueAsString", _this.valueAsString);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Flag name: " + H.S(this.name) + ", comment: " + H.S(this.comment) + ", modified: " + H.S(this.modified) + "]";
+    }
+  };
+  Q.FlagList.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "FlagList");
+      t3 = this.flags;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["flags", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.FlagList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[FlagList type: " + H.S(this.type) + ", flags: " + H.S(this.flags) + "]";
+    },
+    set$flags: function(flags) {
+      this.flags = type$.legacy_List_legacy_Flag._as(flags);
+    }
+  };
+  Q.FlagList_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_Flag._as(f).toJson$0();
+    },
+    $signature: 42
+  };
+  Q.Frame.prototype = {
+    toJson$0: function() {
+      var _this = this, _null = null,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Frame");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["index", _this.index], t1, t2));
+      t2 = _this.$function;
+      Q._setIfNotNull(json, "function", t2 == null ? _null : t2.toJson$0());
+      t1 = _this.code;
+      Q._setIfNotNull(json, "code", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.location;
+      Q._setIfNotNull(json, "location", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.vars;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Frame_toJson_closure()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "vars", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      Q._setIfNotNull(json, "kind", _this.kind);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Frame type: " + H.S(this.type) + ", index: " + H.S(this.index) + "]";
+    },
+    set$vars: function(vars) {
+      this.vars = type$.legacy_List_legacy_BoundVariable._as(vars);
+    }
+  };
+  Q.Frame_toJson_closure.prototype = {
+    call$1: function(f) {
+      type$.legacy_BoundVariable._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 43
+  };
+  Q.FuncRef.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        json = _this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Function");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "static", _this.isStatic, "const", _this.isConst], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_FuncRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[FuncRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", owner: " + H.S(_this.owner) + ", isStatic: " + H.S(_this.isStatic) + ", isConst: " + H.S(_this.isConst) + "]";
+    }
+  };
+  Q.Func.prototype = {
+    toJson$0: function() {
+      var t1, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Function");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", _this.name, "owner", _this.owner.toJson$0(), "static", _this.isStatic, "const", _this.isConst], type$.legacy_String, type$.dynamic));
+      t1 = _this.location;
+      Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0());
+      t1 = _this.code;
+      Q._setIfNotNull(json, "code", t1 == null ? null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Func && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Func type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", owner: " + H.S(_this.owner) + ", isStatic: " + H.S(_this.isStatic) + ", isConst: " + H.S(_this.isConst) + "]";
+    },
+    $isFuncRef: 1
+  };
+  Q.InstanceRef.prototype = {
+    InstanceRef$_fromJson$1: function(json) {
+      var t1, t2, _this = this;
+      _this.kind = H._asStringS(json.$index(0, "kind"));
+      t1 = type$.legacy_ClassRef;
+      _this.classRef = t1._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef));
+      _this.set$valueAsString(H._asStringS(json.$index(0, "valueAsString")));
+      t2 = json.$index(0, "valueAsStringIsTruncated");
+      _this.valueAsStringIsTruncated = H._asBoolS(t2 == null ? false : t2);
+      _this.length = H._asIntS(json.$index(0, "length"));
+      _this.name = H._asStringS(json.$index(0, "name"));
+      _this.typeClass = t1._as(Q.createServiceObject(json.$index(0, "typeClass"), C.List_ClassRef));
+      _this.parameterizedClass = t1._as(Q.createServiceObject(json.$index(0, "parameterizedClass"), C.List_ClassRef));
+      _this.pattern = type$.legacy_InstanceRef._as(Q.createServiceObject(json.$index(0, "pattern"), C.List_InstanceRef));
+      _this.closureFunction = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "closureFunction"), C.List_FuncRef));
+      _this.closureContext = type$.legacy_ContextRef._as(Q.createServiceObject(json.$index(0, "closureContext"), C.List_ContextRef));
+    },
+    toJson$0: function() {
+      var t1, _this = this, _null = null,
+        json = _this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Instance");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "class", _this.classRef.toJson$0()], type$.legacy_String, type$.dynamic));
+      Q._setIfNotNull(json, "valueAsString", _this.get$valueAsString());
+      t1 = _this.valueAsStringIsTruncated;
+      Q._setIfNotNull(json, "valueAsStringIsTruncated", t1 === true);
+      Q._setIfNotNull(json, "length", _this.length);
+      Q._setIfNotNull(json, "name", _this.name);
+      t1 = _this.typeClass;
+      Q._setIfNotNull(json, "typeClass", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.parameterizedClass;
+      Q._setIfNotNull(json, "parameterizedClass", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.pattern;
+      Q._setIfNotNull(json, "pattern", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.closureFunction;
+      Q._setIfNotNull(json, "closureFunction", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.closureContext;
+      Q._setIfNotNull(json, "closureContext", t1 == null ? _null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_InstanceRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[InstanceRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.classRef) + "]";
+    },
+    set$valueAsString: function(valueAsString) {
+      this.valueAsString = H._asStringS(valueAsString);
+    },
+    get$valueAsString: function() {
+      return this.valueAsString;
+    },
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  Q.Instance.prototype = {
+    Instance$_fromJson$1: function(json) {
+      var t1, t2, _this = this,
+        _s8_ = "elements",
+        _s12_ = "associations";
+      _this.kind = H._asStringS(json.$index(0, "kind"));
+      t1 = type$.legacy_ClassRef;
+      _this.Instance_classRef = t1._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef));
+      _this.set$valueAsString(H._asStringS(json.$index(0, "valueAsString")));
+      t2 = json.$index(0, "valueAsStringIsTruncated");
+      _this.valueAsStringIsTruncated = H._asBoolS(t2 == null ? false : t2);
+      _this.length = H._asIntS(json.$index(0, "length"));
+      _this.offset = H._asIntS(json.$index(0, "offset"));
+      _this.count = H._asIntS(json.$index(0, "count"));
+      _this.name = H._asStringS(json.$index(0, "name"));
+      _this.typeClass = t1._as(Q.createServiceObject(json.$index(0, "typeClass"), C.List_ClassRef));
+      _this.parameterizedClass = t1._as(Q.createServiceObject(json.$index(0, "parameterizedClass"), C.List_ClassRef));
+      _this.set$fields(json.$index(0, "fields") == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, "fields"), C.List_BoundField)), true, type$.legacy_BoundField));
+      _this.elements = json.$index(0, _s8_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q.createServiceObject(json.$index(0, _s8_), C.List_dynamic)), true, type$.dynamic);
+      _this.set$associations(json.$index(0, _s12_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(Q._createSpecificObject(json.$index(0, _s12_), Q.vm_service_MapAssociation_parse$closure())), true, type$.legacy_MapAssociation));
+      _this.bytes = H._asStringS(json.$index(0, "bytes"));
+      t1 = type$.legacy_InstanceRef;
+      _this.mirrorReferent = t1._as(Q.createServiceObject(json.$index(0, "mirrorReferent"), C.List_InstanceRef));
+      _this.pattern = t1._as(Q.createServiceObject(json.$index(0, "pattern"), C.List_InstanceRef));
+      _this.closureFunction = type$.legacy_FuncRef._as(Q.createServiceObject(json.$index(0, "closureFunction"), C.List_FuncRef));
+      _this.closureContext = type$.legacy_ContextRef._as(Q.createServiceObject(json.$index(0, "closureContext"), C.List_ContextRef));
+      _this.isCaseSensitive = H._asBoolS(json.$index(0, "isCaseSensitive"));
+      _this.isMultiLine = H._asBoolS(json.$index(0, "isMultiLine"));
+      _this.propertyKey = t1._as(Q.createServiceObject(json.$index(0, "propertyKey"), C.List_InstanceRef));
+      _this.propertyValue = t1._as(Q.createServiceObject(json.$index(0, "propertyValue"), C.List_InstanceRef));
+      _this.typeArguments = type$.legacy_TypeArgumentsRef._as(Q.createServiceObject(json.$index(0, "typeArguments"), C.List_TypeArgumentsRef));
+      _this.parameterIndex = H._asIntS(json.$index(0, "parameterIndex"));
+      _this.targetType = t1._as(Q.createServiceObject(json.$index(0, "targetType"), C.List_InstanceRef));
+      _this.bound = t1._as(Q.createServiceObject(json.$index(0, "bound"), C.List_InstanceRef));
+    },
+    toJson$0: function() {
+      var t1, t2, _this = this, _null = null,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Instance");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "class", _this.Instance_classRef.toJson$0()], type$.legacy_String, type$.dynamic));
+      Q._setIfNotNull(json, "valueAsString", _this.get$valueAsString());
+      t1 = _this.valueAsStringIsTruncated;
+      Q._setIfNotNull(json, "valueAsStringIsTruncated", t1 === true);
+      Q._setIfNotNull(json, "length", _this.length);
+      Q._setIfNotNull(json, "offset", _this.offset);
+      Q._setIfNotNull(json, "count", _this.count);
+      Q._setIfNotNull(json, "name", _this.name);
+      t1 = _this.typeClass;
+      Q._setIfNotNull(json, "typeClass", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.parameterizedClass;
+      Q._setIfNotNull(json, "parameterizedClass", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.fields;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Instance_toJson_closure()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "fields", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      t1 = _this.elements;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("@(1)")._as(new Q.Instance_toJson_closure0()), t2._eval$1("MappedListIterable<1,@>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "elements", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      t1 = _this.associations;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Instance_toJson_closure1()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "associations", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      Q._setIfNotNull(json, "bytes", _this.bytes);
+      t1 = _this.mirrorReferent;
+      Q._setIfNotNull(json, "mirrorReferent", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.pattern;
+      Q._setIfNotNull(json, "pattern", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.closureFunction;
+      Q._setIfNotNull(json, "closureFunction", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.closureContext;
+      Q._setIfNotNull(json, "closureContext", t1 == null ? _null : t1.toJson$0());
+      Q._setIfNotNull(json, "isCaseSensitive", _this.isCaseSensitive);
+      Q._setIfNotNull(json, "isMultiLine", _this.isMultiLine);
+      t1 = _this.propertyKey;
+      Q._setIfNotNull(json, "propertyKey", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.propertyValue;
+      Q._setIfNotNull(json, "propertyValue", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.typeArguments;
+      Q._setIfNotNull(json, "typeArguments", t1 == null ? _null : t1.toJson$0());
+      Q._setIfNotNull(json, "parameterIndex", _this.parameterIndex);
+      t1 = _this.targetType;
+      Q._setIfNotNull(json, "targetType", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.bound;
+      Q._setIfNotNull(json, "bound", t1 == null ? _null : t1.toJson$0());
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Instance && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Instance type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.Instance_classRef) + "]";
+    },
+    set$classRef: function(classRef) {
+      this.Instance_classRef = type$.legacy_ClassRef._as(classRef);
+    },
+    set$valueAsString: function(valueAsString) {
+      this.valueAsString = H._asStringS(valueAsString);
+    },
+    set$fields: function(fields) {
+      this.fields = type$.legacy_List_legacy_BoundField._as(fields);
+    },
+    set$associations: function(associations) {
+      this.associations = type$.legacy_List_legacy_MapAssociation._as(associations);
+    },
+    $isInstanceRef: 1,
+    get$classRef: function() {
+      return this.Instance_classRef;
+    },
+    get$valueAsString: function() {
+      return this.valueAsString;
+    },
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  Q.Instance_toJson_closure.prototype = {
+    call$1: function(f) {
+      type$.legacy_BoundField._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 26
+  };
+  Q.Instance_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 3
+  };
+  Q.Instance_toJson_closure1.prototype = {
+    call$1: function(f) {
+      type$.legacy_MapAssociation._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 45
+  };
+  Q.IsolateRef.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "@Isolate");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id, "number", this.number, "name", this.name], t1, t2));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_IsolateRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[IsolateRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + "]";
+    },
+    get$id: function(receiver) {
+      return this.id;
+    }
+  };
+  Q.Isolate.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, _this = this, _null = null,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Isolate");
+      t3 = _this.id;
+      t4 = _this.number;
+      t5 = _this.name;
+      t6 = _this.startTime;
+      t7 = _this.runnable;
+      t8 = _this.livePorts;
+      t9 = _this.pauseOnExit;
+      t10 = _this.pauseEvent.toJson$0();
+      t11 = _this.libraries;
+      t11.toString;
+      t12 = H._arrayInstanceType(t11);
+      t13 = t12._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t13 = P.List_List$from(new H.MappedListIterable(t11, t12._eval$1("Map<String*,@>*(1)")._as(new Q.Isolate_toJson_closure()), t13), true, t13._eval$1("ListIterable.E"));
+      t12 = _this.breakpoints;
+      t12.toString;
+      t11 = H._arrayInstanceType(t12);
+      t14 = t11._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", t3, "number", t4, "name", t5, "startTime", t6, "runnable", t7, "livePorts", t8, "pauseOnExit", t9, "pauseEvent", t10, "libraries", t13, "breakpoints", P.List_List$from(new H.MappedListIterable(t12, t11._eval$1("Map<String*,@>*(1)")._as(new Q.Isolate_toJson_closure0()), t14), true, t14._eval$1("ListIterable.E")), "exceptionPauseMode", _this.exceptionPauseMode], t1, t2));
+      t2 = _this.rootLib;
+      Q._setIfNotNull(json, "rootLib", t2 == null ? _null : t2.toJson$0());
+      t1 = _this.error;
+      Q._setIfNotNull(json, "error", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.extensionRPCs;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("String*(1)")._as(new Q.Isolate_toJson_closure1()), t2._eval$1("MappedListIterable<1,String*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "extensionRPCs", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Isolate && this.id == other.id;
+    },
+    toString$0: function(_) {
+      return "[Isolate]";
+    },
+    set$libraries: function(libraries) {
+      this.libraries = type$.legacy_List_legacy_LibraryRef._as(libraries);
+    },
+    set$breakpoints: function(breakpoints) {
+      this.breakpoints = type$.legacy_List_legacy_Breakpoint._as(breakpoints);
+    },
+    set$extensionRPCs: function(extensionRPCs) {
+      this.extensionRPCs = type$.legacy_List_legacy_String._as(extensionRPCs);
+    },
+    $isIsolateRef: 1,
+    get$id: function(receiver) {
+      return this.id;
+    }
+  };
+  Q.Isolate_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_LibraryRef._as(f).toJson$0();
+    },
+    $signature: 46
+  };
+  Q.Isolate_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_Breakpoint._as(f).toJson$0();
+    },
+    $signature: 23
+  };
+  Q.Isolate_toJson_closure1.prototype = {
+    call$1: function(f) {
+      return H._asStringS(f);
+    },
+    $signature: 5
+  };
+  Q.IsolateGroupRef.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "@IsolateGroup");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id, "number", this.number, "name", this.name], t1, t2));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_IsolateGroupRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[IsolateGroupRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + "]";
+    },
+    get$id: function(receiver) {
+      return this.id;
+    }
+  };
+  Q.IsolateGroup.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7, t8, _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "IsolateGroup");
+      t3 = _this.id;
+      t4 = _this.number;
+      t5 = _this.name;
+      t6 = _this.isolates;
+      t6.toString;
+      t7 = H._arrayInstanceType(t6);
+      t8 = t7._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", t3, "number", t4, "name", t5, "isolates", P.List_List$from(new H.MappedListIterable(t6, t7._eval$1("Map<String*,@>*(1)")._as(new Q.IsolateGroup_toJson_closure()), t8), true, t8._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.IsolateGroup && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[IsolateGroup type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", number: " + H.S(_this.number) + ", name: " + H.S(_this.name) + ", isolates: " + H.S(_this.isolates) + "]";
+    },
+    set$isolates: function(isolates) {
+      this.isolates = type$.legacy_List_legacy_IsolateRef._as(isolates);
+    },
+    $isIsolateGroupRef: 1,
+    get$id: function(receiver) {
+      return this.id;
+    }
+  };
+  Q.IsolateGroup_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_IsolateRef._as(f).toJson$0();
+    },
+    $signature: 25
+  };
+  Q.InboundReferences.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "InboundReferences");
+      t3 = this.references;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["references", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.InboundReferences_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[InboundReferences type: " + H.S(this.type) + ", references: " + H.S(this.references) + "]";
+    },
+    set$references: function(references) {
+      this.references = type$.legacy_List_legacy_InboundReference._as(references);
+    }
+  };
+  Q.InboundReferences_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_InboundReference._as(f).toJson$0();
+    },
+    $signature: 48
+  };
+  Q.InboundReference.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["source", this.source.toJson$0()], t1, t2));
+      Q._setIfNotNull(json, "parentListIndex", this.parentListIndex);
+      t2 = this.parentField;
+      Q._setIfNotNull(json, "parentField", t2 == null ? null : t2.toJson$0());
+      return json;
+    },
+    toString$0: function(_) {
+      return "[InboundReference source: " + H.S(this.source) + "]";
+    }
+  };
+  Q.InstanceSet.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "InstanceSet");
+      t3 = this.totalCount;
+      t4 = this.instances;
+      t4.toString;
+      t5 = H._arrayInstanceType(t4);
+      t6 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["totalCount", t3, "instances", P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map<String*,@>*(1)")._as(new Q.InstanceSet_toJson_closure()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[InstanceSet type: " + H.S(this.type) + ", totalCount: " + H.S(this.totalCount) + ", instances: " + H.S(this.instances) + "]";
+    },
+    set$instances: function(instances) {
+      this.instances = type$.legacy_List_legacy_ObjRef._as(instances);
+    }
+  };
+  Q.InstanceSet_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ObjRef._as(f).toJson$0();
+    },
+    $signature: 49
+  };
+  Q.LibraryRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Library");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name, "uri", this.uri], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_LibraryRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[LibraryRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", uri: " + H.S(_this.uri) + "]";
+    }
+  };
+  Q.Library.prototype = {
+    toJson$0: function() {
+      var t1, t2, t3, t4, t5, t6, t7, t8, t9, t10, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Library");
+      t1 = _this.name;
+      t2 = _this.uri;
+      t3 = _this.debuggable;
+      t4 = _this.dependencies;
+      t4.toString;
+      t5 = H._arrayInstanceType(t4);
+      t6 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t6 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map<String*,@>*(1)")._as(new Q.Library_toJson_closure()), t6), true, t6._eval$1("ListIterable.E"));
+      t5 = _this.scripts;
+      t5.toString;
+      t4 = H._arrayInstanceType(t5);
+      t7 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t7 = P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("Map<String*,@>*(1)")._as(new Q.Library_toJson_closure0()), t7), true, t7._eval$1("ListIterable.E"));
+      t4 = _this.variables;
+      t4.toString;
+      t5 = H._arrayInstanceType(t4);
+      t8 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t8 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map<String*,@>*(1)")._as(new Q.Library_toJson_closure1()), t8), true, t8._eval$1("ListIterable.E"));
+      t5 = _this.functions;
+      t5.toString;
+      t4 = H._arrayInstanceType(t5);
+      t9 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t9 = P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("Map<String*,@>*(1)")._as(new Q.Library_toJson_closure2()), t9), true, t9._eval$1("ListIterable.E"));
+      t4 = _this.classes;
+      t4.toString;
+      t5 = H._arrayInstanceType(t4);
+      t10 = t5._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "uri", t2, "debuggable", t3, "dependencies", t6, "scripts", t7, "variables", t8, "functions", t9, "classes", P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("Map<String*,@>*(1)")._as(new Q.Library_toJson_closure3()), t10), true, t10._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Library && this.id == other.id;
+    },
+    toString$0: function(_) {
+      return "[Library]";
+    },
+    set$dependencies: function(dependencies) {
+      this.dependencies = type$.legacy_List_legacy_LibraryDependency._as(dependencies);
+    },
+    set$scripts: function(scripts) {
+      this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts);
+    },
+    set$variables: function(variables) {
+      this.variables = type$.legacy_List_legacy_FieldRef._as(variables);
+    },
+    set$functions: function(functions) {
+      this.functions = type$.legacy_List_legacy_FuncRef._as(functions);
+    },
+    set$classes: function(classes) {
+      this.classes = type$.legacy_List_legacy_ClassRef._as(classes);
+    },
+    $isLibraryRef: 1
+  };
+  Q.Library_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_LibraryDependency._as(f).toJson$0();
+    },
+    $signature: 50
+  };
+  Q.Library_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ScriptRef._as(f).toJson$0();
+    },
+    $signature: 9
+  };
+  Q.Library_toJson_closure1.prototype = {
+    call$1: function(f) {
+      return type$.legacy_FieldRef._as(f).toJson$0();
+    },
+    $signature: 21
+  };
+  Q.Library_toJson_closure2.prototype = {
+    call$1: function(f) {
+      return type$.legacy_FuncRef._as(f).toJson$0();
+    },
+    $signature: 22
+  };
+  Q.Library_toJson_closure3.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ClassRef._as(f).toJson$0();
+    },
+    $signature: 8
+  };
+  Q.LibraryDependency.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["isImport", _this.isImport, "isDeferred", _this.isDeferred, "prefix", _this.prefix, "target", _this.target.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[LibraryDependency isImport: " + H.S(_this.isImport) + ", isDeferred: " + H.S(_this.isDeferred) + ", prefix: " + H.S(_this.prefix) + ", target: " + H.S(_this.target) + "]";
+    }
+  };
+  Q.LogRecord.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "LogRecord");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["message", _this.message.toJson$0(), "time", _this.time, "level", _this.level, "sequenceNumber", _this.sequenceNumber, "loggerName", _this.loggerName.toJson$0(), "zone", _this.zone.toJson$0(), "error", _this.error.toJson$0(), "stackTrace", _this.stackTrace.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[LogRecord]";
+    }
+  };
+  Q.MapAssociation.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["key", this.key.toJson$0(), "value", this.value.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[MapAssociation key: " + H.S(this.key) + ", value: " + H.S(this.value) + "]";
+    }
+  };
+  Q.MemoryUsage.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "MemoryUsage");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["externalUsage", this.externalUsage, "heapCapacity", this.heapCapacity, "heapUsage", this.heapUsage], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[MemoryUsage type: " + H.S(_this.type) + ", externalUsage: " + H.S(_this.externalUsage) + ", heapCapacity: " + H.S(_this.heapCapacity) + ", heapUsage: " + H.S(_this.heapUsage) + "]";
+    }
+  };
+  Q.Message.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Message");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["index", _this.index, "name", _this.name, "messageObjectId", _this.messageObjectId, "size", _this.size], t1, t2));
+      t2 = _this.handler;
+      Q._setIfNotNull(json, "handler", t2 == null ? null : t2.toJson$0());
+      t1 = _this.location;
+      Q._setIfNotNull(json, "location", t1 == null ? null : t1.toJson$0());
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Message type: " + H.S(_this.type) + ", index: " + H.S(_this.index) + ", name: " + H.S(_this.name) + ", messageObjectId: " + H.S(_this.messageObjectId) + ", size: " + H.S(_this.size) + "]";
+    }
+  };
+  Q.NativeFunction.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[NativeFunction name: " + H.S(this.name) + "]";
+    }
+  };
+  Q.NullValRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$InstanceRef$toJson();
+      json.$indexSet(0, "type", "@Null");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["valueAsString", this.NullValRef_valueAsString], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_NullValRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[NullValRef type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.classRef) + ", valueAsString: " + H.S(_this.NullValRef_valueAsString) + "]";
+    },
+    set$valueAsString: function(valueAsString) {
+      this.NullValRef_valueAsString = H._asStringS(valueAsString);
+    },
+    get$valueAsString: function() {
+      return this.NullValRef_valueAsString;
+    }
+  };
+  Q.NullVal.prototype = {
+    toJson$0: function() {
+      var json = this.super$Instance$toJson();
+      json.$indexSet(0, "type", "Null");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["valueAsString", this.NullVal_valueAsString], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.NullVal && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[NullVal type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", kind: " + H.S(_this.kind) + ", classRef: " + H.S(_this.Instance_classRef) + ", valueAsString: " + H.S(_this.NullVal_valueAsString) + "]";
+    },
+    set$valueAsString: function(valueAsString) {
+      this.NullVal_valueAsString = H._asStringS(valueAsString);
+    },
+    $isNullValRef: 1,
+    get$valueAsString: function() {
+      return this.NullVal_valueAsString;
+    }
+  };
+  Q.ObjRef.prototype = {
+    ObjRef$_fromJson$1: function(json) {
+      this.id = H._asStringS(json.$index(0, "id"));
+      this.fixedId = H._asBoolS(json.$index(0, "fixedId"));
+    },
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "@Object");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", this.id], t1, t2));
+      Q._setIfNotNull(json, "fixedId", this.fixedId);
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_ObjRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[ObjRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + "]";
+    },
+    get$id: function(receiver) {
+      return this.id;
+    }
+  };
+  Q.Obj.prototype = {
+    Obj$_fromJson$1: function(json) {
+      var _this = this;
+      _this.id = H._asStringS(json.$index(0, "id"));
+      _this.fixedId = H._asBoolS(json.$index(0, "fixedId"));
+      _this.set$classRef(type$.legacy_ClassRef._as(Q.createServiceObject(json.$index(0, "class"), C.List_ClassRef)));
+      _this.size = H._asIntS(json.$index(0, "size"));
+    },
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Object");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["id", _this.id], t1, t2));
+      Q._setIfNotNull(json, "fixedId", _this.fixedId);
+      t2 = _this.get$classRef();
+      Q._setIfNotNull(json, "class", t2 == null ? null : t2.toJson$0());
+      Q._setIfNotNull(json, "size", _this.size);
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Obj && this.id == other.id;
+    },
+    toString$0: function(_) {
+      return "[Obj type: " + H.S(this.type) + ", id: " + H.S(this.id) + "]";
+    },
+    set$classRef: function(classRef) {
+      this.classRef = type$.legacy_ClassRef._as(classRef);
+    },
+    $isObjRef: 1,
+    get$id: function(receiver) {
+      return this.id;
+    },
+    get$classRef: function() {
+      return this.classRef;
+    }
+  };
+  Q.ProfileFunction.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", _this.kind, "inclusiveTicks", _this.inclusiveTicks, "exclusiveTicks", _this.exclusiveTicks, "resolvedUrl", _this.resolvedUrl, "function", _this.$function.toJson$0()], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[ProfileFunction kind: " + H.S(_this.kind) + ", inclusiveTicks: " + H.S(_this.inclusiveTicks) + ", exclusiveTicks: " + H.S(_this.exclusiveTicks) + ", resolvedUrl: " + H.S(_this.resolvedUrl) + ", function: " + H.S(_this.$function) + "]";
+    }
+  };
+  Q.ReloadReport.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "ReloadReport");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["success", this.success], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[ReloadReport type: " + H.S(this.type) + ", success: " + H.S(this.success) + "]";
+    }
+  };
+  Q.RetainingObject.prototype = {
+    toJson$0: function() {
+      var _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["value", _this.value.toJson$0()], t1, t2));
+      Q._setIfNotNull(json, "parentListIndex", _this.parentListIndex);
+      t2 = _this.parentMapKey;
+      Q._setIfNotNull(json, "parentMapKey", t2 == null ? null : t2.toJson$0());
+      Q._setIfNotNull(json, "parentField", _this.parentField);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[RetainingObject value: " + H.S(this.value) + "]";
+    }
+  };
+  Q.RetainingPath.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "RetainingPath");
+      t3 = this.length;
+      t4 = this.gcRootType;
+      t5 = this.elements;
+      t5.toString;
+      t6 = H._arrayInstanceType(t5);
+      t7 = t6._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["length", t3, "gcRootType", t4, "elements", P.List_List$from(new H.MappedListIterable(t5, t6._eval$1("Map<String*,@>*(1)")._as(new Q.RetainingPath_toJson_closure()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[RetainingPath type: " + H.S(_this.type) + ", length: " + H.S(_this.length) + ", gcRootType: " + H.S(_this.gcRootType) + ", elements: " + H.S(_this.elements) + "]";
+    },
+    set$elements: function(elements) {
+      this.elements = type$.legacy_List_legacy_RetainingObject._as(elements);
+    },
+    get$length: function(receiver) {
+      return this.length;
+    }
+  };
+  Q.RetainingPath_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_RetainingObject._as(f).toJson$0();
+    },
+    $signature: 52
+  };
+  Q.Response.prototype = {
+    toJson$0: function() {
+      var result = P.LinkedHashMap_LinkedHashMap$of(this.json, type$.legacy_String, type$.dynamic),
+        t1 = this.type;
+      result.$indexSet(0, "type", t1 == null ? "Response" : t1);
+      return result;
+    },
+    toString$0: function(_) {
+      return "[Response type: " + H.S(this.type) + "]";
+    }
+  };
+  Q.Sentinel.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Sentinel");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["kind", this.kind, "valueAsString", this.valueAsString], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Sentinel type: " + H.S(this.type) + ", kind: " + H.S(this.kind) + ", valueAsString: " + H.S(this.valueAsString) + "]";
+    }
+  };
+  Q.ScriptRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@Script");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["uri", this.uri], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_ScriptRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[ScriptRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", uri: " + H.S(this.uri) + "]";
+    }
+  };
+  Q.Script.prototype = {
+    Script$_fromJson$1: function(json) {
+      var _this = this,
+        _s13_ = "tokenPosTable";
+      _this.uri = H._asStringS(json.$index(0, "uri"));
+      _this.library = type$.legacy_LibraryRef._as(Q.createServiceObject(json.$index(0, "library"), C.List_LibraryRef));
+      _this.lineOffset = H._asIntS(json.$index(0, "lineOffset"));
+      _this.columnOffset = H._asIntS(json.$index(0, "columnOffset"));
+      _this.source = H._asStringS(json.$index(0, "source"));
+      _this.set$tokenPosTable(json.$index(0, _s13_) == null ? null : P.List_List$from(type$.Iterable_dynamic._as(J.map$1$ax(json.$index(0, _s13_), new Q.Script$_fromJson_closure())), true, type$.legacy_List_legacy_int));
+      _this._parseTokenPosTable$0();
+    },
+    _parseTokenPosTable$0: function() {
+      var lineSet, t1, t2, t3, t4, _i, line, t5, lineNumber, pos, tokenOffset, colNumber, _this = this;
+      if (_this.tokenPosTable == null)
+        return;
+      lineSet = P.LinkedHashSet_LinkedHashSet(type$.legacy_int);
+      for (t1 = _this.tokenPosTable, t2 = t1.length, t3 = _this._tokenToLine, t4 = _this._tokenToColumn, _i = 0; _i < t1.length; t1.length === t2 || (0, H.throwConcurrentModificationError)(t1), ++_i) {
+        line = t1[_i];
+        t5 = J.getInterceptor$asx(line);
+        lineNumber = H._asIntS(t5.$index(line, 0));
+        lineSet.add$1(0, lineNumber);
+        for (pos = 1; pos < t5.get$length(line); pos += 2) {
+          tokenOffset = H._asIntS(t5.$index(line, pos));
+          colNumber = H._asIntS(t5.$index(line, pos + 1));
+          t3.$indexSet(0, tokenOffset, lineNumber);
+          t4.$indexSet(0, tokenOffset, colNumber);
+        }
+      }
+    },
+    toJson$0: function() {
+      var t1, t2, _this = this,
+        json = _this.super$Obj$toJson();
+      json.$indexSet(0, "type", "Script");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["uri", _this.uri, "library", _this.library.toJson$0()], type$.legacy_String, type$.dynamic));
+      Q._setIfNotNull(json, "lineOffset", _this.lineOffset);
+      Q._setIfNotNull(json, "columnOffset", _this.columnOffset);
+      Q._setIfNotNull(json, "source", _this.source);
+      t1 = _this.tokenPosTable;
+      if (t1 == null)
+        t1 = null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("List<int*>*(1)")._as(new Q.Script_toJson_closure()), t2._eval$1("MappedListIterable<1,List<int*>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "tokenPosTable", t1 == null ? null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.Script && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Script type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", uri: " + H.S(_this.uri) + ", library: " + H.S(_this.library) + "]";
+    },
+    set$tokenPosTable: function(tokenPosTable) {
+      this.tokenPosTable = type$.legacy_List_legacy_List_legacy_int._as(tokenPosTable);
+    },
+    $isScriptRef: 1
+  };
+  Q.Script$_fromJson_closure.prototype = {
+    call$1: function(list) {
+      return P.List_List$from(type$.Iterable_dynamic._as(list), true, type$.legacy_int);
+    },
+    $signature: 53
+  };
+  Q.Script_toJson_closure.prototype = {
+    call$1: function(f) {
+      type$.legacy_List_legacy_int._as(f);
+      return f == null ? null : J.toList$0$ax(f);
+    },
+    $signature: 54
+  };
+  Q.ScriptList.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "ScriptList");
+      t3 = this.scripts;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["scripts", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.ScriptList_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[ScriptList type: " + H.S(this.type) + ", scripts: " + H.S(this.scripts) + "]";
+    },
+    set$scripts: function(scripts) {
+      this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts);
+    }
+  };
+  Q.ScriptList_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ScriptRef._as(f).toJson$0();
+    },
+    $signature: 9
+  };
+  Q.SourceLocation.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "SourceLocation");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["script", this.script.toJson$0(), "tokenPos", this.tokenPos], t1, t2));
+      Q._setIfNotNull(json, "endTokenPos", this.endTokenPos);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[SourceLocation type: " + H.S(this.type) + ", script: " + H.S(this.script) + ", tokenPos: " + H.S(this.tokenPos) + "]";
+    }
+  };
+  Q.SourceReport.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "SourceReport");
+      t3 = this.ranges;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.SourceReport_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"));
+      t4 = this.scripts;
+      t4.toString;
+      t3 = H._arrayInstanceType(t4);
+      t6 = t3._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["ranges", t5, "scripts", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("Map<String*,@>*(1)")._as(new Q.SourceReport_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[SourceReport type: " + H.S(this.type) + ", ranges: " + H.S(this.ranges) + ", scripts: " + H.S(this.scripts) + "]";
+    },
+    set$ranges: function(ranges) {
+      this.ranges = type$.legacy_List_legacy_SourceReportRange._as(ranges);
+    },
+    set$scripts: function(scripts) {
+      this.scripts = type$.legacy_List_legacy_ScriptRef._as(scripts);
+    }
+  };
+  Q.SourceReport_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_SourceReportRange._as(f).toJson$0();
+    },
+    $signature: 55
+  };
+  Q.SourceReport_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_ScriptRef._as(f).toJson$0();
+    },
+    $signature: 9
+  };
+  Q.SourceReportCoverage.prototype = {
+    toJson$0: function() {
+      var t4, t5, t6,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2),
+        t3 = this.hits;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,int*>");
+      t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("int*(1)")._as(new Q.SourceReportCoverage_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"));
+      t4 = this.misses;
+      t4.toString;
+      t3 = H._arrayInstanceType(t4);
+      t6 = t3._eval$1("MappedListIterable<1,int*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["hits", t5, "misses", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("int*(1)")._as(new Q.SourceReportCoverage_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[SourceReportCoverage hits: " + H.S(this.hits) + ", misses: " + H.S(this.misses) + "]";
+    },
+    set$hits: function(hits) {
+      this.hits = type$.legacy_List_legacy_int._as(hits);
+    },
+    set$misses: function(misses) {
+      this.misses = type$.legacy_List_legacy_int._as(misses);
+    }
+  };
+  Q.SourceReportCoverage_toJson_closure.prototype = {
+    call$1: function(f) {
+      return H._asIntS(f);
+    },
+    $signature: 4
+  };
+  Q.SourceReportCoverage_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return H._asIntS(f);
+    },
+    $signature: 4
+  };
+  Q.SourceReportRange.prototype = {
+    toJson$0: function() {
+      var _this = this, _null = null,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["scriptIndex", _this.scriptIndex, "startPos", _this.startPos, "endPos", _this.endPos, "compiled", _this.compiled], t1, t2));
+      t2 = _this.error;
+      Q._setIfNotNull(json, "error", t2 == null ? _null : t2.toJson$0());
+      t1 = _this.coverage;
+      Q._setIfNotNull(json, "coverage", t1 == null ? _null : t1.toJson$0());
+      t1 = _this.possibleBreakpoints;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("int*(1)")._as(new Q.SourceReportRange_toJson_closure()), t2._eval$1("MappedListIterable<1,int*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "possibleBreakpoints", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[SourceReportRange scriptIndex: " + H.S(_this.scriptIndex) + ", startPos: " + H.S(_this.startPos) + ", endPos: " + H.S(_this.endPos) + ", compiled: " + H.S(_this.compiled) + "]";
+    },
+    set$possibleBreakpoints: function(possibleBreakpoints) {
+      this.possibleBreakpoints = type$.legacy_List_legacy_int._as(possibleBreakpoints);
+    }
+  };
+  Q.SourceReportRange_toJson_closure.prototype = {
+    call$1: function(f) {
+      return H._asIntS(f);
+    },
+    $signature: 4
+  };
+  Q.Stack.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, _this = this, _null = null,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Stack");
+      t3 = _this.frames;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t5 = P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.Stack_toJson_closure()), t5), true, t5._eval$1("ListIterable.E"));
+      t4 = _this.messages;
+      t4.toString;
+      t3 = H._arrayInstanceType(t4);
+      t6 = t3._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["frames", t5, "messages", P.List_List$from(new H.MappedListIterable(t4, t3._eval$1("Map<String*,@>*(1)")._as(new Q.Stack_toJson_closure0()), t6), true, t6._eval$1("ListIterable.E"))], t1, t2));
+      t2 = _this.asyncCausalFrames;
+      if (t2 == null)
+        t1 = _null;
+      else {
+        t1 = H._arrayInstanceType(t2);
+        t1 = new H.MappedListIterable(t2, t1._eval$1("Map<String*,@>*(1)")._as(new Q.Stack_toJson_closure1()), t1._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+      }
+      Q._setIfNotNull(json, "asyncCausalFrames", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      t1 = _this.awaiterFrames;
+      if (t1 == null)
+        t1 = _null;
+      else {
+        t2 = H._arrayInstanceType(t1);
+        t2 = new H.MappedListIterable(t1, t2._eval$1("Map<String*,@>*(1)")._as(new Q.Stack_toJson_closure2()), t2._eval$1("MappedListIterable<1,Map<String*,@>*>"));
+        t1 = t2;
+      }
+      Q._setIfNotNull(json, "awaiterFrames", t1 == null ? _null : P.List_List$from(t1, true, t1.$ti._eval$1("ListIterable.E")));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Stack type: " + H.S(this.type) + ", frames: " + H.S(this.frames) + ", messages: " + H.S(this.messages) + "]";
+    },
+    set$frames: function($frames) {
+      this.frames = type$.legacy_List_legacy_Frame._as($frames);
+    },
+    set$asyncCausalFrames: function(asyncCausalFrames) {
+      this.asyncCausalFrames = type$.legacy_List_legacy_Frame._as(asyncCausalFrames);
+    },
+    set$awaiterFrames: function(awaiterFrames) {
+      this.awaiterFrames = type$.legacy_List_legacy_Frame._as(awaiterFrames);
+    },
+    set$messages: function(messages) {
+      this.messages = type$.legacy_List_legacy_Message._as(messages);
+    }
+  };
+  Q.Stack_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_Frame._as(f).toJson$0();
+    },
+    $signature: 10
+  };
+  Q.Stack_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_Message._as(f).toJson$0();
+    },
+    $signature: 57
+  };
+  Q.Stack_toJson_closure1.prototype = {
+    call$1: function(f) {
+      type$.legacy_Frame._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 10
+  };
+  Q.Stack_toJson_closure2.prototype = {
+    call$1: function(f) {
+      type$.legacy_Frame._as(f);
+      return f == null ? null : f.toJson$0();
+    },
+    $signature: 10
+  };
+  Q.Success.prototype = {
+    toJson$0: function() {
+      var json = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic);
+      json.$indexSet(0, "type", "Success");
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Success type: " + H.S(this.type) + "]";
+    }
+  };
+  Q.Timeline.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Timeline");
+      t3 = this.traceEvents;
+      t3.toString;
+      t4 = H._arrayInstanceType(t3);
+      t5 = t4._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["traceEvents", P.List_List$from(new H.MappedListIterable(t3, t4._eval$1("Map<String*,@>*(1)")._as(new Q.Timeline_toJson_closure()), t5), true, t5._eval$1("ListIterable.E")), "timeOriginMicros", this.timeOriginMicros, "timeExtentMicros", this.timeExtentMicros], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[Timeline type: " + H.S(_this.type) + ", traceEvents: " + H.S(_this.traceEvents) + ", timeOriginMicros: " + H.S(_this.timeOriginMicros) + ", timeExtentMicros: " + H.S(_this.timeExtentMicros) + "]";
+    },
+    set$traceEvents: function(traceEvents) {
+      this.traceEvents = type$.legacy_List_legacy_TimelineEvent._as(traceEvents);
+    }
+  };
+  Q.Timeline_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_TimelineEvent._as(f).toJson$0();
+    },
+    $signature: 24
+  };
+  Q.TimelineEvent.prototype = {
+    toJson$0: function() {
+      var result = P.LinkedHashMap_LinkedHashMap$of(this.json, type$.legacy_String, type$.dynamic);
+      result.$indexSet(0, "type", "TimelineEvent");
+      return result;
+    },
+    toString$0: function(_) {
+      return "[TimelineEvent ]";
+    }
+  };
+  Q.TimelineFlags.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "TimelineFlags");
+      t3 = this.recorderName;
+      t4 = this.availableStreams;
+      t4.toString;
+      t5 = H._arrayInstanceType(t4);
+      t6 = t5._eval$1("MappedListIterable<1,String*>");
+      t6 = P.List_List$from(new H.MappedListIterable(t4, t5._eval$1("String*(1)")._as(new Q.TimelineFlags_toJson_closure()), t6), true, t6._eval$1("ListIterable.E"));
+      t5 = this.recordedStreams;
+      t5.toString;
+      t4 = H._arrayInstanceType(t5);
+      t7 = t4._eval$1("MappedListIterable<1,String*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["recorderName", t3, "availableStreams", t6, "recordedStreams", P.List_List$from(new H.MappedListIterable(t5, t4._eval$1("String*(1)")._as(new Q.TimelineFlags_toJson_closure0()), t7), true, t7._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[TimelineFlags type: " + H.S(_this.type) + ", recorderName: " + H.S(_this.recorderName) + ", availableStreams: " + H.S(_this.availableStreams) + ", recordedStreams: " + H.S(_this.recordedStreams) + "]";
+    },
+    set$availableStreams: function(availableStreams) {
+      this.availableStreams = type$.legacy_List_legacy_String._as(availableStreams);
+    },
+    set$recordedStreams: function(recordedStreams) {
+      this.recordedStreams = type$.legacy_List_legacy_String._as(recordedStreams);
+    }
+  };
+  Q.TimelineFlags_toJson_closure.prototype = {
+    call$1: function(f) {
+      return H._asStringS(f);
+    },
+    $signature: 5
+  };
+  Q.TimelineFlags_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return H._asStringS(f);
+    },
+    $signature: 5
+  };
+  Q.Timestamp.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Timestamp");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["timestamp", this.timestamp], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Timestamp type: " + H.S(this.type) + ", timestamp: " + H.S(this.timestamp) + "]";
+    }
+  };
+  Q.TypeArgumentsRef.prototype = {
+    toJson$0: function() {
+      var json = this.super$ObjRef$toJson();
+      json.$indexSet(0, "type", "@TypeArguments");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return type$.legacy_TypeArgumentsRef._is(other) && this.id == other.get$id(other);
+    },
+    toString$0: function(_) {
+      return "[TypeArgumentsRef type: " + H.S(this.type) + ", id: " + H.S(this.id) + ", name: " + H.S(this.name) + "]";
+    }
+  };
+  Q.TypeArguments.prototype = {
+    toJson$0: function() {
+      var t1, t2, t3, t4,
+        json = this.super$Obj$toJson();
+      json.$indexSet(0, "type", "TypeArguments");
+      t1 = this.name;
+      t2 = this.types;
+      t2.toString;
+      t3 = H._arrayInstanceType(t2);
+      t4 = t3._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t1, "types", P.List_List$from(new H.MappedListIterable(t2, t3._eval$1("Map<String*,@>*(1)")._as(new Q.TypeArguments_toJson_closure()), t4), true, t4._eval$1("ListIterable.E"))], type$.legacy_String, type$.dynamic));
+      return json;
+    },
+    get$hashCode: function(_) {
+      return J.get$hashCode$(this.id);
+    },
+    $eq: function(_, other) {
+      if (other == null)
+        return false;
+      return other instanceof Q.TypeArguments && this.id == other.id;
+    },
+    toString$0: function(_) {
+      var _this = this;
+      return "[TypeArguments type: " + H.S(_this.type) + ", id: " + H.S(_this.id) + ", name: " + H.S(_this.name) + ", types: " + H.S(_this.types) + "]";
+    },
+    set$types: function(types) {
+      this.types = type$.legacy_List_legacy_InstanceRef._as(types);
+    },
+    $isTypeArgumentsRef: 1
+  };
+  Q.TypeArguments_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_InstanceRef._as(f).toJson$0();
+    },
+    $signature: 20
+  };
+  Q.UnresolvedSourceLocation.prototype = {
+    toJson$0: function() {
+      var t1, _this = this,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.dynamic);
+      json.$indexSet(0, "type", "UnresolvedSourceLocation");
+      t1 = _this.script;
+      Q._setIfNotNull(json, "script", t1 == null ? null : t1.toJson$0());
+      Q._setIfNotNull(json, "scriptUri", _this.scriptUri);
+      Q._setIfNotNull(json, "tokenPos", _this.tokenPos);
+      Q._setIfNotNull(json, "line", _this.line);
+      Q._setIfNotNull(json, "column", _this.column);
+      return json;
+    },
+    toString$0: function(_) {
+      return "[UnresolvedSourceLocation type: " + H.S(this.type) + "]";
+    }
+  };
+  Q.Version.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "Version");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["major", this.major, "minor", this.minor], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[Version type: " + H.S(this.type) + ", major: " + H.S(this.major) + ", minor: " + H.S(this.minor) + "]";
+    }
+  };
+  Q.VMRef.prototype = {
+    toJson$0: function() {
+      var t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "@VM");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", this.name], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[VMRef type: " + H.S(this.type) + ", name: " + H.S(this.name) + "]";
+    }
+  };
+  Q.VM.prototype = {
+    toJson$0: function() {
+      var t3, t4, t5, t6, t7, t8, t9, t10, t11, t12, t13, t14, _this = this,
+        t1 = type$.legacy_String,
+        t2 = type$.dynamic,
+        json = P.LinkedHashMap_LinkedHashMap$_empty(t1, t2);
+      json.$indexSet(0, "type", "VM");
+      t3 = _this.name;
+      t4 = _this.architectureBits;
+      t5 = _this.hostCPU;
+      t6 = _this.operatingSystem;
+      t7 = _this.targetCPU;
+      t8 = _this.version;
+      t9 = _this.pid;
+      t10 = _this.startTime;
+      t11 = _this.isolates;
+      t11.toString;
+      t12 = H._arrayInstanceType(t11);
+      t13 = t12._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      t13 = P.List_List$from(new H.MappedListIterable(t11, t12._eval$1("Map<String*,@>*(1)")._as(new Q.VM_toJson_closure()), t13), true, t13._eval$1("ListIterable.E"));
+      t12 = _this.isolateGroups;
+      t12.toString;
+      t11 = H._arrayInstanceType(t12);
+      t14 = t11._eval$1("MappedListIterable<1,Map<String*,@>*>");
+      json.addAll$1(0, P.LinkedHashMap_LinkedHashMap$_literal(["name", t3, "architectureBits", t4, "hostCPU", t5, "operatingSystem", t6, "targetCPU", t7, "version", t8, "pid", t9, "startTime", t10, "isolates", t13, "isolateGroups", P.List_List$from(new H.MappedListIterable(t12, t11._eval$1("Map<String*,@>*(1)")._as(new Q.VM_toJson_closure0()), t14), true, t14._eval$1("ListIterable.E"))], t1, t2));
+      return json;
+    },
+    toString$0: function(_) {
+      return "[VM]";
+    },
+    set$isolates: function(isolates) {
+      this.isolates = type$.legacy_List_legacy_IsolateRef._as(isolates);
+    },
+    set$isolateGroups: function(isolateGroups) {
+      this.isolateGroups = type$.legacy_List_legacy_IsolateGroupRef._as(isolateGroups);
+    },
+    $isVMRef: 1
+  };
+  Q.VM_toJson_closure.prototype = {
+    call$1: function(f) {
+      return type$.legacy_IsolateRef._as(f).toJson$0();
+    },
+    $signature: 25
+  };
+  Q.VM_toJson_closure0.prototype = {
+    call$1: function(f) {
+      return type$.legacy_IsolateGroupRef._as(f).toJson$0();
+    },
+    $signature: 58
+  };
+  E.main_closure.prototype = {
+    call$1: function(e) {
+      var t1 = this.ddsChannel._outgoingController;
+      t1.add$1(0, H._instanceType(t1)._precomputed1._as(e));
+      return null;
+    },
+    $signature: 59
+  };
+  (function aliases() {
+    var _ = J.Interceptor.prototype;
+    _.super$Interceptor$noSuchMethod = _.noSuchMethod$1;
+    _ = J.JavaScriptObject.prototype;
+    _.super$JavaScriptObject$toString = _.toString$0;
+    _ = P._BroadcastStreamController.prototype;
+    _.super$_BroadcastStreamController$_addEventError = _._addEventError$0;
+    _ = P._BufferingStreamSubscription.prototype;
+    _.super$_BufferingStreamSubscription$_add = _._add$1;
+    _.super$_BufferingStreamSubscription$_addError = _._addError$2;
+    _ = Q.InstanceRef.prototype;
+    _.super$InstanceRef$toJson = _.toJson$0;
+    _ = Q.Instance.prototype;
+    _.super$Instance$toJson = _.toJson$0;
+    _ = Q.ObjRef.prototype;
+    _.super$ObjRef$toJson = _.toJson$0;
+    _ = Q.Obj.prototype;
+    _.super$Obj$toJson = _.toJson$0;
+  })();
+  (function installTearOffs() {
+    var _static_1 = hunkHelpers._static_1,
+      _static_0 = hunkHelpers._static_0,
+      _static_2 = hunkHelpers._static_2,
+      _instance_0_u = hunkHelpers._instance_0u,
+      _instance = hunkHelpers.installInstanceTearOff,
+      _instance_2_u = hunkHelpers._instance_2u,
+      _instance_1_u = hunkHelpers._instance_1u;
+    _static_1(P, "async__AsyncRun__scheduleImmediateJsOverride$closure", "_AsyncRun__scheduleImmediateJsOverride", 6);
+    _static_1(P, "async__AsyncRun__scheduleImmediateWithSetImmediate$closure", "_AsyncRun__scheduleImmediateWithSetImmediate", 6);
+    _static_1(P, "async__AsyncRun__scheduleImmediateWithTimer$closure", "_AsyncRun__scheduleImmediateWithTimer", 6);
+    _static_0(P, "async___startMicrotaskLoop$closure", "_startMicrotaskLoop", 0);
+    _static_1(P, "async___nullDataHandler$closure", "_nullDataHandler", 2);
+    _static_2(P, "async___nullErrorHandler$closure", "_nullErrorHandler", 7);
+    var _;
+    _instance_0_u(_ = P._BroadcastSubscription.prototype, "get$_onPause", "_onPause$0", 0);
+    _instance_0_u(_, "get$_onResume", "_onResume$0", 0);
+    _instance(P._Completer.prototype, "get$completeError", 0, 1, null, ["call$2", "call$1"], ["completeError$2", "completeError$1"], 39, 0);
+    _instance_2_u(P._Future.prototype, "get$_completeError", "_completeError$2", 7);
+    _instance_0_u(_ = P._ControllerSubscription.prototype, "get$_onPause", "_onPause$0", 0);
+    _instance_0_u(_, "get$_onResume", "_onResume$0", 0);
+    _instance_0_u(_ = P._BufferingStreamSubscription.prototype, "get$_onPause", "_onPause$0", 0);
+    _instance_0_u(_, "get$_onResume", "_onResume$0", 0);
+    _instance_0_u(P._DoneStreamSubscription.prototype, "get$_sendDone", "_sendDone$0", 0);
+    _instance_1_u(_ = P._StreamIterator.prototype, "get$_async$_onData", "_async$_onData$1", 12);
+    _instance_2_u(_, "get$_onError", "_onError$2", 7);
+    _instance_0_u(_, "get$_onDone", "_onDone$0", 0);
+    _instance_0_u(_ = P._ForwardingStreamSubscription.prototype, "get$_onPause", "_onPause$0", 0);
+    _instance_0_u(_, "get$_onResume", "_onResume$0", 0);
+    _instance_1_u(_, "get$_handleData", "_handleData$1", 12);
+    _instance_2_u(_, "get$_handleError", "_handleError$2", 32);
+    _instance_0_u(_, "get$_handleDone", "_handleDone$0", 0);
+    _static_1(P, "convert___defaultToEncodable$closure", "_defaultToEncodable", 3);
+    _instance_1_u(_ = M.SseClient.prototype, "get$_onIncomingControlMessage", "_onIncomingControlMessage$1", 18);
+    _instance_1_u(_, "get$_onIncomingMessage", "_onIncomingMessage$1", 18);
+    _instance_0_u(_, "get$_onOutgoingDone", "_onOutgoingDone$0", 0);
+    _instance_1_u(_, "get$_onOutgoingMessage", "_onOutgoingMessage$1", 2);
+    _static_1(Q, "vm_service_ExtensionData_parse$closure", "ExtensionData_parse", 61);
+    _static_1(Q, "vm_service_AllocationProfile_parse$closure", "AllocationProfile_parse", 62);
+    _static_1(Q, "vm_service_BoundField_parse$closure", "BoundField_parse", 63);
+    _static_1(Q, "vm_service_BoundVariable_parse$closure", "BoundVariable_parse", 64);
+    _static_1(Q, "vm_service_Breakpoint_parse$closure", "Breakpoint_parse", 65);
+    _static_1(Q, "vm_service_ClassRef_parse$closure", "ClassRef_parse", 66);
+    _static_1(Q, "vm_service_Class_parse$closure", "Class_parse", 67);
+    _static_1(Q, "vm_service_ClassHeapStats_parse$closure", "ClassHeapStats_parse", 68);
+    _static_1(Q, "vm_service_ClassList_parse$closure", "ClassList_parse", 69);
+    _static_1(Q, "vm_service_ClientName_parse$closure", "ClientName_parse", 70);
+    _static_1(Q, "vm_service_CodeRef_parse$closure", "CodeRef_parse", 71);
+    _static_1(Q, "vm_service_Code_parse$closure", "Code_parse", 72);
+    _static_1(Q, "vm_service_ContextRef_parse$closure", "ContextRef_parse", 73);
+    _static_1(Q, "vm_service_Context_parse$closure", "Context_parse", 74);
+    _static_1(Q, "vm_service_ContextElement_parse$closure", "ContextElement_parse", 75);
+    _static_1(Q, "vm_service_CpuSamples_parse$closure", "CpuSamples_parse", 76);
+    _static_1(Q, "vm_service_CpuSample_parse$closure", "CpuSample_parse", 77);
+    _static_1(Q, "vm_service_ErrorRef_parse$closure", "ErrorRef_parse", 78);
+    _static_1(Q, "vm_service_Error_parse$closure", "Error_parse", 79);
+    _static_1(Q, "vm_service_Event_parse$closure", "Event_parse", 80);
+    _static_1(Q, "vm_service_FieldRef_parse$closure", "FieldRef_parse", 81);
+    _static_1(Q, "vm_service_Field_parse$closure", "Field_parse", 82);
+    _static_1(Q, "vm_service_Flag_parse$closure", "Flag_parse", 83);
+    _static_1(Q, "vm_service_FlagList_parse$closure", "FlagList_parse", 84);
+    _static_1(Q, "vm_service_Frame_parse$closure", "Frame_parse", 85);
+    _static_1(Q, "vm_service_FuncRef_parse$closure", "FuncRef_parse", 86);
+    _static_1(Q, "vm_service_Func_parse$closure", "Func_parse", 87);
+    _static_1(Q, "vm_service_InstanceRef_parse$closure", "InstanceRef_parse", 133);
+    _static_1(Q, "vm_service_Instance_parse$closure", "Instance_parse", 89);
+    _static_1(Q, "vm_service_IsolateRef_parse$closure", "IsolateRef_parse", 90);
+    _static_1(Q, "vm_service_Isolate_parse$closure", "Isolate_parse", 91);
+    _static_1(Q, "vm_service_IsolateGroupRef_parse$closure", "IsolateGroupRef_parse", 92);
+    _static_1(Q, "vm_service_IsolateGroup_parse$closure", "IsolateGroup_parse", 93);
+    _static_1(Q, "vm_service_InboundReferences_parse$closure", "InboundReferences_parse", 94);
+    _static_1(Q, "vm_service_InboundReference_parse$closure", "InboundReference_parse", 95);
+    _static_1(Q, "vm_service_InstanceSet_parse$closure", "InstanceSet_parse", 96);
+    _static_1(Q, "vm_service_LibraryRef_parse$closure", "LibraryRef_parse", 97);
+    _static_1(Q, "vm_service_Library_parse$closure", "Library_parse", 98);
+    _static_1(Q, "vm_service_LibraryDependency_parse$closure", "LibraryDependency_parse", 99);
+    _static_1(Q, "vm_service_LogRecord_parse$closure", "LogRecord_parse", 100);
+    _static_1(Q, "vm_service_MapAssociation_parse$closure", "MapAssociation_parse", 101);
+    _static_1(Q, "vm_service_MemoryUsage_parse$closure", "MemoryUsage_parse", 102);
+    _static_1(Q, "vm_service_Message_parse$closure", "Message_parse", 103);
+    _static_1(Q, "vm_service_NativeFunction_parse$closure", "NativeFunction_parse", 104);
+    _static_1(Q, "vm_service_NullValRef_parse$closure", "NullValRef_parse", 105);
+    _static_1(Q, "vm_service_NullVal_parse$closure", "NullVal_parse", 106);
+    _static_1(Q, "vm_service_ObjRef_parse$closure", "ObjRef_parse", 107);
+    _static_1(Q, "vm_service_Obj_parse$closure", "Obj_parse", 108);
+    _static_1(Q, "vm_service_ProfileFunction_parse$closure", "ProfileFunction_parse", 109);
+    _static_1(Q, "vm_service_ReloadReport_parse$closure", "ReloadReport_parse", 110);
+    _static_1(Q, "vm_service_RetainingObject_parse$closure", "RetainingObject_parse", 111);
+    _static_1(Q, "vm_service_RetainingPath_parse$closure", "RetainingPath_parse", 112);
+    _static_1(Q, "vm_service_Response_parse$closure", "Response_parse", 113);
+    _static_1(Q, "vm_service_Sentinel_parse$closure", "Sentinel_parse", 114);
+    _static_1(Q, "vm_service_ScriptRef_parse$closure", "ScriptRef_parse", 115);
+    _static_1(Q, "vm_service_Script_parse$closure", "Script_parse", 116);
+    _static_1(Q, "vm_service_ScriptList_parse$closure", "ScriptList_parse", 117);
+    _static_1(Q, "vm_service_SourceLocation_parse$closure", "SourceLocation_parse", 118);
+    _static_1(Q, "vm_service_SourceReport_parse$closure", "SourceReport_parse", 119);
+    _static_1(Q, "vm_service_SourceReportCoverage_parse$closure", "SourceReportCoverage_parse", 120);
+    _static_1(Q, "vm_service_SourceReportRange_parse$closure", "SourceReportRange_parse", 121);
+    _static_1(Q, "vm_service_Stack_parse$closure", "Stack_parse", 122);
+    _static_1(Q, "vm_service_Success_parse$closure", "Success_parse", 123);
+    _static_1(Q, "vm_service_Timeline_parse$closure", "Timeline_parse", 124);
+    _static_1(Q, "vm_service_TimelineEvent_parse$closure", "TimelineEvent_parse", 125);
+    _static_1(Q, "vm_service_TimelineFlags_parse$closure", "TimelineFlags_parse", 126);
+    _static_1(Q, "vm_service_Timestamp_parse$closure", "Timestamp_parse", 127);
+    _static_1(Q, "vm_service_TypeArgumentsRef_parse$closure", "TypeArgumentsRef_parse", 128);
+    _static_1(Q, "vm_service_TypeArguments_parse$closure", "TypeArguments_parse", 129);
+    _static_1(Q, "vm_service_UnresolvedSourceLocation_parse$closure", "UnresolvedSourceLocation_parse", 130);
+    _static_1(Q, "vm_service_Version_parse$closure", "Version_parse", 131);
+    _static_1(Q, "vm_service_VMRef_parse$closure", "VMRef_parse", 132);
+    _static_1(Q, "vm_service_VM_parse$closure", "VM_parse", 88);
+    _instance_1_u(Q.VmService.prototype, "get$_processMessage", "_processMessage$1", 2);
+  })();
+  (function inheritance() {
+    var _mixin = hunkHelpers.mixin,
+      _inherit = hunkHelpers.inherit,
+      _inheritMany = hunkHelpers.inheritMany;
+    _inherit(P.Object, null);
+    _inheritMany(P.Object, [H.JS_CONST, J.Interceptor, J.JSObject, J.ArrayIterator, P.Iterable, H.ListIterator, P.Iterator, H.FixedLengthListMixin, H.Symbol, P.MapView, H.ConstantMap, H.Closure, H.JSInvocationMirror, H.TypeErrorDecoder, P.Error0, H.NullThrownFromJavaScriptException, H.ExceptionAndStackTrace, H._StackTrace, H._Required, P.MapMixin, H.LinkedHashMapCell, H.LinkedHashMapKeyIterator, H.Rti, H._FunctionParameters, H._Type, P._TimerImpl, P._AsyncAwaitCompleter, P._BufferingStreamSubscription, P._BroadcastStreamController, P.Future, P.Completer, P._Completer, P._FutureListener, P._Future, P._AsyncCallbackEntry, P.Stream, P.StreamSubscription, P.StreamTransformerBase, P.StreamController, P._StreamController, P._AsyncStreamControllerDispatch, P._StreamSinkWrapper, P._DelayedEvent, P._DelayedDone, P._PendingEvents, P._DoneStreamSubscription, P._StreamIterator, P.AsyncError, P._Zone, P._SetBase, P._LinkedHashSetCell, P._LinkedHashSetIterator, P.ListMixin, P._UnmodifiableMapMixin, P._ListQueueIterator, P.Codec, P._JsonStringifier, P._Utf8Decoder, P.bool, P.DateTime, P.num, P.Duration, P.OutOfMemoryError, P.StackOverflowError, P._Exception, P.FormatException, P.Function, P.List, P.Map, P.MapEntry, P.Null, P.StackTrace, P._StringStackTrace, P.String, P.StringBuffer, P.Symbol0, W.EventStreamProvider, P._AcceptStructuredClone, P._JSRandom, P.ByteBuffer, P.ByteData, P.Int8List, P.Uint8List, P.Uint8ClampedList, P.Int16List, P.Uint16List, P.Int32List, P.Uint32List, P.Float32List, P.Float64List, V.ErrorResult, E.Result, F.ValueResult, G.StreamQueue, G._EventRequest, G._NextRequest, Q._QueueList_Object_ListMixin, Y.Level, L.LogRecord0, F.Logger, R.StreamChannelMixin, K.Uuid, Q.VmService, Q.RPCError, Q.SentinelException, Q.ExtensionData, Q._NullLog, Q.Response, Q.BoundField, Q.ContextElement, Q.CpuSample, Q.Flag, Q.InboundReference, Q.LibraryDependency, Q.MapAssociation, Q.NativeFunction, Q.ProfileFunction, Q.RetainingObject, Q.SourceReportCoverage, Q.SourceReportRange, Q.TimelineEvent]);
+    _inheritMany(J.Interceptor, [J.JSBool, J.JSNull, J.JavaScriptObject, J.JSArray, J.JSNumber, J.JSString, H.NativeByteBuffer, H.NativeTypedData, W.DomException, W.Event0, W.EventTarget]);
+    _inheritMany(J.JavaScriptObject, [J.PlainJavaScriptObject, J.UnknownJavaScriptObject, J.JavaScriptFunction]);
+    _inherit(J.JSUnmodifiableArray, J.JSArray);
+    _inheritMany(J.JSNumber, [J.JSInt, J.JSDouble]);
+    _inheritMany(P.Iterable, [H.EfficientLengthIterable, H.MappedIterable, H._ConstantMapKeyIterable]);
+    _inheritMany(H.EfficientLengthIterable, [H.ListIterable, H.LinkedHashMapKeyIterable]);
+    _inherit(H.EfficientLengthMappedIterable, H.MappedIterable);
+    _inherit(H.MappedIterator, P.Iterator);
+    _inheritMany(H.ListIterable, [H.MappedListIterable, P.ListQueue, P._JsonMapKeyIterable]);
+    _inherit(P._UnmodifiableMapView_MapView__UnmodifiableMapMixin, P.MapView);
+    _inherit(P.UnmodifiableMapView, P._UnmodifiableMapView_MapView__UnmodifiableMapMixin);
+    _inherit(H.ConstantMapView, P.UnmodifiableMapView);
+    _inheritMany(H.Closure, [H.ConstantMap_map_closure, H.Primitives_functionNoSuchMethod_closure, H.TearOffClosure, H.JsLinkedHashMap_addAll_closure, H.initHooks_closure, H.initHooks_closure0, H.initHooks_closure1, P._AsyncRun__initializeScheduleImmediate_internalCallback, P._AsyncRun__initializeScheduleImmediate_closure, P._AsyncRun__scheduleImmediateJsOverride_internalCallback, P._AsyncRun__scheduleImmediateWithSetImmediate_internalCallback, P._TimerImpl_internalCallback, P._awaitOnObject_closure, P._awaitOnObject_closure0, P._wrapJsFunctionForAsync_closure, P._SyncBroadcastStreamController__sendData_closure, P._Future__addListener_closure, P._Future__prependListeners_closure, P._Future__chainForeignFuture_closure, P._Future__chainForeignFuture_closure0, P._Future__chainForeignFuture_closure1, P._Future__asyncCompleteWithValue_closure, P._Future__chainFuture_closure, P._Future__asyncCompleteError_closure, P._Future__propagateToListeners_handleWhenCompleteCallback, P._Future__propagateToListeners_handleWhenCompleteCallback_closure, P._Future__propagateToListeners_handleValueCallback, P._Future__propagateToListeners_handleError, P.Stream_length_closure, P.Stream_length_closure0, P.Stream_first_closure, P.Stream_first_closure0, P._StreamController__subscribe_closure, P._StreamController__recordCancel_complete, P._BufferingStreamSubscription__sendError_sendError, P._BufferingStreamSubscription__sendDone_sendDone, P._PendingEvents_schedule_closure, P._cancelAndValue_closure, P._rootHandleUncaughtError_closure, P._RootZone_bindCallback_closure, P._RootZone_bindCallbackGuarded_closure, P._RootZone_bindUnaryCallbackGuarded_closure, P.MapBase_mapToString_closure, P.Utf8Decoder_closure, P.Utf8Decoder_closure0, P._JsonStringifier_writeMap_closure, P._symbolMapToStringMap_closure, P.NoSuchMethodError_toString_closure, P.Duration_toString_sixDigits, P.Duration_toString_twoDigits, W.HttpRequest_request_closure, W._EventStreamSubscription_closure, W._EventStreamSubscription_onData_closure, P._AcceptStructuredClone_walk_closure, P.convertDartToNative_Dictionary_closure, P.promiseToFuture_closure, P.promiseToFuture_closure0, G.StreamQueue__ensureListening_closure, G.StreamQueue__ensureListening_closure1, G.StreamQueue__ensureListening_closure0, F.Logger_Logger_closure, M.SseClient_closure, M.SseClient_closure0, M.SseClient__closure, Q.createServiceObject_closure, Q._createSpecificObject_closure, Q.VmService_closure, Q.AllocationProfile_toJson_closure, Q.Class_toJson_closure, Q.Class_toJson_closure0, Q.Class_toJson_closure1, Q.Class_toJson_closure2, Q.ClassList_toJson_closure, Q.Context_toJson_closure, Q.CpuSamples_toJson_closure, Q.CpuSamples_toJson_closure0, Q.CpuSample_toJson_closure, Q.Event_toJson_closure, Q.Event_toJson_closure0, Q.Event_toJson_closure1, Q.FlagList_toJson_closure, Q.Frame_toJson_closure, Q.Instance_toJson_closure, Q.Instance_toJson_closure0, Q.Instance_toJson_closure1, Q.Isolate_toJson_closure, Q.Isolate_toJson_closure0, Q.Isolate_toJson_closure1, Q.IsolateGroup_toJson_closure, Q.InboundReferences_toJson_closure, Q.InstanceSet_toJson_closure, Q.Library_toJson_closure, Q.Library_toJson_closure0, Q.Library_toJson_closure1, Q.Library_toJson_closure2, Q.Library_toJson_closure3, Q.RetainingPath_toJson_closure, Q.Script$_fromJson_closure, Q.Script_toJson_closure, Q.ScriptList_toJson_closure, Q.SourceReport_toJson_closure, Q.SourceReport_toJson_closure0, Q.SourceReportCoverage_toJson_closure, Q.SourceReportCoverage_toJson_closure0, Q.SourceReportRange_toJson_closure, Q.Stack_toJson_closure, Q.Stack_toJson_closure0, Q.Stack_toJson_closure1, Q.Stack_toJson_closure2, Q.Timeline_toJson_closure, Q.TimelineFlags_toJson_closure, Q.TimelineFlags_toJson_closure0, Q.TypeArguments_toJson_closure, Q.VM_toJson_closure, Q.VM_toJson_closure0, E.main_closure]);
+    _inherit(H.ConstantStringMap, H.ConstantMap);
+    _inheritMany(P.Error0, [H.NullError, H.JsNoSuchMethodError, H.UnknownJsTypeError, H.RuntimeError, P.AssertionError, H._Error, P.JsonUnsupportedObjectError, P.NullThrownError, P.ArgumentError, P.NoSuchMethodError, P.UnsupportedError, P.UnimplementedError, P.StateError, P.ConcurrentModificationError, P.CyclicInitializationError]);
+    _inheritMany(H.TearOffClosure, [H.StaticClosure, H.BoundClosure]);
+    _inherit(H._AssertionError, P.AssertionError);
+    _inherit(P.MapBase, P.MapMixin);
+    _inheritMany(P.MapBase, [H.JsLinkedHashMap, P._JsonMap]);
+    _inheritMany(H.NativeTypedData, [H.NativeByteData, H.NativeTypedArray]);
+    _inheritMany(H.NativeTypedArray, [H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin]);
+    _inherit(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin);
+    _inherit(H.NativeTypedArrayOfDouble, H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin);
+    _inherit(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin);
+    _inherit(H.NativeTypedArrayOfInt, H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin);
+    _inheritMany(H.NativeTypedArrayOfDouble, [H.NativeFloat32List, H.NativeFloat64List]);
+    _inheritMany(H.NativeTypedArrayOfInt, [H.NativeInt16List, H.NativeInt32List, H.NativeInt8List, H.NativeUint16List, H.NativeUint32List, H.NativeUint8ClampedList, H.NativeUint8List]);
+    _inherit(H._TypeError, H._Error);
+    _inheritMany(P._BufferingStreamSubscription, [P._ControllerSubscription, P._ForwardingStreamSubscription]);
+    _inherit(P._BroadcastSubscription, P._ControllerSubscription);
+    _inheritMany(P._BroadcastStreamController, [P._SyncBroadcastStreamController, P._AsyncBroadcastStreamController]);
+    _inherit(P._AsyncCompleter, P._Completer);
+    _inherit(P._AsyncStreamController, P._StreamController);
+    _inheritMany(P.Stream, [P._StreamImpl, P._ForwardingStream, W._EventStream]);
+    _inherit(P._ControllerStream, P._StreamImpl);
+    _inheritMany(P._DelayedEvent, [P._DelayedData, P._DelayedError]);
+    _inherit(P._StreamImplEvents, P._PendingEvents);
+    _inherit(P._MapStream, P._ForwardingStream);
+    _inherit(P._RootZone, P._Zone);
+    _inherit(P._LinkedHashSet, P._SetBase);
+    _inherit(P.Converter, P.StreamTransformerBase);
+    _inherit(P.JsonCyclicError, P.JsonUnsupportedObjectError);
+    _inheritMany(P.Codec, [P.JsonCodec, N.HexCodec]);
+    _inheritMany(P.Converter, [P.JsonEncoder, P.JsonDecoder, P.Utf8Decoder, R.HexEncoder]);
+    _inherit(P._JsonStringStringifier, P._JsonStringifier);
+    _inheritMany(P.num, [P.double, P.int]);
+    _inheritMany(P.ArgumentError, [P.RangeError, P.IndexError]);
+    _inheritMany(W.EventTarget, [W.EventSource, W.HttpRequestEventTarget]);
+    _inherit(W.HttpRequest, W.HttpRequestEventTarget);
+    _inheritMany(W.Event0, [W.MessageEvent, W.ProgressEvent]);
+    _inherit(W._EventStreamSubscription, P.StreamSubscription);
+    _inherit(P._AcceptStructuredCloneDart2Js, P._AcceptStructuredClone);
+    _inherit(Q.QueueList, Q._QueueList_Object_ListMixin);
+    _inherit(M.SseClient, R.StreamChannelMixin);
+    _inheritMany(Q.Response, [Q.AllocationProfile, Q.BoundVariable, Q.Obj, Q.ObjRef, Q.ClassHeapStats, Q.ClassList, Q.ClientName, Q.CpuSamples, Q.Event, Q.FlagList, Q.Frame, Q.IsolateRef, Q.Isolate, Q.IsolateGroupRef, Q.IsolateGroup, Q.InboundReferences, Q.InstanceSet, Q.LogRecord, Q.MemoryUsage, Q.Message, Q.ReloadReport, Q.RetainingPath, Q.Sentinel, Q.ScriptList, Q.SourceLocation, Q.SourceReport, Q.Stack, Q.Success, Q.Timeline, Q.TimelineFlags, Q.Timestamp, Q.UnresolvedSourceLocation, Q.Version, Q.VMRef, Q.VM]);
+    _inheritMany(Q.Obj, [Q.Breakpoint, Q.Class, Q.Context, Q.Error, Q.Field, Q.Func, Q.Instance, Q.Library, Q.Script, Q.TypeArguments]);
+    _inheritMany(Q.ObjRef, [Q.ClassRef, Q.CodeRef, Q.Code, Q.ContextRef, Q.ErrorRef, Q.FieldRef, Q.FuncRef, Q.InstanceRef, Q.LibraryRef, Q.ScriptRef, Q.TypeArgumentsRef]);
+    _inherit(Q.NullValRef, Q.InstanceRef);
+    _inherit(Q.NullVal, Q.Instance);
+    _mixin(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin, P.ListMixin);
+    _mixin(H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin, H.FixedLengthListMixin);
+    _mixin(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin, P.ListMixin);
+    _mixin(H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin, H.FixedLengthListMixin);
+    _mixin(P._AsyncStreamController, P._AsyncStreamControllerDispatch);
+    _mixin(P._UnmodifiableMapView_MapView__UnmodifiableMapMixin, P._UnmodifiableMapMixin);
+    _mixin(Q._QueueList_Object_ListMixin, P.ListMixin);
+  })();
+  var init = {
+    typeUniverse: {eC: new Map(), tR: {}, eT: {}, tPV: {}, sEA: []},
+    mangledGlobalNames: {int: "int", double: "double", num: "num", String: "String", bool: "bool", Null: "Null", List: "List"},
+    mangledNames: {},
+    getTypeFromName: getGlobalFromName,
+    metadata: [],
+    types: ["~()", "Null()", "~(@)", "@(@)", "int*(int*)", "String*(String*)", "~(~())", "~(Object,StackTrace)", "Map<String*,@>*(ClassRef*)", "Map<String*,@>*(ScriptRef*)", "Map<String*,@>*(Frame*)", "Null(@)", "~(Object?)", "Null(Object?,Object?)", "@()", "Null(Symbol0,@)", "String(int)", "@(Event0)", "~(Event0*)", "Null(Event0*)", "Map<String*,@>*(InstanceRef*)", "Map<String*,@>*(FieldRef*)", "Map<String*,@>*(FuncRef*)", "Map<String*,@>*(Breakpoint*)", "Map<String*,@>*(TimelineEvent*)", "Map<String*,@>*(IsolateRef*)", "Map<String*,@>*(BoundField*)", "Null(Object,StackTrace)", "_Future<@>(@)", "Object*(@)", "Map<String*,@>*(ClassHeapStats*)", "@(@,String)", "~(@,StackTrace)", "Null(~())", "Null(@,StackTrace)", "Map<String*,@>*(ContextElement*)", "Map<String*,@>*(ProfileFunction*)", "Map<String*,@>*(CpuSample*)", "Null(int,@)", "~(Object[StackTrace?])", "Null(ProgressEvent)", "@(String)", "Map<String*,@>*(Flag*)", "Map<String*,@>*(BoundVariable*)", "Null(String,@)", "Map<String*,@>*(MapAssociation*)", "Map<String*,@>*(LibraryRef*)", "@(@,@)", "Map<String*,@>*(InboundReference*)", "Map<String*,@>*(ObjRef*)", "Map<String*,@>*(LibraryDependency*)", "Null(@,@)", "Map<String*,@>*(RetainingObject*)", "List<int*>*(@)", "List<int*>*(List<int*>*)", "Map<String*,@>*(SourceReportRange*)", "Null(@,StackTrace*)", "Map<String*,@>*(Message*)", "Map<String*,@>*(IsolateGroupRef*)", "~(String*)", "Logger*()", "ExtensionData*(Map<@,@>*)", "AllocationProfile*(Map<String*,@>*)", "BoundField*(Map<String*,@>*)", "BoundVariable*(Map<String*,@>*)", "Breakpoint*(Map<String*,@>*)", "ClassRef*(Map<String*,@>*)", "Class*(Map<String*,@>*)", "ClassHeapStats*(Map<String*,@>*)", "ClassList*(Map<String*,@>*)", "ClientName*(Map<String*,@>*)", "CodeRef*(Map<String*,@>*)", "Code*(Map<String*,@>*)", "ContextRef*(Map<String*,@>*)", "Context*(Map<String*,@>*)", "ContextElement*(Map<String*,@>*)", "CpuSamples*(Map<String*,@>*)", "CpuSample*(Map<String*,@>*)", "ErrorRef*(Map<String*,@>*)", "Error*(Map<String*,@>*)", "Event*(Map<String*,@>*)", "FieldRef*(Map<String*,@>*)", "Field*(Map<String*,@>*)", "Flag*(Map<String*,@>*)", "FlagList*(Map<String*,@>*)", "Frame*(Map<String*,@>*)", "FuncRef*(Map<String*,@>*)", "Func*(Map<String*,@>*)", "VM*(Map<String*,@>*)", "Instance*(Map<String*,@>*)", "IsolateRef*(Map<String*,@>*)", "Isolate*(Map<String*,@>*)", "IsolateGroupRef*(Map<String*,@>*)", "IsolateGroup*(Map<String*,@>*)", "InboundReferences*(Map<String*,@>*)", "InboundReference*(Map<String*,@>*)", "InstanceSet*(Map<String*,@>*)", "LibraryRef*(Map<String*,@>*)", "Library*(Map<String*,@>*)", "LibraryDependency*(Map<String*,@>*)", "LogRecord*(Map<String*,@>*)", "MapAssociation*(Map<String*,@>*)", "MemoryUsage*(Map<String*,@>*)", "Message*(Map<String*,@>*)", "NativeFunction*(Map<String*,@>*)", "NullValRef*(Map<String*,@>*)", "NullVal*(Map<String*,@>*)", "ObjRef*(Map<String*,@>*)", "Obj*(Map<String*,@>*)", "ProfileFunction*(Map<String*,@>*)", "ReloadReport*(Map<String*,@>*)", "RetainingObject*(Map<String*,@>*)", "RetainingPath*(Map<String*,@>*)", "Response*(Map<String*,@>*)", "Sentinel*(Map<String*,@>*)", "ScriptRef*(Map<String*,@>*)", "Script*(Map<String*,@>*)", "ScriptList*(Map<String*,@>*)", "SourceLocation*(Map<String*,@>*)", "SourceReport*(Map<String*,@>*)", "SourceReportCoverage*(Map<String*,@>*)", "SourceReportRange*(Map<String*,@>*)", "Stack*(Map<String*,@>*)", "Success*(Map<String*,@>*)", "Timeline*(Map<String*,@>*)", "TimelineEvent*(Map<String*,@>*)", "TimelineFlags*(Map<String*,@>*)", "Timestamp*(Map<String*,@>*)", "TypeArgumentsRef*(Map<String*,@>*)", "TypeArguments*(Map<String*,@>*)", "UnresolvedSourceLocation*(Map<String*,@>*)", "Version*(Map<String*,@>*)", "VMRef*(Map<String*,@>*)", "InstanceRef*(Map<String*,@>*)"],
+    interceptorsByTag: null,
+    leafTags: null,
+    arrayRti: typeof Symbol == "function" && typeof Symbol() == "symbol" ? Symbol("$ti") : "$ti"
+  };
+  H._Universe_addRules(init.typeUniverse, JSON.parse('{"JavaScriptFunction":"JavaScriptObject","PlainJavaScriptObject":"JavaScriptObject","UnknownJavaScriptObject":"JavaScriptObject","AbortPaymentEvent":"Event0","ExtendableEvent":"Event0","_ResourceProgressEvent":"ProgressEvent","MessagePort":"EventTarget","JSBool":{"bool":[]},"JSNull":{"Null":[]},"JavaScriptObject":{"Function":[]},"JSArray":{"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"JSIndexable":["1"]},"JSUnmodifiableArray":{"JSArray":["1"],"List":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"JSIndexable":["1"]},"ArrayIterator":{"Iterator":["1"]},"JSNumber":{"double":[],"num":[]},"JSInt":{"double":[],"int":[],"num":[]},"JSDouble":{"double":[],"num":[]},"JSString":{"String":[],"Pattern":[],"JSIndexable":["@"]},"EfficientLengthIterable":{"Iterable":["1"]},"ListIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"ListIterator":{"Iterator":["1"]},"MappedIterable":{"Iterable":["2"],"Iterable.E":"2"},"EfficientLengthMappedIterable":{"MappedIterable":["1","2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"Iterable.E":"2"},"MappedIterator":{"Iterator":["2"]},"MappedListIterable":{"ListIterable":["2"],"EfficientLengthIterable":["2"],"Iterable":["2"],"ListIterable.E":"2","Iterable.E":"2"},"Symbol":{"Symbol0":[]},"ConstantMapView":{"UnmodifiableMapView":["1","2"],"_UnmodifiableMapView_MapView__UnmodifiableMapMixin":["1","2"],"MapView":["1","2"],"_UnmodifiableMapMixin":["1","2"],"Map":["1","2"]},"ConstantMap":{"Map":["1","2"]},"ConstantStringMap":{"ConstantMap":["1","2"],"Map":["1","2"]},"_ConstantMapKeyIterable":{"Iterable":["1"],"Iterable.E":"1"},"JSInvocationMirror":{"Invocation":[]},"NullError":{"Error0":[]},"JsNoSuchMethodError":{"Error0":[]},"UnknownJsTypeError":{"Error0":[]},"_StackTrace":{"StackTrace":[]},"Closure":{"Function":[]},"TearOffClosure":{"Function":[]},"StaticClosure":{"Function":[]},"BoundClosure":{"Function":[]},"RuntimeError":{"Error0":[]},"_AssertionError":{"Error0":[]},"JsLinkedHashMap":{"MapMixin":["1","2"],"LinkedHashMap":["1","2"],"Map":["1","2"],"MapMixin.K":"1","MapMixin.V":"2"},"LinkedHashMapKeyIterable":{"EfficientLengthIterable":["1"],"Iterable":["1"],"Iterable.E":"1"},"LinkedHashMapKeyIterator":{"Iterator":["1"]},"NativeByteData":{"ByteData":[]},"NativeTypedArray":{"JavaScriptIndexingBehavior":["1"],"JSIndexable":["1"]},"NativeTypedArrayOfDouble":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"]},"NativeTypedArrayOfInt":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"]},"NativeFloat32List":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"],"ListMixin.E":"double"},"NativeFloat64List":{"ListMixin":["double"],"JavaScriptIndexingBehavior":["double"],"List":["double"],"EfficientLengthIterable":["double"],"JSIndexable":["double"],"Iterable":["double"],"FixedLengthListMixin":["double"],"ListMixin.E":"double"},"NativeInt16List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeInt32List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeInt8List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint16List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint32List":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint8ClampedList":{"ListMixin":["int"],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"NativeUint8List":{"ListMixin":["int"],"Uint8List":[],"JavaScriptIndexingBehavior":["int"],"List":["int"],"EfficientLengthIterable":["int"],"JSIndexable":["int"],"Iterable":["int"],"FixedLengthListMixin":["int"],"ListMixin.E":"int"},"_Error":{"Error0":[]},"_TypeError":{"Error0":[]},"_TimerImpl":{"Timer":[]},"_AsyncAwaitCompleter":{"Completer":["1"]},"_BroadcastSubscription":{"_ControllerSubscription":["1"],"_BufferingStreamSubscription":["1"],"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_BroadcastStreamController":{"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_SyncBroadcastStreamController":{"_BroadcastStreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_AsyncBroadcastStreamController":{"_BroadcastStreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_Completer":{"Completer":["1"]},"_AsyncCompleter":{"_Completer":["1"],"Completer":["1"]},"_Future":{"Future":["1"]},"_StreamController":{"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_AsyncStreamController":{"_AsyncStreamControllerDispatch":["1"],"_StreamController":["1"],"StreamController":["1"],"_StreamControllerLifecycle":["1"],"_EventSink":["1"],"_EventDispatch":["1"]},"_ControllerStream":{"_StreamImpl":["1"],"Stream":["1"],"Stream.T":"1"},"_ControllerSubscription":{"_BufferingStreamSubscription":["1"],"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_BufferingStreamSubscription":{"StreamSubscription":["1"],"_EventSink":["1"],"_EventDispatch":["1"],"_BufferingStreamSubscription.T":"1"},"_StreamImpl":{"Stream":["1"]},"_DelayedData":{"_DelayedEvent":["1"]},"_DelayedError":{"_DelayedEvent":["@"]},"_DelayedDone":{"_DelayedEvent":["@"]},"_StreamImplEvents":{"_PendingEvents":["1"]},"_DoneStreamSubscription":{"StreamSubscription":["1"]},"_ForwardingStream":{"Stream":["2"]},"_ForwardingStreamSubscription":{"_BufferingStreamSubscription":["2"],"StreamSubscription":["2"],"_EventSink":["2"],"_EventDispatch":["2"],"_BufferingStreamSubscription.T":"2"},"_MapStream":{"_ForwardingStream":["1","2"],"Stream":["2"],"Stream.T":"2"},"AsyncError":{"Error0":[]},"_Zone":{"Zone":[]},"_RootZone":{"_Zone":[],"Zone":[]},"_LinkedHashSet":{"_SetBase":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"]},"_LinkedHashSetIterator":{"Iterator":["1"]},"MapBase":{"MapMixin":["1","2"],"Map":["1","2"]},"MapMixin":{"Map":["1","2"]},"MapView":{"Map":["1","2"]},"UnmodifiableMapView":{"_UnmodifiableMapView_MapView__UnmodifiableMapMixin":["1","2"],"MapView":["1","2"],"_UnmodifiableMapMixin":["1","2"],"Map":["1","2"]},"ListQueue":{"ListIterable":["1"],"Queue":["1"],"EfficientLengthIterable":["1"],"Iterable":["1"],"ListIterable.E":"1","Iterable.E":"1"},"_ListQueueIterator":{"Iterator":["1"]},"_SetBase":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"_JsonMap":{"MapMixin":["String","@"],"Map":["String","@"],"MapMixin.K":"String","MapMixin.V":"@"},"_JsonMapKeyIterable":{"ListIterable":["String"],"EfficientLengthIterable":["String"],"Iterable":["String"],"ListIterable.E":"String","Iterable.E":"String"},"JsonUnsupportedObjectError":{"Error0":[]},"JsonCyclicError":{"Error0":[]},"JsonCodec":{"Codec":["Object?","String"],"Codec.S":"Object?"},"JsonEncoder":{"Converter":["Object?","String"]},"JsonDecoder":{"Converter":["String","Object?"]},"Utf8Decoder":{"Converter":["List<int>","String"]},"double":{"num":[]},"AssertionError":{"Error0":[]},"NullThrownError":{"Error0":[]},"ArgumentError":{"Error0":[]},"RangeError":{"Error0":[]},"IndexError":{"Error0":[]},"NoSuchMethodError":{"Error0":[]},"UnsupportedError":{"Error0":[]},"UnimplementedError":{"Error0":[]},"StateError":{"Error0":[]},"ConcurrentModificationError":{"Error0":[]},"OutOfMemoryError":{"Error0":[]},"StackOverflowError":{"Error0":[]},"CyclicInitializationError":{"Error0":[]},"int":{"num":[]},"List":{"EfficientLengthIterable":["1"],"Iterable":["1"]},"_StringStackTrace":{"StackTrace":[]},"String":{"Pattern":[]},"StringBuffer":{"StringSink":[]},"EventSource":{"EventTarget":[]},"HttpRequest":{"EventTarget":[]},"HttpRequestEventTarget":{"EventTarget":[]},"MessageEvent":{"Event0":[]},"ProgressEvent":{"Event0":[]},"_EventStream":{"Stream":["1"],"Stream.T":"1"},"_EventStreamSubscription":{"StreamSubscription":["1"]},"Int8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint8ClampedList":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint16List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Int32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Uint32List":{"List":["int"],"EfficientLengthIterable":["int"],"Iterable":["int"]},"Float32List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"Float64List":{"List":["double"],"EfficientLengthIterable":["double"],"Iterable":["double"]},"ErrorResult":{"Result":["Null"]},"ValueResult":{"Result":["1*"]},"_NextRequest":{"_EventRequest":["1*"]},"QueueList":{"ListMixin":["1*"],"List":["1*"],"Queue":["1*"],"EfficientLengthIterable":["1*"],"Iterable":["1*"],"ListMixin.E":"1*"},"HexCodec":{"Codec":["List<int*>*","String*"],"Codec.S":"List<int*>*"},"HexEncoder":{"Converter":["List<int*>*","String*"]},"_NullLog":{"Log":[]},"Breakpoint":{"ObjRef":[]},"ClassRef":{"ObjRef":[]},"Class":{"ClassRef":[],"ObjRef":[]},"CodeRef":{"ObjRef":[]},"Code":{"CodeRef":[],"ObjRef":[]},"ContextRef":{"ObjRef":[]},"Context":{"ContextRef":[],"ObjRef":[]},"ErrorRef":{"ObjRef":[]},"Error":{"ErrorRef":[],"ObjRef":[]},"FieldRef":{"ObjRef":[]},"Field":{"FieldRef":[],"ObjRef":[]},"FuncRef":{"ObjRef":[]},"Func":{"FuncRef":[],"ObjRef":[]},"InstanceRef":{"ObjRef":[]},"Instance":{"InstanceRef":[],"ObjRef":[]},"Isolate":{"IsolateRef":[]},"IsolateGroup":{"IsolateGroupRef":[]},"LibraryRef":{"ObjRef":[]},"Library":{"LibraryRef":[],"ObjRef":[]},"NullValRef":{"InstanceRef":[],"ObjRef":[]},"NullVal":{"NullValRef":[],"InstanceRef":[],"ObjRef":[]},"Obj":{"ObjRef":[]},"ScriptRef":{"ObjRef":[]},"Script":{"ScriptRef":[],"ObjRef":[]},"TypeArgumentsRef":{"ObjRef":[]},"TypeArguments":{"TypeArgumentsRef":[],"ObjRef":[]},"VM":{"VMRef":[]}}'));
+  H._Universe_addErasedTypes(init.typeUniverse, JSON.parse('{"EfficientLengthIterable":1,"NativeTypedArray":1,"StreamTransformerBase":2,"MapBase":2,"MapEntry":2,"_QueueList_Object_ListMixin":1,"StreamChannelMixin":1}'));
+  var type$ = (function rtii() {
+    var findType = H.findType;
+    return {
+      $env_1_1_void: findType("@<~>"),
+      AsyncError: findType("AsyncError"),
+      ConstantMapView_Symbol_dynamic: findType("ConstantMapView<Symbol0,@>"),
+      Duration: findType("Duration"),
+      EfficientLengthIterable_dynamic: findType("EfficientLengthIterable<@>"),
+      Error: findType("Error0"),
+      Event: findType("Event0"),
+      Function: findType("Function"),
+      Future_dynamic: findType("Future<@>"),
+      Future_void: findType("Future<~>"),
+      HexCodec: findType("HexCodec"),
+      Invocation: findType("Invocation"),
+      Iterable_dynamic: findType("Iterable<@>"),
+      JSArray_String: findType("JSArray<String>"),
+      JSArray_dynamic: findType("JSArray<@>"),
+      JSArray_int: findType("JSArray<int>"),
+      JSArray_legacy_Result_legacy_String: findType("JSArray<Result<String*>*>"),
+      JSArray_legacy_String: findType("JSArray<String*>"),
+      JSArray_legacy_int: findType("JSArray<int*>"),
+      JSIndexable_dynamic: findType("JSIndexable<@>"),
+      JSNull: findType("JSNull"),
+      JavaScriptFunction: findType("JavaScriptFunction"),
+      JavaScriptIndexingBehavior_dynamic: findType("JavaScriptIndexingBehavior<@>"),
+      JsLinkedHashMap_String_dynamic: findType("JsLinkedHashMap<String,@>"),
+      JsLinkedHashMap_Symbol_dynamic: findType("JsLinkedHashMap<Symbol0,@>"),
+      JsLinkedHashMap_of_legacy_String_and_dynamic: findType("JsLinkedHashMap<String*,@>"),
+      JsLinkedHashMap_of_legacy_String_and_legacy_int: findType("JsLinkedHashMap<String*,int*>"),
+      ListQueue_legacy__EventRequest_dynamic: findType("ListQueue<_EventRequest<@>*>"),
+      List_dynamic: findType("List<@>"),
+      List_int: findType("List<int>"),
+      Map_dynamic_dynamic: findType("Map<@,@>"),
+      Null: findType("Null"),
+      Object: findType("Object"),
+      ProgressEvent: findType("ProgressEvent"),
+      QueueList_legacy_Result_legacy_String: findType("QueueList<Result<String*>*>"),
+      StackTrace: findType("StackTrace"),
+      StreamQueue_legacy_String: findType("StreamQueue<String*>"),
+      Stream_dynamic: findType("Stream<@>"),
+      String: findType("String"),
+      Symbol: findType("Symbol0"),
+      UnknownJavaScriptObject: findType("UnknownJavaScriptObject"),
+      _AsyncCompleter_HttpRequest: findType("_AsyncCompleter<HttpRequest>"),
+      _AsyncCompleter_dynamic: findType("_AsyncCompleter<@>"),
+      _AsyncCompleter_legacy_Version: findType("_AsyncCompleter<Version*>"),
+      _EventStream_legacy_Event: findType("_EventStream<Event0*>"),
+      _Future_HttpRequest: findType("_Future<HttpRequest>"),
+      _Future_bool: findType("_Future<bool>"),
+      _Future_dynamic: findType("_Future<@>"),
+      _Future_int: findType("_Future<int>"),
+      _Future_legacy_Version: findType("_Future<Version*>"),
+      _Future_void: findType("_Future<~>"),
+      _StreamControllerAddStreamState_nullable_Object: findType("_StreamControllerAddStreamState<Object?>"),
+      _StreamIterator_dynamic: findType("_StreamIterator<@>"),
+      bool: findType("bool"),
+      bool_Function_Object: findType("bool(Object)"),
+      double: findType("double"),
+      dynamic: findType("@"),
+      dynamic_Function: findType("@()"),
+      dynamic_Function_Object: findType("@(Object)"),
+      dynamic_Function_Object_StackTrace: findType("@(Object,StackTrace)"),
+      dynamic_Function_dynamic_dynamic: findType("@(@,@)"),
+      int: findType("int"),
+      legacy_BoundField: findType("BoundField*"),
+      legacy_BoundVariable: findType("BoundVariable*"),
+      legacy_Breakpoint: findType("Breakpoint*"),
+      legacy_ByteData: findType("ByteData*"),
+      legacy_ClassHeapStats: findType("ClassHeapStats*"),
+      legacy_ClassRef: findType("ClassRef*"),
+      legacy_CodeRef: findType("CodeRef*"),
+      legacy_Completer_dynamic: findType("Completer<@>*"),
+      legacy_Context: findType("Context*"),
+      legacy_ContextElement: findType("ContextElement*"),
+      legacy_ContextRef: findType("ContextRef*"),
+      legacy_CpuSample: findType("CpuSample*"),
+      legacy_Error: findType("Error*"),
+      legacy_ErrorRef: findType("ErrorRef*"),
+      legacy_Event: findType("Event*"),
+      legacy_Event_2: findType("Event0*"),
+      legacy_FieldRef: findType("FieldRef*"),
+      legacy_Flag: findType("Flag*"),
+      legacy_Frame: findType("Frame*"),
+      legacy_FuncRef: findType("FuncRef*"),
+      legacy_InboundReference: findType("InboundReference*"),
+      legacy_InstanceRef: findType("InstanceRef*"),
+      legacy_IsolateGroupRef: findType("IsolateGroupRef*"),
+      legacy_IsolateRef: findType("IsolateRef*"),
+      legacy_Level: findType("Level*"),
+      legacy_LibraryDependency: findType("LibraryDependency*"),
+      legacy_LibraryRef: findType("LibraryRef*"),
+      legacy_List_dynamic: findType("List<@>*"),
+      legacy_List_legacy_BoundField: findType("List<BoundField*>*"),
+      legacy_List_legacy_BoundVariable: findType("List<BoundVariable*>*"),
+      legacy_List_legacy_Breakpoint: findType("List<Breakpoint*>*"),
+      legacy_List_legacy_ClassHeapStats: findType("List<ClassHeapStats*>*"),
+      legacy_List_legacy_ClassRef: findType("List<ClassRef*>*"),
+      legacy_List_legacy_ContextElement: findType("List<ContextElement*>*"),
+      legacy_List_legacy_CpuSample: findType("List<CpuSample*>*"),
+      legacy_List_legacy_FieldRef: findType("List<FieldRef*>*"),
+      legacy_List_legacy_Flag: findType("List<Flag*>*"),
+      legacy_List_legacy_Frame: findType("List<Frame*>*"),
+      legacy_List_legacy_FuncRef: findType("List<FuncRef*>*"),
+      legacy_List_legacy_InboundReference: findType("List<InboundReference*>*"),
+      legacy_List_legacy_InstanceRef: findType("List<InstanceRef*>*"),
+      legacy_List_legacy_IsolateGroupRef: findType("List<IsolateGroupRef*>*"),
+      legacy_List_legacy_IsolateRef: findType("List<IsolateRef*>*"),
+      legacy_List_legacy_LibraryDependency: findType("List<LibraryDependency*>*"),
+      legacy_List_legacy_LibraryRef: findType("List<LibraryRef*>*"),
+      legacy_List_legacy_List_legacy_int: findType("List<List<int*>*>*"),
+      legacy_List_legacy_MapAssociation: findType("List<MapAssociation*>*"),
+      legacy_List_legacy_Message: findType("List<Message*>*"),
+      legacy_List_legacy_ObjRef: findType("List<ObjRef*>*"),
+      legacy_List_legacy_ProfileFunction: findType("List<ProfileFunction*>*"),
+      legacy_List_legacy_RetainingObject: findType("List<RetainingObject*>*"),
+      legacy_List_legacy_ScriptRef: findType("List<ScriptRef*>*"),
+      legacy_List_legacy_SourceReportRange: findType("List<SourceReportRange*>*"),
+      legacy_List_legacy_String: findType("List<String*>*"),
+      legacy_List_legacy_TimelineEvent: findType("List<TimelineEvent*>*"),
+      legacy_List_legacy_int: findType("List<int*>*"),
+      legacy_LogRecord: findType("LogRecord*"),
+      legacy_Logger: findType("Logger*"),
+      legacy_MapAssociation: findType("MapAssociation*"),
+      legacy_Map_dynamic_dynamic: findType("Map<@,@>*"),
+      legacy_Map_of_legacy_String_and_dynamic: findType("Map<String*,@>*"),
+      legacy_Map_of_legacy_String_and_legacy_int: findType("Map<String*,int*>*"),
+      legacy_Map_of_legacy_Symbol_and_dynamic: findType("Map<Symbol0*,@>*"),
+      legacy_MemoryUsage: findType("MemoryUsage*"),
+      legacy_Message: findType("Message*"),
+      legacy_MessageEvent: findType("MessageEvent*"),
+      legacy_Never: findType("0&*"),
+      legacy_NullValRef: findType("NullValRef*"),
+      legacy_ObjRef: findType("ObjRef*"),
+      legacy_Object: findType("Object*"),
+      legacy_ProfileFunction: findType("ProfileFunction*"),
+      legacy_ProgressEvent: findType("ProgressEvent*"),
+      legacy_RetainingObject: findType("RetainingObject*"),
+      legacy_ScriptRef: findType("ScriptRef*"),
+      legacy_SourceLocation: findType("SourceLocation*"),
+      legacy_SourceReportCoverage: findType("SourceReportCoverage*"),
+      legacy_SourceReportRange: findType("SourceReportRange*"),
+      legacy_StackTrace: findType("StackTrace*"),
+      legacy_StreamController_legacy_Event: findType("StreamController<Event*>*"),
+      legacy_String: findType("String*"),
+      legacy_TimelineEvent: findType("TimelineEvent*"),
+      legacy_TypeArgumentsRef: findType("TypeArgumentsRef*"),
+      legacy_VMRef: findType("VMRef*"),
+      legacy_int: findType("int*"),
+      legacy_legacy_Future_dynamic_Function: findType("Future<@>*()*"),
+      legacy_legacy_Future_legacy_Map_of_legacy_String_and_dynamic_Function_legacy_Map_of_legacy_String_and_dynamic: findType("Future<Map<String*,@>*>*(Map<String*,@>*)*"),
+      nullable_Future_Null: findType("Future<Null>?"),
+      nullable_List_dynamic: findType("List<@>?"),
+      nullable_Object: findType("Object?"),
+      nullable__DelayedEvent_dynamic: findType("_DelayedEvent<@>?"),
+      nullable__EventRequest_dynamic: findType("_EventRequest<@>?"),
+      nullable__FutureListener_dynamic_dynamic: findType("_FutureListener<@,@>?"),
+      nullable__LinkedHashSetCell: findType("_LinkedHashSetCell?"),
+      nullable_dynamic_Function_Event: findType("@(Event0)?"),
+      nullable_nullable_Object_Function_2_nullable_Object_and_nullable_Object: findType("Object?(Object?,Object?)?"),
+      nullable_nullable_Object_Function_dynamic: findType("Object?(@)?"),
+      nullable_void_Function: findType("~()?"),
+      nullable_void_Function_legacy_Event: findType("~(Event0*)?"),
+      nullable_void_Function_legacy_ProgressEvent: findType("~(ProgressEvent*)?"),
+      num: findType("num"),
+      void: findType("~"),
+      void_Function: findType("~()"),
+      void_Function_Object: findType("~(Object)"),
+      void_Function_Object_StackTrace: findType("~(Object,StackTrace)"),
+      void_Function_String_dynamic: findType("~(String,@)")
+    };
+  })();
+  (function constants() {
+    var makeConstList = hunkHelpers.makeConstList;
+    C.EventSource_methods = W.EventSource.prototype;
+    C.HttpRequest_methods = W.HttpRequest.prototype;
+    C.Interceptor_methods = J.Interceptor.prototype;
+    C.JSArray_methods = J.JSArray.prototype;
+    C.JSDouble_methods = J.JSDouble.prototype;
+    C.JSInt_methods = J.JSInt.prototype;
+    C.JSNull_methods = J.JSNull.prototype;
+    C.JSNumber_methods = J.JSNumber.prototype;
+    C.JSString_methods = J.JSString.prototype;
+    C.JavaScriptFunction_methods = J.JavaScriptFunction.prototype;
+    C.NativeByteData_methods = H.NativeByteData.prototype;
+    C.PlainJavaScriptObject_methods = J.PlainJavaScriptObject.prototype;
+    C.UnknownJavaScriptObject_methods = J.UnknownJavaScriptObject.prototype;
+    C.C_HexCodec = new N.HexCodec();
+    C.C_HexEncoder = new R.HexEncoder();
+    C.C_JS_CONST = function getTagFallback(o) {
+  var s = Object.prototype.toString.call(o);
+  return s.substring(8, s.length - 1);
+};
+    C.C_JS_CONST0 = function() {
+  var toStringFunction = Object.prototype.toString;
+  function getTag(o) {
+    var s = toStringFunction.call(o);
+    return s.substring(8, s.length - 1);
+  }
+  function getUnknownTag(object, tag) {
+    if (/^HTML[A-Z].*Element$/.test(tag)) {
+      var name = toStringFunction.call(object);
+      if (name == "[object Object]") return null;
+      return "HTMLElement";
+    }
+  }
+  function getUnknownTagGenericBrowser(object, tag) {
+    if (self.HTMLElement && object instanceof HTMLElement) return "HTMLElement";
+    return getUnknownTag(object, tag);
+  }
+  function prototypeForTag(tag) {
+    if (typeof window == "undefined") return null;
+    if (typeof window[tag] == "undefined") return null;
+    var constructor = window[tag];
+    if (typeof constructor != "function") return null;
+    return constructor.prototype;
+  }
+  function discriminator(tag) { return null; }
+  var isBrowser = typeof navigator == "object";
+  return {
+    getTag: getTag,
+    getUnknownTag: isBrowser ? getUnknownTagGenericBrowser : getUnknownTag,
+    prototypeForTag: prototypeForTag,
+    discriminator: discriminator };
+};
+    C.C_JS_CONST6 = function(getTagFallback) {
+  return function(hooks) {
+    if (typeof navigator != "object") return hooks;
+    var ua = navigator.userAgent;
+    if (ua.indexOf("DumpRenderTree") >= 0) return hooks;
+    if (ua.indexOf("Chrome") >= 0) {
+      function confirm(p) {
+        return typeof window == "object" && window[p] && window[p].name == p;
+      }
+      if (confirm("Window") && confirm("HTMLElement")) return hooks;
+    }
+    hooks.getTag = getTagFallback;
+  };
+};
+    C.C_JS_CONST1 = function(hooks) {
+  if (typeof dartExperimentalFixupGetTag != "function") return hooks;
+  hooks.getTag = dartExperimentalFixupGetTag(hooks.getTag);
+};
+    C.C_JS_CONST2 = function(hooks) {
+  var getTag = hooks.getTag;
+  var prototypeForTag = hooks.prototypeForTag;
+  function getTagFixed(o) {
+    var tag = getTag(o);
+    if (tag == "Document") {
+      if (!!o.xmlVersion) return "!Document";
+      return "!HTMLDocument";
+    }
+    return tag;
+  }
+  function prototypeForTagFixed(tag) {
+    if (tag == "Document") return null;
+    return prototypeForTag(tag);
+  }
+  hooks.getTag = getTagFixed;
+  hooks.prototypeForTag = prototypeForTagFixed;
+};
+    C.C_JS_CONST5 = function(hooks) {
+  var userAgent = typeof navigator == "object" ? navigator.userAgent : "";
+  if (userAgent.indexOf("Firefox") == -1) return hooks;
+  var getTag = hooks.getTag;
+  var quickMap = {
+    "BeforeUnloadEvent": "Event",
+    "DataTransfer": "Clipboard",
+    "GeoGeolocation": "Geolocation",
+    "Location": "!Location",
+    "WorkerMessageEvent": "MessageEvent",
+    "XMLDocument": "!Document"};
+  function getTagFirefox(o) {
+    var tag = getTag(o);
+    return quickMap[tag] || tag;
+  }
+  hooks.getTag = getTagFirefox;
+};
+    C.C_JS_CONST4 = function(hooks) {
+  var userAgent = typeof navigator == "object" ? navigator.userAgent : "";
+  if (userAgent.indexOf("Trident/") == -1) return hooks;
+  var getTag = hooks.getTag;
+  var quickMap = {
+    "BeforeUnloadEvent": "Event",
+    "DataTransfer": "Clipboard",
+    "HTMLDDElement": "HTMLElement",
+    "HTMLDTElement": "HTMLElement",
+    "HTMLPhraseElement": "HTMLElement",
+    "Position": "Geoposition"
+  };
+  function getTagIE(o) {
+    var tag = getTag(o);
+    var newTag = quickMap[tag];
+    if (newTag) return newTag;
+    if (tag == "Object") {
+      if (window.DataView && (o instanceof window.DataView)) return "DataView";
+    }
+    return tag;
+  }
+  function prototypeForTagIE(tag) {
+    var constructor = window[tag];
+    if (constructor == null) return null;
+    return constructor.prototype;
+  }
+  hooks.getTag = getTagIE;
+  hooks.prototypeForTag = prototypeForTagIE;
+};
+    C.C_JS_CONST3 = function(hooks) { return hooks; }
+;
+    C.C_JsonCodec = new P.JsonCodec();
+    C.C_OutOfMemoryError = new P.OutOfMemoryError();
+    C.C__DelayedDone = new P._DelayedDone();
+    C.C__JSRandom = new P._JSRandom();
+    C.C__Required = new H._Required();
+    C.C__RootZone = new P._RootZone();
+    C.C__StringStackTrace = new P._StringStackTrace();
+    C.Duration_0 = new P.Duration(0);
+    C.Duration_5000000 = new P.Duration(5000000);
+    C.JsonDecoder_null = new P.JsonDecoder(null);
+    C.JsonEncoder_null = new P.JsonEncoder(null);
+    C.Level_INFO_800 = new Y.Level("INFO", 800);
+    C.Level_WARNING_900 = new Y.Level("WARNING", 900);
+    C.List_AllocationProfile = H.setRuntimeTypeInfo(makeConstList(["AllocationProfile"]), type$.JSArray_legacy_String);
+    C.List_BoundField = H.setRuntimeTypeInfo(makeConstList(["BoundField"]), type$.JSArray_legacy_String);
+    C.List_BoundVariable = H.setRuntimeTypeInfo(makeConstList(["BoundVariable"]), type$.JSArray_legacy_String);
+    C.List_Breakpoint = H.setRuntimeTypeInfo(makeConstList(["Breakpoint"]), type$.JSArray_legacy_String);
+    C.List_ClassHeapStats = H.setRuntimeTypeInfo(makeConstList(["ClassHeapStats"]), type$.JSArray_legacy_String);
+    C.List_ClassList = H.setRuntimeTypeInfo(makeConstList(["ClassList"]), type$.JSArray_legacy_String);
+    C.List_ClassRef = H.setRuntimeTypeInfo(makeConstList(["ClassRef"]), type$.JSArray_legacy_String);
+    C.List_ClientName = H.setRuntimeTypeInfo(makeConstList(["ClientName"]), type$.JSArray_legacy_String);
+    C.List_CodeRef = H.setRuntimeTypeInfo(makeConstList(["CodeRef"]), type$.JSArray_legacy_String);
+    C.List_Context = H.setRuntimeTypeInfo(makeConstList(["Context"]), type$.JSArray_legacy_String);
+    C.List_ContextElement = H.setRuntimeTypeInfo(makeConstList(["ContextElement"]), type$.JSArray_legacy_String);
+    C.List_ContextRef = H.setRuntimeTypeInfo(makeConstList(["ContextRef"]), type$.JSArray_legacy_String);
+    C.List_CpuSample = H.setRuntimeTypeInfo(makeConstList(["CpuSample"]), type$.JSArray_legacy_String);
+    C.List_CpuSamples = H.setRuntimeTypeInfo(makeConstList(["CpuSamples"]), type$.JSArray_legacy_String);
+    C.List_Error = H.setRuntimeTypeInfo(makeConstList(["Error"]), type$.JSArray_legacy_String);
+    C.List_ErrorRef = H.setRuntimeTypeInfo(makeConstList(["ErrorRef"]), type$.JSArray_legacy_String);
+    C.List_Event = H.setRuntimeTypeInfo(makeConstList(["Event"]), type$.JSArray_legacy_String);
+    C.List_FieldRef = H.setRuntimeTypeInfo(makeConstList(["FieldRef"]), type$.JSArray_legacy_String);
+    C.List_Flag = H.setRuntimeTypeInfo(makeConstList(["Flag"]), type$.JSArray_legacy_String);
+    C.List_FlagList = H.setRuntimeTypeInfo(makeConstList(["FlagList"]), type$.JSArray_legacy_String);
+    C.List_Frame = H.setRuntimeTypeInfo(makeConstList(["Frame"]), type$.JSArray_legacy_String);
+    C.List_FuncRef = H.setRuntimeTypeInfo(makeConstList(["FuncRef"]), type$.JSArray_legacy_String);
+    C.List_InboundReference = H.setRuntimeTypeInfo(makeConstList(["InboundReference"]), type$.JSArray_legacy_String);
+    C.List_InboundReferences = H.setRuntimeTypeInfo(makeConstList(["InboundReferences"]), type$.JSArray_legacy_String);
+    C.List_InstanceRef = H.setRuntimeTypeInfo(makeConstList(["InstanceRef"]), type$.JSArray_legacy_String);
+    C.List_InstanceRef_ErrorRef = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "ErrorRef"]), type$.JSArray_legacy_String);
+    C.List_InstanceRef_Sentinel = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "Sentinel"]), type$.JSArray_legacy_String);
+    C.List_InstanceSet = H.setRuntimeTypeInfo(makeConstList(["InstanceSet"]), type$.JSArray_legacy_String);
+    C.List_Isolate = H.setRuntimeTypeInfo(makeConstList(["Isolate"]), type$.JSArray_legacy_String);
+    C.List_IsolateGroup = H.setRuntimeTypeInfo(makeConstList(["IsolateGroup"]), type$.JSArray_legacy_String);
+    C.List_IsolateGroupRef = H.setRuntimeTypeInfo(makeConstList(["IsolateGroupRef"]), type$.JSArray_legacy_String);
+    C.List_IsolateRef = H.setRuntimeTypeInfo(makeConstList(["IsolateRef"]), type$.JSArray_legacy_String);
+    C.List_LibraryRef = H.setRuntimeTypeInfo(makeConstList(["LibraryRef"]), type$.JSArray_legacy_String);
+    C.List_LibraryRef_ClassRef_FuncRef = H.setRuntimeTypeInfo(makeConstList(["LibraryRef", "ClassRef", "FuncRef"]), type$.JSArray_legacy_String);
+    C.List_LogRecord = H.setRuntimeTypeInfo(makeConstList(["LogRecord"]), type$.JSArray_legacy_String);
+    C.List_MemoryUsage = H.setRuntimeTypeInfo(makeConstList(["MemoryUsage"]), type$.JSArray_legacy_String);
+    C.List_Message = H.setRuntimeTypeInfo(makeConstList(["Message"]), type$.JSArray_legacy_String);
+    C.List_Obj = H.setRuntimeTypeInfo(makeConstList(["Obj"]), type$.JSArray_legacy_String);
+    C.List_ObjRef = H.setRuntimeTypeInfo(makeConstList(["ObjRef"]), type$.JSArray_legacy_String);
+    C.List_PAk = H.setRuntimeTypeInfo(makeConstList(["InstanceRef", "TypeArgumentsRef", "Sentinel"]), type$.JSArray_legacy_String);
+    C.List_ProfileFunction = H.setRuntimeTypeInfo(makeConstList(["ProfileFunction"]), type$.JSArray_legacy_String);
+    C.List_ReloadReport = H.setRuntimeTypeInfo(makeConstList(["ReloadReport"]), type$.JSArray_legacy_String);
+    C.List_RetainingObject = H.setRuntimeTypeInfo(makeConstList(["RetainingObject"]), type$.JSArray_legacy_String);
+    C.List_RetainingPath = H.setRuntimeTypeInfo(makeConstList(["RetainingPath"]), type$.JSArray_legacy_String);
+    C.List_ScriptList = H.setRuntimeTypeInfo(makeConstList(["ScriptList"]), type$.JSArray_legacy_String);
+    C.List_ScriptRef = H.setRuntimeTypeInfo(makeConstList(["ScriptRef"]), type$.JSArray_legacy_String);
+    C.List_SourceLocation = H.setRuntimeTypeInfo(makeConstList(["SourceLocation"]), type$.JSArray_legacy_String);
+    C.List_SourceReport = H.setRuntimeTypeInfo(makeConstList(["SourceReport"]), type$.JSArray_legacy_String);
+    C.List_Stack = H.setRuntimeTypeInfo(makeConstList(["Stack"]), type$.JSArray_legacy_String);
+    C.List_Success = H.setRuntimeTypeInfo(makeConstList(["Success"]), type$.JSArray_legacy_String);
+    C.List_Success_Error = H.setRuntimeTypeInfo(makeConstList(["Success", "Error"]), type$.JSArray_legacy_String);
+    C.List_Timeline = H.setRuntimeTypeInfo(makeConstList(["Timeline"]), type$.JSArray_legacy_String);
+    C.List_TimelineEvent = H.setRuntimeTypeInfo(makeConstList(["TimelineEvent"]), type$.JSArray_legacy_String);
+    C.List_TimelineFlags = H.setRuntimeTypeInfo(makeConstList(["TimelineFlags"]), type$.JSArray_legacy_String);
+    C.List_Timestamp = H.setRuntimeTypeInfo(makeConstList(["Timestamp"]), type$.JSArray_legacy_String);
+    C.List_TypeArgumentsRef = H.setRuntimeTypeInfo(makeConstList(["TypeArgumentsRef"]), type$.JSArray_legacy_String);
+    C.List_VM = H.setRuntimeTypeInfo(makeConstList(["VM"]), type$.JSArray_legacy_String);
+    C.List_VMRef = H.setRuntimeTypeInfo(makeConstList(["VMRef"]), type$.JSArray_legacy_String);
+    C.List_Version = H.setRuntimeTypeInfo(makeConstList(["Version"]), type$.JSArray_legacy_String);
+    C.List_dynamic = H.setRuntimeTypeInfo(makeConstList(["dynamic"]), type$.JSArray_legacy_String);
+    C.List_empty = H.setRuntimeTypeInfo(makeConstList([]), type$.JSArray_dynamic);
+    C.List_oqh = H.setRuntimeTypeInfo(makeConstList(["SourceLocation", "UnresolvedSourceLocation"]), type$.JSArray_legacy_String);
+    C.Map_empty = new H.ConstantStringMap(0, {}, C.List_empty, H.findType("ConstantStringMap<@,@>"));
+    C.List_empty0 = H.setRuntimeTypeInfo(makeConstList([]), H.findType("JSArray<Symbol0*>"));
+    C.Map_empty0 = new H.ConstantStringMap(0, {}, C.List_empty0, H.findType("ConstantStringMap<Symbol0*,@>"));
+    C.Symbol_call = new H.Symbol("call");
+    C.Type_ByteBuffer_RkP = H.typeLiteral("ByteBuffer");
+    C.Type_ByteData_zNC = H.typeLiteral("ByteData");
+    C.Type_Float32List_LB7 = H.typeLiteral("Float32List");
+    C.Type_Float64List_LB7 = H.typeLiteral("Float64List");
+    C.Type_Int16List_uXf = H.typeLiteral("Int16List");
+    C.Type_Int32List_O50 = H.typeLiteral("Int32List");
+    C.Type_Int8List_ekJ = H.typeLiteral("Int8List");
+    C.Type_JSObject_8k0 = H.typeLiteral("JSObject");
+    C.Type_Null_Yyn = H.typeLiteral("Null");
+    C.Type_String_k8F = H.typeLiteral("String");
+    C.Type_Uint16List_2bx = H.typeLiteral("Uint16List");
+    C.Type_Uint32List_2bx = H.typeLiteral("Uint32List");
+    C.Type_Uint8ClampedList_Jik = H.typeLiteral("Uint8ClampedList");
+    C.Type_Uint8List_WLA = H.typeLiteral("Uint8List");
+    C.Type_bool_lhE = H.typeLiteral("bool");
+    C.Type_double_K1J = H.typeLiteral("double");
+    C.Type_int_tHn = H.typeLiteral("int");
+    C.Type_num_cv7 = H.typeLiteral("num");
+    C.Utf8Decoder_false = new P.Utf8Decoder(false);
+  })();
+  (function staticFields() {
+    $._JS_INTEROP_INTERCEPTOR_TAG = null;
+    $.Closure_functionCounter = 0;
+    $.BoundClosure_selfFieldNameCache = null;
+    $.BoundClosure_receiverFieldNameCache = null;
+    $.getTagFunction = null;
+    $.alternateTagFunction = null;
+    $.prototypeForTagFunction = null;
+    $.dispatchRecordsForInstanceTags = null;
+    $.interceptorsForUncacheableTags = null;
+    $.initNativeDispatchFlag = null;
+    $._nextCallback = null;
+    $._lastCallback = null;
+    $._lastPriorityCallback = null;
+    $._isInCallbackLoop = false;
+    $.Zone__current = C.C__RootZone;
+    $._toStringVisiting = H.setRuntimeTypeInfo([], H.findType("JSArray<Object>"));
+    $.LogRecord__nextNumber = 0;
+    $.Logger__loggers = P.LinkedHashMap_LinkedHashMap$_empty(type$.legacy_String, type$.legacy_Logger);
+    $._typeFactories = P.LinkedHashMap_LinkedHashMap$_literal(["AllocationProfile", Q.vm_service_AllocationProfile_parse$closure(), "BoundField", Q.vm_service_BoundField_parse$closure(), "BoundVariable", Q.vm_service_BoundVariable_parse$closure(), "Breakpoint", Q.vm_service_Breakpoint_parse$closure(), "@Class", Q.vm_service_ClassRef_parse$closure(), "Class", Q.vm_service_Class_parse$closure(), "ClassHeapStats", Q.vm_service_ClassHeapStats_parse$closure(), "ClassList", Q.vm_service_ClassList_parse$closure(), "ClientName", Q.vm_service_ClientName_parse$closure(), "@Code", Q.vm_service_CodeRef_parse$closure(), "Code", Q.vm_service_Code_parse$closure(), "@Context", Q.vm_service_ContextRef_parse$closure(), "Context", Q.vm_service_Context_parse$closure(), "ContextElement", Q.vm_service_ContextElement_parse$closure(), "CpuSamples", Q.vm_service_CpuSamples_parse$closure(), "CpuSample", Q.vm_service_CpuSample_parse$closure(), "@Error", Q.vm_service_ErrorRef_parse$closure(), "Error", Q.vm_service_Error_parse$closure(), "Event", Q.vm_service_Event_parse$closure(), "ExtensionData", Q.vm_service_ExtensionData_parse$closure(), "@Field", Q.vm_service_FieldRef_parse$closure(), "Field", Q.vm_service_Field_parse$closure(), "Flag", Q.vm_service_Flag_parse$closure(), "FlagList", Q.vm_service_FlagList_parse$closure(), "Frame", Q.vm_service_Frame_parse$closure(), "@Function", Q.vm_service_FuncRef_parse$closure(), "Function", Q.vm_service_Func_parse$closure(), "@Instance", Q.vm_service_InstanceRef_parse$closure(), "Instance", Q.vm_service_Instance_parse$closure(), "@Isolate", Q.vm_service_IsolateRef_parse$closure(), "Isolate", Q.vm_service_Isolate_parse$closure(), "@IsolateGroup", Q.vm_service_IsolateGroupRef_parse$closure(), "IsolateGroup", Q.vm_service_IsolateGroup_parse$closure(), "InboundReferences", Q.vm_service_InboundReferences_parse$closure(), "InboundReference", Q.vm_service_InboundReference_parse$closure(), "InstanceSet", Q.vm_service_InstanceSet_parse$closure(), "@Library", Q.vm_service_LibraryRef_parse$closure(), "Library", Q.vm_service_Library_parse$closure(), "LibraryDependency", Q.vm_service_LibraryDependency_parse$closure(), "LogRecord", Q.vm_service_LogRecord_parse$closure(), "MapAssociation", Q.vm_service_MapAssociation_parse$closure(), "MemoryUsage", Q.vm_service_MemoryUsage_parse$closure(), "Message", Q.vm_service_Message_parse$closure(), "NativeFunction", Q.vm_service_NativeFunction_parse$closure(), "@Null", Q.vm_service_NullValRef_parse$closure(), "Null", Q.vm_service_NullVal_parse$closure(), "@Object", Q.vm_service_ObjRef_parse$closure(), "Object", Q.vm_service_Obj_parse$closure(), "ProfileFunction", Q.vm_service_ProfileFunction_parse$closure(), "ReloadReport", Q.vm_service_ReloadReport_parse$closure(), "RetainingObject", Q.vm_service_RetainingObject_parse$closure(), "RetainingPath", Q.vm_service_RetainingPath_parse$closure(), "Response", Q.vm_service_Response_parse$closure(), "Sentinel", Q.vm_service_Sentinel_parse$closure(), "@Script", Q.vm_service_ScriptRef_parse$closure(), "Script", Q.vm_service_Script_parse$closure(), "ScriptList", Q.vm_service_ScriptList_parse$closure(), "SourceLocation", Q.vm_service_SourceLocation_parse$closure(), "SourceReport", Q.vm_service_SourceReport_parse$closure(), "SourceReportCoverage", Q.vm_service_SourceReportCoverage_parse$closure(), "SourceReportRange", Q.vm_service_SourceReportRange_parse$closure(), "Stack", Q.vm_service_Stack_parse$closure(), "Success", Q.vm_service_Success_parse$closure(), "Timeline", Q.vm_service_Timeline_parse$closure(), "TimelineEvent", Q.vm_service_TimelineEvent_parse$closure(), "TimelineFlags", Q.vm_service_TimelineFlags_parse$closure(), "Timestamp", Q.vm_service_Timestamp_parse$closure(), "@TypeArguments", Q.vm_service_TypeArgumentsRef_parse$closure(), "TypeArguments", Q.vm_service_TypeArguments_parse$closure(), "UnresolvedSourceLocation", Q.vm_service_UnresolvedSourceLocation_parse$closure(), "Version", Q.vm_service_Version_parse$closure(), "@VM", Q.vm_service_VMRef_parse$closure(), "VM", Q.vm_service_VM_parse$closure()], type$.legacy_String, H.findType("Function*"));
+    $._methodReturnTypes = P.LinkedHashMap_LinkedHashMap$_literal(["addBreakpoint", C.List_Breakpoint, "addBreakpointWithScriptUri", C.List_Breakpoint, "addBreakpointAtEntry", C.List_Breakpoint, "clearCpuSamples", C.List_Success, "clearVMTimeline", C.List_Success, "invoke", C.List_InstanceRef_ErrorRef, "evaluate", C.List_InstanceRef_ErrorRef, "evaluateInFrame", C.List_InstanceRef_ErrorRef, "getAllocationProfile", C.List_AllocationProfile, "getClassList", C.List_ClassList, "getClientName", C.List_ClientName, "getCpuSamples", C.List_CpuSamples, "getFlagList", C.List_FlagList, "getInboundReferences", C.List_InboundReferences, "getInstances", C.List_InstanceSet, "getIsolate", C.List_Isolate, "getIsolateGroup", C.List_IsolateGroup, "getMemoryUsage", C.List_MemoryUsage, "getIsolateGroupMemoryUsage", C.List_MemoryUsage, "getScripts", C.List_ScriptList, "getObject", C.List_Obj, "getRetainingPath", C.List_RetainingPath, "getStack", C.List_Stack, "getSourceReport", C.List_SourceReport, "getVersion", C.List_Version, "getVM", C.List_VM, "getVMTimeline", C.List_Timeline, "getVMTimelineFlags", C.List_TimelineFlags, "getVMTimelineMicros", C.List_Timestamp, "pause", C.List_Success, "kill", C.List_Success, "registerService", C.List_Success, "reloadSources", C.List_ReloadReport, "removeBreakpoint", C.List_Success, "requestHeapSnapshot", C.List_Success, "requirePermissionToResume", C.List_Success, "resume", C.List_Success, "setClientName", C.List_Success, "setExceptionPauseMode", C.List_Success, "setFlag", C.List_Success_Error, "setLibraryDebuggable", C.List_Success, "setName", C.List_Success, "setVMName", C.List_Success, "setVMTimelineFlags", C.List_Success, "streamCancel", C.List_Success, "streamListen", C.List_Success], type$.legacy_String, type$.legacy_List_legacy_String);
+  })();
+  (function lazyInitializers() {
+    var _lazy = hunkHelpers.lazy;
+    _lazy($, "DART_CLOSURE_PROPERTY_NAME", "$get$DART_CLOSURE_PROPERTY_NAME", function() {
+      return H.getIsolateAffinityTag("_$dart_dartClosure");
+    });
+    _lazy($, "TypeErrorDecoder_noSuchMethodPattern", "$get$TypeErrorDecoder_noSuchMethodPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn({
+        toString: function() {
+          return "$receiver$";
+        }
+      }));
+    });
+    _lazy($, "TypeErrorDecoder_notClosurePattern", "$get$TypeErrorDecoder_notClosurePattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn({$method$: null,
+        toString: function() {
+          return "$receiver$";
+        }
+      }));
+    });
+    _lazy($, "TypeErrorDecoder_nullCallPattern", "$get$TypeErrorDecoder_nullCallPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn(null));
+    });
+    _lazy($, "TypeErrorDecoder_nullLiteralCallPattern", "$get$TypeErrorDecoder_nullLiteralCallPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(function() {
+        var $argumentsExpr$ = '$arguments$';
+        try {
+          null.$method$($argumentsExpr$);
+        } catch (e) {
+          return e.message;
+        }
+      }());
+    });
+    _lazy($, "TypeErrorDecoder_undefinedCallPattern", "$get$TypeErrorDecoder_undefinedCallPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokeCallErrorOn(void 0));
+    });
+    _lazy($, "TypeErrorDecoder_undefinedLiteralCallPattern", "$get$TypeErrorDecoder_undefinedLiteralCallPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(function() {
+        var $argumentsExpr$ = '$arguments$';
+        try {
+          (void 0).$method$($argumentsExpr$);
+        } catch (e) {
+          return e.message;
+        }
+      }());
+    });
+    _lazy($, "TypeErrorDecoder_nullPropertyPattern", "$get$TypeErrorDecoder_nullPropertyPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokePropertyErrorOn(null));
+    });
+    _lazy($, "TypeErrorDecoder_nullLiteralPropertyPattern", "$get$TypeErrorDecoder_nullLiteralPropertyPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(function() {
+        try {
+          null.$method$;
+        } catch (e) {
+          return e.message;
+        }
+      }());
+    });
+    _lazy($, "TypeErrorDecoder_undefinedPropertyPattern", "$get$TypeErrorDecoder_undefinedPropertyPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(H.TypeErrorDecoder_provokePropertyErrorOn(void 0));
+    });
+    _lazy($, "TypeErrorDecoder_undefinedLiteralPropertyPattern", "$get$TypeErrorDecoder_undefinedLiteralPropertyPattern", function() {
+      return H.TypeErrorDecoder_extractPattern(function() {
+        try {
+          (void 0).$method$;
+        } catch (e) {
+          return e.message;
+        }
+      }());
+    });
+    _lazy($, "_AsyncRun__scheduleImmediateClosure", "$get$_AsyncRun__scheduleImmediateClosure", function() {
+      return P._AsyncRun__initializeScheduleImmediate();
+    });
+    _lazy($, "Future__nullFuture", "$get$Future__nullFuture", function() {
+      return P._Future$zoneValue(null, C.C__RootZone, type$.Null);
+    });
+    _lazy($, "Future__falseFuture", "$get$Future__falseFuture", function() {
+      return P._Future$zoneValue(false, C.C__RootZone, type$.bool);
+    });
+    _lazy($, "Utf8Decoder__decoder", "$get$Utf8Decoder__decoder", function() {
+      return new P.Utf8Decoder_closure().call$0();
+    });
+    _lazy($, "Utf8Decoder__decoderNonfatal", "$get$Utf8Decoder__decoderNonfatal", function() {
+      return new P.Utf8Decoder_closure0().call$0();
+    });
+    _lazy($, "_hasErrorStackProperty", "$get$_hasErrorStackProperty", function() {
+      return new Error().stack != void 0;
+    });
+    _lazy($, "Logger_root", "$get$Logger_root", function() {
+      return F.Logger_Logger("");
+    });
+  })();
+  (function nativeSupport() {
+    !function() {
+      var intern = function(s) {
+        var o = {};
+        o[s] = 1;
+        return Object.keys(hunkHelpers.convertToFastObject(o))[0];
+      };
+      init.getIsolateTag = function(name) {
+        return intern("___dart_" + name + init.isolateTag);
+      };
+      var tableProperty = "___dart_isolate_tags_";
+      var usedProperties = Object[tableProperty] || (Object[tableProperty] = Object.create(null));
+      var rootProperty = "_ZxYxX";
+      for (var i = 0;; i++) {
+        var property = intern(rootProperty + "_" + i + "_");
+        if (!(property in usedProperties)) {
+          usedProperties[property] = 1;
+          init.isolateTag = property;
+          break;
+        }
+      }
+      init.dispatchPropertyName = init.getIsolateTag("dispatch_record");
+    }();
+    hunkHelpers.setOrUpdateInterceptorsByTag({Blob: J.Interceptor, DOMError: J.Interceptor, File: J.Interceptor, MediaError: J.Interceptor, NavigatorUserMediaError: J.Interceptor, OverconstrainedError: J.Interceptor, PositionError: J.Interceptor, SQLError: J.Interceptor, ArrayBuffer: H.NativeByteBuffer, ArrayBufferView: H.NativeTypedData, DataView: H.NativeByteData, Float32Array: H.NativeFloat32List, Float64Array: H.NativeFloat64List, Int16Array: H.NativeInt16List, Int32Array: H.NativeInt32List, Int8Array: H.NativeInt8List, Uint16Array: H.NativeUint16List, Uint32Array: H.NativeUint32List, Uint8ClampedArray: H.NativeUint8ClampedList, CanvasPixelArray: H.NativeUint8ClampedList, Uint8Array: H.NativeUint8List, DOMException: W.DomException, AbortPaymentEvent: W.Event0, AnimationEvent: W.Event0, AnimationPlaybackEvent: W.Event0, ApplicationCacheErrorEvent: W.Event0, BackgroundFetchClickEvent: W.Event0, BackgroundFetchEvent: W.Event0, BackgroundFetchFailEvent: W.Event0, BackgroundFetchedEvent: W.Event0, BeforeInstallPromptEvent: W.Event0, BeforeUnloadEvent: W.Event0, BlobEvent: W.Event0, CanMakePaymentEvent: W.Event0, ClipboardEvent: W.Event0, CloseEvent: W.Event0, CompositionEvent: W.Event0, CustomEvent: W.Event0, DeviceMotionEvent: W.Event0, DeviceOrientationEvent: W.Event0, ErrorEvent: W.Event0, ExtendableEvent: W.Event0, ExtendableMessageEvent: W.Event0, FetchEvent: W.Event0, FocusEvent: W.Event0, FontFaceSetLoadEvent: W.Event0, ForeignFetchEvent: W.Event0, GamepadEvent: W.Event0, HashChangeEvent: W.Event0, InstallEvent: W.Event0, KeyboardEvent: W.Event0, MediaEncryptedEvent: W.Event0, MediaKeyMessageEvent: W.Event0, MediaQueryListEvent: W.Event0, MediaStreamEvent: W.Event0, MediaStreamTrackEvent: W.Event0, MIDIConnectionEvent: W.Event0, MIDIMessageEvent: W.Event0, MouseEvent: W.Event0, DragEvent: W.Event0, MutationEvent: W.Event0, NotificationEvent: W.Event0, PageTransitionEvent: W.Event0, PaymentRequestEvent: W.Event0, PaymentRequestUpdateEvent: W.Event0, PointerEvent: W.Event0, PopStateEvent: W.Event0, PresentationConnectionAvailableEvent: W.Event0, PresentationConnectionCloseEvent: W.Event0, PromiseRejectionEvent: W.Event0, PushEvent: W.Event0, RTCDataChannelEvent: W.Event0, RTCDTMFToneChangeEvent: W.Event0, RTCPeerConnectionIceEvent: W.Event0, RTCTrackEvent: W.Event0, SecurityPolicyViolationEvent: W.Event0, SensorErrorEvent: W.Event0, SpeechRecognitionError: W.Event0, SpeechRecognitionEvent: W.Event0, SpeechSynthesisEvent: W.Event0, StorageEvent: W.Event0, SyncEvent: W.Event0, TextEvent: W.Event0, TouchEvent: W.Event0, TrackEvent: W.Event0, TransitionEvent: W.Event0, WebKitTransitionEvent: W.Event0, UIEvent: W.Event0, VRDeviceEvent: W.Event0, VRDisplayEvent: W.Event0, VRSessionEvent: W.Event0, WheelEvent: W.Event0, MojoInterfaceRequestEvent: W.Event0, USBConnectionEvent: W.Event0, IDBVersionChangeEvent: W.Event0, AudioProcessingEvent: W.Event0, OfflineAudioCompletionEvent: W.Event0, WebGLContextEvent: W.Event0, Event: W.Event0, InputEvent: W.Event0, SubmitEvent: W.Event0, EventSource: W.EventSource, MessagePort: W.EventTarget, EventTarget: W.EventTarget, XMLHttpRequest: W.HttpRequest, XMLHttpRequestEventTarget: W.HttpRequestEventTarget, MessageEvent: W.MessageEvent, ProgressEvent: W.ProgressEvent, ResourceProgressEvent: W.ProgressEvent});
+    hunkHelpers.setOrUpdateLeafTags({Blob: true, DOMError: true, File: true, MediaError: true, NavigatorUserMediaError: true, OverconstrainedError: true, PositionError: true, SQLError: true, ArrayBuffer: true, ArrayBufferView: false, DataView: true, Float32Array: true, Float64Array: true, Int16Array: true, Int32Array: true, Int8Array: true, Uint16Array: true, Uint32Array: true, Uint8ClampedArray: true, CanvasPixelArray: true, Uint8Array: false, DOMException: true, AbortPaymentEvent: true, AnimationEvent: true, AnimationPlaybackEvent: true, ApplicationCacheErrorEvent: true, BackgroundFetchClickEvent: true, BackgroundFetchEvent: true, BackgroundFetchFailEvent: true, BackgroundFetchedEvent: true, BeforeInstallPromptEvent: true, BeforeUnloadEvent: true, BlobEvent: true, CanMakePaymentEvent: true, ClipboardEvent: true, CloseEvent: true, CompositionEvent: true, CustomEvent: true, DeviceMotionEvent: true, DeviceOrientationEvent: true, ErrorEvent: true, ExtendableEvent: true, ExtendableMessageEvent: true, FetchEvent: true, FocusEvent: true, FontFaceSetLoadEvent: true, ForeignFetchEvent: true, GamepadEvent: true, HashChangeEvent: true, InstallEvent: true, KeyboardEvent: true, MediaEncryptedEvent: true, MediaKeyMessageEvent: true, MediaQueryListEvent: true, MediaStreamEvent: true, MediaStreamTrackEvent: true, MIDIConnectionEvent: true, MIDIMessageEvent: true, MouseEvent: true, DragEvent: true, MutationEvent: true, NotificationEvent: true, PageTransitionEvent: true, PaymentRequestEvent: true, PaymentRequestUpdateEvent: true, PointerEvent: true, PopStateEvent: true, PresentationConnectionAvailableEvent: true, PresentationConnectionCloseEvent: true, PromiseRejectionEvent: true, PushEvent: true, RTCDataChannelEvent: true, RTCDTMFToneChangeEvent: true, RTCPeerConnectionIceEvent: true, RTCTrackEvent: true, SecurityPolicyViolationEvent: true, SensorErrorEvent: true, SpeechRecognitionError: true, SpeechRecognitionEvent: true, SpeechSynthesisEvent: true, StorageEvent: true, SyncEvent: true, TextEvent: true, TouchEvent: true, TrackEvent: true, TransitionEvent: true, WebKitTransitionEvent: true, UIEvent: true, VRDeviceEvent: true, VRDisplayEvent: true, VRSessionEvent: true, WheelEvent: true, MojoInterfaceRequestEvent: true, USBConnectionEvent: true, IDBVersionChangeEvent: true, AudioProcessingEvent: true, OfflineAudioCompletionEvent: true, WebGLContextEvent: true, Event: false, InputEvent: false, SubmitEvent: false, EventSource: true, MessagePort: true, EventTarget: false, XMLHttpRequest: true, XMLHttpRequestEventTarget: false, MessageEvent: true, ProgressEvent: true, ResourceProgressEvent: true});
+    H.NativeTypedArray.$nativeSuperclassTag = "ArrayBufferView";
+    H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView";
+    H._NativeTypedArrayOfDouble_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView";
+    H.NativeTypedArrayOfDouble.$nativeSuperclassTag = "ArrayBufferView";
+    H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin.$nativeSuperclassTag = "ArrayBufferView";
+    H._NativeTypedArrayOfInt_NativeTypedArray_ListMixin_FixedLengthListMixin.$nativeSuperclassTag = "ArrayBufferView";
+    H.NativeTypedArrayOfInt.$nativeSuperclassTag = "ArrayBufferView";
+  })();
+  convertAllToFastObject(holders);
+  convertToFastObject($);
+  (function(callback) {
+    if (typeof document === "undefined") {
+      callback(null);
+      return;
+    }
+    if (typeof document.currentScript != 'undefined') {
+      callback(document.currentScript);
+      return;
+    }
+    var scripts = document.scripts;
+    function onLoad(event) {
+      for (var i = 0; i < scripts.length; ++i)
+        scripts[i].removeEventListener("load", onLoad, false);
+      callback(event.target);
+    }
+    for (var i = 0; i < scripts.length; ++i)
+      scripts[i].addEventListener("load", onLoad, false);
+  })(function(currentScript) {
+    init.currentScript = currentScript;
+    if (typeof dartMainRunner === "function")
+      dartMainRunner(E.main, []);
+    else
+      E.main([]);
+  });
+})();
+
+//# sourceMappingURL=sse_smoke_driver.dart.js.map
diff --git a/pkg/dev_compiler/LICENSE.md b/pkg/dev_compiler/LICENSE
similarity index 87%
rename from pkg/dev_compiler/LICENSE.md
rename to pkg/dev_compiler/LICENSE
index bab6a8c..9276409 100644
--- a/pkg/dev_compiler/LICENSE.md
+++ b/pkg/dev_compiler/LICENSE
@@ -1,11 +1,3 @@
-This license applies to all files contained here with the following
-exceptions:
-
-- All code in test/js_test_tools is externally maintained with
-  corresponding licenses in those individual files and directories.
-
----
-
 Copyright 2015, the Dart project authors. All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
diff --git a/pkg/dev_compiler/lib/src/kernel/compiler.dart b/pkg/dev_compiler/lib/src/kernel/compiler.dart
index d6f0fa5..0801c1c 100644
--- a/pkg/dev_compiler/lib/src/kernel/compiler.dart
+++ b/pkg/dev_compiler/lib/src/kernel/compiler.dart
@@ -3239,7 +3239,8 @@
 
       if (_annotatedNullCheck(p.annotations)) {
         body.add(_nullParameterCheck(jsParam));
-      } else if (_mustBeNonNullable(p.type) &&
+      } else if (!_options.soundNullSafety &&
+          _mustBeNonNullable(p.type) &&
           !_annotatedNotNull(p.annotations)) {
         // TODO(vsm): Remove if / when CFE does this:
         // https://github.com/dart-lang/sdk/issues/40597
@@ -4849,6 +4850,14 @@
         if (name == 'extensionSymbol' && firstArg is StringLiteral) {
           return getExtensionSymbolInternal(firstArg.value);
         }
+
+        if (name == 'compileTimeFlag' && firstArg is StringLiteral) {
+          var flagName = firstArg.value;
+          if (flagName == 'soundNullSafety') {
+            return js.boolean(_options.soundNullSafety);
+          }
+          throw UnsupportedError('Invalid flag in call to $name: $flagName');
+        }
       } else if (node.arguments.positional.length == 2) {
         var firstArg = node.arguments.positional[0];
         var secondArg = node.arguments.positional[1];
@@ -5212,8 +5221,9 @@
   @override
   js_ast.Expression visitNullCheck(NullCheck node) {
     var expr = node.operand;
+    var jsExpr = _visitExpression(expr);
     // If the expression is non-nullable already, this is a no-op.
-    return isNullable(expr) ? notNull(expr) : _visitExpression(expr);
+    return isNullable(expr) ? runtimeCall('nullCheck(#)', [jsExpr]) : jsExpr;
   }
 
   @override
diff --git a/pkg/dev_compiler/lib/src/kernel/nullable_inference.dart b/pkg/dev_compiler/lib/src/kernel/nullable_inference.dart
index 25fce07..363f13a 100644
--- a/pkg/dev_compiler/lib/src/kernel/nullable_inference.dart
+++ b/pkg/dev_compiler/lib/src/kernel/nullable_inference.dart
@@ -68,6 +68,12 @@
   bool visitNullLiteral(NullLiteral node) => true;
 
   @override
+  bool visitNullCheck(NullCheck node) {
+    node.operand.accept(this);
+    return false;
+  }
+
+  @override
   bool visitVariableGet(VariableGet node) {
     return _variableInference.variableIsNullable(node.variable);
   }
diff --git a/pkg/dev_compiler/test/modular_suite.dart b/pkg/dev_compiler/test/modular_suite.dart
index ab721cb..3d47edc 100644
--- a/pkg/dev_compiler/test/modular_suite.dart
+++ b/pkg/dev_compiler/test/modular_suite.dart
@@ -259,8 +259,6 @@
     var runjs = '''
     import { dart, _isolate_helper } from 'dart_sdk.js';
     import { main } from 'main.js';
-    // Run with weak null safety.
-    dart.nullSafety(false);
     _isolate_helper.startRootIsolate(() => {}, []);
     main.main();
     ''';
diff --git a/pkg/dev_compiler/test/modular_suite_nnbd.dart b/pkg/dev_compiler/test/modular_suite_nnbd.dart
index 0970e54..6677465 100644
--- a/pkg/dev_compiler/test/modular_suite_nnbd.dart
+++ b/pkg/dev_compiler/test/modular_suite_nnbd.dart
@@ -263,7 +263,6 @@
     var runjs = '''
     import { dart, _isolate_helper } from 'dart_sdk.js';
     import { main } from 'main.js';
-    dart.nullSafety(false);
     _isolate_helper.startRootIsolate(() => {}, []);
     main.main();
     ''';
diff --git a/pkg/dev_compiler/tool/dartdevc_nnbd_sdk_error_golden.txt b/pkg/dev_compiler/tool/dartdevc_nnbd_sdk_error_golden.txt
index 21a638c..004f021 100644
--- a/pkg/dev_compiler/tool/dartdevc_nnbd_sdk_error_golden.txt
+++ b/pkg/dev_compiler/tool/dartdevc_nnbd_sdk_error_golden.txt
@@ -1,8 +1,8 @@
-ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|3726|5|94|Const constructors can't throw exceptions.
-ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|7916|5|97|Const constructors can't throw exceptions.
-ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|940|5|95|Const constructors can't throw exceptions.
-ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|973|5|94|Const constructors can't throw exceptions.
-ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|3724|3|5|Only redirecting factory constructors can be declared to be 'const'.
-ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|7914|3|5|Only redirecting factory constructors can be declared to be 'const'.
-ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|938|3|5|Only redirecting factory constructors can be declared to be 'const'.
-ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|971|3|5|Only redirecting factory constructors can be declared to be 'const'.
+ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|3725|5|94|Const constructors can't throw exceptions.
+ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|7913|5|97|Const constructors can't throw exceptions.
+ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|939|5|95|Const constructors can't throw exceptions.
+ERROR|COMPILE_TIME_ERROR|CONST_CONSTRUCTOR_THROWS_EXCEPTION|lib/core/core.dart|972|5|94|Const constructors can't throw exceptions.
+ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|3723|3|5|Only redirecting factory constructors can be declared to be 'const'.
+ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|7911|3|5|Only redirecting factory constructors can be declared to be 'const'.
+ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|937|3|5|Only redirecting factory constructors can be declared to be 'const'.
+ERROR|SYNTACTIC_ERROR|CONST_FACTORY|lib/core/core.dart|970|3|5|Only redirecting factory constructors can be declared to be 'const'.
diff --git a/pkg/dev_compiler/tool/ddb b/pkg/dev_compiler/tool/ddb
index 642d148..2fbe99e 100755
--- a/pkg/dev_compiler/tool/ddb
+++ b/pkg/dev_compiler/tool/ddb
@@ -42,13 +42,16 @@
         help: 'Option to (compile|run|all). Default is all (compile and run).',
         allowed: ['compile', 'run', 'all'],
         defaultsTo: 'all')
-    ..addOption('nnbd',
-        help: 'Runtime null safety mode (strong|weak|disabled). When enabled '
-            'will automatically enable the "non-nullable" experiment. Defaults '
-            'to strong if the experiment is also passed manually, otherwise '
-            'to disabled.',
-        allowed: ['strong', 'weak', 'disabled'],
-        defaultsTo: 'disabled')
+    ..addFlag('sound-null-safety',
+        help: 'Compile for sound null safety at runtime. Passed through to the '
+            'DDC binary. Defaults to false.',
+        defaultsTo: false,
+        negatable: true)
+    ..addFlag('null-assertions',
+        help: 'Run with assertions that values passed to non-nullable method '
+            'parameters are not null.',
+        defaultsTo: false,
+        negatable: true)
     ..addFlag('observe',
         help:
             'Run the compiler in the Dart VM with --observe. Implies --debug.',
@@ -77,10 +80,7 @@
         negatable: false,
         defaultsTo: false)
     ..addOption('vm-service-port',
-        help: 'Specify the observatory port. Implied --observe.')
-    ..addSeparator('Deprecated and will be removed:')
-    ..addFlag('kernel',
-        abbr: 'k', help: 'Ignored. The kernel based DDC is always used.');
+        help: 'Specify the observatory port. Implied --observe.');
 
   var options = parser.parse(args);
   if (options['help'] as bool) {
@@ -106,15 +106,15 @@
   var compile = mode == 'compile' || mode == 'all';
   var run = mode == 'run' || mode == 'all';
   var verbose = options['verbose'] as bool;
+  var nonNullAsserts = options['null-assertions'] as bool;
 
-  // Enable null-safety either by passing the experiment flag
-  // or by requesting an nnbd mode:
-  var nnbd =
-      experiments.contains('non-nullable') || options['nnbd'] != 'disabled';
-  // Unless weak-mode is specified, default to strict checks
-  var isNnbdStrong = nnbd && options['nnbd'] != 'weak';
-  // Ensure non-nullable is passed as a flag
-  if (nnbd && !experiments.contains('non-nullable')) {
+  var soundNullSafety = options['sound-null-safety'] as bool;
+  // Enable null safety either by passing the `non-nullable` experiment flag or
+  // `sound-null-safety`.
+  var nnbd = experiments.contains('non-nullable') || soundNullSafety;
+
+  // Ensure non-nullable is passed as a flag.
+  if (soundNullSafety && !experiments.contains('non-nullable')) {
     experiments.add('non-nullable');
   }
 
@@ -210,14 +210,14 @@
   String ddcSdk;
   String sdkJsPath;
   String requirePath;
-  var suffix = isNnbdStrong ? p.join('sound', mod) : p.join('kernel', mod);
+  var suffix = soundNullSafety ? p.join('sound', mod) : p.join('kernel', mod);
   if (debug) {
     var sdkRoot = p.dirname(p.dirname(ddcPath));
     var buildDir =
         p.join(sdkRoot, Platform.isMacOS ? 'xcodebuild' : 'out', 'ReleaseX64');
     dartSdk = p.join(buildDir, 'dart-sdk');
-    ddcSdk = p.join(
-        buildDir, isNnbdStrong ? 'ddc_outline_sound.dill' : 'ddc_outline.dill');
+    ddcSdk = p.join(buildDir,
+        soundNullSafety ? 'ddc_outline_sound.dill' : 'ddc_outline.dill');
     sdkJsPath = p.join(buildDir, 'gen', 'utils', 'dartdevc', suffix);
     requirePath = p.join(sdkRoot, 'third_party', 'requirejs');
   } else {
@@ -227,17 +227,18 @@
   }
 
   // Print an initial empty line to separate the invocation from the output.
-  print('');
+  if (verbose) {
+    print('');
+  }
 
   if (compile) {
     var ddcArgs = [
-      '--kernel',
       if (summarizeText) '--summarize-text',
       '--modules=$mod',
       '--dart-sdk-summary=$ddcSdk',
       for (var summary in summaries) '--summary=$summary',
       for (var experiment in experiments) '--enable-experiment=$experiment',
-      if (isNnbdStrong) '--sound-null-safety',
+      if (soundNullSafety) '--sound-null-safety',
       if (options['packages'] != null) '--packages=${options['packages']}',
       '-o',
       out,
@@ -275,8 +276,8 @@
         function(sdk, app) {
     'use strict';
     if ($nnbd) {
-      sdk.dart.nullSafety($isNnbdStrong);
-      sdk.dart.weakNullSafetyWarnings(!$isNnbdStrong);
+      sdk.dart.weakNullSafetyWarnings(!$soundNullSafety);
+      sdk.dart.nonNullAsserts($nonNullAsserts);
     }
     sdk._debugger.registerDevtoolsFormatter();
     app.$libname.main();
@@ -308,8 +309,8 @@
 let main = require(\"./$basename\").$libname.main;
 try {
   if ($nnbd) {
-    sdk.dart.nullSafety($isNnbdStrong);
-    sdk.dart.weakNullSafetyWarnings(!$isNnbdStrong);
+    sdk.dart.weakNullSafetyWarnings(!$soundNullSafety);
+    sdk.dart.nonNullAsserts($nonNullAsserts);
   }
   sdk._isolate_helper.startRootIsolate(main, []);
 } catch(e) {
@@ -342,8 +343,8 @@
 let main = $libname.main;
 try {
   if ($nnbd) {
-    dart.nullSafety($isNnbdStrong);
-    dart.weakNullSafetyWarnings(!$isNnbdStrong);
+    dart.weakNullSafetyWarnings(!$soundNullSafety);
+    dart.nonNullAsserts($nonNullAsserts);
   }
   _isolate_helper.startRootIsolate(() => {}, []);
   main();
diff --git a/pkg/front_end/lib/src/api_prototype/compiler_options.dart b/pkg/front_end/lib/src/api_prototype/compiler_options.dart
index 2e8dc26..558db46 100644
--- a/pkg/front_end/lib/src/api_prototype/compiler_options.dart
+++ b/pkg/front_end/lib/src/api_prototype/compiler_options.dart
@@ -236,6 +236,10 @@
       "."
       "${kernel.defaultLanguageVersion.minor}";
 
+  /// If `true`, a '.d' file with input dependencies is generated when
+  /// compiling the platform dill.
+  bool emitDeps = true;
+
   bool equivalent(CompilerOptions other,
       {bool ignoreOnDiagnostic: true,
       bool ignoreVerbose: true,
@@ -290,6 +294,7 @@
     if (writeFileOnCrashReport != other.writeFileOnCrashReport) return false;
     if (nnbdMode != other.nnbdMode) return false;
     if (currentSdkVersion != other.currentSdkVersion) return false;
+    if (emitDeps != other.emitDeps) return false;
 
     return true;
   }
diff --git a/pkg/front_end/lib/src/api_prototype/experimental_flags_generated.dart b/pkg/front_end/lib/src/api_prototype/experimental_flags_generated.dart
index 26c702a..bc825bc 100644
--- a/pkg/front_end/lib/src/api_prototype/experimental_flags_generated.dart
+++ b/pkg/front_end/lib/src/api_prototype/experimental_flags_generated.dart
@@ -23,16 +23,16 @@
 }
 
 const Version enableAlternativeInvalidationStrategyVersion =
-    const Version(2, 9);
+    const Version(2, 10);
 const Version enableConstantUpdate2018Version = const Version(2, 4);
 const Version enableControlFlowCollectionsVersion = const Version(2, 2);
 const Version enableExtensionMethodsVersion = const Version(2, 6);
-const Version enableNonNullableVersion = const Version(2, 9);
-const Version enableNonfunctionTypeAliasesVersion = const Version(2, 9);
+const Version enableNonNullableVersion = const Version(2, 10);
+const Version enableNonfunctionTypeAliasesVersion = const Version(2, 10);
 const Version enableSetLiteralsVersion = const Version(2, 2);
 const Version enableSpreadCollectionsVersion = const Version(2, 2);
-const Version enableTripleShiftVersion = const Version(2, 9);
-const Version enableVarianceVersion = const Version(2, 9);
+const Version enableTripleShiftVersion = const Version(2, 10);
+const Version enableVarianceVersion = const Version(2, 10);
 
 ExperimentalFlag parseExperimentalFlag(String flag) {
   switch (flag) {
diff --git a/pkg/front_end/lib/src/base/command_line_options.dart b/pkg/front_end/lib/src/base/command_line_options.dart
index 03fe3a2..d8c5e33 100644
--- a/pkg/front_end/lib/src/base/command_line_options.dart
+++ b/pkg/front_end/lib/src/base/command_line_options.dart
@@ -27,6 +27,7 @@
   static const String help = "--help";
   static const String librariesJson = "--libraries-json";
   static const String noDefines = "--no-defines";
+  static const String noDeps = "--no-deps";
   static const String output = "--output";
   static const String packages = "--packages";
   static const String platform = "--platform";
diff --git a/pkg/front_end/lib/src/base/processed_options.dart b/pkg/front_end/lib/src/base/processed_options.dart
index e832549..9421858 100644
--- a/pkg/front_end/lib/src/base/processed_options.dart
+++ b/pkg/front_end/lib/src/base/processed_options.dart
@@ -170,6 +170,8 @@
 
   bool get throwOnWarningsForDebugging => _raw.throwOnWarningsForDebugging;
 
+  bool get emitDeps => _raw.emitDeps;
+
   NnbdMode get nnbdMode => _raw.nnbdMode;
 
   /// The entry-points provided to the compiler.
diff --git a/pkg/front_end/lib/src/fasta/builder/class_builder.dart b/pkg/front_end/lib/src/fasta/builder/class_builder.dart
index 2b7f3a1..a5f2286 100644
--- a/pkg/front_end/lib/src/fasta/builder/class_builder.dart
+++ b/pkg/front_end/lib/src/fasta/builder/class_builder.dart
@@ -62,7 +62,7 @@
 
 import '../modifier.dart';
 
-import '../names.dart' show noSuchMethodName;
+import '../names.dart' show equalsName, noSuchMethodName;
 
 import '../problems.dart' show internalProblem, unhandled, unimplemented;
 
@@ -791,27 +791,30 @@
           "Constructor in override check.", declaredMember.fileOffset, fileUri);
     }
     if (declaredMember is Procedure && interfaceMember is Procedure) {
-      if (declaredMember.kind == ProcedureKind.Method &&
-          interfaceMember.kind == ProcedureKind.Method) {
-        bool seenCovariant = checkMethodOverride(
-            types, declaredMember, interfaceMember, isInterfaceCheck);
-        if (seenCovariant) {
-          handleSeenCovariant(
-              types, declaredMember, interfaceMember, isSetter, callback);
-        }
-      }
-      if (declaredMember.kind == ProcedureKind.Getter &&
-          interfaceMember.kind == ProcedureKind.Getter) {
-        checkGetterOverride(
-            types, declaredMember, interfaceMember, isInterfaceCheck);
-      }
-      if (declaredMember.kind == ProcedureKind.Setter &&
-          interfaceMember.kind == ProcedureKind.Setter) {
-        bool seenCovariant = checkSetterOverride(
-            types, declaredMember, interfaceMember, isInterfaceCheck);
-        if (seenCovariant) {
-          handleSeenCovariant(
-              types, declaredMember, interfaceMember, isSetter, callback);
+      if (declaredMember.kind == interfaceMember.kind) {
+        if (declaredMember.kind == ProcedureKind.Method ||
+            declaredMember.kind == ProcedureKind.Operator) {
+          bool seenCovariant = checkMethodOverride(
+              types, declaredMember, interfaceMember, isInterfaceCheck);
+          if (seenCovariant) {
+            handleSeenCovariant(
+                types, declaredMember, interfaceMember, isSetter, callback);
+          }
+        } else if (declaredMember.kind == ProcedureKind.Getter) {
+          checkGetterOverride(
+              types, declaredMember, interfaceMember, isInterfaceCheck);
+        } else if (declaredMember.kind == ProcedureKind.Setter) {
+          bool seenCovariant = checkSetterOverride(
+              types, declaredMember, interfaceMember, isInterfaceCheck);
+          if (seenCovariant) {
+            handleSeenCovariant(
+                types, declaredMember, interfaceMember, isSetter, callback);
+          }
+        } else {
+          assert(
+              false,
+              "Unexpected procedure kind in override check: "
+              "${declaredMember.kind}");
         }
       }
     } else {
@@ -1093,8 +1096,9 @@
   @override
   bool checkMethodOverride(Types types, Procedure declaredMember,
       Procedure interfaceMember, bool isInterfaceCheck) {
-    assert(declaredMember.kind == ProcedureKind.Method);
-    assert(interfaceMember.kind == ProcedureKind.Method);
+    assert(declaredMember.kind == interfaceMember.kind);
+    assert(declaredMember.kind == ProcedureKind.Method ||
+        declaredMember.kind == ProcedureKind.Operator);
     bool seenCovariant = false;
     FunctionNode declaredFunction = declaredMember.function;
     FunctionNode interfaceFunction = interfaceMember.function;
@@ -1167,6 +1171,17 @@
           declaredFunction.positionalParameters[i];
       VariableDeclaration interfaceParameter =
           interfaceFunction.positionalParameters[i];
+      if (i == 0 &&
+          declaredMember.name == equalsName &&
+          declaredParameter.type ==
+              types.hierarchy.coreTypes.objectNonNullableRawType &&
+          interfaceParameter.type is DynamicType) {
+        // TODO(johnniwinther): Add check for opt-in overrides of operator ==.
+        // `operator ==` methods in opt-out classes have type
+        // `bool Function(dynamic)`.
+        continue;
+      }
+
       _checkTypes(
           types,
           interfaceSubstitution,
@@ -1174,7 +1189,7 @@
           declaredMember,
           interfaceMember,
           declaredParameter.type,
-          interfaceFunction.positionalParameters[i].type,
+          interfaceParameter.type,
           declaredParameter.isCovariant || interfaceParameter.isCovariant,
           declaredParameter,
           isInterfaceCheck);
@@ -1340,6 +1355,10 @@
   void reportInvalidOverride(bool isInterfaceCheck, Member declaredMember,
       Message message, int fileOffset, int length,
       {List<LocatedMessage> context}) {
+    if (shouldOverrideProblemBeOverlooked(this)) {
+      return;
+    }
+
     if (declaredMember.enclosingClass == cls) {
       // Ordinary override
       library.addProblem(message, fileOffset, length, declaredMember.fileUri,
@@ -1769,3 +1788,17 @@
 
   ConstructorRedirection(this.target) : cycleReported = false;
 }
+
+/// Returns `true` if override problems should be overlooked.
+///
+/// This is needed for the current encoding of some JavaScript implementation
+/// classes that are not valid Dart. For instance `JSInt` in
+/// 'dart:_interceptors' that implements both `int` and `double`, and `JsArray`
+/// in `dart:js` that implement both `ListMixin` and `JsObject`.
+bool shouldOverrideProblemBeOverlooked(ClassBuilder classBuilder) {
+  String uri = '${classBuilder.library.importUri}';
+  return uri == 'dart:js' &&
+          classBuilder.fileUri.pathSegments.last == 'js.dart' ||
+      uri == 'dart:_interceptors' &&
+          classBuilder.fileUri.pathSegments.last == 'js_number.dart';
+}
diff --git a/pkg/front_end/lib/src/fasta/builder/field_builder.dart b/pkg/front_end/lib/src/fasta/builder/field_builder.dart
index a04c39f..cbb624a 100644
--- a/pkg/front_end/lib/src/fasta/builder/field_builder.dart
+++ b/pkg/front_end/lib/src/fasta/builder/field_builder.dart
@@ -115,16 +115,14 @@
       Procedure setterReferenceFrom)
       : super(libraryBuilder, charOffset) {
     Uri fileUri = libraryBuilder?.fileUri;
-    if (isExternal) {
-      _fieldEncoding = new ExternalFieldEncoding(
-          fileUri,
-          charOffset,
-          charEndOffset,
-          getterReferenceFrom,
-          setterReferenceFrom,
-          isFinal,
-          isCovariant,
-          library.isNonNullableByDefault);
+    if (isAbstract || isExternal) {
+      _fieldEncoding = new AbstractOrExternalFieldEncoding(fileUri, charOffset,
+          charEndOffset, getterReferenceFrom, setterReferenceFrom,
+          isAbstract: isAbstract,
+          isExternal: isExternal,
+          isFinal: isFinal,
+          isCovariant: isCovariant,
+          isNonNullableByDefault: library.isNonNullableByDefault);
     } else if (isLate &&
         !libraryBuilder.loader.target.backendTarget.supportsLateFields) {
       if (hasInitializer) {
@@ -1321,19 +1319,25 @@
       '_ClassMember($fieldBuilder,$_member,forSetter=${forSetter})';
 }
 
-class ExternalFieldEncoding implements FieldEncoding {
+class AbstractOrExternalFieldEncoding implements FieldEncoding {
+  final bool isAbstract;
+  final bool isExternal;
+
   Procedure _getter;
   Procedure _setter;
 
-  ExternalFieldEncoding(
-      Uri fileUri,
-      int charOffset,
-      int charEndOffset,
-      Procedure getterReference,
-      Procedure setterReference,
+  AbstractOrExternalFieldEncoding(Uri fileUri, int charOffset,
+      int charEndOffset, Procedure getterReference, Procedure setterReference,
+      {this.isAbstract,
+      this.isExternal,
       bool isFinal,
       bool isCovariant,
-      bool isNonNullableByDefault) {
+      bool isNonNullableByDefault})
+      : assert(isAbstract != null),
+        assert(isExternal != null),
+        assert(isFinal != null),
+        assert(isCovariant != null),
+        assert(isNonNullableByDefault != null) {
     _getter = new Procedure(null, ProcedureKind.Getter, new FunctionNode(null),
         fileUri: fileUri, reference: getterReference?.reference)
       ..fileOffset = charOffset
@@ -1406,7 +1410,8 @@
     _getter
       ..isStatic = !isInstanceMember
       ..isExtensionMember = isExtensionMember
-      ..isExternal = true;
+      ..isAbstract = isAbstract
+      ..isExternal = isExternal;
     // TODO(johnniwinther): How can the name already have been computed?
     _getter.name ??= new Name(getterName, libraryBuilder.library);
 
@@ -1423,7 +1428,8 @@
       _setter
         ..isStatic = !isInstanceMember
         ..isExtensionMember = isExtensionMember
-        ..isExternal = true;
+        ..isAbstract = isAbstract
+        ..isExternal = isExternal;
       // TODO(johnniwinther): How can the name already have been computed?
       _setter?.name ??= new Name(setterName, libraryBuilder.library);
     }
diff --git a/pkg/front_end/lib/src/fasta/builder/member_builder.dart b/pkg/front_end/lib/src/fasta/builder/member_builder.dart
index d1a3f67..05c1bc4 100644
--- a/pkg/front_end/lib/src/fasta/builder/member_builder.dart
+++ b/pkg/front_end/lib/src/fasta/builder/member_builder.dart
@@ -59,6 +59,8 @@
 
   bool get isExternal;
 
+  bool get isAbstract;
+
   void buildOutlineExpressions(LibraryBuilder library, CoreTypes coreTypes);
 
   /// Returns the [ClassMember]s for the non-setter members created for this
@@ -124,6 +126,9 @@
   bool get isExternal => (modifiers & externalMask) != 0;
 
   @override
+  bool get isAbstract => (modifiers & abstractMask) != 0;
+
+  @override
   LibraryBuilder get library {
     if (parent is LibraryBuilder) {
       LibraryBuilder library = parent;
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 b4d3941..7bb3453 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
@@ -2042,6 +2042,84 @@
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
+    Message Function(
+        DartType _type,
+        DartType _type2,
+        bool
+            isNonNullableByDefault)> templateInvalidReturn = 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'.""",
+    withArguments: _withArgumentsInvalidReturn);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeInvalidReturn = const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+  "InvalidReturn",
+  templateInvalidReturn,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturn(
+    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(codeInvalidReturn,
+      message:
+          """A value of type '${type}' can't be returned from a function with return type '${type2}'.""" +
+              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,
+        bool
+            isNonNullableByDefault)> templateInvalidReturnAsync = 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'.""",
+    withArguments: _withArgumentsInvalidReturnAsync);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeInvalidReturnAsync = const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+  "InvalidReturnAsync",
+  templateInvalidReturnAsync,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturnAsync(
+    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(codeInvalidReturnAsync,
+      message:
+          """A value of type '${type}' can't be returned from an async function with return type '${type2}'.""" +
+              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,
             bool isNonNullableByDefault)>
     templateMixinApplicationIncompatibleSupertype = const Template<
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 69f4d72..4610fe5 100644
--- a/pkg/front_end/lib/src/fasta/kernel/body_builder.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/body_builder.dart
@@ -696,6 +696,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -707,6 +708,10 @@
     debugEvent("Fields");
     if (!libraryBuilder.isNonNullableByDefault) {
       reportNonNullableModifierError(lateToken);
+      if (abstractToken != null) {
+        handleRecoverableError(
+            fasta.messageAbstractClassMember, abstractToken, abstractToken);
+      }
       if (externalToken != null) {
         handleRecoverableError(
             fasta.messageExternalField, externalToken, externalToken);
@@ -2394,22 +2399,25 @@
     bool isFinal = (currentLocalVariableModifiers & finalMask) != 0;
     bool isLate = (currentLocalVariableModifiers & lateMask) != 0;
     Expression initializer;
-    if (!optional("in", token)) {
+    if (!optional("in", token.next)) {
       // A for-in loop-variable can't have an initializer. So let's remain
       // silent if the next token is `in`. Since a for-in loop can only have
       // one variable it must be followed by `in`.
-      if (isConst) {
-        initializer = buildProblem(
-            fasta.templateConstFieldWithoutInitializer
-                .withArguments(token.lexeme),
-            token.charOffset,
-            token.length);
-      } else if (isFinal && !isLate) {
-        initializer = buildProblem(
-            fasta.templateFinalFieldWithoutInitializer
-                .withArguments(token.lexeme),
-            token.charOffset,
-            token.length);
+      if (!token.isSynthetic) {
+        // If [token] is synthetic it is created from error recovery.
+        if (isConst) {
+          initializer = buildProblem(
+              fasta.templateConstFieldWithoutInitializer
+                  .withArguments(token.lexeme),
+              token.charOffset,
+              token.length);
+        } else if (isFinal && !isLate) {
+          initializer = buildProblem(
+              fasta.templateFinalFieldWithoutInitializer
+                  .withArguments(token.lexeme),
+              token.charOffset,
+              token.length);
+        }
       }
     }
     pushNewLocalVariable(initializer);
@@ -2452,6 +2460,13 @@
     if (member is FieldBuilder) {
       FieldBuilder fieldBuilder = member;
       inLateFieldInitializer = fieldBuilder.isLate;
+      if (fieldBuilder.isAbstract) {
+        addProblem(
+            fasta.messageAbstractFieldInitializer, token.charOffset, noLength);
+      } else if (fieldBuilder.isExternal) {
+        addProblem(
+            fasta.messageExternalFieldInitializer, token.charOffset, noLength);
+      }
     } else {
       inLateFieldInitializer = false;
     }
@@ -5863,7 +5878,21 @@
         ];
       }
       initializedFields[name] = assignmentOffset;
-      if (builder.isFinal && builder.hasInitializer) {
+      if (builder.isAbstract) {
+        return <Initializer>[
+          buildInvalidInitializer(
+              buildProblem(fasta.messageAbstractFieldConstructorInitializer,
+                  fieldNameOffset, name.length),
+              fieldNameOffset)
+        ];
+      } else if (builder.isExternal) {
+        return <Initializer>[
+          buildInvalidInitializer(
+              buildProblem(fasta.messageExternalFieldConstructorInitializer,
+                  fieldNameOffset, name.length),
+              fieldNameOffset)
+        ];
+      } else if (builder.isFinal && builder.hasInitializer) {
         addProblem(
             fasta.templateFinalInstanceVariableAlreadyInitialized
                 .withArguments(name),
diff --git a/pkg/front_end/lib/src/fasta/kernel/class_hierarchy_builder.dart b/pkg/front_end/lib/src/fasta/kernel/class_hierarchy_builder.dart
index 1b9fa19..bce8e77 100644
--- a/pkg/front_end/lib/src/fasta/kernel/class_hierarchy_builder.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/class_hierarchy_builder.dart
@@ -3038,14 +3038,7 @@
           debug?.log("Combined Member Signature: "
               "${bestSoFar.fullName} !<: ${candidate.fullName}");
 
-          String uri = '${classBuilder.library.importUri}';
-          if (uri == 'dart:js' &&
-                  classBuilder.fileUri.pathSegments.last == 'js.dart' ||
-              uri == 'dart:_interceptors' &&
-                  classBuilder.fileUri.pathSegments.last == 'js_number.dart') {
-            // TODO(johnniwinther): Fix the dart2js libraries and remove the
-            // above URIs.
-          } else {
+          if (!shouldOverrideProblemBeOverlooked(classBuilder)) {
             bestSoFar = null;
             bestTypeSoFar = null;
             mutualSubtypes = null;
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 e39ecdb..c7dadc0 100644
--- a/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart
@@ -76,13 +76,16 @@
     Map<String, String> environmentDefines,
     ErrorReporter errorReporter,
     EvaluationMode evaluationMode,
-    {bool keepFields: true,
-    bool evaluateAnnotations: true,
-    bool desugarSets: false,
-    bool enableTripleShift: false,
-    bool errorOnUnevaluatedConstant: false,
+    {bool evaluateAnnotations,
+    bool desugarSets,
+    bool enableTripleShift,
+    bool errorOnUnevaluatedConstant,
     CoreTypes coreTypes,
     ClassHierarchy hierarchy}) {
+  assert(evaluateAnnotations != null);
+  assert(desugarSets != null);
+  assert(enableTripleShift != null);
+  assert(errorOnUnevaluatedConstant != null);
   coreTypes ??= new CoreTypes(component);
   hierarchy ??= new ClassHierarchy(component, coreTypes);
 
@@ -91,7 +94,6 @@
 
   transformLibraries(component.libraries, backend, environmentDefines,
       typeEnvironment, errorReporter, evaluationMode,
-      keepFields: keepFields,
       desugarSets: desugarSets,
       enableTripleShift: enableTripleShift,
       errorOnUnevaluatedConstant: errorOnUnevaluatedConstant,
@@ -106,15 +108,17 @@
     TypeEnvironment typeEnvironment,
     ErrorReporter errorReporter,
     EvaluationMode evaluationMode,
-    {bool keepFields: true,
-    bool evaluateAnnotations: true,
-    bool desugarSets: false,
-    bool enableTripleShift: false,
-    bool errorOnUnevaluatedConstant: false}) {
+    {bool evaluateAnnotations,
+    bool desugarSets,
+    bool enableTripleShift,
+    bool errorOnUnevaluatedConstant}) {
+  assert(evaluateAnnotations != null);
+  assert(desugarSets != null);
+  assert(enableTripleShift != null);
+  assert(errorOnUnevaluatedConstant != null);
   final ConstantsTransformer constantsTransformer = new ConstantsTransformer(
       backend,
       environmentDefines,
-      keepFields,
       evaluateAnnotations,
       desugarSets,
       enableTripleShift,
@@ -127,6 +131,34 @@
   }
 }
 
+void transformProcedure(
+    Procedure procedure,
+    ConstantsBackend backend,
+    Map<String, String> environmentDefines,
+    TypeEnvironment typeEnvironment,
+    ErrorReporter errorReporter,
+    EvaluationMode evaluationMode,
+    {bool evaluateAnnotations: true,
+    bool desugarSets: false,
+    bool enableTripleShift: false,
+    bool errorOnUnevaluatedConstant: false}) {
+  assert(evaluateAnnotations != null);
+  assert(desugarSets != null);
+  assert(enableTripleShift != null);
+  assert(errorOnUnevaluatedConstant != null);
+  final ConstantsTransformer constantsTransformer = new ConstantsTransformer(
+      backend,
+      environmentDefines,
+      evaluateAnnotations,
+      desugarSets,
+      enableTripleShift,
+      errorOnUnevaluatedConstant,
+      typeEnvironment,
+      errorReporter,
+      evaluationMode);
+  constantsTransformer.visitProcedure(procedure);
+}
+
 enum EvaluationMode {
   weak,
   agnostic,
@@ -292,8 +324,6 @@
   final TypeEnvironment typeEnvironment;
   StaticTypeContext _staticTypeContext;
 
-  /// Whether to preserve constant [Field]s.  All use-sites will be rewritten.
-  final bool keepFields;
   final bool evaluateAnnotations;
   final bool desugarSets;
   final bool enableTripleShift;
@@ -302,7 +332,6 @@
   ConstantsTransformer(
       this.backend,
       Map<String, String> environmentDefines,
-      this.keepFields,
       this.evaluateAnnotations,
       this.desugarSets,
       this.enableTripleShift,
@@ -317,6 +346,13 @@
             errorOnUnevaluatedConstant: errorOnUnevaluatedConstant,
             evaluationMode: evaluationMode);
 
+  /// Whether to preserve constant [Field]s. All use-sites will be rewritten.
+  bool get keepFields => backend.keepFields;
+
+  /// Whether to preserve constant [VariableDeclaration]s. All use-sites will be
+  /// rewritten.
+  bool get keepLocals => backend.keepLocals;
+
   // Transform the library/class members:
 
   void convertLibrary(Library library) {
@@ -489,7 +525,7 @@
           ..parent = node;
 
         // If this constant is inlined, remove it.
-        if (shouldInline(node.initializer)) {
+        if (!keepLocals && shouldInline(node.initializer)) {
           if (constant is! UnevaluatedConstant) {
             // If the constant is unevaluated we need to keep the expression,
             // so that, in the case the constant contains error but the local
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 1e8e21e..415e851 100644
--- a/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart
@@ -6,6 +6,7 @@
 
 import 'package:_fe_analyzer_shared/src/util/link.dart';
 import 'package:kernel/ast.dart';
+import 'package:kernel/src/legacy_erasure.dart';
 import 'package:kernel/type_algebra.dart' show Substitution;
 import 'package:kernel/type_environment.dart';
 
@@ -3655,6 +3656,11 @@
         }
         break;
     }
+
+    if (!inferrer.isNonNullableByDefault) {
+      binaryType = legacyErasure(inferrer.coreTypes, binaryType);
+    }
+
     if (!inferrer.isTopLevel && binaryTarget.isNullable) {
       return new ExpressionInferenceResult(
           binaryType,
@@ -3747,6 +3753,11 @@
         }
         break;
     }
+
+    if (!inferrer.isNonNullableByDefault) {
+      unaryType = legacyErasure(inferrer.coreTypes, unaryType);
+    }
+
     if (!inferrer.isTopLevel && unaryTarget.isNullable) {
       // TODO(johnniwinther): Special case 'unary-' in messages. It should
       // probably be referred to as "Unary operator '-' ...".
@@ -3830,6 +3841,11 @@
         }
         break;
     }
+
+    if (!inferrer.isNonNullableByDefault) {
+      readType = legacyErasure(inferrer.coreTypes, readType);
+    }
+
     if (!inferrer.isTopLevel && readTarget.isNullable) {
       return new ExpressionInferenceResult(
           readType,
@@ -4023,6 +4039,11 @@
         }
         break;
     }
+
+    if (!inferrer.isNonNullableByDefault) {
+      readType = legacyErasure(inferrer.coreTypes, readType);
+    }
+
     readResult ??= new ExpressionInferenceResult(readType, read);
     if (!inferrer.isTopLevel && readTarget.isNullable) {
       readResult = inferrer.wrapExpressionInferenceResultInProblem(
@@ -5080,6 +5101,11 @@
     Member target = node.target;
     TypeInferenceEngine.resolveInferenceNode(target);
     DartType type = target.getterType;
+
+    if (!inferrer.isNonNullableByDefault) {
+      type = legacyErasure(inferrer.coreTypes, type);
+    }
+
     if (target is Procedure && target.kind == ProcedureKind.Method) {
       return inferrer.instantiateTearOff(type, typeContext, node);
     } else {
diff --git a/pkg/front_end/lib/src/fasta/kernel/kernel_target.dart b/pkg/front_end/lib/src/fasta/kernel/kernel_target.dart
index d3e1c96..12cbd54 100644
--- a/pkg/front_end/lib/src/fasta/kernel/kernel_target.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/kernel_target.dart
@@ -97,7 +97,6 @@
         messageConstConstructorNonFinalField,
         messageConstConstructorNonFinalFieldCause,
         messageConstConstructorRedirectionToNonConst,
-        messageStrongModeNNBDButOptOut,
         noLength,
         templateFieldNonNullableNotInitializedByConstructorError,
         templateFieldNonNullableWithoutInitializerError,
@@ -122,7 +121,7 @@
 import '../uri_translator.dart' show UriTranslator;
 
 import 'constant_evaluator.dart' as constants
-    show EvaluationMode, transformLibraries;
+    show EvaluationMode, transformLibraries, transformProcedure;
 
 import 'kernel_constants.dart' show KernelConstantErrorReporter;
 
@@ -255,7 +254,7 @@
         if (loader.nnbdMode == NnbdMode.Strong ||
             loader.nnbdMode == NnbdMode.Agnostic) {
           if (!builder.isNonNullableByDefault) {
-            loader.addProblem(messageStrongModeNNBDButOptOut, -1, 1, fileUri);
+            loader.registerStrongOptOutLibrary(builder);
           }
         }
         return builder;
@@ -770,9 +769,9 @@
     List<FieldBuilder> lateFinalFields = <FieldBuilder>[];
 
     builder.forEachDeclaredField((String name, FieldBuilder fieldBuilder) {
-      if (fieldBuilder.isExternal) {
-        // Skip external fields. These are external getters/setters and have
-        // no initialization.
+      if (fieldBuilder.isAbstract || fieldBuilder.isExternal) {
+        // Skip abstract and external fields. These are abstract/external
+        // getters/setters and have no initialization.
         return;
       }
       if (fieldBuilder.isDeclarationInstanceMember && !fieldBuilder.isFinal) {
@@ -871,27 +870,6 @@
           constructor.function.body.parent = constructor.function;
         }
 
-        Set<Field> myInitializedFields = new Set<Field>();
-        for (Initializer initializer in constructor.initializers) {
-          if (initializer is FieldInitializer) {
-            myInitializedFields.add(initializer.field);
-          }
-        }
-        for (VariableDeclaration formal
-            in constructor.function.positionalParameters) {
-          if (formal.isFieldFormal) {
-            Builder fieldBuilder =
-                builder.scope.lookupLocalMember(formal.name, setter: false) ??
-                    builder.origin.scope
-                        .lookupLocalMember(formal.name, setter: false);
-            // If next is not null it's a duplicated field,
-            // and it doesn't need to be initialized to null below
-            // (and doing it will crash serialization).
-            if (fieldBuilder?.next == null && fieldBuilder is FieldBuilder) {
-              myInitializedFields.add(fieldBuilder.field);
-            }
-          }
-        }
         if (constructor.isConst && nonFinalFields.isNotEmpty) {
           builder.addProblem(messageConstConstructorNonFinalField,
               constructor.fileOffset, noLength,
@@ -1092,26 +1070,7 @@
 
     TypeEnvironment environment =
         new TypeEnvironment(loader.coreTypes, loader.hierarchy);
-    constants.EvaluationMode evaluationMode;
-    // If nnbd is not enabled we will use weak evaluation mode. This is needed
-    // because the SDK might be agnostic and therefore needs to be weakened
-    // for legacy mode.
-    assert(
-        isExperimentEnabledGlobally(ExperimentalFlag.nonNullable) ||
-            loader.nnbdMode == NnbdMode.Weak,
-        "Non-weak nnbd mode found without experiment enabled: "
-        "${loader.nnbdMode}.");
-    switch (loader.nnbdMode) {
-      case NnbdMode.Weak:
-        evaluationMode = constants.EvaluationMode.weak;
-        break;
-      case NnbdMode.Strong:
-        evaluationMode = constants.EvaluationMode.strong;
-        break;
-      case NnbdMode.Agnostic:
-        evaluationMode = constants.EvaluationMode.agnostic;
-        break;
-    }
+    constants.EvaluationMode evaluationMode = _getConstantEvaluationMode();
 
     constants.transformLibraries(
         loader.libraries,
@@ -1120,6 +1079,7 @@
         environment,
         new KernelConstantErrorReporter(loader),
         evaluationMode,
+        evaluateAnnotations: true,
         desugarSets: !backendTarget.supportsSetLiterals,
         enableTripleShift:
             isExperimentEnabledGlobally(ExperimentalFlag.tripleShift),
@@ -1141,11 +1101,53 @@
   ChangedStructureNotifier get changedStructureNotifier => null;
 
   void runProcedureTransformations(Procedure procedure) {
+    TypeEnvironment environment =
+        new TypeEnvironment(loader.coreTypes, loader.hierarchy);
+    constants.EvaluationMode evaluationMode = _getConstantEvaluationMode();
+
+    constants.transformProcedure(
+        procedure,
+        backendTarget.constantsBackend(loader.coreTypes),
+        environmentDefines,
+        environment,
+        new KernelConstantErrorReporter(loader),
+        evaluationMode,
+        evaluateAnnotations: true,
+        desugarSets: !backendTarget.supportsSetLiterals,
+        enableTripleShift:
+            isExperimentEnabledGlobally(ExperimentalFlag.tripleShift),
+        errorOnUnevaluatedConstant: errorOnUnevaluatedConstant);
+    ticker.logMs("Evaluated constants");
+
     backendTarget.performTransformationsOnProcedure(
         loader.coreTypes, loader.hierarchy, procedure,
         logger: (String msg) => ticker.logMs(msg));
   }
 
+  constants.EvaluationMode _getConstantEvaluationMode() {
+    constants.EvaluationMode evaluationMode;
+    // If nnbd is not enabled we will use weak evaluation mode. This is needed
+    // because the SDK might be agnostic and therefore needs to be weakened
+    // for legacy mode.
+    assert(
+        isExperimentEnabledGlobally(ExperimentalFlag.nonNullable) ||
+            loader.nnbdMode == NnbdMode.Weak,
+        "Non-weak nnbd mode found without experiment enabled: "
+        "${loader.nnbdMode}.");
+    switch (loader.nnbdMode) {
+      case NnbdMode.Weak:
+        evaluationMode = constants.EvaluationMode.weak;
+        break;
+      case NnbdMode.Strong:
+        evaluationMode = constants.EvaluationMode.strong;
+        break;
+      case NnbdMode.Agnostic:
+        evaluationMode = constants.EvaluationMode.agnostic;
+        break;
+    }
+    return evaluationMode;
+  }
+
   void verify() {
     // TODO(ahe): How to handle errors.
     verifyComponent(component);
diff --git a/pkg/front_end/lib/src/fasta/scope.dart b/pkg/front_end/lib/src/fasta/scope.dart
index 67008ef..c222a16 100644
--- a/pkg/front_end/lib/src/fasta/scope.dart
+++ b/pkg/front_end/lib/src/fasta/scope.dart
@@ -680,6 +680,9 @@
   bool get isExternal => false;
 
   @override
+  bool get isAbstract => false;
+
+  @override
   void set parent(Builder value) {
     throw new UnsupportedError('AmbiguousMemberBuilder.parent=');
   }
diff --git a/pkg/front_end/lib/src/fasta/source/diet_listener.dart b/pkg/front_end/lib/src/fasta/source/diet_listener.dart
index bf3499e..bc81fc6 100644
--- a/pkg/front_end/lib/src/fasta/source/diet_listener.dart
+++ b/pkg/front_end/lib/src/fasta/source/diet_listener.dart
@@ -326,6 +326,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
diff --git a/pkg/front_end/lib/src/fasta/source/outline_builder.dart b/pkg/front_end/lib/src/fasta/source/outline_builder.dart
index 37a9535..53b4729 100644
--- a/pkg/front_end/lib/src/fasta/source/outline_builder.dart
+++ b/pkg/front_end/lib/src/fasta/source/outline_builder.dart
@@ -1686,12 +1686,18 @@
       Token beginToken,
       Token endToken) {
     debugEvent("endTopLevelFields");
-    if (lateToken != null && !libraryBuilder.isNonNullableByDefault) {
+    if (!libraryBuilder.isNonNullableByDefault) {
       reportNonNullableModifierError(lateToken);
       if (externalToken != null) {
-        externalToken = null;
         handleRecoverableError(
             messageExternalField, externalToken, externalToken);
+        externalToken = null;
+      }
+    } else {
+      if (externalToken != null && lateToken != null) {
+        handleRecoverableError(
+            messageExternalLateField, externalToken, externalToken);
+        externalToken = null;
       }
     }
     List<FieldInfo> fieldInfos = popFieldInfos(count);
@@ -1711,6 +1717,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1720,17 +1727,38 @@
       Token beginToken,
       Token endToken) {
     debugEvent("Fields");
-    if (lateToken != null && !libraryBuilder.isNonNullableByDefault) {
+    if (!libraryBuilder.isNonNullableByDefault) {
       reportNonNullableModifierError(lateToken);
+      if (abstractToken != null) {
+        handleRecoverableError(
+            messageAbstractClassMember, abstractToken, abstractToken);
+        abstractToken = null;
+      }
       if (externalToken != null) {
-        externalToken = null;
         handleRecoverableError(
             messageExternalField, externalToken, externalToken);
+        externalToken = null;
+      }
+    } else {
+      if (staticToken != null && abstractToken != null) {
+        handleRecoverableError(
+            messageAbstractStaticField, abstractToken, abstractToken);
+        abstractToken = null;
+      }
+      if (abstractToken != null && lateToken != null) {
+        handleRecoverableError(
+            messageAbstractLateField, abstractToken, abstractToken);
+        abstractToken = null;
+      } else if (externalToken != null && lateToken != null) {
+        handleRecoverableError(
+            messageExternalLateField, externalToken, externalToken);
+        externalToken = null;
       }
     }
     List<FieldInfo> fieldInfos = popFieldInfos(count);
     TypeBuilder type = pop();
-    int modifiers = (externalToken != null ? externalMask : 0) |
+    int modifiers = (abstractToken != null ? abstractMask : 0) |
+        (externalToken != null ? externalMask : 0) |
         (staticToken != null ? staticMask : 0) |
         (covariantToken != null ? covariantMask : 0) |
         (lateToken != null ? lateMask : 0) |
diff --git a/pkg/front_end/lib/src/fasta/source/source_library_builder.dart b/pkg/front_end/lib/src/fasta/source/source_library_builder.dart
index 9d489d6..0f9c220 100644
--- a/pkg/front_end/lib/src/fasta/source/source_library_builder.dart
+++ b/pkg/front_end/lib/src/fasta/source/source_library_builder.dart
@@ -453,15 +453,42 @@
 
   LanguageVersion get languageVersion => _languageVersion;
 
+  void markLanguageVersionFinal() {
+    if (enableNonNullableInLibrary &&
+        (loader.nnbdMode == NnbdMode.Strong ||
+            loader.nnbdMode == NnbdMode.Agnostic)) {
+      // In strong and agnostic mode, the language version is not allowed to
+      // opt a library out of nnbd.
+      if (!isNonNullableByDefault) {
+        if (_languageVersion.isExplicit) {
+          addPostponedProblem(messageStrongModeNNBDButOptOut,
+              _languageVersion.charOffset, _languageVersion.charCount, fileUri);
+        } else {
+          loader.registerStrongOptOutLibrary(this);
+        }
+        _languageVersion = new InvalidLanguageVersion(
+            fileUri,
+            _languageVersion.charOffset,
+            _languageVersion.charCount,
+            _languageVersion.isExplicit,
+            loader.target.currentSdkVersion);
+      }
+    }
+    _languageVersion.isFinal = true;
+  }
+
   @override
   void setLanguageVersion(Version version,
       {int offset: 0, int length: noLength, bool explicit: false}) {
+    assert(!_languageVersion.isFinal);
     if (languageVersion.isExplicit) return;
 
     if (version == null) {
       addPostponedProblem(
           messageLanguageVersionInvalidInDotPackages, offset, length, fileUri);
       if (_languageVersion is ImplicitLanguageVersion) {
+        // If the package set an OK version, but the file set an invalid version
+        // we want to use the package version.
         _languageVersion = new InvalidLanguageVersion(
             fileUri, offset, length, explicit, loader.target.currentSdkVersion);
         library.setLanguageVersion(_languageVersion.version);
@@ -480,6 +507,8 @@
           length,
           fileUri);
       if (_languageVersion is ImplicitLanguageVersion) {
+        // If the package set an OK version, but the file set an invalid version
+        // we want to use the package version.
         _languageVersion = new InvalidLanguageVersion(
             fileUri, offset, length, explicit, loader.target.currentSdkVersion);
         library.setLanguageVersion(_languageVersion.version);
@@ -490,19 +519,6 @@
     _languageVersion =
         new LanguageVersion(version, fileUri, offset, length, explicit);
     library.setLanguageVersion(version);
-
-    if (enableNonNullableInLibrary &&
-        (loader.nnbdMode == NnbdMode.Strong ||
-            loader.nnbdMode == NnbdMode.Agnostic)) {
-      // In strong and agnostic mode, the language version is not allowed to
-      // opt a library out of nnbd.
-      if (!isNonNullableByDefault) {
-        addPostponedProblem(
-            messageStrongModeNNBDButOptOut, offset, length, fileUri);
-        _languageVersion = new InvalidLanguageVersion(
-            fileUri, offset, length, explicit, loader.target.currentSdkVersion);
-      }
-    }
   }
 
   ConstructorReferenceBuilder addConstructorReference(Object name,
@@ -3780,6 +3796,7 @@
   final int charOffset;
   final int charCount;
   final bool isExplicit;
+  bool isFinal = false;
 
   LanguageVersion(this.version, this.fileUri, this.charOffset, this.charCount,
       this.isExplicit);
@@ -3807,6 +3824,7 @@
   final int charCount;
   final bool isExplicit;
   final Version version;
+  bool isFinal = false;
 
   InvalidLanguageVersion(this.fileUri, this.charOffset, this.charCount,
       this.isExplicit, this.version);
@@ -3830,6 +3848,7 @@
 class ImplicitLanguageVersion implements LanguageVersion {
   @override
   final Version version;
+  bool isFinal = false;
 
   ImplicitLanguageVersion(this.version);
 
diff --git a/pkg/front_end/lib/src/fasta/source/source_loader.dart b/pkg/front_end/lib/src/fasta/source/source_loader.dart
index dd1021b..81679f7 100644
--- a/pkg/front_end/lib/src/fasta/source/source_loader.dart
+++ b/pkg/front_end/lib/src/fasta/source/source_loader.dart
@@ -25,6 +25,7 @@
         ScannerResult,
         Token,
         scan;
+import 'package:front_end/src/api_prototype/experimental_flags.dart';
 
 import 'package:kernel/ast.dart'
     show
@@ -53,6 +54,8 @@
 
 import 'package:kernel/reference_from_index.dart' show ReferenceFromIndex;
 
+import 'package:package_config/package_config.dart';
+
 import '../../api_prototype/file_system.dart';
 
 import '../../base/common.dart';
@@ -90,6 +93,7 @@
         messageObjectImplements,
         messageObjectMixesIn,
         messagePartOrphan,
+        messageStrongModeNNBDButOptOut,
         messageTypedefCause,
         messageTypedefUnaliasedTypeCause,
         noLength,
@@ -107,6 +111,7 @@
         templateIllegalMixinDueToConstructorsCause,
         templateInternalProblemUriMissingScheme,
         templateSourceOutlineSummary,
+        templateStrongModeNNBDPackageOptOut,
         templateUntranslatableUri;
 
 import '../kernel/kernel_builder.dart'
@@ -262,8 +267,10 @@
             enableNonNullable: library.isNonNullableByDefault),
         languageVersionChanged:
             (Scanner scanner, LanguageVersionToken version) {
-      library.setLanguageVersion(new Version(version.major, version.minor),
-          offset: version.offset, length: version.length, explicit: true);
+      if (!suppressLexicalErrors) {
+        library.setLanguageVersion(new Version(version.major, version.minor),
+            offset: version.offset, length: version.length, explicit: true);
+      }
       scanner.configuration = new ScannerConfiguration(
           enableTripleShift: library.enableTripleShiftInLibrary,
           enableExtensionMethods: library.enableExtensionMethodsInLibrary,
@@ -290,6 +297,7 @@
           importUri, library.fileUri, result.lineStarts, source);
     }
     library.issuePostponedProblems();
+    library.markLanguageVersionFinal();
     while (token is ErrorToken) {
       if (!suppressLexicalErrors) {
         ErrorToken error = token;
@@ -323,6 +331,79 @@
     }
   }
 
+  Set<LibraryBuilder> _strongOptOutLibraries;
+
+  void registerStrongOptOutLibrary(LibraryBuilder libraryBuilder) {
+    _strongOptOutLibraries ??= {};
+    _strongOptOutLibraries.add(libraryBuilder);
+  }
+
+  @override
+  Future<Null> buildOutlines() async {
+    await super.buildOutlines();
+
+    if (_strongOptOutLibraries != null) {
+      // We have libraries that are opted out in strong mode "non-explicitly",
+      // that is, either implicitly through the package version or loaded from
+      // .dill as opt out.
+      //
+      // To reduce the verbosity of the error messages we try to reduce the
+      // message to only include the package name once for packages that are
+      // opted out.
+      //
+      // We use the current package config to retrieve the package based
+      // language version to determine whether the package as a whole is opted
+      // out. If so, we only include the package name and not the library uri
+      // in the message. For package libraries with no corresponding package
+      // config we include each library uri in the message. For non-package
+      // libraries with no corresponding package config we generate a message
+      // per library.
+      Map<String, List<LibraryBuilder>> libraryByPackage = {};
+      for (LibraryBuilder libraryBuilder in _strongOptOutLibraries) {
+        Package package =
+            target.uriTranslator.getPackage(libraryBuilder.importUri);
+
+        if (package != null &&
+            package.languageVersion != null &&
+            package.languageVersion is! InvalidLanguageVersion) {
+          Version version = new Version(
+              package.languageVersion.major, package.languageVersion.minor);
+          if (version < enableNonNullableVersion) {
+            (libraryByPackage[package?.name] ??= []).add(libraryBuilder);
+            continue;
+          }
+        }
+        if (libraryBuilder.importUri.scheme == 'package') {
+          (libraryByPackage[null] ??= []).add(libraryBuilder);
+        } else {
+          // Emit a message that doesn't mention running 'pub'.
+          addProblem(messageStrongModeNNBDButOptOut, -1, noLength,
+              libraryBuilder.fileUri);
+        }
+      }
+      if (libraryByPackage.isNotEmpty) {
+        List<String> dependencies = [];
+        libraryByPackage.forEach((String name, List<LibraryBuilder> libraries) {
+          if (name != null) {
+            dependencies.add('package:$name');
+          } else {
+            for (LibraryBuilder libraryBuilder in libraries) {
+              dependencies.add(libraryBuilder.importUri.toString());
+            }
+          }
+        });
+        // Emit a message that suggests to run 'pub' to check for opted in
+        // versions of the packages.
+        addProblem(
+            templateStrongModeNNBDPackageOptOut.withArguments(dependencies),
+            -1,
+            -1,
+            null);
+        _strongOptOutLibraries = null;
+      }
+    }
+  }
+
   List<int> getSource(List<int> bytes) {
     // bytes is 0-terminated. We don't want that included.
     if (bytes is Uint8List) {
@@ -354,7 +435,7 @@
           // Part was included in multiple libraries. Skip it here.
           continue;
         }
-        Token tokens = await tokenize(part);
+        Token tokens = await tokenize(part, suppressLexicalErrors: true);
         if (tokens != null) {
           listener.uri = part.fileUri;
           parser.parseUnit(tokens);
@@ -1296,6 +1377,8 @@
   factory List() => null;
   factory List.unmodifiable(elements) => null;
   factory List.filled(int length, E fill, {bool growable = false}) => null;
+  factory List.generate(int length, E generator(int index),
+      {bool growable = true}) => null;
   void add(E) {}
   E operator [](int index) => null;
 }
@@ -1303,11 +1386,13 @@
 class _GrowableList<E> {
   factory _GrowableList() => null;
   factory _GrowableList.filled() => null;
+  factory _GrowableList.generate(int length, E generator(int index)) => null;
 }
 
 class _List<E> {
   factory _List() => null;
   factory _List.filled() => null;
+  factory _List.generate(int length, E generator(int index)) => null;
 }
 
 class MapEntry<K, V> {
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 0251f0c..d0f4ba3 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
@@ -195,7 +195,8 @@
           // nor dynamic, and S is void.
           statement.expression = inferrer.helper.wrapInProblem(
               statement.expression,
-              messageVoidExpression,
+              templateInvalidReturn.withArguments(expressionType,
+                  _declaredReturnType, inferrer.isNonNullableByDefault),
               statement.expression.fileOffset,
               noLength)
             ..parent = statement;
@@ -204,7 +205,9 @@
           // S is not assignable to T.
           Expression expression = inferrer.ensureAssignable(
               _returnContext, expressionType, statement.expression,
-              fileOffset: statement.expression.fileOffset, isVoidAllowed: true);
+              fileOffset: statement.expression.fileOffset,
+              isVoidAllowed: true,
+              errorTemplate: templateInvalidReturn);
           statement.expression = expression..parent = statement;
         }
       }
@@ -481,7 +484,8 @@
           // flatten(S) is neither void, dynamic, Null.
           statement.expression = inferrer.helper.wrapInProblem(
               new NullLiteral()..fileOffset = statement.fileOffset,
-              messageReturnFromVoidFunction,
+              templateInvalidReturnAsync.withArguments(
+                  expressionType, returnType, inferrer.isNonNullableByDefault),
               statement.expression.fileOffset,
               noLength)
             ..parent = statement;
@@ -492,25 +496,11 @@
           // nor dynamic, and flatten(S) is void.
           statement.expression = inferrer.helper.wrapInProblem(
               new NullLiteral()..fileOffset = statement.fileOffset,
-              messageVoidExpression,
+              templateInvalidReturnAsync.withArguments(
+                  expressionType, returnType, inferrer.isNonNullableByDefault),
               statement.expression.fileOffset,
               noLength)
             ..parent = statement;
-/*        } else if (flattenedExpressionType is! VoidType &&
-            !inferrer.isAssignable(futureValueType, expressionType) &&
-            !inferrer.typeSchemaEnvironment
-                .performNullabilityAwareSubtypeCheck(
-                    flattenedExpressionType, futureValueType)
-                .isSubtypeWhenUsingNullabilities()) {
-          // It is a compile-time error if s is `return e;`, flatten(S) is not
-          // void, S is not assignable to T_v, and flatten(S) is not a subtype
-          // of T_v.
-          statement.expression = inferrer.helper.wrapInProblem(
-              new NullLiteral()..fileOffset = statement.fileOffset,
-              messageReturnWithoutExpressionAsync,
-              statement.expression.fileOffset,
-              noLength)
-            ..parent = statement;*/
         } else if (flattenedExpressionType is! VoidType &&
             !inferrer.typeSchemaEnvironment
                 .performNullabilityAwareSubtypeCheck(
@@ -522,8 +512,11 @@
           statement.expression = inferrer.ensureAssignable(
               futureValueType, expressionType, statement.expression,
               fileOffset: statement.expression.fileOffset,
-              runtimeCheckedType: _returnContext,
-              isVoidAllowed: false)
+              runtimeCheckedType:
+                  inferrer.computeGreatestClosure2(_returnContext),
+              declaredContextType: returnType,
+              isVoidAllowed: false,
+              errorTemplate: templateInvalidReturnAsync)
             ..parent = statement;
         }
       }
@@ -559,7 +552,8 @@
               statement.expression,
               fileOffset: statement.fileOffset,
               isVoidAllowed: true,
-              runtimeCheckedType: _returnContext);
+              runtimeCheckedType:
+                  inferrer.computeGreatestClosure(_returnContext));
           statement.expression = expression..parent = statement;
         }
 
diff --git a/pkg/front_end/lib/src/fasta/type_inference/type_inference_engine.dart b/pkg/front_end/lib/src/fasta/type_inference/type_inference_engine.dart
index 5f9c59e..78e2f3e 100644
--- a/pkg/front_end/lib/src/fasta/type_inference/type_inference_engine.dart
+++ b/pkg/front_end/lib/src/fasta/type_inference/type_inference_engine.dart
@@ -276,6 +276,11 @@
         !variable.hasDeclaredInitializer;
   }
 
+  @override
+  bool isNever(DartType type) {
+    return typeEnvironment.coreTypes.isBottom(type);
+  }
+
   // TODO(dmitryas): Consider checking for mutual subtypes instead of ==.
   @override
   bool isSameType(DartType type1, DartType type2) => type1 == type2;
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 6e43379..8a268cb 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
@@ -387,6 +387,13 @@
   /// [contextType], and inserts an implicit downcast, inserts a tear-off, or
   /// reports an error if appropriate.
   ///
+  /// If [declaredContextType] is provided, this is used instead of
+  /// [contextType] for reporting the type against which [expressionType] isn't
+  /// assignable. This is used when checking the assignability of return
+  /// statements in async functions in which the assignability is checked
+  /// against the future value type but the reporting should refer to the
+  /// declared return type.
+  ///
   /// If [runtimeCheckedType] is provided, this is used for the implicit cast,
   /// otherwise [contextType] is used. This is used for return from async
   /// where the returned expression is wrapped in a `Future`, if necessary,
@@ -395,6 +402,7 @@
   Expression ensureAssignable(
       DartType contextType, DartType expressionType, Expression expression,
       {int fileOffset,
+      DartType declaredContextType,
       DartType runtimeCheckedType,
       bool isVoidAllowed: false,
       Template<Message Function(DartType, DartType, bool)> errorTemplate}) {
@@ -444,8 +452,8 @@
         break;
       case AssignabilityKind.unassignable:
         // Error: not assignable.  Perform error recovery.
-        result = _wrapUnassignableExpression(
-            expression, expressionType, contextType, errorTemplate);
+        result = _wrapUnassignableExpression(expression, expressionType,
+            contextType, declaredContextType, errorTemplate);
         break;
       case AssignabilityKind.unassignableVoid:
         // Error: not assignable.  Perform error recovery.
@@ -465,8 +473,12 @@
       case AssignabilityKind.unassignableTearoff:
         TypedTearoff typedTearoff =
             _tearOffCall(expression, expressionType, fileOffset);
-        result = _wrapUnassignableExpression(typedTearoff.tearoff,
-            typedTearoff.tearoffType, contextType, errorTemplate);
+        result = _wrapUnassignableExpression(
+            typedTearoff.tearoff,
+            typedTearoff.tearoffType,
+            contextType,
+            declaredContextType,
+            errorTemplate);
         break;
       case AssignabilityKind.unassignableCantTearoff:
         result = _wrapTearoffErrorExpression(
@@ -505,6 +517,7 @@
       Expression expression,
       DartType expressionType,
       DartType contextType,
+      DartType declaredContextType,
       Template<Message Function(DartType, DartType, bool)> template) {
     Expression errorNode = new AsExpression(
         expression,
@@ -520,7 +533,9 @@
       errorNode = helper.wrapInProblem(
           errorNode,
           (template ?? templateInvalidAssignmentError).withArguments(
-              expressionType, contextType, isNonNullableByDefault),
+              expressionType,
+              declaredContextType ?? contextType,
+              isNonNullableByDefault),
           errorNode.fileOffset,
           noLength);
     }
@@ -845,7 +860,8 @@
       }
       if (includeExtensionMethods) {
         ObjectAccessTarget target = _findExtensionMember(
-            receiverBound, coreTypes.objectClass, name, fileOffset);
+            receiverBound, coreTypes.objectClass, name, fileOffset,
+            setter: setter);
         if (target != null) {
           return target;
         }
@@ -1587,7 +1603,7 @@
             messageVoidExpression, expression.fileOffset, noLength);
       }
     }
-    if (result.inferredType is NeverType) {
+    if (coreTypes.isBottom(result.inferredType)) {
       flowAnalysis.handleExit();
     }
     return result;
@@ -1747,7 +1763,6 @@
       Arguments arguments,
       List<VariableDeclaration> hoistedExpressions,
       {bool isOverloadedArithmeticOperator: false,
-      bool isBinaryOperator: false,
       DartType receiverType,
       DartType returnType,
       bool skipTypeArgumentInference: false,
@@ -2017,6 +2032,10 @@
         "Inferred return type $inferredType contains free variables."
         "Inferred function type: $calleeType.");
 
+    if (!isNonNullableByDefault) {
+      inferredType = legacyErasure(coreTypes, inferredType);
+    }
+
     return new SuccessfulInferenceResult(inferredType);
   }
 
diff --git a/pkg/front_end/lib/src/fasta/util/textual_outline.dart b/pkg/front_end/lib/src/fasta/util/textual_outline.dart
index c3401cb..dca418e 100644
--- a/pkg/front_end/lib/src/fasta/util/textual_outline.dart
+++ b/pkg/front_end/lib/src/fasta/util/textual_outline.dart
@@ -311,7 +311,7 @@
 
 String _textualizeClass(TextualOutlineListener listener, Token beginToken,
     Token endToken, _TextualOutlineState originalState,
-    {bool throwOnUnexpected: false, bool model: false}) {
+    {bool throwOnUnexpected: false}) {
   Token token = beginToken;
   TokenPrinter tokenPrinter = new TokenPrinter();
   // Class header.
@@ -388,6 +388,7 @@
 
   @override
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
diff --git a/pkg/front_end/messages.status b/pkg/front_end/messages.status
index f5a8184..a002f41 100644
--- a/pkg/front_end/messages.status
+++ b/pkg/front_end/messages.status
@@ -5,16 +5,16 @@
 # Note that test/spelling: Status will have no effect. Spelling errors can
 # always be fixed by either spelling correctly or updating the dictionary.
 
-StrongModeNNBDButOptOut/analyzerCode: Fail
-StrongModeNNBDButOptOut/example: Fail
-
 AbstractClassInstantiation/example: Fail
-AbstractClassMember/part_wrapped_script5: Fail
-AbstractClassMember/part_wrapped_script6: Fail
-AbstractClassMember/script5: Fail
-AbstractClassMember/script6: Fail
+AbstractFieldConstructorInitializer/analyzerCode: Fail
+AbstractFieldInitializer/analyzerCode: Fail
+AbstractExtensionField/analyzerCode: Fail
+AbstractExtensionField/example: Fail
+AbstractExternalField/analyzerCode: Fail
+AbstractLateField/analyzerCode: Fail
 AbstractNotSync/example: Fail
 AbstractRedirectedClassInstantiation/example: Fail
+AbstractStaticField/analyzerCode: Fail
 AccessError/analyzerCode: Fail
 AccessError/example: Fail
 AmbiguousExtensionMethod/analyzerCode: Fail
@@ -259,6 +259,9 @@
 ExternalFactoryRedirection/example: Fail
 ExternalFactoryWithBody/part_wrapped_script1: Fail
 ExternalFactoryWithBody/script1: Fail
+ExternalFieldConstructorInitializer/analyzerCode: Fail
+ExternalFieldInitializer/analyzerCode: Fail
+ExternalLateField/analyzerCode: Fail
 ExtraneousModifier/part_wrapped_script1: Fail
 ExtraneousModifier/part_wrapped_script10: Fail
 ExtraneousModifier/part_wrapped_script11: Fail
@@ -415,6 +418,8 @@
 InvalidInitializer/example: Fail
 InvalidPackageUri/analyzerCode: Fail
 InvalidPackageUri/example: Fail
+InvalidReturn/analyzerCode: Fail
+InvalidReturnAsync/analyzerCode: Fail
 InvalidSuperInInitializer/example: Fail
 InvalidThisInInitializer/example: Fail
 InvalidTypeVariableInSupertype/analyzerCode: Fail
@@ -434,6 +439,8 @@
 InvalidVoid/script2: Fail
 JsInteropIndexNotSupported/analyzerCode: Fail # Web compiler specific
 JsInteropIndexNotSupported/example: Fail # Web compiler specific
+JsInteropNamedParameters/analyzerCode: Fail # Web compiler specific
+JsInteropNamedParameters/example: Fail # Web compiler specific
 JsInteropNonExternalConstructor/analyzerCode: Fail # Web compiler specific
 JsInteropNonExternalConstructor/example: Fail # Web compiler specific
 LanguageVersionInvalidInDotPackages/analyzerCode: Fail
@@ -636,6 +643,10 @@
 SpreadMapEntryTypeMismatch/analyzerCode: Fail # There's no analyzer code for that error yet.
 SpreadTypeMismatch/analyzerCode: Fail # There's no analyzer code for that error yet.
 StackOverflow/example: Fail
+StrongModeNNBDButOptOut/analyzerCode: Fail
+StrongModeNNBDButOptOut/example: Fail
+StrongModeNNBDPackageOptOut/analyzerCode: Fail
+StrongModeNNBDPackageOptOut/example: Fail
 SuperAsExpression/example: Fail
 SuperAsIdentifier/example: Fail
 SuperclassHasNoDefaultConstructor/example: Fail
diff --git a/pkg/front_end/messages.yaml b/pkg/front_end/messages.yaml
index 7b44c74..7dc026c 100644
--- a/pkg/front_end/messages.yaml
+++ b/pkg/front_end/messages.yaml
@@ -548,8 +548,53 @@
     - "abstract class C {abstract m();}"
     - "abstract class C {abstract get m;}"
     - "abstract class C {abstract set m(int x);}"
-    - "abstract class C {abstract f;}"
-    - "abstract class C {abstract static f;}"
+    - "abstract class C {abstract var f;}"
+    - "abstract class C {abstract static var f;}"
+
+AbstractExternalField:
+  template: "Fields can't be declared both 'abstract' and 'external'."
+  tip: "Try removing the 'abstract' or 'external' keyword."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {abstract external var f;}"
+    - "abstract class C {external abstract var f;}"
+
+AbstractStaticField:
+  template: "Static fields can't be declared 'abstract'."
+  tip: "Try removing the 'abstract' or 'static' keyword."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {abstract static var f;}"
+
+AbstractExtensionField:
+  template: "Extension fields can't be declared 'abstract'."
+  tip: "Try removing the 'abstract' keyword."
+# Separate class and extension field handling to to support this.
+#  configuration: nnbd-strong
+#  script:
+#    - "extension C on int {abstract static var f;}"
+
+AbstractFieldInitializer:
+  template: "Abstract fields cannot have initializers."
+  tip: "Try removing the initializer or the 'abstract' keyword."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {abstract var f = 0;}"
+
+AbstractFieldConstructorInitializer:
+  template: "Abstract fields cannot have initializers."
+  tip: "Try removing the field initializer or the 'abstract' keyword from the field declaration."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {abstract var f; C(this.f);}"
+    - "abstract class C {abstract var f; C() : this.f = 0;}"
+
+AbstractLateField:
+  template: "Abstract fields cannot be late."
+  tip: "Try removing the 'abstract' or 'late' keyword."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {abstract late var f;}"
 
 ClassInClass:
   index: 53
@@ -735,6 +780,31 @@
   script:
     - "class C { external var f; }"
 
+
+ExternalFieldInitializer:
+  template: "External fields cannot have initializers."
+  tip: "Try removing the initializer or the 'external' keyword."
+  configuration: nnbd-strong
+  script:
+    - "external var f = 0;"
+    - "abstract class C {external var f = 0;}"
+
+ExternalFieldConstructorInitializer:
+  template: "External fields cannot have initializers."
+  tip: "Try removing the field initializer or the 'external' keyword from the field declaration."
+  configuration: nnbd-strong
+  script:
+    - "abstract class C {external var f; C(this.f);}"
+    - "abstract class C {external var f; C() : this.f = 0;}"
+
+ExternalLateField:
+  template: "External fields cannot be late."
+  tip: "Try removing the 'external' or 'late' keyword."
+  configuration: nnbd-strong
+  script:
+    - "external late var f;"
+    - "abstract class C {external late var f;}"
+
 InitializerForStaticField:
   template: "'#name' isn't an instance field of this class."
   analyzerCode: INITIALIZER_FOR_STATIC_FIELD
@@ -1188,6 +1258,16 @@
 StrongModeNNBDButOptOut:
   template: "A library can't opt out of null safety by default, when using sound null safety."
 
+StrongModeNNBDPackageOptOut:
+  template:  |
+    Cannot run with sound null safety as one or more dependencies do not
+    support null safety:
+
+    #names
+
+    Run 'pub outdated --mode=null-safety' to determine if versions of your
+    dependencies supporting null safety are available.
+
 AbstractNotSync:
   template: "Abstract methods can't use 'async', 'async*', or 'sync*'."
   analyzerCode: NON_SYNC_ABSTRACT_METHOD
@@ -3413,6 +3493,16 @@
   configuration: nnbd-strong
   declaration: "Future<int> foo() async { return; }"
 
+InvalidReturn:
+  template: "A value of type '#type' can't be returned from a function with return type '#type2'."
+  configuration: nnbd-strong
+  declaration: "int foo() { return true; }"
+
+InvalidReturnAsync:
+  template: "A value of type '#type' can't be returned from an async function with return type '#type2'."
+  configuration: nnbd-strong
+  declaration: "Future<int> foo() async { return true; }"
+
 ImplicitReturnNull:
   template: "A non-null value must be returned since the return type '#type' doesn't allow null."
   configuration: nnbd-strong
@@ -4022,6 +4112,10 @@
   template: "JS interop classes do not support [] and []= operator methods."
   tip: "Try replacing with a normal method."
 
+JsInteropNamedParameters:
+  template: "Named parameters for JS interop functions are only allowed in a factory constructor of an @anonymous JS class."
+  tip: "Try replacing them with normal or optional parameters."
+
 JsInteropNonExternalConstructor:
   template: "JS interop classes do not support non-external constructors."
   tip: "Try annotating with `external`."
diff --git a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
index 5b5ca89..75db5c6 100644
--- a/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/bracket_mismatch_01.dart.intertwined.expect
@@ -33,7 +33,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, C)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -76,7 +76,7 @@
                 listener: beginMetadataStar(C)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'SimpleType', null, m, DeclarationKind.Class, C, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', null, m, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, m)
                 listener: handleIdentifier(C, typeReference)
                 listener: handleNoTypeArguments(m)
@@ -278,7 +278,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, D, DeclarationKind.Class, D, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, D, DeclarationKind.Class, D, false)
                 listener: beginMethod(null, null, null, null, null, D)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -321,7 +321,7 @@
                 listener: beginMetadataStar(D)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'SimpleType', null, m, DeclarationKind.Class, D, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', null, m, DeclarationKind.Class, D, false)
                 listener: beginMethod(null, null, null, null, null, m)
                 listener: handleIdentifier(D, typeReference)
                 listener: handleNoTypeArguments(m)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect
index fec79f8..a6f2bc7 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_general.crash_dart.intertwined.expect
@@ -33,7 +33,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -71,7 +71,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -133,7 +133,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -190,7 +190,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -227,7 +227,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -271,7 +271,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -318,7 +318,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -372,7 +372,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -439,7 +439,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -517,7 +517,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -560,7 +560,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -610,7 +610,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -657,7 +657,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -711,7 +711,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -778,7 +778,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -857,7 +857,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, external, null, null, null, null, external, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, external, null, null, null, null, external, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(external, null, null, null, null, Foo)
                 listener: handleNoType(external)
                 ensureIdentifierPotentiallyRecovered(external, methodDeclaration, false)
@@ -913,7 +913,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, external, null, null, null, null, external, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, external, null, null, null, null, external, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(external, null, null, null, null, Foo)
                 listener: handleNoType(external)
                 ensureIdentifierPotentiallyRecovered(external, methodDeclaration, false)
@@ -990,13 +990,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(}, null, null, null, null, null, }, Instance of 'SimpleType', Foo, DeclarationKind.Class, Foo, false)
+              parseFields(}, null, null, null, null, null, null, }, Instance of 'SimpleType', Foo, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(Foo)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(Foo, fieldDeclaration)
-                parseFieldInitializerOpt(Foo, Foo, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(Foo, Foo, null, null, null, null, DeclarationKind.Class, Foo)
                   reportRecoverableError(Foo, MemberWithSameNameAsClass)
                     listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo)
                   listener: handleNoFieldInitializer(;)
@@ -1008,23 +1008,23 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', A, DeclarationKind.Class, Foo, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', A, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(A)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(A, fieldDeclaration)
-                parseFieldInitializerOpt(A, A, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(A, A, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(,)
                 ensureIdentifier(,, fieldDeclaration)
                   listener: handleIdentifier(Foo, fieldDeclaration)
-                parseFieldInitializerOpt(Foo, Foo, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(Foo, Foo, null, null, null, null, DeclarationKind.Class, Foo)
                   reportRecoverableError(Foo, MemberWithSameNameAsClass)
                     listener: handleRecoverableError(MemberWithSameNameAsClass, Foo, Foo)
                   listener: handleNoFieldInitializer(,)
                 ensureIdentifier(,, fieldDeclaration)
                   listener: handleIdentifier(B, fieldDeclaration)
-                parseFieldInitializerOpt(B, B, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(B, B, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 3, int, ;)
               listener: endMember()
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect
index c85db7e..5d87d53 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_get.crash_dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -71,7 +71,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -134,7 +134,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect
index 65a470c..9fd9286 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_return_type.crash_dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -71,7 +71,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -134,7 +134,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect
index 700b32f..41adc50 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_bad_name_set.crash_dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -71,7 +71,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -134,7 +134,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect
index 942c9f8..8dd7398 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_get.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -67,7 +67,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -126,7 +126,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
@@ -163,7 +163,7 @@
                 listener: beginMetadataStar(get)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', get, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, get, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(get, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect
index fa9e673..742aa8b 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_ok.dart.intertwined.expect
@@ -33,7 +33,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -65,7 +65,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -121,7 +121,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -157,7 +157,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect
index 83c7426..a035119 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_operator.crash_dart.intertwined.expect
@@ -33,7 +33,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -68,12 +68,12 @@
                 listener: beginMetadataStar(/)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(}, }, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
-                parseInvalidOperatorDeclaration(}, null, null, null, null, null, }, DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(}, }, null, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
+                parseInvalidOperatorDeclaration(}, null, null, null, null, null, null, }, DeclarationKind.Class, Foo)
                   reportRecoverableError(/, MissingOperatorKeyword)
                     listener: handleRecoverableError(MissingOperatorKeyword, /, /)
                   rewriter()
-                  parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
+                  parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
                     listener: beginMethod(null, null, null, null, null, operator)
                     listener: handleNoType(})
                     parseOperatorName(})
@@ -128,7 +128,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -163,7 +163,7 @@
                 listener: beginMetadataStar(.)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(}, }, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(}, }, null, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
                 reportRecoverableErrorWithToken(., Instance of 'Template<(Token) => Message>')
                   listener: handleRecoverableError(Message[ExpectedClassMember, Expected a class member, but got '.'., null, {token: .}], ., .)
                 listener: handleInvalidMember(.)
@@ -174,12 +174,12 @@
                 listener: beginMetadataStar(/)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(., ., null, null, null, null, null, ., Instance of 'NoType', null, DeclarationKind.Class, Foo)
-                parseInvalidOperatorDeclaration(., null, null, null, null, null, ., DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(., ., null, null, null, null, null, null, ., Instance of 'NoType', null, DeclarationKind.Class, Foo)
+                parseInvalidOperatorDeclaration(., null, null, null, null, null, null, ., DeclarationKind.Class, Foo)
                   reportRecoverableError(/, MissingOperatorKeyword)
                     listener: handleRecoverableError(MissingOperatorKeyword, /, /)
                   rewriter()
-                  parseMethod(., null, null, null, null, null, ., Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
+                  parseMethod(., null, null, null, null, null, null, ., Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
                     listener: beginMethod(null, null, null, null, null, operator)
                     listener: handleNoType(.)
                     parseOperatorName(.)
@@ -234,7 +234,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -269,12 +269,12 @@
                 listener: beginMetadataStar(/)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(}, }, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
-                parseInvalidOperatorDeclaration(}, null, null, null, null, null, }, DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(}, }, null, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
+                parseInvalidOperatorDeclaration(}, null, null, null, null, null, null, }, DeclarationKind.Class, Foo)
                   reportRecoverableError(/, MissingOperatorKeyword)
                     listener: handleRecoverableError(MissingOperatorKeyword, /, /)
                   rewriter()
-                  parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
+                  parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
                     listener: beginMethod(null, null, null, null, null, operator)
                     listener: handleNoType(})
                     parseOperatorName(})
@@ -329,7 +329,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -364,7 +364,7 @@
                 listener: beginMetadataStar(.)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(}, }, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(}, }, null, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, Foo)
                 reportRecoverableErrorWithToken(., Instance of 'Template<(Token) => Message>')
                   listener: handleRecoverableError(Message[ExpectedClassMember, Expected a class member, but got '.'., null, {token: .}], ., .)
                 listener: handleInvalidMember(.)
@@ -375,12 +375,12 @@
                 listener: beginMetadataStar(/)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(., ., null, null, null, null, null, ., Instance of 'NoType', null, DeclarationKind.Class, Foo)
-                parseInvalidOperatorDeclaration(., null, null, null, null, null, ., DeclarationKind.Class, Foo)
+              recoverFromInvalidMember(., ., null, null, null, null, null, null, ., Instance of 'NoType', null, DeclarationKind.Class, Foo)
+                parseInvalidOperatorDeclaration(., null, null, null, null, null, null, ., DeclarationKind.Class, Foo)
                   reportRecoverableError(/, MissingOperatorKeyword)
                     listener: handleRecoverableError(MissingOperatorKeyword, /, /)
                   rewriter()
-                  parseMethod(., null, null, null, null, null, ., Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
+                  parseMethod(., null, null, null, null, null, null, ., Instance of 'NoType', null, operator, DeclarationKind.Class, Foo, false)
                     listener: beginMethod(null, null, null, null, null, operator)
                     listener: handleNoType(.)
                     parseOperatorName(.)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect
index b1b218d..4bbafcb 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_return_type.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -65,7 +65,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -122,7 +122,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -159,7 +159,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect
index 572e2e5..223fd14 100644
--- a/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/constructor_recovery_set.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -65,7 +65,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -122,7 +122,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -159,7 +159,7 @@
                 listener: beginMetadataStar(set)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', set, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, set, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect
index a182540..740482c 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026.crash_dart.intertwined.expect
@@ -32,11 +32,11 @@
                 listener: beginMetadataStar(co)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseInvalidOperatorDeclaration({, null, null, null, null, null, {, DeclarationKind.Class, A)
+              parseInvalidOperatorDeclaration({, null, null, null, null, null, null, {, DeclarationKind.Class, A)
                 reportRecoverableError(<, MissingOperatorKeyword)
                   listener: handleRecoverableError(MissingOperatorKeyword, <, <)
                 rewriter()
-                parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, A, false)
+                parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, A, false)
                   listener: beginMethod(null, null, null, null, null, operator)
                   listener: handleIdentifier(co, typeReference)
                   listener: handleNoTypeArguments(operator)
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect
index cc5f502..cb81bba 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39026_prime.crash_dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(co)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, A, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, A, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleIdentifier(co, typeReference)
                 listener: handleNoTypeArguments(operator)
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.expect
index a94d802..9d88a31 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.expect
@@ -37,7 +37,7 @@
           beginVariablesDeclaration(A, null, null)
             handleIdentifier(A, localVariableDeclaration)
             beginInitializedIdentifier(A)
-              handleNoVariableInitializer(<)
+              handleNoVariableInitializer(A)
             endInitializedIdentifier(A)
             handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], A, A)
           endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.intertwined.expect
index e5d85d2..5c0352c 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39060.dart.intertwined.expect
@@ -49,7 +49,7 @@
                             listener: handleIdentifier(A, localVariableDeclaration)
                           listener: beginInitializedIdentifier(A)
                           parseVariableInitializerOpt(A)
-                            listener: handleNoVariableInitializer(<)
+                            listener: handleNoVariableInitializer(A)
                           listener: endInitializedIdentifier(A)
                         ensureSemicolon(A)
                           reportRecoverableError(A, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
index bcf47c6..7bc6caa 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39202.crash_dart.intertwined.expect
@@ -75,7 +75,7 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(b)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'ComplexTypeInfo', $, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'ComplexTypeInfo', $, DeclarationKind.TopLevel, null, false)
         ensureIdentifier(;, typeReference)
           listener: handleIdentifier(b, typeReference)
         listener: beginTypeArguments(<)
@@ -92,7 +92,7 @@
               listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got ''., null, {token: }], , )
             rewriter()
           listener: handleIdentifier(, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(, , null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(, , null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer()
         ensureSemicolon()
           reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
diff --git a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect
index 2310e8e..3784f8cb 100644
--- a/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/issue_39230.crash_dart.intertwined.expect
@@ -33,7 +33,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, C)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -68,12 +68,12 @@
                 listener: beginMetadataStar(/)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(}, }, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, C)
-                parseInvalidOperatorDeclaration(}, null, null, null, null, null, }, DeclarationKind.Class, C)
+              recoverFromInvalidMember(}, }, null, null, null, null, null, null, }, Instance of 'NoType', null, DeclarationKind.Class, C)
+                parseInvalidOperatorDeclaration(}, null, null, null, null, null, null, }, DeclarationKind.Class, C)
                   reportRecoverableError(/, MissingOperatorKeyword)
                     listener: handleRecoverableError(MissingOperatorKeyword, /, /)
                   rewriter()
-                  parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, C, false)
+                  parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, operator, DeclarationKind.Class, C, false)
                     listener: beginMethod(null, null, null, null, null, operator)
                     listener: handleNoType(})
                     parseOperatorName(})
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
index 880586e..71e5c0c 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_fields.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', abstract, DeclarationKind.Class, WrapperClass, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', abstract, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(abstract)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(abstract, fieldDeclaration)
-                parseFieldInitializerOpt(abstract, abstract, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(abstract, abstract, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -55,13 +55,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(as)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(as, fieldDeclaration)
-                parseFieldInitializerOpt(as, as, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(as, as, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -80,7 +80,7 @@
               listener: beginMember()
               isReservedKeyword(assert)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', assert, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', assert, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(assert)
                 listener: handleType(int, null)
@@ -88,7 +88,7 @@
                   reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
                   listener: handleIdentifier(assert, fieldDeclaration)
-                parseFieldInitializerOpt(assert, assert, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(assert, assert, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -105,13 +105,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', async, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', async, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(async)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(async, fieldDeclaration)
-                parseFieldInitializerOpt(async, async, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(async, async, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -128,13 +128,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', await, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', await, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(await)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(await, fieldDeclaration)
-                parseFieldInitializerOpt(await, await, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(await, await, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -153,7 +153,7 @@
               listener: beginMember()
               isReservedKeyword(break)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', break, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', break, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(break)
                 listener: handleType(int, null)
@@ -161,7 +161,7 @@
                   reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
                   listener: handleIdentifier(break, fieldDeclaration)
-                parseFieldInitializerOpt(break, break, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(break, break, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -180,7 +180,7 @@
               listener: beginMember()
               isReservedKeyword(case)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', case, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', case, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(case)
                 listener: handleType(int, null)
@@ -188,7 +188,7 @@
                   reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
                   listener: handleIdentifier(case, fieldDeclaration)
-                parseFieldInitializerOpt(case, case, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(case, case, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -207,7 +207,7 @@
               listener: beginMember()
               isReservedKeyword(catch)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', catch, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', catch, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(catch)
                 listener: handleType(int, null)
@@ -215,7 +215,7 @@
                   reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
                   listener: handleIdentifier(catch, fieldDeclaration)
-                parseFieldInitializerOpt(catch, catch, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(catch, catch, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -234,7 +234,7 @@
               listener: beginMember()
               isReservedKeyword(class)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', class, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', class, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(class)
                 listener: handleType(int, null)
@@ -242,7 +242,7 @@
                   reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
                   listener: handleIdentifier(class, fieldDeclaration)
-                parseFieldInitializerOpt(class, class, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(class, class, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -261,7 +261,7 @@
               listener: beginMember()
               isReservedKeyword(const)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', const, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', const, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(const)
                 listener: handleType(int, null)
@@ -269,7 +269,7 @@
                   reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
                   listener: handleIdentifier(const, fieldDeclaration)
-                parseFieldInitializerOpt(const, const, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(const, const, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -288,7 +288,7 @@
               listener: beginMember()
               isReservedKeyword(continue)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', continue, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', continue, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(continue)
                 listener: handleType(int, null)
@@ -296,7 +296,7 @@
                   reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
                   listener: handleIdentifier(continue, fieldDeclaration)
-                parseFieldInitializerOpt(continue, continue, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(continue, continue, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -313,13 +313,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(covariant)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(covariant, fieldDeclaration)
-                parseFieldInitializerOpt(covariant, covariant, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(covariant, covariant, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -338,7 +338,7 @@
               listener: beginMember()
               isReservedKeyword(default)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', default, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', default, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(default)
                 listener: handleType(int, null)
@@ -346,7 +346,7 @@
                   reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
                   listener: handleIdentifier(default, fieldDeclaration)
-                parseFieldInitializerOpt(default, default, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(default, default, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -363,13 +363,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(deferred)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(deferred, fieldDeclaration)
-                parseFieldInitializerOpt(deferred, deferred, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(deferred, deferred, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -388,7 +388,7 @@
               listener: beginMember()
               isReservedKeyword(do)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', do, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', do, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(do)
                 listener: handleType(int, null)
@@ -396,7 +396,7 @@
                   reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
                   listener: handleIdentifier(do, fieldDeclaration)
-                parseFieldInitializerOpt(do, do, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(do, do, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -413,13 +413,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(dynamic)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(dynamic, fieldDeclaration)
-                parseFieldInitializerOpt(dynamic, dynamic, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(dynamic, dynamic, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -438,7 +438,7 @@
               listener: beginMember()
               isReservedKeyword(else)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', else, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', else, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(else)
                 listener: handleType(int, null)
@@ -446,7 +446,7 @@
                   reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
                   listener: handleIdentifier(else, fieldDeclaration)
-                parseFieldInitializerOpt(else, else, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(else, else, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -465,7 +465,7 @@
               listener: beginMember()
               isReservedKeyword(enum)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', enum, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', enum, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(enum)
                 listener: handleType(int, null)
@@ -473,7 +473,7 @@
                   reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
                   listener: handleIdentifier(enum, fieldDeclaration)
-                parseFieldInitializerOpt(enum, enum, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(enum, enum, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -490,13 +490,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(export)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(export, fieldDeclaration)
-                parseFieldInitializerOpt(export, export, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(export, export, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -515,7 +515,7 @@
               listener: beginMember()
               isReservedKeyword(extends)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', extends, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', extends, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(extends)
                 listener: handleType(int, null)
@@ -523,7 +523,7 @@
                   reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
                   listener: handleIdentifier(extends, fieldDeclaration)
-                parseFieldInitializerOpt(extends, extends, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(extends, extends, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -540,13 +540,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', extension, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', extension, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(extension)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(extension, fieldDeclaration)
-                parseFieldInitializerOpt(extension, extension, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(extension, extension, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -563,13 +563,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(external)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(external, fieldDeclaration)
-                parseFieldInitializerOpt(external, external, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(external, external, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -586,13 +586,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(factory)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(factory, fieldDeclaration)
-                parseFieldInitializerOpt(factory, factory, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(factory, factory, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -611,7 +611,7 @@
               listener: beginMember()
               isReservedKeyword(false)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', false, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', false, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(false)
                 listener: handleType(int, null)
@@ -619,7 +619,7 @@
                   reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
                   listener: handleIdentifier(false, fieldDeclaration)
-                parseFieldInitializerOpt(false, false, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(false, false, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -638,7 +638,7 @@
               listener: beginMember()
               isReservedKeyword(final)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', final, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', final, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(final)
                 listener: handleType(int, null)
@@ -646,7 +646,7 @@
                   reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
                   listener: handleIdentifier(final, fieldDeclaration)
-                parseFieldInitializerOpt(final, final, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(final, final, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -665,7 +665,7 @@
               listener: beginMember()
               isReservedKeyword(finally)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', finally, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', finally, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(finally)
                 listener: handleType(int, null)
@@ -673,7 +673,7 @@
                   reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
                   listener: handleIdentifier(finally, fieldDeclaration)
-                parseFieldInitializerOpt(finally, finally, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(finally, finally, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -692,7 +692,7 @@
               listener: beginMember()
               isReservedKeyword(for)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', for, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', for, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(for)
                 listener: handleType(int, null)
@@ -700,7 +700,7 @@
                   reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
                   listener: handleIdentifier(for, fieldDeclaration)
-                parseFieldInitializerOpt(for, for, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(for, for, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -717,13 +717,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(Function)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(Function, fieldDeclaration)
-                parseFieldInitializerOpt(Function, Function, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(Function, Function, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -741,13 +741,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(get, fieldDeclaration)
-                parseFieldInitializerOpt(get, get, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(get, get, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -764,13 +764,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', hide, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', hide, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(hide)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(hide, fieldDeclaration)
-                parseFieldInitializerOpt(hide, hide, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(hide, hide, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -789,7 +789,7 @@
               listener: beginMember()
               isReservedKeyword(if)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', if, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', if, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(if)
                 listener: handleType(int, null)
@@ -797,7 +797,7 @@
                   reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
                   listener: handleIdentifier(if, fieldDeclaration)
-                parseFieldInitializerOpt(if, if, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(if, if, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -814,13 +814,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(implements)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(implements, fieldDeclaration)
-                parseFieldInitializerOpt(implements, implements, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(implements, implements, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -837,13 +837,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(import)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(import, fieldDeclaration)
-                parseFieldInitializerOpt(import, import, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(import, import, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -862,7 +862,7 @@
               listener: beginMember()
               isReservedKeyword(in)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', in, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', in, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(in)
                 listener: handleType(int, null)
@@ -870,7 +870,7 @@
                   reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
                   listener: handleIdentifier(in, fieldDeclaration)
-                parseFieldInitializerOpt(in, in, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(in, in, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -887,13 +887,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', inout, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', inout, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(inout)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(inout, fieldDeclaration)
-                parseFieldInitializerOpt(inout, inout, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(inout, inout, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -910,13 +910,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(interface)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(interface, fieldDeclaration)
-                parseFieldInitializerOpt(interface, interface, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(interface, interface, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -935,7 +935,7 @@
               listener: beginMember()
               isReservedKeyword(is)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', is, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', is, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(is)
                 listener: handleType(int, null)
@@ -943,7 +943,7 @@
                   reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
                   listener: handleIdentifier(is, fieldDeclaration)
-                parseFieldInitializerOpt(is, is, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(is, is, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -960,13 +960,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', late, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', late, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(late)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(late, fieldDeclaration)
-                parseFieldInitializerOpt(late, late, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(late, late, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -983,13 +983,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(library)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(library, fieldDeclaration)
-                parseFieldInitializerOpt(library, library, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(library, library, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1006,13 +1006,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(mixin)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(mixin, fieldDeclaration)
-                parseFieldInitializerOpt(mixin, mixin, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(mixin, mixin, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1029,13 +1029,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', native, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', native, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(native)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(native, fieldDeclaration)
-                parseFieldInitializerOpt(native, native, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(native, native, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1054,7 +1054,7 @@
               listener: beginMember()
               isReservedKeyword(new)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', new, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', new, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(new)
                 listener: handleType(int, null)
@@ -1062,7 +1062,7 @@
                   reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
                   listener: handleIdentifier(new, fieldDeclaration)
-                parseFieldInitializerOpt(new, new, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(new, new, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1081,7 +1081,7 @@
               listener: beginMember()
               isReservedKeyword(null)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(null)
                 listener: handleType(int, null)
@@ -1089,7 +1089,7 @@
                   reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
                   listener: handleIdentifier(null, fieldDeclaration)
-                parseFieldInitializerOpt(null, null, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(null, null, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1106,13 +1106,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', of, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', of, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(of)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(of, fieldDeclaration)
-                parseFieldInitializerOpt(of, of, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(of, of, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1129,13 +1129,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', on, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', on, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(on)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(on, fieldDeclaration)
-                parseFieldInitializerOpt(on, on, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(on, on, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1153,13 +1153,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isUnaryMinus(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(operator)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(operator, fieldDeclaration)
-                parseFieldInitializerOpt(operator, operator, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(operator, operator, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1176,13 +1176,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', out, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', out, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(out)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(out, fieldDeclaration)
-                parseFieldInitializerOpt(out, out, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(out, out, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1199,13 +1199,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(part)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(part, fieldDeclaration)
-                parseFieldInitializerOpt(part, part, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(part, part, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1222,13 +1222,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', patch, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', patch, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(patch)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(patch, fieldDeclaration)
-                parseFieldInitializerOpt(patch, patch, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(patch, patch, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1245,13 +1245,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', required, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', required, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(required)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(required, fieldDeclaration)
-                parseFieldInitializerOpt(required, required, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(required, required, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1270,7 +1270,7 @@
               listener: beginMember()
               isReservedKeyword(rethrow)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', rethrow, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', rethrow, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(rethrow)
                 listener: handleType(int, null)
@@ -1278,7 +1278,7 @@
                   reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
                   listener: handleIdentifier(rethrow, fieldDeclaration)
-                parseFieldInitializerOpt(rethrow, rethrow, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(rethrow, rethrow, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1297,7 +1297,7 @@
               listener: beginMember()
               isReservedKeyword(return)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', return, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', return, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(return)
                 listener: handleType(int, null)
@@ -1305,7 +1305,7 @@
                   reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
                   listener: handleIdentifier(return, fieldDeclaration)
-                parseFieldInitializerOpt(return, return, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(return, return, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1323,13 +1323,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(set)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(set, fieldDeclaration)
-                parseFieldInitializerOpt(set, set, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(set, set, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1346,13 +1346,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', show, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', show, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(show)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(show, fieldDeclaration)
-                parseFieldInitializerOpt(show, show, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(show, show, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1369,13 +1369,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', source, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', source, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(source)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(source, fieldDeclaration)
-                parseFieldInitializerOpt(source, source, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(source, source, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1392,13 +1392,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(static)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(static, fieldDeclaration)
-                parseFieldInitializerOpt(static, static, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(static, static, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1417,7 +1417,7 @@
               listener: beginMember()
               isReservedKeyword(super)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', super, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', super, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(super)
                 listener: handleType(int, null)
@@ -1425,7 +1425,7 @@
                   reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
                   listener: handleIdentifier(super, fieldDeclaration)
-                parseFieldInitializerOpt(super, super, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(super, super, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1444,7 +1444,7 @@
               listener: beginMember()
               isReservedKeyword(switch)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', switch, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', switch, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(switch)
                 listener: handleType(int, null)
@@ -1452,7 +1452,7 @@
                   reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
                   listener: handleIdentifier(switch, fieldDeclaration)
-                parseFieldInitializerOpt(switch, switch, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(switch, switch, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1469,13 +1469,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', sync, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', sync, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(sync)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(sync, fieldDeclaration)
-                parseFieldInitializerOpt(sync, sync, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(sync, sync, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1492,8 +1492,8 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(int, ;, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass)
-                parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', this, DeclarationKind.Class, WrapperClass, false)
+              recoverFromInvalidMember(int, ;, null, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass)
+                parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', this, DeclarationKind.Class, WrapperClass, false)
                   listener: handleIdentifier(int, typeReference)
                   listener: handleNoTypeArguments(this)
                   listener: handleType(int, null)
@@ -1501,7 +1501,7 @@
                     reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
                       listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
                     listener: handleIdentifier(this, fieldDeclaration)
-                  parseFieldInitializerOpt(this, this, null, null, DeclarationKind.Class, WrapperClass)
+                  parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.Class, WrapperClass)
                     listener: beginFieldInitializer(=)
                     parseExpression(=)
                       parsePrecedenceExpression(=, 1, true)
@@ -1520,7 +1520,7 @@
               listener: beginMember()
               isReservedKeyword(throw)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', throw, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', throw, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(throw)
                 listener: handleType(int, null)
@@ -1528,7 +1528,7 @@
                   reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
                   listener: handleIdentifier(throw, fieldDeclaration)
-                parseFieldInitializerOpt(throw, throw, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(throw, throw, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1547,7 +1547,7 @@
               listener: beginMember()
               isReservedKeyword(true)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', true, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', true, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(true)
                 listener: handleType(int, null)
@@ -1555,7 +1555,7 @@
                   reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
                   listener: handleIdentifier(true, fieldDeclaration)
-                parseFieldInitializerOpt(true, true, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(true, true, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1574,7 +1574,7 @@
               listener: beginMember()
               isReservedKeyword(try)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', try, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', try, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(try)
                 listener: handleType(int, null)
@@ -1582,7 +1582,7 @@
                   reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
                   listener: handleIdentifier(try, fieldDeclaration)
-                parseFieldInitializerOpt(try, try, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(try, try, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1599,13 +1599,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(typedef)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(typedef, fieldDeclaration)
-                parseFieldInitializerOpt(typedef, typedef, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(typedef, typedef, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1624,7 +1624,7 @@
               listener: beginMember()
               isReservedKeyword(var)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', var, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', var, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(var)
                 listener: handleType(int, null)
@@ -1632,7 +1632,7 @@
                   reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
                   listener: handleIdentifier(var, fieldDeclaration)
-                parseFieldInitializerOpt(var, var, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(var, var, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1651,7 +1651,7 @@
               listener: beginMember()
               isReservedKeyword(void)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', void, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', void, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(void)
                 listener: handleType(int, null)
@@ -1659,7 +1659,7 @@
                   reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
                   listener: handleIdentifier(void, fieldDeclaration)
-                parseFieldInitializerOpt(void, void, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(void, void, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1678,7 +1678,7 @@
               listener: beginMember()
               isReservedKeyword(while)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', while, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', while, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(while)
                 listener: handleType(int, null)
@@ -1686,7 +1686,7 @@
                   reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
                   listener: handleIdentifier(while, fieldDeclaration)
-                parseFieldInitializerOpt(while, while, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(while, while, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1705,7 +1705,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.Class, WrapperClass, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.Class, WrapperClass, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(with)
                 listener: handleType(int, null)
@@ -1713,7 +1713,7 @@
                   reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
                   listener: handleIdentifier(with, fieldDeclaration)
-                parseFieldInitializerOpt(with, with, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -1730,13 +1730,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', yield, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', yield, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(yield)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(yield, fieldDeclaration)
-                parseFieldInitializerOpt(yield, yield, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(yield, yield, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
index b80ddaf..d64400c 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.expect
@@ -1992,7 +1992,7 @@
                 handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
                 handleIdentifier(, localVariableDeclaration)
                 beginInitializedIdentifier()
-                  handleNoVariableInitializer(x)
+                  handleNoVariableInitializer()
                 endInitializedIdentifier()
                 handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
               endVariablesDeclaration(1, ;)
@@ -4433,7 +4433,7 @@
               handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
               handleIdentifier(, localVariableDeclaration)
               beginInitializedIdentifier()
-                handleNoVariableInitializer(x)
+                handleNoVariableInitializer()
               endInitializedIdentifier()
               handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
             endVariablesDeclaration(1, ;)
@@ -4520,7 +4520,7 @@
               handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
               handleIdentifier(, localVariableDeclaration)
               beginInitializedIdentifier()
-                handleNoVariableInitializer(x)
+                handleNoVariableInitializer()
               endInitializedIdentifier()
               handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
             endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
index 7c40ac6..eccfc71 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_class_methods.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, abstract, DeclarationKind.Class, WrapperClass, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, abstract, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, abstract)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(abstract)
@@ -173,7 +173,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, as, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, as, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, as)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(as)
@@ -316,7 +316,7 @@
               listener: beginMember()
               isReservedKeyword(assert)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, assert, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, assert, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, assert)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(assert)
@@ -451,7 +451,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, async, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, async, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, async)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(async)
@@ -592,7 +592,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, await, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, await, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, await)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(await)
@@ -738,7 +738,7 @@
               listener: beginMember()
               isReservedKeyword(break)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, break, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, break, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, break)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(break)
@@ -914,7 +914,7 @@
               listener: beginMember()
               isReservedKeyword(case)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, case, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, case, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, case)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(case)
@@ -1058,7 +1058,7 @@
               listener: beginMember()
               isReservedKeyword(catch)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, catch, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, catch, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, catch)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(catch)
@@ -1202,7 +1202,7 @@
               listener: beginMember()
               isReservedKeyword(class)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, class, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, class, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, class)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(class)
@@ -1346,7 +1346,7 @@
               listener: beginMember()
               isReservedKeyword(const)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, const, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, const, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, const)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(const)
@@ -1496,7 +1496,7 @@
               listener: beginMember()
               isReservedKeyword(continue)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, continue, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, continue, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, continue)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(continue)
@@ -1670,7 +1670,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, covariant, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, covariant, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, covariant)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(covariant)
@@ -1813,7 +1813,7 @@
               listener: beginMember()
               isReservedKeyword(default)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, default, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, default, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, default)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(default)
@@ -1955,7 +1955,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, deferred, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, deferred, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, deferred)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(deferred)
@@ -2098,7 +2098,7 @@
               listener: beginMember()
               isReservedKeyword(do)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, do, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, do, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, do)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(do)
@@ -2295,7 +2295,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, dynamic, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, dynamic, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, dynamic)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(dynamic)
@@ -2438,7 +2438,7 @@
               listener: beginMember()
               isReservedKeyword(else)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, else, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, else, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, else)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(else)
@@ -2631,7 +2631,7 @@
               listener: beginMember()
               isReservedKeyword(enum)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, enum, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, enum, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, enum)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(enum)
@@ -2773,7 +2773,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, export, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, export, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, export)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(export)
@@ -2916,7 +2916,7 @@
               listener: beginMember()
               isReservedKeyword(extends)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, extends, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, extends, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, extends)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(extends)
@@ -3058,7 +3058,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, extension, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, extension, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, extension)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(extension)
@@ -3199,7 +3199,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, external, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, external, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, external)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(external)
@@ -3340,7 +3340,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, factory, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, factory, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, factory)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(factory)
@@ -3483,7 +3483,7 @@
               listener: beginMember()
               isReservedKeyword(false)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, false, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, false, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(false)
@@ -3623,7 +3623,7 @@
               listener: beginMember()
               isReservedKeyword(final)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, final, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, final, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, final)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(final)
@@ -3748,7 +3748,7 @@
                               listener: handleIdentifier(, localVariableDeclaration)
                             listener: beginInitializedIdentifier()
                             parseVariableInitializerOpt()
-                              listener: handleNoVariableInitializer(x)
+                              listener: handleNoVariableInitializer()
                             listener: endInitializedIdentifier()
                           ensureSemicolon()
                             reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -3857,7 +3857,7 @@
               listener: beginMember()
               isReservedKeyword(finally)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, finally, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, finally, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, finally)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(finally)
@@ -4001,7 +4001,7 @@
               listener: beginMember()
               isReservedKeyword(for)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, for, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, for, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, for)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(for)
@@ -4208,7 +4208,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, Function, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, Function, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, Function)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(Function)
@@ -4350,7 +4350,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, get, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, get, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, get)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -4491,7 +4491,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, hide, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, hide, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, hide)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(hide)
@@ -4634,7 +4634,7 @@
               listener: beginMember()
               isReservedKeyword(if)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, if, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, if, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, if)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(if)
@@ -4813,7 +4813,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, implements, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, implements, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, implements)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(implements)
@@ -4954,7 +4954,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, import, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, import, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, import)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(import)
@@ -5097,7 +5097,7 @@
               listener: beginMember()
               isReservedKeyword(in)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, in, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, in, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, in)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(in)
@@ -5239,7 +5239,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, inout, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, inout, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, inout)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(inout)
@@ -5380,7 +5380,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, interface, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, interface, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, interface)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(interface)
@@ -5523,7 +5523,7 @@
               listener: beginMember()
               isReservedKeyword(is)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, is, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, is, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, is)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(is)
@@ -5697,7 +5697,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, late, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, late, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, late)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(late)
@@ -5838,7 +5838,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, library, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, library, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, library)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(library)
@@ -5979,7 +5979,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, mixin, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, mixin, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, mixin)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(mixin)
@@ -6120,7 +6120,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, native, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, native, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, native)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(native)
@@ -6263,7 +6263,7 @@
               listener: beginMember()
               isReservedKeyword(new)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, new, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, new, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, new)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(new)
@@ -6413,7 +6413,7 @@
               listener: beginMember()
               isReservedKeyword(null)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, null, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, null, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, null)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(null)
@@ -6551,7 +6551,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, of, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, of, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, of)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(of)
@@ -6692,7 +6692,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, on, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, on, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, on)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(on)
@@ -6834,7 +6834,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isUnaryMinus(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, operator, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, operator, DeclarationKind.Class, WrapperClass, false)
                 isUnaryMinus(()
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleIdentifier(int, typeReference)
@@ -6976,7 +6976,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, out, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, out, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, out)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(out)
@@ -7117,7 +7117,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, part, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, part, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, part)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(part)
@@ -7258,7 +7258,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, patch, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, patch, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, patch)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(patch)
@@ -7399,7 +7399,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, required, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, required, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, required)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(required)
@@ -7542,7 +7542,7 @@
               listener: beginMember()
               isReservedKeyword(rethrow)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, rethrow, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, rethrow, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, rethrow)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(rethrow)
@@ -7686,7 +7686,7 @@
               listener: beginMember()
               isReservedKeyword(return)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, return, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, return, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, return)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(return)
@@ -7826,7 +7826,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, set, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, set, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, set)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(set)
@@ -7967,7 +7967,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, show, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, show, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, show)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(show)
@@ -8108,7 +8108,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, source, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, source, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, source)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(source)
@@ -8249,7 +8249,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, static, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, static, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, static)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(static)
@@ -8392,7 +8392,7 @@
               listener: beginMember()
               isReservedKeyword(super)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, super, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, super, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, super)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(super)
@@ -8531,7 +8531,7 @@
               listener: beginMember()
               isReservedKeyword(switch)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, switch, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, switch, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, switch)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(switch)
@@ -8719,7 +8719,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, sync, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, sync, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, sync)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(sync)
@@ -8860,8 +8860,8 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(int, }, null, null, null, null, null, }, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass)
-                parseFields(}, null, null, null, null, null, }, Instance of 'SimpleType', this, DeclarationKind.Class, WrapperClass, false)
+              recoverFromInvalidMember(int, }, null, null, null, null, null, null, }, Instance of 'SimpleType', null, DeclarationKind.Class, WrapperClass)
+                parseFields(}, null, null, null, null, null, null, }, Instance of 'SimpleType', this, DeclarationKind.Class, WrapperClass, false)
                   listener: handleIdentifier(int, typeReference)
                   listener: handleNoTypeArguments(this)
                   listener: handleType(int, null)
@@ -8869,7 +8869,7 @@
                     reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
                       listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
                     listener: handleIdentifier(this, fieldDeclaration)
-                  parseFieldInitializerOpt(this, this, null, null, DeclarationKind.Class, WrapperClass)
+                  parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.Class, WrapperClass)
                     listener: handleNoFieldInitializer(()
                   ensureSemicolon(this)
                     reportRecoverableError(this, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -8883,8 +8883,8 @@
                 listener: beginMetadataStar(()
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(;, ;, null, null, null, null, null, ;, Instance of 'NoType', null, DeclarationKind.Class, WrapperClass)
-                parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, (, DeclarationKind.Class, WrapperClass, false)
+              recoverFromInvalidMember(;, ;, null, null, null, null, null, null, ;, Instance of 'NoType', null, DeclarationKind.Class, WrapperClass)
+                parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, (, DeclarationKind.Class, WrapperClass, false)
                   listener: beginMethod(null, null, null, null, null, ()
                   listener: handleNoType(;)
                   ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -9023,7 +9023,7 @@
               listener: beginMember()
               isReservedKeyword(throw)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, throw, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, throw, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, throw)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(throw)
@@ -9163,7 +9163,7 @@
               listener: beginMember()
               isReservedKeyword(true)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, true, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, true, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(true)
@@ -9303,7 +9303,7 @@
               listener: beginMember()
               isReservedKeyword(try)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, try, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, try, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, try)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(try)
@@ -9483,7 +9483,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, typedef, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, typedef, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, typedef)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(typedef)
@@ -9626,7 +9626,7 @@
               listener: beginMember()
               isReservedKeyword(var)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, var, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, var, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, var)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(var)
@@ -9751,7 +9751,7 @@
                               listener: handleIdentifier(, localVariableDeclaration)
                             listener: beginInitializedIdentifier()
                             parseVariableInitializerOpt()
-                              listener: handleNoVariableInitializer(x)
+                              listener: handleNoVariableInitializer()
                             listener: endInitializedIdentifier()
                           ensureSemicolon()
                             reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -9860,7 +9860,7 @@
               listener: beginMember()
               isReservedKeyword(void)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, void, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, void, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, void)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(void)
@@ -9986,7 +9986,7 @@
                                 listener: handleIdentifier(, localVariableDeclaration)
                               listener: beginInitializedIdentifier()
                               parseVariableInitializerOpt()
-                                listener: handleNoVariableInitializer(x)
+                                listener: handleNoVariableInitializer()
                               listener: endInitializedIdentifier()
                             ensureSemicolon()
                               reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -10095,7 +10095,7 @@
               listener: beginMember()
               isReservedKeyword(while)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, while, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, while, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, while)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(while)
@@ -10276,7 +10276,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, with, DeclarationKind.Class, WrapperClass, true)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, with, DeclarationKind.Class, WrapperClass, true)
                 listener: beginMethod(null, null, null, null, null, with)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(with)
@@ -10418,7 +10418,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, yield, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, yield, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, yield)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(yield)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
index 20430f0..cf78306 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_fields.dart.intertwined.expect
@@ -8,13 +8,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl()
       listener: beginTopLevelMember(int)
-      parseFields(, null, null, null, null, null, , Instance of 'SimpleType', abstract, DeclarationKind.TopLevel, null, false)
+      parseFields(, null, null, null, null, null, null, , Instance of 'SimpleType', abstract, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(abstract)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(abstract, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(abstract, abstract, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(abstract, abstract, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -31,13 +31,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(as)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(as, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(as, as, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(as, as, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -56,7 +56,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(assert)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', assert, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', assert, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(assert)
         listener: handleType(int, null)
@@ -64,7 +64,7 @@
           reportRecoverableErrorWithToken(assert, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'assert'., null, {token: assert}], assert, assert)
           listener: handleIdentifier(assert, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(assert, assert, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(assert, assert, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -81,13 +81,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', async, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', async, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(async)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(async, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(async, async, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(async, async, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -104,13 +104,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', await, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', await, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(await)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(await, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(await, await, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(await, await, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -129,7 +129,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(break)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', break, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', break, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(break)
         listener: handleType(int, null)
@@ -137,7 +137,7 @@
           reportRecoverableErrorWithToken(break, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'break'., null, {token: break}], break, break)
           listener: handleIdentifier(break, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(break, break, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(break, break, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -156,7 +156,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(case)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', case, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', case, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(case)
         listener: handleType(int, null)
@@ -164,7 +164,7 @@
           reportRecoverableErrorWithToken(case, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'case'., null, {token: case}], case, case)
           listener: handleIdentifier(case, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(case, case, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(case, case, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -183,7 +183,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(catch)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', catch, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', catch, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(catch)
         listener: handleType(int, null)
@@ -191,7 +191,7 @@
           reportRecoverableErrorWithToken(catch, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'catch'., null, {token: catch}], catch, catch)
           listener: handleIdentifier(catch, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(catch, catch, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(catch, catch, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -210,7 +210,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(class)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', class, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', class, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(class)
         listener: handleType(int, null)
@@ -218,7 +218,7 @@
           reportRecoverableErrorWithToken(class, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'class'., null, {token: class}], class, class)
           listener: handleIdentifier(class, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(class, class, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(class, class, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -237,7 +237,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(const)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', const, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', const, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(const)
         listener: handleType(int, null)
@@ -245,7 +245,7 @@
           reportRecoverableErrorWithToken(const, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'const'., null, {token: const}], const, const)
           listener: handleIdentifier(const, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(const, const, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(const, const, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -264,7 +264,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(continue)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', continue, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', continue, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(continue)
         listener: handleType(int, null)
@@ -272,7 +272,7 @@
           reportRecoverableErrorWithToken(continue, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'continue'., null, {token: continue}], continue, continue)
           listener: handleIdentifier(continue, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(continue, continue, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(continue, continue, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -289,13 +289,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(covariant)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(covariant, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(covariant, covariant, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(covariant, covariant, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -314,7 +314,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(default)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', default, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', default, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(default)
         listener: handleType(int, null)
@@ -322,7 +322,7 @@
           reportRecoverableErrorWithToken(default, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'default'., null, {token: default}], default, default)
           listener: handleIdentifier(default, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(default, default, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(default, default, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -339,13 +339,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(deferred)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(deferred, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(deferred, deferred, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(deferred, deferred, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -364,7 +364,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(do)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', do, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', do, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(do)
         listener: handleType(int, null)
@@ -372,7 +372,7 @@
           reportRecoverableErrorWithToken(do, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'do'., null, {token: do}], do, do)
           listener: handleIdentifier(do, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(do, do, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(do, do, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -389,13 +389,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(dynamic)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(dynamic, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(dynamic, dynamic, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(dynamic, dynamic, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -414,7 +414,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(else)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', else, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', else, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(else)
         listener: handleType(int, null)
@@ -422,7 +422,7 @@
           reportRecoverableErrorWithToken(else, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'else'., null, {token: else}], else, else)
           listener: handleIdentifier(else, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(else, else, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(else, else, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -441,7 +441,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(enum)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', enum, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', enum, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(enum)
         listener: handleType(int, null)
@@ -449,7 +449,7 @@
           reportRecoverableErrorWithToken(enum, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'enum'., null, {token: enum}], enum, enum)
           listener: handleIdentifier(enum, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(enum, enum, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(enum, enum, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -466,13 +466,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(export)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(export, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(export, export, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(export, export, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -491,7 +491,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(extends)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', extends, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', extends, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(extends)
         listener: handleType(int, null)
@@ -499,7 +499,7 @@
           reportRecoverableErrorWithToken(extends, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'extends'., null, {token: extends}], extends, extends)
           listener: handleIdentifier(extends, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(extends, extends, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(extends, extends, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -516,13 +516,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', extension, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', extension, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(extension)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(extension, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(extension, extension, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(extension, extension, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -539,13 +539,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(external)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(external, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(external, external, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(external, external, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -562,13 +562,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(factory)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(factory, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(factory, factory, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(factory, factory, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -587,7 +587,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(false)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', false, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', false, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(false)
         listener: handleType(int, null)
@@ -595,7 +595,7 @@
           reportRecoverableErrorWithToken(false, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'false'., null, {token: false}], false, false)
           listener: handleIdentifier(false, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(false, false, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(false, false, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -614,7 +614,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(final)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', final, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', final, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(final)
         listener: handleType(int, null)
@@ -622,7 +622,7 @@
           reportRecoverableErrorWithToken(final, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'final'., null, {token: final}], final, final)
           listener: handleIdentifier(final, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(final, final, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(final, final, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -641,7 +641,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(finally)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', finally, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', finally, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(finally)
         listener: handleType(int, null)
@@ -649,7 +649,7 @@
           reportRecoverableErrorWithToken(finally, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'finally'., null, {token: finally}], finally, finally)
           listener: handleIdentifier(finally, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(finally, finally, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(finally, finally, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -668,7 +668,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(for)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', for, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', for, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(for)
         listener: handleType(int, null)
@@ -676,7 +676,7 @@
           reportRecoverableErrorWithToken(for, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'for'., null, {token: for}], for, for)
           listener: handleIdentifier(for, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(for, for, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(for, for, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -693,13 +693,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(Function)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(Function, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(Function, Function, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(Function, Function, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -716,13 +716,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(get)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(get, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(get, get, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(get, get, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -739,13 +739,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', hide, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', hide, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(hide)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(hide, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(hide, hide, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(hide, hide, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -764,7 +764,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(if)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', if, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', if, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(if)
         listener: handleType(int, null)
@@ -772,7 +772,7 @@
           reportRecoverableErrorWithToken(if, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'if'., null, {token: if}], if, if)
           listener: handleIdentifier(if, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(if, if, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(if, if, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -789,13 +789,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(implements)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(implements, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(implements, implements, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(implements, implements, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -812,13 +812,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(import)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(import, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(import, import, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(import, import, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -837,7 +837,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(in)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', in, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', in, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(in)
         listener: handleType(int, null)
@@ -845,7 +845,7 @@
           reportRecoverableErrorWithToken(in, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'in'., null, {token: in}], in, in)
           listener: handleIdentifier(in, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(in, in, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(in, in, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -862,13 +862,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', inout, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', inout, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(inout)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(inout, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(inout, inout, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(inout, inout, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -885,13 +885,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(interface)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(interface, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(interface, interface, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(interface, interface, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -910,7 +910,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(is)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', is, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', is, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(is)
         listener: handleType(int, null)
@@ -918,7 +918,7 @@
           reportRecoverableErrorWithToken(is, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'is'., null, {token: is}], is, is)
           listener: handleIdentifier(is, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(is, is, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(is, is, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -935,13 +935,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', late, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', late, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(late)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(late, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(late, late, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(late, late, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -958,13 +958,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(library)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(library, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(library, library, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(library, library, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -981,13 +981,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(mixin)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(mixin, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(mixin, mixin, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(mixin, mixin, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1004,13 +1004,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', native, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', native, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(native)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(native, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(native, native, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(native, native, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1029,7 +1029,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(new)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', new, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', new, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(new)
         listener: handleType(int, null)
@@ -1037,7 +1037,7 @@
           reportRecoverableErrorWithToken(new, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'new'., null, {token: new}], new, new)
           listener: handleIdentifier(new, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(new, new, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(new, new, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1056,7 +1056,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(null)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', null, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(null)
         listener: handleType(int, null)
@@ -1064,7 +1064,7 @@
           reportRecoverableErrorWithToken(null, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'null'., null, {token: null}], null, null)
           listener: handleIdentifier(null, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(null, null, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(null, null, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1081,13 +1081,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', of, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', of, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(of)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(of, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(of, of, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(of, of, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1104,13 +1104,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', on, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', on, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(on)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(on, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(on, on, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(on, on, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1127,13 +1127,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(operator)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(operator, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(operator, operator, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(operator, operator, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1150,13 +1150,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', out, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', out, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(out)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(out, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(out, out, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(out, out, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1173,13 +1173,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(part)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(part, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(part, part, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(part, part, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1196,13 +1196,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', patch, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', patch, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(patch)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(patch, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(patch, patch, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(patch, patch, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1219,13 +1219,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', required, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', required, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(required)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(required, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(required, required, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(required, required, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1244,7 +1244,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(rethrow)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', rethrow, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', rethrow, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(rethrow)
         listener: handleType(int, null)
@@ -1252,7 +1252,7 @@
           reportRecoverableErrorWithToken(rethrow, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'rethrow'., null, {token: rethrow}], rethrow, rethrow)
           listener: handleIdentifier(rethrow, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(rethrow, rethrow, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(rethrow, rethrow, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1271,7 +1271,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(return)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', return, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', return, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(return)
         listener: handleType(int, null)
@@ -1279,7 +1279,7 @@
           reportRecoverableErrorWithToken(return, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'return'., null, {token: return}], return, return)
           listener: handleIdentifier(return, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(return, return, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(return, return, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1296,13 +1296,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(set)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(set, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(set, set, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(set, set, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1319,13 +1319,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', show, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', show, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(show)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(show, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(show, show, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(show, show, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1342,13 +1342,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', source, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', source, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(source)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(source, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(source, source, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(source, source, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1365,13 +1365,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(static)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(static, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(static, static, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(static, static, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1390,7 +1390,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(super)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', super, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', super, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(super)
         listener: handleType(int, null)
@@ -1398,7 +1398,7 @@
           reportRecoverableErrorWithToken(super, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'super'., null, {token: super}], super, super)
           listener: handleIdentifier(super, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(super, super, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(super, super, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1417,7 +1417,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(switch)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', switch, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', switch, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(switch)
         listener: handleType(int, null)
@@ -1425,7 +1425,7 @@
           reportRecoverableErrorWithToken(switch, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'switch'., null, {token: switch}], switch, switch)
           listener: handleIdentifier(switch, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(switch, switch, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(switch, switch, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1442,13 +1442,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', sync, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', sync, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(sync)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(sync, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(sync, sync, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(sync, sync, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1465,7 +1465,7 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', this, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', this, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(this)
         listener: handleType(int, null)
@@ -1473,7 +1473,7 @@
           reportRecoverableErrorWithToken(this, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'this'., null, {token: this}], this, this)
           listener: handleIdentifier(this, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(this, this, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(this, this, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1492,7 +1492,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(throw)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', throw, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', throw, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(throw)
         listener: handleType(int, null)
@@ -1500,7 +1500,7 @@
           reportRecoverableErrorWithToken(throw, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'throw'., null, {token: throw}], throw, throw)
           listener: handleIdentifier(throw, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(throw, throw, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(throw, throw, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1519,7 +1519,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(true)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', true, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', true, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(true)
         listener: handleType(int, null)
@@ -1527,7 +1527,7 @@
           reportRecoverableErrorWithToken(true, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'true'., null, {token: true}], true, true)
           listener: handleIdentifier(true, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(true, true, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(true, true, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1546,7 +1546,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(try)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', try, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', try, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(try)
         listener: handleType(int, null)
@@ -1554,7 +1554,7 @@
           reportRecoverableErrorWithToken(try, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'try'., null, {token: try}], try, try)
           listener: handleIdentifier(try, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(try, try, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(try, try, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1571,13 +1571,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(typedef)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(typedef, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(typedef, typedef, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(typedef, typedef, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1596,7 +1596,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(var)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', var, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', var, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(var)
         listener: handleType(int, null)
@@ -1604,7 +1604,7 @@
           reportRecoverableErrorWithToken(var, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'var'., null, {token: var}], var, var)
           listener: handleIdentifier(var, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(var, var, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(var, var, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1623,7 +1623,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(void)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', void, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', void, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(void)
         listener: handleType(int, null)
@@ -1631,7 +1631,7 @@
           reportRecoverableErrorWithToken(void, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'void'., null, {token: void}], void, void)
           listener: handleIdentifier(void, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(void, void, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(void, void, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1650,7 +1650,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(while)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', while, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', while, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(while)
         listener: handleType(int, null)
@@ -1658,7 +1658,7 @@
           reportRecoverableErrorWithToken(while, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'while'., null, {token: while}], while, while)
           listener: handleIdentifier(while, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(while, while, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(while, while, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1677,7 +1677,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(with)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(with)
         listener: handleType(int, null)
@@ -1685,7 +1685,7 @@
           reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
           listener: handleIdentifier(with, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(with, with, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -1702,13 +1702,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', yield, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', yield, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(yield)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(yield, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(yield, yield, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(yield, yield, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
index fffb7b5..45af522 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.expect
@@ -1947,7 +1947,7 @@
           handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
           handleIdentifier(, localVariableDeclaration)
           beginInitializedIdentifier()
-            handleNoVariableInitializer(x)
+            handleNoVariableInitializer()
           endInitializedIdentifier()
           handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
         endVariablesDeclaration(1, ;)
@@ -4338,7 +4338,7 @@
           handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
           handleIdentifier(, localVariableDeclaration)
           beginInitializedIdentifier()
-            handleNoVariableInitializer(x)
+            handleNoVariableInitializer()
           endInitializedIdentifier()
           handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
         endVariablesDeclaration(1, ;)
@@ -4424,7 +4424,7 @@
           handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got '('., null, {token: (}], (, ()
           handleIdentifier(, localVariableDeclaration)
           beginInitializedIdentifier()
-            handleNoVariableInitializer(x)
+            handleNoVariableInitializer()
           endInitializedIdentifier()
           handleRecoverableError(Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}], x, x)
         endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
index c54e05b..f6e0e65 100644
--- a/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/keyword_named_top_level_methods.dart.intertwined.expect
@@ -3624,7 +3624,7 @@
                       listener: handleIdentifier(, localVariableDeclaration)
                     listener: beginInitializedIdentifier()
                     parseVariableInitializerOpt()
-                      listener: handleNoVariableInitializer(x)
+                      listener: handleNoVariableInitializer()
                     listener: endInitializedIdentifier()
                   ensureSemicolon()
                     reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -9439,7 +9439,7 @@
                       listener: handleIdentifier(, localVariableDeclaration)
                     listener: beginInitializedIdentifier()
                     parseVariableInitializerOpt()
-                      listener: handleNoVariableInitializer(x)
+                      listener: handleNoVariableInitializer()
                     listener: endInitializedIdentifier()
                   ensureSemicolon()
                     reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -9670,7 +9670,7 @@
                         listener: handleIdentifier(, localVariableDeclaration)
                       listener: beginInitializedIdentifier()
                       parseVariableInitializerOpt()
-                        listener: handleNoVariableInitializer(x)
+                        listener: handleNoVariableInitializer()
                       listener: endInitializedIdentifier()
                     ensureSemicolon()
                       reportRecoverableError(, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
index 34e33bb..f865ff8 100644
--- a/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with.dart.intertwined.expect
@@ -34,7 +34,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, with, DeclarationKind.Class, C, true)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, with, DeclarationKind.Class, C, true)
                 listener: beginMethod(null, null, null, null, null, with)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(with)
@@ -78,7 +78,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.Class, C, true)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.Class, C, true)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(with)
                 listener: handleType(int, null)
@@ -86,7 +86,7 @@
                   reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
                     listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
                   listener: handleIdentifier(with, fieldDeclaration)
-                parseFieldInitializerOpt(with, with, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -105,7 +105,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(=>)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, with, DeclarationKind.Class, C, true)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, with, DeclarationKind.Class, C, true)
                 listener: beginMethod(null, null, null, null, get, with)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -146,7 +146,7 @@
               listener: beginMember()
               isReservedKeyword(with)
               indicatesMethodOrField(()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'VoidType', set, with, DeclarationKind.Class, C, true)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'VoidType', set, with, DeclarationKind.Class, C, true)
                 listener: beginMethod(null, null, null, null, set, with)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, true)
@@ -237,7 +237,7 @@
       listener: beginTopLevelMember(int)
       isReservedKeyword(with)
       indicatesMethodOrField(=)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.TopLevel, null, true)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', with, DeclarationKind.TopLevel, null, true)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(with)
         listener: handleType(int, null)
@@ -245,7 +245,7 @@
           reportRecoverableErrorWithToken(with, Instance of 'Template<(Token) => Message>')
             listener: handleRecoverableError(Message[ExpectedIdentifier, Expected an identifier, but got 'with'., null, {token: with}], with, with)
           listener: handleIdentifier(with, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(with, with, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(with, with, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect
index bd0176a..06a6ce3 100644
--- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, With, DeclarationKind.Class, C, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, With, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, With)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(With)
@@ -72,13 +72,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', With, DeclarationKind.Class, C, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', With, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(With)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(With, fieldDeclaration)
-                parseFieldInitializerOpt(With, With, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(With, With, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -95,7 +95,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, With, DeclarationKind.Class, C, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, With, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, get, With)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -132,7 +132,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'VoidType', set, With, DeclarationKind.Class, C, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'VoidType', set, With, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, set, With)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -215,13 +215,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', With, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', With, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(With)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(With, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(With, With, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(With, With, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect
index 1dcb53c..c7abc22 100644
--- a/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/method_called_with_prime2.dart.intertwined.expect
@@ -38,13 +38,13 @@
       listener: beginTopLevelMember(foo)
       isReservedKeyword(class)
       indicatesMethodOrField(M1)
-      parseFields(}, null, null, null, null, null, }, Instance of 'NoType', foo, DeclarationKind.TopLevel, null, false)
+      parseFields(}, null, null, null, null, null, null, }, Instance of 'NoType', foo, DeclarationKind.TopLevel, null, false)
         reportRecoverableError(foo, MissingConstFinalVarOrType)
           listener: handleRecoverableError(MissingConstFinalVarOrType, foo, foo)
         listener: handleNoType(})
         ensureIdentifierPotentiallyRecovered(}, topLevelVariableDeclaration, false)
           listener: handleIdentifier(foo, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(foo, foo, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(foo, foo, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(class)
         ensureSemicolon(foo)
           reportRecoverableError(foo, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -84,13 +84,13 @@
               listener: beginMember()
               isReservedKeyword(class)
               indicatesMethodOrField(M2)
-              parseFields({, null, null, null, null, null, {, Instance of 'NoType', foo, DeclarationKind.Class, M1, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'NoType', foo, DeclarationKind.Class, M1, false)
                 reportRecoverableError(foo, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, foo, foo)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, fieldDeclaration, false)
                   listener: handleIdentifier(foo, fieldDeclaration)
-                parseFieldInitializerOpt(foo, foo, null, null, DeclarationKind.Class, M1)
+                parseFieldInitializerOpt(foo, foo, null, null, null, null, DeclarationKind.Class, M1)
                   listener: handleNoFieldInitializer(class)
                 ensureSemicolon(foo)
                   reportRecoverableError(foo, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -104,7 +104,7 @@
                 listener: beginMetadataStar(class)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              recoverFromInvalidMember(;, ;, null, null, null, null, null, ;, Instance of 'NoType', null, DeclarationKind.Class, M1)
+              recoverFromInvalidMember(;, ;, null, null, null, null, null, null, ;, Instance of 'NoType', null, DeclarationKind.Class, M1)
                 reportAndSkipClassInClass(class)
                   reportRecoverableError(class, ClassInClass)
                     listener: handleRecoverableError(ClassInClass, class, class)
diff --git a/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.expect b/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.expect
index 3f36091..15abefb 100644
--- a/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.expect
Binary files differ
diff --git a/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.intertwined.expect
index 3fa4232..4e3a324 100644
--- a/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/error_recovery/utf_16_le_content.crash_dart.intertwined.expect
@@ -28,13 +28,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(/)
       listener: beginTopLevelMember(C)
-      parseFields(/, null, null, null, null, null, /, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
+      parseFields(/, null, null, null, null, null, null, /, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(C, typeReference)
         listener: handleNoTypeArguments(o)
         listener: handleType(C, null)
         ensureIdentifierPotentiallyRecovered(C, topLevelVariableDeclaration, false)
           listener: handleIdentifier(o, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(o, o, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(o, o, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(p)
         ensureSemicolon(o)
           reportRecoverableError(o, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -48,13 +48,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(p)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(p, typeReference)
         listener: handleNoTypeArguments(y)
         listener: handleType(p, null)
         ensureIdentifierPotentiallyRecovered(p, topLevelVariableDeclaration, false)
           listener: handleIdentifier(y, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(y, y, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(r)
         ensureSemicolon(y)
           reportRecoverableError(y, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -68,13 +68,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(r)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(r, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(r, null)
         ensureIdentifierPotentiallyRecovered(r, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(g)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -88,13 +88,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(g)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(g, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(g, null)
         ensureIdentifierPotentiallyRecovered(g, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(t)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -200,13 +200,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(,)
       listener: beginTopLevelMember(t)
-      parseFields(,, null, null, null, null, null, ,, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(,, null, null, null, null, null, null, ,, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(t, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(t, null)
         ensureIdentifierPotentiallyRecovered(t, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -220,13 +220,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', D, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', D, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(D)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(D, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(D, D, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(D, D, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(a)
         ensureSemicolon(D)
           reportRecoverableError(D, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -240,13 +240,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(a)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(a, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(a, null)
         ensureIdentifierPotentiallyRecovered(a, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(t)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -260,13 +260,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(t)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', p, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', p, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(t, typeReference)
         listener: handleNoTypeArguments(p)
         listener: handleType(t, null)
         ensureIdentifierPotentiallyRecovered(t, topLevelVariableDeclaration, false)
           listener: handleIdentifier(p, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(p, p, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(p, p, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(r)
         ensureSemicolon(p)
           reportRecoverableError(p, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -280,13 +280,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(r)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(r, typeReference)
         listener: handleNoTypeArguments(o)
         listener: handleType(r, null)
         ensureIdentifierPotentiallyRecovered(r, topLevelVariableDeclaration, false)
           listener: handleIdentifier(o, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(o, o, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(o, o, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(j)
         ensureSemicolon(o)
           reportRecoverableError(o, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -300,13 +300,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(j)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(j, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(j, null)
         ensureIdentifierPotentiallyRecovered(j, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(c)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -320,13 +320,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(c)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(c, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(c, null)
         ensureIdentifierPotentiallyRecovered(c, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(a)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -340,13 +340,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(a)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(a, typeReference)
         listener: handleNoTypeArguments(u)
         listener: handleType(a, null)
         ensureIdentifierPotentiallyRecovered(a, topLevelVariableDeclaration, false)
           listener: handleIdentifier(u, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(u, u, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(u, u, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(t)
         ensureSemicolon(u)
           reportRecoverableError(u, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -360,13 +360,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(t)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(t, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(t, null)
         ensureIdentifierPotentiallyRecovered(t, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(o)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -380,13 +380,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(o)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(o, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(o, null)
         ensureIdentifierPotentiallyRecovered(o, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -400,7 +400,7 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'PrefixedType', l, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'PrefixedType', l, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, prefixedTypeReference)
         listener: handleIdentifier(P, typeReferenceContinuation)
         listener: handleQualified(.)
@@ -408,7 +408,7 @@
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(P, topLevelVariableDeclaration, false)
           listener: handleIdentifier(l, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(l, l, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(l)
           reportRecoverableError(l, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -422,13 +422,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -442,13 +442,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -462,13 +462,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -482,13 +482,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(h)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -502,13 +502,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(h)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(h, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(h, null)
         ensureIdentifierPotentiallyRecovered(h, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(A)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -522,13 +522,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(A)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', U, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', U, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(A, typeReference)
         listener: handleNoTypeArguments(U)
         listener: handleType(A, null)
         ensureIdentifierPotentiallyRecovered(A, topLevelVariableDeclaration, false)
           listener: handleIdentifier(U, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(U, U, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(U, U, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(T)
         ensureSemicolon(U)
           reportRecoverableError(U, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -542,13 +542,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(T)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', H, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', H, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(T, typeReference)
         listener: handleNoTypeArguments(H)
         listener: handleType(T, null)
         ensureIdentifierPotentiallyRecovered(T, topLevelVariableDeclaration, false)
           listener: handleIdentifier(H, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(H, H, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(H, H, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(O)
         ensureSemicolon(H)
           reportRecoverableError(H, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -562,13 +562,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(O)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', R, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', R, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(O, typeReference)
         listener: handleNoTypeArguments(R)
         listener: handleType(O, null)
         ensureIdentifierPotentiallyRecovered(O, topLevelVariableDeclaration, false)
           listener: handleIdentifier(R, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(R, R, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(R, R, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(S)
         ensureSemicolon(R)
           reportRecoverableError(R, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -582,13 +582,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(S)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', f, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', f, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(S, typeReference)
         listener: handleNoTypeArguments(f)
         listener: handleType(S, null)
         ensureIdentifierPotentiallyRecovered(S, topLevelVariableDeclaration, false)
           listener: handleIdentifier(f, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(f, f, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(f, f, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(f)
           reportRecoverableError(f, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -602,13 +602,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(l)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(l, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(l, l, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(l)
           reportRecoverableError(l, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -623,13 +623,13 @@
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
       isReservedKeyword(/)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'NoType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'NoType', e, DeclarationKind.TopLevel, null, false)
         reportRecoverableError(e, MissingConstFinalVarOrType)
           listener: handleRecoverableError(MissingConstFinalVarOrType, e, e)
         listener: handleNoType(;)
         ensureIdentifierPotentiallyRecovered(;, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(/)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -663,13 +663,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(/)
       listener: beginTopLevelMember(f)
-      parseFields(/, null, null, null, null, null, /, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
+      parseFields(/, null, null, null, null, null, null, /, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(f, typeReference)
         listener: handleNoTypeArguments(o)
         listener: handleType(f, null)
         ensureIdentifierPotentiallyRecovered(f, topLevelVariableDeclaration, false)
           listener: handleIdentifier(o, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(o, o, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(o, o, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(r)
         ensureSemicolon(o)
           reportRecoverableError(o, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -683,13 +683,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(r)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(r, typeReference)
         listener: handleNoTypeArguments(d)
         listener: handleType(r, null)
         ensureIdentifierPotentiallyRecovered(r, topLevelVariableDeclaration, false)
           listener: handleIdentifier(d, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(d, d, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(d, d, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(d)
           reportRecoverableError(d, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -703,13 +703,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(a)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -723,13 +723,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(a)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(a, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(a, null)
         ensureIdentifierPotentiallyRecovered(a, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(l)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -789,13 +789,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(.)
       listener: beginTopLevelMember(A)
-      parseFields(., null, null, null, null, null, ., Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
+      parseFields(., null, null, null, null, null, null, ., Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(A, typeReference)
         listener: handleNoTypeArguments(l)
         listener: handleType(A, null)
         ensureIdentifierPotentiallyRecovered(A, topLevelVariableDeclaration, false)
           listener: handleIdentifier(l, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(l, l, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(l)
         ensureSemicolon(l)
           reportRecoverableError(l, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -809,13 +809,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(l)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(l, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(l, null)
         ensureIdentifierPotentiallyRecovered(l, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -829,13 +829,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', g, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', g, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(g)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(g, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(g, g, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(g, g, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(h)
         ensureSemicolon(g)
           reportRecoverableError(g, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -849,13 +849,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(h)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(h, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(h, null)
         ensureIdentifierPotentiallyRecovered(h, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -869,13 +869,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -889,13 +889,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(s)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(s, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(s, s, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(s, s, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(s)
           reportRecoverableError(s, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -909,13 +909,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(v)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -929,13 +929,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(v)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(v, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(v, null)
         ensureIdentifierPotentiallyRecovered(v, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(d)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -949,7 +949,7 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(d)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'PrefixedType', s, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'PrefixedType', s, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(d, prefixedTypeReference)
         listener: handleIdentifier(U, typeReferenceContinuation)
         listener: handleQualified(.)
@@ -957,7 +957,7 @@
         listener: handleType(d, null)
         ensureIdentifierPotentiallyRecovered(U, topLevelVariableDeclaration, false)
           listener: handleIdentifier(s, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(s, s, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(s, s, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(s)
           reportRecoverableError(s, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -971,13 +971,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', o, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(o)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(o, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(o, o, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(o, o, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(f)
         ensureSemicolon(o)
           reportRecoverableError(o, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -991,13 +991,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(f)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(f, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(f, null)
         ensureIdentifierPotentiallyRecovered(f, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(h)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1011,13 +1011,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(h)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(h, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(h, null)
         ensureIdentifierPotentiallyRecovered(h, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1031,13 +1031,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(s)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(s, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(s, s, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(s, s, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(o)
         ensureSemicolon(s)
           reportRecoverableError(s, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1051,13 +1051,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(o)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(o, typeReference)
         listener: handleNoTypeArguments(u)
         listener: handleType(o, null)
         ensureIdentifierPotentiallyRecovered(o, topLevelVariableDeclaration, false)
           listener: handleIdentifier(u, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(u, u, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(u, u, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(r)
         ensureSemicolon(u)
           reportRecoverableError(u, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1071,13 +1071,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(r)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(r, typeReference)
         listener: handleNoTypeArguments(c)
         listener: handleType(r, null)
         ensureIdentifierPotentiallyRecovered(r, topLevelVariableDeclaration, false)
           listener: handleIdentifier(c, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(c, c, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(c, c, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(c)
           reportRecoverableError(c, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1091,13 +1091,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(c)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(c, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(c, c, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(c, c, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(o)
         ensureSemicolon(c)
           reportRecoverableError(c, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1111,13 +1111,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(o)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(o, typeReference)
         listener: handleNoTypeArguments(d)
         listener: handleType(o, null)
         ensureIdentifierPotentiallyRecovered(o, topLevelVariableDeclaration, false)
           listener: handleIdentifier(d, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(d, d, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(d, d, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(d)
           reportRecoverableError(d, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1131,13 +1131,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1151,13 +1151,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', g, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', g, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(g)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(g, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(g, g, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(g, g, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(o)
         ensureSemicolon(g)
           reportRecoverableError(g, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1171,13 +1171,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(o)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', v, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', v, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(o, typeReference)
         listener: handleNoTypeArguments(v)
         listener: handleType(o, null)
         ensureIdentifierPotentiallyRecovered(o, topLevelVariableDeclaration, false)
           listener: handleIdentifier(v, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(v, v, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(v, v, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(v)
           reportRecoverableError(v, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1191,13 +1191,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(r)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(r, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(r, r, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(n)
         ensureSemicolon(r)
           reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1211,13 +1211,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(n)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(n, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(n, null)
         ensureIdentifierPotentiallyRecovered(n, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(d)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1231,13 +1231,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(d)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', b, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', b, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(d, typeReference)
         listener: handleNoTypeArguments(b)
         listener: handleType(d, null)
         ensureIdentifierPotentiallyRecovered(d, topLevelVariableDeclaration, false)
           listener: handleIdentifier(b, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(b, b, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(b, b, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(y)
         ensureSemicolon(b)
           reportRecoverableError(b, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1251,13 +1251,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(y)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(y, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(y, null)
         ensureIdentifierPotentiallyRecovered(y, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(/)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1291,13 +1291,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(/)
       listener: beginTopLevelMember(B)
-      parseFields(/, null, null, null, null, null, /, Instance of 'SimpleType', S, DeclarationKind.TopLevel, null, false)
+      parseFields(/, null, null, null, null, null, null, /, Instance of 'SimpleType', S, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(B, typeReference)
         listener: handleNoTypeArguments(S)
         listener: handleType(B, null)
         ensureIdentifierPotentiallyRecovered(B, topLevelVariableDeclaration, false)
           listener: handleIdentifier(S, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(S, S, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(S, S, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(D)
         ensureSemicolon(S)
           reportRecoverableError(S, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1312,13 +1312,13 @@
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(D)
       isReservedKeyword(-)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'NoType', D, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'NoType', D, DeclarationKind.TopLevel, null, false)
         reportRecoverableError(D, MissingConstFinalVarOrType)
           listener: handleRecoverableError(MissingConstFinalVarOrType, D, D)
         listener: handleNoType(;)
         ensureIdentifierPotentiallyRecovered(;, topLevelVariableDeclaration, false)
           listener: handleIdentifier(D, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(D, D, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(D, D, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(-)
         ensureSemicolon(D)
           reportRecoverableError(D, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1342,13 +1342,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(-)
       listener: beginTopLevelMember(s)
-      parseFields(-, null, null, null, null, null, -, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(-, null, null, null, null, null, null, -, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(y)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1362,13 +1362,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(y)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(y, typeReference)
         listener: handleNoTypeArguments(l)
         listener: handleType(y, null)
         ensureIdentifierPotentiallyRecovered(y, topLevelVariableDeclaration, false)
           listener: handleIdentifier(l, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(l, l, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(l)
           reportRecoverableError(l, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1382,13 +1382,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', l, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(l)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(l, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(l, l, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(l)
           reportRecoverableError(l, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1402,13 +1402,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', c, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(c)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(c, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(c, c, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(c, c, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(c)
           reportRecoverableError(c, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1422,13 +1422,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', n, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', n, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(n)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(n, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(n, n, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(n, n, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(n)
           reportRecoverableError(n, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1442,13 +1442,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(t)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1462,13 +1462,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(t)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(t, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(t, null)
         ensureIdentifierPotentiallyRecovered(t, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(a)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1482,13 +1482,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(a)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', t, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(a, typeReference)
         listener: handleNoTypeArguments(t)
         listener: handleType(a, null)
         ensureIdentifierPotentiallyRecovered(a, topLevelVariableDeclaration, false)
           listener: handleIdentifier(t, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(t, t, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(t, t, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(c)
         ensureSemicolon(t)
           reportRecoverableError(t, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1502,13 +1502,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(c)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(c, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(c, null)
         ensureIdentifierPotentiallyRecovered(c, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(n)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1522,13 +1522,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(n)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', b, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', b, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(n, typeReference)
         listener: handleNoTypeArguments(b)
         listener: handleType(n, null)
         ensureIdentifierPotentiallyRecovered(n, topLevelVariableDeclaration, false)
           listener: handleIdentifier(b, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(b, b, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(b, b, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(b)
           reportRecoverableError(b, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1542,13 +1542,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', f, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', f, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(f)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(f, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(f, f, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(f, f, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(o)
         ensureSemicolon(f)
           reportRecoverableError(f, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1562,13 +1562,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(o)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', u, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(o, typeReference)
         listener: handleNoTypeArguments(u)
         listener: handleType(o, null)
         ensureIdentifierPotentiallyRecovered(o, topLevelVariableDeclaration, false)
           listener: handleIdentifier(u, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(u, u, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(u, u, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(n)
         ensureSemicolon(u)
           reportRecoverableError(u, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1582,13 +1582,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(n)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(n, typeReference)
         listener: handleNoTypeArguments(d)
         listener: handleType(n, null)
         ensureIdentifierPotentiallyRecovered(n, topLevelVariableDeclaration, false)
           listener: handleIdentifier(d, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(d, d, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(d, d, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(d)
           reportRecoverableError(d, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1602,13 +1602,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', n, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', n, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(n)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(n, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(n, n, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(n, n, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(t)
         ensureSemicolon(n)
           reportRecoverableError(n, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1622,13 +1622,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(t)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(t, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(t, null)
         ensureIdentifierPotentiallyRecovered(t, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(e)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1642,13 +1642,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(e)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', L, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', L, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(e, typeReference)
         listener: handleNoTypeArguments(L)
         listener: handleType(e, null)
         ensureIdentifierPotentiallyRecovered(e, topLevelVariableDeclaration, false)
           listener: handleIdentifier(L, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(L, L, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(L, L, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(I)
         ensureSemicolon(L)
           reportRecoverableError(L, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1662,13 +1662,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(I)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', C, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', C, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(I, typeReference)
         listener: handleNoTypeArguments(C)
         listener: handleType(I, null)
         ensureIdentifierPotentiallyRecovered(I, topLevelVariableDeclaration, false)
           listener: handleIdentifier(C, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(C, C, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(C, C, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(E)
         ensureSemicolon(C)
           reportRecoverableError(C, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1682,13 +1682,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(E)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', N, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', N, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(E, typeReference)
         listener: handleNoTypeArguments(N)
         listener: handleType(E, null)
         ensureIdentifierPotentiallyRecovered(E, topLevelVariableDeclaration, false)
           listener: handleIdentifier(N, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(N, N, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(N, N, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(S)
         ensureSemicolon(N)
           reportRecoverableError(N, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1748,13 +1748,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(.)
       listener: beginTopLevelMember(m)
-      parseFields(., null, null, null, null, null, ., Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
+      parseFields(., null, null, null, null, null, null, ., Instance of 'SimpleType', d, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(m, typeReference)
         listener: handleNoTypeArguments(d)
         listener: handleType(m, null)
         ensureIdentifierPotentiallyRecovered(m, topLevelVariableDeclaration, false)
           listener: handleIdentifier(d, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(d, d, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(d, d, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(f)
         ensureSemicolon(d)
           reportRecoverableError(d, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1768,13 +1768,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(f)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(f, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(f, null)
         ensureIdentifierPotentiallyRecovered(f, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(l)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1854,13 +1854,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(/)
       listener: beginTopLevelMember(T)
-      parseFields(/, null, null, null, null, null, /, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
+      parseFields(/, null, null, null, null, null, null, /, Instance of 'SimpleType', h, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(T, typeReference)
         listener: handleNoTypeArguments(h)
         listener: handleType(T, null)
         ensureIdentifierPotentiallyRecovered(T, topLevelVariableDeclaration, false)
           listener: handleIdentifier(h, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(h, h, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(h, h, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(h)
           reportRecoverableError(h, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1874,13 +1874,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(s)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(s, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(s, s, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(s, s, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(f)
         ensureSemicolon(s)
           reportRecoverableError(s, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1894,13 +1894,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(f)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', i, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(f, typeReference)
         listener: handleNoTypeArguments(i)
         listener: handleType(f, null)
         ensureIdentifierPotentiallyRecovered(f, topLevelVariableDeclaration, false)
           listener: handleIdentifier(i, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(i, i, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(i, i, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(l)
         ensureSemicolon(i)
           reportRecoverableError(i, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1914,13 +1914,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(l)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(l, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(l, null)
         ensureIdentifierPotentiallyRecovered(l, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1934,13 +1934,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(i)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', s, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(i, typeReference)
         listener: handleNoTypeArguments(s)
         listener: handleType(i, null)
         ensureIdentifierPotentiallyRecovered(i, topLevelVariableDeclaration, false)
           listener: handleIdentifier(s, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(s, s, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(s, s, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(s)
           reportRecoverableError(s, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1954,13 +1954,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(v)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1974,13 +1974,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(v)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', e, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(v, typeReference)
         listener: handleNoTypeArguments(e)
         listener: handleType(v, null)
         ensureIdentifierPotentiallyRecovered(v, topLevelVariableDeclaration, false)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(d)
         ensureSemicolon(e)
           reportRecoverableError(e, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -1994,13 +1994,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(d)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(d, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(d, null)
         ensureIdentifierPotentiallyRecovered(d, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(s)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -2014,13 +2014,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(s)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', U, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', U, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(s, typeReference)
         listener: handleNoTypeArguments(U)
         listener: handleType(s, null)
         ensureIdentifierPotentiallyRecovered(s, topLevelVariableDeclaration, false)
           listener: handleIdentifier(U, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(U, U, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(U, U, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(T)
         ensureSemicolon(U)
           reportRecoverableError(U, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -2034,13 +2034,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(T)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', F, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', F, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(T, typeReference)
         listener: handleNoTypeArguments(F)
         listener: handleType(T, null)
         ensureIdentifierPotentiallyRecovered(T, topLevelVariableDeclaration, false)
           listener: handleIdentifier(F, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(F, F, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(F, F, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(-)
         ensureSemicolon(F)
           reportRecoverableError(F, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -2130,13 +2130,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(.)
       listener: beginTopLevelMember(m)
-      parseFields(., null, null, null, null, null, ., Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(., null, null, null, null, null, null, ., Instance of 'SimpleType', a, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(m, typeReference)
         listener: handleNoTypeArguments(a)
         listener: handleType(m, null)
         ensureIdentifierPotentiallyRecovered(m, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(i)
         ensureSemicolon(a)
           reportRecoverableError(a, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -2186,7 +2186,7 @@
                       listener: handleIdentifier(r, localVariableDeclaration)
                     listener: beginInitializedIdentifier(r)
                     parseVariableInitializerOpt(r)
-                      listener: handleNoVariableInitializer(i)
+                      listener: handleNoVariableInitializer(r)
                     listener: endInitializedIdentifier(r)
                   ensureSemicolon(r)
                     reportRecoverableError(r, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
@@ -2210,7 +2210,7 @@
                       listener: handleIdentifier(n, localVariableDeclaration)
                     listener: beginInitializedIdentifier(n)
                     parseVariableInitializerOpt(n)
-                      listener: handleNoVariableInitializer(t)
+                      listener: handleNoVariableInitializer(n)
                     listener: endInitializedIdentifier(n)
                   ensureSemicolon(n)
                     reportRecoverableError(n, Message[ExpectedAfterButGot, Expected ';' after this., null, {string: ;}])
diff --git a/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect
index 6f54ea6..a6bfc1c 100644
--- a/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/extensions/covariant.dart.intertwined.expect
@@ -82,7 +82,7 @@
               listener: endMetadataStar(0)
             listener: beginMember()
             isReservedKeyword(()
-            parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
+            parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
               listener: beginMethod(null, null, null, null, null, addChild)
               listener: handleNoType({)
               ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect
index 309c3b2..9bfe405 100644
--- a/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/extensions/not_covariant.dart.intertwined.expect
@@ -82,7 +82,7 @@
               listener: endMetadataStar(0)
             listener: beginMember()
             isReservedKeyword(()
-            parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
+            parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
               listener: beginMethod(null, null, null, null, null, addChild)
               listener: handleNoType({)
               ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect
index 8c2fff7..cd427ab 100644
--- a/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/extensions/static.dart.intertwined.expect
@@ -82,7 +82,7 @@
               listener: endMetadataStar(0)
             listener: beginMember()
             isReservedKeyword(()
-            parseMethod({, null, static, null, null, null, static, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
+            parseMethod({, null, null, static, null, null, null, static, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
               listener: beginMethod(null, static, null, null, null, addChild)
               listener: handleNoType(static)
               ensureIdentifierPotentiallyRecovered(static, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect
index e53f220..ff30f70 100644
--- a/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/extensions/static_covariant.dart.intertwined.expect
@@ -82,7 +82,7 @@
               listener: endMetadataStar(0)
             listener: beginMember()
             isReservedKeyword(()
-            parseMethod({, null, static, null, null, null, static, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
+            parseMethod({, null, null, static, null, null, null, static, Instance of 'NoType', null, addChild, DeclarationKind.Extension, null, false)
               listener: beginMethod(null, static, null, null, null, addChild)
               listener: handleNoType(static)
               ensureIdentifierPotentiallyRecovered(static, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/general/ambiguous_builder_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/ambiguous_builder_01.dart.intertwined.expect
index e4575db..5a9bafc 100644
--- a/pkg/front_end/parser_testcases/general/ambiguous_builder_01.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/ambiguous_builder_01.dart.intertwined.expect
@@ -54,13 +54,13 @@
     parseTopLevelMemberImpl(.)
       listener: beginTopLevelMember(y)
       isReservedKeyword(=)
-      parseFields(., null, null, null, null, null, ., Instance of 'NoType', y, DeclarationKind.TopLevel, null, false)
+      parseFields(., null, null, null, null, null, null, ., Instance of 'NoType', y, DeclarationKind.TopLevel, null, false)
         reportRecoverableError(y, MissingConstFinalVarOrType)
           listener: handleRecoverableError(MissingConstFinalVarOrType, y, y)
         listener: handleNoType(.)
         ensureIdentifierPotentiallyRecovered(., topLevelVariableDeclaration, false)
           listener: handleIdentifier(y, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(y, y, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -123,13 +123,13 @@
     parseTopLevelMemberImpl(.)
       listener: beginTopLevelMember(z)
       isReservedKeyword(=)
-      parseFields(., null, null, null, null, null, ., Instance of 'NoType', z, DeclarationKind.TopLevel, null, false)
+      parseFields(., null, null, null, null, null, null, ., Instance of 'NoType', z, DeclarationKind.TopLevel, null, false)
         reportRecoverableError(z, MissingConstFinalVarOrType)
           listener: handleRecoverableError(MissingConstFinalVarOrType, z, z)
         listener: handleNoType(.)
         ensureIdentifierPotentiallyRecovered(., topLevelVariableDeclaration, false)
           listener: handleIdentifier(z, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(z, z, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(z, z, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect
index 82ec9c3..4f0fae4 100644
--- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_fields.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', abstract, DeclarationKind.Class, WrapperClass, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', abstract, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(abstract)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(abstract, fieldDeclaration)
-                parseFieldInitializerOpt(abstract, abstract, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(abstract, abstract, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -55,13 +55,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(as)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(as, fieldDeclaration)
-                parseFieldInitializerOpt(as, as, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(as, as, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -78,13 +78,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(covariant)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(covariant, fieldDeclaration)
-                parseFieldInitializerOpt(covariant, covariant, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(covariant, covariant, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -101,13 +101,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(deferred)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(deferred, fieldDeclaration)
-                parseFieldInitializerOpt(deferred, deferred, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(deferred, deferred, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -124,13 +124,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(dynamic)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(dynamic, fieldDeclaration)
-                parseFieldInitializerOpt(dynamic, dynamic, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(dynamic, dynamic, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -147,13 +147,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(export)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(export, fieldDeclaration)
-                parseFieldInitializerOpt(export, export, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(export, export, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -170,13 +170,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(external)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(external, fieldDeclaration)
-                parseFieldInitializerOpt(external, external, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(external, external, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -193,13 +193,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(factory)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(factory, fieldDeclaration)
-                parseFieldInitializerOpt(factory, factory, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(factory, factory, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -216,13 +216,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(Function)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(Function, fieldDeclaration)
-                parseFieldInitializerOpt(Function, Function, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(Function, Function, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -240,13 +240,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(get, fieldDeclaration)
-                parseFieldInitializerOpt(get, get, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(get, get, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -263,13 +263,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(implements)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(implements, fieldDeclaration)
-                parseFieldInitializerOpt(implements, implements, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(implements, implements, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -286,13 +286,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(import)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(import, fieldDeclaration)
-                parseFieldInitializerOpt(import, import, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(import, import, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -309,13 +309,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(interface)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(interface, fieldDeclaration)
-                parseFieldInitializerOpt(interface, interface, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(interface, interface, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -332,13 +332,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(library)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(library, fieldDeclaration)
-                parseFieldInitializerOpt(library, library, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(library, library, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -356,13 +356,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isUnaryMinus(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(operator)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(operator, fieldDeclaration)
-                parseFieldInitializerOpt(operator, operator, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(operator, operator, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -379,13 +379,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(mixin)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(mixin, fieldDeclaration)
-                parseFieldInitializerOpt(mixin, mixin, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(mixin, mixin, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -402,13 +402,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(part)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(part, fieldDeclaration)
-                parseFieldInitializerOpt(part, part, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(part, part, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -426,13 +426,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(set)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(set, fieldDeclaration)
-                parseFieldInitializerOpt(set, set, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(set, set, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -449,13 +449,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(static)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(static, fieldDeclaration)
-                parseFieldInitializerOpt(static, static, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(static, static, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -472,13 +472,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.Class, WrapperClass, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.Class, WrapperClass, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(typedef)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(typedef, fieldDeclaration)
-                parseFieldInitializerOpt(typedef, typedef, null, null, DeclarationKind.Class, WrapperClass)
+                parseFieldInitializerOpt(typedef, typedef, null, null, null, null, DeclarationKind.Class, WrapperClass)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect
index 70d5893..b7770f9 100644
--- a/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/built_in_identifier_class_methods.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, abstract, DeclarationKind.Class, WrapperClass, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, abstract, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, abstract)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(abstract)
@@ -166,7 +166,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, as, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, as, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, as)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(as)
@@ -300,7 +300,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, covariant, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, covariant, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, covariant)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(covariant)
@@ -434,7 +434,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, deferred, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, deferred, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, deferred)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(deferred)
@@ -568,7 +568,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, dynamic, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, dynamic, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, dynamic)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(dynamic)
@@ -702,7 +702,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, export, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, export, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, export)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(export)
@@ -836,7 +836,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, external, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, external, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, external)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(external)
@@ -970,7 +970,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, factory, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, factory, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, factory)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(factory)
@@ -1104,7 +1104,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, Function, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, Function, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, Function)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(Function)
@@ -1239,7 +1239,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, get, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, get, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, get)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -1373,7 +1373,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, implements, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, implements, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, implements)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(implements)
@@ -1507,7 +1507,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, import, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, import, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, import)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(import)
@@ -1641,7 +1641,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, interface, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, interface, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, interface)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(interface)
@@ -1775,7 +1775,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, library, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, library, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, library)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(library)
@@ -1910,7 +1910,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isUnaryMinus(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, operator, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, operator, DeclarationKind.Class, WrapperClass, false)
                 isUnaryMinus(()
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleIdentifier(int, typeReference)
@@ -2045,7 +2045,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, mixin, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, mixin, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, mixin)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(mixin)
@@ -2179,7 +2179,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, part, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, part, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, part)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(part)
@@ -2314,7 +2314,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, set, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, set, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, set)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(set)
@@ -2448,7 +2448,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, static, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, static, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, static)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(static)
@@ -2582,7 +2582,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', null, typedef, DeclarationKind.Class, WrapperClass, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', null, typedef, DeclarationKind.Class, WrapperClass, false)
                 listener: beginMethod(null, null, null, null, null, typedef)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(typedef)
diff --git a/pkg/front_end/parser_testcases/general/built_in_identifier_top_level_fields.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/built_in_identifier_top_level_fields.dart.intertwined.expect
index 33c529a..4ab6b44 100644
--- a/pkg/front_end/parser_testcases/general/built_in_identifier_top_level_fields.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/built_in_identifier_top_level_fields.dart.intertwined.expect
@@ -8,13 +8,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl()
       listener: beginTopLevelMember(int)
-      parseFields(, null, null, null, null, null, , Instance of 'SimpleType', abstract, DeclarationKind.TopLevel, null, false)
+      parseFields(, null, null, null, null, null, null, , Instance of 'SimpleType', abstract, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(abstract)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(abstract, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(abstract, abstract, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(abstract, abstract, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -31,13 +31,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', as, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(as)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(as, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(as, as, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(as, as, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -54,13 +54,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', covariant, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(covariant)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(covariant, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(covariant, covariant, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(covariant, covariant, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -77,13 +77,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', deferred, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(deferred)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(deferred, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(deferred, deferred, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(deferred, deferred, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -100,13 +100,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', dynamic, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(dynamic)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(dynamic, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(dynamic, dynamic, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(dynamic, dynamic, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -123,13 +123,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', export, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(export)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(export, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(export, export, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(export, export, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -146,13 +146,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', external, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(external)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(external, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(external, external, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(external, external, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -169,13 +169,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', factory, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(factory)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(factory, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(factory, factory, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(factory, factory, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -192,13 +192,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', Function, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(Function)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(Function, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(Function, Function, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(Function, Function, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -215,13 +215,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', get, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(get)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(get, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(get, get, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(get, get, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -238,13 +238,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', implements, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(implements)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(implements, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(implements, implements, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(implements, implements, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -261,13 +261,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', import, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(import)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(import, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(import, import, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(import, import, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -284,13 +284,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', interface, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(interface)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(interface, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(interface, interface, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(interface, interface, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -307,13 +307,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', library, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(library)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(library, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(library, library, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(library, library, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -330,13 +330,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', operator, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(operator)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(operator, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(operator, operator, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(operator, operator, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -353,13 +353,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', mixin, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(mixin)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(mixin, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(mixin, mixin, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(mixin, mixin, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -376,13 +376,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', part, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(part)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(part, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(part, part, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(part, part, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -399,13 +399,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', set, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(set)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(set, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(set, set, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(set, set, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -422,13 +422,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', static, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(static)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(static, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(static, static, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(static, static, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
@@ -445,13 +445,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(int)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', typedef, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(int, typeReference)
         listener: handleNoTypeArguments(typedef)
         listener: handleType(int, null)
         ensureIdentifierPotentiallyRecovered(int, topLevelVariableDeclaration, false)
           listener: handleIdentifier(typedef, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(typedef, typedef, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(typedef, typedef, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: beginFieldInitializer(=)
           parseExpression(=)
             parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/general/for_in.dart.expect b/pkg/front_end/parser_testcases/general/for_in.dart.expect
index b075cf9..c00444c 100644
--- a/pkg/front_end/parser_testcases/general/for_in.dart.expect
+++ b/pkg/front_end/parser_testcases/general/for_in.dart.expect
@@ -17,7 +17,7 @@
           beginVariablesDeclaration(i, null, var)
             handleIdentifier(i, localVariableDeclaration)
             beginInitializedIdentifier(i)
-              handleNoVariableInitializer(in)
+              handleNoVariableInitializer(i)
             endInitializedIdentifier(i)
           endVariablesDeclaration(1, null)
           handleForInitializerLocalVariableDeclaration(i, true)
diff --git a/pkg/front_end/parser_testcases/general/for_in.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/for_in.dart.intertwined.expect
index d06605e..6be8639 100644
--- a/pkg/front_end/parser_testcases/general/for_in.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/for_in.dart.intertwined.expect
@@ -45,7 +45,7 @@
                         listener: handleIdentifier(i, localVariableDeclaration)
                       listener: beginInitializedIdentifier(i)
                       parseVariableInitializerOpt(i)
-                        listener: handleNoVariableInitializer(in)
+                        listener: handleNoVariableInitializer(i)
                       listener: endInitializedIdentifier(i)
                     listener: endVariablesDeclaration(1, null)
                   listener: handleForInitializerLocalVariableDeclaration(i, true)
diff --git a/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.expect b/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.expect
index e8e3110..54e4fc4 100644
--- a/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.expect
+++ b/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.expect
@@ -16,7 +16,7 @@
         beginVariablesDeclaration(i, null, var)
           handleIdentifier(i, localVariableDeclaration)
           beginInitializedIdentifier(i)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(i)
           endInitializedIdentifier(i)
         endVariablesDeclaration(1, ;)
         beginForStatement(for)
diff --git a/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.intertwined.expect
index 14660b8..a7f2679 100644
--- a/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/for_in_no_decl.dart.intertwined.expect
@@ -41,7 +41,7 @@
                       listener: handleIdentifier(i, localVariableDeclaration)
                     listener: beginInitializedIdentifier(i)
                     parseVariableInitializerOpt(i)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(i)
                     listener: endInitializedIdentifier(i)
                   ensureSemicolon(i)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/general/for_no_decl.dart.expect b/pkg/front_end/parser_testcases/general/for_no_decl.dart.expect
index d5af7db..bbe4ce5 100644
--- a/pkg/front_end/parser_testcases/general/for_no_decl.dart.expect
+++ b/pkg/front_end/parser_testcases/general/for_no_decl.dart.expect
@@ -18,7 +18,7 @@
         beginVariablesDeclaration(i, null, null)
           handleIdentifier(i, localVariableDeclaration)
           beginInitializedIdentifier(i)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(i)
           endInitializedIdentifier(i)
         endVariablesDeclaration(1, ;)
         beginForStatement(for)
diff --git a/pkg/front_end/parser_testcases/general/for_no_decl.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/for_no_decl.dart.intertwined.expect
index 710c4157..dce6b08 100644
--- a/pkg/front_end/parser_testcases/general/for_no_decl.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/for_no_decl.dart.intertwined.expect
@@ -43,7 +43,7 @@
                       listener: handleIdentifier(i, localVariableDeclaration)
                     listener: beginInitializedIdentifier(i)
                     parseVariableInitializerOpt(i)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(i)
                     listener: endInitializedIdentifier(i)
                   ensureSemicolon(i)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect b/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect
index af39092..f010597 100644
--- a/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/issue_41121.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(Configuration)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', _configuration, DeclarationKind.Class, ConfigurationService, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', _configuration, DeclarationKind.Class, ConfigurationService, false)
                 listener: handleIdentifier(Configuration, typeReference)
                 listener: handleNoTypeArguments(_configuration)
                 listener: handleType(Configuration, null)
                 ensureIdentifierPotentiallyRecovered(Configuration, fieldDeclaration, false)
                   listener: handleIdentifier(_configuration, fieldDeclaration)
-                parseFieldInitializerOpt(_configuration, _configuration, null, null, DeclarationKind.Class, ConfigurationService)
+                parseFieldInitializerOpt(_configuration, _configuration, null, null, null, null, DeclarationKind.Class, ConfigurationService)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, Configuration, ;)
               listener: endMember()
@@ -49,7 +49,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, ConfigurationService, DeclarationKind.Class, ConfigurationService, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, ConfigurationService, DeclarationKind.Class, ConfigurationService, false)
                 listener: beginMethod(null, null, null, null, null, ConfigurationService)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -147,7 +147,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', set, configuration, DeclarationKind.Class, ConfigurationService, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', set, configuration, DeclarationKind.Class, ConfigurationService, false)
                 listener: beginMethod(null, null, null, null, set, configuration)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(set, methodDeclaration, false)
@@ -251,7 +251,7 @@
                 listener: beginMetadataStar(Configuration)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'SimpleType', get, configuration, DeclarationKind.Class, ConfigurationService, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'SimpleType', get, configuration, DeclarationKind.Class, ConfigurationService, false)
                 listener: beginMethod(null, null, null, null, get, configuration)
                 listener: handleIdentifier(Configuration, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -378,7 +378,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, method, DeclarationKind.Class, ConfigurationService, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, method, DeclarationKind.Class, ConfigurationService, false)
                 listener: beginMethod(null, null, null, null, null, method)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -438,7 +438,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, ConfigurationService, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'NoType', null, Foo, DeclarationKind.Class, ConfigurationService, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(})
                 ensureIdentifierPotentiallyRecovered(}, methodDeclaration, false)
@@ -523,7 +523,7 @@
                 listener: beginMetadataStar(Configuration)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', get, foo, DeclarationKind.Class, Configuration, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', get, foo, DeclarationKind.Class, Configuration, false)
                 listener: beginMethod(null, null, null, null, get, foo)
                 listener: handleIdentifier(Configuration, typeReference)
                 listener: handleNoTypeArguments(get)
diff --git a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect
index 0f64958..beab6b7 100644
--- a/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/general/operator_hat_class.crash_dart.intertwined.expect
@@ -34,7 +34,7 @@
                 listener: beginMetadataStar(operator)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, operator, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, operator, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleNoType({)
                 parseOperatorName({)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.expect
index 235826c..fa7ddf9 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.expect
@@ -16,7 +16,7 @@
         beginVariablesDeclaration(c, null, var)
           handleIdentifier(c, localVariableDeclaration)
           beginInitializedIdentifier(c)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c)
           endInitializedIdentifier(c)
         endVariablesDeclaration(1, ;)
         handleIdentifier(c, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.intertwined.expect
index 7b47813..1368e76 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39326.dart.intertwined.expect
@@ -41,7 +41,7 @@
                       listener: handleIdentifier(c, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c)
                     parseVariableInitializerOpt(c)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c)
                     listener: endInitializedIdentifier(c)
                   ensureSemicolon(c)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect
index 8ae8297..183b237 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39723.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(operator)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, A, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, A, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleNoType({)
                 parseOperatorName({)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect
index 2c43271..3af8393 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39723_prime.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(operator)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, A, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, operator, DeclarationKind.Class, A, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleNoType({)
                 parseOperatorName({)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect
index f4f808b..8162b63 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39858.dart.intertwined.expect
@@ -33,13 +33,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(;)
-              parseFields({, null, null, null, late, null, late, Instance of 'NoType', x1, DeclarationKind.Class, X, false)
+              parseFields({, null, null, null, null, late, null, late, Instance of 'NoType', x1, DeclarationKind.Class, X, false)
                 reportRecoverableError(x1, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x1, x1)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x1, fieldDeclaration)
-                parseFieldInitializerOpt(x1, x1, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x1, x1, late, null, null, null, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, late, null, 1, late, ;)
               listener: endMember()
@@ -50,13 +50,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(;)
-              parseFields(;, null, static, null, late, null, late, Instance of 'NoType', x2, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, static, null, late, null, late, Instance of 'NoType', x2, DeclarationKind.Class, X, false)
                 reportRecoverableError(x2, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x2, x2)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x2, fieldDeclaration)
-                parseFieldInitializerOpt(x2, x2, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x2, x2, late, null, null, null, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(static, null, late, null, 1, static, ;)
               listener: endMember()
@@ -67,13 +67,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(;)
-              parseFields(;, null, null, covariant, late, null, late, Instance of 'NoType', x3, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, covariant, late, null, late, Instance of 'NoType', x3, DeclarationKind.Class, X, false)
                 reportRecoverableError(x3, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x3, x3)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x3, fieldDeclaration)
-                parseFieldInitializerOpt(x3, x3, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x3, x3, late, null, null, null, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, covariant, late, null, 1, covariant, ;)
               listener: endMember()
@@ -84,13 +84,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, null, late, null, late, Instance of 'NoType', x4, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, null, late, null, late, Instance of 'NoType', x4, DeclarationKind.Class, X, false)
                 reportRecoverableError(x4, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x4, x4)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x4, fieldDeclaration)
-                parseFieldInitializerOpt(x4, x4, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x4, x4, late, null, null, null, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -108,13 +108,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, static, null, late, null, late, Instance of 'NoType', x5, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, static, null, late, null, late, Instance of 'NoType', x5, DeclarationKind.Class, X, false)
                 reportRecoverableError(x5, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x5, x5)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x5, fieldDeclaration)
-                parseFieldInitializerOpt(x5, x5, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x5, x5, late, null, null, null, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -132,13 +132,13 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(=)
-              parseFields(;, null, null, covariant, late, null, late, Instance of 'NoType', x6, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, covariant, late, null, late, Instance of 'NoType', x6, DeclarationKind.Class, X, false)
                 reportRecoverableError(x6, MissingConstFinalVarOrType)
                   listener: handleRecoverableError(MissingConstFinalVarOrType, x6, x6)
                 listener: handleNoType(late)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(x6, fieldDeclaration)
-                parseFieldInitializerOpt(x6, x6, late, null, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x6, x6, late, null, null, null, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect
index d224ea7..c807ed8 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_39858_prime1.dart.intertwined.expect
@@ -32,11 +32,11 @@
                 listener: beginMetadataStar(var)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, var, var, Instance of 'NoType', x1, DeclarationKind.Class, X, false)
+              parseFields({, null, null, null, null, null, var, var, Instance of 'NoType', x1, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x1, fieldDeclaration)
-                parseFieldInitializerOpt(x1, x1, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x1, x1, null, null, null, var, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, var, 1, var, ;)
               listener: endMember()
@@ -46,11 +46,11 @@
                 listener: beginMetadataStar(static)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, static, null, null, var, var, Instance of 'NoType', x2, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, static, null, null, var, var, Instance of 'NoType', x2, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x2, fieldDeclaration)
-                parseFieldInitializerOpt(x2, x2, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x2, x2, null, null, null, var, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(static, null, null, var, 1, static, ;)
               listener: endMember()
@@ -60,11 +60,11 @@
                 listener: beginMetadataStar(covariant)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, covariant, null, var, var, Instance of 'NoType', x3, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, covariant, null, var, var, Instance of 'NoType', x3, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x3, fieldDeclaration)
-                parseFieldInitializerOpt(x3, x3, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x3, x3, null, null, null, var, DeclarationKind.Class, X)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, covariant, null, var, 1, covariant, ;)
               listener: endMember()
@@ -74,11 +74,11 @@
                 listener: beginMetadataStar(var)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, var, var, Instance of 'NoType', x4, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, null, null, var, var, Instance of 'NoType', x4, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x4, fieldDeclaration)
-                parseFieldInitializerOpt(x4, x4, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x4, x4, null, null, null, var, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -95,11 +95,11 @@
                 listener: beginMetadataStar(static)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, static, null, null, var, var, Instance of 'NoType', x5, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, static, null, null, var, var, Instance of 'NoType', x5, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x5, fieldDeclaration)
-                parseFieldInitializerOpt(x5, x5, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x5, x5, null, null, null, var, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -116,11 +116,11 @@
                 listener: beginMetadataStar(covariant)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, covariant, null, var, var, Instance of 'NoType', x6, DeclarationKind.Class, X, false)
+              parseFields(;, null, null, null, covariant, null, var, var, Instance of 'NoType', x6, DeclarationKind.Class, X, false)
                 listener: handleNoType(var)
                 ensureIdentifierPotentiallyRecovered(var, fieldDeclaration, false)
                   listener: handleIdentifier(x6, fieldDeclaration)
-                parseFieldInitializerOpt(x6, x6, null, var, DeclarationKind.Class, X)
+                parseFieldInitializerOpt(x6, x6, null, null, null, var, DeclarationKind.Class, X)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.expect
index b143be7..51ede43 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.expect
@@ -16,15 +16,15 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
           handleIdentifier(c, localVariableDeclaration)
           beginInitializedIdentifier(c)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c)
           endInitializedIdentifier(c)
         endVariablesDeclaration(3, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.intertwined.expect
index 6761e0c..caa1810 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional.dart.intertwined.expect
@@ -41,21 +41,21 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(c, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c)
                     parseVariableInitializerOpt(c)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c)
                     listener: endInitializedIdentifier(c)
                   ensureSemicolon(c)
                   listener: endVariablesDeclaration(3, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.expect
index 6acafe8..947256d 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.expect
@@ -16,11 +16,11 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
         endVariablesDeclaration(2, ;)
         beginReturnStatement(return)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.intertwined.expect
index a4a13e9..2b95e24 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_conditional_2.dart.intertwined.expect
@@ -41,14 +41,14 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   ensureSemicolon(b)
                   listener: endVariablesDeclaration(2, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.expect
index b2e3729..3c6833e 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.expect
@@ -16,11 +16,11 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
         endVariablesDeclaration(2, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.intertwined.expect
index 7582fd9..da5c160 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_access.dart.intertwined.expect
@@ -41,14 +41,14 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   ensureSemicolon(b)
                   listener: endVariablesDeclaration(2, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.expect
index a4ed432..32e3968 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.expect
@@ -16,15 +16,15 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
           handleIdentifier(c, localVariableDeclaration)
           beginInitializedIdentifier(c)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c)
           endInitializedIdentifier(c)
         endVariablesDeclaration(3, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.intertwined.expect
index 0c65fee..05def0c 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_index_set.dart.intertwined.expect
@@ -41,21 +41,21 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(c, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c)
                     parseVariableInitializerOpt(c)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c)
                     listener: endInitializedIdentifier(c)
                   ensureSemicolon(c)
                   listener: endVariablesDeclaration(3, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
index 1b1476d..df0efbe 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.expect
@@ -26,11 +26,11 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
         endVariablesDeclaration(2, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
index 0fe0966..65987de 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_no_type_arguments.dart.intertwined.expect
@@ -41,14 +41,14 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   ensureSemicolon(b)
                   listener: endVariablesDeclaration(2, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
index 5832363..8839c76 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.expect
@@ -38,11 +38,11 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
         endVariablesDeclaration(2, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
index d4d40f7..76f08fd 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40267_method_call_with_type_arguments.dart.intertwined.expect
@@ -41,14 +41,14 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   ensureSemicolon(b)
                   listener: endVariablesDeclaration(2, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect
index d815fea..abe076a 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_01.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(covariant)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, covariant, late, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
+              parseFields({, null, null, null, covariant, late, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(x)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(x, fieldDeclaration)
-                parseFieldInitializerOpt(x, x, late, final, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(x, x, late, null, null, final, DeclarationKind.Class, C)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, covariant, late, final, 1, covariant, ;)
               listener: endMember()
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect
index ca8c3f6..73d8eb0 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_02.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(covariant)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, covariant, late, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
+              parseFields({, null, null, null, covariant, late, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(x)
                 listener: handleType(int, null)
@@ -40,7 +40,7 @@
                   listener: handleIdentifier(x, fieldDeclaration)
                 reportRecoverableError(covariant, FinalAndCovariantLateWithInitializer)
                   listener: handleRecoverableError(FinalAndCovariantLateWithInitializer, covariant, covariant)
-                parseFieldInitializerOpt(x, x, late, final, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(x, x, late, null, null, final, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect
index 9854745..a73b460 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40805_03.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(covariant)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, covariant, null, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
+              parseFields({, null, null, null, covariant, null, final, final, Instance of 'SimpleType', x, DeclarationKind.Class, C, false)
                 reportRecoverableError(covariant, FinalAndCovariant)
                   listener: handleRecoverableError(FinalAndCovariant, covariant, covariant)
                 listener: handleIdentifier(int, typeReference)
@@ -40,7 +40,7 @@
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(x, fieldDeclaration)
-                parseFieldInitializerOpt(x, x, null, final, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(x, x, null, null, null, final, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect
index 3f329b4..490e20d 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_01.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(String)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(String, typeReference)
                 listener: handleNoTypeArguments(?)
                 listener: handleType(String, ?)
                 ensureIdentifierPotentiallyRecovered(?, fieldDeclaration, false)
                   listener: handleIdentifier(x, fieldDeclaration)
-                parseFieldInitializerOpt(x, x, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, String, ;)
               listener: endMember()
@@ -48,13 +48,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(y)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(y, fieldDeclaration)
-                parseFieldInitializerOpt(y, y, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, int, ;)
               listener: endMember()
@@ -65,7 +65,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -168,7 +168,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -308,7 +308,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -448,7 +448,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -588,7 +588,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect
index b87bd16..3354446 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_02.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(String)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(String, typeReference)
                 listener: handleNoTypeArguments(?)
                 listener: handleType(String, ?)
                 ensureIdentifierPotentiallyRecovered(?, fieldDeclaration, false)
                   listener: handleIdentifier(x, fieldDeclaration)
-                parseFieldInitializerOpt(x, x, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, String, ;)
               listener: endMember()
@@ -48,13 +48,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(y)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(y, fieldDeclaration)
-                parseFieldInitializerOpt(y, y, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, int, ;)
               listener: endMember()
@@ -65,7 +65,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect
index a2ada84..830eaf7 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_40834_03.dart.intertwined.expect
@@ -32,13 +32,13 @@
                 listener: beginMetadataStar(String)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(String, typeReference)
                 listener: handleNoTypeArguments(?)
                 listener: handleType(String, ?)
                 ensureIdentifierPotentiallyRecovered(?, fieldDeclaration, false)
                   listener: handleIdentifier(x, fieldDeclaration)
-                parseFieldInitializerOpt(x, x, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, String, ;)
               listener: endMember()
@@ -48,13 +48,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', y, DeclarationKind.Class, Foo, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(y)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(y, fieldDeclaration)
-                parseFieldInitializerOpt(y, y, null, null, DeclarationKind.Class, Foo)
+                parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.Class, Foo)
                   listener: handleNoFieldInitializer(;)
                 listener: endClassFields(null, null, null, null, 1, int, ;)
               listener: endMember()
@@ -65,7 +65,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, Foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, Foo)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
@@ -197,7 +197,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'VoidType', null, foo, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, foo)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
@@ -336,7 +336,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(}, null, null, null, null, null, }, Instance of 'VoidType', null, bar, DeclarationKind.Class, Foo, false)
+              parseMethod(}, null, null, null, null, null, null, }, Instance of 'VoidType', null, bar, DeclarationKind.Class, Foo, false)
                 listener: beginMethod(null, null, null, null, null, bar)
                 listener: handleVoidKeyword(void)
                 ensureIdentifierPotentiallyRecovered(void, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect
index 0aa114d..4d70eea 100644
--- a/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/issue_41597.dart.intertwined.expect
@@ -8,13 +8,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl()
       listener: beginTopLevelMember(bool)
-      parseFields(, null, null, null, null, null, , Instance of 'SimpleType', x, DeclarationKind.TopLevel, null, false)
+      parseFields(, null, null, null, null, null, null, , Instance of 'SimpleType', x, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(bool, typeReference)
         listener: handleNoTypeArguments(x)
         listener: handleType(bool, null)
         ensureIdentifierPotentiallyRecovered(bool, topLevelVariableDeclaration, false)
           listener: handleIdentifier(x, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(x, x, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(;)
         listener: endTopLevelFields(null, null, null, null, 1, bool, ;)
   listener: endTopLevelDeclaration(bool)
@@ -24,13 +24,13 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl(;)
       listener: beginTopLevelMember(bool)
-      parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', x, DeclarationKind.TopLevel, null, false)
+      parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', x, DeclarationKind.TopLevel, null, false)
         listener: handleIdentifier(bool, typeReference)
         listener: handleNoTypeArguments(x)
         listener: handleType(bool, null)
         ensureIdentifierPotentiallyRecovered(bool, topLevelVariableDeclaration, false)
           listener: handleIdentifier(x, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(x, x, null, null, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(;)
         listener: endTopLevelFields(null, null, null, null, 1, bool, ;)
   listener: endTopLevelDeclaration(errors)
@@ -205,7 +205,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, C)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -258,7 +258,7 @@
                 listener: endMetadataStar(0)
               listener: beginMember()
               isReservedKeyword(.)
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'NoType', null, C, DeclarationKind.Class, C, false)
                 listener: beginMethod(null, null, null, null, null, C)
                 listener: handleNoType(;)
                 ensureIdentifierPotentiallyRecovered(;, methodDeclaration, false)
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart
new file mode 100644
index 0000000..c5704c1
--- /dev/null
+++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart
@@ -0,0 +1,27 @@
+Order method1(Map<String, dynamic> json) {
+  return Order()
+    ..x = json['x'] as List
+    ..y = json['y'] as int;
+}
+
+Order method2(Map<String, dynamic> json) {
+  return Order()
+    ..x = json['x'] as List?
+    ..y = json['y'] as int;
+}
+
+Order method3(Map<String, dynamic> json) {
+  return Order()
+    ..x = (json['x'] as List?)
+    ..y = json['y'] as int;
+}
+
+Order method4(Map<String, dynamic> json) {
+  return Order()
+    ..x = json['x'] as List?;
+}
+
+class Order {
+  List? x;
+  int? y;
+}
\ No newline at end of file
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect
new file mode 100644
index 0000000..616be0b
--- /dev/null
+++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.expect
@@ -0,0 +1,341 @@
+beginCompilationUnit(Order)
+  beginMetadataStar(Order)
+  endMetadataStar(0)
+  beginTopLevelMember(Order)
+    beginTopLevelMethod(, null)
+      handleIdentifier(Order, typeReference)
+      handleNoTypeArguments(method1)
+      handleType(Order, null)
+      handleIdentifier(method1, topLevelFunctionDeclaration)
+      handleNoTypeVariables(()
+      beginFormalParameters((, MemberKind.TopLevelMethod)
+        beginMetadataStar(Map)
+        endMetadataStar(0)
+        beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+          handleIdentifier(Map, typeReference)
+          beginTypeArguments(<)
+            handleIdentifier(String, typeReference)
+            handleNoTypeArguments(,)
+            handleType(String, null)
+            handleIdentifier(dynamic, typeReference)
+            handleNoTypeArguments(>)
+            handleType(dynamic, null)
+          endTypeArguments(2, <, >)
+          handleType(Map, null)
+          handleIdentifier(json, formalParameterDeclaration)
+          handleFormalParameterWithoutValue())
+        endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+      endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+      handleAsyncModifier(null, null)
+      beginBlockFunctionBody({)
+        beginReturnStatement(return)
+          handleIdentifier(Order, expression)
+          handleNoTypeArguments(()
+          beginArguments(()
+          endArguments(0, (, ))
+          handleSend(Order, ..)
+          beginCascade(..)
+            handleIdentifier(x, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(x, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('x')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(List, typeReference)
+              handleNoTypeArguments(..)
+              handleType(List, null)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+          beginCascade(..)
+            handleIdentifier(y, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(y, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('y')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(int, typeReference)
+              handleNoTypeArguments(;)
+              handleType(int, null)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+        endReturnStatement(true, return, ;)
+      endBlockFunctionBody(1, {, })
+    endTopLevelMethod(Order, null, })
+  endTopLevelDeclaration(Order)
+  beginMetadataStar(Order)
+  endMetadataStar(0)
+  beginTopLevelMember(Order)
+    beginTopLevelMethod(}, null)
+      handleIdentifier(Order, typeReference)
+      handleNoTypeArguments(method2)
+      handleType(Order, null)
+      handleIdentifier(method2, topLevelFunctionDeclaration)
+      handleNoTypeVariables(()
+      beginFormalParameters((, MemberKind.TopLevelMethod)
+        beginMetadataStar(Map)
+        endMetadataStar(0)
+        beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+          handleIdentifier(Map, typeReference)
+          beginTypeArguments(<)
+            handleIdentifier(String, typeReference)
+            handleNoTypeArguments(,)
+            handleType(String, null)
+            handleIdentifier(dynamic, typeReference)
+            handleNoTypeArguments(>)
+            handleType(dynamic, null)
+          endTypeArguments(2, <, >)
+          handleType(Map, null)
+          handleIdentifier(json, formalParameterDeclaration)
+          handleFormalParameterWithoutValue())
+        endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+      endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+      handleAsyncModifier(null, null)
+      beginBlockFunctionBody({)
+        beginReturnStatement(return)
+          handleIdentifier(Order, expression)
+          handleNoTypeArguments(()
+          beginArguments(()
+          endArguments(0, (, ))
+          handleSend(Order, ..)
+          beginCascade(..)
+            handleIdentifier(x, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(x, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('x')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(List, typeReference)
+              handleNoTypeArguments(?)
+              handleType(List, ?)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+          beginCascade(..)
+            handleIdentifier(y, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(y, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('y')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(int, typeReference)
+              handleNoTypeArguments(;)
+              handleType(int, null)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+        endReturnStatement(true, return, ;)
+      endBlockFunctionBody(1, {, })
+    endTopLevelMethod(Order, null, })
+  endTopLevelDeclaration(Order)
+  beginMetadataStar(Order)
+  endMetadataStar(0)
+  beginTopLevelMember(Order)
+    beginTopLevelMethod(}, null)
+      handleIdentifier(Order, typeReference)
+      handleNoTypeArguments(method3)
+      handleType(Order, null)
+      handleIdentifier(method3, topLevelFunctionDeclaration)
+      handleNoTypeVariables(()
+      beginFormalParameters((, MemberKind.TopLevelMethod)
+        beginMetadataStar(Map)
+        endMetadataStar(0)
+        beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+          handleIdentifier(Map, typeReference)
+          beginTypeArguments(<)
+            handleIdentifier(String, typeReference)
+            handleNoTypeArguments(,)
+            handleType(String, null)
+            handleIdentifier(dynamic, typeReference)
+            handleNoTypeArguments(>)
+            handleType(dynamic, null)
+          endTypeArguments(2, <, >)
+          handleType(Map, null)
+          handleIdentifier(json, formalParameterDeclaration)
+          handleFormalParameterWithoutValue())
+        endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+      endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+      handleAsyncModifier(null, null)
+      beginBlockFunctionBody({)
+        beginReturnStatement(return)
+          handleIdentifier(Order, expression)
+          handleNoTypeArguments(()
+          beginArguments(()
+          endArguments(0, (, ))
+          handleSend(Order, ..)
+          beginCascade(..)
+            handleIdentifier(x, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(x, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('x')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(List, typeReference)
+              handleNoTypeArguments(?)
+              handleType(List, ?)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleParenthesizedExpression(()
+            handleAssignmentExpression(=)
+          endCascade()
+          beginCascade(..)
+            handleIdentifier(y, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(y, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('y')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(int, typeReference)
+              handleNoTypeArguments(;)
+              handleType(int, null)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+        endReturnStatement(true, return, ;)
+      endBlockFunctionBody(1, {, })
+    endTopLevelMethod(Order, null, })
+  endTopLevelDeclaration(Order)
+  beginMetadataStar(Order)
+  endMetadataStar(0)
+  beginTopLevelMember(Order)
+    beginTopLevelMethod(}, null)
+      handleIdentifier(Order, typeReference)
+      handleNoTypeArguments(method4)
+      handleType(Order, null)
+      handleIdentifier(method4, topLevelFunctionDeclaration)
+      handleNoTypeVariables(()
+      beginFormalParameters((, MemberKind.TopLevelMethod)
+        beginMetadataStar(Map)
+        endMetadataStar(0)
+        beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+          handleIdentifier(Map, typeReference)
+          beginTypeArguments(<)
+            handleIdentifier(String, typeReference)
+            handleNoTypeArguments(,)
+            handleType(String, null)
+            handleIdentifier(dynamic, typeReference)
+            handleNoTypeArguments(>)
+            handleType(dynamic, null)
+          endTypeArguments(2, <, >)
+          handleType(Map, null)
+          handleIdentifier(json, formalParameterDeclaration)
+          handleFormalParameterWithoutValue())
+        endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+      endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+      handleAsyncModifier(null, null)
+      beginBlockFunctionBody({)
+        beginReturnStatement(return)
+          handleIdentifier(Order, expression)
+          handleNoTypeArguments(()
+          beginArguments(()
+          endArguments(0, (, ))
+          handleSend(Order, ..)
+          beginCascade(..)
+            handleIdentifier(x, expressionContinuation)
+            handleNoTypeArguments(=)
+            handleNoArguments(=)
+            handleSend(x, =)
+            endBinaryExpression(..)
+            handleIdentifier(json, expression)
+            handleNoTypeArguments([)
+            handleNoArguments([)
+            handleSend(json, [)
+            beginLiteralString('x')
+            endLiteralString(0, ])
+            handleIndexedExpression(null, [, ])
+            beginAsOperatorType(as)
+              handleIdentifier(List, typeReference)
+              handleNoTypeArguments(?)
+              handleType(List, ?)
+            endAsOperatorType(as)
+            handleAsOperator(as)
+            handleAssignmentExpression(=)
+          endCascade()
+        endReturnStatement(true, return, ;)
+      endBlockFunctionBody(1, {, })
+    endTopLevelMethod(Order, null, })
+  endTopLevelDeclaration(class)
+  beginMetadataStar(class)
+  endMetadataStar(0)
+  beginClassOrNamedMixinApplicationPrelude(class)
+    handleIdentifier(Order, classOrMixinDeclaration)
+    handleNoTypeVariables({)
+    beginClassDeclaration(class, null, Order)
+      handleNoType(Order)
+      handleClassExtends(null)
+      handleClassNoWithClause()
+      handleClassOrMixinImplements(null, 0)
+      handleClassHeader(class, class, null)
+      beginClassOrMixinBody(DeclarationKind.Class, {)
+        beginMetadataStar(List)
+        endMetadataStar(0)
+        beginMember()
+          handleIdentifier(List, typeReference)
+          handleNoTypeArguments(?)
+          handleType(List, ?)
+          handleIdentifier(x, fieldDeclaration)
+          handleNoFieldInitializer(;)
+        endClassFields(null, null, null, null, 1, List, ;)
+      endMember()
+      beginMetadataStar(int)
+      endMetadataStar(0)
+      beginMember()
+        handleIdentifier(int, typeReference)
+        handleNoTypeArguments(?)
+        handleType(int, ?)
+        handleIdentifier(y, fieldDeclaration)
+        handleNoFieldInitializer(;)
+      endClassFields(null, null, null, null, 1, int, ;)
+    endMember()
+  endClassOrMixinBody(DeclarationKind.Class, 2, {, })
+endClassDeclaration(class, })
+endTopLevelDeclaration()
+endCompilationUnit(5, )
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect
new file mode 100644
index 0000000..536f1f7
--- /dev/null
+++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.intertwined.expect
@@ -0,0 +1,676 @@
+parseUnit(Order)
+  skipErrorTokens(Order)
+  listener: beginCompilationUnit(Order)
+  syntheticPreviousToken(Order)
+  parseTopLevelDeclarationImpl(, Instance of 'DirectiveContext')
+    parseMetadataStar()
+      listener: beginMetadataStar(Order)
+      listener: endMetadataStar(0)
+    parseTopLevelMemberImpl()
+      listener: beginTopLevelMember(Order)
+      parseTopLevelMethod(, null, , Instance of 'SimpleType', null, method1, false)
+        listener: beginTopLevelMethod(, null)
+        listener: handleIdentifier(Order, typeReference)
+        listener: handleNoTypeArguments(method1)
+        listener: handleType(Order, null)
+        ensureIdentifierPotentiallyRecovered(Order, topLevelFunctionDeclaration, false)
+          listener: handleIdentifier(method1, topLevelFunctionDeclaration)
+        parseMethodTypeVar(method1)
+          listener: handleNoTypeVariables(()
+        parseGetterOrFormalParameters(method1, method1, false, MemberKind.TopLevelMethod)
+          parseFormalParameters(method1, MemberKind.TopLevelMethod)
+            parseFormalParametersRest((, MemberKind.TopLevelMethod)
+              listener: beginFormalParameters((, MemberKind.TopLevelMethod)
+              parseFormalParameter((, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+                parseMetadataStar(()
+                  listener: beginMetadataStar(Map)
+                  listener: endMetadataStar(0)
+                listener: beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+                ensureIdentifier((, typeReference)
+                  listener: handleIdentifier(Map, typeReference)
+                listener: beginTypeArguments(<)
+                listener: handleIdentifier(String, typeReference)
+                listener: handleNoTypeArguments(,)
+                listener: handleType(String, null)
+                listener: handleIdentifier(dynamic, typeReference)
+                listener: handleNoTypeArguments(>)
+                listener: handleType(dynamic, null)
+                listener: endTypeArguments(2, <, >)
+                listener: handleType(Map, null)
+                ensureIdentifier(>, formalParameterDeclaration)
+                  listener: handleIdentifier(json, formalParameterDeclaration)
+                listener: handleFormalParameterWithoutValue())
+                listener: endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+              listener: endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+        parseAsyncModifierOpt())
+          listener: handleAsyncModifier(null, null)
+          inPlainSync()
+        parseFunctionBody(), false, false)
+          listener: beginBlockFunctionBody({)
+          notEofOrValue(}, return)
+          parseStatement({)
+            parseStatementX({)
+              parseReturnStatement({)
+                listener: beginReturnStatement(return)
+                parseExpression(return)
+                  parsePrecedenceExpression(return, 1, true)
+                    parseUnaryExpression(return, true)
+                      parsePrimary(return, expression)
+                        parseSendOrFunctionLiteral(return, expression)
+                          looksLikeFunctionBody(..)
+                          parseSend(return, expression)
+                            ensureIdentifier(return, expression)
+                              listener: handleIdentifier(Order, expression)
+                            listener: handleNoTypeArguments(()
+                            parseArgumentsOpt(Order)
+                              parseArguments(Order)
+                                parseArgumentsRest(()
+                                  listener: beginArguments(()
+                                  listener: endArguments(0, (, ))
+                            listener: handleSend(Order, ..)
+                    parseCascadeExpression())
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(x, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(x)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(x, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(x, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('x')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(List, typeReference)
+                            listener: handleNoTypeArguments(..)
+                            listener: handleType(List, null)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(List)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                    parseCascadeExpression(List)
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(y, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(y)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(y, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(y, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('y')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(int, typeReference)
+                            listener: handleNoTypeArguments(;)
+                            listener: handleType(int, null)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(int)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                ensureSemicolon(int)
+                listener: endReturnStatement(true, return, ;)
+                inGenerator()
+          notEofOrValue(}, })
+          listener: endBlockFunctionBody(1, {, })
+        listener: endTopLevelMethod(Order, null, })
+  listener: endTopLevelDeclaration(Order)
+  parseTopLevelDeclarationImpl(}, Instance of 'DirectiveContext')
+    parseMetadataStar(})
+      listener: beginMetadataStar(Order)
+      listener: endMetadataStar(0)
+    parseTopLevelMemberImpl(})
+      listener: beginTopLevelMember(Order)
+      parseTopLevelMethod(}, null, }, Instance of 'SimpleType', null, method2, false)
+        listener: beginTopLevelMethod(}, null)
+        listener: handleIdentifier(Order, typeReference)
+        listener: handleNoTypeArguments(method2)
+        listener: handleType(Order, null)
+        ensureIdentifierPotentiallyRecovered(Order, topLevelFunctionDeclaration, false)
+          listener: handleIdentifier(method2, topLevelFunctionDeclaration)
+        parseMethodTypeVar(method2)
+          listener: handleNoTypeVariables(()
+        parseGetterOrFormalParameters(method2, method2, false, MemberKind.TopLevelMethod)
+          parseFormalParameters(method2, MemberKind.TopLevelMethod)
+            parseFormalParametersRest((, MemberKind.TopLevelMethod)
+              listener: beginFormalParameters((, MemberKind.TopLevelMethod)
+              parseFormalParameter((, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+                parseMetadataStar(()
+                  listener: beginMetadataStar(Map)
+                  listener: endMetadataStar(0)
+                listener: beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+                ensureIdentifier((, typeReference)
+                  listener: handleIdentifier(Map, typeReference)
+                listener: beginTypeArguments(<)
+                listener: handleIdentifier(String, typeReference)
+                listener: handleNoTypeArguments(,)
+                listener: handleType(String, null)
+                listener: handleIdentifier(dynamic, typeReference)
+                listener: handleNoTypeArguments(>)
+                listener: handleType(dynamic, null)
+                listener: endTypeArguments(2, <, >)
+                listener: handleType(Map, null)
+                ensureIdentifier(>, formalParameterDeclaration)
+                  listener: handleIdentifier(json, formalParameterDeclaration)
+                listener: handleFormalParameterWithoutValue())
+                listener: endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+              listener: endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+        parseAsyncModifierOpt())
+          listener: handleAsyncModifier(null, null)
+          inPlainSync()
+        parseFunctionBody(), false, false)
+          listener: beginBlockFunctionBody({)
+          notEofOrValue(}, return)
+          parseStatement({)
+            parseStatementX({)
+              parseReturnStatement({)
+                listener: beginReturnStatement(return)
+                parseExpression(return)
+                  parsePrecedenceExpression(return, 1, true)
+                    parseUnaryExpression(return, true)
+                      parsePrimary(return, expression)
+                        parseSendOrFunctionLiteral(return, expression)
+                          looksLikeFunctionBody(..)
+                          parseSend(return, expression)
+                            ensureIdentifier(return, expression)
+                              listener: handleIdentifier(Order, expression)
+                            listener: handleNoTypeArguments(()
+                            parseArgumentsOpt(Order)
+                              parseArguments(Order)
+                                parseArgumentsRest(()
+                                  listener: beginArguments(()
+                                  listener: endArguments(0, (, ))
+                            listener: handleSend(Order, ..)
+                    parseCascadeExpression())
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(x, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(x)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(x, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(x, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('x')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(List, typeReference)
+                            listener: handleNoTypeArguments(?)
+                            listener: handleType(List, ?)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(?)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                    parseCascadeExpression(?)
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(y, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(y)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(y, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(y, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('y')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(int, typeReference)
+                            listener: handleNoTypeArguments(;)
+                            listener: handleType(int, null)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(int)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                ensureSemicolon(int)
+                listener: endReturnStatement(true, return, ;)
+                inGenerator()
+          notEofOrValue(}, })
+          listener: endBlockFunctionBody(1, {, })
+        listener: endTopLevelMethod(Order, null, })
+  listener: endTopLevelDeclaration(Order)
+  parseTopLevelDeclarationImpl(}, Instance of 'DirectiveContext')
+    parseMetadataStar(})
+      listener: beginMetadataStar(Order)
+      listener: endMetadataStar(0)
+    parseTopLevelMemberImpl(})
+      listener: beginTopLevelMember(Order)
+      parseTopLevelMethod(}, null, }, Instance of 'SimpleType', null, method3, false)
+        listener: beginTopLevelMethod(}, null)
+        listener: handleIdentifier(Order, typeReference)
+        listener: handleNoTypeArguments(method3)
+        listener: handleType(Order, null)
+        ensureIdentifierPotentiallyRecovered(Order, topLevelFunctionDeclaration, false)
+          listener: handleIdentifier(method3, topLevelFunctionDeclaration)
+        parseMethodTypeVar(method3)
+          listener: handleNoTypeVariables(()
+        parseGetterOrFormalParameters(method3, method3, false, MemberKind.TopLevelMethod)
+          parseFormalParameters(method3, MemberKind.TopLevelMethod)
+            parseFormalParametersRest((, MemberKind.TopLevelMethod)
+              listener: beginFormalParameters((, MemberKind.TopLevelMethod)
+              parseFormalParameter((, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+                parseMetadataStar(()
+                  listener: beginMetadataStar(Map)
+                  listener: endMetadataStar(0)
+                listener: beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+                ensureIdentifier((, typeReference)
+                  listener: handleIdentifier(Map, typeReference)
+                listener: beginTypeArguments(<)
+                listener: handleIdentifier(String, typeReference)
+                listener: handleNoTypeArguments(,)
+                listener: handleType(String, null)
+                listener: handleIdentifier(dynamic, typeReference)
+                listener: handleNoTypeArguments(>)
+                listener: handleType(dynamic, null)
+                listener: endTypeArguments(2, <, >)
+                listener: handleType(Map, null)
+                ensureIdentifier(>, formalParameterDeclaration)
+                  listener: handleIdentifier(json, formalParameterDeclaration)
+                listener: handleFormalParameterWithoutValue())
+                listener: endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+              listener: endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+        parseAsyncModifierOpt())
+          listener: handleAsyncModifier(null, null)
+          inPlainSync()
+        parseFunctionBody(), false, false)
+          listener: beginBlockFunctionBody({)
+          notEofOrValue(}, return)
+          parseStatement({)
+            parseStatementX({)
+              parseReturnStatement({)
+                listener: beginReturnStatement(return)
+                parseExpression(return)
+                  parsePrecedenceExpression(return, 1, true)
+                    parseUnaryExpression(return, true)
+                      parsePrimary(return, expression)
+                        parseSendOrFunctionLiteral(return, expression)
+                          looksLikeFunctionBody(..)
+                          parseSend(return, expression)
+                            ensureIdentifier(return, expression)
+                              listener: handleIdentifier(Order, expression)
+                            listener: handleNoTypeArguments(()
+                            parseArgumentsOpt(Order)
+                              parseArguments(Order)
+                                parseArgumentsRest(()
+                                  listener: beginArguments(()
+                                  listener: endArguments(0, (, ))
+                            listener: handleSend(Order, ..)
+                    parseCascadeExpression())
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(x, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(x)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(x, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(x, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseParenthesizedExpressionOrFunctionLiteral(=)
+                                parseParenthesizedExpression(=)
+                                  parseExpressionInParenthesis(=)
+                                    parseExpressionInParenthesisRest(()
+                                      parseExpression(()
+                                        parsePrecedenceExpression((, 1, true)
+                                          parseUnaryExpression((, true)
+                                            parsePrimary((, expression)
+                                              parseSendOrFunctionLiteral((, expression)
+                                                parseSend((, expression)
+                                                  ensureIdentifier((, expression)
+                                                    listener: handleIdentifier(json, expression)
+                                                  listener: handleNoTypeArguments([)
+                                                  parseArgumentsOpt(json)
+                                                    listener: handleNoArguments([)
+                                                  listener: handleSend(json, [)
+                                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                                            parseExpression([)
+                                              parsePrecedenceExpression([, 1, true)
+                                                parseUnaryExpression([, true)
+                                                  parsePrimary([, expression)
+                                                    parseLiteralString([)
+                                                      parseSingleLiteralString([)
+                                                        listener: beginLiteralString('x')
+                                                        listener: endLiteralString(0, ])
+                                            listener: handleIndexedExpression(null, [, ])
+                                          parseAsOperatorRest(])
+                                            listener: beginAsOperatorType(as)
+                                            computeTypeAfterIsOrAs(as)
+                                            listener: handleIdentifier(List, typeReference)
+                                            listener: handleNoTypeArguments(?)
+                                            listener: handleType(List, ?)
+                                            listener: endAsOperatorType(as)
+                                            listener: handleAsOperator(as)
+                                            skipChainedAsIsOperators(?)
+                                      ensureCloseParen(?, ()
+                                  listener: handleParenthesizedExpression(()
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                    parseCascadeExpression())
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(y, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(y)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(y, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(y, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('y')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(int, typeReference)
+                            listener: handleNoTypeArguments(;)
+                            listener: handleType(int, null)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(int)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                ensureSemicolon(int)
+                listener: endReturnStatement(true, return, ;)
+                inGenerator()
+          notEofOrValue(}, })
+          listener: endBlockFunctionBody(1, {, })
+        listener: endTopLevelMethod(Order, null, })
+  listener: endTopLevelDeclaration(Order)
+  parseTopLevelDeclarationImpl(}, Instance of 'DirectiveContext')
+    parseMetadataStar(})
+      listener: beginMetadataStar(Order)
+      listener: endMetadataStar(0)
+    parseTopLevelMemberImpl(})
+      listener: beginTopLevelMember(Order)
+      parseTopLevelMethod(}, null, }, Instance of 'SimpleType', null, method4, false)
+        listener: beginTopLevelMethod(}, null)
+        listener: handleIdentifier(Order, typeReference)
+        listener: handleNoTypeArguments(method4)
+        listener: handleType(Order, null)
+        ensureIdentifierPotentiallyRecovered(Order, topLevelFunctionDeclaration, false)
+          listener: handleIdentifier(method4, topLevelFunctionDeclaration)
+        parseMethodTypeVar(method4)
+          listener: handleNoTypeVariables(()
+        parseGetterOrFormalParameters(method4, method4, false, MemberKind.TopLevelMethod)
+          parseFormalParameters(method4, MemberKind.TopLevelMethod)
+            parseFormalParametersRest((, MemberKind.TopLevelMethod)
+              listener: beginFormalParameters((, MemberKind.TopLevelMethod)
+              parseFormalParameter((, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+                parseMetadataStar(()
+                  listener: beginMetadataStar(Map)
+                  listener: endMetadataStar(0)
+                listener: beginFormalParameter(Map, MemberKind.TopLevelMethod, null, null, null)
+                ensureIdentifier((, typeReference)
+                  listener: handleIdentifier(Map, typeReference)
+                listener: beginTypeArguments(<)
+                listener: handleIdentifier(String, typeReference)
+                listener: handleNoTypeArguments(,)
+                listener: handleType(String, null)
+                listener: handleIdentifier(dynamic, typeReference)
+                listener: handleNoTypeArguments(>)
+                listener: handleType(dynamic, null)
+                listener: endTypeArguments(2, <, >)
+                listener: handleType(Map, null)
+                ensureIdentifier(>, formalParameterDeclaration)
+                  listener: handleIdentifier(json, formalParameterDeclaration)
+                listener: handleFormalParameterWithoutValue())
+                listener: endFormalParameter(null, null, json, null, null, FormalParameterKind.mandatory, MemberKind.TopLevelMethod)
+              listener: endFormalParameters(1, (, ), MemberKind.TopLevelMethod)
+        parseAsyncModifierOpt())
+          listener: handleAsyncModifier(null, null)
+          inPlainSync()
+        parseFunctionBody(), false, false)
+          listener: beginBlockFunctionBody({)
+          notEofOrValue(}, return)
+          parseStatement({)
+            parseStatementX({)
+              parseReturnStatement({)
+                listener: beginReturnStatement(return)
+                parseExpression(return)
+                  parsePrecedenceExpression(return, 1, true)
+                    parseUnaryExpression(return, true)
+                      parsePrimary(return, expression)
+                        parseSendOrFunctionLiteral(return, expression)
+                          looksLikeFunctionBody(..)
+                          parseSend(return, expression)
+                            ensureIdentifier(return, expression)
+                              listener: handleIdentifier(Order, expression)
+                            listener: handleNoTypeArguments(()
+                            parseArgumentsOpt(Order)
+                              parseArguments(Order)
+                                parseArgumentsRest(()
+                                  listener: beginArguments(()
+                                  listener: endArguments(0, (, ))
+                            listener: handleSend(Order, ..)
+                    parseCascadeExpression())
+                      listener: beginCascade(..)
+                      parseSend(.., expressionContinuation)
+                        ensureIdentifier(.., expressionContinuation)
+                          listener: handleIdentifier(x, expressionContinuation)
+                        listener: handleNoTypeArguments(=)
+                        parseArgumentsOpt(x)
+                          listener: handleNoArguments(=)
+                        listener: handleSend(x, =)
+                      listener: endBinaryExpression(..)
+                      parseArgumentOrIndexStar(x, Instance of 'NoTypeParamOrArg', false)
+                      parseExpressionWithoutCascade(=)
+                        parsePrecedenceExpression(=, 1, false)
+                          parseUnaryExpression(=, false)
+                            parsePrimary(=, expression)
+                              parseSendOrFunctionLiteral(=, expression)
+                                parseSend(=, expression)
+                                  ensureIdentifier(=, expression)
+                                    listener: handleIdentifier(json, expression)
+                                  listener: handleNoTypeArguments([)
+                                  parseArgumentsOpt(json)
+                                    listener: handleNoArguments([)
+                                  listener: handleSend(json, [)
+                          parseArgumentOrIndexStar(json, Instance of 'NoTypeParamOrArg', false)
+                            parseExpression([)
+                              parsePrecedenceExpression([, 1, true)
+                                parseUnaryExpression([, true)
+                                  parsePrimary([, expression)
+                                    parseLiteralString([)
+                                      parseSingleLiteralString([)
+                                        listener: beginLiteralString('x')
+                                        listener: endLiteralString(0, ])
+                            listener: handleIndexedExpression(null, [, ])
+                          parseAsOperatorRest(])
+                            listener: beginAsOperatorType(as)
+                            computeTypeAfterIsOrAs(as)
+                            listener: handleIdentifier(List, typeReference)
+                            listener: handleNoTypeArguments(?)
+                            listener: handleType(List, ?)
+                            listener: endAsOperatorType(as)
+                            listener: handleAsOperator(as)
+                            skipChainedAsIsOperators(?)
+                      listener: handleAssignmentExpression(=)
+                      listener: endCascade()
+                ensureSemicolon(?)
+                listener: endReturnStatement(true, return, ;)
+                inGenerator()
+          notEofOrValue(}, })
+          listener: endBlockFunctionBody(1, {, })
+        listener: endTopLevelMethod(Order, null, })
+  listener: endTopLevelDeclaration(class)
+  parseTopLevelDeclarationImpl(}, Instance of 'DirectiveContext')
+    parseMetadataStar(})
+      listener: beginMetadataStar(class)
+      listener: endMetadataStar(0)
+    parseTopLevelKeywordDeclaration(}, class, Instance of 'DirectiveContext')
+      parseClassDeclarationModifiers(}, class)
+      parseClassOrNamedMixinApplication(null, class)
+        listener: beginClassOrNamedMixinApplicationPrelude(class)
+        ensureIdentifier(class, classOrMixinDeclaration)
+          listener: handleIdentifier(Order, classOrMixinDeclaration)
+        listener: handleNoTypeVariables({)
+        listener: beginClassDeclaration(class, null, Order)
+        parseClass(Order, class, class, Order)
+          parseClassHeaderOpt(Order, class, class)
+            parseClassExtendsOpt(Order)
+              listener: handleNoType(Order)
+              listener: handleClassExtends(null)
+            parseWithClauseOpt(Order)
+              listener: handleClassNoWithClause()
+            parseClassOrMixinImplementsOpt(Order)
+              listener: handleClassOrMixinImplements(null, 0)
+            listener: handleClassHeader(class, class, null)
+          parseClassOrMixinOrExtensionBody(Order, DeclarationKind.Class, Order)
+            listener: beginClassOrMixinBody(DeclarationKind.Class, {)
+            notEofOrValue(}, List)
+            parseClassOrMixinOrExtensionMemberImpl({, DeclarationKind.Class, Order)
+              parseMetadataStar({)
+                listener: beginMetadataStar(List)
+                listener: endMetadataStar(0)
+              listener: beginMember()
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleNullableType', x, DeclarationKind.Class, Order, false)
+                listener: handleIdentifier(List, typeReference)
+                listener: handleNoTypeArguments(?)
+                listener: handleType(List, ?)
+                ensureIdentifierPotentiallyRecovered(?, fieldDeclaration, false)
+                  listener: handleIdentifier(x, fieldDeclaration)
+                parseFieldInitializerOpt(x, x, null, null, null, null, DeclarationKind.Class, Order)
+                  listener: handleNoFieldInitializer(;)
+                listener: endClassFields(null, null, null, null, 1, List, ;)
+              listener: endMember()
+            notEofOrValue(}, int)
+            parseClassOrMixinOrExtensionMemberImpl(;, DeclarationKind.Class, Order)
+              parseMetadataStar(;)
+                listener: beginMetadataStar(int)
+                listener: endMetadataStar(0)
+              listener: beginMember()
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleNullableType', y, DeclarationKind.Class, Order, false)
+                listener: handleIdentifier(int, typeReference)
+                listener: handleNoTypeArguments(?)
+                listener: handleType(int, ?)
+                ensureIdentifierPotentiallyRecovered(?, fieldDeclaration, false)
+                  listener: handleIdentifier(y, fieldDeclaration)
+                parseFieldInitializerOpt(y, y, null, null, null, null, DeclarationKind.Class, Order)
+                  listener: handleNoFieldInitializer(;)
+                listener: endClassFields(null, null, null, null, 1, int, ;)
+              listener: endMember()
+            notEofOrValue(}, })
+            listener: endClassOrMixinBody(DeclarationKind.Class, 2, {, })
+          listener: endClassDeclaration(class, })
+  listener: endTopLevelDeclaration()
+  reportAllErrorTokens(Order)
+  listener: endCompilationUnit(5, )
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.parser.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.parser.expect
new file mode 100644
index 0000000..6da417a0
--- /dev/null
+++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.parser.expect
@@ -0,0 +1,55 @@
+Order method1(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List
+..y = json['y'] as int;
+}
+
+Order method2(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List?
+..y = json['y'] as int;
+}
+
+Order method3(Map<String, dynamic> json) {
+return Order()
+..x = (json['x'] as List?)
+..y = json['y'] as int;
+}
+
+Order method4(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List?;
+}
+
+class Order {
+List? x;
+int? y;
+}
+
+Order[StringToken] method1[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method2[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method3[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] ([BeginToken]json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken])[SimpleToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method4[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken];[SimpleToken]
+}[SimpleToken]
+
+class[KeywordToken] Order[StringToken] {[BeginToken]
+List[StringToken]?[SimpleToken] x[StringToken];[SimpleToken]
+int[StringToken]?[SimpleToken] y[StringToken];[SimpleToken]
+}[SimpleToken][SimpleToken]
diff --git a/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.scanner.expect b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.scanner.expect
new file mode 100644
index 0000000..6da417a0
--- /dev/null
+++ b/pkg/front_end/parser_testcases/nnbd/issue_42621.dart.scanner.expect
@@ -0,0 +1,55 @@
+Order method1(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List
+..y = json['y'] as int;
+}
+
+Order method2(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List?
+..y = json['y'] as int;
+}
+
+Order method3(Map<String, dynamic> json) {
+return Order()
+..x = (json['x'] as List?)
+..y = json['y'] as int;
+}
+
+Order method4(Map<String, dynamic> json) {
+return Order()
+..x = json['x'] as List?;
+}
+
+class Order {
+List? x;
+int? y;
+}
+
+Order[StringToken] method1[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method2[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method3[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] ([BeginToken]json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken])[SimpleToken]
+..[SimpleToken]y[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'y'[StringToken]][SimpleToken] as[KeywordToken] int[StringToken];[SimpleToken]
+}[SimpleToken]
+
+Order[StringToken] method4[StringToken]([BeginToken]Map[StringToken]<[BeginToken]String[StringToken],[SimpleToken] dynamic[KeywordToken]>[SimpleToken] json[StringToken])[SimpleToken] {[BeginToken]
+return[KeywordToken] Order[StringToken]([BeginToken])[SimpleToken]
+..[SimpleToken]x[StringToken] =[SimpleToken] json[StringToken][[BeginToken]'x'[StringToken]][SimpleToken] as[KeywordToken] List[StringToken]?[SimpleToken];[SimpleToken]
+}[SimpleToken]
+
+class[KeywordToken] Order[StringToken] {[BeginToken]
+List[StringToken]?[SimpleToken] x[StringToken];[SimpleToken]
+int[StringToken]?[SimpleToken] y[StringToken];[SimpleToken]
+}[SimpleToken][SimpleToken]
diff --git a/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect
index ca211fe..0824b96 100644
--- a/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/late_member.dart.intertwined.expect
@@ -341,7 +341,7 @@
                 listener: beginMetadataStar(late)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, late, DeclarationKind.Class, X, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, late, DeclarationKind.Class, X, false)
                 listener: beginMethod(null, null, null, null, null, late)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -432,13 +432,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', late, DeclarationKind.Class, Y, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', late, DeclarationKind.Class, Y, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(late)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(late, fieldDeclaration)
-                parseFieldInitializerOpt(late, late, null, null, DeclarationKind.Class, Y)
+                parseFieldInitializerOpt(late, late, null, null, null, null, DeclarationKind.Class, Y)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect
index 8faa8f7..155bdd0 100644
--- a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.expect
@@ -101,7 +101,7 @@
         beginVariablesDeclaration(foo, late, null)
           handleIdentifier(foo, localVariableDeclaration)
           beginInitializedIdentifier(foo)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(foo)
           endInitializedIdentifier(foo)
         endVariablesDeclaration(1, ;)
         handleIdentifier(foo, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect
index 2fecad0..42ff91b 100644
--- a/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/late_modifier.dart.intertwined.expect
@@ -265,7 +265,7 @@
                         listener: handleIdentifier(foo, localVariableDeclaration)
                       listener: beginInitializedIdentifier(foo)
                       parseVariableInitializerOpt(foo)
-                        listener: handleNoVariableInitializer(;)
+                        listener: handleNoVariableInitializer(foo)
                       listener: endInitializedIdentifier(foo)
                     ensureSemicolon(foo)
                     listener: endVariablesDeclaration(1, ;)
@@ -389,7 +389,7 @@
                 listener: beginMetadataStar(late)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, late, DeclarationKind.Class, X, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, late, DeclarationKind.Class, X, false)
                 listener: beginMethod(null, null, null, null, null, late)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -480,13 +480,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', late, DeclarationKind.Class, Y, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', late, DeclarationKind.Class, Y, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(late)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(late, fieldDeclaration)
-                parseFieldInitializerOpt(late, late, null, null, DeclarationKind.Class, Y)
+                parseFieldInitializerOpt(late, late, null, null, null, null, DeclarationKind.Class, Y)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect
index 6774f62..b5fe182 100644
--- a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect
+++ b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.expect
@@ -95,7 +95,7 @@
         beginVariablesDeclaration(c1, null, null)
           handleIdentifier(c1, localVariableDeclaration)
           beginInitializedIdentifier(c1)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c1)
           endInitializedIdentifier(c1)
         endVariablesDeclaration(1, ;)
         handleIdentifier(c1, expression)
diff --git a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect
index d6e66a9..2a6ddba 100644
--- a/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/null_shorting_index.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, Class1, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', null, operator, DeclarationKind.Class, Class1, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(operator)
@@ -89,7 +89,7 @@
                 listener: beginMetadataStar(void)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod(;, null, null, null, null, null, ;, Instance of 'VoidType', null, operator, DeclarationKind.Class, Class1, false)
+              parseMethod(;, null, null, null, null, null, null, ;, Instance of 'VoidType', null, operator, DeclarationKind.Class, Class1, false)
                 listener: beginMethod(null, null, null, null, null, operator)
                 listener: handleVoidKeyword(void)
                 parseOperatorName(void)
@@ -182,7 +182,7 @@
                       listener: handleIdentifier(c1, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c1)
                     parseVariableInitializerOpt(c1)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c1)
                     listener: endInitializedIdentifier(c1)
                   ensureSemicolon(c1)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect
index 993b8d5..d96a3c0 100644
--- a/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/required_member.dart.intertwined.expect
@@ -341,7 +341,7 @@
                 listener: beginMetadataStar(required)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, required, DeclarationKind.Class, X, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, required, DeclarationKind.Class, X, false)
                 listener: beginMethod(null, null, null, null, null, required)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -432,13 +432,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', required, DeclarationKind.Class, Y, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', required, DeclarationKind.Class, Y, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(required)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(required, fieldDeclaration)
-                parseFieldInitializerOpt(required, required, null, null, DeclarationKind.Class, Y)
+                parseFieldInitializerOpt(required, required, null, null, null, null, DeclarationKind.Class, Y)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect
index a8ff973..dce54ab 100644
--- a/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/nnbd/required_modifier.dart.intertwined.expect
@@ -357,7 +357,7 @@
                 listener: beginMetadataStar(required)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'NoType', null, required, DeclarationKind.Class, X, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'NoType', null, required, DeclarationKind.Class, X, false)
                 listener: beginMethod(null, null, null, null, null, required)
                 listener: handleNoType({)
                 ensureIdentifierPotentiallyRecovered({, methodDeclaration, false)
@@ -448,13 +448,13 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', required, DeclarationKind.Class, Y, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', required, DeclarationKind.Class, Y, false)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(required)
                 listener: handleType(int, null)
                 ensureIdentifierPotentiallyRecovered(int, fieldDeclaration, false)
                   listener: handleIdentifier(required, fieldDeclaration)
-                parseFieldInitializerOpt(required, required, null, null, DeclarationKind.Class, Y)
+                parseFieldInitializerOpt(required, required, null, null, null, null, DeclarationKind.Class, Y)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.expect
index fa50909..1b5dade 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.expect
@@ -16,7 +16,7 @@
         beginVariablesDeclaration(c, null, var)
           handleIdentifier(c, localVariableDeclaration)
           beginInitializedIdentifier(c)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c)
           endInitializedIdentifier(c)
         endVariablesDeclaration(1, ;)
         handleIdentifier(c, expression)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.intertwined.expect
index 35d43d6..4fc4b624 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_39326.dart.intertwined.expect
@@ -41,7 +41,7 @@
                       listener: handleIdentifier(c, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c)
                     parseVariableInitializerOpt(c)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c)
                     listener: endInitializedIdentifier(c)
                   ensureSemicolon(c)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.expect
index b143be7..51ede43 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.expect
@@ -16,15 +16,15 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
           handleIdentifier(c, localVariableDeclaration)
           beginInitializedIdentifier(c)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(c)
           endInitializedIdentifier(c)
         endVariablesDeclaration(3, ;)
         handleIdentifier(a, expression)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.intertwined.expect
index 6761e0c..caa1810 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional.dart.intertwined.expect
@@ -41,21 +41,21 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(c, localVariableDeclaration)
                     listener: beginInitializedIdentifier(c)
                     parseVariableInitializerOpt(c)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(c)
                     listener: endInitializedIdentifier(c)
                   ensureSemicolon(c)
                   listener: endVariablesDeclaration(3, ;)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.expect
index 6acafe8..947256d 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.expect
@@ -16,11 +16,11 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(,)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
           handleIdentifier(b, localVariableDeclaration)
           beginInitializedIdentifier(b)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(b)
           endInitializedIdentifier(b)
         endVariablesDeclaration(2, ;)
         beginReturnStatement(return)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.intertwined.expect
index a4a13e9..2b95e24 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_2.dart.intertwined.expect
@@ -41,14 +41,14 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(,)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   parseOptionallyInitializedIdentifier(,)
                     ensureIdentifier(,, localVariableDeclaration)
                       listener: handleIdentifier(b, localVariableDeclaration)
                     listener: beginInitializedIdentifier(b)
                     parseVariableInitializerOpt(b)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(b)
                     listener: endInitializedIdentifier(b)
                   ensureSemicolon(b)
                   listener: endVariablesDeclaration(2, ;)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.expect
index cad0a56..b24106f 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.expect
@@ -16,7 +16,7 @@
         beginVariablesDeclaration(a, null, var)
           handleIdentifier(a, localVariableDeclaration)
           beginInitializedIdentifier(a)
-            handleNoVariableInitializer(;)
+            handleNoVariableInitializer(a)
           endInitializedIdentifier(a)
         endVariablesDeclaration(1, ;)
         beginReturnStatement(return)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.intertwined.expect
index ac9fa6e..ba903a4 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_3.dart.intertwined.expect
@@ -41,7 +41,7 @@
                       listener: handleIdentifier(a, localVariableDeclaration)
                     listener: beginInitializedIdentifier(a)
                     parseVariableInitializerOpt(a)
-                      listener: handleNoVariableInitializer(;)
+                      listener: handleNoVariableInitializer(a)
                     listener: endInitializedIdentifier(a)
                   ensureSemicolon(a)
                   listener: endVariablesDeclaration(1, ;)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_4.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_4.dart.intertwined.expect
index 4ff7912..5f46730 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_4.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40267_conditional_4.dart.intertwined.expect
@@ -8,27 +8,27 @@
       listener: endMetadataStar(0)
     parseTopLevelMemberImpl()
       listener: beginTopLevelMember(var)
-      parseFields(, null, null, null, null, var, var, Instance of 'NoType', a, DeclarationKind.TopLevel, null, false)
+      parseFields(, null, null, null, null, null, var, var, Instance of 'NoType', a, DeclarationKind.TopLevel, null, false)
         listener: handleNoType(var)
         ensureIdentifierPotentiallyRecovered(var, topLevelVariableDeclaration, false)
           listener: handleIdentifier(a, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(a, a, null, var, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(a, a, null, null, null, var, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(,)
         ensureIdentifier(,, topLevelVariableDeclaration)
           listener: handleIdentifier(b, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(b, b, null, var, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(b, b, null, null, null, var, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(,)
         ensureIdentifier(,, topLevelVariableDeclaration)
           listener: handleIdentifier(c, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(c, c, null, var, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(c, c, null, null, null, var, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(,)
         ensureIdentifier(,, topLevelVariableDeclaration)
           listener: handleIdentifier(d, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(d, d, null, var, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(d, d, null, null, null, var, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(,)
         ensureIdentifier(,, topLevelVariableDeclaration)
           listener: handleIdentifier(e, topLevelVariableDeclaration)
-        parseFieldInitializerOpt(e, e, null, var, DeclarationKind.TopLevel, null)
+        parseFieldInitializerOpt(e, e, null, null, null, var, DeclarationKind.TopLevel, null)
           listener: handleNoFieldInitializer(;)
         listener: endTopLevelFields(null, null, null, var, 5, var, ;)
   listener: endTopLevelDeclaration(List)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40288.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40288.dart.intertwined.expect
index 223ac8e..4d741e9 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40288.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40288.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, late, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, late, false)
                 listener: beginMethod(null, null, null, null, get, g)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -97,7 +97,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, required, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, required, false)
                 listener: beginMethod(null, null, null, null, get, g)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -162,13 +162,13 @@
                 listener: beginMetadataStar(late)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', l, DeclarationKind.Class, C, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', l, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(late, typeReference)
                 listener: handleNoTypeArguments(l)
                 listener: handleType(late, null)
                 ensureIdentifierPotentiallyRecovered(late, fieldDeclaration, false)
                   listener: handleIdentifier(l, fieldDeclaration)
-                parseFieldInitializerOpt(l, l, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -195,13 +195,13 @@
                 listener: beginMetadataStar(required)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.Class, C, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(required, typeReference)
                 listener: handleNoTypeArguments(r)
                 listener: handleType(required, null)
                 ensureIdentifierPotentiallyRecovered(required, fieldDeclaration, false)
                   listener: handleIdentifier(r, fieldDeclaration)
-                parseFieldInitializerOpt(r, r, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/parser_testcases/non-nnbd/issue_40288_prime.dart.intertwined.expect b/pkg/front_end/parser_testcases/non-nnbd/issue_40288_prime.dart.intertwined.expect
index 0d80626..5e5e660 100644
--- a/pkg/front_end/parser_testcases/non-nnbd/issue_40288_prime.dart.intertwined.expect
+++ b/pkg/front_end/parser_testcases/non-nnbd/issue_40288_prime.dart.intertwined.expect
@@ -32,7 +32,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, Xlate, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, Xlate, false)
                 listener: beginMethod(null, null, null, null, get, g)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -97,7 +97,7 @@
                 listener: beginMetadataStar(int)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseMethod({, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, Xrequired, false)
+              parseMethod({, null, null, null, null, null, null, {, Instance of 'SimpleType', get, g, DeclarationKind.Class, Xrequired, false)
                 listener: beginMethod(null, null, null, null, get, g)
                 listener: handleIdentifier(int, typeReference)
                 listener: handleNoTypeArguments(get)
@@ -162,13 +162,13 @@
                 listener: beginMetadataStar(Xlate)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields({, null, null, null, null, null, {, Instance of 'SimpleType', l, DeclarationKind.Class, C, false)
+              parseFields({, null, null, null, null, null, null, {, Instance of 'SimpleType', l, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(Xlate, typeReference)
                 listener: handleNoTypeArguments(l)
                 listener: handleType(Xlate, null)
                 ensureIdentifierPotentiallyRecovered(Xlate, fieldDeclaration, false)
                   listener: handleIdentifier(l, fieldDeclaration)
-                parseFieldInitializerOpt(l, l, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(l, l, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
@@ -195,13 +195,13 @@
                 listener: beginMetadataStar(Xrequired)
                 listener: endMetadataStar(0)
               listener: beginMember()
-              parseFields(;, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.Class, C, false)
+              parseFields(;, null, null, null, null, null, null, ;, Instance of 'SimpleType', r, DeclarationKind.Class, C, false)
                 listener: handleIdentifier(Xrequired, typeReference)
                 listener: handleNoTypeArguments(r)
                 listener: handleType(Xrequired, null)
                 ensureIdentifierPotentiallyRecovered(Xrequired, fieldDeclaration, false)
                   listener: handleIdentifier(r, fieldDeclaration)
-                parseFieldInitializerOpt(r, r, null, null, DeclarationKind.Class, C)
+                parseFieldInitializerOpt(r, r, null, null, null, null, DeclarationKind.Class, C)
                   listener: beginFieldInitializer(=)
                   parseExpression(=)
                     parsePrecedenceExpression(=, 1, true)
diff --git a/pkg/front_end/test/fasta/expression_suite.dart b/pkg/front_end/test/fasta/expression_suite.dart
index 7ca9e56..03865e8 100644
--- a/pkg/front_end/test/fasta/expression_suite.dart
+++ b/pkg/front_end/test/fasta/expression_suite.dart
@@ -113,7 +113,9 @@
     if (compiledProcedure == null) {
       buffer.write("<no procedure>");
     } else {
-      new Printer(buffer).visitProcedure(compiledProcedure);
+      Printer printer = new Printer(buffer);
+      printer.visitProcedure(compiledProcedure);
+      printer.writeConstantTable(new Component());
     }
     Uri base = entryPoint.resolve(".");
     return "$buffer".replaceAll("$base", "org-dartlang-testcase:///");
diff --git a/pkg/front_end/test/fasta/parser/literal_entry_info_test.dart b/pkg/front_end/test/fasta/parser/literal_entry_info_test.dart
index 91d645b..1cdea58 100644
--- a/pkg/front_end/test/fasta/parser/literal_entry_info_test.dart
+++ b/pkg/front_end/test/fasta/parser/literal_entry_info_test.dart
@@ -153,7 +153,7 @@
         'beginVariablesDeclaration a var',
         'handleIdentifier a localVariableDeclaration',
         'beginInitializedIdentifier a',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer a',
         'endInitializedIdentifier a',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration a',
@@ -188,7 +188,7 @@
         'beginVariablesDeclaration x var',
         'handleIdentifier x localVariableDeclaration',
         'beginInitializedIdentifier x',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer x',
         'endInitializedIdentifier x',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration x',
@@ -250,7 +250,7 @@
         'beginVariablesDeclaration x var',
         'handleIdentifier x localVariableDeclaration',
         'beginInitializedIdentifier x',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer x',
         'endInitializedIdentifier x',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration x',
@@ -280,7 +280,7 @@
         'beginVariablesDeclaration x var',
         'handleIdentifier x localVariableDeclaration',
         'beginInitializedIdentifier x',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer x',
         'endInitializedIdentifier x',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration x',
@@ -675,7 +675,7 @@
         'beginVariablesDeclaration x var',
         'handleIdentifier x localVariableDeclaration',
         'beginInitializedIdentifier x',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer x',
         'endInitializedIdentifier x',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration x',
@@ -706,7 +706,7 @@
         'beginVariablesDeclaration x var',
         'handleIdentifier x localVariableDeclaration',
         'beginInitializedIdentifier x',
-        'handleNoVariableInitializer in',
+        'handleNoVariableInitializer x',
         'endInitializedIdentifier x',
         'endVariablesDeclaration 1 null',
         'handleForInitializerLocalVariableDeclaration x',
diff --git a/pkg/front_end/test/fasta/testing/suite.dart b/pkg/front_end/test/fasta/testing/suite.dart
index 4b03080..a9a355b 100644
--- a/pkg/front_end/test/fasta/testing/suite.dart
+++ b/pkg/front_end/test/fasta/testing/suite.dart
@@ -203,7 +203,7 @@
   final Map<Component, List<Iterable<String>>> componentToDiagnostics =
       <Component, List<Iterable<String>>>{};
   final Uri platformBinaries;
-  final Map<Uri, UriTranslator> _uriTranslators = {};
+  final Map<UriConfiguration, UriTranslator> _uriTranslators = {};
   final Map<Uri, TestOptions> _testOptions = {};
   final Map<Uri, LinkDependenciesOptions> _linkDependencies = {};
   final Map<Uri, Uri> _librariesJson = {};
@@ -364,9 +364,8 @@
 
   Future<UriTranslator> computeUriTranslator(
       TestDescription description) async {
-    Uri librariesSpecificationUri =
-        computeLibrariesSpecificationUri(description);
-    UriTranslator uriTranslator = _uriTranslators[librariesSpecificationUri];
+    UriConfiguration uriConfiguration = computeUriConfiguration(description);
+    UriTranslator uriTranslator = _uriTranslators[uriConfiguration];
     if (uriTranslator == null) {
       Uri sdk = Uri.base.resolve("sdk/");
       Uri packages = Uri.base.resolve(".packages");
@@ -376,7 +375,7 @@
           throw message.plainTextFormatted.join("\n");
         }
         ..sdkRoot = sdk
-        ..packagesFileUri = packages
+        ..packagesFileUri = uriConfiguration.packageConfigUri ?? packages
         ..environmentDefines = {}
         ..experimentalFlags =
             testOptions.computeExperimentalFlags(experimentalFlags)
@@ -385,14 +384,15 @@
             : (testOptions.nnbdAgnosticMode
                 ? NnbdMode.Agnostic
                 : NnbdMode.Strong)
-        ..librariesSpecificationUri = librariesSpecificationUri;
+        ..librariesSpecificationUri =
+            uriConfiguration.librariesSpecificationUri;
       if (testOptions.overwriteCurrentSdkVersion != null) {
         compilerOptions.currentSdkVersion =
             testOptions.overwriteCurrentSdkVersion;
       }
       ProcessedOptions options = new ProcessedOptions(options: compilerOptions);
       uriTranslator = await options.getUriTranslator();
-      _uriTranslators[librariesSpecificationUri] = uriTranslator;
+      _uriTranslators[uriConfiguration] = uriTranslator;
     }
     return uriTranslator;
   }
@@ -431,11 +431,15 @@
             }
             nnbdMode = NnbdMode.Weak;
           } else {
-            File f = new File.fromUri(description.uri.resolve(line));
-            if (!f.existsSync()) {
-              throw new UnsupportedError("No file found: $f ($line)");
+            Uri uri = description.uri.resolve(line);
+            if (uri.scheme != 'package') {
+              File f = new File.fromUri(uri);
+              if (!f.existsSync()) {
+                throw new UnsupportedError("No file found: $f ($line)");
+              }
+              uri = f.uri;
             }
-            content.add(f.uri);
+            content.add(uri);
           }
         }
       }
@@ -461,6 +465,20 @@
     }
   }
 
+  /// Custom package config used for [description].
+  Uri computePackageConfigUri(TestDescription description) {
+    Uri packageConfig =
+        description.uri.resolve(".dart_tool/package_config.json");
+    return new File.fromUri(packageConfig).existsSync() ? packageConfig : null;
+  }
+
+  UriConfiguration computeUriConfiguration(TestDescription description) {
+    Uri librariesSpecificationUri =
+        computeLibrariesSpecificationUri(description);
+    Uri packageConfigUri = computePackageConfigUri(description);
+    return new UriConfiguration(librariesSpecificationUri, packageConfigUri);
+  }
+
   Expectation get verificationError => expectationSet["VerificationError"];
 
   Future ensurePlatformUris() async {
@@ -574,7 +592,7 @@
           if (experimentalFlags[ExperimentalFlag.nonNullable]) {
             args.add("--enable-experiment=non-nullable");
             if (!context.weak) {
-              args.add("--null-safety");
+              args.add("--sound-null-safety");
             }
           }
           args.add(generated.path);
@@ -666,7 +684,7 @@
         linkDependenciesOptions.component = p;
         List<Library> keepLibraries = new List<Library>();
         for (Library lib in p.libraries) {
-          if (linkDependenciesOptions.content.contains(lib.fileUri)) {
+          if (linkDependenciesOptions.content.contains(lib.importUri)) {
             keepLibraries.add(lib);
           }
         }
@@ -896,3 +914,22 @@
         ".hierarchy.expect", "$sb", uri, result);
   }
 }
+
+class UriConfiguration {
+  final Uri librariesSpecificationUri;
+  final Uri packageConfigUri;
+
+  UriConfiguration(this.librariesSpecificationUri, this.packageConfigUri);
+
+  @override
+  int get hashCode =>
+      librariesSpecificationUri.hashCode * 13 + packageConfigUri.hashCode * 17;
+
+  @override
+  bool operator ==(Object other) {
+    if (identical(this, other)) return true;
+    return other is UriConfiguration &&
+        librariesSpecificationUri == other.librariesSpecificationUri &&
+        packageConfigUri == other.packageConfigUri;
+  }
+}
diff --git a/pkg/front_end/test/hot_reload_e2e_test.dart b/pkg/front_end/test/hot_reload_e2e_test.dart
index d58ec7f..939d3a0 100644
--- a/pkg/front_end/test/hot_reload_e2e_test.dart
+++ b/pkg/front_end/test/hot_reload_e2e_test.dart
@@ -103,6 +103,10 @@
       '--enable-vm-service=0', // Note: use 0 to avoid port collisions.
       '--pause_isolates_on_start',
       '--disable-service-auth-codes',
+      // TODO(bkonyi): The service isolate starts before DartDev has a chance
+      // to spawn DDS. We should suppress the Observatory message until DDS
+      // starts (#42727).
+      '--disable-dart-dev',
       outputUri.toFilePath()
     ];
     vmArgs.add('$reloadCount');
diff --git a/pkg/front_end/test/incremental_compiler_leak_test.dart b/pkg/front_end/test/incremental_compiler_leak_test.dart
index 03f68dd..326c2e2 100644
--- a/pkg/front_end/test/incremental_compiler_leak_test.dart
+++ b/pkg/front_end/test/incremental_compiler_leak_test.dart
@@ -13,6 +13,7 @@
   LeakFinder heapHelper = new LeakFinder();
 
   heapHelper.start([
+    "--disable-dart-dev",
     "--enable-asserts",
     Platform.script.resolve("incremental_dart2js_tester.dart").toString(),
     "--addDebugBreaks",
diff --git a/pkg/front_end/test/incremental_load_from_dill_suite.dart b/pkg/front_end/test/incremental_load_from_dill_suite.dart
index 52c9a86..9131713 100644
--- a/pkg/front_end/test/incremental_load_from_dill_suite.dart
+++ b/pkg/front_end/test/incremental_load_from_dill_suite.dart
@@ -26,6 +26,8 @@
 import "package:front_end/src/api_prototype/memory_file_system.dart"
     show MemoryFileSystem;
 
+import 'package:front_end/src/base/nnbd_mode.dart' show NnbdMode;
+
 import 'package:front_end/src/base/processed_options.dart'
     show ProcessedOptions;
 
@@ -112,6 +114,7 @@
   @override
   Future<void> cleanUp(TestDescription description, Result result) async {
     await cleanupHelper?.outDir?.delete(recursive: true);
+    cleanupHelper?.outDir = null;
   }
 
   TestData cleanupHelper;
@@ -328,6 +331,12 @@
   Component component2;
   Component component3;
 
+  String doStringReplacements(String input) {
+    String output = input.replaceAll("%NNBD_VERSION_MARKER%",
+        "${enableNonNullableVersion.major}.${enableNonNullableVersion.minor}");
+    return output;
+  }
+
   Future<Null> newWorldTest(
       TestData data,
       Context context,
@@ -458,6 +467,9 @@
         if (filename == ".packages") {
           packagesUri = uri;
         }
+        if (world["enableStringReplacement"] == true) {
+          data = doStringReplacements(data);
+        }
         fs.entityForUri(uri).writeAsStringSync(data);
       }
       if (world["dotPackagesFile"] != null) {
@@ -481,6 +493,16 @@
                       throw "Error on parsing experiments flags: $e");
           options.experimentalFlags = experimentalFlags;
         }
+        if (world["nnbdMode"] != null) {
+          String nnbdMode = world["nnbdMode"];
+          switch (nnbdMode) {
+            case "strong":
+              options.nnbdMode = NnbdMode.Strong;
+              break;
+            default:
+              throw "Not supported nnbd mode: $nnbdMode";
+          }
+        }
       }
       if (packagesUri != null) {
         options.packagesFileUri = packagesUri;
diff --git a/pkg/front_end/test/language_versioning/data/issue42661a/.dart_tool/package_config.json b/pkg/front_end/test/language_versioning/data/issue42661a/.dart_tool/package_config.json
new file mode 100644
index 0000000..0286844
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661a/.dart_tool/package_config.json
@@ -0,0 +1,10 @@
+{
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "pack",
+      "rootUri": "../pack/lib/",
+      "languageVersion": "2.7"
+    }
+  ]
+}
\ No newline at end of file
diff --git a/pkg/front_end/test/language_versioning/data/issue42661a/main.dart b/pkg/front_end/test/language_versioning/data/issue42661a/main.dart
new file mode 100644
index 0000000..06c234a
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661a/main.dart
@@ -0,0 +1,3 @@
+/*library: languageVersion=2.8*/
+
+import 'pack/web/pack.dart';
diff --git a/pkg/front_end/test/language_versioning/data/issue42661a/pack/lib/src/part.dart b/pkg/front_end/test/language_versioning/data/issue42661a/pack/lib/src/part.dart
new file mode 100644
index 0000000..835902f
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661a/pack/lib/src/part.dart
@@ -0,0 +1 @@
+part of pack;
diff --git a/pkg/front_end/test/language_versioning/data/issue42661a/pack/web/pack.dart b/pkg/front_end/test/language_versioning/data/issue42661a/pack/web/pack.dart
new file mode 100644
index 0000000..68e26be
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661a/pack/web/pack.dart
@@ -0,0 +1,4 @@
+/*library: languageVersion=2.8*/
+library pack;
+
+part /*error: errors=LanguageVersionMismatchInPart*/ 'package:pack/src/part.dart';
diff --git a/pkg/front_end/test/language_versioning/data/issue42661b/.dart_tool/package_config.json b/pkg/front_end/test/language_versioning/data/issue42661b/.dart_tool/package_config.json
new file mode 100644
index 0000000..00f6b8c
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661b/.dart_tool/package_config.json
@@ -0,0 +1,11 @@
+{
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "pack",
+      "rootUri": "../",
+      "packageUri": "lib/",
+      "languageVersion": "2.7"
+    }
+  ]
+}
\ No newline at end of file
diff --git a/pkg/front_end/test/language_versioning/data/issue42661b/lib/src/part.dart b/pkg/front_end/test/language_versioning/data/issue42661b/lib/src/part.dart
new file mode 100644
index 0000000..835902f
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661b/lib/src/part.dart
@@ -0,0 +1 @@
+part of pack;
diff --git a/pkg/front_end/test/language_versioning/data/issue42661b/main.dart b/pkg/front_end/test/language_versioning/data/issue42661b/main.dart
new file mode 100644
index 0000000..bd8fb96
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661b/main.dart
@@ -0,0 +1,6 @@
+/*library: 
+ languageVersion=2.7,
+ packageUri=package:pack
+*/
+
+import 'web/pack.dart';
diff --git a/pkg/front_end/test/language_versioning/data/issue42661b/web/pack.dart b/pkg/front_end/test/language_versioning/data/issue42661b/web/pack.dart
new file mode 100644
index 0000000..217ed77
--- /dev/null
+++ b/pkg/front_end/test/language_versioning/data/issue42661b/web/pack.dart
@@ -0,0 +1,7 @@
+/*library: 
+ languageVersion=2.7,
+ packageUri=package:pack
+*/
+library pack;
+
+part 'package:pack/src/part.dart';
diff --git a/pkg/front_end/test/lint_suite.dart b/pkg/front_end/test/lint_suite.dart
index 5ae80a7..d047ab7 100644
--- a/pkg/front_end/test/lint_suite.dart
+++ b/pkg/front_end/test/lint_suite.dart
@@ -233,6 +233,7 @@
   }
 
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
diff --git a/pkg/front_end/test/parser_test_listener.dart b/pkg/front_end/test/parser_test_listener.dart
index e0aa818..620cdef 100644
--- a/pkg/front_end/test/parser_test_listener.dart
+++ b/pkg/front_end/test/parser_test_listener.dart
@@ -520,6 +520,7 @@
   }
 
   void endClassFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -529,6 +530,7 @@
       Token beginToken,
       Token endToken) {
     indent--;
+    seen(abstractToken);
     seen(staticToken);
     seen(covariantToken);
     seen(lateToken);
@@ -546,6 +548,7 @@
   }
 
   void endMixinFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -555,6 +558,7 @@
       Token beginToken,
       Token endToken) {
     indent--;
+    seen(abstractToken);
     seen(staticToken);
     seen(covariantToken);
     seen(lateToken);
@@ -572,6 +576,7 @@
   }
 
   void endExtensionFields(
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
diff --git a/pkg/front_end/test/parser_test_parser.dart b/pkg/front_end/test/parser_test_parser.dart
index a0499fb..8033a37 100644
--- a/pkg/front_end/test/parser_test_parser.dart
+++ b/pkg/front_end/test/parser_test_parser.dart
@@ -694,6 +694,7 @@
 
   Token parseFields(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -707,6 +708,7 @@
       bool nameIsRecovered) {
     doPrint('parseFields('
         '$beforeStart, '
+        '$abstractToken, '
         '$externalToken, '
         '$staticToken, '
         '$covariantToken, '
@@ -721,6 +723,7 @@
     indent++;
     var result = super.parseFields(
         beforeStart,
+        abstractToken,
         externalToken,
         staticToken,
         covariantToken,
@@ -771,6 +774,7 @@
       Token token,
       Token name,
       Token lateToken,
+      Token abstractToken,
       Token externalToken,
       Token varFinalOrConst,
       DeclarationKind kind,
@@ -779,12 +783,21 @@
         '$token, '
         '$name, '
         '$lateToken, '
+        '$abstractToken, '
+        '$externalToken, '
         '$varFinalOrConst, '
         '$kind, '
         '$enclosingDeclarationName)');
     indent++;
-    var result = super.parseFieldInitializerOpt(token, name, lateToken,
-        externalToken, varFinalOrConst, kind, enclosingDeclarationName);
+    var result = super.parseFieldInitializerOpt(
+        token,
+        name,
+        lateToken,
+        abstractToken,
+        externalToken,
+        varFinalOrConst,
+        kind,
+        enclosingDeclarationName);
     indent--;
     return result;
   }
@@ -1004,6 +1017,7 @@
 
   Token parseMethod(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1018,6 +1032,7 @@
       bool nameIsRecovered) {
     doPrint('parseMethod('
         '$beforeStart, '
+        '$abstractToken, '
         '$externalToken, '
         '$staticToken, '
         '$covariantToken, '
@@ -1033,6 +1048,7 @@
     indent++;
     var result = super.parseMethod(
         beforeStart,
+        abstractToken,
         externalToken,
         staticToken,
         covariantToken,
@@ -1948,6 +1964,7 @@
 
   Token parseInvalidOperatorDeclaration(
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1958,6 +1975,7 @@
       String enclosingDeclarationName) {
     doPrint('parseInvalidOperatorDeclaration('
         '$beforeStart, '
+        '$abstractToken, '
         '$externalToken, '
         '$staticToken, '
         '$covariantToken, '
@@ -1969,6 +1987,7 @@
     indent++;
     var result = super.parseInvalidOperatorDeclaration(
         beforeStart,
+        abstractToken,
         externalToken,
         staticToken,
         covariantToken,
@@ -1984,6 +2003,7 @@
   Token recoverFromInvalidMember(
       Token token,
       Token beforeStart,
+      Token abstractToken,
       Token externalToken,
       Token staticToken,
       Token covariantToken,
@@ -1997,6 +2017,7 @@
     doPrint('recoverFromInvalidMember('
         '$token, '
         '$beforeStart, '
+        '$abstractToken, '
         '$externalToken, '
         '$staticToken, '
         '$covariantToken, '
@@ -2011,6 +2032,7 @@
     var result = super.recoverFromInvalidMember(
         token,
         beforeStart,
+        abstractToken,
         externalToken,
         staticToken,
         covariantToken,
diff --git a/pkg/front_end/test/spell_checking_list_code.txt b/pkg/front_end/test/spell_checking_list_code.txt
index 0dba39a..229417f 100644
--- a/pkg/front_end/test/spell_checking_list_code.txt
+++ b/pkg/front_end/test/spell_checking_list_code.txt
@@ -154,6 +154,7 @@
 cast
 casted
 casts
+ce
 cfe
 ch
 channel
@@ -184,6 +185,7 @@
 class6b
 clazz
 cli
+clil
 clock
 cls
 cn
@@ -404,6 +406,7 @@
 field1a
 field1b
 field2
+fieldformal
 file's
 filenames
 finv
@@ -432,6 +435,7 @@
 frontends
 fs
 fsource
+fue
 fuller
 function's
 fuse
@@ -493,6 +497,7 @@
 i
 i'll
 i2b
+ic
 id
 identifies
 identifying
@@ -577,6 +582,8 @@
 lattice
 layer
 layout
+lc
+ld
 leafp
 len
 lets
@@ -593,6 +600,7 @@
 linebreak
 linter
 lives
+ll
 llub
 lm
 locationd
@@ -622,6 +630,7 @@
 master
 matcher
 mb
+mc
 md
 me
 merely
@@ -679,6 +688,7 @@
 namer
 natively
 nbsp
+nc
 ncs
 ncurses
 nd
@@ -742,6 +752,7 @@
 outputting
 overlap
 overloader
+overlooked
 overshadowed
 overwrite
 overwriting
@@ -1041,6 +1052,7 @@
 substed
 substitutes
 substitutor
+suggests
 sum
 summarizing
 superclasses
@@ -1130,6 +1142,9 @@
 tuple2
 tuple3
 tuple4
+tuple5
+tuple6
+tuple7
 type1
 type2
 typeref
@@ -1210,6 +1225,7 @@
 vb
 vector
 vegorov
+verbosity
 versa
 vice
 violated
diff --git a/pkg/front_end/test/spell_checking_list_common.txt b/pkg/front_end/test/spell_checking_list_common.txt
index 2812378..b7ba245 100644
--- a/pkg/front_end/test/spell_checking_list_common.txt
+++ b/pkg/front_end/test/spell_checking_list_common.txt
@@ -1083,8 +1083,8 @@
 experimentally
 experiments
 expired
-explanation
 explain
+explanation
 explicit
 explicitly
 exponent
@@ -1152,6 +1152,7 @@
 field's
 fieldname
 fields
+fifth
 figure
 file
 filename
@@ -2642,6 +2643,7 @@
 settings
 settled
 setup
+seventh
 several
 severity
 shadow
@@ -2700,6 +2702,7 @@
 sites
 situation
 situations
+sixth
 skip
 skipped
 skipping
diff --git a/pkg/front_end/test/spell_checking_list_messages.txt b/pkg/front_end/test/spell_checking_list_messages.txt
index 0a521d2..3b3a9ce 100644
--- a/pkg/front_end/test/spell_checking_list_messages.txt
+++ b/pkg/front_end/test/spell_checking_list_messages.txt
@@ -45,6 +45,7 @@
 o
 opt
 opts
+outdated
 part(s)
 patch(es)
 pubspec.yaml
diff --git a/pkg/front_end/test/spell_checking_list_tests.txt b/pkg/front_end/test/spell_checking_list_tests.txt
index e62b6c1..52494a6 100644
--- a/pkg/front_end/test/spell_checking_list_tests.txt
+++ b/pkg/front_end/test/spell_checking_list_tests.txt
@@ -56,6 +56,7 @@
 besides
 beta
 bigger
+bkonyi
 blah
 blindly
 blocked
@@ -118,6 +119,7 @@
 cov
 crashes
 cumulative
+cx
 dacoharkes
 dadd
 daemon
@@ -128,6 +130,7 @@
 dashes
 day
 db
+dds
 debugger
 decrease
 decrements
@@ -160,6 +163,7 @@
 dispatcher
 dispose
 dist
+divergent
 doctype
 doesnt
 dog
@@ -204,6 +208,7 @@
 falling
 favors
 fetched
+fi
 fibonacci
 filesystem
 filler
@@ -241,6 +246,7 @@
 fulfill
 func
 futures
+fx
 gallery
 gamma
 gave
@@ -409,6 +415,7 @@
 oracle
 outbound
 overlay
+pack
 party
 pause
 paused
@@ -497,6 +504,7 @@
 smoke
 somehow
 spans
+spawn
 spell
 spellcheck
 spelled
diff --git a/pkg/front_end/test/utils/kernel_chain.dart b/pkg/front_end/test/utils/kernel_chain.dart
index bf5e04b..9e0988a 100644
--- a/pkg/front_end/test/utils/kernel_chain.dart
+++ b/pkg/front_end/test/utils/kernel_chain.dart
@@ -362,6 +362,7 @@
           });
     return await CompilerContext.runWithOptions(options,
         (compilerContext) async {
+      component.computeCanonicalNames();
       compilerContext.uriToSource.addAll(component.uriToSource);
       TextSerializationVerifier verifier =
           new TextSerializationVerifier(root: component.root);
diff --git a/pkg/front_end/testcases/expression/const_usage.expression.yaml b/pkg/front_end/testcases/expression/const_usage.expression.yaml
new file mode 100644
index 0000000..b017b26
--- /dev/null
+++ b/pkg/front_end/testcases/expression/const_usage.expression.yaml
@@ -0,0 +1,9 @@
+# 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.
+
+entry_point: "main.dart"
+definitions: []
+position: "main.dart"
+expression: |
+  const42.x
diff --git a/pkg/front_end/testcases/expression/const_usage.expression.yaml.expect b/pkg/front_end/testcases/expression/const_usage.expression.yaml.expect
new file mode 100644
index 0000000..1d2b890
--- /dev/null
+++ b/pkg/front_end/testcases/expression/const_usage.expression.yaml.expect
@@ -0,0 +1,8 @@
+Errors: {
+}
+method /* from org-dartlang-debug:synthetic_debug_expression */ debugExpr() → dynamic
+  return (#C2).{main::ConstClass::x};
+constants  {
+  #C1 = 42
+  #C2 = main::ConstClass {x:#C1}
+}
diff --git a/pkg/front_end/testcases/expression/const_usage_class.expression.yaml b/pkg/front_end/testcases/expression/const_usage_class.expression.yaml
new file mode 100644
index 0000000..9425ebb
--- /dev/null
+++ b/pkg/front_end/testcases/expression/const_usage_class.expression.yaml
@@ -0,0 +1,9 @@
+# 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.
+
+entry_point: "main.dart"
+definitions: []
+position: "main.dart#ConstClass"
+expression: |
+  classConst42.x
diff --git a/pkg/front_end/testcases/expression/const_usage_class.expression.yaml.expect b/pkg/front_end/testcases/expression/const_usage_class.expression.yaml.expect
new file mode 100644
index 0000000..1d2b890
--- /dev/null
+++ b/pkg/front_end/testcases/expression/const_usage_class.expression.yaml.expect
@@ -0,0 +1,8 @@
+Errors: {
+}
+method /* from org-dartlang-debug:synthetic_debug_expression */ debugExpr() → dynamic
+  return (#C2).{main::ConstClass::x};
+constants  {
+  #C1 = 42
+  #C2 = main::ConstClass {x:#C1}
+}
diff --git a/pkg/front_end/testcases/expression/lib_ctor.expression.yaml.expect b/pkg/front_end/testcases/expression/lib_ctor.expression.yaml.expect
index dc61171..45805ec 100644
--- a/pkg/front_end/testcases/expression/lib_ctor.expression.yaml.expect
+++ b/pkg/front_end/testcases/expression/lib_ctor.expression.yaml.expect
@@ -3,5 +3,9 @@
 method /* from org-dartlang-debug:synthetic_debug_expression */ debugExpr() → dynamic
   return () → dart.core::Null? {
     new main::A::•<dynamic>();
-    const main::A::•<dynamic>();
+    #C2;
   };
+constants  {
+  #C1 = 0
+  #C2 = main::A<dynamic> {_priv:#C1}
+}
diff --git a/pkg/front_end/testcases/expression/main.dart b/pkg/front_end/testcases/expression/main.dart
index bdf80a9..e38cbea 100644
--- a/pkg/front_end/testcases/expression/main.dart
+++ b/pkg/front_end/testcases/expression/main.dart
@@ -14,6 +14,14 @@
 int globalVar = 6;
 int _globalPrivate = 7;
 
+const ConstClass const42 = ConstClass(42);
+
+class ConstClass {
+  static const ConstClass classConst42 = ConstClass(42);
+  final int x;
+  const ConstClass(this.x);
+}
+
 class A<T> {
   const A();
   static int doit(int x) => x + 1;
diff --git a/pkg/front_end/testcases/extensions/extension_setter.dart.strong.expect b/pkg/front_end/testcases/extensions/extension_setter.dart.strong.expect
index 686d8d2..8e500e2 100644
--- a/pkg/front_end/testcases/extensions/extension_setter.dart.strong.expect
+++ b/pkg/front_end/testcases/extensions/extension_setter.dart.strong.expect
@@ -91,7 +91,7 @@
   self::expect(2, #this.{self::Class::field});
   self::expect(3, let final core::int* #t5 = 3 in let final void #t6 = self::Extension|set#setterWithReturn(#this, #t5) in #t5);
   self::expect(3, #this.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t7 = 4.{core::int::unary-}() in let final void #t8 = self::Extension|set#setterWithReturn(#this, #t7) in #t7);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t7 = 4.{core::int::unary-}() in let final void #t8 = self::Extension|set#setterWithReturn(#this, #t7) in #t7);
   self::expect(4, #this.{self::Class::field});
   self::Extension|set#setterWithClosure(#this, 1);
   self::expect(1, #this.{self::Class::field});
@@ -99,7 +99,7 @@
   self::expect(2, #this.{self::Class::field});
   self::expect(3, let final core::int* #t9 = 3 in let final void #t10 = self::Extension|set#setterWithClosure(#this, #t9) in #t9);
   self::expect(3, #this.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t11 = 4.{core::int::unary-}() in let final void #t12 = self::Extension|set#setterWithClosure(#this, #t11) in #t11);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t11 = 4.{core::int::unary-}() in let final void #t12 = self::Extension|set#setterWithClosure(#this, #t11) in #t11);
   self::expect(4, #this.{self::Class::field});
 }
 static method Extension|get#testInternal(final self::Class* #this) → () →* dynamic
@@ -128,7 +128,7 @@
   self::expect(2, c.{self::Class::field});
   self::expect(3, let final core::int* #t23 = 3 in let final void #t24 = self::Extension|set#setterWithReturn(c, #t23) in #t23);
   self::expect(3, c.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t25 = 4.{core::int::unary-}() in let final void #t26 = self::Extension|set#setterWithReturn(c, #t25) in #t25);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t25 = 4.{core::int::unary-}() in let final void #t26 = self::Extension|set#setterWithReturn(c, #t25) in #t25);
   self::expect(4, c.{self::Class::field});
   self::Extension|set#setterWithReturn(c, 5);
   self::expect(5, c.{self::Class::field});
@@ -136,7 +136,7 @@
   self::expect(6, c.{self::Class::field});
   self::expect(7, let final self::Class* #t27 = c in let final core::int* #t28 = 7 in let final void #t29 = self::Extension|set#setterWithReturn(#t27, #t28) in #t28);
   self::expect(7, c.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t30 = c in let final core::int #t31 = 8.{core::int::unary-}() in let final void #t32 = self::Extension|set#setterWithReturn(#t30, #t31) in #t31);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t30 = c in let final core::int* #t31 = 8.{core::int::unary-}() in let final void #t32 = self::Extension|set#setterWithReturn(#t30, #t31) in #t31);
   self::expect(8, c.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 1);
   self::expect(1, c.{self::Class::field});
@@ -144,7 +144,7 @@
   self::expect(2, c.{self::Class::field});
   self::expect(3, let final core::int* #t33 = 3 in let final void #t34 = self::Extension|set#setterWithClosure(c, #t33) in #t33);
   self::expect(3, c.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t35 = 4.{core::int::unary-}() in let final void #t36 = self::Extension|set#setterWithClosure(c, #t35) in #t35);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t35 = 4.{core::int::unary-}() in let final void #t36 = self::Extension|set#setterWithClosure(c, #t35) in #t35);
   self::expect(4, c.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 5);
   self::expect(5, c.{self::Class::field});
@@ -152,7 +152,7 @@
   self::expect(6, c.{self::Class::field});
   self::expect(7, let final self::Class* #t37 = c in let final core::int* #t38 = 7 in let final void #t39 = self::Extension|set#setterWithClosure(#t37, #t38) in #t38);
   self::expect(7, c.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t40 = c in let final core::int #t41 = 8.{core::int::unary-}() in let final void #t42 = self::Extension|set#setterWithClosure(#t40, #t41) in #t41);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t40 = c in let final core::int* #t41 = 8.{core::int::unary-}() in let final void #t42 = self::Extension|set#setterWithClosure(#t40, #t41) in #t41);
   self::expect(8, c.{self::Class::field});
   self::Extension|set#simpleSetter(c, 0);
   self::expect(0, let final self::Class* #t43 = c in #t43.{self::Class::==}(null) ?{core::int*} null : #t43.{self::Class::field});
@@ -174,7 +174,7 @@
   self::expect(2, let final self::Class* #t64 = c in #t64.{self::Class::==}(null) ?{core::int*} null : #t64.{self::Class::field});
   self::expect(3, let final self::Class* #t65 = c in #t65.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t66 = 3 in let final void #t67 = self::Extension|set#setterWithReturn(#t65, #t66) in #t66);
   self::expect(3, let final self::Class* #t68 = c in #t68.{self::Class::==}(null) ?{core::int*} null : #t68.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final self::Class* #t69 = c in #t69.{self::Class::==}(null) ?{core::int*} null : let final core::int #t70 = 4.{core::int::unary-}() in let final void #t71 = self::Extension|set#setterWithReturn(#t69, #t70) in #t70);
+  self::expect(4.{core::int::unary-}(), let final self::Class* #t69 = c in #t69.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t70 = 4.{core::int::unary-}() in let final void #t71 = self::Extension|set#setterWithReturn(#t69, #t70) in #t70);
   self::expect(4, let final self::Class* #t72 = c in #t72.{self::Class::==}(null) ?{core::int*} null : #t72.{self::Class::field});
   self::Extension|set#setterWithReturn(c, 5);
   self::expect(5, let final self::Class* #t73 = c in #t73.{self::Class::==}(null) ?{core::int*} null : #t73.{self::Class::field});
@@ -182,7 +182,7 @@
   self::expect(6, let final self::Class* #t74 = c in #t74.{self::Class::==}(null) ?{core::int*} null : #t74.{self::Class::field});
   self::expect(7, let final self::Class* #t75 = c in let final core::int* #t76 = 7 in let final void #t77 = self::Extension|set#setterWithReturn(#t75, #t76) in #t76);
   self::expect(7, let final self::Class* #t78 = c in #t78.{self::Class::==}(null) ?{core::int*} null : #t78.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t79 = c in let final core::int #t80 = 8.{core::int::unary-}() in let final void #t81 = self::Extension|set#setterWithReturn(#t79, #t80) in #t80);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t79 = c in let final core::int* #t80 = 8.{core::int::unary-}() in let final void #t81 = self::Extension|set#setterWithReturn(#t79, #t80) in #t80);
   self::expect(8, let final self::Class* #t82 = c in #t82.{self::Class::==}(null) ?{core::int*} null : #t82.{self::Class::field});
   let final self::Class* #t83 = c in #t83.{self::Class::==}(null) ?{core::int*} null : self::Extension|set#setterWithClosure(#t83, 1);
   self::expect(1, let final self::Class* #t84 = c in #t84.{self::Class::==}(null) ?{core::int*} null : #t84.{self::Class::field});
@@ -190,7 +190,7 @@
   self::expect(2, let final self::Class* #t86 = c in #t86.{self::Class::==}(null) ?{core::int*} null : #t86.{self::Class::field});
   self::expect(3, let final self::Class* #t87 = c in #t87.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t88 = 3 in let final void #t89 = self::Extension|set#setterWithClosure(#t87, #t88) in #t88);
   self::expect(3, let final self::Class* #t90 = c in #t90.{self::Class::==}(null) ?{core::int*} null : #t90.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final self::Class* #t91 = c in #t91.{self::Class::==}(null) ?{core::int*} null : let final core::int #t92 = 4.{core::int::unary-}() in let final void #t93 = self::Extension|set#setterWithClosure(#t91, #t92) in #t92);
+  self::expect(4.{core::int::unary-}(), let final self::Class* #t91 = c in #t91.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t92 = 4.{core::int::unary-}() in let final void #t93 = self::Extension|set#setterWithClosure(#t91, #t92) in #t92);
   self::expect(4, let final self::Class* #t94 = c in #t94.{self::Class::==}(null) ?{core::int*} null : #t94.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 5);
   self::expect(5, let final self::Class* #t95 = c in #t95.{self::Class::==}(null) ?{core::int*} null : #t95.{self::Class::field});
@@ -198,7 +198,7 @@
   self::expect(6, let final self::Class* #t96 = c in #t96.{self::Class::==}(null) ?{core::int*} null : #t96.{self::Class::field});
   self::expect(7, let final self::Class* #t97 = c in let final core::int* #t98 = 7 in let final void #t99 = self::Extension|set#setterWithClosure(#t97, #t98) in #t98);
   self::expect(7, let final self::Class* #t100 = c in #t100.{self::Class::==}(null) ?{core::int*} null : #t100.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t101 = c in let final core::int #t102 = 8.{core::int::unary-}() in let final void #t103 = self::Extension|set#setterWithClosure(#t101, #t102) in #t102);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t101 = c in let final core::int* #t102 = 8.{core::int::unary-}() in let final void #t103 = self::Extension|set#setterWithClosure(#t101, #t102) in #t102);
   self::expect(8, let final self::Class* #t104 = c in #t104.{self::Class::==}(null) ?{core::int*} null : #t104.{self::Class::field});
   c.{self::Class::field} = null;
   let final self::Class* #t105 = c in self::Extension|get#simpleSetter(#t105).{core::num::==}(null) ?{core::int*} self::Extension|set#simpleSetter(#t105, 1) : null;
diff --git a/pkg/front_end/testcases/extensions/extension_setter.dart.strong.transformed.expect b/pkg/front_end/testcases/extensions/extension_setter.dart.strong.transformed.expect
index 686d8d2..8e500e2 100644
--- a/pkg/front_end/testcases/extensions/extension_setter.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/extensions/extension_setter.dart.strong.transformed.expect
@@ -91,7 +91,7 @@
   self::expect(2, #this.{self::Class::field});
   self::expect(3, let final core::int* #t5 = 3 in let final void #t6 = self::Extension|set#setterWithReturn(#this, #t5) in #t5);
   self::expect(3, #this.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t7 = 4.{core::int::unary-}() in let final void #t8 = self::Extension|set#setterWithReturn(#this, #t7) in #t7);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t7 = 4.{core::int::unary-}() in let final void #t8 = self::Extension|set#setterWithReturn(#this, #t7) in #t7);
   self::expect(4, #this.{self::Class::field});
   self::Extension|set#setterWithClosure(#this, 1);
   self::expect(1, #this.{self::Class::field});
@@ -99,7 +99,7 @@
   self::expect(2, #this.{self::Class::field});
   self::expect(3, let final core::int* #t9 = 3 in let final void #t10 = self::Extension|set#setterWithClosure(#this, #t9) in #t9);
   self::expect(3, #this.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t11 = 4.{core::int::unary-}() in let final void #t12 = self::Extension|set#setterWithClosure(#this, #t11) in #t11);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t11 = 4.{core::int::unary-}() in let final void #t12 = self::Extension|set#setterWithClosure(#this, #t11) in #t11);
   self::expect(4, #this.{self::Class::field});
 }
 static method Extension|get#testInternal(final self::Class* #this) → () →* dynamic
@@ -128,7 +128,7 @@
   self::expect(2, c.{self::Class::field});
   self::expect(3, let final core::int* #t23 = 3 in let final void #t24 = self::Extension|set#setterWithReturn(c, #t23) in #t23);
   self::expect(3, c.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t25 = 4.{core::int::unary-}() in let final void #t26 = self::Extension|set#setterWithReturn(c, #t25) in #t25);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t25 = 4.{core::int::unary-}() in let final void #t26 = self::Extension|set#setterWithReturn(c, #t25) in #t25);
   self::expect(4, c.{self::Class::field});
   self::Extension|set#setterWithReturn(c, 5);
   self::expect(5, c.{self::Class::field});
@@ -136,7 +136,7 @@
   self::expect(6, c.{self::Class::field});
   self::expect(7, let final self::Class* #t27 = c in let final core::int* #t28 = 7 in let final void #t29 = self::Extension|set#setterWithReturn(#t27, #t28) in #t28);
   self::expect(7, c.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t30 = c in let final core::int #t31 = 8.{core::int::unary-}() in let final void #t32 = self::Extension|set#setterWithReturn(#t30, #t31) in #t31);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t30 = c in let final core::int* #t31 = 8.{core::int::unary-}() in let final void #t32 = self::Extension|set#setterWithReturn(#t30, #t31) in #t31);
   self::expect(8, c.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 1);
   self::expect(1, c.{self::Class::field});
@@ -144,7 +144,7 @@
   self::expect(2, c.{self::Class::field});
   self::expect(3, let final core::int* #t33 = 3 in let final void #t34 = self::Extension|set#setterWithClosure(c, #t33) in #t33);
   self::expect(3, c.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final core::int #t35 = 4.{core::int::unary-}() in let final void #t36 = self::Extension|set#setterWithClosure(c, #t35) in #t35);
+  self::expect(4.{core::int::unary-}(), let final core::int* #t35 = 4.{core::int::unary-}() in let final void #t36 = self::Extension|set#setterWithClosure(c, #t35) in #t35);
   self::expect(4, c.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 5);
   self::expect(5, c.{self::Class::field});
@@ -152,7 +152,7 @@
   self::expect(6, c.{self::Class::field});
   self::expect(7, let final self::Class* #t37 = c in let final core::int* #t38 = 7 in let final void #t39 = self::Extension|set#setterWithClosure(#t37, #t38) in #t38);
   self::expect(7, c.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t40 = c in let final core::int #t41 = 8.{core::int::unary-}() in let final void #t42 = self::Extension|set#setterWithClosure(#t40, #t41) in #t41);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t40 = c in let final core::int* #t41 = 8.{core::int::unary-}() in let final void #t42 = self::Extension|set#setterWithClosure(#t40, #t41) in #t41);
   self::expect(8, c.{self::Class::field});
   self::Extension|set#simpleSetter(c, 0);
   self::expect(0, let final self::Class* #t43 = c in #t43.{self::Class::==}(null) ?{core::int*} null : #t43.{self::Class::field});
@@ -174,7 +174,7 @@
   self::expect(2, let final self::Class* #t64 = c in #t64.{self::Class::==}(null) ?{core::int*} null : #t64.{self::Class::field});
   self::expect(3, let final self::Class* #t65 = c in #t65.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t66 = 3 in let final void #t67 = self::Extension|set#setterWithReturn(#t65, #t66) in #t66);
   self::expect(3, let final self::Class* #t68 = c in #t68.{self::Class::==}(null) ?{core::int*} null : #t68.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final self::Class* #t69 = c in #t69.{self::Class::==}(null) ?{core::int*} null : let final core::int #t70 = 4.{core::int::unary-}() in let final void #t71 = self::Extension|set#setterWithReturn(#t69, #t70) in #t70);
+  self::expect(4.{core::int::unary-}(), let final self::Class* #t69 = c in #t69.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t70 = 4.{core::int::unary-}() in let final void #t71 = self::Extension|set#setterWithReturn(#t69, #t70) in #t70);
   self::expect(4, let final self::Class* #t72 = c in #t72.{self::Class::==}(null) ?{core::int*} null : #t72.{self::Class::field});
   self::Extension|set#setterWithReturn(c, 5);
   self::expect(5, let final self::Class* #t73 = c in #t73.{self::Class::==}(null) ?{core::int*} null : #t73.{self::Class::field});
@@ -182,7 +182,7 @@
   self::expect(6, let final self::Class* #t74 = c in #t74.{self::Class::==}(null) ?{core::int*} null : #t74.{self::Class::field});
   self::expect(7, let final self::Class* #t75 = c in let final core::int* #t76 = 7 in let final void #t77 = self::Extension|set#setterWithReturn(#t75, #t76) in #t76);
   self::expect(7, let final self::Class* #t78 = c in #t78.{self::Class::==}(null) ?{core::int*} null : #t78.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t79 = c in let final core::int #t80 = 8.{core::int::unary-}() in let final void #t81 = self::Extension|set#setterWithReturn(#t79, #t80) in #t80);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t79 = c in let final core::int* #t80 = 8.{core::int::unary-}() in let final void #t81 = self::Extension|set#setterWithReturn(#t79, #t80) in #t80);
   self::expect(8, let final self::Class* #t82 = c in #t82.{self::Class::==}(null) ?{core::int*} null : #t82.{self::Class::field});
   let final self::Class* #t83 = c in #t83.{self::Class::==}(null) ?{core::int*} null : self::Extension|set#setterWithClosure(#t83, 1);
   self::expect(1, let final self::Class* #t84 = c in #t84.{self::Class::==}(null) ?{core::int*} null : #t84.{self::Class::field});
@@ -190,7 +190,7 @@
   self::expect(2, let final self::Class* #t86 = c in #t86.{self::Class::==}(null) ?{core::int*} null : #t86.{self::Class::field});
   self::expect(3, let final self::Class* #t87 = c in #t87.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t88 = 3 in let final void #t89 = self::Extension|set#setterWithClosure(#t87, #t88) in #t88);
   self::expect(3, let final self::Class* #t90 = c in #t90.{self::Class::==}(null) ?{core::int*} null : #t90.{self::Class::field});
-  self::expect(4.{core::int::unary-}(), let final self::Class* #t91 = c in #t91.{self::Class::==}(null) ?{core::int*} null : let final core::int #t92 = 4.{core::int::unary-}() in let final void #t93 = self::Extension|set#setterWithClosure(#t91, #t92) in #t92);
+  self::expect(4.{core::int::unary-}(), let final self::Class* #t91 = c in #t91.{self::Class::==}(null) ?{core::int*} null : let final core::int* #t92 = 4.{core::int::unary-}() in let final void #t93 = self::Extension|set#setterWithClosure(#t91, #t92) in #t92);
   self::expect(4, let final self::Class* #t94 = c in #t94.{self::Class::==}(null) ?{core::int*} null : #t94.{self::Class::field});
   self::Extension|set#setterWithClosure(c, 5);
   self::expect(5, let final self::Class* #t95 = c in #t95.{self::Class::==}(null) ?{core::int*} null : #t95.{self::Class::field});
@@ -198,7 +198,7 @@
   self::expect(6, let final self::Class* #t96 = c in #t96.{self::Class::==}(null) ?{core::int*} null : #t96.{self::Class::field});
   self::expect(7, let final self::Class* #t97 = c in let final core::int* #t98 = 7 in let final void #t99 = self::Extension|set#setterWithClosure(#t97, #t98) in #t98);
   self::expect(7, let final self::Class* #t100 = c in #t100.{self::Class::==}(null) ?{core::int*} null : #t100.{self::Class::field});
-  self::expect(8.{core::int::unary-}(), let final self::Class* #t101 = c in let final core::int #t102 = 8.{core::int::unary-}() in let final void #t103 = self::Extension|set#setterWithClosure(#t101, #t102) in #t102);
+  self::expect(8.{core::int::unary-}(), let final self::Class* #t101 = c in let final core::int* #t102 = 8.{core::int::unary-}() in let final void #t103 = self::Extension|set#setterWithClosure(#t101, #t102) in #t102);
   self::expect(8, let final self::Class* #t104 = c in #t104.{self::Class::==}(null) ?{core::int*} null : #t104.{self::Class::field});
   c.{self::Class::field} = null;
   let final self::Class* #t105 = c in self::Extension|get#simpleSetter(#t105).{core::num::==}(null) ?{core::int*} self::Extension|set#simpleSetter(#t105, 1) : null;
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart b/pkg/front_end/testcases/general/abstract_operator_override.dart
new file mode 100644
index 0000000..89d5f93
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart
@@ -0,0 +1,24 @@
+// 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.
+
+class A {
+  A operator +(B b) => new A();
+  A operator -() => new A();
+  A operator [](B b) => new A();
+  void operator []=(B b1, B b2) {}
+}
+
+class B extends A {
+  A operator +(A a);
+  B operator -();
+  A operator [](A a);
+  void operator []=(A a, B b);
+}
+
+class C extends A {
+  B operator [](B b);
+  void operator []=(B b, A a);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart.outline.expect b/pkg/front_end/testcases/general/abstract_operator_override.dart.outline.expect
new file mode 100644
index 0000000..954d77d
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart.outline.expect
@@ -0,0 +1,123 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '+' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:6:18: Context: The parameter 'b' of the method 'A.+' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.+'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator +(B b) => new A();
+//                  ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:13:14: Context: This is the overridden method ('+').
+//   A operator +(A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of 'unary-' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:7:14: Context: The return type of the method 'A.unary-' is 'A', which does not match the return type, 'B', of the overridden method, 'B.unary-'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator -() => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:14:14: Context: This is the overridden method ('unary-').
+//   B operator -();
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:19: Context: The parameter 'b' of the method 'A.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator [](B b) => new A();
+//                   ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:15:14: Context: This is the overridden method ('[]').
+//   A operator [](A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]=' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:23: Context: The parameter 'b1' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:16:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a, B b);
+//                 ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:14: Context: The return type of the method 'A.[]' is 'A', which does not match the return type, 'B', of the overridden method, 'C.[]'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator [](B b) => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:20:14: Context: This is the overridden method ('[]').
+//   B operator [](B b);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]=' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:29: Context: The parameter 'b2' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'C.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                             ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:21:17: Context: This is the overridden method ('[]=').
+//   void operator []=(B b, A a);
+//                 ^
+//
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A*
+    ;
+  operator +(self::B* b) → self::A*
+    ;
+  operator unary-() → self::A*
+    ;
+  operator [](self::B* b) → self::A*
+    ;
+  operator []=(self::B* b1, self::B* b2) → void
+    ;
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+class B extends self::A {
+  synthetic constructor •() → self::B*
+    ;
+  abstract operator +(self::A* a) → self::A*;
+  abstract operator unary-() → self::B*;
+  abstract operator [](self::A* a) → self::A*;
+  abstract operator []=(self::A* a, self::B* b) → void;
+}
+class C extends self::A {
+  synthetic constructor •() → self::C*
+    ;
+  abstract operator [](self::B* b) → self::B*;
+  abstract operator []=(self::B* b, self::A* a) → void;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.expect b/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.expect
new file mode 100644
index 0000000..7fc1b8e
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.expect
@@ -0,0 +1,124 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '+' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:6:18: Context: The parameter 'b' of the method 'A.+' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.+'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator +(B b) => new A();
+//                  ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:13:14: Context: This is the overridden method ('+').
+//   A operator +(A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of 'unary-' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:7:14: Context: The return type of the method 'A.unary-' is 'A', which does not match the return type, 'B', of the overridden method, 'B.unary-'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator -() => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:14:14: Context: This is the overridden method ('unary-').
+//   B operator -();
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:19: Context: The parameter 'b' of the method 'A.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator [](B b) => new A();
+//                   ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:15:14: Context: This is the overridden method ('[]').
+//   A operator [](A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]=' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:23: Context: The parameter 'b1' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:16:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a, B b);
+//                 ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:14: Context: The return type of the method 'A.[]' is 'A', which does not match the return type, 'B', of the overridden method, 'C.[]'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator [](B b) => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:20:14: Context: This is the overridden method ('[]').
+//   B operator [](B b);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]=' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:29: Context: The parameter 'b2' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'C.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                             ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:21:17: Context: This is the overridden method ('[]=').
+//   void operator []=(B b, A a);
+//                 ^
+//
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A*
+    : super core::Object::•()
+    ;
+  operator +(self::B* b) → self::A*
+    return new self::A::•();
+  operator unary-() → self::A*
+    return new self::A::•();
+  operator [](self::B* b) → self::A*
+    return new self::A::•();
+  operator []=(self::B* b1, self::B* b2) → void {}
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+class B extends self::A {
+  synthetic constructor •() → self::B*
+    : super self::A::•()
+    ;
+  abstract operator +(self::A* a) → self::A*;
+  abstract operator unary-() → self::B*;
+  abstract operator [](self::A* a) → self::A*;
+  abstract operator []=(self::A* a, self::B* b) → void;
+}
+class C extends self::A {
+  synthetic constructor •() → self::C*
+    : super self::A::•()
+    ;
+  abstract operator [](self::B* b) → self::B*;
+  abstract operator []=(self::B* b, self::A* a) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.transformed.expect b/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.transformed.expect
new file mode 100644
index 0000000..7fc1b8e
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart.strong.transformed.expect
@@ -0,0 +1,124 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '+' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:6:18: Context: The parameter 'b' of the method 'A.+' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.+'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator +(B b) => new A();
+//                  ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:13:14: Context: This is the overridden method ('+').
+//   A operator +(A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of 'unary-' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:7:14: Context: The return type of the method 'A.unary-' is 'A', which does not match the return type, 'B', of the overridden method, 'B.unary-'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator -() => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:14:14: Context: This is the overridden method ('unary-').
+//   B operator -();
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:19: Context: The parameter 'b' of the method 'A.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator [](B b) => new A();
+//                   ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:15:14: Context: This is the overridden method ('[]').
+//   A operator [](A a);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:12:7: Error: The implementation of '[]=' in the non-abstract class 'B' does not conform to its interface.
+// class B extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:23: Context: The parameter 'b1' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'B.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:16:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a, B b);
+//                 ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:8:14: Context: The return type of the method 'A.[]' is 'A', which does not match the return type, 'B', of the overridden method, 'C.[]'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator [](B b) => new A();
+//              ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:20:14: Context: This is the overridden method ('[]').
+//   B operator [](B b);
+//              ^
+//
+// pkg/front_end/testcases/general/abstract_operator_override.dart:19:7: Error: The implementation of '[]=' in the non-abstract class 'C' does not conform to its interface.
+// class C extends A {
+//       ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:9:29: Context: The parameter 'b2' of the method 'A.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'C.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/abstract_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b1, B b2) {}
+//                             ^
+// pkg/front_end/testcases/general/abstract_operator_override.dart:21:17: Context: This is the overridden method ('[]=').
+//   void operator []=(B b, A a);
+//                 ^
+//
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A*
+    : super core::Object::•()
+    ;
+  operator +(self::B* b) → self::A*
+    return new self::A::•();
+  operator unary-() → self::A*
+    return new self::A::•();
+  operator [](self::B* b) → self::A*
+    return new self::A::•();
+  operator []=(self::B* b1, self::B* b2) → void {}
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+class B extends self::A {
+  synthetic constructor •() → self::B*
+    : super self::A::•()
+    ;
+  abstract operator +(self::A* a) → self::A*;
+  abstract operator unary-() → self::B*;
+  abstract operator [](self::A* a) → self::A*;
+  abstract operator []=(self::A* a, self::B* b) → void;
+}
+class C extends self::A {
+  synthetic constructor •() → self::C*
+    : super self::A::•()
+    ;
+  abstract operator [](self::B* b) → self::B*;
+  abstract operator []=(self::B* b, self::A* a) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline.expect b/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline.expect
new file mode 100644
index 0000000..cbb8adc
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline.expect
@@ -0,0 +1,20 @@
+class A {
+  A operator +(B b) => new A();
+  A operator -() => new A();
+  A operator [](B b) => new A();
+  void operator []=(B b1, B b2) {}
+}
+
+class B extends A {
+  A operator +(A a);
+  B operator -();
+  A operator [](A a);
+  void operator []=(A a, B b);
+}
+
+class C extends A {
+  B operator [](B b);
+  void operator []=(B b, A a);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..a8a7f31
--- /dev/null
+++ b/pkg/front_end/testcases/general/abstract_operator_override.dart.textual_outline_modelled.expect
@@ -0,0 +1,20 @@
+class A {
+  A operator +(B b) => new A();
+  A operator -() => new A();
+  A operator [](B b) => new A();
+  void operator []=(B b1, B b2) {}
+}
+
+class B extends A {
+  A operator +(A a);
+  A operator [](A a);
+  B operator -();
+  void operator []=(A a, B b);
+}
+
+class C extends A {
+  B operator [](B b);
+  void operator []=(B b, A a);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/invalid_operator.dart.outline.expect b/pkg/front_end/testcases/general/invalid_operator.dart.outline.expect
index d4cd135..02fda71 100644
--- a/pkg/front_end/testcases/general/invalid_operator.dart.outline.expect
+++ b/pkg/front_end/testcases/general/invalid_operator.dart.outline.expect
@@ -560,6 +560,42 @@
 //   operator ~<T>() => true;
 //              ^
 //
+// pkg/front_end/testcases/general/invalid_operator.dart:6:12: Error: The method 'Operators1.==' has fewer positional arguments than those of overridden method 'Object.=='.
+//   operator ==() => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:27:12: Error: The method 'Operators2.==' has more required arguments than those of overridden method 'Object.=='.
+//   operator ==(a, b) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:71:12: Error: The method 'Operators4.==' has fewer positional arguments than those of overridden method 'Object.=='.
+//   operator ==({a}) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:137:12: Error: Declared type variables of 'Operators7.==' doesn't match those on overridden method 'Object.=='.
+//   operator ==<T>(a) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:137:12: Error: The return type of the method 'Operators7.==' is 'dynamic', which does not match the return type, 'bool', of the overridden method, 'Object.=='.
+// Change to a subtype of 'bool'.
+//   operator ==<T>(a) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
 import self as self;
 import "dart:core" as core;
 
diff --git a/pkg/front_end/testcases/general/invalid_operator.dart.strong.expect b/pkg/front_end/testcases/general/invalid_operator.dart.strong.expect
index 2dac239..6a1e770 100644
--- a/pkg/front_end/testcases/general/invalid_operator.dart.strong.expect
+++ b/pkg/front_end/testcases/general/invalid_operator.dart.strong.expect
@@ -560,6 +560,42 @@
 //   operator ~<T>() => true;
 //              ^
 //
+// pkg/front_end/testcases/general/invalid_operator.dart:6:12: Error: The method 'Operators1.==' has fewer positional arguments than those of overridden method 'Object.=='.
+//   operator ==() => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:27:12: Error: The method 'Operators2.==' has more required arguments than those of overridden method 'Object.=='.
+//   operator ==(a, b) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:71:12: Error: The method 'Operators4.==' has fewer positional arguments than those of overridden method 'Object.=='.
+//   operator ==({a}) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:137:12: Error: Declared type variables of 'Operators7.==' doesn't match those on overridden method 'Object.=='.
+//   operator ==<T>(a) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator.dart:137:12: Error: The return type of the method 'Operators7.==' is 'dynamic', which does not match the return type, 'bool', of the overridden method, 'Object.=='.
+// Change to a subtype of 'bool'.
+//   operator ==<T>(a) => true;
+//            ^
+// sdk/lib/_internal/vm/lib/object_patch.dart:18:17: Context: This is the overridden method ('==').
+//   bool operator ==(Object other) native "Object_equals";
+//                 ^
+//
 import self as self;
 import "dart:core" as core;
 
diff --git a/pkg/front_end/testcases/general/invalid_operator_override.dart b/pkg/front_end/testcases/general/invalid_operator_override.dart
new file mode 100644
index 0000000..9767d57
--- /dev/null
+++ b/pkg/front_end/testcases/general/invalid_operator_override.dart
@@ -0,0 +1,24 @@
+// 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.
+
+class A {
+  A operator +(A a) => a;
+  B operator -() => new B();
+  B operator [](A a) => new B();
+  void operator []=(A a1, A a2) {}
+}
+
+class B extends A {
+  A operator +(B b) => b;
+  A operator -() => this;
+  B operator [](B b) => b;
+  void operator []=(B b, A a) {}
+}
+
+class C extends A {
+  A operator [](B b) => b;
+  void operator []=(A a, B b) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/invalid_operator_override.dart.outline.expect b/pkg/front_end/testcases/general/invalid_operator_override.dart.outline.expect
new file mode 100644
index 0000000..a34493c
--- /dev/null
+++ b/pkg/front_end/testcases/general/invalid_operator_override.dart.outline.expect
@@ -0,0 +1,121 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:13:18: Error: The parameter 'b' of the method 'B.+' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.+'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator +(B b) => b;
+//                  ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:6:14: Context: This is the overridden method ('+').
+//   A operator +(A a) => a;
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:14:14: Error: The return type of the method 'B.unary-' is 'A', which does not match the return type, 'B', of the overridden method, 'A.unary-'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator -() => this;
+//              ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:7:14: Context: This is the overridden method ('unary-').
+//   B operator -() => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:15:19: Error: The parameter 'b' of the method 'B.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   B operator [](B b) => b;
+//                   ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:16:23: Error: The parameter 'b' of the method 'B.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b, A a) {}
+//                       ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:9:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a1, A a2) {}
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:20:14: Error: The return type of the method 'C.[]' is 'A', which does not match the return type, 'B', of the overridden method, 'A.[]'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator [](B b) => b;
+//              ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:20:19: Error: The parameter 'b' of the method 'C.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator [](B b) => b;
+//                   ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:21:28: Error: The parameter 'b' of the method 'C.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(A a, B b) {}
+//                            ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:9:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a1, A a2) {}
+//                 ^
+//
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A*
+    ;
+  operator +(self::A* a) → self::A*
+    ;
+  operator unary-() → self::B*
+    ;
+  operator [](self::A* a) → self::B*
+    ;
+  operator []=(self::A* a1, self::A* a2) → void
+    ;
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+class B extends self::A {
+  synthetic constructor •() → self::B*
+    ;
+  operator +(self::B* b) → self::A*
+    ;
+  operator unary-() → self::A*
+    ;
+  operator [](self::B* b) → self::B*
+    ;
+  operator []=(self::B* b, self::A* a) → void
+    ;
+}
+class C extends self::A {
+  synthetic constructor •() → self::C*
+    ;
+  operator [](self::B* b) → self::A*
+    ;
+  operator []=(self::A* a, self::B* b) → void
+    ;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/general/invalid_operator_override.dart.strong.expect b/pkg/front_end/testcases/general/invalid_operator_override.dart.strong.expect
new file mode 100644
index 0000000..8ad0fbc
--- /dev/null
+++ b/pkg/front_end/testcases/general/invalid_operator_override.dart.strong.expect
@@ -0,0 +1,120 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:13:18: Error: The parameter 'b' of the method 'B.+' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.+'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator +(B b) => b;
+//                  ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:6:14: Context: This is the overridden method ('+').
+//   A operator +(A a) => a;
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:14:14: Error: The return type of the method 'B.unary-' is 'A', which does not match the return type, 'B', of the overridden method, 'A.unary-'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator -() => this;
+//              ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:7:14: Context: This is the overridden method ('unary-').
+//   B operator -() => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:15:19: Error: The parameter 'b' of the method 'B.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   B operator [](B b) => b;
+//                   ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:16:23: Error: The parameter 'b' of the method 'B.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(B b, A a) {}
+//                       ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:9:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a1, A a2) {}
+//                 ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:20:14: Error: The return type of the method 'C.[]' is 'A', which does not match the return type, 'B', of the overridden method, 'A.[]'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a subtype of 'B'.
+//   A operator [](B b) => b;
+//              ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:20:19: Error: The parameter 'b' of the method 'C.[]' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]'.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   A operator [](B b) => b;
+//                   ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:8:14: Context: This is the overridden method ('[]').
+//   B operator [](A a) => new B();
+//              ^
+//
+// pkg/front_end/testcases/general/invalid_operator_override.dart:21:28: Error: The parameter 'b' of the method 'C.[]=' has type 'B', which does not match the corresponding type, 'A', in the overridden method, 'A.[]='.
+//  - 'B' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/general/invalid_operator_override.dart'.
+// Change to a supertype of 'A', or, for a covariant parameter, a subtype.
+//   void operator []=(A a, B b) {}
+//                            ^
+// pkg/front_end/testcases/general/invalid_operator_override.dart:9:17: Context: This is the overridden method ('[]=').
+//   void operator []=(A a1, A a2) {}
+//                 ^
+//
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A*
+    : super core::Object::•()
+    ;
+  operator +(self::A* a) → self::A*
+    return a;
+  operator unary-() → self::B*
+    return new self::B::•();
+  operator [](self::A* a) → self::B*
+    return new self::B::•();
+  operator []=(self::A* a1, self::A* a2) → void {}
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+class B extends self::A {
+  synthetic constructor •() → self::B*
+    : super self::A::•()
+    ;
+  operator +(self::B* b) → self::A*
+    return b;
+  operator unary-() → self::A*
+    return this;
+  operator [](self::B* b) → self::B*
+    return b;
+  operator []=(self::B* b, self::A* a) → void {}
+}
+class C extends self::A {
+  synthetic constructor •() → self::C*
+    : super self::A::•()
+    ;
+  operator [](self::B* b) → self::A*
+    return b;
+  operator []=(self::A* a, self::B* b) → void {}
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline.expect b/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline.expect
new file mode 100644
index 0000000..f4a5167
--- /dev/null
+++ b/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline.expect
@@ -0,0 +1,20 @@
+class A {
+  A operator +(A a) => a;
+  B operator -() => new B();
+  B operator [](A a) => new B();
+  void operator []=(A a1, A a2) {}
+}
+
+class B extends A {
+  A operator +(B b) => b;
+  A operator -() => this;
+  B operator [](B b) => b;
+  void operator []=(B b, A a) {}
+}
+
+class C extends A {
+  A operator [](B b) => b;
+  void operator []=(A a, B b) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..f4a5167
--- /dev/null
+++ b/pkg/front_end/testcases/general/invalid_operator_override.dart.textual_outline_modelled.expect
@@ -0,0 +1,20 @@
+class A {
+  A operator +(A a) => a;
+  B operator -() => new B();
+  B operator [](A a) => new B();
+  void operator []=(A a1, A a2) {}
+}
+
+class B extends A {
+  A operator +(B b) => b;
+  A operator -() => this;
+  B operator [](B b) => b;
+  void operator []=(B b, A a) {}
+}
+
+class C extends A {
+  A operator [](B b) => b;
+  void operator []=(A a, B b) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/general/issue42610.dart b/pkg/front_end/testcases/general/issue42610.dart
new file mode 100644
index 0000000..df912e3
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart
@@ -0,0 +1,13 @@
+// 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.
+
+void test() {
+  #final;
+  final x;
+  const y;
+  final int z;
+  const int w;
+}
+
+void main() {}
diff --git a/pkg/front_end/testcases/general/issue42610.dart.outline.expect b/pkg/front_end/testcases/general/issue42610.dart.outline.expect
new file mode 100644
index 0000000..a440da0
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart.outline.expect
@@ -0,0 +1,7 @@
+library;
+import self as self;
+
+static method test() → void
+  ;
+static method main() → void
+  ;
diff --git a/pkg/front_end/testcases/general/issue42610.dart.strong.expect b/pkg/front_end/testcases/general/issue42610.dart.strong.expect
new file mode 100644
index 0000000..77e5fc9
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart.strong.expect
@@ -0,0 +1,40 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected an identifier, but got 'final'.
+//   #final;
+//    ^^^^^
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected ';' after this.
+//   #final;
+//    ^^^^^
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:9: Error: Expected an identifier, but got ';'.
+//   #final;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:7:9: Error: The final variable 'x' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   final x;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:8:9: Error: The const variable 'y' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   const y;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:9:13: Error: The final variable 'z' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   final int z;
+//             ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:10:13: Error: The const variable 'w' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   const int w;
+//             ^
+//
+import self as self;
+
+static method test() → void {}
+static method main() → void {}
diff --git a/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect
new file mode 100644
index 0000000..77e5fc9
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart.strong.transformed.expect
@@ -0,0 +1,40 @@
+library;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected an identifier, but got 'final'.
+//   #final;
+//    ^^^^^
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:4: Error: Expected ';' after this.
+//   #final;
+//    ^^^^^
+//
+// pkg/front_end/testcases/general/issue42610.dart:6:9: Error: Expected an identifier, but got ';'.
+//   #final;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:7:9: Error: The final variable 'x' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   final x;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:8:9: Error: The const variable 'y' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   const y;
+//         ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:9:13: Error: The final variable 'z' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   final int z;
+//             ^
+//
+// pkg/front_end/testcases/general/issue42610.dart:10:13: Error: The const variable 'w' must be initialized.
+// Try adding an initializer ('= expression') to the declaration.
+//   const int w;
+//             ^
+//
+import self as self;
+
+static method test() → void {}
+static method main() → void {}
diff --git a/pkg/front_end/testcases/general/issue42610.dart.textual_outline.expect b/pkg/front_end/testcases/general/issue42610.dart.textual_outline.expect
new file mode 100644
index 0000000..41786bb
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart.textual_outline.expect
@@ -0,0 +1,2 @@
+void test() {}
+void main() {}
diff --git a/pkg/front_end/testcases/general/issue42610.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/general/issue42610.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..0e0980f
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42610.dart.textual_outline_modelled.expect
@@ -0,0 +1,2 @@
+void main() {}
+void test() {}
diff --git a/pkg/front_end/testcases/general/issue42615.dart b/pkg/front_end/testcases/general/issue42615.dart
new file mode 100644
index 0000000..b18b51f
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42615.dart
@@ -0,0 +1,15 @@
+// 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';
+
+class Class<T> {
+  Class({FutureOr<List<T>> Function() a});
+}
+
+dynamic method() => null;
+
+main() {
+  Class(a: () async => method());
+}
diff --git a/pkg/front_end/testcases/general/issue42615.dart.outline.expect b/pkg/front_end/testcases/general/issue42615.dart.outline.expect
new file mode 100644
index 0000000..77a5b08
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42615.dart.outline.expect
@@ -0,0 +1,24 @@
+library;
+import self as self;
+import "dart:core" as core;
+
+import "dart:async";
+
+class Class<T extends core::Object* = dynamic> extends core::Object {
+  constructor •({() →* FutureOr<core::List<self::Class::T*>*>* a}) → self::Class<self::Class::T*>*
+    ;
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+static method method() → dynamic
+  ;
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/general/issue42615.dart.strong.expect b/pkg/front_end/testcases/general/issue42615.dart.strong.expect
new file mode 100644
index 0000000..2f569f8
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42615.dart.strong.expect
@@ -0,0 +1,30 @@
+library;
+import self as self;
+import "dart:core" as core;
+
+import "dart:async";
+
+class Class<T extends core::Object* = dynamic> extends core::Object {
+  constructor •({() →* FutureOr<core::List<self::Class::T*>*>* a = #C1}) → self::Class<self::Class::T*>*
+    : super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+static method method() → dynamic
+  return null;
+static method main() → dynamic {
+  new self::Class::•<dynamic>(a: () → FutureOr<core::List<dynamic>*>* async => self::method() as{TypeError} FutureOr<core::List<dynamic>*>*);
+}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/general/issue42615.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue42615.dart.strong.transformed.expect
new file mode 100644
index 0000000..6057834
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue42615.dart.strong.transformed.expect
@@ -0,0 +1,57 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
+
+class Class<T extends core::Object* = dynamic> extends core::Object {
+  constructor •({() →* FutureOr<core::List<self::Class::T*>*>* a = #C1}) → self::Class<self::Class::T*>*
+    : super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*;
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*;
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*;
+  abstract member-signature operator ==(dynamic other) → core::bool*;
+  abstract member-signature get hashCode() → core::int*;
+  abstract member-signature method toString() → core::String*;
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic;
+  abstract member-signature get runtimeType() → core::Type*;
+}
+static method method() → dynamic
+  return null;
+static method main() → dynamic {
+  new self::Class::•<dynamic>(a: () → FutureOr<core::List<dynamic>*>* /* originally async */ {
+    final asy::_AsyncAwaitCompleter<core::List<dynamic>*>* :async_completer = new asy::_AsyncAwaitCompleter::•<core::List<dynamic>*>();
+    FutureOr<core::List<dynamic>*>* :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 {
+        #L1:
+        {
+          :return_value = self::method() as{TypeError} FutureOr<core::List<dynamic>*>*;
+          break #L1;
+        }
+        asy::_completeOnAsyncReturn(:async_completer, :return_value);
+        return;
+      }
+      on dynamic catch(dynamic exception, core::StackTrace* stack_trace) {
+        :async_completer.{asy::Completer::completeError}(exception, stack_trace);
+      }
+    :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+    :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+    :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+    :async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
+    return :async_completer.{asy::Completer::future};
+  });
+}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml
new file mode 100644
index 0000000..160f076
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml
@@ -0,0 +1,83 @@
+# 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.md file.
+
+type: newworld
+target: DDC
+trackWidgetCreation: true
+worlds:
+  - entry: main.dart
+    experiments: non-nullable
+    sources:
+      main.dart: |
+        import 'foo.dart';
+      foo.dart:
+        import 'package:flutter/src/widgets/framework.dart';
+        import 'package:flutter/src/widgets/widget_inspector.dart';
+
+        class Foo extends Widget {
+          const Foo();
+        }
+      flutter/lib/src/widgets/framework.dart: |
+        abstract class Bar {
+          const Bar();
+        }
+
+        abstract class Widget extends Bar {
+          const Widget();
+        }
+      flutter/lib/src/widgets/widget_inspector.dart: |
+        abstract class _HasCreationLocation {
+          _Location get _location;
+        }
+
+        /// A tuple with file, line, and column number, for displaying human-readable
+        /// file locations.
+        class _Location {
+          const _Location({
+            required this.file,
+            required this.line,
+            required this.column,
+            required this.name,
+            required this.parameterLocations,
+          });
+
+          /// File path of the location.
+          final String file;
+
+          /// 1-based line number.
+          final int line;
+
+          /// 1-based column number.
+          final int column;
+
+          /// Optional name of the parameter or function at this location.
+          final String name;
+
+          /// Optional locations of the parameters of the member at this location.
+          final List<_Location> parameterLocations;
+        }
+      .dart_tool/package_config.json: |
+        {
+          "configVersion": 2,
+          "packages": [
+            {
+              "name": "flutter",
+              "rootUri": "../flutter",
+              "packageUri": "lib/",
+              "languageVersion": "2.9"
+            }
+          ]
+        }
+    expectedLibraryCount: 4
+  - entry: main.dart
+    worldType: updated
+    invalidate:
+      - main.dart
+    expectInitializeFromDill: false
+    sources:
+      main.dart: |
+        import 'foo.dart';
+
+        Foo foo = const Foo();
+    expectedLibraryCount: 4
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.1.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.1.expect
new file mode 100644
index 0000000..cf1b295
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.1.expect
@@ -0,0 +1,53 @@
+main = <No Member>;
+library from "package:flutter/src/widgets/framework.dart" as fra {
+
+  abstract class Bar extends dart.core::Object /*hasConstConstructor*/  {
+    const constructor •() → fra::Bar
+      : super dart.core::Object::•()
+      ;
+  }
+  abstract class Widget extends fra::Bar implements wid::_HasCreationLocation /*hasConstConstructor*/  {
+    final field wid::_Location? _location /*isNullableByDefault, from null */;
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → fra::Widget
+      : super fra::Bar::•(), fra::Widget::_location = $creationLocationd_0dea112b090073317d4!
+      ;
+  }
+}
+library from "package:flutter/src/widgets/widget_inspector.dart" as wid {
+
+  abstract class _HasCreationLocation extends dart.core::Object {
+    synthetic constructor •() → wid::_HasCreationLocation
+      : super dart.core::Object::•()
+      ;
+    abstract get _location() → wid::_Location;
+  }
+  class _Location extends dart.core::Object /*hasConstConstructor*/  {
+    final field dart.core::String file;
+    final field dart.core::int line;
+    final field dart.core::int column;
+    final field dart.core::String name;
+    final field dart.core::List<wid::_Location> parameterLocations;
+    const constructor •({required dart.core::String file = #C1, required dart.core::int line = #C1, required dart.core::int column = #C1, required dart.core::String name = #C1, required dart.core::List<wid::_Location> parameterLocations = #C1}) → wid::_Location
+      : wid::_Location::file = file, wid::_Location::line = line, wid::_Location::column = column, wid::_Location::name = name, wid::_Location::parameterLocations = parameterLocations, super dart.core::Object::•()
+      ;
+  }
+}
+library from "org-dartlang-test:///foo.dart" as foo {
+
+  import "package:flutter/src/widgets/framework.dart";
+  import "package:flutter/src/widgets/widget_inspector.dart";
+
+  class Foo extends fra::Widget /*hasConstConstructor*/  {
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → foo::Foo
+      : super fra::Widget::•($creationLocationd_0dea112b090073317d4: $creationLocationd_0dea112b090073317d4)
+      ;
+  }
+}
+library from "org-dartlang-test:///main.dart" as main {
+
+  import "org-dartlang-test:///foo.dart";
+
+}
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.2.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.2.expect
new file mode 100644
index 0000000..2019f1f
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transform_nnbd.yaml.world.2.expect
@@ -0,0 +1,54 @@
+main = <No Member>;
+library from "package:flutter/src/widgets/framework.dart" as fra {
+
+  abstract class Bar extends dart.core::Object /*hasConstConstructor*/  {
+    const constructor •() → fra::Bar
+      : super dart.core::Object::•()
+      ;
+  }
+  abstract class Widget extends fra::Bar implements wid::_HasCreationLocation /*hasConstConstructor*/  {
+    final field wid::_Location? _location /*isNullableByDefault, from null */;
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → fra::Widget
+      : super fra::Bar::•(), fra::Widget::_location = $creationLocationd_0dea112b090073317d4!
+      ;
+  }
+}
+library from "package:flutter/src/widgets/widget_inspector.dart" as wid {
+
+  abstract class _HasCreationLocation extends dart.core::Object {
+    synthetic constructor •() → wid::_HasCreationLocation
+      : super dart.core::Object::•()
+      ;
+    abstract get _location() → wid::_Location;
+  }
+  class _Location extends dart.core::Object /*hasConstConstructor*/  {
+    final field dart.core::String file;
+    final field dart.core::int line;
+    final field dart.core::int column;
+    final field dart.core::String name;
+    final field dart.core::List<wid::_Location> parameterLocations;
+    const constructor •({required dart.core::String file = #C1, required dart.core::int line = #C1, required dart.core::int column = #C1, required dart.core::String name = #C1, required dart.core::List<wid::_Location> parameterLocations = #C1}) → wid::_Location
+      : wid::_Location::file = file, wid::_Location::line = line, wid::_Location::column = column, wid::_Location::name = name, wid::_Location::parameterLocations = parameterLocations, super dart.core::Object::•()
+      ;
+  }
+}
+library from "org-dartlang-test:///foo.dart" as foo {
+
+  import "package:flutter/src/widgets/framework.dart";
+  import "package:flutter/src/widgets/widget_inspector.dart";
+
+  class Foo extends fra::Widget /*hasConstConstructor*/  {
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → foo::Foo
+      : super fra::Widget::•($creationLocationd_0dea112b090073317d4: $creationLocationd_0dea112b090073317d4)
+      ;
+  }
+}
+library from "org-dartlang-test:///main.dart" as main {
+
+  import "org-dartlang-test:///foo.dart";
+
+  static field foo::Foo foo = invalid-expression "Constant evaluation has no support for NullCheck!";
+}
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml
new file mode 100644
index 0000000..99f0f81
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml
@@ -0,0 +1,77 @@
+# 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.md file.
+
+type: newworld
+target: DDC
+trackWidgetCreation: true
+worlds:
+  - entry: main.dart
+    experiments: non-nullable
+    sources:
+      main.dart: |
+        import 'foo.dart';
+      foo.dart:
+        import 'package:flutter/src/widgets/framework.dart';
+        import 'package:flutter/src/widgets/widget_inspector.dart';
+
+        class Foo extends Widget {
+          final String name;
+
+          Foo({required this.name});
+        }
+      flutter/lib/src/widgets/framework.dart: |
+        abstract class Bar {
+          const Bar();
+        }
+        abstract class Widget extends Bar {
+          const Widget();
+        }
+      flutter/lib/src/widgets/widget_inspector.dart: |
+        abstract class _HasCreationLocation {
+          _Location get _location;
+        }
+        /// A tuple with file, line, and column number, for displaying human-readable
+        /// file locations.
+        class _Location {
+          const _Location({
+            required this.file,
+            required this.line,
+            required this.column,
+            required this.name,
+            required this.parameterLocations,
+          });
+          /// File path of the location.
+          final String file;
+          /// 1-based line number.
+          final int line;
+          /// 1-based column number.
+          final int column;
+          /// Optional name of the parameter or function at this location.
+          final String name;
+          /// Optional locations of the parameters of the member at this location.
+          final List<_Location> parameterLocations;
+        }
+      .dart_tool/package_config.json: |
+        {
+          "configVersion": 2,
+          "packages": [
+            {
+              "name": "flutter",
+              "rootUri": "../flutter",
+              "packageUri": "lib/",
+              "languageVersion": "2.9"
+            }
+          ]
+        }
+    expectedLibraryCount: 4
+  - entry: main.dart
+    worldType: updated
+    invalidate:
+      - main.dart
+    expectInitializeFromDill: false
+    sources:
+      main.dart: |
+        import 'foo.dart';
+        Foo foo = new Foo(name: 'foo');
+    expectedLibraryCount: 4
\ No newline at end of file
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.1.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.1.expect
new file mode 100644
index 0000000..ad57ba5
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.1.expect
@@ -0,0 +1,54 @@
+main = <No Member>;
+library from "package:flutter/src/widgets/framework.dart" as fra {
+
+  abstract class Bar extends dart.core::Object /*hasConstConstructor*/  {
+    const constructor •() → fra::Bar
+      : super dart.core::Object::•()
+      ;
+  }
+  abstract class Widget extends fra::Bar implements wid::_HasCreationLocation /*hasConstConstructor*/  {
+    final field wid::_Location? _location /*isNullableByDefault, from null */;
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → fra::Widget
+      : super fra::Bar::•(), fra::Widget::_location = $creationLocationd_0dea112b090073317d4!
+      ;
+  }
+}
+library from "package:flutter/src/widgets/widget_inspector.dart" as wid {
+
+  abstract class _HasCreationLocation extends dart.core::Object {
+    synthetic constructor •() → wid::_HasCreationLocation
+      : super dart.core::Object::•()
+      ;
+    abstract get _location() → wid::_Location;
+  }
+  class _Location extends dart.core::Object /*hasConstConstructor*/  {
+    final field dart.core::String file;
+    final field dart.core::int line;
+    final field dart.core::int column;
+    final field dart.core::String name;
+    final field dart.core::List<wid::_Location> parameterLocations;
+    const constructor •({required dart.core::String file = #C1, required dart.core::int line = #C1, required dart.core::int column = #C1, required dart.core::String name = #C1, required dart.core::List<wid::_Location> parameterLocations = #C1}) → wid::_Location
+      : wid::_Location::file = file, wid::_Location::line = line, wid::_Location::column = column, wid::_Location::name = name, wid::_Location::parameterLocations = parameterLocations, super dart.core::Object::•()
+      ;
+  }
+}
+library from "org-dartlang-test:///foo.dart" as foo {
+
+  import "package:flutter/src/widgets/framework.dart";
+  import "package:flutter/src/widgets/widget_inspector.dart";
+
+  class Foo extends fra::Widget {
+    final field dart.core::String name;
+    constructor •({required dart.core::String name = #C1, wid::_Location? $creationLocationd_0dea112b090073317d4}) → foo::Foo
+      : foo::Foo::name = name, super fra::Widget::•($creationLocationd_0dea112b090073317d4: $creationLocationd_0dea112b090073317d4)
+      ;
+  }
+}
+library from "org-dartlang-test:///main.dart" as main {
+
+  import "org-dartlang-test:///foo.dart";
+
+}
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.2.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.2.expect
new file mode 100644
index 0000000..1990ba5
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/flutter_widget_transformer_non_const.yaml.world.2.expect
@@ -0,0 +1,63 @@
+main = <No Member>;
+library from "package:flutter/src/widgets/framework.dart" as fra {
+
+  abstract class Bar extends dart.core::Object /*hasConstConstructor*/  {
+    const constructor •() → fra::Bar
+      : super dart.core::Object::•()
+      ;
+  }
+  abstract class Widget extends fra::Bar implements wid::_HasCreationLocation /*hasConstConstructor*/  {
+    final field wid::_Location? _location /*isNullableByDefault, from null */;
+    const constructor •({wid::_Location? $creationLocationd_0dea112b090073317d4}) → fra::Widget
+      : super fra::Bar::•(), fra::Widget::_location = $creationLocationd_0dea112b090073317d4!
+      ;
+  }
+}
+library from "package:flutter/src/widgets/widget_inspector.dart" as wid {
+
+  abstract class _HasCreationLocation extends dart.core::Object {
+    synthetic constructor •() → wid::_HasCreationLocation
+      : super dart.core::Object::•()
+      ;
+    abstract get _location() → wid::_Location;
+  }
+  class _Location extends dart.core::Object /*hasConstConstructor*/  {
+    final field dart.core::String file;
+    final field dart.core::int line;
+    final field dart.core::int column;
+    final field dart.core::String name;
+    final field dart.core::List<wid::_Location> parameterLocations;
+    const constructor •({required dart.core::String file = #C1, required dart.core::int line = #C1, required dart.core::int column = #C1, required dart.core::String name = #C1, required dart.core::List<wid::_Location> parameterLocations = #C1}) → wid::_Location
+      : wid::_Location::file = file, wid::_Location::line = line, wid::_Location::column = column, wid::_Location::name = name, wid::_Location::parameterLocations = parameterLocations, super dart.core::Object::•()
+      ;
+  }
+}
+library from "org-dartlang-test:///foo.dart" as foo {
+
+  import "package:flutter/src/widgets/framework.dart";
+  import "package:flutter/src/widgets/widget_inspector.dart";
+
+  class Foo extends fra::Widget {
+    final field dart.core::String name;
+    constructor •({required dart.core::String name = #C1, wid::_Location? $creationLocationd_0dea112b090073317d4}) → foo::Foo
+      : foo::Foo::name = name, super fra::Widget::•($creationLocationd_0dea112b090073317d4: $creationLocationd_0dea112b090073317d4)
+      ;
+  }
+}
+library from "org-dartlang-test:///main.dart" as main {
+
+  import "org-dartlang-test:///foo.dart";
+
+  static field foo::Foo foo = new foo::Foo::•(name: "foo", $creationLocationd_0dea112b090073317d4: #C9);
+}
+constants  {
+  #C1 = null
+  #C2 = "org-dartlang-test:///main.dart"
+  #C3 = 2.0
+  #C4 = 15.0
+  #C5 = 19.0
+  #C6 = "name"
+  #C7 = wid::_Location {file:#C1, line:#C3, column:#C5, name:#C6, parameterLocations:#C1}
+  #C8 = <wid::_Location*>[#C7]
+  #C9 = wid::_Location {file:#C2, line:#C3, column:#C4, name:#C1, parameterLocations:#C8}
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml
new file mode 100644
index 0000000..0b2d164
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml
@@ -0,0 +1,33 @@
+# 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.md file.
+
+# This is not actually an incremental compiler test as much as a compiler test.
+# Test what happens when running a package file as strong NNBD (and it's marked
+# with a matching language version) in a package that's with a lower language
+# version (nothing should really happen --- it should just work).
+# See https://github.com/dart-lang/sdk/issues/42323.
+
+type: newworld
+worlds:
+  - entry: bin/runMe.dart
+    experiments: non-nullable
+    nnbdMode: strong
+    enableStringReplacement: true
+    sources:
+      .dart_tool/package_config.json: |
+        {
+          "configVersion": 2,
+          "packages": [
+            {
+              "name": "issue42323",
+              "rootUri": "../",
+              "packageUri": "lib/",
+              "languageVersion": "2.8"
+            }
+          ]
+        }
+      bin/runMe.dart: |
+        // @dart = %NNBD_VERSION_MARKER%
+        main() {}
+    expectedLibraryCount: 1
\ No newline at end of file
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml.world.1.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml.world.1.expect
new file mode 100644
index 0000000..6176fb2
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323.yaml.world.1.expect
@@ -0,0 +1,5 @@
+main = <No Member>;
+library from "org-dartlang-test:///bin/runMe.dart" as run {
+
+  static method main() → dynamic {}
+}
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml
new file mode 100644
index 0000000..59e9a32
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml
@@ -0,0 +1,33 @@
+# 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.md file.
+
+# This is not actually an incremental compiler test as much as a compiler test.
+# Test what happens when running a package file as strong NNBD (and it's marked
+# with a non-nnbd language version) in a package that's with a lower language
+# version (an error should be reported).
+# Good "variant" of https://github.com/dart-lang/sdk/issues/42323.
+
+type: newworld
+worlds:
+  - entry: bin/runMe.dart
+    experiments: non-nullable
+    nnbdMode: strong
+    errors: true
+    sources:
+      .dart_tool/package_config.json: |
+        {
+          "configVersion": 2,
+          "packages": [
+            {
+              "name": "issue42323",
+              "rootUri": "../",
+              "packageUri": "lib/",
+              "languageVersion": "2.8"
+            }
+          ]
+        }
+      bin/runMe.dart: |
+        // @dart = 2.8
+        main() {}
+    expectedLibraryCount: 1
\ No newline at end of file
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml.world.1.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml.world.1.expect
new file mode 100644
index 0000000..6c8e984
--- /dev/null
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/issue_42323_prime.yaml.world.1.expect
@@ -0,0 +1,12 @@
+main = <No Member>;
+library from "org-dartlang-test:///bin/runMe.dart" as run {
+//
+// Problems in library:
+//
+// org-dartlang-test:///bin/runMe.dart:1:1: Error: A library can't opt out of null safety by default, when using sound null safety.
+// // @dart = 2.8
+// ^^^^^^^^^^^^^^
+//
+
+  static method main() → dynamic {}
+}
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 5ea6e57..2e894e1 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
@@ -424,14 +424,13 @@
     }
     method /*isNonNullableByDefault, from org-dartlang-sdk:///sdk/lib/collection/list.dart */ insert(dart.core::int index, generic-covariant-impl dart.core::int* element) → void {
       dart.core::ArgumentError::checkNotNull<dart.core::int>(index, "index");
-      dart.core::RangeError::checkValueInInterval(index, 0, this.{dart.core::List::length}, "index");
-      if(index.{dart.core::num::==}(this.{dart.core::List::length})) {
-        this.{dart.collection::ListMixin::add}(element);
-        return;
+      dart.core::int length = this.{dart.core::List::length};
+      dart.core::RangeError::checkValueInInterval(index, 0, length, "index");
+      this.{dart.collection::ListMixin::add}(element);
+      if(!index.{dart.core::num::==}(length)) {
+        this.{dart.collection::ListMixin::setRange}(index.{dart.core::num::+}(1), length.{dart.core::num::+}(1), this, index);
+        this.{dart.core::List::[]=}(index, element);
       }
-      this.{dart.core::List::length} = this.{dart.core::List::length}.{dart.core::num::+}(1);
-      this.{dart.collection::ListMixin::setRange}(index.{dart.core::num::+}(1), this.{dart.core::List::length}, this, index);
-      this.{dart.core::List::[]=}(index, element);
     }
     method /*isNonNullableByDefault, from org-dartlang-sdk:///sdk/lib/collection/list.dart */ removeAt(dart.core::int index) → dart.core::int* {
       dart.core::int* result = this.{dart.core::List::[]}(index);
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 5ea6e57..2e894e1 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
@@ -424,14 +424,13 @@
     }
     method /*isNonNullableByDefault, from org-dartlang-sdk:///sdk/lib/collection/list.dart */ insert(dart.core::int index, generic-covariant-impl dart.core::int* element) → void {
       dart.core::ArgumentError::checkNotNull<dart.core::int>(index, "index");
-      dart.core::RangeError::checkValueInInterval(index, 0, this.{dart.core::List::length}, "index");
-      if(index.{dart.core::num::==}(this.{dart.core::List::length})) {
-        this.{dart.collection::ListMixin::add}(element);
-        return;
+      dart.core::int length = this.{dart.core::List::length};
+      dart.core::RangeError::checkValueInInterval(index, 0, length, "index");
+      this.{dart.collection::ListMixin::add}(element);
+      if(!index.{dart.core::num::==}(length)) {
+        this.{dart.collection::ListMixin::setRange}(index.{dart.core::num::+}(1), length.{dart.core::num::+}(1), this, index);
+        this.{dart.core::List::[]=}(index, element);
       }
-      this.{dart.core::List::length} = this.{dart.core::List::length}.{dart.core::num::+}(1);
-      this.{dart.collection::ListMixin::setRange}(index.{dart.core::num::+}(1), this.{dart.core::List::length}, this, index);
-      this.{dart.core::List::[]=}(index, element);
     }
     method /*isNonNullableByDefault, from org-dartlang-sdk:///sdk/lib/collection/list.dart */ removeAt(dart.core::int index) → dart.core::int* {
       dart.core::int* result = this.{dart.core::List::[]}(index);
diff --git a/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.expect b/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.expect
index cea3286..29f3dec 100644
--- a/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.expect
@@ -37,10 +37,10 @@
     core::num* v4 = let final self::Test2* #t16 = t in #t16.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t17 = #t16.{self::Test2::prop} in #t17.{core::num::==}(null) ?{core::num*} #t16.{self::Test2::prop} = self::getInt() : #t17;
     core::num* v5 = let final self::Test2* #t18 = t in #t18.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t19 = #t18.{self::Test2::prop} in #t19.{core::num::==}(null) ?{core::num*} #t18.{self::Test2::prop} = self::getNum() : #t19;
     core::num* v6 = let final self::Test2* #t20 = t in #t20.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t21 = #t20.{self::Test2::prop} in #t21.{core::num::==}(null) ?{core::num*} #t20.{self::Test2::prop} = self::getDouble() : #t21;
-    core::num* v7 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t23 = #t22.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t24 = #t22.{self::Test2::prop} = #t23 in #t23;
-    core::num* v8 = let final self::Test2* #t25 = t in #t25.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t26 = #t25.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t27 = #t25.{self::Test2::prop} = #t26 in #t26;
-    core::num* v9 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
-    core::num* v10 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t32 = #t31.{self::Test2::prop}.{core::num::+}(1) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
+    core::num* v7 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t23 = #t22.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t24 = #t22.{self::Test2::prop} = #t23 in #t23;
+    core::num* v8 = let final self::Test2* #t25 = t in #t25.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t26 = #t25.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t27 = #t25.{self::Test2::prop} = #t26 in #t26;
+    core::num* v9 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
+    core::num* v10 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t32 = #t31.{self::Test2::prop}.{core::num::+}(1) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
     core::num* v11 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t35 = #t34.{self::Test2::prop} in let final void #t36 = #t34.{self::Test2::prop} = #t35.{core::num::+}(1) in #t35;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -62,10 +62,10 @@
   static method test3(self::Test3* t) → void {
     core::double* v3 = let final self::Test3* #t37 = t in #t37.{self::Test3::==}(null) ?{core::double*} null : #t37.{self::Test3::prop} = self::getDouble();
     core::double* v6 = let final self::Test3* #t38 = t in #t38.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t39 = #t38.{self::Test3::prop} in #t39.{core::num::==}(null) ?{core::double*} #t38.{self::Test3::prop} = self::getDouble() : #t39;
-    core::double* v7 = let final self::Test3* #t40 = t in #t40.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t41 = #t40.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t42 = #t40.{self::Test3::prop} = #t41 in #t41;
-    core::double* v8 = let final self::Test3* #t43 = t in #t43.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t44 = #t43.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t45 = #t43.{self::Test3::prop} = #t44 in #t44;
-    core::double* v9 = let final self::Test3* #t46 = t in #t46.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t47 = #t46.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t48 = #t46.{self::Test3::prop} = #t47 in #t47;
-    core::double* v10 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t50 = #t49.{self::Test3::prop}.{core::double::+}(1) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
+    core::double* v7 = let final self::Test3* #t40 = t in #t40.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t41 = #t40.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t42 = #t40.{self::Test3::prop} = #t41 in #t41;
+    core::double* v8 = let final self::Test3* #t43 = t in #t43.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t44 = #t43.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t45 = #t43.{self::Test3::prop} = #t44 in #t44;
+    core::double* v9 = let final self::Test3* #t46 = t in #t46.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t47 = #t46.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t48 = #t46.{self::Test3::prop} = #t47 in #t47;
+    core::double* v10 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t50 = #t49.{self::Test3::prop}.{core::double::+}(1) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
     core::double* v11 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t53 = #t52.{self::Test3::prop} in let final void #t54 = #t52.{self::Test3::prop} = #t53.{core::double::+}(1) in #t53;
   }
   abstract member-signature get _identityHashCode() → core::int*;
diff --git a/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
index cea3286..29f3dec 100644
--- a/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
@@ -37,10 +37,10 @@
     core::num* v4 = let final self::Test2* #t16 = t in #t16.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t17 = #t16.{self::Test2::prop} in #t17.{core::num::==}(null) ?{core::num*} #t16.{self::Test2::prop} = self::getInt() : #t17;
     core::num* v5 = let final self::Test2* #t18 = t in #t18.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t19 = #t18.{self::Test2::prop} in #t19.{core::num::==}(null) ?{core::num*} #t18.{self::Test2::prop} = self::getNum() : #t19;
     core::num* v6 = let final self::Test2* #t20 = t in #t20.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t21 = #t20.{self::Test2::prop} in #t21.{core::num::==}(null) ?{core::num*} #t20.{self::Test2::prop} = self::getDouble() : #t21;
-    core::num* v7 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t23 = #t22.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t24 = #t22.{self::Test2::prop} = #t23 in #t23;
-    core::num* v8 = let final self::Test2* #t25 = t in #t25.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t26 = #t25.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t27 = #t25.{self::Test2::prop} = #t26 in #t26;
-    core::num* v9 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
-    core::num* v10 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t32 = #t31.{self::Test2::prop}.{core::num::+}(1) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
+    core::num* v7 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t23 = #t22.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t24 = #t22.{self::Test2::prop} = #t23 in #t23;
+    core::num* v8 = let final self::Test2* #t25 = t in #t25.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t26 = #t25.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t27 = #t25.{self::Test2::prop} = #t26 in #t26;
+    core::num* v9 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
+    core::num* v10 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t32 = #t31.{self::Test2::prop}.{core::num::+}(1) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
     core::num* v11 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t35 = #t34.{self::Test2::prop} in let final void #t36 = #t34.{self::Test2::prop} = #t35.{core::num::+}(1) in #t35;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -62,10 +62,10 @@
   static method test3(self::Test3* t) → void {
     core::double* v3 = let final self::Test3* #t37 = t in #t37.{self::Test3::==}(null) ?{core::double*} null : #t37.{self::Test3::prop} = self::getDouble();
     core::double* v6 = let final self::Test3* #t38 = t in #t38.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t39 = #t38.{self::Test3::prop} in #t39.{core::num::==}(null) ?{core::double*} #t38.{self::Test3::prop} = self::getDouble() : #t39;
-    core::double* v7 = let final self::Test3* #t40 = t in #t40.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t41 = #t40.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t42 = #t40.{self::Test3::prop} = #t41 in #t41;
-    core::double* v8 = let final self::Test3* #t43 = t in #t43.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t44 = #t43.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t45 = #t43.{self::Test3::prop} = #t44 in #t44;
-    core::double* v9 = let final self::Test3* #t46 = t in #t46.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t47 = #t46.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t48 = #t46.{self::Test3::prop} = #t47 in #t47;
-    core::double* v10 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t50 = #t49.{self::Test3::prop}.{core::double::+}(1) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
+    core::double* v7 = let final self::Test3* #t40 = t in #t40.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t41 = #t40.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t42 = #t40.{self::Test3::prop} = #t41 in #t41;
+    core::double* v8 = let final self::Test3* #t43 = t in #t43.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t44 = #t43.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t45 = #t43.{self::Test3::prop} = #t44 in #t44;
+    core::double* v9 = let final self::Test3* #t46 = t in #t46.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t47 = #t46.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t48 = #t46.{self::Test3::prop} = #t47 in #t47;
+    core::double* v10 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t50 = #t49.{self::Test3::prop}.{core::double::+}(1) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
     core::double* v11 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t53 = #t52.{self::Test3::prop} in let final void #t54 = #t52.{self::Test3::prop} = #t53.{core::double::+}(1) in #t53;
   }
   abstract member-signature get _identityHashCode() → core::int*;
diff --git a/pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart.strong.expect b/pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart.strong.expect
index 1f2b516..9af1595 100644
--- a/pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart.strong.expect
@@ -118,9 +118,9 @@
     core::num* v2 = let final core::String* #t98 = "x" in let final core::num* #t99 = self::getNum() as{TypeError} core::int* in let final void #t100 = super.{self::Base::[]=}(#t98, #t99) in #t99;
     core::num* v4 = let final core::String* #t101 = "x" in let final core::num* #t102 = super.{self::Base::[]}(#t101) in #t102.{core::num::==}(null) ?{core::num*} let final core::int* #t103 = self::getInt() in let final void #t104 = super.{self::Base::[]=}(#t101, #t103) in #t103 : #t102;
     core::num* v5 = let final core::String* #t105 = "x" in let final core::num* #t106 = super.{self::Base::[]}(#t105) in #t106.{core::num::==}(null) ?{core::num*} let final core::num* #t107 = self::getNum() as{TypeError} core::int* in let final void #t108 = super.{self::Base::[]=}(#t105, #t107) in #t107 : #t106;
-    core::num* v7 = let final core::String* #t109 = "x" in let final core::num #t110 = super.{self::Base::[]}(#t109).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t111 = super.{self::Base::[]=}(#t109, #t110) in #t110;
-    core::num* v8 = let final core::String* #t112 = "x" in let final core::num #t113 = super.{self::Base::[]}(#t112).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t114 = super.{self::Base::[]=}(#t112, #t113) in #t113;
-    core::num* v10 = let final core::String* #t115 = "x" in let final core::num #t116 = super.{self::Base::[]}(#t115).{core::num::+}(1) as{TypeError} core::int* in let final void #t117 = super.{self::Base::[]=}(#t115, #t116) in #t116;
+    core::num* v7 = let final core::String* #t109 = "x" in let final core::num* #t110 = super.{self::Base::[]}(#t109).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t111 = super.{self::Base::[]=}(#t109, #t110) in #t110;
+    core::num* v8 = let final core::String* #t112 = "x" in let final core::num* #t113 = super.{self::Base::[]}(#t112).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t114 = super.{self::Base::[]=}(#t112, #t113) in #t113;
+    core::num* v10 = let final core::String* #t115 = "x" in let final core::num* #t116 = super.{self::Base::[]}(#t115).{core::num::+}(1) as{TypeError} core::int* in let final void #t117 = super.{self::Base::[]=}(#t115, #t116) in #t116;
     core::num* v11 = let final core::String* #t118 = "x" in let final core::num* #t119 = super.{self::Base::[]}(#t118) in let final void #t120 = super.{self::Base::[]=}(#t118, #t119.{core::num::+}(1) as{TypeError} core::int*) in #t119;
   }
 }
@@ -135,10 +135,10 @@
     core::num* v4 = let final core::String* #t130 = "x" in let final core::num* #t131 = super.{self::Base::[]}(#t130) in #t131.{core::num::==}(null) ?{core::num*} let final core::int* #t132 = self::getInt() in let final void #t133 = super.{self::Base::[]=}(#t130, #t132) in #t132 : #t131;
     core::num* v5 = let final core::String* #t134 = "x" in let final core::num* #t135 = super.{self::Base::[]}(#t134) in #t135.{core::num::==}(null) ?{core::num*} let final core::num* #t136 = self::getNum() in let final void #t137 = super.{self::Base::[]=}(#t134, #t136) in #t136 : #t135;
     core::num* v6 = let final core::String* #t138 = "x" in let final core::num* #t139 = super.{self::Base::[]}(#t138) in #t139.{core::num::==}(null) ?{core::num*} let final core::double* #t140 = self::getDouble() in let final void #t141 = super.{self::Base::[]=}(#t138, #t140) in #t140 : #t139;
-    core::num* v7 = let final core::String* #t142 = "x" in let final core::num #t143 = super.{self::Base::[]}(#t142).{core::num::+}(self::getInt()) in let final void #t144 = super.{self::Base::[]=}(#t142, #t143) in #t143;
-    core::num* v8 = let final core::String* #t145 = "x" in let final core::num #t146 = super.{self::Base::[]}(#t145).{core::num::+}(self::getNum()) in let final void #t147 = super.{self::Base::[]=}(#t145, #t146) in #t146;
-    core::num* v9 = let final core::String* #t148 = "x" in let final core::num #t149 = super.{self::Base::[]}(#t148).{core::num::+}(self::getDouble()) in let final void #t150 = super.{self::Base::[]=}(#t148, #t149) in #t149;
-    core::num* v10 = let final core::String* #t151 = "x" in let final core::num #t152 = super.{self::Base::[]}(#t151).{core::num::+}(1) in let final void #t153 = super.{self::Base::[]=}(#t151, #t152) in #t152;
+    core::num* v7 = let final core::String* #t142 = "x" in let final core::num* #t143 = super.{self::Base::[]}(#t142).{core::num::+}(self::getInt()) in let final void #t144 = super.{self::Base::[]=}(#t142, #t143) in #t143;
+    core::num* v8 = let final core::String* #t145 = "x" in let final core::num* #t146 = super.{self::Base::[]}(#t145).{core::num::+}(self::getNum()) in let final void #t147 = super.{self::Base::[]=}(#t145, #t146) in #t146;
+    core::num* v9 = let final core::String* #t148 = "x" in let final core::num* #t149 = super.{self::Base::[]}(#t148).{core::num::+}(self::getDouble()) in let final void #t150 = super.{self::Base::[]=}(#t148, #t149) in #t149;
+    core::num* v10 = let final core::String* #t151 = "x" in let final core::num* #t152 = super.{self::Base::[]}(#t151).{core::num::+}(1) in let final void #t153 = super.{self::Base::[]=}(#t151, #t152) in #t152;
     core::num* v11 = let final core::String* #t154 = "x" in let final core::num* #t155 = super.{self::Base::[]}(#t154) in let final void #t156 = super.{self::Base::[]=}(#t154, #t155.{core::num::+}(1)) in #t155;
   }
 }
@@ -151,10 +151,10 @@
     core::double* v3 = let final core::String* #t160 = "x" in let final core::double* #t161 = self::getDouble() in let final void #t162 = super.{self::Base::[]=}(#t160, #t161) in #t161;
     core::num* v5 = let final core::String* #t163 = "x" in let final core::num* #t164 = super.{self::Base::[]}(#t163) in #t164.{core::num::==}(null) ?{core::num*} let final core::num* #t165 = self::getNum() as{TypeError} core::double* in let final void #t166 = super.{self::Base::[]=}(#t163, #t165) in #t165 : #t164;
     core::num* v6 = let final core::String* #t167 = "x" in let final core::num* #t168 = super.{self::Base::[]}(#t167) in #t168.{core::num::==}(null) ?{core::num*} let final core::double* #t169 = self::getDouble() in let final void #t170 = super.{self::Base::[]=}(#t167, #t169) in #t169 : #t168;
-    core::num* v7 = let final core::String* #t171 = "x" in let final core::num #t172 = super.{self::Base::[]}(#t171).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t173 = super.{self::Base::[]=}(#t171, #t172) in #t172;
-    core::num* v8 = let final core::String* #t174 = "x" in let final core::num #t175 = super.{self::Base::[]}(#t174).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t176 = super.{self::Base::[]=}(#t174, #t175) in #t175;
-    core::num* v9 = let final core::String* #t177 = "x" in let final core::num #t178 = super.{self::Base::[]}(#t177).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t179 = super.{self::Base::[]=}(#t177, #t178) in #t178;
-    core::num* v10 = let final core::String* #t180 = "x" in let final core::num #t181 = super.{self::Base::[]}(#t180).{core::num::+}(1) as{TypeError} core::double* in let final void #t182 = super.{self::Base::[]=}(#t180, #t181) in #t181;
+    core::num* v7 = let final core::String* #t171 = "x" in let final core::num* #t172 = super.{self::Base::[]}(#t171).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t173 = super.{self::Base::[]=}(#t171, #t172) in #t172;
+    core::num* v8 = let final core::String* #t174 = "x" in let final core::num* #t175 = super.{self::Base::[]}(#t174).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t176 = super.{self::Base::[]=}(#t174, #t175) in #t175;
+    core::num* v9 = let final core::String* #t177 = "x" in let final core::num* #t178 = super.{self::Base::[]}(#t177).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t179 = super.{self::Base::[]=}(#t177, #t178) in #t178;
+    core::num* v10 = let final core::String* #t180 = "x" in let final core::num* #t181 = super.{self::Base::[]}(#t180).{core::num::+}(1) as{TypeError} core::double* in let final void #t182 = super.{self::Base::[]=}(#t180, #t181) in #t181;
     core::num* v11 = let final core::String* #t183 = "x" in let final core::num* #t184 = super.{self::Base::[]}(#t183) in let final void #t185 = super.{self::Base::[]=}(#t183, #t184.{core::num::+}(1) as{TypeError} core::double*) in #t184;
   }
 }
@@ -167,13 +167,13 @@
     core::num* v2 = let final core::String* #t189 = "x" in let final core::num* #t190 = self::getNum() as{TypeError} core::int* in let final void #t191 = super.{self::Base::[]=}(#t189, #t190) in #t190;
     core::num* v4 = let final core::String* #t192 = "x" in let final core::double* #t193 = super.{self::Base::[]}(#t192) in #t193.{core::num::==}(null) ?{core::num*} let final core::int* #t194 = self::getInt() in let final void #t195 = super.{self::Base::[]=}(#t192, #t194) in #t194 : #t193;
     core::num* v5 = let final core::String* #t196 = "x" in let final core::double* #t197 = super.{self::Base::[]}(#t196) in #t197.{core::num::==}(null) ?{core::num*} let final core::num* #t198 = self::getNum() as{TypeError} core::int* in let final void #t199 = super.{self::Base::[]=}(#t196, #t198) in #t198 : #t197;
-    core::double* v7 = let final core::String* #t200 = "x" in let final core::double #t201 = let final<BottomType> #t202 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:244:34: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v7 = let final core::String* #t200 = "x" in let final core::double* #t201 = let final<BottomType> #t202 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:244:34: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
             /*@target=double.+*/ += getInt();
                                  ^" in super.{self::Base::[]}(#t200).{core::double::+}(self::getInt()) as{TypeError} core::int* in let final void #t203 = super.{self::Base::[]=}(#t200, #t201) in #t201;
-    core::double* v8 = let final core::String* #t204 = "x" in let final core::double #t205 = let final<BottomType> #t206 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:248:34: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v8 = let final core::String* #t204 = "x" in let final core::double* #t205 = let final<BottomType> #t206 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:248:34: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
             /*@target=double.+*/ += getNum();
                                  ^" in super.{self::Base::[]}(#t204).{core::double::+}(self::getNum()) as{TypeError} core::int* in let final void #t207 = super.{self::Base::[]=}(#t204, #t205) in #t205;
-    core::double* v10 = let final core::String* #t208 = "x" in let final core::double #t209 = let final<BottomType> #t210 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:250:56: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v10 = let final core::String* #t208 = "x" in let final core::double* #t209 = let final<BottomType> #t210 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:250:56: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
     var /*@ type=double* */ v10 = /*@target=double.+*/ ++super
                                                        ^" in super.{self::Base::[]}(#t208).{core::double::+}(1) as{TypeError} core::int* in let final void #t211 = super.{self::Base::[]=}(#t208, #t209) in #t209;
     core::double* v11 = let final core::String* #t212 = "x" in let final core::double* #t213 = super.{self::Base::[]}(#t212) in let final void #t214 = super.{self::Base::[]=}(#t212, let final<BottomType> #t215 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_super_upwards.dart:254:36: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
@@ -192,10 +192,10 @@
     core::num* v4 = let final core::String* #t225 = "x" in let final core::double* #t226 = super.{self::Base::[]}(#t225) in #t226.{core::num::==}(null) ?{core::num*} let final core::int* #t227 = self::getInt() in let final void #t228 = super.{self::Base::[]=}(#t225, #t227) in #t227 : #t226;
     core::num* v5 = let final core::String* #t229 = "x" in let final core::double* #t230 = super.{self::Base::[]}(#t229) in #t230.{core::num::==}(null) ?{core::num*} let final core::num* #t231 = self::getNum() in let final void #t232 = super.{self::Base::[]=}(#t229, #t231) in #t231 : #t230;
     core::double* v6 = let final core::String* #t233 = "x" in let final core::double* #t234 = super.{self::Base::[]}(#t233) in #t234.{core::num::==}(null) ?{core::double*} let final core::double* #t235 = self::getDouble() in let final void #t236 = super.{self::Base::[]=}(#t233, #t235) in #t235 : #t234;
-    core::double* v7 = let final core::String* #t237 = "x" in let final core::double #t238 = super.{self::Base::[]}(#t237).{core::double::+}(self::getInt()) in let final void #t239 = super.{self::Base::[]=}(#t237, #t238) in #t238;
-    core::double* v8 = let final core::String* #t240 = "x" in let final core::double #t241 = super.{self::Base::[]}(#t240).{core::double::+}(self::getNum()) in let final void #t242 = super.{self::Base::[]=}(#t240, #t241) in #t241;
-    core::double* v9 = let final core::String* #t243 = "x" in let final core::double #t244 = super.{self::Base::[]}(#t243).{core::double::+}(self::getDouble()) in let final void #t245 = super.{self::Base::[]=}(#t243, #t244) in #t244;
-    core::double* v10 = let final core::String* #t246 = "x" in let final core::double #t247 = super.{self::Base::[]}(#t246).{core::double::+}(1) in let final void #t248 = super.{self::Base::[]=}(#t246, #t247) in #t247;
+    core::double* v7 = let final core::String* #t237 = "x" in let final core::double* #t238 = super.{self::Base::[]}(#t237).{core::double::+}(self::getInt()) in let final void #t239 = super.{self::Base::[]=}(#t237, #t238) in #t238;
+    core::double* v8 = let final core::String* #t240 = "x" in let final core::double* #t241 = super.{self::Base::[]}(#t240).{core::double::+}(self::getNum()) in let final void #t242 = super.{self::Base::[]=}(#t240, #t241) in #t241;
+    core::double* v9 = let final core::String* #t243 = "x" in let final core::double* #t244 = super.{self::Base::[]}(#t243).{core::double::+}(self::getDouble()) in let final void #t245 = super.{self::Base::[]=}(#t243, #t244) in #t244;
+    core::double* v10 = let final core::String* #t246 = "x" in let final core::double* #t247 = super.{self::Base::[]}(#t246).{core::double::+}(1) in let final void #t248 = super.{self::Base::[]=}(#t246, #t247) in #t247;
     core::double* v11 = let final core::String* #t249 = "x" in let final core::double* #t250 = super.{self::Base::[]}(#t249) in let final void #t251 = super.{self::Base::[]=}(#t249, #t250.{core::double::+}(1)) in #t250;
   }
 }
@@ -208,10 +208,10 @@
     core::double* v3 = let final core::String* #t255 = "x" in let final core::double* #t256 = self::getDouble() in let final void #t257 = super.{self::Base::[]=}(#t255, #t256) in #t256;
     core::num* v5 = let final core::String* #t258 = "x" in let final core::double* #t259 = super.{self::Base::[]}(#t258) in #t259.{core::num::==}(null) ?{core::num*} let final core::num* #t260 = self::getNum() as{TypeError} core::double* in let final void #t261 = super.{self::Base::[]=}(#t258, #t260) in #t260 : #t259;
     core::double* v6 = let final core::String* #t262 = "x" in let final core::double* #t263 = super.{self::Base::[]}(#t262) in #t263.{core::num::==}(null) ?{core::double*} let final core::double* #t264 = self::getDouble() in let final void #t265 = super.{self::Base::[]=}(#t262, #t264) in #t264 : #t263;
-    core::double* v7 = let final core::String* #t266 = "x" in let final core::double #t267 = super.{self::Base::[]}(#t266).{core::double::+}(self::getInt()) in let final void #t268 = super.{self::Base::[]=}(#t266, #t267) in #t267;
-    core::double* v8 = let final core::String* #t269 = "x" in let final core::double #t270 = super.{self::Base::[]}(#t269).{core::double::+}(self::getNum()) in let final void #t271 = super.{self::Base::[]=}(#t269, #t270) in #t270;
-    core::double* v9 = let final core::String* #t272 = "x" in let final core::double #t273 = super.{self::Base::[]}(#t272).{core::double::+}(self::getDouble()) in let final void #t274 = super.{self::Base::[]=}(#t272, #t273) in #t273;
-    core::double* v10 = let final core::String* #t275 = "x" in let final core::double #t276 = super.{self::Base::[]}(#t275).{core::double::+}(1) in let final void #t277 = super.{self::Base::[]=}(#t275, #t276) in #t276;
+    core::double* v7 = let final core::String* #t266 = "x" in let final core::double* #t267 = super.{self::Base::[]}(#t266).{core::double::+}(self::getInt()) in let final void #t268 = super.{self::Base::[]=}(#t266, #t267) in #t267;
+    core::double* v8 = let final core::String* #t269 = "x" in let final core::double* #t270 = super.{self::Base::[]}(#t269).{core::double::+}(self::getNum()) in let final void #t271 = super.{self::Base::[]=}(#t269, #t270) in #t270;
+    core::double* v9 = let final core::String* #t272 = "x" in let final core::double* #t273 = super.{self::Base::[]}(#t272).{core::double::+}(self::getDouble()) in let final void #t274 = super.{self::Base::[]=}(#t272, #t273) in #t273;
+    core::double* v10 = let final core::String* #t275 = "x" in let final core::double* #t276 = super.{self::Base::[]}(#t275).{core::double::+}(1) in let final void #t277 = super.{self::Base::[]=}(#t275, #t276) in #t276;
     core::double* v11 = let final core::String* #t278 = "x" in let final core::double* #t279 = super.{self::Base::[]}(#t278) in let final void #t280 = super.{self::Base::[]=}(#t278, #t279.{core::double::+}(1)) in #t279;
   }
 }
diff --git a/pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart.strong.expect b/pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart.strong.expect
index de71071..cb16def 100644
--- a/pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart.strong.expect
@@ -135,9 +135,9 @@
     core::num* v2 = let final core::String* #t98 = "x" in let final core::num* #t99 = self::getNum() as{TypeError} core::int* in let final void #t100 = this.{self::Test4::[]=}(#t98, #t99) in #t99;
     core::num* v4 = let final core::String* #t101 = "x" in let final core::num* #t102 = this.{self::Test4::[]}(#t101) in #t102.{core::num::==}(null) ?{core::num*} let final core::int* #t103 = self::getInt() in let final void #t104 = this.{self::Test4::[]=}(#t101, #t103) in #t103 : #t102;
     core::num* v5 = let final core::String* #t105 = "x" in let final core::num* #t106 = this.{self::Test4::[]}(#t105) in #t106.{core::num::==}(null) ?{core::num*} let final core::num* #t107 = self::getNum() as{TypeError} core::int* in let final void #t108 = this.{self::Test4::[]=}(#t105, #t107) in #t107 : #t106;
-    core::num* v7 = let final core::String* #t109 = "x" in let final core::num #t110 = this.{self::Test4::[]}(#t109).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t111 = this.{self::Test4::[]=}(#t109, #t110) in #t110;
-    core::num* v8 = let final core::String* #t112 = "x" in let final core::num #t113 = this.{self::Test4::[]}(#t112).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t114 = this.{self::Test4::[]=}(#t112, #t113) in #t113;
-    core::num* v10 = let final core::String* #t115 = "x" in let final core::num #t116 = this.{self::Test4::[]}(#t115).{core::num::+}(1) as{TypeError} core::int* in let final void #t117 = this.{self::Test4::[]=}(#t115, #t116) in #t116;
+    core::num* v7 = let final core::String* #t109 = "x" in let final core::num* #t110 = this.{self::Test4::[]}(#t109).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t111 = this.{self::Test4::[]=}(#t109, #t110) in #t110;
+    core::num* v8 = let final core::String* #t112 = "x" in let final core::num* #t113 = this.{self::Test4::[]}(#t112).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t114 = this.{self::Test4::[]=}(#t112, #t113) in #t113;
+    core::num* v10 = let final core::String* #t115 = "x" in let final core::num* #t116 = this.{self::Test4::[]}(#t115).{core::num::+}(1) as{TypeError} core::int* in let final void #t117 = this.{self::Test4::[]=}(#t115, #t116) in #t116;
     core::num* v11 = let final core::String* #t118 = "x" in let final core::num* #t119 = this.{self::Test4::[]}(#t118) in let final void #t120 = this.{self::Test4::[]=}(#t118, #t119.{core::num::+}(1) as{TypeError} core::int*) in #t119;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -164,10 +164,10 @@
     core::num* v4 = let final core::String* #t130 = "x" in let final core::num* #t131 = this.{self::Test5::[]}(#t130) in #t131.{core::num::==}(null) ?{core::num*} let final core::int* #t132 = self::getInt() in let final void #t133 = this.{self::Test5::[]=}(#t130, #t132) in #t132 : #t131;
     core::num* v5 = let final core::String* #t134 = "x" in let final core::num* #t135 = this.{self::Test5::[]}(#t134) in #t135.{core::num::==}(null) ?{core::num*} let final core::num* #t136 = self::getNum() in let final void #t137 = this.{self::Test5::[]=}(#t134, #t136) in #t136 : #t135;
     core::num* v6 = let final core::String* #t138 = "x" in let final core::num* #t139 = this.{self::Test5::[]}(#t138) in #t139.{core::num::==}(null) ?{core::num*} let final core::double* #t140 = self::getDouble() in let final void #t141 = this.{self::Test5::[]=}(#t138, #t140) in #t140 : #t139;
-    core::num* v7 = let final core::String* #t142 = "x" in let final core::num #t143 = this.{self::Test5::[]}(#t142).{core::num::+}(self::getInt()) in let final void #t144 = this.{self::Test5::[]=}(#t142, #t143) in #t143;
-    core::num* v8 = let final core::String* #t145 = "x" in let final core::num #t146 = this.{self::Test5::[]}(#t145).{core::num::+}(self::getNum()) in let final void #t147 = this.{self::Test5::[]=}(#t145, #t146) in #t146;
-    core::num* v9 = let final core::String* #t148 = "x" in let final core::num #t149 = this.{self::Test5::[]}(#t148).{core::num::+}(self::getDouble()) in let final void #t150 = this.{self::Test5::[]=}(#t148, #t149) in #t149;
-    core::num* v10 = let final core::String* #t151 = "x" in let final core::num #t152 = this.{self::Test5::[]}(#t151).{core::num::+}(1) in let final void #t153 = this.{self::Test5::[]=}(#t151, #t152) in #t152;
+    core::num* v7 = let final core::String* #t142 = "x" in let final core::num* #t143 = this.{self::Test5::[]}(#t142).{core::num::+}(self::getInt()) in let final void #t144 = this.{self::Test5::[]=}(#t142, #t143) in #t143;
+    core::num* v8 = let final core::String* #t145 = "x" in let final core::num* #t146 = this.{self::Test5::[]}(#t145).{core::num::+}(self::getNum()) in let final void #t147 = this.{self::Test5::[]=}(#t145, #t146) in #t146;
+    core::num* v9 = let final core::String* #t148 = "x" in let final core::num* #t149 = this.{self::Test5::[]}(#t148).{core::num::+}(self::getDouble()) in let final void #t150 = this.{self::Test5::[]=}(#t148, #t149) in #t149;
+    core::num* v10 = let final core::String* #t151 = "x" in let final core::num* #t152 = this.{self::Test5::[]}(#t151).{core::num::+}(1) in let final void #t153 = this.{self::Test5::[]=}(#t151, #t152) in #t152;
     core::num* v11 = let final core::String* #t154 = "x" in let final core::num* #t155 = this.{self::Test5::[]}(#t154) in let final void #t156 = this.{self::Test5::[]=}(#t154, #t155.{core::num::+}(1)) in #t155;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -192,10 +192,10 @@
     core::double* v3 = let final core::String* #t160 = "x" in let final core::double* #t161 = self::getDouble() in let final void #t162 = this.{self::Test6::[]=}(#t160, #t161) in #t161;
     core::num* v5 = let final core::String* #t163 = "x" in let final core::num* #t164 = this.{self::Test6::[]}(#t163) in #t164.{core::num::==}(null) ?{core::num*} let final core::num* #t165 = self::getNum() as{TypeError} core::double* in let final void #t166 = this.{self::Test6::[]=}(#t163, #t165) in #t165 : #t164;
     core::num* v6 = let final core::String* #t167 = "x" in let final core::num* #t168 = this.{self::Test6::[]}(#t167) in #t168.{core::num::==}(null) ?{core::num*} let final core::double* #t169 = self::getDouble() in let final void #t170 = this.{self::Test6::[]=}(#t167, #t169) in #t169 : #t168;
-    core::num* v7 = let final core::String* #t171 = "x" in let final core::num #t172 = this.{self::Test6::[]}(#t171).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t173 = this.{self::Test6::[]=}(#t171, #t172) in #t172;
-    core::num* v8 = let final core::String* #t174 = "x" in let final core::num #t175 = this.{self::Test6::[]}(#t174).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t176 = this.{self::Test6::[]=}(#t174, #t175) in #t175;
-    core::num* v9 = let final core::String* #t177 = "x" in let final core::num #t178 = this.{self::Test6::[]}(#t177).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t179 = this.{self::Test6::[]=}(#t177, #t178) in #t178;
-    core::num* v10 = let final core::String* #t180 = "x" in let final core::num #t181 = this.{self::Test6::[]}(#t180).{core::num::+}(1) as{TypeError} core::double* in let final void #t182 = this.{self::Test6::[]=}(#t180, #t181) in #t181;
+    core::num* v7 = let final core::String* #t171 = "x" in let final core::num* #t172 = this.{self::Test6::[]}(#t171).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t173 = this.{self::Test6::[]=}(#t171, #t172) in #t172;
+    core::num* v8 = let final core::String* #t174 = "x" in let final core::num* #t175 = this.{self::Test6::[]}(#t174).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t176 = this.{self::Test6::[]=}(#t174, #t175) in #t175;
+    core::num* v9 = let final core::String* #t177 = "x" in let final core::num* #t178 = this.{self::Test6::[]}(#t177).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t179 = this.{self::Test6::[]=}(#t177, #t178) in #t178;
+    core::num* v10 = let final core::String* #t180 = "x" in let final core::num* #t181 = this.{self::Test6::[]}(#t180).{core::num::+}(1) as{TypeError} core::double* in let final void #t182 = this.{self::Test6::[]=}(#t180, #t181) in #t181;
     core::num* v11 = let final core::String* #t183 = "x" in let final core::num* #t184 = this.{self::Test6::[]}(#t183) in let final void #t185 = this.{self::Test6::[]=}(#t183, #t184.{core::num::+}(1) as{TypeError} core::double*) in #t184;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -220,13 +220,13 @@
     core::num* v2 = let final core::String* #t189 = "x" in let final core::num* #t190 = self::getNum() as{TypeError} core::int* in let final void #t191 = this.{self::Test7::[]=}(#t189, #t190) in #t190;
     core::num* v4 = let final core::String* #t192 = "x" in let final core::double* #t193 = this.{self::Test7::[]}(#t192) in #t193.{core::num::==}(null) ?{core::num*} let final core::int* #t194 = self::getInt() in let final void #t195 = this.{self::Test7::[]=}(#t192, #t194) in #t194 : #t193;
     core::num* v5 = let final core::String* #t196 = "x" in let final core::double* #t197 = this.{self::Test7::[]}(#t196) in #t197.{core::num::==}(null) ?{core::num*} let final core::num* #t198 = self::getNum() as{TypeError} core::int* in let final void #t199 = this.{self::Test7::[]=}(#t196, #t198) in #t198 : #t197;
-    core::double* v7 = let final core::String* #t200 = "x" in let final core::double #t201 = let final<BottomType> #t202 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:264:30: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v7 = let final core::String* #t200 = "x" in let final core::double* #t201 = let final<BottomType> #t202 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:264:30: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
         /*@target=double.+*/ += getInt();
                              ^" in this.{self::Test7::[]}(#t200).{core::double::+}(self::getInt()) as{TypeError} core::int* in let final void #t203 = this.{self::Test7::[]=}(#t200, #t201) in #t201;
-    core::double* v8 = let final core::String* #t204 = "x" in let final core::double #t205 = let final<BottomType> #t206 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:268:30: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v8 = let final core::String* #t204 = "x" in let final core::double* #t205 = let final<BottomType> #t206 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:268:30: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
         /*@target=double.+*/ += getNum();
                              ^" in this.{self::Test7::[]}(#t204).{core::double::+}(self::getNum()) as{TypeError} core::int* in let final void #t207 = this.{self::Test7::[]=}(#t204, #t205) in #t205;
-    core::double* v10 = let final core::String* #t208 = "x" in let final core::double #t209 = let final<BottomType> #t210 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:270:56: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+    core::double* v10 = let final core::String* #t208 = "x" in let final core::double* #t209 = let final<BottomType> #t210 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:270:56: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
     var /*@ type=double* */ v10 = /*@target=double.+*/ ++this
                                                        ^" in this.{self::Test7::[]}(#t208).{core::double::+}(1) as{TypeError} core::int* in let final void #t211 = this.{self::Test7::[]=}(#t208, #t209) in #t209;
     core::double* v11 = let final core::String* #t212 = "x" in let final core::double* #t213 = this.{self::Test7::[]}(#t212) in let final void #t214 = this.{self::Test7::[]=}(#t212, let final<BottomType> #t215 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_this_upwards.dart:275:30: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
@@ -257,10 +257,10 @@
     core::num* v4 = let final core::String* #t225 = "x" in let final core::double* #t226 = this.{self::Test8::[]}(#t225) in #t226.{core::num::==}(null) ?{core::num*} let final core::int* #t227 = self::getInt() in let final void #t228 = this.{self::Test8::[]=}(#t225, #t227) in #t227 : #t226;
     core::num* v5 = let final core::String* #t229 = "x" in let final core::double* #t230 = this.{self::Test8::[]}(#t229) in #t230.{core::num::==}(null) ?{core::num*} let final core::num* #t231 = self::getNum() in let final void #t232 = this.{self::Test8::[]=}(#t229, #t231) in #t231 : #t230;
     core::double* v6 = let final core::String* #t233 = "x" in let final core::double* #t234 = this.{self::Test8::[]}(#t233) in #t234.{core::num::==}(null) ?{core::double*} let final core::double* #t235 = self::getDouble() in let final void #t236 = this.{self::Test8::[]=}(#t233, #t235) in #t235 : #t234;
-    core::double* v7 = let final core::String* #t237 = "x" in let final core::double #t238 = this.{self::Test8::[]}(#t237).{core::double::+}(self::getInt()) in let final void #t239 = this.{self::Test8::[]=}(#t237, #t238) in #t238;
-    core::double* v8 = let final core::String* #t240 = "x" in let final core::double #t241 = this.{self::Test8::[]}(#t240).{core::double::+}(self::getNum()) in let final void #t242 = this.{self::Test8::[]=}(#t240, #t241) in #t241;
-    core::double* v9 = let final core::String* #t243 = "x" in let final core::double #t244 = this.{self::Test8::[]}(#t243).{core::double::+}(self::getDouble()) in let final void #t245 = this.{self::Test8::[]=}(#t243, #t244) in #t244;
-    core::double* v10 = let final core::String* #t246 = "x" in let final core::double #t247 = this.{self::Test8::[]}(#t246).{core::double::+}(1) in let final void #t248 = this.{self::Test8::[]=}(#t246, #t247) in #t247;
+    core::double* v7 = let final core::String* #t237 = "x" in let final core::double* #t238 = this.{self::Test8::[]}(#t237).{core::double::+}(self::getInt()) in let final void #t239 = this.{self::Test8::[]=}(#t237, #t238) in #t238;
+    core::double* v8 = let final core::String* #t240 = "x" in let final core::double* #t241 = this.{self::Test8::[]}(#t240).{core::double::+}(self::getNum()) in let final void #t242 = this.{self::Test8::[]=}(#t240, #t241) in #t241;
+    core::double* v9 = let final core::String* #t243 = "x" in let final core::double* #t244 = this.{self::Test8::[]}(#t243).{core::double::+}(self::getDouble()) in let final void #t245 = this.{self::Test8::[]=}(#t243, #t244) in #t244;
+    core::double* v10 = let final core::String* #t246 = "x" in let final core::double* #t247 = this.{self::Test8::[]}(#t246).{core::double::+}(1) in let final void #t248 = this.{self::Test8::[]=}(#t246, #t247) in #t247;
     core::double* v11 = let final core::String* #t249 = "x" in let final core::double* #t250 = this.{self::Test8::[]}(#t249) in let final void #t251 = this.{self::Test8::[]=}(#t249, #t250.{core::double::+}(1)) in #t250;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -285,10 +285,10 @@
     core::double* v3 = let final core::String* #t255 = "x" in let final core::double* #t256 = self::getDouble() in let final void #t257 = this.{self::Test9::[]=}(#t255, #t256) in #t256;
     core::num* v5 = let final core::String* #t258 = "x" in let final core::double* #t259 = this.{self::Test9::[]}(#t258) in #t259.{core::num::==}(null) ?{core::num*} let final core::num* #t260 = self::getNum() as{TypeError} core::double* in let final void #t261 = this.{self::Test9::[]=}(#t258, #t260) in #t260 : #t259;
     core::double* v6 = let final core::String* #t262 = "x" in let final core::double* #t263 = this.{self::Test9::[]}(#t262) in #t263.{core::num::==}(null) ?{core::double*} let final core::double* #t264 = self::getDouble() in let final void #t265 = this.{self::Test9::[]=}(#t262, #t264) in #t264 : #t263;
-    core::double* v7 = let final core::String* #t266 = "x" in let final core::double #t267 = this.{self::Test9::[]}(#t266).{core::double::+}(self::getInt()) in let final void #t268 = this.{self::Test9::[]=}(#t266, #t267) in #t267;
-    core::double* v8 = let final core::String* #t269 = "x" in let final core::double #t270 = this.{self::Test9::[]}(#t269).{core::double::+}(self::getNum()) in let final void #t271 = this.{self::Test9::[]=}(#t269, #t270) in #t270;
-    core::double* v9 = let final core::String* #t272 = "x" in let final core::double #t273 = this.{self::Test9::[]}(#t272).{core::double::+}(self::getDouble()) in let final void #t274 = this.{self::Test9::[]=}(#t272, #t273) in #t273;
-    core::double* v10 = let final core::String* #t275 = "x" in let final core::double #t276 = this.{self::Test9::[]}(#t275).{core::double::+}(1) in let final void #t277 = this.{self::Test9::[]=}(#t275, #t276) in #t276;
+    core::double* v7 = let final core::String* #t266 = "x" in let final core::double* #t267 = this.{self::Test9::[]}(#t266).{core::double::+}(self::getInt()) in let final void #t268 = this.{self::Test9::[]=}(#t266, #t267) in #t267;
+    core::double* v8 = let final core::String* #t269 = "x" in let final core::double* #t270 = this.{self::Test9::[]}(#t269).{core::double::+}(self::getNum()) in let final void #t271 = this.{self::Test9::[]=}(#t269, #t270) in #t270;
+    core::double* v9 = let final core::String* #t272 = "x" in let final core::double* #t273 = this.{self::Test9::[]}(#t272).{core::double::+}(self::getDouble()) in let final void #t274 = this.{self::Test9::[]=}(#t272, #t273) in #t273;
+    core::double* v10 = let final core::String* #t275 = "x" in let final core::double* #t276 = this.{self::Test9::[]}(#t275).{core::double::+}(1) in let final void #t277 = this.{self::Test9::[]=}(#t275, #t276) in #t276;
     core::double* v11 = let final core::String* #t278 = "x" in let final core::double* #t279 = this.{self::Test9::[]}(#t278) in let final void #t280 = this.{self::Test9::[]=}(#t278, #t279.{core::double::+}(1)) in #t279;
   }
   abstract member-signature get _identityHashCode() → core::int*;
diff --git a/pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart.strong.expect b/pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart.strong.expect
index 4b4c09b..28e8772 100644
--- a/pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart.strong.expect
@@ -101,9 +101,9 @@
   core::num* v2 = let final self::Test<core::num*, core::int*>* #t127 = t in let final core::String* #t128 = "x" in let final core::num* #t129 = self::getNum() as{TypeError} core::int* in let final void #t130 = #t127.{self::Test::[]=}(#t128, #t129) in #t129;
   core::num* v4 = let final self::Test<core::num*, core::int*>* #t131 = t in let final core::String* #t132 = "x" in let final core::num* #t133 = #t131.{self::Test::[]}(#t132) in #t133.{core::num::==}(null) ?{core::num*} let final core::int* #t134 = self::getInt() in let final void #t135 = #t131.{self::Test::[]=}(#t132, #t134) in #t134 : #t133;
   core::num* v5 = let final self::Test<core::num*, core::int*>* #t136 = t in let final core::String* #t137 = "x" in let final core::num* #t138 = #t136.{self::Test::[]}(#t137) in #t138.{core::num::==}(null) ?{core::num*} let final core::num* #t139 = self::getNum() as{TypeError} core::int* in let final void #t140 = #t136.{self::Test::[]=}(#t137, #t139) in #t139 : #t138;
-  core::num* v7 = let final self::Test<core::num*, core::int*>* #t141 = t in let final core::String* #t142 = "x" in let final core::num #t143 = #t141.{self::Test::[]}(#t142).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t144 = #t141.{self::Test::[]=}(#t142, #t143) in #t143;
-  core::num* v8 = let final self::Test<core::num*, core::int*>* #t145 = t in let final core::String* #t146 = "x" in let final core::num #t147 = #t145.{self::Test::[]}(#t146).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t148 = #t145.{self::Test::[]=}(#t146, #t147) in #t147;
-  core::num* v10 = let final self::Test<core::num*, core::int*>* #t149 = t in let final core::String* #t150 = "x" in let final core::num #t151 = #t149.{self::Test::[]}(#t150).{core::num::+}(1) as{TypeError} core::int* in let final void #t152 = #t149.{self::Test::[]=}(#t150, #t151) in #t151;
+  core::num* v7 = let final self::Test<core::num*, core::int*>* #t141 = t in let final core::String* #t142 = "x" in let final core::num* #t143 = #t141.{self::Test::[]}(#t142).{core::num::+}(self::getInt()) as{TypeError} core::int* in let final void #t144 = #t141.{self::Test::[]=}(#t142, #t143) in #t143;
+  core::num* v8 = let final self::Test<core::num*, core::int*>* #t145 = t in let final core::String* #t146 = "x" in let final core::num* #t147 = #t145.{self::Test::[]}(#t146).{core::num::+}(self::getNum()) as{TypeError} core::int* in let final void #t148 = #t145.{self::Test::[]=}(#t146, #t147) in #t147;
+  core::num* v10 = let final self::Test<core::num*, core::int*>* #t149 = t in let final core::String* #t150 = "x" in let final core::num* #t151 = #t149.{self::Test::[]}(#t150).{core::num::+}(1) as{TypeError} core::int* in let final void #t152 = #t149.{self::Test::[]=}(#t150, #t151) in #t151;
   core::num* v11 = let final self::Test<core::num*, core::int*>* #t153 = t in let final core::String* #t154 = "x" in let final core::num* #t155 = #t153.{self::Test::[]}(#t154) in let final void #t156 = #t153.{self::Test::[]=}(#t154, #t155.{core::num::+}(1) as{TypeError} core::int*) in #t155;
 }
 static method test5(self::Test<core::num*, core::num*>* t) → void {
@@ -113,10 +113,10 @@
   core::num* v4 = let final self::Test<core::num*, core::num*>* #t169 = t in let final core::String* #t170 = "x" in let final core::num* #t171 = #t169.{self::Test::[]}(#t170) in #t171.{core::num::==}(null) ?{core::num*} let final core::int* #t172 = self::getInt() in let final void #t173 = #t169.{self::Test::[]=}(#t170, #t172) in #t172 : #t171;
   core::num* v5 = let final self::Test<core::num*, core::num*>* #t174 = t in let final core::String* #t175 = "x" in let final core::num* #t176 = #t174.{self::Test::[]}(#t175) in #t176.{core::num::==}(null) ?{core::num*} let final core::num* #t177 = self::getNum() in let final void #t178 = #t174.{self::Test::[]=}(#t175, #t177) in #t177 : #t176;
   core::num* v6 = let final self::Test<core::num*, core::num*>* #t179 = t in let final core::String* #t180 = "x" in let final core::num* #t181 = #t179.{self::Test::[]}(#t180) in #t181.{core::num::==}(null) ?{core::num*} let final core::double* #t182 = self::getDouble() in let final void #t183 = #t179.{self::Test::[]=}(#t180, #t182) in #t182 : #t181;
-  core::num* v7 = let final self::Test<core::num*, core::num*>* #t184 = t in let final core::String* #t185 = "x" in let final core::num #t186 = #t184.{self::Test::[]}(#t185).{core::num::+}(self::getInt()) in let final void #t187 = #t184.{self::Test::[]=}(#t185, #t186) in #t186;
-  core::num* v8 = let final self::Test<core::num*, core::num*>* #t188 = t in let final core::String* #t189 = "x" in let final core::num #t190 = #t188.{self::Test::[]}(#t189).{core::num::+}(self::getNum()) in let final void #t191 = #t188.{self::Test::[]=}(#t189, #t190) in #t190;
-  core::num* v9 = let final self::Test<core::num*, core::num*>* #t192 = t in let final core::String* #t193 = "x" in let final core::num #t194 = #t192.{self::Test::[]}(#t193).{core::num::+}(self::getDouble()) in let final void #t195 = #t192.{self::Test::[]=}(#t193, #t194) in #t194;
-  core::num* v10 = let final self::Test<core::num*, core::num*>* #t196 = t in let final core::String* #t197 = "x" in let final core::num #t198 = #t196.{self::Test::[]}(#t197).{core::num::+}(1) in let final void #t199 = #t196.{self::Test::[]=}(#t197, #t198) in #t198;
+  core::num* v7 = let final self::Test<core::num*, core::num*>* #t184 = t in let final core::String* #t185 = "x" in let final core::num* #t186 = #t184.{self::Test::[]}(#t185).{core::num::+}(self::getInt()) in let final void #t187 = #t184.{self::Test::[]=}(#t185, #t186) in #t186;
+  core::num* v8 = let final self::Test<core::num*, core::num*>* #t188 = t in let final core::String* #t189 = "x" in let final core::num* #t190 = #t188.{self::Test::[]}(#t189).{core::num::+}(self::getNum()) in let final void #t191 = #t188.{self::Test::[]=}(#t189, #t190) in #t190;
+  core::num* v9 = let final self::Test<core::num*, core::num*>* #t192 = t in let final core::String* #t193 = "x" in let final core::num* #t194 = #t192.{self::Test::[]}(#t193).{core::num::+}(self::getDouble()) in let final void #t195 = #t192.{self::Test::[]=}(#t193, #t194) in #t194;
+  core::num* v10 = let final self::Test<core::num*, core::num*>* #t196 = t in let final core::String* #t197 = "x" in let final core::num* #t198 = #t196.{self::Test::[]}(#t197).{core::num::+}(1) in let final void #t199 = #t196.{self::Test::[]=}(#t197, #t198) in #t198;
   core::num* v11 = let final self::Test<core::num*, core::num*>* #t200 = t in let final core::String* #t201 = "x" in let final core::num* #t202 = #t200.{self::Test::[]}(#t201) in let final void #t203 = #t200.{self::Test::[]=}(#t201, #t202.{core::num::+}(1)) in #t202;
 }
 static method test6(self::Test<core::num*, core::double*>* t) → void {
@@ -124,10 +124,10 @@
   core::double* v3 = let final self::Test<core::num*, core::double*>* #t208 = t in let final core::String* #t209 = "x" in let final core::double* #t210 = self::getDouble() in let final void #t211 = #t208.{self::Test::[]=}(#t209, #t210) in #t210;
   core::num* v5 = let final self::Test<core::num*, core::double*>* #t212 = t in let final core::String* #t213 = "x" in let final core::num* #t214 = #t212.{self::Test::[]}(#t213) in #t214.{core::num::==}(null) ?{core::num*} let final core::num* #t215 = self::getNum() as{TypeError} core::double* in let final void #t216 = #t212.{self::Test::[]=}(#t213, #t215) in #t215 : #t214;
   core::num* v6 = let final self::Test<core::num*, core::double*>* #t217 = t in let final core::String* #t218 = "x" in let final core::num* #t219 = #t217.{self::Test::[]}(#t218) in #t219.{core::num::==}(null) ?{core::num*} let final core::double* #t220 = self::getDouble() in let final void #t221 = #t217.{self::Test::[]=}(#t218, #t220) in #t220 : #t219;
-  core::num* v7 = let final self::Test<core::num*, core::double*>* #t222 = t in let final core::String* #t223 = "x" in let final core::num #t224 = #t222.{self::Test::[]}(#t223).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t225 = #t222.{self::Test::[]=}(#t223, #t224) in #t224;
-  core::num* v8 = let final self::Test<core::num*, core::double*>* #t226 = t in let final core::String* #t227 = "x" in let final core::num #t228 = #t226.{self::Test::[]}(#t227).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t229 = #t226.{self::Test::[]=}(#t227, #t228) in #t228;
-  core::num* v9 = let final self::Test<core::num*, core::double*>* #t230 = t in let final core::String* #t231 = "x" in let final core::num #t232 = #t230.{self::Test::[]}(#t231).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t233 = #t230.{self::Test::[]=}(#t231, #t232) in #t232;
-  core::num* v10 = let final self::Test<core::num*, core::double*>* #t234 = t in let final core::String* #t235 = "x" in let final core::num #t236 = #t234.{self::Test::[]}(#t235).{core::num::+}(1) as{TypeError} core::double* in let final void #t237 = #t234.{self::Test::[]=}(#t235, #t236) in #t236;
+  core::num* v7 = let final self::Test<core::num*, core::double*>* #t222 = t in let final core::String* #t223 = "x" in let final core::num* #t224 = #t222.{self::Test::[]}(#t223).{core::num::+}(self::getInt()) as{TypeError} core::double* in let final void #t225 = #t222.{self::Test::[]=}(#t223, #t224) in #t224;
+  core::num* v8 = let final self::Test<core::num*, core::double*>* #t226 = t in let final core::String* #t227 = "x" in let final core::num* #t228 = #t226.{self::Test::[]}(#t227).{core::num::+}(self::getNum()) as{TypeError} core::double* in let final void #t229 = #t226.{self::Test::[]=}(#t227, #t228) in #t228;
+  core::num* v9 = let final self::Test<core::num*, core::double*>* #t230 = t in let final core::String* #t231 = "x" in let final core::num* #t232 = #t230.{self::Test::[]}(#t231).{core::num::+}(self::getDouble()) as{TypeError} core::double* in let final void #t233 = #t230.{self::Test::[]=}(#t231, #t232) in #t232;
+  core::num* v10 = let final self::Test<core::num*, core::double*>* #t234 = t in let final core::String* #t235 = "x" in let final core::num* #t236 = #t234.{self::Test::[]}(#t235).{core::num::+}(1) as{TypeError} core::double* in let final void #t237 = #t234.{self::Test::[]=}(#t235, #t236) in #t236;
   core::num* v11 = let final self::Test<core::num*, core::double*>* #t238 = t in let final core::String* #t239 = "x" in let final core::num* #t240 = #t238.{self::Test::[]}(#t239) in let final void #t241 = #t238.{self::Test::[]=}(#t239, #t240.{core::num::+}(1) as{TypeError} core::double*) in #t240;
 }
 static method test7(self::Test<core::double*, core::int*>* t) → void {
@@ -135,13 +135,13 @@
   core::num* v2 = let final self::Test<core::double*, core::int*>* #t246 = t in let final core::String* #t247 = "x" in let final core::num* #t248 = self::getNum() as{TypeError} core::int* in let final void #t249 = #t246.{self::Test::[]=}(#t247, #t248) in #t248;
   core::num* v4 = let final self::Test<core::double*, core::int*>* #t250 = t in let final core::String* #t251 = "x" in let final core::double* #t252 = #t250.{self::Test::[]}(#t251) in #t252.{core::num::==}(null) ?{core::num*} let final core::int* #t253 = self::getInt() in let final void #t254 = #t250.{self::Test::[]=}(#t251, #t253) in #t253 : #t252;
   core::num* v5 = let final self::Test<core::double*, core::int*>* #t255 = t in let final core::String* #t256 = "x" in let final core::double* #t257 = #t255.{self::Test::[]}(#t256) in #t257.{core::num::==}(null) ?{core::num*} let final core::num* #t258 = self::getNum() as{TypeError} core::int* in let final void #t259 = #t255.{self::Test::[]=}(#t256, #t258) in #t258 : #t257;
-  core::double* v7 = let final self::Test<core::double*, core::int*>* #t260 = t in let final core::String* #t261 = "x" in let final core::double #t262 = let final<BottomType> #t263 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:211:77: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+  core::double* v7 = let final self::Test<core::double*, core::int*>* #t260 = t in let final core::String* #t261 = "x" in let final core::double* #t262 = let final<BottomType> #t263 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:211:77: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
       t /*@target=Test.[]*/ /*@target=Test.[]=*/ ['x'] /*@target=double.+*/ +=
                                                                             ^" in #t260.{self::Test::[]}(#t261).{core::double::+}(self::getInt()) as{TypeError} core::int* in let final void #t264 = #t260.{self::Test::[]=}(#t261, #t262) in #t262;
-  core::double* v8 = let final self::Test<core::double*, core::int*>* #t265 = t in let final core::String* #t266 = "x" in let final core::double #t267 = let final<BottomType> #t268 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:215:77: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+  core::double* v8 = let final self::Test<core::double*, core::int*>* #t265 = t in let final core::String* #t266 = "x" in let final core::double* #t267 = let final<BottomType> #t268 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:215:77: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
       t /*@target=Test.[]*/ /*@target=Test.[]=*/ ['x'] /*@target=double.+*/ +=
                                                                             ^" in #t265.{self::Test::[]}(#t266).{core::double::+}(self::getNum()) as{TypeError} core::int* in let final void #t269 = #t265.{self::Test::[]=}(#t266, #t267) in #t267;
-  core::double* v10 = let final self::Test<core::double*, core::int*>* #t270 = t in let final core::String* #t271 = "x" in let final core::double #t272 = let final<BottomType> #t273 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:219:28: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
+  core::double* v10 = let final self::Test<core::double*, core::int*>* #t270 = t in let final core::String* #t271 = "x" in let final core::double* #t272 = let final<BottomType> #t273 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:219:28: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
       /*@target=double.+*/ ++t
                            ^" in #t270.{self::Test::[]}(#t271).{core::double::+}(1) as{TypeError} core::int* in let final void #t274 = #t270.{self::Test::[]=}(#t271, #t272) in #t272;
   core::double* v11 = let final self::Test<core::double*, core::int*>* #t275 = t in let final core::String* #t276 = "x" in let final core::double* #t277 = #t275.{self::Test::[]}(#t276) in let final void #t278 = #t275.{self::Test::[]=}(#t276, let final<BottomType> #t279 = invalid-expression "pkg/front_end/testcases/inference_new/infer_assign_to_index_upwards.dart:223:77: Error: A value of type 'double' can't be assigned to a variable of type 'int'.
@@ -155,10 +155,10 @@
   core::num* v4 = let final self::Test<core::double*, core::num*>* #t292 = t in let final core::String* #t293 = "x" in let final core::double* #t294 = #t292.{self::Test::[]}(#t293) in #t294.{core::num::==}(null) ?{core::num*} let final core::int* #t295 = self::getInt() in let final void #t296 = #t292.{self::Test::[]=}(#t293, #t295) in #t295 : #t294;
   core::num* v5 = let final self::Test<core::double*, core::num*>* #t297 = t in let final core::String* #t298 = "x" in let final core::double* #t299 = #t297.{self::Test::[]}(#t298) in #t299.{core::num::==}(null) ?{core::num*} let final core::num* #t300 = self::getNum() in let final void #t301 = #t297.{self::Test::[]=}(#t298, #t300) in #t300 : #t299;
   core::double* v6 = let final self::Test<core::double*, core::num*>* #t302 = t in let final core::String* #t303 = "x" in let final core::double* #t304 = #t302.{self::Test::[]}(#t303) in #t304.{core::num::==}(null) ?{core::double*} let final core::double* #t305 = self::getDouble() in let final void #t306 = #t302.{self::Test::[]=}(#t303, #t305) in #t305 : #t304;
-  core::double* v7 = let final self::Test<core::double*, core::num*>* #t307 = t in let final core::String* #t308 = "x" in let final core::double #t309 = #t307.{self::Test::[]}(#t308).{core::double::+}(self::getInt()) in let final void #t310 = #t307.{self::Test::[]=}(#t308, #t309) in #t309;
-  core::double* v8 = let final self::Test<core::double*, core::num*>* #t311 = t in let final core::String* #t312 = "x" in let final core::double #t313 = #t311.{self::Test::[]}(#t312).{core::double::+}(self::getNum()) in let final void #t314 = #t311.{self::Test::[]=}(#t312, #t313) in #t313;
-  core::double* v9 = let final self::Test<core::double*, core::num*>* #t315 = t in let final core::String* #t316 = "x" in let final core::double #t317 = #t315.{self::Test::[]}(#t316).{core::double::+}(self::getDouble()) in let final void #t318 = #t315.{self::Test::[]=}(#t316, #t317) in #t317;
-  core::double* v10 = let final self::Test<core::double*, core::num*>* #t319 = t in let final core::String* #t320 = "x" in let final core::double #t321 = #t319.{self::Test::[]}(#t320).{core::double::+}(1) in let final void #t322 = #t319.{self::Test::[]=}(#t320, #t321) in #t321;
+  core::double* v7 = let final self::Test<core::double*, core::num*>* #t307 = t in let final core::String* #t308 = "x" in let final core::double* #t309 = #t307.{self::Test::[]}(#t308).{core::double::+}(self::getInt()) in let final void #t310 = #t307.{self::Test::[]=}(#t308, #t309) in #t309;
+  core::double* v8 = let final self::Test<core::double*, core::num*>* #t311 = t in let final core::String* #t312 = "x" in let final core::double* #t313 = #t311.{self::Test::[]}(#t312).{core::double::+}(self::getNum()) in let final void #t314 = #t311.{self::Test::[]=}(#t312, #t313) in #t313;
+  core::double* v9 = let final self::Test<core::double*, core::num*>* #t315 = t in let final core::String* #t316 = "x" in let final core::double* #t317 = #t315.{self::Test::[]}(#t316).{core::double::+}(self::getDouble()) in let final void #t318 = #t315.{self::Test::[]=}(#t316, #t317) in #t317;
+  core::double* v10 = let final self::Test<core::double*, core::num*>* #t319 = t in let final core::String* #t320 = "x" in let final core::double* #t321 = #t319.{self::Test::[]}(#t320).{core::double::+}(1) in let final void #t322 = #t319.{self::Test::[]=}(#t320, #t321) in #t321;
   core::double* v11 = let final self::Test<core::double*, core::num*>* #t323 = t in let final core::String* #t324 = "x" in let final core::double* #t325 = #t323.{self::Test::[]}(#t324) in let final void #t326 = #t323.{self::Test::[]=}(#t324, #t325.{core::double::+}(1)) in #t325;
 }
 static method test9(self::Test<core::double*, core::double*>* t) → void {
@@ -166,10 +166,10 @@
   core::double* v3 = let final self::Test<core::double*, core::double*>* #t331 = t in let final core::String* #t332 = "x" in let final core::double* #t333 = self::getDouble() in let final void #t334 = #t331.{self::Test::[]=}(#t332, #t333) in #t333;
   core::num* v5 = let final self::Test<core::double*, core::double*>* #t335 = t in let final core::String* #t336 = "x" in let final core::double* #t337 = #t335.{self::Test::[]}(#t336) in #t337.{core::num::==}(null) ?{core::num*} let final core::num* #t338 = self::getNum() as{TypeError} core::double* in let final void #t339 = #t335.{self::Test::[]=}(#t336, #t338) in #t338 : #t337;
   core::double* v6 = let final self::Test<core::double*, core::double*>* #t340 = t in let final core::String* #t341 = "x" in let final core::double* #t342 = #t340.{self::Test::[]}(#t341) in #t342.{core::num::==}(null) ?{core::double*} let final core::double* #t343 = self::getDouble() in let final void #t344 = #t340.{self::Test::[]=}(#t341, #t343) in #t343 : #t342;
-  core::double* v7 = let final self::Test<core::double*, core::double*>* #t345 = t in let final core::String* #t346 = "x" in let final core::double #t347 = #t345.{self::Test::[]}(#t346).{core::double::+}(self::getInt()) in let final void #t348 = #t345.{self::Test::[]=}(#t346, #t347) in #t347;
-  core::double* v8 = let final self::Test<core::double*, core::double*>* #t349 = t in let final core::String* #t350 = "x" in let final core::double #t351 = #t349.{self::Test::[]}(#t350).{core::double::+}(self::getNum()) in let final void #t352 = #t349.{self::Test::[]=}(#t350, #t351) in #t351;
-  core::double* v9 = let final self::Test<core::double*, core::double*>* #t353 = t in let final core::String* #t354 = "x" in let final core::double #t355 = #t353.{self::Test::[]}(#t354).{core::double::+}(self::getDouble()) in let final void #t356 = #t353.{self::Test::[]=}(#t354, #t355) in #t355;
-  core::double* v10 = let final self::Test<core::double*, core::double*>* #t357 = t in let final core::String* #t358 = "x" in let final core::double #t359 = #t357.{self::Test::[]}(#t358).{core::double::+}(1) in let final void #t360 = #t357.{self::Test::[]=}(#t358, #t359) in #t359;
+  core::double* v7 = let final self::Test<core::double*, core::double*>* #t345 = t in let final core::String* #t346 = "x" in let final core::double* #t347 = #t345.{self::Test::[]}(#t346).{core::double::+}(self::getInt()) in let final void #t348 = #t345.{self::Test::[]=}(#t346, #t347) in #t347;
+  core::double* v8 = let final self::Test<core::double*, core::double*>* #t349 = t in let final core::String* #t350 = "x" in let final core::double* #t351 = #t349.{self::Test::[]}(#t350).{core::double::+}(self::getNum()) in let final void #t352 = #t349.{self::Test::[]=}(#t350, #t351) in #t351;
+  core::double* v9 = let final self::Test<core::double*, core::double*>* #t353 = t in let final core::String* #t354 = "x" in let final core::double* #t355 = #t353.{self::Test::[]}(#t354).{core::double::+}(self::getDouble()) in let final void #t356 = #t353.{self::Test::[]=}(#t354, #t355) in #t355;
+  core::double* v10 = let final self::Test<core::double*, core::double*>* #t357 = t in let final core::String* #t358 = "x" in let final core::double* #t359 = #t357.{self::Test::[]}(#t358).{core::double::+}(1) in let final void #t360 = #t357.{self::Test::[]=}(#t358, #t359) in #t359;
   core::double* v11 = let final self::Test<core::double*, core::double*>* #t361 = t in let final core::String* #t362 = "x" in let final core::double* #t363 = #t361.{self::Test::[]}(#t362) in let final void #t364 = #t361.{self::Test::[]=}(#t362, #t363.{core::double::+}(1)) in #t363;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.expect b/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.expect
index 4f02efd..c1ec8db 100644
--- a/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.expect
@@ -40,10 +40,10 @@
     core::num* v4 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t23 = #t22.{self::Test2::prop} in #t23.{core::num::==}(null) ?{core::num*} #t22.{self::Test2::prop} = self::getInt() : #t23;
     core::num* v5 = let final self::Test2* #t24 = t in #t24.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t25 = #t24.{self::Test2::prop} in #t25.{core::num::==}(null) ?{core::num*} #t24.{self::Test2::prop} = self::getNum() : #t25;
     core::num* v6 = let final self::Test2* #t26 = t in #t26.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t27 = #t26.{self::Test2::prop} in #t27.{core::num::==}(null) ?{core::num*} #t26.{self::Test2::prop} = self::getDouble() : #t27;
-    core::num* v7 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
-    core::num* v8 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t32 = #t31.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
-    core::num* v9 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t35 = #t34.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t36 = #t34.{self::Test2::prop} = #t35 in #t35;
-    core::num* v10 = let final self::Test2* #t37 = t in #t37.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t38 = #t37.{self::Test2::prop}.{core::num::+}(1) in let final void #t39 = #t37.{self::Test2::prop} = #t38 in #t38;
+    core::num* v7 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
+    core::num* v8 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t32 = #t31.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
+    core::num* v9 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t35 = #t34.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t36 = #t34.{self::Test2::prop} = #t35 in #t35;
+    core::num* v10 = let final self::Test2* #t37 = t in #t37.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t38 = #t37.{self::Test2::prop}.{core::num::+}(1) in let final void #t39 = #t37.{self::Test2::prop} = #t38 in #t38;
     core::num* v11 = let final self::Test2* #t40 = t in #t40.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t41 = #t40.{self::Test2::prop} in let final void #t42 = #t40.{self::Test2::prop} = #t41.{core::num::+}(1) in #t41;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -67,10 +67,10 @@
     core::double* v3 = let final self::Test3* #t44 = t in #t44.{self::Test3::==}(null) ?{core::double*} null : #t44.{self::Test3::prop} = self::getDouble();
     core::num* v5 = let final self::Test3* #t45 = t in #t45.{self::Test3::==}(null) ?{core::num*} null : let final core::double* #t46 = #t45.{self::Test3::prop} in #t46.{core::num::==}(null) ?{core::num*} #t45.{self::Test3::prop} = self::getNum() as{TypeError} core::double* : #t46;
     core::double* v6 = let final self::Test3* #t47 = t in #t47.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t48 = #t47.{self::Test3::prop} in #t48.{core::num::==}(null) ?{core::double*} #t47.{self::Test3::prop} = self::getDouble() : #t48;
-    core::double* v7 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t50 = #t49.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
-    core::double* v8 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t53 = #t52.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t54 = #t52.{self::Test3::prop} = #t53 in #t53;
-    core::double* v9 = let final self::Test3* #t55 = t in #t55.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t56 = #t55.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t57 = #t55.{self::Test3::prop} = #t56 in #t56;
-    core::double* v10 = let final self::Test3* #t58 = t in #t58.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t59 = #t58.{self::Test3::prop}.{core::double::+}(1) in let final void #t60 = #t58.{self::Test3::prop} = #t59 in #t59;
+    core::double* v7 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t50 = #t49.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
+    core::double* v8 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t53 = #t52.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t54 = #t52.{self::Test3::prop} = #t53 in #t53;
+    core::double* v9 = let final self::Test3* #t55 = t in #t55.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t56 = #t55.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t57 = #t55.{self::Test3::prop} = #t56 in #t56;
+    core::double* v10 = let final self::Test3* #t58 = t in #t58.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t59 = #t58.{self::Test3::prop}.{core::double::+}(1) in let final void #t60 = #t58.{self::Test3::prop} = #t59 in #t59;
     core::double* v11 = let final self::Test3* #t61 = t in #t61.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t62 = #t61.{self::Test3::prop} in let final void #t63 = #t61.{self::Test3::prop} = #t62.{core::double::+}(1) in #t62;
   }
   abstract member-signature get _identityHashCode() → core::int*;
diff --git a/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
index 4f02efd..c1ec8db 100644
--- a/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference_new/infer_assign_to_property_null_aware_upwards.dart.strong.transformed.expect
@@ -40,10 +40,10 @@
     core::num* v4 = let final self::Test2* #t22 = t in #t22.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t23 = #t22.{self::Test2::prop} in #t23.{core::num::==}(null) ?{core::num*} #t22.{self::Test2::prop} = self::getInt() : #t23;
     core::num* v5 = let final self::Test2* #t24 = t in #t24.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t25 = #t24.{self::Test2::prop} in #t25.{core::num::==}(null) ?{core::num*} #t24.{self::Test2::prop} = self::getNum() : #t25;
     core::num* v6 = let final self::Test2* #t26 = t in #t26.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t27 = #t26.{self::Test2::prop} in #t27.{core::num::==}(null) ?{core::num*} #t26.{self::Test2::prop} = self::getDouble() : #t27;
-    core::num* v7 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
-    core::num* v8 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t32 = #t31.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
-    core::num* v9 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t35 = #t34.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t36 = #t34.{self::Test2::prop} = #t35 in #t35;
-    core::num* v10 = let final self::Test2* #t37 = t in #t37.{self::Test2::==}(null) ?{core::num*} null : let final core::num #t38 = #t37.{self::Test2::prop}.{core::num::+}(1) in let final void #t39 = #t37.{self::Test2::prop} = #t38 in #t38;
+    core::num* v7 = let final self::Test2* #t28 = t in #t28.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t29 = #t28.{self::Test2::prop}.{core::num::+}(self::getInt()) in let final void #t30 = #t28.{self::Test2::prop} = #t29 in #t29;
+    core::num* v8 = let final self::Test2* #t31 = t in #t31.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t32 = #t31.{self::Test2::prop}.{core::num::+}(self::getNum()) in let final void #t33 = #t31.{self::Test2::prop} = #t32 in #t32;
+    core::num* v9 = let final self::Test2* #t34 = t in #t34.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t35 = #t34.{self::Test2::prop}.{core::num::+}(self::getDouble()) in let final void #t36 = #t34.{self::Test2::prop} = #t35 in #t35;
+    core::num* v10 = let final self::Test2* #t37 = t in #t37.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t38 = #t37.{self::Test2::prop}.{core::num::+}(1) in let final void #t39 = #t37.{self::Test2::prop} = #t38 in #t38;
     core::num* v11 = let final self::Test2* #t40 = t in #t40.{self::Test2::==}(null) ?{core::num*} null : let final core::num* #t41 = #t40.{self::Test2::prop} in let final void #t42 = #t40.{self::Test2::prop} = #t41.{core::num::+}(1) in #t41;
   }
   abstract member-signature get _identityHashCode() → core::int*;
@@ -67,10 +67,10 @@
     core::double* v3 = let final self::Test3* #t44 = t in #t44.{self::Test3::==}(null) ?{core::double*} null : #t44.{self::Test3::prop} = self::getDouble();
     core::num* v5 = let final self::Test3* #t45 = t in #t45.{self::Test3::==}(null) ?{core::num*} null : let final core::double* #t46 = #t45.{self::Test3::prop} in #t46.{core::num::==}(null) ?{core::num*} #t45.{self::Test3::prop} = self::getNum() as{TypeError} core::double* : #t46;
     core::double* v6 = let final self::Test3* #t47 = t in #t47.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t48 = #t47.{self::Test3::prop} in #t48.{core::num::==}(null) ?{core::double*} #t47.{self::Test3::prop} = self::getDouble() : #t48;
-    core::double* v7 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t50 = #t49.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
-    core::double* v8 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t53 = #t52.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t54 = #t52.{self::Test3::prop} = #t53 in #t53;
-    core::double* v9 = let final self::Test3* #t55 = t in #t55.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t56 = #t55.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t57 = #t55.{self::Test3::prop} = #t56 in #t56;
-    core::double* v10 = let final self::Test3* #t58 = t in #t58.{self::Test3::==}(null) ?{core::double*} null : let final core::double #t59 = #t58.{self::Test3::prop}.{core::double::+}(1) in let final void #t60 = #t58.{self::Test3::prop} = #t59 in #t59;
+    core::double* v7 = let final self::Test3* #t49 = t in #t49.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t50 = #t49.{self::Test3::prop}.{core::double::+}(self::getInt()) in let final void #t51 = #t49.{self::Test3::prop} = #t50 in #t50;
+    core::double* v8 = let final self::Test3* #t52 = t in #t52.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t53 = #t52.{self::Test3::prop}.{core::double::+}(self::getNum()) in let final void #t54 = #t52.{self::Test3::prop} = #t53 in #t53;
+    core::double* v9 = let final self::Test3* #t55 = t in #t55.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t56 = #t55.{self::Test3::prop}.{core::double::+}(self::getDouble()) in let final void #t57 = #t55.{self::Test3::prop} = #t56 in #t56;
+    core::double* v10 = let final self::Test3* #t58 = t in #t58.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t59 = #t58.{self::Test3::prop}.{core::double::+}(1) in let final void #t60 = #t58.{self::Test3::prop} = #t59 in #t59;
     core::double* v11 = let final self::Test3* #t61 = t in #t61.{self::Test3::==}(null) ?{core::double*} null : let final core::double* #t62 = #t61.{self::Test3::prop} in let final void #t63 = #t61.{self::Test3::prop} = #t62.{core::double::+}(1) in #t62;
   }
   abstract member-signature get _identityHashCode() → core::int*;
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart
new file mode 100644
index 0000000..3fd4ae8
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.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.
+
+abstract int topLevelField;
+
+abstract final int finalTopLevelField = 0;
+
+abstract const int constField = 0;
+
+abstract class A {
+  abstract int fieldWithInitializer = 0;
+
+  abstract int initializedField1;
+
+  abstract int initializedField2;
+
+  A(this.initializedField1) : this.initializedField2 = 0;
+
+  abstract static int staticField;
+
+  abstract static final int finalStaticField;
+
+  abstract late int lateInstanceField;
+
+  external abstract int externalInstanceField;
+
+  external abstract final int externalFinalInstanceField;
+
+  external abstract covariant num externalCovariantInstanceField;
+
+  abstract external int externalInstanceField;
+
+  abstract external final int externalFinalInstanceField;
+
+  abstract external covariant num externalCovariantInstanceField;
+
+  external abstract late int externalLateInstanceField;
+}
+
+mixin B {
+  abstract static int staticField;
+
+  abstract static final int finalStaticField;
+
+  external abstract int externalInstanceField;
+
+  external abstract final int externalFinalInstanceField;
+
+  external abstract covariant num externalCovariantInstanceField;
+
+}
+
+extension Extension on A {
+  abstract int extensionInstanceField;
+  abstract final int finalExtensionInstanceField;
+  abstract static int extensionStaticField;
+  abstract static final int finalExtensionStaticField;
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.outline.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.outline.expect
new file mode 100644
index 0000000..0f64f8f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.outline.expect
@@ -0,0 +1,229 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract int topLevelField;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:7:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract final int finalTopLevelField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:9:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract const int constField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:24:3: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   abstract late int lateInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external int externalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:25: Error: 'externalInstanceField' is already declared in this scope.
+//   abstract external int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:25: Context: Previous declaration of 'externalInstanceField'.
+//   external abstract int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external final int externalFinalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:31: Error: 'externalFinalInstanceField' is already declared in this scope.
+//   abstract external final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:31: Context: Previous declaration of 'externalFinalInstanceField'.
+//   external abstract final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external covariant num externalCovariantInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:35: Error: 'externalCovariantInstanceField' is already declared in this scope.
+//   abstract external covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:35: Context: Previous declaration of 'externalCovariantInstanceField'.
+//   external abstract covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:46:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:48:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:50:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:23: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static int extensionStaticField;
+//                       ^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int extensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:29: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static final int finalExtensionStaticField;
+//                             ^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalExtensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:14: Error: Field 'topLevelField' should be initialized because its type 'int' doesn't allow null.
+// abstract int topLevelField;
+//              ^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  static field core::int staticField;
+  static final field core::int finalStaticField;
+  late field core::int lateInstanceField;
+  constructor •(core::int initializedField1) → self::A
+    ;
+  abstract get fieldWithInitializer() → core::int;
+  abstract set fieldWithInitializer(core::int #t1) → void;
+  abstract get initializedField1() → core::int;
+  abstract set initializedField1(core::int #t2) → void;
+  abstract get initializedField2() → core::int;
+  abstract set initializedField2(core::int #t3) → void;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t4) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t5) → void;
+  external get externalLateInstanceField() → core::int;
+  external set externalLateInstanceField(core::int #t6) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  static field core::int staticField;
+  static final field core::int finalStaticField;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t7) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t8) → void;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static field extensionStaticField = self::Extension|extensionStaticField;
+  static field finalExtensionStaticField = self::Extension|finalExtensionStaticField;
+}
+static field core::int topLevelField;
+static final field core::int finalTopLevelField;
+static const field core::int constField = 0;
+static field core::int Extension|extensionStaticField;
+static final field core::int Extension|finalExtensionStaticField;
+static abstract get Extension|extensionInstanceField() → core::int;
+static abstract set Extension|extensionInstanceField(core::int #t9) → void;
+static abstract get Extension|finalExtensionInstanceField() → core::int;
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.expect
new file mode 100644
index 0000000..002cc9d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.expect
@@ -0,0 +1,264 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract int topLevelField;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:7:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract final int finalTopLevelField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:9:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract const int constField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:24:3: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   abstract late int lateInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external int externalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:25: Error: 'externalInstanceField' is already declared in this scope.
+//   abstract external int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:25: Context: Previous declaration of 'externalInstanceField'.
+//   external abstract int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external final int externalFinalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:31: Error: 'externalFinalInstanceField' is already declared in this scope.
+//   abstract external final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:31: Context: Previous declaration of 'externalFinalInstanceField'.
+//   external abstract final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external covariant num externalCovariantInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:35: Error: 'externalCovariantInstanceField' is already declared in this scope.
+//   abstract external covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:35: Context: Previous declaration of 'externalCovariantInstanceField'.
+//   external abstract covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:46:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:48:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:50:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:23: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static int extensionStaticField;
+//                       ^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int extensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:29: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static final int finalExtensionStaticField;
+//                             ^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalExtensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:14: Error: Field 'topLevelField' should be initialized because its type 'int' doesn't allow null.
+// abstract int topLevelField;
+//              ^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:12:37: Error: Abstract fields cannot have initializers.
+// Try removing the initializer or the 'abstract' keyword.
+//   abstract int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  late field core::int lateInstanceField;
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  abstract get fieldWithInitializer() → core::int;
+  abstract set fieldWithInitializer(core::int #t3) → void;
+  abstract get initializedField1() → core::int;
+  abstract set initializedField1(core::int #t4) → void;
+  abstract get initializedField2() → core::int;
+  abstract set initializedField2(core::int #t5) → void;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t6) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t7) → void;
+  external get externalLateInstanceField() → core::int;
+  external set externalLateInstanceField(core::int #t8) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t9) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t10) → void;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static field extensionStaticField = self::Extension|extensionStaticField;
+  static field finalExtensionStaticField = self::Extension|finalExtensionStaticField;
+}
+static field core::int topLevelField;
+static final field core::int finalTopLevelField = 0;
+static const field core::int constField = #C1;
+static field core::int Extension|extensionStaticField;
+static final field core::int Extension|finalExtensionStaticField;
+static abstract get Extension|extensionInstanceField() → core::int;
+static abstract set Extension|extensionInstanceField(core::int #t11) → void;
+static abstract get Extension|finalExtensionInstanceField() → core::int;
+static method main() → dynamic {}
+
+constants  {
+  #C1 = 0
+}
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.transformed.expect
new file mode 100644
index 0000000..002cc9d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.strong.transformed.expect
@@ -0,0 +1,264 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract int topLevelField;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:7:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract final int finalTopLevelField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:9:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract const int constField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:24:3: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   abstract late int lateInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external int externalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:25: Error: 'externalInstanceField' is already declared in this scope.
+//   abstract external int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:25: Context: Previous declaration of 'externalInstanceField'.
+//   external abstract int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external final int externalFinalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:31: Error: 'externalFinalInstanceField' is already declared in this scope.
+//   abstract external final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:31: Context: Previous declaration of 'externalFinalInstanceField'.
+//   external abstract final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external covariant num externalCovariantInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:35: Error: 'externalCovariantInstanceField' is already declared in this scope.
+//   abstract external covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:35: Context: Previous declaration of 'externalCovariantInstanceField'.
+//   external abstract covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:46:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:48:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:50:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:23: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static int extensionStaticField;
+//                       ^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int extensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:29: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static final int finalExtensionStaticField;
+//                             ^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalExtensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:14: Error: Field 'topLevelField' should be initialized because its type 'int' doesn't allow null.
+// abstract int topLevelField;
+//              ^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:12:37: Error: Abstract fields cannot have initializers.
+// Try removing the initializer or the 'abstract' keyword.
+//   abstract int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  late field core::int lateInstanceField;
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  abstract get fieldWithInitializer() → core::int;
+  abstract set fieldWithInitializer(core::int #t3) → void;
+  abstract get initializedField1() → core::int;
+  abstract set initializedField1(core::int #t4) → void;
+  abstract get initializedField2() → core::int;
+  abstract set initializedField2(core::int #t5) → void;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t6) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t7) → void;
+  external get externalLateInstanceField() → core::int;
+  external set externalLateInstanceField(core::int #t8) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t9) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t10) → void;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static field extensionStaticField = self::Extension|extensionStaticField;
+  static field finalExtensionStaticField = self::Extension|finalExtensionStaticField;
+}
+static field core::int topLevelField;
+static final field core::int finalTopLevelField = 0;
+static const field core::int constField = #C1;
+static field core::int Extension|extensionStaticField;
+static final field core::int Extension|finalExtensionStaticField;
+static abstract get Extension|extensionInstanceField() → core::int;
+static abstract set Extension|extensionInstanceField(core::int #t11) → void;
+static abstract get Extension|finalExtensionInstanceField() → core::int;
+static method main() → dynamic {}
+
+constants  {
+  #C1 = 0
+}
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.textual_outline.expect
new file mode 100644
index 0000000..b49127a
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.textual_outline.expect
@@ -0,0 +1,31 @@
+abstract int topLevelField;
+abstract final int finalTopLevelField = 0;
+abstract const int constField = 0;
+abstract class A {
+  abstract int fieldWithInitializer = 0;
+  abstract int initializedField1;
+  abstract int initializedField2;
+  A(this.initializedField1) : this.initializedField2 = 0;
+  abstract static int staticField;
+  abstract static final int finalStaticField;
+  abstract late int ;
+  lateInstanceField;
+  external abstract int externalInstanceField;
+  external abstract final int externalFinalInstanceField;
+  external abstract covariant num externalCovariantInstanceField;
+  abstract external int externalInstanceField;
+  abstract external final int externalFinalInstanceField;
+  abstract external covariant num externalCovariantInstanceField;
+  external abstract late int ;
+  externalLateInstanceField;
+}
+mixin B {
+  abstract static int staticField;
+  abstract static final int finalStaticField;
+  external abstract int externalInstanceField;
+  external abstract final int externalFinalInstanceField;
+  external abstract covariant num externalCovariantInstanceField;
+}
+extension Extension ;
+on A (){ }
+main() { }
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.expect
new file mode 100644
index 0000000..002cc9d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.expect
@@ -0,0 +1,264 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract int topLevelField;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:7:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract final int finalTopLevelField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:9:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract const int constField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:24:3: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   abstract late int lateInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external int externalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:25: Error: 'externalInstanceField' is already declared in this scope.
+//   abstract external int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:25: Context: Previous declaration of 'externalInstanceField'.
+//   external abstract int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external final int externalFinalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:31: Error: 'externalFinalInstanceField' is already declared in this scope.
+//   abstract external final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:31: Context: Previous declaration of 'externalFinalInstanceField'.
+//   external abstract final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external covariant num externalCovariantInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:35: Error: 'externalCovariantInstanceField' is already declared in this scope.
+//   abstract external covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:35: Context: Previous declaration of 'externalCovariantInstanceField'.
+//   external abstract covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:46:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:48:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:50:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:23: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static int extensionStaticField;
+//                       ^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int extensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:29: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static final int finalExtensionStaticField;
+//                             ^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalExtensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:14: Error: Field 'topLevelField' should be initialized because its type 'int' doesn't allow null.
+// abstract int topLevelField;
+//              ^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:12:37: Error: Abstract fields cannot have initializers.
+// Try removing the initializer or the 'abstract' keyword.
+//   abstract int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  late field core::int lateInstanceField;
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  abstract get fieldWithInitializer() → core::int;
+  abstract set fieldWithInitializer(core::int #t3) → void;
+  abstract get initializedField1() → core::int;
+  abstract set initializedField1(core::int #t4) → void;
+  abstract get initializedField2() → core::int;
+  abstract set initializedField2(core::int #t5) → void;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t6) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t7) → void;
+  external get externalLateInstanceField() → core::int;
+  external set externalLateInstanceField(core::int #t8) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t9) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t10) → void;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static field extensionStaticField = self::Extension|extensionStaticField;
+  static field finalExtensionStaticField = self::Extension|finalExtensionStaticField;
+}
+static field core::int topLevelField;
+static final field core::int finalTopLevelField = 0;
+static const field core::int constField = #C1;
+static field core::int Extension|extensionStaticField;
+static final field core::int Extension|finalExtensionStaticField;
+static abstract get Extension|extensionInstanceField() → core::int;
+static abstract set Extension|extensionInstanceField(core::int #t11) → void;
+static abstract get Extension|finalExtensionInstanceField() → core::int;
+static method main() → dynamic {}
+
+constants  {
+  #C1 = 0
+}
diff --git a/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.transformed.expect
new file mode 100644
index 0000000..002cc9d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_field_errors.dart.weak.transformed.expect
@@ -0,0 +1,264 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract int topLevelField;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:7:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract final int finalTopLevelField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:9:1: Error: Can't have modifier 'abstract' here.
+// Try removing 'abstract'.
+// abstract const int constField = 0;
+// ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:24:3: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   abstract late int lateInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external int externalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:32:25: Error: 'externalInstanceField' is already declared in this scope.
+//   abstract external int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:26:25: Context: Previous declaration of 'externalInstanceField'.
+//   external abstract int externalInstanceField;
+//                         ^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external final int externalFinalInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:34:31: Error: 'externalFinalInstanceField' is already declared in this scope.
+//   abstract external final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:28:31: Context: Previous declaration of 'externalFinalInstanceField'.
+//   external abstract final int externalFinalInstanceField;
+//                               ^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:3: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   abstract external covariant num externalCovariantInstanceField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:36:35: Error: 'externalCovariantInstanceField' is already declared in this scope.
+//   abstract external covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:30:35: Context: Previous declaration of 'externalCovariantInstanceField'.
+//   external abstract covariant num externalCovariantInstanceField;
+//                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:38:12: Error: Abstract fields cannot be late.
+// Try removing the 'abstract' or 'late' keyword.
+//   external abstract late int externalLateInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int staticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:46:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract int externalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:48:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract final int externalFinalInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:50:12: Error: Fields can't be declared both 'abstract' and 'external'.
+// Try removing the 'abstract' or 'external' keyword.
+//   external abstract covariant num externalCovariantInstanceField;
+//            ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:55:16: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract int extensionInstanceField;
+//                ^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:56:22: Error: Extensions can't declare instance fields
+// Try removing the field declaration or making it a static field
+//   abstract final int finalExtensionInstanceField;
+//                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:23: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static int extensionStaticField;
+//                       ^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:57:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static int extensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:29: Error: Extension fields can't be declared 'abstract'.
+// Try removing the 'abstract' keyword.
+//   abstract static final int finalExtensionStaticField;
+//                             ^^^^^^^^^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:58:3: Error: Static fields can't be declared 'abstract'.
+// Try removing the 'abstract' or 'static' keyword.
+//   abstract static final int finalExtensionStaticField;
+//   ^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:5:14: Error: Field 'topLevelField' should be initialized because its type 'int' doesn't allow null.
+// abstract int topLevelField;
+//              ^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:20:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:42:23: Error: Field 'staticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static int staticField;
+//                       ^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Field 'finalStaticField' should be initialized because its type 'int' doesn't allow null.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:12:37: Error: Abstract fields cannot have initializers.
+// Try removing the initializer or the 'abstract' keyword.
+//   abstract int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+// Try removing the field initializer or the 'abstract' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:22:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/abstract_field_errors.dart:44:29: Error: Final field 'finalStaticField' is not initialized.
+// Try to initialize the field in the declaration or in every constructor.
+//   abstract static final int finalStaticField;
+//                             ^^^^^^^^^^^^^^^^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  late field core::int lateInstanceField;
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:10: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/abstract_field_errors.dart:18:36: Error: Abstract fields cannot have initializers.
+Try removing the field initializer or the 'abstract' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  abstract get fieldWithInitializer() → core::int;
+  abstract set fieldWithInitializer(core::int #t3) → void;
+  abstract get initializedField1() → core::int;
+  abstract set initializedField1(core::int #t4) → void;
+  abstract get initializedField2() → core::int;
+  abstract set initializedField2(core::int #t5) → void;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t6) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t7) → void;
+  external get externalLateInstanceField() → core::int;
+  external set externalLateInstanceField(core::int #t8) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  static field core::int staticField = null;
+  static final field core::int finalStaticField = null;
+  external abstract get externalInstanceField() → core::int;
+  external abstract set externalInstanceField(core::int #t9) → void;
+  external abstract get externalFinalInstanceField() → core::int;
+  external abstract get externalCovariantInstanceField() → core::num;
+  external abstract set externalCovariantInstanceField(covariant core::num #t10) → void;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static field extensionStaticField = self::Extension|extensionStaticField;
+  static field finalExtensionStaticField = self::Extension|finalExtensionStaticField;
+}
+static field core::int topLevelField;
+static final field core::int finalTopLevelField = 0;
+static const field core::int constField = #C1;
+static field core::int Extension|extensionStaticField;
+static final field core::int Extension|finalExtensionStaticField;
+static abstract get Extension|extensionInstanceField() → core::int;
+static abstract set Extension|extensionInstanceField(core::int #t11) → void;
+static abstract get Extension|finalExtensionInstanceField() → core::int;
+static method main() → dynamic {}
+
+constants  {
+  #C1 = 0
+}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart b/pkg/front_end/testcases/nnbd/abstract_fields.dart
new file mode 100644
index 0000000..7b2d06f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.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.
+
+abstract class A {
+  abstract int instanceField; // ok
+
+  abstract final int finalInstanceField; // ok
+
+  abstract covariant num covariantInstanceField; // ok
+}
+
+mixin B {
+  abstract int instanceField; // ok
+
+  abstract final int finalInstanceField; // ok
+
+  abstract covariant num covariantInstanceField; // ok
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.outline.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.outline.expect
new file mode 100644
index 0000000..e13a36a
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.outline.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    ;
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t1) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t2) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t3) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t4) → void;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.expect
new file mode 100644
index 0000000..d5823fb
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t1) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t2) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t3) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t4) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.transformed.expect
new file mode 100644
index 0000000..d5823fb
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.strong.transformed.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t1) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t2) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t3) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t4) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.textual_outline.expect
new file mode 100644
index 0000000..9d0e9ba
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.textual_outline.expect
@@ -0,0 +1,11 @@
+abstract class A {
+  abstract int instanceField;
+  abstract final int finalInstanceField;
+  abstract covariant num covariantInstanceField;
+}
+mixin B {
+  abstract int instanceField;
+  abstract final int finalInstanceField;
+  abstract covariant num covariantInstanceField;
+}
+main() { }
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.expect
new file mode 100644
index 0000000..d5823fb
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t1) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t2) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t3) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t4) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.transformed.expect
new file mode 100644
index 0000000..d5823fb
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields.dart.weak.transformed.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t1) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t2) → void;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  abstract get instanceField() → core::int;
+  abstract set instanceField(core::int #t3) → void;
+  abstract get finalInstanceField() → core::int;
+  abstract get covariantInstanceField() → core::num;
+  abstract set covariantInstanceField(covariant core::num #t4) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart
new file mode 100644
index 0000000..3164945
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart
@@ -0,0 +1,14 @@
+// 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.
+
+abstract class A {
+  abstract int i1, i2;
+  abstract var x;
+  abstract final int fi;
+  abstract final fx;
+  abstract covariant num cn;
+  abstract covariant var cx;
+}
+
+main() {}
\ No newline at end of file
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.outline.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.outline.expect
new file mode 100644
index 0000000..492b9a7
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.outline.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    ;
+  abstract get i1() → core::int;
+  abstract set i1(core::int #t1) → void;
+  abstract get i2() → core::int;
+  abstract set i2(core::int #t2) → void;
+  abstract get x() → dynamic;
+  abstract set x(dynamic #t3) → void;
+  abstract get fi() → core::int;
+  abstract get fx() → dynamic;
+  abstract get cn() → core::num;
+  abstract set cn(covariant core::num #t4) → void;
+  abstract get cx() → dynamic;
+  abstract set cx(covariant dynamic #t5) → void;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.expect
new file mode 100644
index 0000000..345a7f1
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get i1() → core::int;
+  abstract set i1(core::int #t1) → void;
+  abstract get i2() → core::int;
+  abstract set i2(core::int #t2) → void;
+  abstract get x() → dynamic;
+  abstract set x(dynamic #t3) → void;
+  abstract get fi() → core::int;
+  abstract get fx() → dynamic;
+  abstract get cn() → core::num;
+  abstract set cn(covariant core::num #t4) → void;
+  abstract get cx() → dynamic;
+  abstract set cx(covariant dynamic #t5) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.transformed.expect
new file mode 100644
index 0000000..345a7f1
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.strong.transformed.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get i1() → core::int;
+  abstract set i1(core::int #t1) → void;
+  abstract get i2() → core::int;
+  abstract set i2(core::int #t2) → void;
+  abstract get x() → dynamic;
+  abstract set x(dynamic #t3) → void;
+  abstract get fi() → core::int;
+  abstract get fx() → dynamic;
+  abstract get cn() → core::num;
+  abstract set cn(covariant core::num #t4) → void;
+  abstract get cx() → dynamic;
+  abstract set cx(covariant dynamic #t5) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.textual_outline.expect
new file mode 100644
index 0000000..eb8f57c
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.textual_outline.expect
@@ -0,0 +1,9 @@
+abstract class A {
+  abstract int i1, i2;
+  abstract var x;
+  abstract final int fi;
+  abstract final fx;
+  abstract covariant num cn;
+  abstract covariant var cx;
+}
+main() { }
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.expect
new file mode 100644
index 0000000..345a7f1
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get i1() → core::int;
+  abstract set i1(core::int #t1) → void;
+  abstract get i2() → core::int;
+  abstract set i2(core::int #t2) → void;
+  abstract get x() → dynamic;
+  abstract set x(dynamic #t3) → void;
+  abstract get fi() → core::int;
+  abstract get fx() → dynamic;
+  abstract get cn() → core::num;
+  abstract set cn(covariant core::num #t4) → void;
+  abstract get cx() → dynamic;
+  abstract set cx(covariant dynamic #t5) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.transformed.expect
new file mode 100644
index 0000000..345a7f1
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/abstract_fields_spec.dart.weak.transformed.expect
@@ -0,0 +1,22 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract get i1() → core::int;
+  abstract set i1(core::int #t1) → void;
+  abstract get i2() → core::int;
+  abstract set i2(core::int #t2) → void;
+  abstract get x() → dynamic;
+  abstract set x(dynamic #t3) → void;
+  abstract get fi() → core::int;
+  abstract get fx() → dynamic;
+  abstract get cn() → core::num;
+  abstract set cn(covariant core::num #t4) → void;
+  abstract get cx() → dynamic;
+  abstract set cx(covariant dynamic #t5) → void;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline.expect
new file mode 100644
index 0000000..5c9aa73
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline.expect
@@ -0,0 +1,9 @@
+class Class {
+  @override
+  noSuchMethod(Object o, {String foo = ''}) => 42;
+  @override
+  toString({String foo = ''}) => 'foo';
+}
+
+main() {}
+test() {}
diff --git a/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..5c9aa73
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/dynamic_object_call.dart.textual_outline_modelled.expect
@@ -0,0 +1,9 @@
+class Class {
+  @override
+  noSuchMethod(Object o, {String foo = ''}) => 42;
+  @override
+  toString({String foo = ''}) => 'foo';
+}
+
+main() {}
+test() {}
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart b/pkg/front_end/testcases/nnbd/external_field_errors.dart
new file mode 100644
index 0000000..66fd83b
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart
@@ -0,0 +1,38 @@
+// 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.
+
+external int topLevelField = 0;
+
+external final int finalTopLevelField = 0;
+
+external const int constField = 0;
+
+abstract class A {
+  external int fieldWithInitializer = 0;
+
+  external int initializedField1;
+
+  external int initializedField2;
+
+  A(this.initializedField1) : this.initializedField2 = 0;
+
+  external static int staticField = 0;
+
+  external static final int finalStaticField = 0;
+}
+
+mixin B {
+  external static int staticField = 0;
+
+  external static final int finalStaticField = 0;
+}
+
+extension Extension on A {
+  external int extensionInstanceField = 0;
+  external final int finalExtensionInstanceField = 0;
+  external static int extensionStaticField = 0;
+  external static final int finalExtensionStaticField = 0;
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.outline.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.outline.expect
new file mode 100644
index 0000000..197f942
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.outline.expect
@@ -0,0 +1,43 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  constructor •(core::int initializedField1) → self::A
+    ;
+  external get fieldWithInitializer() → core::int;
+  external set fieldWithInitializer(core::int #t1) → void;
+  external get initializedField1() → core::int;
+  external set initializedField1(core::int #t2) → void;
+  external get initializedField2() → core::int;
+  external set initializedField2(core::int #t3) → void;
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t4) → void;
+  external static get finalStaticField() → core::int;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t5) → void;
+  external static get finalStaticField() → core::int;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static get extensionStaticField = get self::Extension|extensionStaticField;
+  static set extensionStaticField = set self::Extension|extensionStaticField;
+  static get finalExtensionStaticField = get self::Extension|finalExtensionStaticField;
+}
+external static get topLevelField() → core::int;
+external static set topLevelField(core::int #t6) → void;
+external static get finalTopLevelField() → core::int;
+external static get constField() → core::int;
+external static set constField(core::int #t7) → void;
+external static get Extension|extensionInstanceField() → core::int;
+external static set Extension|extensionInstanceField(core::int #t8) → void;
+external static get Extension|finalExtensionInstanceField() → core::int;
+external static get Extension|extensionStaticField() → core::int;
+external static set Extension|extensionStaticField(core::int #t9) → void;
+external static get Extension|finalExtensionStaticField() → core::int;
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.expect
new file mode 100644
index 0000000..895696f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.expect
@@ -0,0 +1,122 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:5:28: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external int topLevelField = 0;
+//                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:7:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external final int finalTopLevelField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:9:31: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external const int constField = 0;
+//                               ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:12:37: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:20:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:22:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:26:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:28:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:32:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int extensionInstanceField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:33:50: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external final int finalExtensionInstanceField = 0;
+//                                                  ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:34:44: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int extensionStaticField = 0;
+//                                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:35:55: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalExtensionStaticField = 0;
+//                                                       ^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  external get fieldWithInitializer() → core::int;
+  external set fieldWithInitializer(core::int #t3) → void;
+  external get initializedField1() → core::int;
+  external set initializedField1(core::int #t4) → void;
+  external get initializedField2() → core::int;
+  external set initializedField2(core::int #t5) → void;
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t6) → void;
+  external static get finalStaticField() → core::int;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t7) → void;
+  external static get finalStaticField() → core::int;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static get extensionStaticField = get self::Extension|extensionStaticField;
+  static set extensionStaticField = set self::Extension|extensionStaticField;
+  static get finalExtensionStaticField = get self::Extension|finalExtensionStaticField;
+}
+external static get topLevelField() → core::int;
+external static set topLevelField(core::int #t8) → void;
+external static get finalTopLevelField() → core::int;
+external static get constField() → core::int;
+external static set constField(core::int #t9) → void;
+external static get Extension|extensionInstanceField() → core::int;
+external static set Extension|extensionInstanceField(core::int #t10) → void;
+external static get Extension|finalExtensionInstanceField() → core::int;
+external static get Extension|extensionStaticField() → core::int;
+external static set Extension|extensionStaticField(core::int #t11) → void;
+external static get Extension|finalExtensionStaticField() → core::int;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.transformed.expect
new file mode 100644
index 0000000..895696f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.strong.transformed.expect
@@ -0,0 +1,122 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:5:28: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external int topLevelField = 0;
+//                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:7:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external final int finalTopLevelField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:9:31: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external const int constField = 0;
+//                               ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:12:37: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:20:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:22:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:26:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:28:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:32:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int extensionInstanceField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:33:50: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external final int finalExtensionInstanceField = 0;
+//                                                  ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:34:44: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int extensionStaticField = 0;
+//                                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:35:55: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalExtensionStaticField = 0;
+//                                                       ^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  external get fieldWithInitializer() → core::int;
+  external set fieldWithInitializer(core::int #t3) → void;
+  external get initializedField1() → core::int;
+  external set initializedField1(core::int #t4) → void;
+  external get initializedField2() → core::int;
+  external set initializedField2(core::int #t5) → void;
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t6) → void;
+  external static get finalStaticField() → core::int;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t7) → void;
+  external static get finalStaticField() → core::int;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static get extensionStaticField = get self::Extension|extensionStaticField;
+  static set extensionStaticField = set self::Extension|extensionStaticField;
+  static get finalExtensionStaticField = get self::Extension|finalExtensionStaticField;
+}
+external static get topLevelField() → core::int;
+external static set topLevelField(core::int #t8) → void;
+external static get finalTopLevelField() → core::int;
+external static get constField() → core::int;
+external static set constField(core::int #t9) → void;
+external static get Extension|extensionInstanceField() → core::int;
+external static set Extension|extensionInstanceField(core::int #t10) → void;
+external static get Extension|finalExtensionInstanceField() → core::int;
+external static get Extension|extensionStaticField() → core::int;
+external static set Extension|extensionStaticField(core::int #t11) → void;
+external static get Extension|finalExtensionStaticField() → core::int;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.textual_outline.expect
new file mode 100644
index 0000000..933da15
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.textual_outline.expect
@@ -0,0 +1,18 @@
+external int topLevelField = 0;
+external final int finalTopLevelField = 0;
+external const int constField = 0;
+abstract class A {
+  external int fieldWithInitializer = 0;
+  external int initializedField1;
+  external int initializedField2;
+  A(this.initializedField1) : this.initializedField2 = 0;
+  external static int staticField = 0;
+  external static final int finalStaticField = 0;
+}
+mixin B {
+  external static int staticField = 0;
+  external static final int finalStaticField = 0;
+}
+extension Extension ;
+on A (){ }
+main() { }
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.expect
new file mode 100644
index 0000000..895696f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.expect
@@ -0,0 +1,122 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:5:28: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external int topLevelField = 0;
+//                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:7:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external final int finalTopLevelField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:9:31: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external const int constField = 0;
+//                               ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:12:37: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:20:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:22:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:26:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:28:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:32:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int extensionInstanceField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:33:50: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external final int finalExtensionInstanceField = 0;
+//                                                  ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:34:44: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int extensionStaticField = 0;
+//                                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:35:55: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalExtensionStaticField = 0;
+//                                                       ^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  external get fieldWithInitializer() → core::int;
+  external set fieldWithInitializer(core::int #t3) → void;
+  external get initializedField1() → core::int;
+  external set initializedField1(core::int #t4) → void;
+  external get initializedField2() → core::int;
+  external set initializedField2(core::int #t5) → void;
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t6) → void;
+  external static get finalStaticField() → core::int;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t7) → void;
+  external static get finalStaticField() → core::int;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static get extensionStaticField = get self::Extension|extensionStaticField;
+  static set extensionStaticField = set self::Extension|extensionStaticField;
+  static get finalExtensionStaticField = get self::Extension|finalExtensionStaticField;
+}
+external static get topLevelField() → core::int;
+external static set topLevelField(core::int #t8) → void;
+external static get finalTopLevelField() → core::int;
+external static get constField() → core::int;
+external static set constField(core::int #t9) → void;
+external static get Extension|extensionInstanceField() → core::int;
+external static set Extension|extensionInstanceField(core::int #t10) → void;
+external static get Extension|finalExtensionInstanceField() → core::int;
+external static get Extension|extensionStaticField() → core::int;
+external static set Extension|extensionStaticField(core::int #t11) → void;
+external static get Extension|finalExtensionStaticField() → core::int;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.transformed.expect
new file mode 100644
index 0000000..895696f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_field_errors.dart.weak.transformed.expect
@@ -0,0 +1,122 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:5:28: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external int topLevelField = 0;
+//                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:7:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external final int finalTopLevelField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:9:31: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+// external const int constField = 0;
+//                               ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:12:37: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int fieldWithInitializer = 0;
+//                                     ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//          ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+// Try removing the field initializer or the 'external' keyword from the field declaration.
+//   A(this.initializedField1) : this.initializedField2 = 0;
+//                                    ^^^^^^^^^^^^^^^^^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:20:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:22:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:26:35: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int staticField = 0;
+//                                   ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:28:46: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalStaticField = 0;
+//                                              ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:32:39: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external int extensionInstanceField = 0;
+//                                       ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:33:50: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external final int finalExtensionInstanceField = 0;
+//                                                  ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:34:44: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static int extensionStaticField = 0;
+//                                            ^
+//
+// pkg/front_end/testcases/nnbd/external_field_errors.dart:35:55: Error: External fields cannot have initializers.
+// Try removing the initializer or the 'external' keyword.
+//   external static final int finalExtensionStaticField = 0;
+//                                                       ^
+//
+import self as self;
+import "dart:core" as core;
+
+abstract class A extends core::Object {
+  constructor •(core::int initializedField1) → self::A
+    : final dynamic #t1 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:10: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+         ^^^^^^^^^^^^^^^^^", final dynamic #t2 = invalid-expression "pkg/front_end/testcases/nnbd/external_field_errors.dart:18:36: Error: External fields cannot have initializers.
+Try removing the field initializer or the 'external' keyword from the field declaration.
+  A(this.initializedField1) : this.initializedField2 = 0;
+                                   ^^^^^^^^^^^^^^^^^"
+    ;
+  external get fieldWithInitializer() → core::int;
+  external set fieldWithInitializer(core::int #t3) → void;
+  external get initializedField1() → core::int;
+  external set initializedField1(core::int #t4) → void;
+  external get initializedField2() → core::int;
+  external set initializedField2(core::int #t5) → void;
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t6) → void;
+  external static get finalStaticField() → core::int;
+}
+abstract class B extends core::Object /*isMixinDeclaration*/  {
+  external static get staticField() → core::int;
+  external static set staticField(core::int #t7) → void;
+  external static get finalStaticField() → core::int;
+}
+extension Extension on self::A {
+  get extensionInstanceField = get self::Extension|extensionInstanceField;
+  set extensionInstanceField = set self::Extension|extensionInstanceField;
+  get finalExtensionInstanceField = get self::Extension|finalExtensionInstanceField;
+  static get extensionStaticField = get self::Extension|extensionStaticField;
+  static set extensionStaticField = set self::Extension|extensionStaticField;
+  static get finalExtensionStaticField = get self::Extension|finalExtensionStaticField;
+}
+external static get topLevelField() → core::int;
+external static set topLevelField(core::int #t8) → void;
+external static get finalTopLevelField() → core::int;
+external static get constField() → core::int;
+external static set constField(core::int #t9) → void;
+external static get Extension|extensionInstanceField() → core::int;
+external static set Extension|extensionInstanceField(core::int #t10) → void;
+external static get Extension|finalExtensionInstanceField() → core::int;
+external static get Extension|extensionStaticField() → core::int;
+external static set Extension|extensionStaticField(core::int #t11) → void;
+external static get Extension|finalExtensionStaticField() → core::int;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart b/pkg/front_end/testcases/nnbd/external_fields_spec.dart
new file mode 100644
index 0000000..c4e5f80
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart
@@ -0,0 +1,16 @@
+// 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.
+
+external int s1;
+external final fx;
+
+class A {
+  external int i1;
+  external covariant var cx;
+
+  external static int s1;
+  external static final fx;
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.outline.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.outline.expect
new file mode 100644
index 0000000..832b31d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.outline.expect
@@ -0,0 +1,20 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    ;
+  external get i1() → core::int;
+  external set i1(core::int #t1) → void;
+  external get cx() → dynamic;
+  external set cx(covariant dynamic #t2) → void;
+  external static get s1() → core::int;
+  external static set s1(core::int #t3) → void;
+  external static get fx() → dynamic;
+}
+external static get s1() → core::int;
+external static set s1(core::int #t4) → void;
+external static get fx() → dynamic;
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.expect
new file mode 100644
index 0000000..57dc59d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.expect
@@ -0,0 +1,20 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  external get i1() → core::int;
+  external set i1(core::int #t1) → void;
+  external get cx() → dynamic;
+  external set cx(covariant dynamic #t2) → void;
+  external static get s1() → core::int;
+  external static set s1(core::int #t3) → void;
+  external static get fx() → dynamic;
+}
+external static get s1() → core::int;
+external static set s1(core::int #t4) → void;
+external static get fx() → dynamic;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.transformed.expect
new file mode 100644
index 0000000..57dc59d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.strong.transformed.expect
@@ -0,0 +1,20 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  external get i1() → core::int;
+  external set i1(core::int #t1) → void;
+  external get cx() → dynamic;
+  external set cx(covariant dynamic #t2) → void;
+  external static get s1() → core::int;
+  external static set s1(core::int #t3) → void;
+  external static get fx() → dynamic;
+}
+external static get s1() → core::int;
+external static set s1(core::int #t4) → void;
+external static get fx() → dynamic;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.textual_outline.expect
new file mode 100644
index 0000000..bd0f4a6
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.textual_outline.expect
@@ -0,0 +1,9 @@
+external int s1;
+external final fx;
+class A {
+  external int i1;
+  external covariant var cx;
+  external static int s1;
+  external static final fx;
+}
+main() { }
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.expect
new file mode 100644
index 0000000..57dc59d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.expect
@@ -0,0 +1,20 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  external get i1() → core::int;
+  external set i1(core::int #t1) → void;
+  external get cx() → dynamic;
+  external set cx(covariant dynamic #t2) → void;
+  external static get s1() → core::int;
+  external static set s1(core::int #t3) → void;
+  external static get fx() → dynamic;
+}
+external static get s1() → core::int;
+external static set s1(core::int #t4) → void;
+external static get fx() → dynamic;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.transformed.expect
new file mode 100644
index 0000000..57dc59d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/external_fields_spec.dart.weak.transformed.expect
@@ -0,0 +1,20 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  external get i1() → core::int;
+  external set i1(core::int #t1) → void;
+  external get cx() → dynamic;
+  external set cx(covariant dynamic #t2) → void;
+  external static get s1() → core::int;
+  external static set s1(core::int #t3) → void;
+  external static get fx() → dynamic;
+}
+external static get s1() → core::int;
+external static set s1(core::int #t4) → void;
+external static get fx() → dynamic;
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline.expect
new file mode 100644
index 0000000..cfc22c4
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline.expect
@@ -0,0 +1,3 @@
+bool Function(T) predicate<T>(bool Function(T) fn) => (T val) => fn(val);
+void test() {}
+void main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..5bfe1f4
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41386.dart.textual_outline_modelled.expect
@@ -0,0 +1,3 @@
+bool Function(T) predicate<T>(bool Function(T) fn) => (T val) => fn(val);
+void main() {}
+void test() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline.expect
new file mode 100644
index 0000000..31c91a2
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline.expect
@@ -0,0 +1,2 @@
+void test() {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..4742c78
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41386b.dart.textual_outline_modelled.expect
@@ -0,0 +1,2 @@
+main() {}
+void test() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.expect
index 7b35002..fbcd99e 100644
--- a/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 // Future<bool> test5() => getFutureNull(); // error
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 //   Future<bool> test5() => getFutureNull(); // error
 //                           ^
@@ -48,7 +48,7 @@
 static method test4() → asy::Future<core::bool> async 
   return await self::getFutureNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::bool>;
 static method test5() → asy::Future<core::bool>
-  return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+  return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
 Future<bool> test5() => getFutureNull(); // error
                         ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
@@ -66,7 +66,7 @@
   function test4() → asy::Future<core::bool> async 
     return await self::getFutureNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::bool>;
   function test5() → asy::Future<core::bool>
-    return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+    return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
   Future<bool> test5() => getFutureNull(); // error
                           ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.transformed.expect
index 4efaadf..e54c5af 100644
--- a/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437a.dart.strong.transformed.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 // Future<bool> test5() => getFutureNull(); // error
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 //   Future<bool> test5() => getFutureNull(); // error
 //                           ^
@@ -150,7 +150,7 @@
   return :async_completer.{asy::Completer::future};
 }
 static method test5() → asy::Future<core::bool>
-  return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+  return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
 Future<bool> test5() => getFutureNull(); // error
                         ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
@@ -258,7 +258,7 @@
           return :async_completer.{asy::Completer::future};
         }
         function test5() → asy::Future<core::bool>
-          return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+          return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
   Future<bool> test5() => getFutureNull(); // error
                           ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.expect
index 7b35002..fbcd99e 100644
--- a/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 // Future<bool> test5() => getFutureNull(); // error
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 //   Future<bool> test5() => getFutureNull(); // error
 //                           ^
@@ -48,7 +48,7 @@
 static method test4() → asy::Future<core::bool> async 
   return await self::getFutureNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::bool>;
 static method test5() → asy::Future<core::bool>
-  return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+  return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
 Future<bool> test5() => getFutureNull(); // error
                         ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
@@ -66,7 +66,7 @@
   function test4() → asy::Future<core::bool> async 
     return await self::getFutureNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::bool>;
   function test5() → asy::Future<core::bool>
-    return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+    return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
   Future<bool> test5() => getFutureNull(); // error
                           ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.transformed.expect
index 4efaadf..e54c5af 100644
--- a/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437a.dart.weak.transformed.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 // Future<bool> test5() => getFutureNull(); // error
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
 //  - 'Future' is from 'dart:async'.
 //   Future<bool> test5() => getFutureNull(); // error
 //                           ^
@@ -150,7 +150,7 @@
   return :async_completer.{asy::Completer::future};
 }
 static method test5() → asy::Future<core::bool>
-  return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+  return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:18:25: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
 Future<bool> test5() => getFutureNull(); // error
                         ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
@@ -258,7 +258,7 @@
           return :async_completer.{asy::Completer::future};
         }
         function test5() → asy::Future<core::bool>
-          return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be assigned to a variable of type 'Future<bool>'.
+          return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437a.dart:27:27: Error: A value of type 'Future<dynamic>' can't be returned from a function with return type 'Future<bool>'.
  - 'Future' is from 'dart:async'.
   Future<bool> test5() => getFutureNull(); // error
                           ^" in self::getFutureNull() as{TypeError,ForNonNullableByDefault} asy::Future<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.expect
index 3c4069e..ca9e764 100644
--- a/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.expect
@@ -7,7 +7,7 @@
 //   yield* getIterableNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 // Iterable<bool> test5() => getIterableNull(); // error
 //                           ^
@@ -17,7 +17,7 @@
 //     yield* getIterableNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 //   Iterable<bool> test5() => getIterableNull(); // error
 //                             ^
@@ -62,7 +62,7 @@
          ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
 }
 static method test5() → core::Iterable<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
 Iterable<bool> test5() => getIterableNull(); // error
                           ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
@@ -86,7 +86,7 @@
            ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
   }
   function test5() → core::Iterable<core::bool>
-    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
   Iterable<bool> test5() => getIterableNull(); // error
                             ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.transformed.expect
index 17b627a..36cb9dd 100644
--- a/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.strong.transformed.expect
@@ -7,7 +7,7 @@
 //   yield* getIterableNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 // Iterable<bool> test5() => getIterableNull(); // error
 //                           ^
@@ -17,7 +17,7 @@
 //     yield* getIterableNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 //   Iterable<bool> test5() => getIterableNull(); // error
 //                             ^
@@ -115,7 +115,7 @@
   return new core::_SyncIterable::•<core::bool>(:sync_op_gen);
 }
 static method test5() → core::Iterable<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
 Iterable<bool> test5() => getIterableNull(); // error
                           ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
@@ -189,7 +189,7 @@
           return new core::_SyncIterable::•<core::bool>(:sync_op_gen);
         }
         function test5() → core::Iterable<core::bool>
-          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
   Iterable<bool> test5() => getIterableNull(); // error
                             ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline.expect
new file mode 100644
index 0000000..cec88c6
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline.expect
@@ -0,0 +1,12 @@
+dynamic getNull() => null;
+Iterable<dynamic> getIterableNull() sync* {}
+Iterable<bool> getIterableBool() sync* {}
+Iterable<bool> test1() sync* {}
+Iterable<bool> test2() => getNull();
+bool test3() => getNull();
+Iterable<bool> test4() sync* {}
+Iterable<bool> test5() => getIterableNull();
+Iterable<bool> test6() => getIterableBool();
+Iterable<bool> test7() sync* {}
+test() async {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..f215cc1
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.textual_outline_modelled.expect
@@ -0,0 +1,12 @@
+Iterable<bool> getIterableBool() sync* {}
+Iterable<bool> test1() sync* {}
+Iterable<bool> test2() => getNull();
+Iterable<bool> test4() sync* {}
+Iterable<bool> test5() => getIterableNull();
+Iterable<bool> test6() => getIterableBool();
+Iterable<bool> test7() sync* {}
+Iterable<dynamic> getIterableNull() sync* {}
+bool test3() => getNull();
+dynamic getNull() => null;
+main() {}
+test() async {}
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.expect
index 3c4069e..ca9e764 100644
--- a/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.expect
@@ -7,7 +7,7 @@
 //   yield* getIterableNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 // Iterable<bool> test5() => getIterableNull(); // error
 //                           ^
@@ -17,7 +17,7 @@
 //     yield* getIterableNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 //   Iterable<bool> test5() => getIterableNull(); // error
 //                             ^
@@ -62,7 +62,7 @@
          ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
 }
 static method test5() → core::Iterable<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
 Iterable<bool> test5() => getIterableNull(); // error
                           ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
@@ -86,7 +86,7 @@
            ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
   }
   function test5() → core::Iterable<core::bool>
-    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
   Iterable<bool> test5() => getIterableNull(); // error
                             ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.transformed.expect
index 17b627a..36cb9dd 100644
--- a/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437b.dart.weak.transformed.expect
@@ -7,7 +7,7 @@
 //   yield* getIterableNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 // Iterable<bool> test5() => getIterableNull(); // error
 //                           ^
@@ -17,7 +17,7 @@
 //     yield* getIterableNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
 //  - 'Iterable' is from 'dart:core'.
 //   Iterable<bool> test5() => getIterableNull(); // error
 //                             ^
@@ -115,7 +115,7 @@
   return new core::_SyncIterable::•<core::bool>(:sync_op_gen);
 }
 static method test5() → core::Iterable<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:24:27: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
 Iterable<bool> test5() => getIterableNull(); // error
                           ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
@@ -189,7 +189,7 @@
           return new core::_SyncIterable::•<core::bool>(:sync_op_gen);
         }
         function test5() → core::Iterable<core::bool>
-          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be assigned to a variable of type 'Iterable<bool>'.
+          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437b.dart:41:29: Error: A value of type 'Iterable<dynamic>' can't be returned from a function with return type 'Iterable<bool>'.
  - 'Iterable' is from 'dart:core'.
   Iterable<bool> test5() => getIterableNull(); // error
                             ^" in self::getIterableNull() as{TypeError,ForNonNullableByDefault} core::Iterable<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.expect
index 16b4fb1..c020c72 100644
--- a/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.expect
@@ -7,7 +7,7 @@
 //   yield* getStreamNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 // Stream<bool> test5() => getStreamNull(); // error
 //                         ^
@@ -17,7 +17,7 @@
 //     yield* getStreamNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 //   Stream<bool> test5() => getStreamNull(); // error
 //                           ^
@@ -63,7 +63,7 @@
          ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
 }
 static method test5() → asy::Stream<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
 Stream<bool> test5() => getStreamNull(); // error
                         ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
@@ -87,7 +87,7 @@
            ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
   }
   function test5() → asy::Stream<core::bool>
-    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
   Stream<bool> test5() => getStreamNull(); // error
                           ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.transformed.expect
index 06f62bb..71bc53a 100644
--- a/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.strong.transformed.expect
@@ -7,7 +7,7 @@
 //   yield* getStreamNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 // Stream<bool> test5() => getStreamNull(); // error
 //                         ^
@@ -17,7 +17,7 @@
 //     yield* getStreamNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 //   Stream<bool> test5() => getStreamNull(); // error
 //                           ^
@@ -191,7 +191,7 @@
   return :controller_stream;
 }
 static method test5() → asy::Stream<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
 Stream<bool> test5() => getStreamNull(); // error
                         ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
@@ -322,7 +322,7 @@
           return :controller_stream;
         }
         function test5() → asy::Stream<core::bool>
-          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
   Stream<bool> test5() => getStreamNull(); // error
                           ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline.expect
new file mode 100644
index 0000000..25fb625
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline.expect
@@ -0,0 +1,12 @@
+dynamic getNull() => null;
+Stream<dynamic> getStreamNull() async* {}
+Stream<bool> getStreamBool() async* {}
+Stream<bool> test1() async* {}
+Stream<bool> test2() => getNull();
+bool test3() => getNull();
+Stream<bool> test4() async* {}
+Stream<bool> test5() => getStreamNull();
+Stream<bool> test6() => getStreamBool();
+Stream<bool> test7() async* {}
+test() async {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..08bd153
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.textual_outline_modelled.expect
@@ -0,0 +1,12 @@
+Stream<bool> getStreamBool() async* {}
+Stream<bool> test1() async* {}
+Stream<bool> test2() => getNull();
+Stream<bool> test4() async* {}
+Stream<bool> test5() => getStreamNull();
+Stream<bool> test6() => getStreamBool();
+Stream<bool> test7() async* {}
+Stream<dynamic> getStreamNull() async* {}
+bool test3() => getNull();
+dynamic getNull() => null;
+main() {}
+test() async {}
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.expect
index 16b4fb1..c020c72 100644
--- a/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.expect
@@ -7,7 +7,7 @@
 //   yield* getStreamNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 // Stream<bool> test5() => getStreamNull(); // error
 //                         ^
@@ -17,7 +17,7 @@
 //     yield* getStreamNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 //   Stream<bool> test5() => getStreamNull(); // error
 //                           ^
@@ -63,7 +63,7 @@
          ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
 }
 static method test5() → asy::Stream<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
 Stream<bool> test5() => getStreamNull(); // error
                         ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
@@ -87,7 +87,7 @@
            ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
   }
   function test5() → asy::Stream<core::bool>
-    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
   Stream<bool> test5() => getStreamNull(); // error
                           ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.transformed.expect
index 06f62bb..71bc53a 100644
--- a/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41437c.dart.weak.transformed.expect
@@ -7,7 +7,7 @@
 //   yield* getStreamNull(); // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 // Stream<bool> test5() => getStreamNull(); // error
 //                         ^
@@ -17,7 +17,7 @@
 //     yield* getStreamNull(); // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+// pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
 //  - 'Stream' is from 'dart:async'.
 //   Stream<bool> test5() => getStreamNull(); // error
 //                           ^
@@ -191,7 +191,7 @@
   return :controller_stream;
 }
 static method test5() → asy::Stream<core::bool>
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:24:25: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
 Stream<bool> test5() => getStreamNull(); // error
                         ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
@@ -322,7 +322,7 @@
           return :controller_stream;
         }
         function test5() → asy::Stream<core::bool>
-          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be assigned to a variable of type 'Stream<bool>'.
+          return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/issue41437c.dart:41:27: Error: A value of type 'Stream<dynamic>' can't be returned from a function with return type 'Stream<bool>'.
  - 'Stream' is from 'dart:async'.
   Stream<bool> test5() => getStreamNull(); // error
                           ^" in self::getStreamNull() as{TypeError,ForNonNullableByDefault} asy::Stream<core::bool>;
diff --git a/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline.expect
new file mode 100644
index 0000000..1abae43
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline.expect
@@ -0,0 +1,4 @@
+void errors() {}
+void _takesObject(Object o) {}
+void _takesStackTrace(StackTrace o) {}
+void main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..10c705d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41520.dart.textual_outline_modelled.expect
@@ -0,0 +1,4 @@
+void _takesObject(Object o) {}
+void _takesStackTrace(StackTrace o) {}
+void errors() {}
+void main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline.expect
new file mode 100644
index 0000000..ec6b9e0
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline.expect
@@ -0,0 +1,2 @@
+test() {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..f67dbb0
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41700a.dart.textual_outline_modelled.expect
@@ -0,0 +1,2 @@
+main() {}
+test() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline.expect
new file mode 100644
index 0000000..54124f5
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline.expect
@@ -0,0 +1,4 @@
+class Null {}
+
+test() {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..6684200
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.textual_outline_modelled.expect
@@ -0,0 +1,4 @@
+class Null {}
+
+main() {}
+test() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart b/pkg/front_end/testcases/nnbd/issue42199.dart
new file mode 100644
index 0000000..92b4e35
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart
@@ -0,0 +1,9 @@
+// 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.
+
+class A {
+  operator ==(dynamic other);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.outline.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.outline.expect
new file mode 100644
index 0000000..46b84b0
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.outline.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    ;
+  abstract operator ==(dynamic other) → core::bool;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.strong.expect
new file mode 100644
index 0000000..3ae4f33
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.strong.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract operator ==(dynamic other) → core::bool;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.strong.transformed.expect
new file mode 100644
index 0000000..3ae4f33
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.strong.transformed.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract operator ==(dynamic other) → core::bool;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline.expect
new file mode 100644
index 0000000..d5032a7
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline.expect
@@ -0,0 +1,5 @@
+class A {
+  operator ==(dynamic other);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..d5032a7
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.textual_outline_modelled.expect
@@ -0,0 +1,5 @@
+class A {
+  operator ==(dynamic other);
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.weak.expect
new file mode 100644
index 0000000..3ae4f33
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.weak.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract operator ==(dynamic other) → core::bool;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42199.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue42199.dart.weak.transformed.expect
new file mode 100644
index 0000000..3ae4f33
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42199.dart.weak.transformed.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  abstract operator ==(dynamic other) → core::bool;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart b/pkg/front_end/testcases/nnbd/issue42540.dart
new file mode 100644
index 0000000..92a2d76
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart
@@ -0,0 +1,12 @@
+// 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.
+
+dynamic getNull() => null;
+
+Future<Object> fn() async {
+  Object o = await getNull();
+  return await getNull();
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.outline.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.outline.expect
new file mode 100644
index 0000000..51057a4
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.outline.expect
@@ -0,0 +1,11 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:async" as asy;
+import "dart:core" as core;
+
+static method getNull() → dynamic
+  ;
+static method fn() → asy::Future<core::Object> async 
+  ;
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.strong.expect
new file mode 100644
index 0000000..aaf931d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.strong.expect
@@ -0,0 +1,12 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:async" as asy;
+import "dart:core" as core;
+
+static method getNull() → dynamic
+  return null;
+static method fn() → asy::Future<core::Object> async {
+  core::Object o = await self::getNull() as{TypeError,ForDynamic,ForNonNullableByDefault} core::Object;
+  return await self::getNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::Object>;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.strong.transformed.expect
new file mode 100644
index 0000000..5fbd656
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.strong.transformed.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:async" as asy;
+import "dart:core" as core;
+
+static method getNull() → dynamic
+  return null;
+static method fn() → asy::Future<core::Object> /* originally async */ {
+  final asy::_AsyncAwaitCompleter<core::Object> :async_completer = new asy::_AsyncAwaitCompleter::•<core::Object>();
+  FutureOr<core::Object>? :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;
+  dynamic :saved_try_context_var0;
+  function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+    try {
+      #L1:
+      {
+        [yield] let dynamic #t1 = asy::_awaitHelper(self::getNull(), :async_op_then, :async_op_error, :async_op) in null;
+        core::Object o = let dynamic #t2 = :result in #t2.==(null) ?{core::Object} #t2 as{TypeError,ForDynamic,ForNonNullableByDefault} core::Object : #t2{core::Object};
+        [yield] let dynamic #t3 = asy::_awaitHelper(self::getNull(), :async_op_then, :async_op_error, :async_op) in null;
+        :return_value = let dynamic #t4 = :result in #t4.==(null) ?{FutureOr<core::Object>} #t4 as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::Object> : #t4{FutureOr<core::Object>};
+        break #L1;
+      }
+      asy::_completeOnAsyncReturn(:async_completer, :return_value);
+      return;
+    }
+    on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+      :async_completer.{asy::Completer::completeError}(exception, stack_trace);
+    }
+  :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+  :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+  :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+  :async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
+  return :async_completer.{asy::Completer::future};
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline.expect
new file mode 100644
index 0000000..326ff56
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline.expect
@@ -0,0 +1,3 @@
+dynamic getNull() => null;
+Future<Object> fn() async {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..a6184d9
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.textual_outline_modelled.expect
@@ -0,0 +1,3 @@
+Future<Object> fn() async {}
+dynamic getNull() => null;
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.weak.expect
new file mode 100644
index 0000000..aaf931d
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.weak.expect
@@ -0,0 +1,12 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:async" as asy;
+import "dart:core" as core;
+
+static method getNull() → dynamic
+  return null;
+static method fn() → asy::Future<core::Object> async {
+  core::Object o = await self::getNull() as{TypeError,ForDynamic,ForNonNullableByDefault} core::Object;
+  return await self::getNull() as{TypeError,ForDynamic,ForNonNullableByDefault} FutureOr<core::Object>;
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42540.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue42540.dart.weak.transformed.expect
new file mode 100644
index 0000000..ae9a451
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42540.dart.weak.transformed.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:async" as asy;
+import "dart:core" as core;
+
+static method getNull() → dynamic
+  return null;
+static method fn() → asy::Future<core::Object> /* originally async */ {
+  final asy::_AsyncAwaitCompleter<core::Object> :async_completer = new asy::_AsyncAwaitCompleter::•<core::Object>();
+  FutureOr<core::Object>? :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;
+  dynamic :saved_try_context_var0;
+  function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+    try {
+      #L1:
+      {
+        [yield] let dynamic #t1 = asy::_awaitHelper(self::getNull(), :async_op_then, :async_op_error, :async_op) in null;
+        core::Object o = :result;
+        [yield] let dynamic #t2 = asy::_awaitHelper(self::getNull(), :async_op_then, :async_op_error, :async_op) in null;
+        :return_value = :result;
+        break #L1;
+      }
+      asy::_completeOnAsyncReturn(:async_completer, :return_value);
+      return;
+    }
+    on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+      :async_completer.{asy::Completer::completeError}(exception, stack_trace);
+    }
+  :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+  :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+  :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+  :async_completer.{asy::_AsyncAwaitCompleter::start}(:async_op);
+  return :async_completer.{asy::Completer::future};
+}
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart b/pkg/front_end/testcases/nnbd/issue42546.dart
new file mode 100644
index 0000000..42ccf0c
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart
@@ -0,0 +1,17 @@
+// 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.
+
+// Based on tests/language/unsorted/flatten_test/12
+
+import 'dart:async';
+
+class Divergent<T> implements Future<Divergent<Divergent<T>>> {
+  noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
+}
+
+test() async {
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart.outline.expect b/pkg/front_end/testcases/nnbd/issue42546.dart.outline.expect
new file mode 100644
index 0000000..0f8217b
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart.outline.expect
@@ -0,0 +1,31 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
+
+class Divergent<T extends core::Object? = dynamic> extends core::Object implements asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>> {
+  synthetic constructor •() → self::Divergent<self::Divergent::T%>
+    ;
+  method noSuchMethod(core::Invocation invocation) → dynamic
+    ;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ catchError(core::Function onError, {(core::Object) →? core::bool test = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#catchError, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[onError]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#test: test}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ whenComplete(() → FutureOr<void>action) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#whenComplete, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ timeout(core::Duration timeLimit, {generic-covariant-impl () →? FutureOr<self::Divergent<self::Divergent<self::Divergent::T%>>>onTimeout = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#timeout, 0, const <core::Type*>[], core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onTimeout: onTimeout}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ then<R extends core::Object? = dynamic>((self::Divergent<self::Divergent<self::Divergent::T%>>) → FutureOr<self::Divergent::then::R%>onValue, {core::Function? onError = #C1}) → asy::Future<self::Divergent::then::R%>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#then, 0, core::List::unmodifiable<core::Type*>(<core::Type*>[self::Divergent::then::R%]), core::List::unmodifiable<dynamic>(<dynamic>[onValue]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#onError: onError}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent::then::R%>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ asStream() → asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#asStream, 0, const <core::Type*>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol*, dynamic>(const <core::Symbol*, dynamic>{}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+}
+static method test() → dynamic async 
+  ;
+static method main() → dynamic
+  ;
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue42546.dart.strong.expect
new file mode 100644
index 0000000..e5372a7
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart.strong.expect
@@ -0,0 +1,66 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/issue42546.dart:14:58: Error: A value of type 'Divergent<int>' can't be returned from an async function with return type 'Future<Divergent<Divergent<Divergent<int>>>>'.
+//  - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+//  - 'Future' is from 'dart:async'.
+//   Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+//                                                          ^
+//
+// pkg/front_end/testcases/nnbd/issue42546.dart:14:75: Error: A value of type 'Future<Divergent<Divergent<Divergent<int>>>>' can't be assigned to a variable of type 'Future<Divergent<Divergent<int>>>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+//   Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+//                                                                           ^
+//
+import self as self;
+import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
+
+class Divergent<T extends core::Object? = dynamic> extends core::Object implements asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>> {
+  synthetic constructor •() → self::Divergent<self::Divergent::T%>
+    : super core::Object::•()
+    ;
+  method noSuchMethod(core::Invocation invocation) → dynamic
+    return super.{core::Object::noSuchMethod}(invocation);
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ catchError(core::Function onError, {(core::Object) →? core::bool test = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C2, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[onError]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C4: test}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ whenComplete(() → FutureOr<void>action) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ timeout(core::Duration timeLimit, {generic-covariant-impl () →? FutureOr<self::Divergent<self::Divergent<self::Divergent::T%>>>onTimeout = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C9: onTimeout}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ then<R extends core::Object? = dynamic>((self::Divergent<self::Divergent<self::Divergent::T%>>) → FutureOr<self::Divergent::then::R%>onValue, {core::Function? onError = #C1}) → asy::Future<self::Divergent::then::R%>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C10, 0, core::List::unmodifiable<core::Type*>(<core::Type*>[self::Divergent::then::R%]), core::List::unmodifiable<dynamic>(<dynamic>[onValue]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C11: onError}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent::then::R%>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ asStream() → asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C12, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+}
+static method test() → dynamic async {
+  asy::Future<self::Divergent<self::Divergent<core::int>>> x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue42546.dart:14:75: Error: A value of type 'Future<Divergent<Divergent<Divergent<int>>>>' can't be assigned to a variable of type 'Future<Divergent<Divergent<int>>>'.
+ - 'Future' is from 'dart:async'.
+ - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+                                                                          ^" in (() → asy::Future<self::Divergent<self::Divergent<self::Divergent<core::int>>>> async => let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue42546.dart:14:58: Error: A value of type 'Divergent<int>' can't be returned from an async function with return type 'Future<Divergent<Divergent<Divergent<int>>>>'.
+ - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+ - 'Future' is from 'dart:async'.
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+                                                         ^" in new self::Divergent::•<core::int>() as{TypeError,ForNonNullableByDefault} self::Divergent<self::Divergent<self::Divergent<core::int>>>).call() as{TypeError,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<core::int>>>;
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+  #C2 = #catchError
+  #C3 = <core::Type*>[]
+  #C4 = #test
+  #C5 = #whenComplete
+  #C6 = <dynamic>[]
+  #C7 = core::_ImmutableMap<core::Symbol*, dynamic> {_kvPairs:#C6}
+  #C8 = #timeout
+  #C9 = #onTimeout
+  #C10 = #then
+  #C11 = #onError
+  #C12 = #asStream
+}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline.expect
new file mode 100644
index 0000000..0303360
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline.expect
@@ -0,0 +1,8 @@
+import 'dart:async';
+
+class Divergent<T> implements Future<Divergent<Divergent<T>>> {
+  noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
+}
+
+test() async {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..5198cb8
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart.textual_outline_modelled.expect
@@ -0,0 +1,8 @@
+import 'dart:async';
+
+class Divergent<T> implements Future<Divergent<Divergent<T>>> {
+  noSuchMethod(Invocation invocation) => super.noSuchMethod(invocation);
+}
+
+main() {}
+test() async {}
diff --git a/pkg/front_end/testcases/nnbd/issue42546.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue42546.dart.weak.expect
new file mode 100644
index 0000000..e5372a7
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/issue42546.dart.weak.expect
@@ -0,0 +1,66 @@
+library /*isNonNullableByDefault*/;
+//
+// Problems in library:
+//
+// pkg/front_end/testcases/nnbd/issue42546.dart:14:58: Error: A value of type 'Divergent<int>' can't be returned from an async function with return type 'Future<Divergent<Divergent<Divergent<int>>>>'.
+//  - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+//  - 'Future' is from 'dart:async'.
+//   Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+//                                                          ^
+//
+// pkg/front_end/testcases/nnbd/issue42546.dart:14:75: Error: A value of type 'Future<Divergent<Divergent<Divergent<int>>>>' can't be assigned to a variable of type 'Future<Divergent<Divergent<int>>>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+//   Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+//                                                                           ^
+//
+import self as self;
+import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
+
+class Divergent<T extends core::Object? = dynamic> extends core::Object implements asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>> {
+  synthetic constructor •() → self::Divergent<self::Divergent::T%>
+    : super core::Object::•()
+    ;
+  method noSuchMethod(core::Invocation invocation) → dynamic
+    return super.{core::Object::noSuchMethod}(invocation);
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ catchError(core::Function onError, {(core::Object) →? core::bool test = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C2, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[onError]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C4: test}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ whenComplete(() → FutureOr<void>action) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C5, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[action]), core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ timeout(core::Duration timeLimit, {generic-covariant-impl () →? FutureOr<self::Divergent<self::Divergent<self::Divergent::T%>>>onTimeout = #C1}) → asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C8, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[timeLimit]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C9: onTimeout}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ then<R extends core::Object? = dynamic>((self::Divergent<self::Divergent<self::Divergent::T%>>) → FutureOr<self::Divergent::then::R%>onValue, {core::Function? onError = #C1}) → asy::Future<self::Divergent::then::R%>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C10, 0, core::List::unmodifiable<core::Type*>(<core::Type*>[self::Divergent::then::R%]), core::List::unmodifiable<dynamic>(<dynamic>[onValue]), core::Map::unmodifiable<core::Symbol*, dynamic>(<core::Symbol*, dynamic>{#C11: onError}))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Future<self::Divergent::then::R%>;
+  no-such-method-forwarder method /* from org-dartlang-sdk:///sdk/lib/async/future.dart */ asStream() → asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>
+    return this.{self::Divergent::noSuchMethod}(new core::_InvocationMirror::_withType(#C12, 0, #C3, #C6, core::Map::unmodifiable<core::Symbol*, dynamic>(#C7))) as{TypeError,ForDynamic,ForNonNullableByDefault} asy::Stream<self::Divergent<self::Divergent<self::Divergent::T%>>>;
+}
+static method test() → dynamic async {
+  asy::Future<self::Divergent<self::Divergent<core::int>>> x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue42546.dart:14:75: Error: A value of type 'Future<Divergent<Divergent<Divergent<int>>>>' can't be assigned to a variable of type 'Future<Divergent<Divergent<int>>>'.
+ - 'Future' is from 'dart:async'.
+ - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+                                                                          ^" in (() → asy::Future<self::Divergent<self::Divergent<self::Divergent<core::int>>>> async => let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/issue42546.dart:14:58: Error: A value of type 'Divergent<int>' can't be returned from an async function with return type 'Future<Divergent<Divergent<Divergent<int>>>>'.
+ - 'Divergent' is from 'pkg/front_end/testcases/nnbd/issue42546.dart'.
+ - 'Future' is from 'dart:async'.
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())();
+                                                         ^" in new self::Divergent::•<core::int>() as{TypeError,ForNonNullableByDefault} self::Divergent<self::Divergent<self::Divergent<core::int>>>).call() as{TypeError,ForNonNullableByDefault} asy::Future<self::Divergent<self::Divergent<core::int>>>;
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+  #C2 = #catchError
+  #C3 = <core::Type*>[]
+  #C4 = #test
+  #C5 = #whenComplete
+  #C6 = <dynamic>[]
+  #C7 = core::_ImmutableMap<core::Symbol*, dynamic> {_kvPairs:#C6}
+  #C8 = #timeout
+  #C9 = #onTimeout
+  #C10 = #then
+  #C11 = #onError
+  #C12 = #asStream
+}
diff --git a/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline.expect
new file mode 100644
index 0000000..54bd347
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline.expect
@@ -0,0 +1,6 @@
+propertyGet(Never never) {}
+propertySet(Never never) {}
+methodInvocation(Never never, Invocation invocation) {}
+equals(Never never) {}
+operator(Never never) {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..4dcbb4a
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/never_calls.dart.textual_outline_modelled.expect
@@ -0,0 +1,6 @@
+equals(Never never) {}
+main() {}
+methodInvocation(Never never, Invocation invocation) {}
+operator(Never never) {}
+propertyGet(Never never) {}
+propertySet(Never never) {}
diff --git a/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline.expect
new file mode 100644
index 0000000..a38ad66
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline.expect
@@ -0,0 +1,2 @@
+test(Never nonNullableNever, Never? nullableNever) {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..d9aa494
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/never_equals.dart.textual_outline_modelled.expect
@@ -0,0 +1,2 @@
+main() {}
+test(Never nonNullableNever, Never? nullableNever) {}
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart b/pkg/front_end/testcases/nnbd/nullable_setter.dart
new file mode 100644
index 0000000..8e9d230
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart
@@ -0,0 +1,32 @@
+// Copyright (c) 2019, 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.
+
+class C {
+  String m = "";
+  void set setter(String v) {}
+  void operator []=(int index, String value) {}
+}
+
+extension on C? {
+  void set setter(String v) {
+    this?.m = v;
+  }
+
+  void operator []=(int index, String value) {
+    this?.m = '$index$value';
+  }
+}
+
+main() {
+  C? c = new C();
+  expect("", c?.m);
+  c.setter = "42";
+  expect("42", c?.m);
+  c[42] = "87";
+  expect("4287", c?.m);
+}
+
+expect(expected, actual) {
+  if (expected != actual) throw 'Expected $expected, actual $actual';
+}
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.outline.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.outline.expect
new file mode 100644
index 0000000..3f88610
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.outline.expect
@@ -0,0 +1,25 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class C extends core::Object {
+  field core::String m;
+  synthetic constructor •() → self::C
+    ;
+  set setter(core::String v) → void
+    ;
+  operator []=(core::int index, core::String value) → void
+    ;
+}
+extension _extension#0 on self::C? {
+  operator []= = self::_extension#0|[]=;
+  set setter = self::_extension#0|set#setter;
+}
+static method _extension#0|set#setter(final self::C? #this, core::String v) → void
+  ;
+static method _extension#0|[]=(final self::C? #this, core::int index, core::String value) → void
+  ;
+static method main() → dynamic
+  ;
+static method expect(dynamic expected, dynamic actual) → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.expect
new file mode 100644
index 0000000..d367854
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.expect
@@ -0,0 +1,34 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class C extends core::Object {
+  field core::String m = "";
+  synthetic constructor •() → self::C
+    : super core::Object::•()
+    ;
+  set setter(core::String v) → void {}
+  operator []=(core::int index, core::String value) → void {}
+}
+extension _extension#0 on self::C? {
+  operator []= = self::_extension#0|[]=;
+  set setter = self::_extension#0|set#setter;
+}
+static method _extension#0|set#setter(final self::C? #this, core::String v) → void {
+  let final self::C? #t1 = #this in #t1.{core::Object::==}(null) ?{core::String?} null : #t1{self::C}.{self::C::m} = v;
+}
+static method _extension#0|[]=(final self::C? #this, core::int index, core::String value) → void {
+  let final self::C? #t2 = #this in #t2.{core::Object::==}(null) ?{core::String?} null : #t2{self::C}.{self::C::m} = "${index}${value}";
+}
+static method main() → dynamic {
+  self::C? c = new self::C::•();
+  self::expect("", let final self::C? #t3 = c in #t3.{core::Object::==}(null) ?{core::String?} null : #t3{self::C}.{self::C::m});
+  self::_extension#0|set#setter(c, "42");
+  self::expect("42", let final self::C? #t4 = c in #t4.{core::Object::==}(null) ?{core::String?} null : #t4{self::C}.{self::C::m});
+  self::_extension#0|[]=(c, 42, "87");
+  self::expect("4287", let final self::C? #t5 = c in #t5.{core::Object::==}(null) ?{core::String?} null : #t5{self::C}.{self::C::m});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.transformed.expect
new file mode 100644
index 0000000..d367854
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.strong.transformed.expect
@@ -0,0 +1,34 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class C extends core::Object {
+  field core::String m = "";
+  synthetic constructor •() → self::C
+    : super core::Object::•()
+    ;
+  set setter(core::String v) → void {}
+  operator []=(core::int index, core::String value) → void {}
+}
+extension _extension#0 on self::C? {
+  operator []= = self::_extension#0|[]=;
+  set setter = self::_extension#0|set#setter;
+}
+static method _extension#0|set#setter(final self::C? #this, core::String v) → void {
+  let final self::C? #t1 = #this in #t1.{core::Object::==}(null) ?{core::String?} null : #t1{self::C}.{self::C::m} = v;
+}
+static method _extension#0|[]=(final self::C? #this, core::int index, core::String value) → void {
+  let final self::C? #t2 = #this in #t2.{core::Object::==}(null) ?{core::String?} null : #t2{self::C}.{self::C::m} = "${index}${value}";
+}
+static method main() → dynamic {
+  self::C? c = new self::C::•();
+  self::expect("", let final self::C? #t3 = c in #t3.{core::Object::==}(null) ?{core::String?} null : #t3{self::C}.{self::C::m});
+  self::_extension#0|set#setter(c, "42");
+  self::expect("42", let final self::C? #t4 = c in #t4.{core::Object::==}(null) ?{core::String?} null : #t4{self::C}.{self::C::m});
+  self::_extension#0|[]=(c, 42, "87");
+  self::expect("4287", let final self::C? #t5 = c in #t5.{core::Object::==}(null) ?{core::String?} null : #t5{self::C}.{self::C::m});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.textual_outline.expect
new file mode 100644
index 0000000..c1aeb83
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.textual_outline.expect
@@ -0,0 +1,10 @@
+class C {
+  String m = "";
+  void set setter(String v) { }
+  void operator []=(int index, String value) { }
+}
+extension on ;
+C;
+? { void set setter(String v) { this?.m = v; } void operator []=(int index, String value) { this?.m = '$index$value'; } }
+main() { }
+expect(expected, actual) { }
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.expect
new file mode 100644
index 0000000..d367854
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.expect
@@ -0,0 +1,34 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class C extends core::Object {
+  field core::String m = "";
+  synthetic constructor •() → self::C
+    : super core::Object::•()
+    ;
+  set setter(core::String v) → void {}
+  operator []=(core::int index, core::String value) → void {}
+}
+extension _extension#0 on self::C? {
+  operator []= = self::_extension#0|[]=;
+  set setter = self::_extension#0|set#setter;
+}
+static method _extension#0|set#setter(final self::C? #this, core::String v) → void {
+  let final self::C? #t1 = #this in #t1.{core::Object::==}(null) ?{core::String?} null : #t1{self::C}.{self::C::m} = v;
+}
+static method _extension#0|[]=(final self::C? #this, core::int index, core::String value) → void {
+  let final self::C? #t2 = #this in #t2.{core::Object::==}(null) ?{core::String?} null : #t2{self::C}.{self::C::m} = "${index}${value}";
+}
+static method main() → dynamic {
+  self::C? c = new self::C::•();
+  self::expect("", let final self::C? #t3 = c in #t3.{core::Object::==}(null) ?{core::String?} null : #t3{self::C}.{self::C::m});
+  self::_extension#0|set#setter(c, "42");
+  self::expect("42", let final self::C? #t4 = c in #t4.{core::Object::==}(null) ?{core::String?} null : #t4{self::C}.{self::C::m});
+  self::_extension#0|[]=(c, 42, "87");
+  self::expect("4287", let final self::C? #t5 = c in #t5.{core::Object::==}(null) ?{core::String?} null : #t5{self::C}.{self::C::m});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
diff --git a/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.transformed.expect
new file mode 100644
index 0000000..d367854
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/nullable_setter.dart.weak.transformed.expect
@@ -0,0 +1,34 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class C extends core::Object {
+  field core::String m = "";
+  synthetic constructor •() → self::C
+    : super core::Object::•()
+    ;
+  set setter(core::String v) → void {}
+  operator []=(core::int index, core::String value) → void {}
+}
+extension _extension#0 on self::C? {
+  operator []= = self::_extension#0|[]=;
+  set setter = self::_extension#0|set#setter;
+}
+static method _extension#0|set#setter(final self::C? #this, core::String v) → void {
+  let final self::C? #t1 = #this in #t1.{core::Object::==}(null) ?{core::String?} null : #t1{self::C}.{self::C::m} = v;
+}
+static method _extension#0|[]=(final self::C? #this, core::int index, core::String value) → void {
+  let final self::C? #t2 = #this in #t2.{core::Object::==}(null) ?{core::String?} null : #t2{self::C}.{self::C::m} = "${index}${value}";
+}
+static method main() → dynamic {
+  self::C? c = new self::C::•();
+  self::expect("", let final self::C? #t3 = c in #t3.{core::Object::==}(null) ?{core::String?} null : #t3{self::C}.{self::C::m});
+  self::_extension#0|set#setter(c, "42");
+  self::expect("42", let final self::C? #t4 = c in #t4.{core::Object::==}(null) ?{core::String?} null : #t4{self::C}.{self::C::m});
+  self::_extension#0|[]=(c, 42, "87");
+  self::expect("4287", let final self::C? #t5 = c in #t5.{core::Object::==}(null) ?{core::String?} null : #t5{self::C}.{self::C::m});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
diff --git a/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline.expect
new file mode 100644
index 0000000..f56a0d9
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline.expect
@@ -0,0 +1,6 @@
+class A<T> {
+  T? _current;
+  T get current => _current as T;
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..268c668
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/redundant_type_casts.dart.textual_outline_modelled.expect
@@ -0,0 +1,6 @@
+class A<T> {
+  T get current => _current as T;
+  T? _current;
+}
+
+main() {}
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 b9743eb..ec3912f 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 assigned to a variable of type 'String'.
+// 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'.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //     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 assigned to a variable of type 'String'.
+// 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'.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //       return null; // error
 //              ^
 //
@@ -82,14 +82,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 assigned to a variable of type 'String'.
+  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'.
   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 assigned to a variable of type 'String'.
+    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'.
     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 assigned to a variable of type 'String'.
+    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'.
     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 assigned to a variable of type 'String'.
+      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'.
       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 e9cbf0c..e697630 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 assigned to a variable of type 'String'.
+// 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'.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //     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 assigned to a variable of type 'String'.
+// 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'.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //       return null; // error
 //              ^
 //
@@ -82,14 +82,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 assigned to a variable of type 'String'.
+  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'.
   return null; // error
          ^" in let core::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 assigned to a variable of type 'String'.
+    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'.
     return null; // error
            ^" in let core::Null? #t5 = null in #t5.==(null) ?{core::String} #t5 as{TypeError,ForNonNullableByDefault} core::String : #t5{core::String};
   }
@@ -351,14 +351,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 assigned to a variable of type 'String'.
+    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'.
     return null; // error
            ^" in let core::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 assigned to a variable of type 'String'.
+      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'.
       return null; // error
              ^" in let core::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 c0505b5..2aff0f0 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 assigned to a variable of type 'String'.
+// 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'.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //     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 assigned to a variable of type 'String'.
+// 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'.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //       return null; // error
 //              ^
 //
@@ -82,14 +82,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 assigned to a variable of type 'String'.
+  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'.
   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 assigned to a variable of type 'String'.
+    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'.
     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 assigned to a variable of type 'String'.
+    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'.
     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 assigned to a variable of type 'String'.
+      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'.
       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 755ad61..e888a45 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 assigned to a variable of type 'String'.
+// 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'.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //     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 assigned to a variable of type 'String'.
+// 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'.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be assigned to a variable of type 'String'.
+// 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'.
 //       return null; // error
 //              ^
 //
@@ -82,14 +82,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 assigned to a variable of type 'String'.
+  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'.
   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 assigned to a variable of type 'String'.
+    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'.
     return null; // error
            ^" in null;
   }
@@ -351,14 +351,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 assigned to a variable of type 'String'.
+    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'.
     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 assigned to a variable of type 'String'.
+      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'.
       return null; // error
              ^" in null;
     }
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/.dart_tool/package_config.json b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/.dart_tool/package_config.json
new file mode 100644
index 0000000..c312198
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "opt_out_package",
+      "rootUri": "../opt_out_package/lib/",
+      "languageVersion": "2.7"
+    },
+    {
+      "name": "opt_in_package",
+      "rootUri": "../opt_in_package/lib/"
+    }
+
+  ]
+}
\ No newline at end of file
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/link.options b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/link.options
new file mode 100644
index 0000000..5d06f3f
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/link.options
@@ -0,0 +1,5 @@
+package:opt_in_package/opt_in_lib.dart
+package:opt_in_package/opt_out_lib.dart
+package:opt_out_package/regular_lib1.dart
+package:opt_out_package/regular_lib2.dart
+--nnbd-weak
\ No newline at end of file
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_in_lib.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_in_lib.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_in_lib.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_out_lib.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_out_lib.dart
new file mode 100644
index 0000000..3ceddc3
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_in_package/lib/opt_out_lib.dart
@@ -0,0 +1,5 @@
+// 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.7
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib1.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib1.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib1.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib2.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib2.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/opt_out_package/lib/regular_lib2.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart
new file mode 100644
index 0000000..f3ef4f5
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart
@@ -0,0 +1,10 @@
+// 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 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.outline.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.outline.expect
new file mode 100644
index 0000000..0c8bca3
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.outline.expect
@@ -0,0 +1,22 @@
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_in_package/opt_out_lib.dart
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.expect
new file mode 100644
index 0000000..ce5b6e5
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.expect
@@ -0,0 +1,21 @@
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_in_package/opt_out_lib.dart
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.transformed.expect
new file mode 100644
index 0000000..ce5b6e5
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.strong.transformed.expect
@@ -0,0 +1,21 @@
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_in_package/opt_out_lib.dart
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline.expect
new file mode 100644
index 0000000..3127540
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline.expect
@@ -0,0 +1,6 @@
+import 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..3127540
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.textual_outline_modelled.expect
@@ -0,0 +1,6 @@
+import 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.expect
new file mode 100644
index 0000000..ba7e12e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.expect
@@ -0,0 +1,9 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.transformed.expect
new file mode 100644
index 0000000..ba7e12e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_dill/strong.dart.weak.transformed.expect
@@ -0,0 +1,9 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/.dart_tool/package_config.json b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/.dart_tool/package_config.json
new file mode 100644
index 0000000..c312198
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "opt_out_package",
+      "rootUri": "../opt_out_package/lib/",
+      "languageVersion": "2.7"
+    },
+    {
+      "name": "opt_in_package",
+      "rootUri": "../opt_in_package/lib/"
+    }
+
+  ]
+}
\ No newline at end of file
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_in_lib.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_in_lib.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_in_lib.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_out_lib.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_out_lib.dart
new file mode 100644
index 0000000..3ceddc3
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_out_lib.dart
@@ -0,0 +1,5 @@
+// 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.7
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib1.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib1.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib1.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib2.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib2.dart
new file mode 100644
index 0000000..a08c72e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_out_package/lib/regular_lib2.dart
@@ -0,0 +1,3 @@
+// 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.
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart
new file mode 100644
index 0000000..f3ef4f5
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart
@@ -0,0 +1,10 @@
+// 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 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.outline.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.outline.expect
new file mode 100644
index 0000000..6d4bfe9
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.outline.expect
@@ -0,0 +1,28 @@
+//
+// Problems outside component:
+//
+// pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_out_lib.dart:5:1: Error: A library can't opt out of null safety by default, when using sound null safety.
+// // @dart=2.7
+// ^^^^^^^^^^^^
+//
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.expect
new file mode 100644
index 0000000..45dd453
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.expect
@@ -0,0 +1,27 @@
+//
+// Problems outside component:
+//
+// pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/opt_in_package/lib/opt_out_lib.dart:5:1: Error: A library can't opt out of null safety by default, when using sound null safety.
+// // @dart=2.7
+// ^^^^^^^^^^^^
+//
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.transformed.expect
new file mode 100644
index 0000000..0134870
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.strong.transformed.expect
@@ -0,0 +1,20 @@
+//
+// Problems in component:
+//
+// Error: Cannot run with sound null safety as one or more dependencies do not
+// support null safety:
+//
+//  - package:opt_out_package
+//
+// Run 'pub outdated --mode=null-safety' to determine if versions of your
+// dependencies supporting null safety are available.
+//
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline.expect
new file mode 100644
index 0000000..3127540
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline.expect
@@ -0,0 +1,6 @@
+import 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..3127540
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.textual_outline_modelled.expect
@@ -0,0 +1,6 @@
+import 'package:opt_in_package/opt_in_lib.dart';
+import 'package:opt_in_package/opt_out_lib.dart';
+import 'package:opt_out_package/regular_lib1.dart';
+import 'package:opt_out_package/regular_lib2.dart';
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.expect
new file mode 100644
index 0000000..ba7e12e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.expect
@@ -0,0 +1,9 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.transformed.expect
new file mode 100644
index 0000000..ba7e12e
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/strong_package_not_ok_from_source/strong.dart.weak.transformed.expect
@@ -0,0 +1,9 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+
+import "package:opt_in_package/opt_in_lib.dart";
+import "package:opt_in_package/opt_out_lib.dart";
+import "package:opt_out_package/regular_lib1.dart";
+import "package:opt_out_package/regular_lib2.dart";
+
+static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline.expect
new file mode 100644
index 0000000..fa80f6b
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline.expect
@@ -0,0 +1,7 @@
+class C<X> {
+  C(void Function(X) x);
+}
+
+T check<T>(C<List<T>> f) {}
+void test() {}
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..bf84124
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/type_constraint_solving_closures_in_upper_and_lower_bounds.dart.textual_outline_modelled.expect
@@ -0,0 +1,8 @@
+T check<T>(C<List<T>> f) {}
+
+class C<X> {
+  C(void Function(X) x);
+}
+
+main() {}
+void test() {}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_basic_types_lib.dart b/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_basic_types_lib.dart
index c2736fd..0984f7c 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_basic_types_lib.dart
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_basic_types_lib.dart
@@ -2,6 +2,6 @@
 // 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
+// @dart = 2.10
 
 typedef Future<Null> AsyncCallback();
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_binding_lib.dart b/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_binding_lib.dart
index a1fb380..9666c88 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_binding_lib.dart
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42387/foundation_binding_lib.dart
@@ -2,7 +2,7 @@
 // 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
+// @dart = 2.10
 
 import 'foundation_basic_types_lib.dart';
 
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660.dart b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart
new file mode 100644
index 0000000..0d300c0
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660.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.8
+import 'issue42660_lib.dart';
+
+void main() {
+  f().m();
+  (f)().m();
+  p.m();
+  var c = new Class();
+  c.f().m();
+  (c.f)().m();
+  c.p.m();
+  c[0].m();
+  (-c).m();
+  (c + 4).m();
+  c..p.m()..f().m()..[0].m();
+  new Class()..p.m()..f().m()..[0].m();
+}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline.expect
new file mode 100644
index 0000000..a163495
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline.expect
@@ -0,0 +1,4 @@
+// @dart = 2.8
+import 'issue42660_lib.dart';
+
+void main() {}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..a163495
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.textual_outline_modelled.expect
@@ -0,0 +1,4 @@
+// @dart = 2.8
+import 'issue42660_lib.dart';
+
+void main() {}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.expect
new file mode 100644
index 0000000..88ec031
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.expect
@@ -0,0 +1,65 @@
+library;
+import self as self;
+import "issue42660_lib.dart" as iss;
+import "dart:core" as core;
+
+import "org-dartlang-testcase:///issue42660_lib.dart";
+
+static method main() → void {
+  iss::E|m(iss::f());
+  iss::E|m((#C1).call());
+  iss::E|m(iss::p);
+  iss::Class<dynamic>* c = new iss::Class::•<dynamic>();
+  iss::E|m(c.{iss::Class::f}());
+  iss::E|m(c.{iss::Class::f}.call());
+  iss::E|m(c.{iss::Class::p});
+  iss::E|m(c.{iss::Class::[]}(0));
+  iss::E|m(c.{iss::Class::unary-}());
+  iss::E|m(c.{iss::Class::+}(4));
+  let final iss::Class<dynamic>* #t1 = c in block {
+    iss::E|m(#t1.{iss::Class::p});
+    iss::E|m(#t1.{iss::Class::f}());
+    iss::E|m(#t1.{iss::Class::[]}(0));
+  } =>#t1;
+  let final iss::Class<dynamic>* #t2 = new iss::Class::•<dynamic>() in block {
+    iss::E|m(#t2.{iss::Class::p});
+    iss::E|m(#t2.{iss::Class::f}());
+    iss::E|m(#t2.{iss::Class::[]}(0));
+  } =>#t2;
+}
+
+library /*isNonNullableByDefault*/;
+import self as iss;
+import "dart:core" as core;
+
+class Class<T extends core::Object? = dynamic> extends core::Object {
+  synthetic constructor •() → iss::Class<iss::Class::T%>
+    : super core::Object::•()
+    ;
+  method f() → core::int?
+    return 4;
+  get p() → core::int?
+    return 4;
+  operator [](core::int index) → core::int?
+    return 4;
+  operator unary-() → core::int?
+    return 4;
+  operator +(core::Object? other) → core::int?
+    return 4;
+}
+extension E on core::int {
+  method m = iss::E|m;
+  tearoff m = iss::E|get#m;
+}
+static method E|m(final core::int #this) → core::String
+  return "m";
+static method E|get#m(final core::int #this) → () → core::String
+  return () → core::String => iss::E|m(#this);
+static method f() → core::int?
+  return 4;
+static get p() → core::int?
+  return 4;
+
+constants  {
+  #C1 = tearoff iss::f
+}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.transformed.expect
new file mode 100644
index 0000000..88ec031
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660.dart.weak.transformed.expect
@@ -0,0 +1,65 @@
+library;
+import self as self;
+import "issue42660_lib.dart" as iss;
+import "dart:core" as core;
+
+import "org-dartlang-testcase:///issue42660_lib.dart";
+
+static method main() → void {
+  iss::E|m(iss::f());
+  iss::E|m((#C1).call());
+  iss::E|m(iss::p);
+  iss::Class<dynamic>* c = new iss::Class::•<dynamic>();
+  iss::E|m(c.{iss::Class::f}());
+  iss::E|m(c.{iss::Class::f}.call());
+  iss::E|m(c.{iss::Class::p});
+  iss::E|m(c.{iss::Class::[]}(0));
+  iss::E|m(c.{iss::Class::unary-}());
+  iss::E|m(c.{iss::Class::+}(4));
+  let final iss::Class<dynamic>* #t1 = c in block {
+    iss::E|m(#t1.{iss::Class::p});
+    iss::E|m(#t1.{iss::Class::f}());
+    iss::E|m(#t1.{iss::Class::[]}(0));
+  } =>#t1;
+  let final iss::Class<dynamic>* #t2 = new iss::Class::•<dynamic>() in block {
+    iss::E|m(#t2.{iss::Class::p});
+    iss::E|m(#t2.{iss::Class::f}());
+    iss::E|m(#t2.{iss::Class::[]}(0));
+  } =>#t2;
+}
+
+library /*isNonNullableByDefault*/;
+import self as iss;
+import "dart:core" as core;
+
+class Class<T extends core::Object? = dynamic> extends core::Object {
+  synthetic constructor •() → iss::Class<iss::Class::T%>
+    : super core::Object::•()
+    ;
+  method f() → core::int?
+    return 4;
+  get p() → core::int?
+    return 4;
+  operator [](core::int index) → core::int?
+    return 4;
+  operator unary-() → core::int?
+    return 4;
+  operator +(core::Object? other) → core::int?
+    return 4;
+}
+extension E on core::int {
+  method m = iss::E|m;
+  tearoff m = iss::E|get#m;
+}
+static method E|m(final core::int #this) → core::String
+  return "m";
+static method E|get#m(final core::int #this) → () → core::String
+  return () → core::String => iss::E|m(#this);
+static method f() → core::int?
+  return 4;
+static get p() → core::int?
+  return 4;
+
+constants  {
+  #C1 = tearoff iss::f
+}
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42660_lib.dart b/pkg/front_end/testcases/nnbd_mixed/issue42660_lib.dart
new file mode 100644
index 0000000..7207237
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42660_lib.dart
@@ -0,0 +1,24 @@
+// 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.10
+
+extension E on int {
+  String m() => 'm';
+}
+
+int? f() => 4;
+
+int? get p => 4;
+
+class Class<T> {
+  int? f() => 4;
+  int? get p => 4;
+
+  int? operator [](int index) => 4;
+
+  int? operator -() => 4;
+
+  int? operator +(Object? other) => 4;
+}
diff --git a/pkg/front_end/testcases/nnbd_mixed/never_opt_out.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/never_opt_out.dart.weak.expect
index ad7f2b8..620ed33 100644
--- a/pkg/front_end/testcases/nnbd_mixed/never_opt_out.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/never_opt_out.dart.weak.expect
@@ -60,11 +60,11 @@
   abstract member-signature get runtimeType() → core::Type*;
 }
 static field Never* optOutNever;
-static field core::Null? inferredOptOutNever = nev::optInNever;
+static field dynamic inferredOptOutNever = nev::optInNever;
 static method main() → dynamic {
   Never* localNever = null;
   core::Null? localNull = null;
-  Never* inferredLocalNever = nev::optInNever;
+  dynamic inferredLocalNever = nev::optInNever;
   localNever = localNever;
   self::optOutNever = localNever;
   nev::optInNever = localNever;
@@ -73,13 +73,13 @@
   inferredLocalNever = localNever;
   localNever = self::optOutNever;
   self::optOutNever = self::optOutNever;
-  nev::optInNever = self::optOutNever;
+  nev::optInNever = self::optOutNever as{TypeError} Never;
   localNull = self::optOutNever;
   self::inferredOptOutNever = self::optOutNever;
   inferredLocalNever = self::optOutNever;
   localNever = nev::optInNever;
   self::optOutNever = nev::optInNever;
-  nev::optInNever = nev::optInNever;
+  nev::optInNever = nev::optInNever as{TypeError} Never;
   localNull = nev::optInNever;
   self::inferredOptOutNever = nev::optInNever;
   inferredLocalNever = nev::optInNever;
@@ -89,24 +89,24 @@
   localNull = localNull;
   self::inferredOptOutNever = localNull;
   inferredLocalNever = localNull;
-  localNever = self::inferredOptOutNever;
-  self::optOutNever = self::inferredOptOutNever;
-  nev::optInNever = self::inferredOptOutNever as{TypeError} Never;
-  localNull = self::inferredOptOutNever;
+  localNever = self::inferredOptOutNever as{TypeError,ForDynamic} Never*;
+  self::optOutNever = self::inferredOptOutNever as{TypeError,ForDynamic} Never*;
+  nev::optInNever = self::inferredOptOutNever as{TypeError,ForDynamic} Never;
+  localNull = self::inferredOptOutNever as{TypeError,ForDynamic} core::Null?;
   self::inferredOptOutNever = self::inferredOptOutNever;
   inferredLocalNever = self::inferredOptOutNever;
-  localNever = inferredLocalNever;
-  self::optOutNever = inferredLocalNever;
-  nev::optInNever = inferredLocalNever;
-  localNull = inferredLocalNever;
+  localNever = inferredLocalNever as{TypeError,ForDynamic} Never*;
+  self::optOutNever = inferredLocalNever as{TypeError,ForDynamic} Never*;
+  nev::optInNever = inferredLocalNever as{TypeError,ForDynamic} Never;
+  localNull = inferredLocalNever as{TypeError,ForDynamic} core::Null?;
   self::inferredOptOutNever = inferredLocalNever;
   inferredLocalNever = inferredLocalNever;
-  self::throws(() → Never* => self::optOutNever = nev::throwing());
-  self::throws(() → Never* => localNever = nev::throwing());
-  self::throws(() → Never* => self::optOutNever = nev::throwing());
-  self::throws(() → Never* => nev::optInNever = nev::throwing());
-  self::throws(() → Never* => self::inferredOptOutNever = nev::throwing());
-  self::throws(() → Never* => inferredLocalNever = nev::throwing());
+  self::throws(() → core::Null? => self::optOutNever = nev::throwing());
+  self::throws(() → core::Null? => localNever = nev::throwing());
+  self::throws(() → core::Null? => self::optOutNever = nev::throwing());
+  self::throws(() → core::Null? => nev::optInNever = nev::throwing() as{TypeError} Never);
+  self::throws(() → core::Null? => self::inferredOptOutNever = nev::throwing());
+  self::throws(() → core::Null? => inferredLocalNever = nev::throwing());
 }
 static method throws(() →* void f) → dynamic {
   try {
@@ -122,7 +122,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd_mixed/never_opt_out_lib.dart:19:28: Error: A value of type 'Type' can't be assigned to a variable of type 'Null'.
+// pkg/front_end/testcases/nnbd_mixed/never_opt_out_lib.dart:19:28: Error: A value of type 'Type' can't be returned from a function with return type 'Null'.
 //  - 'Type' is from 'dart:core'.
 //   Null get nullProperty => Null;
 //                            ^
@@ -147,7 +147,7 @@
   method nullMethod(core::Null? value) → core::Null?
     return value;
   get nullProperty() → core::Null?
-    return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/never_opt_out_lib.dart:19:28: Error: A value of type 'Type' can't be assigned to a variable of type 'Null'.
+    return let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/never_opt_out_lib.dart:19:28: Error: A value of type 'Type' can't be returned from a function with return type 'Null'.
  - 'Type' is from 'dart:core'.
   Null get nullProperty => Null;
                            ^" in core::Null? as{TypeError,ForNonNullableByDefault} core::Null?;
diff --git a/pkg/front_end/testcases/outline.status b/pkg/front_end/testcases/outline.status
index cfe04cd..f58f9fe 100644
--- a/pkg/front_end/testcases/outline.status
+++ b/pkg/front_end/testcases/outline.status
@@ -17,6 +17,7 @@
 general/covariant_field: TypeCheckError
 general/infer_field_from_multiple: TypeCheckError
 general/invalid_operator: TypeCheckError
+general/invalid_operator_override: TypeCheckError
 general/issue41210a: TypeCheckError
 general/issue41210b/issue41210: TypeCheckError
 general/mixin_application_override: TypeCheckError
diff --git a/pkg/front_end/testcases/strong.status b/pkg/front_end/testcases/strong.status
index bf4a5ea..66d7125 100644
--- a/pkg/front_end/testcases/strong.status
+++ b/pkg/front_end/testcases/strong.status
@@ -65,6 +65,7 @@
 general/incomplete_field_formal_parameter: RuntimeError
 general/infer_field_from_multiple: TypeCheckError
 general/invalid_operator: TypeCheckError
+general/invalid_operator_override: TypeCheckError
 general/invocations: RuntimeError
 general/issue37776: RuntimeError
 general/issue38938: RuntimeError # no main and compile time errors.
@@ -171,10 +172,12 @@
 late_lowering/covariant_late_field: TypeCheckError
 nnbd/covariant_late_field: TypeCheckError
 nnbd/issue41180: RuntimeError # Strong mode runtime checking fails due to mixed strong mode.
+nnbd/issue42546: TypeCheckError
 nnbd/nullable_object_access: TypeCheckError
 nnbd/nullable_receiver: TypeCheckError
 nnbd/potentially_nullable_access: TypeCheckError
 nnbd/strong_lib_not_ok_from_dill/strong: RuntimeError
+nnbd/strong_package_not_ok_from_dill/strong: RuntimeError
 rasta/abstract_constructor: RuntimeError
 rasta/bad_constructor_redirection: RuntimeError
 rasta/bad_continue: RuntimeError
diff --git a/pkg/front_end/testcases/text_serialization.status b/pkg/front_end/testcases/text_serialization.status
index 5b10647..d31841a 100644
--- a/pkg/front_end/testcases/text_serialization.status
+++ b/pkg/front_end/testcases/text_serialization.status
@@ -65,6 +65,7 @@
 general/incomplete_field_formal_parameter: RuntimeError
 general/infer_field_from_multiple: TypeCheckError
 general/invalid_operator: TypeCheckError
+general/invalid_operator_override: TypeCheckError
 general/invocations: RuntimeError
 general/issue37776: RuntimeError
 general/issue38938: RuntimeError
@@ -169,10 +170,12 @@
 late_lowering/covariant_late_field: TypeCheckError
 nnbd/covariant_late_field: TypeCheckError
 nnbd/issue41180: RuntimeError
+nnbd/issue42546: TypeCheckError
 nnbd/nullable_object_access: TypeCheckError
 nnbd/nullable_receiver: TypeCheckError
 nnbd/potentially_nullable_access: TypeCheckError
 nnbd/strong_lib_not_ok_from_dill/strong: RuntimeError
+nnbd/strong_package_not_ok_from_dill/strong: RuntimeError
 rasta/abstract_constructor: RuntimeError
 rasta/bad_constructor_redirection: RuntimeError
 rasta/bad_continue: RuntimeError
diff --git a/pkg/front_end/testcases/weak.status b/pkg/front_end/testcases/weak.status
index 332439cd..80dbc59 100644
--- a/pkg/front_end/testcases/weak.status
+++ b/pkg/front_end/testcases/weak.status
@@ -60,6 +60,7 @@
 general_nnbd_opt_out/void_methods: RuntimeError
 late_lowering/covariant_late_field: TypeCheckError
 nnbd/covariant_late_field: TypeCheckError
+nnbd/issue42546: TypeCheckError
 nnbd/nullable_object_access: TypeCheckError
 nnbd/nullable_receiver: TypeCheckError
 nnbd/potentially_nullable_access: TypeCheckError
diff --git a/pkg/front_end/tool/_fasta/command_line.dart b/pkg/front_end/tool/_fasta/command_line.dart
index 7433302..950515e 100644
--- a/pkg/front_end/tool/_fasta/command_line.dart
+++ b/pkg/front_end/tool/_fasta/command_line.dart
@@ -197,6 +197,7 @@
   Flags.verbose: const BoolValue(false),
   Flags.verify: const BoolValue(false),
   Flags.linkDependencies: const UriListValue(),
+  Flags.noDeps: const BoolValue(false),
   "-D": const DefineValue(),
   "-h": const AliasValue(Flags.help),
   "--out": const AliasValue(Flags.output),
@@ -256,6 +257,8 @@
 
   final bool noDefines = options[Flags.noDefines];
 
+  final bool noDeps = options[Flags.noDeps];
+
   final bool verify = options[Flags.verify];
 
   final bool dumpIr = options[Flags.dumpIr];
@@ -341,7 +344,8 @@
     ..experimentalFlags = experimentalFlags
     ..environmentDefines = noDefines ? null : parsedArguments.defines
     ..nnbdMode = nnbdMode
-    ..additionalDills = linkDependencies;
+    ..additionalDills = linkDependencies
+    ..emitDeps = !noDeps;
 
   if (programName == "compile_platform") {
     if (arguments.length != 5) {
diff --git a/pkg/front_end/tool/_fasta/entry_points.dart b/pkg/front_end/tool/_fasta/entry_points.dart
index 0b082f9..1a4399f2 100644
--- a/pkg/front_end/tool/_fasta/entry_points.dart
+++ b/pkg/front_end/tool/_fasta/entry_points.dart
@@ -434,17 +434,19 @@
 
   c.options.ticker.logMs("Wrote component to ${fullOutput.toFilePath()}");
 
-  List<Uri> deps = result.deps.toList();
-  for (Uri dependency in await computeHostDependencies(hostPlatform)) {
-    // Add the dependencies of the compiler's own sources.
-    if (dependency != outlineOutput) {
-      // We're computing the dependencies for [outlineOutput], so we shouldn't
-      // include it in the deps file.
-      deps.add(dependency);
+  if (c.options.emitDeps) {
+    List<Uri> deps = result.deps.toList();
+    for (Uri dependency in await computeHostDependencies(hostPlatform)) {
+      // Add the dependencies of the compiler's own sources.
+      if (dependency != outlineOutput) {
+        // We're computing the dependencies for [outlineOutput], so we shouldn't
+        // include it in the deps file.
+        deps.add(dependency);
+      }
     }
+    await writeDepsFile(fullOutput,
+        new File(new File.fromUri(fullOutput).path + ".d").uri, deps);
   }
-  await writeDepsFile(
-      fullOutput, new File(new File.fromUri(fullOutput).path + ".d").uri, deps);
 }
 
 Future<List<Uri>> computeHostDependencies(Uri hostPlatform) async {
diff --git a/pkg/frontend_server/lib/frontend_server.dart b/pkg/frontend_server/lib/frontend_server.dart
index d9e4fbf..35f5631 100644
--- a/pkg/frontend_server/lib/frontend_server.dart
+++ b/pkg/frontend_server/lib/frontend_server.dart
@@ -154,10 +154,8 @@
       help: 'Include only bytecode into the output file', defaultsTo: true)
   ..addFlag('enable-asserts',
       help: 'Whether asserts will be enabled.', defaultsTo: false)
-  ..addFlag('null-safety',
-      help:
-          'Respect the nullability of types at runtime in casts and instance checks.',
-      defaultsTo: null)
+  ..addFlag('sound-null-safety',
+      help: 'Respect the nullability of types at runtime.', defaultsTo: null)
   ..addMultiOption('enable-experiment',
       help: 'Comma separated list of experimental features, eg set-literals.',
       hide: true)
@@ -172,7 +170,7 @@
   ..addOption('libraries-spec',
       help: 'A path or uri to the libraries specification JSON file')
   ..addFlag('debugger-module-names',
-      help: 'Use debugger-friendly modules names', defaultsTo: false)
+      help: 'Use debugger-friendly modules names', defaultsTo: true)
   ..addFlag('experimental-emit-debug-metadata',
       help: 'Emit module and library metadata for the debugger',
       defaultsTo: false)
@@ -407,6 +405,7 @@
     final String platformKernelDill =
         options['platform'] ?? 'platform_strong.dill';
     final String packagesOption = _options['packages'];
+    final bool nullSafety = _options['sound-null-safety'];
     final CompilerOptions compilerOptions = CompilerOptions()
       ..sdkRoot = sdkRoot
       ..fileSystem = _fileSystem
@@ -418,8 +417,7 @@
       ..experimentalFlags = parseExperimentalFlags(
           parseExperimentalArguments(options['enable-experiment']),
           onError: (msg) => errors.add(msg))
-      ..nnbdMode =
-          (options['null-safety'] == true) ? NnbdMode.Strong : NnbdMode.Weak
+      ..nnbdMode = (nullSafety == true) ? NnbdMode.Strong : NnbdMode.Weak
       ..onDiagnostic = _onDiagnostic;
 
     if (options.wasParsed('libraries-spec')) {
@@ -469,7 +467,7 @@
       }
     }
 
-    if (options['null-safety'] == null &&
+    if (nullSafety == null &&
         compilerOptions.experimentalFlags[ExperimentalFlag.nonNullable]) {
       await autoDetectNullSafetyMode(_mainSource, compilerOptions);
     }
diff --git a/pkg/frontend_server/test/frontend_server_test.dart b/pkg/frontend_server/test/frontend_server_test.dart
index a042a1e..d4b17b7 100644
--- a/pkg/frontend_server/test/frontend_server_test.dart
+++ b/pkg/frontend_server/test/frontend_server_test.dart
@@ -1490,7 +1490,6 @@
         '--output-dill=${dillFile.path}',
         '--target=dartdevc',
         '--packages=${tempDir.path}/.packages',
-        '--debugger-module-names'
       ];
 
       final StreamController<List<int>> streamController =
@@ -1557,7 +1556,6 @@
         '--output-dill=${dillFile.path}',
         '--target=dartdevc',
         '--packages=${tempDir.path}/.packages',
-        '--debugger-module-names',
         '--experimental-emit-debug-metadata'
       ];
 
@@ -1621,7 +1619,6 @@
         '--output-dill=${dillFile.path}',
         '--target=dartdevc',
         '--packages=${tempDir.path}/.packages',
-        '--debugger-module-names'
       ];
 
       final StreamController<List<int>> streamController =
@@ -1729,7 +1726,6 @@
         '--output-dill=${dillFile.path}',
         '--target=dartdevc',
         '--packages=${tempDir.path}/.packages',
-        '--debugger-module-names'
       ];
 
       final StreamController<List<int>> streamController =
diff --git a/pkg/frontend_server/test/src/expression_compiler_test.dart b/pkg/frontend_server/test/src/expression_compiler_test.dart
index 52b309c..245118a 100644
--- a/pkg/frontend_server/test/src/expression_compiler_test.dart
+++ b/pkg/frontend_server/test/src/expression_compiler_test.dart
@@ -1129,9 +1129,10 @@
         var k = Key('t');
         MyClass c = MyClass(0);
         int p = 1;
+        const t = 1;
 
         /* evaluation placeholder */
-        print('\$c, \$k');
+        print('\$c, \$k, \$t');
       }
       ''';
 
@@ -1158,19 +1159,33 @@
           ''');
     });
 
-    test('evaluate const expression', () async {
+    test('evaluate new const expression', () async {
       await driver.check(
           scope: <String, String>{'p': '1'},
           expression: 'const MyClass(1)',
           expectedResult: '''
           (function(p) {
-            return dart.const(new foo.MyClass.new(1));
+            return C0 || CT.C0;
           }(
           1
           ))
           ''');
     });
 
+    test('evaluate optimized const expression', () async {
+      await driver.check(
+          scope: <String, String>{},
+          expression: 't',
+          expectedResult: '''
+          (function() {
+            return 1;
+          }(
+          ))
+          ''');
+    },
+        skip:
+            'Cannot compile constants optimized away by the frontend'); // https://github.com/dart-lang/sdk/issues/41999
+
     test('evaluate factory constructor call', () async {
       await driver.check(
           scope: <String, String>{'p': '1'},
@@ -1182,9 +1197,7 @@
           1
           ))
           ''');
-    },
-        skip:
-            'Incorrect kernel for factory constructor call'); // https://github.com/dart-lang/sdk/issues/41976
+    });
 
     test('evaluate const factory constructor call', () async {
       await driver.check(
@@ -1192,14 +1205,12 @@
           expression: "const Key('t')",
           expectedResult: '''
           (function(p) {
-            return dart.const(new foo.ValueKey.new("t"));
+            return C0 || CT.C0;
           }(
           1
           ))
           ''');
-    },
-        skip:
-            'Incorrect kernel for factory constructor call'); // https://github.com/dart-lang/sdk/issues/41976
+    });
   });
 
   return 0;
diff --git a/pkg/js/CHANGELOG.md b/pkg/js/CHANGELOG.md
index 05ef42f..a996ef1 100644
--- a/pkg/js/CHANGELOG.md
+++ b/pkg/js/CHANGELOG.md
@@ -1,4 +1,4 @@
-## 0.6.3-dev
+## 0.6.3-nullsafety
 
 * Opt in to null safety.
 
diff --git a/pkg/js/pubspec.yaml b/pkg/js/pubspec.yaml
index 24616bf..67165c3 100644
--- a/pkg/js/pubspec.yaml
+++ b/pkg/js/pubspec.yaml
@@ -1,10 +1,10 @@
 name: js
-version: 0.6.3-dev
+version: 0.6.3-nullsafety
 description: Annotations to create static Dart interfaces for JavaScript APIs.
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/js
 
 environment:
-  sdk: '>=2.9.0-1 <3.0.0'
+  sdk: '>=2.10.0-0 <2.10.0'
 
 dev_dependencies:
   pedantic: ^1.9.0
diff --git a/pkg/kernel/bin/transform.dart b/pkg/kernel/bin/transform.dart
index bec347f..7a1036d 100755
--- a/pkg/kernel/bin/transform.dart
+++ b/pkg/kernel/bin/transform.dart
@@ -101,7 +101,11 @@
     case 'constants':
       final VmConstantsBackend backend = new VmConstantsBackend(coreTypes);
       component = constants.transformComponent(component, backend, defines,
-          const constants.SimpleErrorReporter(), constants.EvaluationMode.weak);
+          const constants.SimpleErrorReporter(), constants.EvaluationMode.weak,
+          desugarSets: false,
+          evaluateAnnotations: true,
+          enableTripleShift: false,
+          errorOnUnevaluatedConstant: false);
       break;
     case 'empty':
       component = empty.transformComponent(component);
diff --git a/pkg/kernel/lib/ast.dart b/pkg/kernel/lib/ast.dart
index 89a0398..ad82c3c 100644
--- a/pkg/kernel/lib/ast.dart
+++ b/pkg/kernel/lib/ast.dart
@@ -1471,7 +1471,7 @@
       {this.name,
       List<TypeParameter> typeParameters,
       this.onType,
-      List<Reference> members,
+      List<ExtensionMemberDescriptor> members,
       this.fileUri,
       Reference reference})
       : this.typeParameters = typeParameters ?? <TypeParameter>[],
diff --git a/pkg/kernel/lib/default_language_version.dart b/pkg/kernel/lib/default_language_version.dart
index cd5308e..6b7b18c 100644
--- a/pkg/kernel/lib/default_language_version.dart
+++ b/pkg/kernel/lib/default_language_version.dart
@@ -9,4 +9,4 @@
 
 import "ast.dart";
 
-Version defaultLanguageVersion = const Version(2, 9);
+Version defaultLanguageVersion = const Version(2, 10);
diff --git a/pkg/kernel/lib/target/targets.dart b/pkg/kernel/lib/target/targets.dart
index 5ef2712..1253b7d 100644
--- a/pkg/kernel/lib/target/targets.dart
+++ b/pkg/kernel/lib/target/targets.dart
@@ -96,7 +96,7 @@
   /// is the initializer of a [Field] or [VariableDeclaration] node.
   /// If this method returns `true`, the variable will be inlined at all
   /// points of reference and the variable itself removed (unless overridden
-  /// by the `keepFields` or `keepVariables` flag to the constant transformer).
+  /// by the `keepFields` or `keepLocals` properties).
   /// This method must be deterministic, i.e. it must always return the same
   /// value for the same constant value and place in the AST.
   bool shouldInlineConstant(ConstantExpression initializer) => true;
@@ -109,6 +109,18 @@
   /// This defaults to `false` since it requires additional work for a backend
   /// to support unevaluated constants.
   bool get supportsUnevaluatedConstants => false;
+
+  /// If `true` constant [Field] declarations are not removed from the AST even
+  /// when use-sites are inlined.
+  ///
+  /// All use-sites will be rewritten based on [shouldInlineConstant].
+  bool get keepFields => true;
+
+  /// If `true` constant [VariableDeclaration]s are not removed from the AST
+  /// even when use-sites are inlined.
+  ///
+  /// All use-sites will be rewritten based on [shouldInlineConstant].
+  bool get keepLocals => false;
 }
 
 /// A target provides backend-specific options for generating kernel IR.
diff --git a/pkg/kernel/lib/text/serializer_combinators.dart b/pkg/kernel/lib/text/serializer_combinators.dart
index 30eb6a3..39435d7 100644
--- a/pkg/kernel/lib/text/serializer_combinators.dart
+++ b/pkg/kernel/lib/text/serializer_combinators.dart
@@ -17,25 +17,30 @@
 
   final Map<String, T> binders = <String, T>{};
 
-  final Set<String> usedNames;
+  final Map<T, String> distinctNames = new Map<T, String>.identity();
 
-  DeserializationEnvironment(this.parent)
-      : usedNames = parent?.usedNames?.toSet() ?? new Set<String>();
+  DeserializationEnvironment(this.parent);
 
   T lookup(String name) => locals[name] ?? parent?.lookup(name);
 
-  T addBinder(String name, T node) {
-    if (usedNames.contains(name)) {
-      throw StateError("Name '${name}' is already declared in this scope.");
+  T addBinder(T node, String distinctName) {
+    if (lookupDistinctName(node) != null) {
+      throw StateError(
+          "Name '${distinctName}' is already declared in this scope.");
     }
-    usedNames.add(name);
-    return binders[name] = node;
+    distinctNames[node] = distinctName;
+    return binders[distinctName] = node;
   }
 
-  void close() {
+  // TODO(dmitryas): Consider combining with [addBinder] into a single method.
+  void extend() {
     locals.addAll(binders);
     binders.clear();
   }
+
+  String lookupDistinctName(T object) {
+    return distinctNames[object] ?? parent?.lookupDistinctName(object);
+  }
 }
 
 class SerializationEnvironment<T extends Node> {
@@ -47,33 +52,55 @@
 
   int nameCount;
 
+  Map<T, String> distinctNames = new Map<T, String>.identity();
+
   SerializationEnvironment(this.parent) : nameCount = parent?.nameCount ?? 0;
 
   String lookup(T node) => locals[node] ?? parent?.lookup(node);
 
-  String addBinder(T node, String name) {
+  String addBinder(T node, {String nameClue}) {
     final String separator = "^";
     final int codeOfZero = "0".codeUnitAt(0);
     final int codeOfNine = "9".codeUnitAt(0);
 
-    int prefixLength = name.length - 1;
-    bool isOnlyDigits = true;
-    while (prefixLength >= 0 && name[prefixLength] != separator) {
-      int code = name.codeUnitAt(prefixLength);
-      isOnlyDigits = isOnlyDigits && (codeOfZero <= code && code <= codeOfNine);
-      --prefixLength;
+    String prefix;
+    if (nameClue != null) {
+      int prefixLength = nameClue.length - 1;
+      bool isOnlyDigits = true;
+      while (prefixLength >= 0 && nameClue[prefixLength] != separator) {
+        int code = nameClue.codeUnitAt(prefixLength);
+        isOnlyDigits =
+            isOnlyDigits && (codeOfZero <= code && code <= codeOfNine);
+        --prefixLength;
+      }
+      if (prefixLength < 0 || !isOnlyDigits) {
+        prefixLength = nameClue.length;
+      }
+      prefix = nameClue.substring(0, prefixLength);
+    } else {
+      prefix = "ID";
     }
-    if (prefixLength < 0 || !isOnlyDigits) {
-      prefixLength = name.length;
-    }
-    String prefix = name.substring(0, prefixLength);
-    return binders[node] = "$prefix$separator${nameCount++}";
+    String distinctName = "$prefix$separator${nameCount++}";
+    // The following checks for an internal error, not an error caused by the user.
+    // So, an assert is used instead of an exception.
+    assert(
+        lookupDistinctName(node) == null,
+        "Can't assign distinct name '${distinctName}' "
+        "to an object of kind '${node.runtimeType}': "
+        "it's already known by name '${lookupDistinctName(node)}'.");
+    distinctNames[node] = distinctName;
+    return binders[node] = distinctName;
   }
 
-  void close() {
+  // TODO(dmitryas): Consider combining with [addBinder] into a single method.
+  void extend() {
     locals.addAll(binders);
     binders.clear();
   }
+
+  String lookupDistinctName(T object) {
+    return distinctNames[object] ?? parent?.lookupDistinctName(object);
+  }
 }
 
 class DeserializationState {
@@ -203,7 +230,7 @@
 // They require a function mapping serializables to a tag string.  This is
 // implemented by Tagger visitors.
 // A tagged union of serializer/deserializers.
-class Case<T extends Node> extends TextSerializer<T> {
+class Case<T> extends TextSerializer<T> {
   final Tagger<T> tagger;
   final List<String> _tags;
   final List<TextSerializer<T>> _serializers;
@@ -312,7 +339,7 @@
   void writeTo(
       StringBuffer buffer, Tuple2<T1, T2> object, SerializationState state) {
     first.writeTo(buffer, object.first, state);
-    buffer.write(' ');
+    if (!second.isEmpty) buffer.write(' ');
     second.writeTo(buffer, object.second, state);
   }
 }
@@ -340,9 +367,9 @@
   void writeTo(StringBuffer buffer, Tuple3<T1, T2, T3> object,
       SerializationState state) {
     first.writeTo(buffer, object.first, state);
-    buffer.write(' ');
+    if (!second.isEmpty) buffer.write(' ');
     second.writeTo(buffer, object.second, state);
-    buffer.write(' ');
+    if (!third.isEmpty) buffer.write(' ');
     third.writeTo(buffer, object.third, state);
   }
 }
@@ -376,11 +403,11 @@
   void writeTo(StringBuffer buffer, Tuple4<T1, T2, T3, T4> object,
       SerializationState state) {
     first.writeTo(buffer, object.first, state);
-    buffer.write(' ');
+    if (!second.isEmpty) buffer.write(' ');
     second.writeTo(buffer, object.second, state);
-    buffer.write(' ');
+    if (!third.isEmpty) buffer.write(' ');
     third.writeTo(buffer, object.third, state);
-    buffer.write(' ');
+    if (!fourth.isEmpty) buffer.write(' ');
     fourth.writeTo(buffer, object.fourth, state);
   }
 }
@@ -394,6 +421,158 @@
   const Tuple4(this.first, this.second, this.third, this.fourth);
 }
 
+class Tuple5Serializer<T1, T2, T3, T4, T5>
+    extends TextSerializer<Tuple5<T1, T2, T3, T4, T5>> {
+  final TextSerializer<T1> first;
+  final TextSerializer<T2> second;
+  final TextSerializer<T3> third;
+  final TextSerializer<T4> fourth;
+  final TextSerializer<T5> fifth;
+
+  const Tuple5Serializer(
+      this.first, this.second, this.third, this.fourth, this.fifth);
+
+  Tuple5<T1, T2, T3, T4, T5> readFrom(
+      Iterator<Object> stream, DeserializationState state) {
+    return new Tuple5(
+        first.readFrom(stream, state),
+        second.readFrom(stream, state),
+        third.readFrom(stream, state),
+        fourth.readFrom(stream, state),
+        fifth.readFrom(stream, state));
+  }
+
+  void writeTo(StringBuffer buffer, Tuple5<T1, T2, T3, T4, T5> object,
+      SerializationState state) {
+    first.writeTo(buffer, object.first, state);
+    if (!second.isEmpty) buffer.write(' ');
+    second.writeTo(buffer, object.second, state);
+    if (!third.isEmpty) buffer.write(' ');
+    third.writeTo(buffer, object.third, state);
+    if (!fourth.isEmpty) buffer.write(' ');
+    fourth.writeTo(buffer, object.fourth, state);
+    if (!fifth.isEmpty) buffer.write(' ');
+    fifth.writeTo(buffer, object.fifth, state);
+  }
+}
+
+class Tuple5<T1, T2, T3, T4, T5> {
+  final T1 first;
+  final T2 second;
+  final T3 third;
+  final T4 fourth;
+  final T5 fifth;
+
+  const Tuple5(this.first, this.second, this.third, this.fourth, this.fifth);
+}
+
+class Tuple6Serializer<T1, T2, T3, T4, T5, T6>
+    extends TextSerializer<Tuple6<T1, T2, T3, T4, T5, T6>> {
+  final TextSerializer<T1> first;
+  final TextSerializer<T2> second;
+  final TextSerializer<T3> third;
+  final TextSerializer<T4> fourth;
+  final TextSerializer<T5> fifth;
+  final TextSerializer<T6> sixth;
+
+  const Tuple6Serializer(
+      this.first, this.second, this.third, this.fourth, this.fifth, this.sixth);
+
+  Tuple6<T1, T2, T3, T4, T5, T6> readFrom(
+      Iterator<Object> stream, DeserializationState state) {
+    return new Tuple6(
+        first.readFrom(stream, state),
+        second.readFrom(stream, state),
+        third.readFrom(stream, state),
+        fourth.readFrom(stream, state),
+        fifth.readFrom(stream, state),
+        sixth.readFrom(stream, state));
+  }
+
+  void writeTo(StringBuffer buffer, Tuple6<T1, T2, T3, T4, T5, T6> object,
+      SerializationState state) {
+    first.writeTo(buffer, object.first, state);
+    if (!second.isEmpty) buffer.write(' ');
+    second.writeTo(buffer, object.second, state);
+    if (!third.isEmpty) buffer.write(' ');
+    third.writeTo(buffer, object.third, state);
+    if (!fourth.isEmpty) buffer.write(' ');
+    fourth.writeTo(buffer, object.fourth, state);
+    if (!fifth.isEmpty) buffer.write(' ');
+    fifth.writeTo(buffer, object.fifth, state);
+    if (!sixth.isEmpty) buffer.write(' ');
+    sixth.writeTo(buffer, object.sixth, state);
+  }
+}
+
+class Tuple6<T1, T2, T3, T4, T5, T6> {
+  final T1 first;
+  final T2 second;
+  final T3 third;
+  final T4 fourth;
+  final T5 fifth;
+  final T6 sixth;
+
+  const Tuple6(
+      this.first, this.second, this.third, this.fourth, this.fifth, this.sixth);
+}
+
+class Tuple7Serializer<T1, T2, T3, T4, T5, T6, T7>
+    extends TextSerializer<Tuple7<T1, T2, T3, T4, T5, T6, T7>> {
+  final TextSerializer<T1> first;
+  final TextSerializer<T2> second;
+  final TextSerializer<T3> third;
+  final TextSerializer<T4> fourth;
+  final TextSerializer<T5> fifth;
+  final TextSerializer<T6> sixth;
+  final TextSerializer<T7> seventh;
+
+  const Tuple7Serializer(this.first, this.second, this.third, this.fourth,
+      this.fifth, this.sixth, this.seventh);
+
+  Tuple7<T1, T2, T3, T4, T5, T6, T7> readFrom(
+      Iterator<Object> stream, DeserializationState state) {
+    return new Tuple7(
+        first.readFrom(stream, state),
+        second.readFrom(stream, state),
+        third.readFrom(stream, state),
+        fourth.readFrom(stream, state),
+        fifth.readFrom(stream, state),
+        sixth.readFrom(stream, state),
+        seventh.readFrom(stream, state));
+  }
+
+  void writeTo(StringBuffer buffer, Tuple7<T1, T2, T3, T4, T5, T6, T7> object,
+      SerializationState state) {
+    first.writeTo(buffer, object.first, state);
+    if (!second.isEmpty) buffer.write(' ');
+    second.writeTo(buffer, object.second, state);
+    if (!third.isEmpty) buffer.write(' ');
+    third.writeTo(buffer, object.third, state);
+    if (!fourth.isEmpty) buffer.write(' ');
+    fourth.writeTo(buffer, object.fourth, state);
+    if (!fifth.isEmpty) buffer.write(' ');
+    fifth.writeTo(buffer, object.fifth, state);
+    if (!sixth.isEmpty) buffer.write(' ');
+    sixth.writeTo(buffer, object.sixth, state);
+    if (!seventh.isEmpty) buffer.write(' ');
+    seventh.writeTo(buffer, object.seventh, state);
+  }
+}
+
+class Tuple7<T1, T2, T3, T4, T5, T6, T7> {
+  final T1 first;
+  final T2 second;
+  final T3 third;
+  final T4 fourth;
+  final T5 fifth;
+  final T6 sixth;
+  final T7 seventh;
+
+  const Tuple7(this.first, this.second, this.third, this.fourth, this.fifth,
+      this.sixth, this.seventh);
+}
+
 // A serializer/deserializer for lists.
 class ListSerializer<T> extends TextSerializer<List<T>> {
   final TextSerializer<T> elements;
@@ -451,25 +630,28 @@
 /// Serializes an object and uses it as a binder for the name that is retrieved
 /// from the object using [nameGetter] and (temporarily) modified using
 /// [nameSetter].  The binder is added to the enclosing environment.
-class Binder<T extends Node> extends TextSerializer<T> {
-  final TextSerializer<T> contents;
-  final String Function(T) nameGetter;
-  final void Function(T, String) nameSetter;
+class Binder<T extends Node> extends TextSerializer<Tuple2<String, T>> {
+  final Tuple2Serializer<String, T> namedContents;
 
-  const Binder(this.contents, this.nameGetter, this.nameSetter);
+  Binder(TextSerializer<T> contents)
+      : namedContents = new Tuple2Serializer(const DartString(), contents);
 
-  T readFrom(Iterator<Object> stream, DeserializationState state) {
-    T object = contents.readFrom(stream, state);
-    state.environment.addBinder(nameGetter(object), object);
-    return object;
+  Tuple2<String, T> readFrom(
+      Iterator<Object> stream, DeserializationState state) {
+    Tuple2<String, T> namedObject = namedContents.readFrom(stream, state);
+    String name = namedObject.first;
+    T object = namedObject.second;
+    state.environment.addBinder(object, name);
+    return new Tuple2(name, object);
   }
 
-  void writeTo(StringBuffer buffer, T object, SerializationState state) {
-    String oldName = nameGetter(object);
-    String newName = state.environment.addBinder(object, oldName);
-    nameSetter(object, newName);
-    contents.writeTo(buffer, object, state);
-    nameSetter(object, oldName);
+  void writeTo(StringBuffer buffer, Tuple2<String, T> namedObject,
+      SerializationState state) {
+    String nameClue = namedObject.first;
+    T object = namedObject.second;
+    String distinctName =
+        state.environment.addBinder(object, nameClue: nameClue);
+    namedContents.writeTo(buffer, new Tuple2(distinctName, object), state);
   }
 }
 
@@ -488,7 +670,7 @@
     var bindingState = new DeserializationState(
         new DeserializationEnvironment(state.environment), state.nameRoot);
     P first = pattern.readFrom(stream, bindingState);
-    bindingState.environment.close();
+    bindingState.environment.extend();
     T second = term.readFrom(stream, bindingState);
     return new Tuple2(first, second);
   }
@@ -498,7 +680,7 @@
     var bindingState =
         new SerializationState(new SerializationEnvironment(state.environment));
     pattern.writeTo(buffer, tuple.first, bindingState);
-    bindingState.environment.close();
+    bindingState.environment.extend();
     buffer.write(' ');
     term.writeTo(buffer, tuple.second, bindingState);
   }
@@ -520,7 +702,7 @@
     var closedState = new DeserializationState(
         new DeserializationEnvironment(state.environment)
           ..binders.addAll(state.environment.binders)
-          ..close(),
+          ..extend(),
         state.nameRoot);
     T second = pattern2.readFrom(stream, closedState);
     state.environment.binders.addAll(closedState.environment.binders);
@@ -533,7 +715,7 @@
     var closedState =
         new SerializationState(new SerializationEnvironment(state.environment)
           ..binders.addAll(state.environment.binders)
-          ..close());
+          ..extend());
     buffer.write(' ');
     pattern2.writeTo(buffer, tuple.second, closedState);
     state.environment.binders.addAll(closedState.environment.binders);
diff --git a/pkg/kernel/lib/text/text_serialization_verifier.dart b/pkg/kernel/lib/text/text_serialization_verifier.dart
index 456b204..0b983c2 100644
--- a/pkg/kernel/lib/text/text_serialization_verifier.dart
+++ b/pkg/kernel/lib/text/text_serialization_verifier.dart
@@ -29,9 +29,9 @@
   RoundTripStatus(this.node, {TreeNode context})
       : context = node is TreeNode && node.location != null ? node : context;
 
-  Uri get uri => context.location.file;
+  Uri get uri => context?.location?.file;
 
-  int get offset => context.fileOffset;
+  int get offset => context?.fileOffset;
 
   bool get isSuccess;
 
@@ -194,213 +194,7 @@
   }
 }
 
-class VerificationState {
-  final VerificationState parent;
-
-  final Node node;
-
-  bool allChildrenAreSupported = true;
-  final List<Node> roundTripReadyNodes = [];
-
-  final Set<VariableDeclaration> variableDeclarations =
-      new Set<VariableDeclaration>.identity();
-  final Set<TypeParameter> typeParameters = new Set<TypeParameter>.identity();
-
-  final Set<VariableDeclaration> usedVariables =
-      new Set<VariableDeclaration>.identity();
-  final Set<TypeParameter> usedTypeParameters =
-      new Set<TypeParameter>.identity();
-
-  VerificationState(this.parent, this.node);
-
-  bool get isRoot => parent == null;
-
-  bool get isFullySupported => isSupported(node) && allChildrenAreSupported;
-
-  bool get hasSufficientScope {
-    return usedVariables.every((v) => variableDeclarations.contains(v)) &&
-        usedTypeParameters.every((p) => typeParameters.contains(p));
-  }
-
-  bool get isRoundTripReady => isFullySupported && hasSufficientScope;
-
-  bool isVariableDeclared(VariableDeclaration node) {
-    return variableDeclarations.contains(node) ||
-        !isRoot && parent.isVariableDeclared(node);
-  }
-
-  bool isTypeParameterDeclared(TypeParameter node) {
-    return typeParameters.contains(node) ||
-        !isRoot && parent.isTypeParameterDeclared(node);
-  }
-
-  void handleChild(VerificationState childState) {
-    allChildrenAreSupported =
-        allChildrenAreSupported && childState.isFullySupported;
-  }
-
-  void handleDeclarations() {
-    Node node = this.node;
-    if (node is VariableDeclaration) {
-      parent.variableDeclarations.add(node);
-    }
-    if (node is TypeParameter) {
-      parent.typeParameters.add(node);
-    }
-    if (node is VariableGet) {
-      usedVariables.add(node.variable);
-    }
-    if (node is VariableSet) {
-      usedVariables.add(node.variable);
-    }
-    if (node is TypeParameterType) {
-      usedTypeParameters.add(node.parameter);
-    }
-  }
-
-  /// Computes round-trip ready nodes or propagates them further in the stack.
-  ///
-  /// The returned nodes are the roots of maximal-by-inclusion subtrees that are
-  /// ready for the round-trip textual serialization.
-  List<Node> takeRoundTripReadyNodes() {
-    if (isRoot) {
-      // If the node is the root of the AST and is round-trip ready, return just
-      // the root because it's maximal-by-inclusion.
-      // Otherwise, return the nodes collected so far.
-      List<Node> result =
-          isRoundTripReady ? <Node>[node] : roundTripReadyNodes.toList();
-      roundTripReadyNodes.clear();
-      return result;
-    }
-
-    // The algorithm in this branch is based on the following observations:
-    //   - The isFullySupported property is monotonous.  That is, when traveling
-    //     from a leaf to the root, the property may only change its value from
-    //     true to false.
-    //   - The isRoundTripReady property is not monotonous because the sub-tree
-    //     that is ready for the round trip shouldn't contain free variables or
-    //     free type parameters.
-    //   - The isRoundTripReady property implies the isFullySupported property.
-
-    if (!isFullySupported) {
-      // We're out of the isFullySupported sub-tree, run the round trip on the
-      // nodes that are ready for it so far -- they are maximal-by-inclusion by
-      // construction.
-      List<Node> result = roundTripReadyNodes.toList();
-      roundTripReadyNodes.clear();
-      return result;
-    } else {
-      // We're still in the isFullySupported sub-tree.  It's to early to decide
-      // if the collected sub-trees or the node itself are maximal-by-inclusion.
-      // The decision should be made in one of the parent nodes.  So, we just
-      // propagate the information to the parent, returning an empty list for
-      // the current node.
-      if (isRoundTripReady) {
-        // The current tree is ready for the round trip.  Its sub-trees, which
-        // are also round-trip ready, are not maximal-by-inclusion.  So only the
-        // node itself is passed to the parent.
-        parent.roundTripReadyNodes.add(node);
-      } else {
-        // The node is not round-trip ready.  The round-trip ready sub-trees
-        // collected so far remain the candidates for being
-        // maximal-by-inclusion.
-        parent.roundTripReadyNodes.addAll(roundTripReadyNodes);
-      }
-      return const <Node>[];
-    }
-  }
-
-  /// Passes the necessary information to the parent when popped from the stack.
-  void mergeToParent() {
-    // Pass the free occurrences of variables and type parameters to the parent.
-    if (parent != null) {
-      parent.usedVariables
-          .addAll(usedVariables.difference(variableDeclarations));
-      parent.usedTypeParameters
-          .addAll(usedTypeParameters.difference(typeParameters));
-      parent.handleChild(this);
-    }
-  }
-
-  static bool isExpressionSupported(Expression node) =>
-      !isExpressionNotSupported(node);
-
-  static bool isExpressionNotSupported(Expression node) =>
-      node is SetConcatenation ||
-      node is MapConcatenation ||
-      node is InstanceCreation ||
-      node is FileUriExpression ||
-      node is BlockExpression ||
-      node is ListConcatenation ||
-      node is NullCheck ||
-      node is BasicLiteral ||
-      node is InvocationExpression ||
-      node is Instantiation ||
-      node is ConstantExpression ||
-      node is CheckLibraryIsLoaded ||
-      node is LoadLibrary;
-
-  static bool isStatementSupported(Statement node) =>
-      !isStatementNotSupported(node);
-
-  static bool isStatementNotSupported(Statement node) =>
-      node is BreakStatement ||
-      node is VariableDeclaration &&
-          (node.parent is! Block || node.name == null) ||
-      node is SwitchStatement ||
-      node is TryFinally ||
-      node is LabeledStatement ||
-      node is TryCatch ||
-      node is FunctionDeclaration ||
-      node is ContinueSwitchStatement;
-
-  static bool isSupported(Node node) => !isNotSupported(node);
-
-  static bool isNotSupported(Node node) =>
-      node is Expression && isExpressionNotSupported(node) ||
-      node is Statement && isStatementNotSupported(node) ||
-      node is FunctionNode && node.body == null ||
-      node is Procedure &&
-          (!node.isStatic || node.kind != ProcedureKind.Method) ||
-      node is AssertInitializer ||
-      node is BoolConstant ||
-      node is Catch ||
-      node is Class ||
-      node is Combinator ||
-      node is Component ||
-      node is Constructor ||
-      node is DoubleConstant ||
-      node is Extension ||
-      node is Field ||
-      node is FieldInitializer ||
-      node is InstanceConstant ||
-      node is IntConstant ||
-      node is InvalidInitializer ||
-      node is Library ||
-      node is LibraryDependency ||
-      node is LibraryPart ||
-      node is ListConstant ||
-      node is LocalInitializer ||
-      node is MapConstant ||
-      node is Name && node.isPrivate ||
-      node is NullConstant ||
-      node is PartialInstantiationConstant ||
-      node is PrimitiveConstant ||
-      node is RedirectingFactoryConstructor ||
-      node is RedirectingInitializer ||
-      node is SetConstant ||
-      node is StringConstant ||
-      node is SuperInitializer ||
-      node is Supertype ||
-      node is SwitchCase ||
-      node is SymbolConstant ||
-      node is TearOffConstant ||
-      node is TypeLiteralConstant ||
-      node is Typedef ||
-      node is UnevaluatedConstant;
-}
-
-class TextSerializationVerifier extends RecursiveVisitor<void> {
+class TextSerializationVerifier {
   static const bool showStackTrace = bool.fromEnvironment(
       "text_serialization.showStackTrace",
       defaultValue: false);
@@ -410,8 +204,6 @@
 
   final CanonicalName root;
 
-  VerificationState _stateStackTop;
-
   TextSerializationVerifier({CanonicalName root})
       : root = root ?? new CanonicalName.root() {
     initializeSerializers();
@@ -422,58 +214,11 @@
 
   List<RoundTripStatus> get failures => _failures.toList()..sort();
 
-  VerificationState get currentState => _stateStackTop;
-
-  TreeNode get lastSeenTreeNodeWithLocation {
-    VerificationState state = _stateStackTop;
-    while (state != null) {
-      Node node = state.node;
-      if (node is TreeNode && node.location != null) {
-        return node;
-      }
-      state = state.parent;
-    }
-    return null;
+  void verify(Library node) {
+    makeRoundTrip<Library>(node, librarySerializer);
   }
 
-  void pushStateFor(Node node) {
-    _stateStackTop = new VerificationState(_stateStackTop, node);
-  }
-
-  void dropState() {
-    if (_stateStackTop == null) {
-      throw new StateError("Attempting to remove a state from an empty stack.");
-    }
-    _stateStackTop = _stateStackTop.parent;
-  }
-
-  void verify(Node node) => node.accept(this);
-
-  void defaultNode(Node node) {
-    enterNode(node);
-    node.visitChildren(this);
-    exitNode(node);
-  }
-
-  void enterNode(node) {
-    pushStateFor(node);
-    currentState.handleDeclarations();
-  }
-
-  void exitNode(node) {
-    if (!identical(node, currentState.node)) {
-      throw new StateError("Trying to remove node '${node}' from the stack, "
-          "while another node '${currentState.node}' is on the top of it.");
-    }
-    List<Node> roundTripReadyNodes = currentState.takeRoundTripReadyNodes();
-    for (Node node in roundTripReadyNodes) {
-      makeRoundTripDispatch(node);
-    }
-    currentState.mergeToParent();
-    dropState();
-  }
-
-  T readNode<T extends Node>(
+  T readNode<T extends TreeNode>(
       T node, String input, TextSerializer<T> serializer) {
     TextIterator stream = new TextIterator(input, 0);
     stream.moveNext();
@@ -484,24 +229,24 @@
     } catch (exception, stackTrace) {
       String message =
           showStackTrace ? "${exception}\n${stackTrace}" : "${exception}";
-      _status.add(new RoundTripDeserializationFailure(node, message,
-          context: lastSeenTreeNodeWithLocation));
+      _status.add(
+          new RoundTripDeserializationFailure(node, message, context: node));
       return null;
     }
     if (stream.moveNext()) {
       _status.add(new RoundTripDeserializationFailure(
           node, "unexpected trailing text",
-          context: lastSeenTreeNodeWithLocation));
+          context: node));
     }
     if (result == null) {
       _status.add(new RoundTripDeserializationFailure(
           node, "Deserialization of the following returned null: '${input}'",
-          context: lastSeenTreeNodeWithLocation));
+          context: node));
     }
     return result;
   }
 
-  String writeNode<T extends Node>(T node, TextSerializer<T> serializer) {
+  String writeNode<T extends TreeNode>(T node, TextSerializer<T> serializer) {
     StringBuffer buffer = new StringBuffer();
     try {
       serializer.writeTo(buffer, node,
@@ -510,38 +255,12 @@
       String message =
           showStackTrace ? "${exception}\n${stackTrace}" : "${exception}";
       _status.add(new RoundTripInitialSerializationFailure(node, message,
-          context: lastSeenTreeNodeWithLocation));
+          context: node));
     }
     return buffer.toString();
   }
 
-  void makeRoundTripDispatch(Node node) {
-    if (node is DartType) {
-      makeRoundTrip<DartType>(node, dartTypeSerializer);
-    } else if (node is Expression) {
-      makeRoundTrip<Expression>(node, expressionSerializer);
-    } else if (node is Statement) {
-      makeRoundTrip<Statement>(node, statementSerializer);
-    } else if (node is Arguments) {
-      makeRoundTrip<Arguments>(node, argumentsSerializer);
-    } else if (node is FunctionNode) {
-      makeRoundTrip<FunctionNode>(node, functionNodeSerializer);
-    } else if (node is Procedure) {
-      makeRoundTrip<Procedure>(node, procedureSerializer);
-    } else if (node is TypeParameter) {
-      makeRoundTrip<TypeParameter>(node, typeParameterSerializer);
-    } else if (node is NamedType) {
-      makeRoundTrip<NamedType>(node, namedTypeSerializer);
-    } else if (node is Name) {
-      makeRoundTrip<Name>(node, nameSerializer);
-    } else {
-      throw new StateError(
-          "Don't know how to make a round trip for a supported node "
-          "'${node.runtimeType}'");
-    }
-  }
-
-  void makeRoundTrip<T extends Node>(T node, TextSerializer<T> serializer) {
+  void makeRoundTrip<T extends TreeNode>(T node, TextSerializer<T> serializer) {
     int failureCount = _failures.length;
     String initial = writeNode(node, serializer);
     if (_failures.length != failureCount) {
@@ -567,10 +286,9 @@
     if (initial != serialized) {
       _status.add(new RoundTripSecondSerializationFailure(
           node, initial, serialized,
-          context: lastSeenTreeNodeWithLocation));
+          context: node));
     } else {
-      _status.add(new RoundTripSuccess(node, initial,
-          context: lastSeenTreeNodeWithLocation));
+      _status.add(new RoundTripSuccess(node, initial, context: node));
     }
   }
 
diff --git a/pkg/kernel/lib/text/text_serializer.dart b/pkg/kernel/lib/text/text_serializer.dart
index 829959c..59d13a0 100644
--- a/pkg/kernel/lib/text/text_serializer.dart
+++ b/pkg/kernel/lib/text/text_serializer.dart
@@ -10,8 +10,8 @@
 
 import '../visitor.dart' show ExpressionVisitor;
 
-abstract class Tagger<T extends Node> {
-  String tag(T node);
+abstract class Tagger<T> {
+  String tag(T object);
 }
 
 class NameTagger implements Tagger<Name> {
@@ -20,25 +20,13 @@
   String tag(Name name) => name.isPrivate ? "private" : "public";
 }
 
-const TextSerializer<Name> publicName =
-    const Wrapped(unwrapPublicName, wrapPublicName, const DartString());
+TextSerializer<Name> publicName =
+    Wrapped((w) => w.name, (u) => Name(u), const DartString());
 
-String unwrapPublicName(Name name) => name.name;
-
-Name wrapPublicName(String name) => new Name(name);
-
-const TextSerializer<Name> privateName = const Wrapped(unwrapPrivateName,
-    wrapPrivateName, Tuple2Serializer(const DartString(), const DartString()));
-
-Tuple2<String, String> unwrapPrivateName(Name name) {
-  return new Tuple2(name.library.importUri.toString(), name.name);
-}
-
-Name wrapPrivateName(Tuple2<String, String> tuple) {
-  // We need a map from import URI to libraries.  More generally, we will need
-  // a way to map any 'named' node to the node's reference.
-  throw UnimplementedError('Deserialization of private names.');
-}
+TextSerializer<Name> privateName = Wrapped(
+    (w) => Tuple2(w.name, w.library.canonicalName),
+    (u) => Name.byReference(u.first, u.second.getReference()),
+    Tuple2Serializer(DartString(), CanonicalNameSerializer()));
 
 TextSerializer<Name> nameSerializer = new Case(
     const NameTagger(), {"public": publicName, "private": privateName});
@@ -112,6 +100,17 @@
   }
 
   String visitFunctionExpression(FunctionExpression _) => "fun";
+  String visitListConcatenation(ListConcatenation _) => "lists";
+  String visitSetConcatenation(SetConcatenation _) => "sets";
+  String visitMapConcatenation(MapConcatenation _) => "maps";
+  String visitBlockExpression(BlockExpression _) => "let-block";
+  String visitInstantiation(Instantiation _) => "apply";
+  String visitNullCheck(NullCheck _) => "not-null";
+  String visitFileUriExpression(FileUriExpression _) => "with-uri";
+  String visitCheckLibraryIsLoaded(CheckLibraryIsLoaded _) => "is-loaded";
+  String visitLoadLibrary(LoadLibrary _) => "load";
+  String visitConstantExpression(ConstantExpression _) => "const";
+  String visitInstanceCreation(InstanceCreation _) => "object";
 }
 
 const TextSerializer<InvalidExpression> invalidExpressionSerializer =
@@ -397,12 +396,6 @@
   return new Let(tuple.first, tuple.second);
 }
 
-String getVariableDeclarationName(VariableDeclaration node) => node.name;
-
-void setVariableDeclarationName(VariableDeclaration node, String name) {
-  node.name = name;
-}
-
 TextSerializer<PropertyGet> propertyGetSerializer = new Wrapped(
     unwrapPropertyGet,
     wrapPropertyGet,
@@ -695,6 +688,71 @@
   return new FunctionExpression(node);
 }
 
+TextSerializer<ListConcatenation> listConcatenationSerializer = Wrapped(
+    (lc) => Tuple2(lc.typeArgument, lc.lists),
+    (t) => ListConcatenation(t.second, typeArgument: t.first),
+    Tuple2Serializer(dartTypeSerializer, ListSerializer(expressionSerializer)));
+
+TextSerializer<SetConcatenation> setConcatenationSerializer = Wrapped(
+    (sc) => Tuple2(sc.typeArgument, sc.sets),
+    (t) => SetConcatenation(t.second, typeArgument: t.first),
+    Tuple2Serializer(dartTypeSerializer, ListSerializer(expressionSerializer)));
+
+TextSerializer<MapConcatenation> mapConcatenationSerializer = Wrapped(
+    (mc) => Tuple3(mc.keyType, mc.valueType, mc.maps),
+    (t) => MapConcatenation(t.third, keyType: t.first, valueType: t.second),
+    Tuple3Serializer(dartTypeSerializer, dartTypeSerializer,
+        ListSerializer(expressionSerializer)));
+
+TextSerializer<BlockExpression> blockExpressionSerializer = Wrapped(
+    (w) => Tuple2(w.body.statements, w.value),
+    (u) => BlockExpression(Block(u.first), u.second),
+    const BlockSerializer());
+
+TextSerializer<Instantiation> instantiationSerializer = Wrapped(
+    (i) => Tuple2(i.expression, i.typeArguments),
+    (t) => Instantiation(t.first, t.second),
+    Tuple2Serializer(expressionSerializer, ListSerializer(dartTypeSerializer)));
+
+TextSerializer<NullCheck> nullCheckSerializer =
+    Wrapped((nc) => nc.operand, (op) => NullCheck(op), expressionSerializer);
+
+TextSerializer<FileUriExpression> fileUriExpressionSerializer = Wrapped(
+    (fue) => Tuple2(fue.expression, fue.fileUri),
+    (t) => FileUriExpression(t.first, t.second),
+    Tuple2Serializer(expressionSerializer, const UriSerializer()));
+
+TextSerializer<CheckLibraryIsLoaded> checkLibraryIsLoadedSerializer = Wrapped(
+    (clil) => clil.import,
+    (i) => CheckLibraryIsLoaded(i),
+    libraryDependencySerializer);
+
+TextSerializer<LoadLibrary> loadLibrarySerializer = Wrapped(
+    (ll) => ll.import, (i) => LoadLibrary(i), libraryDependencySerializer);
+
+TextSerializer<ConstantExpression> constantExpressionSerializer = Wrapped(
+    (ce) => Tuple2(ce.constant, ce.type),
+    (t) => ConstantExpression(t.first, t.second),
+    Tuple2Serializer(constantSerializer, dartTypeSerializer));
+
+TextSerializer<InstanceCreation> instanceCreationSerializer = Wrapped(
+    (ic) => Tuple6(
+        ic.classReference.canonicalName,
+        ic.typeArguments,
+        ic.fieldValues.keys.map((r) => r.canonicalName).toList(),
+        ic.fieldValues.values.toList(),
+        ic.asserts,
+        ic.unusedArguments),
+    (t) => InstanceCreation(t.first.getReference(), t.second,
+        Map.fromIterables(t.third, t.fourth), t.fifth, t.sixth),
+    Tuple6Serializer(
+        CanonicalNameSerializer(),
+        ListSerializer(dartTypeSerializer),
+        ListSerializer(CanonicalNameSerializer()),
+        ListSerializer(expressionSerializer),
+        ListSerializer(assertStatementSerializer),
+        ListSerializer(expressionSerializer)));
+
 Case<Expression> expressionSerializer =
     new Case.uninitialized(const ExpressionTagger());
 
@@ -729,105 +787,54 @@
   return new Arguments(tuple.second, types: tuple.first, named: tuple.third);
 }
 
-class VariableDeclarationTagger implements Tagger<VariableDeclaration> {
-  const VariableDeclarationTagger();
+const Map<int, String> variableDeclarationFlagToName = const {
+  VariableDeclaration.FlagFinal: "final",
+  VariableDeclaration.FlagConst: "const",
+  VariableDeclaration.FlagFieldFormal: "field-formal",
+  VariableDeclaration.FlagCovariant: "covariant",
+  VariableDeclaration.FlagInScope: "in-scope",
+  VariableDeclaration.FlagGenericCovariantImpl: "generic-covariant-impl",
+  VariableDeclaration.FlagLate: "late",
+  VariableDeclaration.FlagRequired: "required",
+};
 
-  String tag(VariableDeclaration decl) {
-    if (decl.isCovariant) throw UnimplementedError("Covariant declaration.");
-    if (decl.isFieldFormal) throw UnimplementedError("Initializing formal.");
-    if (decl.isConst) {
-      // It's not clear what invariants we assume about const/final.  For now
-      // throw if we have both.
-      if (decl.isFinal) throw UnimplementedError("const and final");
-      return "const";
-    }
-    if (decl.isFinal) {
-      return "final";
-    }
-    return "var";
+class VariableDeclarationFlagTagger implements Tagger<int> {
+  String tag(int flag) {
+    return variableDeclarationFlagToName[flag] ??
+        (throw StateError("Unknown VariableDeclaration flag value: ${flag}."));
   }
 }
 
-TextSerializer<VariableDeclaration> varDeclarationSerializer = new Wrapped(
-    unwrapVariableDeclaration,
-    wrapVarDeclaration,
-    Tuple4Serializer(
-        const DartString(),
-        dartTypeSerializer,
-        new Optional(expressionSerializer),
-        new ListSerializer(expressionSerializer)));
+TextSerializer<int> variableDeclarationFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        VariableDeclarationFlagTagger(),
+        Map.fromIterable(variableDeclarationFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
 
-Tuple4<String, DartType, Expression, List<Expression>>
-    unwrapVariableDeclaration(VariableDeclaration declaration) {
-  return new Tuple4(declaration.name ?? "", declaration.type,
-      declaration.initializer, declaration.annotations);
-}
+TextSerializer<VariableDeclaration> variableDeclarationSerializer = Wrapped(
+    (v) => Tuple2(v.name, v),
+    (t) => t.second..name = t.first,
+    Binder<VariableDeclaration>(
+      new Wrapped(
+          (w) => Tuple4(w.flags, w.type, w.initializer, w.annotations),
+          (u) => u.fourth.fold(
+              VariableDeclaration(null,
+                  flags: u.first, type: u.second, initializer: u.third),
+              (v, a) => v..addAnnotation(a)),
+          Tuple4Serializer(
+              variableDeclarationFlagsSerializer,
+              dartTypeSerializer,
+              new Optional(expressionSerializer),
+              new ListSerializer(expressionSerializer))),
+    ));
 
-VariableDeclaration wrapVarDeclaration(
-    Tuple4<String, DartType, Expression, List<Expression>> tuple) {
-  var result = new VariableDeclaration(tuple.first.isEmpty ? null : tuple.first,
-      initializer: tuple.third, type: tuple.second);
-  for (int i = 0; i < tuple.fourth.length; ++i) {
-    result.addAnnotation(tuple.fourth[i]);
-  }
-  return result;
-}
-
-TextSerializer<VariableDeclaration> finalDeclarationSerializer = new Wrapped(
-    unwrapVariableDeclaration,
-    wrapFinalDeclaration,
-    Tuple4Serializer(
-        const DartString(),
-        dartTypeSerializer,
-        new Optional(expressionSerializer),
-        new ListSerializer(expressionSerializer)));
-
-VariableDeclaration wrapFinalDeclaration(
-    Tuple4<String, DartType, Expression, List<Expression>> tuple) {
-  var result = new VariableDeclaration(tuple.first.isEmpty ? null : tuple.first,
-      initializer: tuple.third, type: tuple.second, isFinal: true);
-  for (int i = 0; i < tuple.fourth.length; ++i) {
-    result.addAnnotation(tuple.fourth[i]);
-  }
-  return result;
-}
-
-TextSerializer<VariableDeclaration> constDeclarationSerializer = new Wrapped(
-    unwrapVariableDeclaration,
-    wrapConstDeclaration,
-    Tuple4Serializer(
-        const DartString(),
-        dartTypeSerializer,
-        new Optional(expressionSerializer),
-        new ListSerializer(expressionSerializer)));
-
-VariableDeclaration wrapConstDeclaration(
-    Tuple4<String, DartType, Expression, List<Expression>> tuple) {
-  var result = new VariableDeclaration(tuple.first.isEmpty ? null : tuple.first,
-      initializer: tuple.third, type: tuple.second, isConst: true);
-  for (int i = 0; i < tuple.fourth.length; ++i) {
-    result.addAnnotation(tuple.fourth[i]);
-  }
-  return result;
-}
-
-TextSerializer<VariableDeclaration> variableDeclarationSerializer = new Binder(
-    new Case(const VariableDeclarationTagger(), {
-      "var": varDeclarationSerializer,
-      "final": finalDeclarationSerializer,
-      "const": constDeclarationSerializer,
-    }),
-    getVariableDeclarationName,
-    setVariableDeclarationName);
-
-TextSerializer<TypeParameter> typeParameterSerializer = new Binder(
-    const Wrapped(unwrapTypeParameter, wrapTypeParameter, const DartString()),
-    getTypeParameterName,
-    setTypeParameterName);
-
-String unwrapTypeParameter(TypeParameter node) => node.name;
-
-TypeParameter wrapTypeParameter(String name) => new TypeParameter(name);
+TextSerializer<TypeParameter> typeParameterSerializer = Wrapped(
+    (p) => Tuple2(p.name, p),
+    (t) => t.second..name = t.first,
+    Binder(Wrapped((_) => null, (_) => TypeParameter(), const Nothing())));
 
 TextSerializer<List<TypeParameter>> typeParametersSerializer = new Zip(
     new Rebind(
@@ -840,12 +847,6 @@
     zipTypeParameterDefaultType,
     unzipTypeParameterDefaultType);
 
-String getTypeParameterName(TypeParameter node) => node.name;
-
-void setTypeParameterName(TypeParameter node, String name) {
-  node.name = name;
-}
-
 TypeParameter zipTypeParameterBound(TypeParameter node, DartType bound) {
   return node..bound = bound;
 }
@@ -1050,6 +1051,14 @@
 
   String visitAssertStatement(AssertStatement node) => "assert";
   String visitAssertBlock(AssertBlock node) => "assert-block";
+  String visitLabeledStatement(LabeledStatement node) => "label";
+  String visitBreakStatement(BreakStatement node) => "break";
+  String visitTryFinally(TryFinally node) => "try-finally";
+  String visitTryCatch(TryCatch node) => "try-catch";
+  String visitSwitchStatement(SwitchStatement node) => "switch";
+  String visitContinueSwitchStatement(ContinueSwitchStatement node) =>
+      "continue";
+  String visitFunctionDeclaration(FunctionDeclaration node) => "local-fun";
 }
 
 TextSerializer<ExpressionStatement> expressionStatementSerializer = new Wrapped(
@@ -1090,33 +1099,18 @@
   return new YieldStatement(expression);
 }
 
-TextSerializer<AssertStatement> assertStatementSerializer = new Wrapped(
-    unwrapAssertStatement,
-    wrapAssertStatement,
-    new Tuple2Serializer(expressionSerializer, expressionSerializer));
+TextSerializer<AssertStatement> assertStatementSerializer = Wrapped(
+    (a) => Tuple2(a.condition, a.message),
+    (t) => AssertStatement(t.first, message: t.second),
+    Tuple2Serializer(expressionSerializer, Optional(expressionSerializer)));
 
-Tuple2<Expression, Expression> unwrapAssertStatement(AssertStatement node) {
-  return new Tuple2<Expression, Expression>(node.condition, node.message);
-}
+TextSerializer<Block> blockSerializer = new Wrapped(
+    (w) => Tuple2(w.statements, null),
+    (u) => Block(u.first),
+    const BlockSerializer());
 
-AssertStatement wrapAssertStatement(Tuple2<Expression, Expression> tuple) {
-  return new AssertStatement(tuple.first, message: tuple.second);
-}
-
-TextSerializer<Block> blockSerializer =
-    new Wrapped(unwrapBlock, wrapBlock, const BlockSerializer());
-
-List<Statement> unwrapBlock(Block node) => node.statements;
-
-Block wrapBlock(List<Statement> statements) => new Block(statements);
-
-TextSerializer<AssertBlock> assertBlockSerializer =
-    new Wrapped(unwrapAssertBlock, wrapAssertBlock, const BlockSerializer());
-
-List<Statement> unwrapAssertBlock(AssertBlock node) => node.statements;
-
-AssertBlock wrapAssertBlock(List<Statement> statements) =>
-    new AssertBlock(statements);
+TextSerializer<AssertBlock> assertBlockSerializer = new Wrapped(
+    (w) => Tuple2(w.statements, null), (u) => u.first, const BlockSerializer());
 
 /// Serializer for [Block]s.
 ///
@@ -1131,41 +1125,46 @@
 /// unnecessary nested blocks.  Instead, [BlockSerializer] is implemented
 /// without direct invocations of either [ListSerializer] or [Bind], but with a
 /// certain internal correspondence to how they work.
-class BlockSerializer extends TextSerializer<List<Statement>> {
+class BlockSerializer
+    extends TextSerializer<Tuple2<List<Statement>, Expression>> {
   const BlockSerializer();
 
-  List<Statement> readFrom(
+  Tuple2<List<Statement>, Expression> readFrom(
       Iterator<Object> stream, DeserializationState state) {
     if (stream.current is! Iterator) {
       throw StateError("Expected a list, found an atom: '${stream.current}'.");
     }
     Iterator<Object> list = stream.current;
     list.moveNext();
-    List<Statement> result = [];
+    List<Statement> statements = [];
     DeserializationState currentState = state;
     while (list.current != null) {
       currentState = new DeserializationState(
           new DeserializationEnvironment(currentState.environment),
           currentState.nameRoot);
-      result.add(statementSerializer.readFrom(list, currentState));
-      currentState.environment.close();
+      statements.add(statementSerializer.readFrom(list, currentState));
+      currentState.environment.extend();
     }
     stream.moveNext();
-    return result;
+    Expression expression =
+        new Optional(expressionSerializer).readFrom(stream, currentState);
+    return new Tuple2(statements, expression);
   }
 
-  void writeTo(StringBuffer buffer, List<Statement> statements,
+  void writeTo(StringBuffer buffer, Tuple2<List<Statement>, Expression> tuple,
       SerializationState state) {
     buffer.write('(');
     SerializationState currentState = state;
-    for (int i = 0; i < statements.length; ++i) {
+    for (int i = 0; i < tuple.first.length; ++i) {
       if (i != 0) buffer.write(' ');
       currentState = new SerializationState(
           new SerializationEnvironment(currentState.environment));
-      statementSerializer.writeTo(buffer, statements[i], currentState);
-      currentState.environment.close();
+      statementSerializer.writeTo(buffer, tuple.first[i], currentState);
+      currentState.environment.extend();
     }
-    buffer.write(')');
+    buffer.write(') ');
+    new Optional(expressionSerializer)
+        .writeTo(buffer, tuple.second, currentState);
   }
 }
 
@@ -1232,28 +1231,14 @@
 }
 
 TextSerializer<ForStatement> forStatementSerializer = new Wrapped(
-    unwrapForStatement,
-    wrapForStatement,
+    (w) => Tuple2(w.variables, Tuple3(w.condition, w.updates, w.body)),
+    (u) =>
+        ForStatement(u.first, u.second.first, u.second.second, u.second.third),
     new Bind(
         ListSerializer(variableDeclarationSerializer),
-        new Tuple3Serializer(expressionSerializer,
+        new Tuple3Serializer(Optional(expressionSerializer),
             new ListSerializer(expressionSerializer), statementSerializer)));
 
-Tuple2<List<VariableDeclaration>,
-        Tuple3<Expression, List<Expression>, Statement>>
-    unwrapForStatement(ForStatement node) {
-  return new Tuple2(
-      node.variables, new Tuple3(node.condition, node.updates, node.body));
-}
-
-ForStatement wrapForStatement(
-    Tuple2<List<VariableDeclaration>,
-            Tuple3<Expression, List<Expression>, Statement>>
-        tuple) {
-  return new ForStatement(
-      tuple.first, tuple.second.first, tuple.second.second, tuple.second.third);
-}
-
 TextSerializer<ForInStatement> forInStatementSerializer = new Wrapped(
     unwrapForInStatement,
     wrapForInStatement,
@@ -1284,229 +1269,401 @@
       isAsync: true);
 }
 
+TextSerializer<LabeledStatement> labeledStatementSerializer =
+    Wrapped<Tuple2<LabeledStatement, Statement>, LabeledStatement>(
+        (ls) => Tuple2(ls, ls.body),
+        (t) => t.first..body = t.second,
+        Bind(
+            Wrapped(
+                (ls) => Tuple2("L", ls),
+                (t) => t.second,
+                Binder(Wrapped(
+                    (_) => null, (_) => LabeledStatement(null), Nothing()))),
+            statementSerializer));
+
+TextSerializer<BreakStatement> breakSerializer = new Wrapped(
+    unwrapBreakStatement,
+    wrapBreakStatement,
+    const ScopedUse<LabeledStatement>());
+
+LabeledStatement unwrapBreakStatement(BreakStatement node) {
+  return node.target;
+}
+
+BreakStatement wrapBreakStatement(LabeledStatement node) {
+  return new BreakStatement(node);
+}
+
+TextSerializer<TryFinally> tryFinallySerializer = Wrapped(
+    (w) => Tuple2(w.body, w.finalizer),
+    (u) => TryFinally(u.first, u.second),
+    Tuple2Serializer(statementSerializer, statementSerializer));
+
+TextSerializer<TryCatch> tryCatchSerializer = Wrapped(
+    (w) => Tuple2(w.body, w.catches),
+    (u) => TryCatch(u.first, u.second),
+    Tuple2Serializer(statementSerializer, ListSerializer(catchSerializer)));
+
+TextSerializer<Catch> catchSerializer = Wrapped(
+    (w) => Tuple2(w.guard, Tuple2(Tuple2(w.exception, w.stackTrace), w.body)),
+    (u) => Catch(u.second.first.first, u.second.second,
+        stackTrace: u.second.first.second, guard: u.first),
+    Tuple2Serializer(
+        dartTypeSerializer,
+        Bind(
+            Tuple2Serializer(Optional(variableDeclarationSerializer),
+                Optional(variableDeclarationSerializer)),
+            statementSerializer)));
+
+TextSerializer<SwitchStatement> switchStatementSerializer = Wrapped(
+    (w) => Tuple2(w.expression, w.cases),
+    (u) => SwitchStatement(u.first, u.second),
+    Tuple2Serializer(
+        expressionSerializer,
+        Zip(
+            Bind(ListSerializer<SwitchCase>(switchCaseSerializer),
+                ListSerializer(statementSerializer)),
+            (SwitchCase c, Statement b) => c..body = b,
+            (SwitchCase z) => Tuple2(z, z.body))));
+
+class SwitchCaseTagger implements Tagger<SwitchCase> {
+  String tag(SwitchCase node) {
+    return node.isDefault ? "default" : "case";
+  }
+}
+
+TextSerializer<SwitchCase> switchCaseCaseSerializer = Wrapped(
+    (w) => Tuple2("L", w),
+    (u) => u.second,
+    Binder(Wrapped(
+        (w) => w.expressions,
+        (u) => SwitchCase(u, List.filled(u.length, 0), null),
+        ListSerializer(expressionSerializer))));
+
+TextSerializer<SwitchCase> switchCaseDefaultSerializer = Wrapped(
+    (w) => Tuple2("L", w),
+    (u) => u.second,
+    Binder(
+        Wrapped((w) => null, (u) => SwitchCase.defaultCase(null), Nothing())));
+
+TextSerializer<SwitchCase> switchCaseSerializer = Case(SwitchCaseTagger(), {
+  "case": switchCaseCaseSerializer,
+  "default": switchCaseDefaultSerializer,
+});
+
+TextSerializer<ContinueSwitchStatement> continueSwitchStatementSerializer =
+    Wrapped((w) => w.target, (u) => ContinueSwitchStatement(u), ScopedUse());
+
+TextSerializer<FunctionDeclaration> functionDeclarationSerializer = Wrapped(
+    (w) => Tuple2(w.variable, w.function),
+    (u) => FunctionDeclaration(u.first, u.second),
+    Rebind(variableDeclarationSerializer, functionNodeSerializer));
+
 Case<Statement> statementSerializer =
     new Case.uninitialized(const StatementTagger());
 
-class FunctionNodeTagger implements Tagger<FunctionNode> {
-  const FunctionNodeTagger();
+const Map<AsyncMarker, String> asyncMarkerToName = {
+  AsyncMarker.Async: "async",
+  AsyncMarker.Sync: "sync",
+  AsyncMarker.AsyncStar: "async-star",
+  AsyncMarker.SyncStar: "sync-star",
+  AsyncMarker.SyncYielding: "sync-yielding",
+};
 
-  String tag(FunctionNode node) {
-    switch (node.asyncMarker) {
-      case AsyncMarker.Async:
-        return "async";
-      case AsyncMarker.Sync:
-        return "sync";
-      case AsyncMarker.AsyncStar:
-        return "async-star";
-      case AsyncMarker.SyncStar:
-        return "sync-star";
-      case AsyncMarker.SyncYielding:
-        return "sync-yielding";
-    }
-    throw new UnsupportedError("${node.asyncMarker}");
+class AsyncMarkerTagger implements Tagger<AsyncMarker> {
+  const AsyncMarkerTagger();
+
+  String tag(AsyncMarker node) {
+    return asyncMarkerToName[node] ?? (throw new UnsupportedError("${node}"));
   }
 }
 
-TextSerializer<FunctionNode> syncFunctionNodeSerializer = new Wrapped(
-    unwrapFunctionNode,
-    wrapSyncFunctionNode,
-    new Bind(
-        new Rebind(
-            typeParametersSerializer,
-            new Tuple3Serializer(
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer))),
-        new Tuple2Serializer(dartTypeSerializer, statementSerializer)));
+TextSerializer<AsyncMarker> asyncMarkerSerializer = Case(
+    AsyncMarkerTagger(),
+    Map.fromIterable(asyncMarkerToName.entries,
+        key: (e) => e.value,
+        value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())));
 
-Tuple2<
-    Tuple2<
-        List<TypeParameter>,
-        Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-            List<VariableDeclaration>>>,
-    Tuple2<DartType, Statement>> unwrapFunctionNode(FunctionNode node) {
-  return new Tuple2(
-      new Tuple2(
-          node.typeParameters,
-          new Tuple3(
-              node.positionalParameters.sublist(0, node.requiredParameterCount),
-              node.positionalParameters.sublist(node.requiredParameterCount),
-              node.namedParameters)),
-      new Tuple2(node.returnType, node.body));
+TextSerializer<Tuple2<FunctionNode, List<Initializer>>>
+    functionNodeWithInitializersSerializer = Wrapped(
+        (w) => Tuple2(
+            w.first.asyncMarker,
+            Tuple2(
+                Tuple2(
+                    w.first.typeParameters,
+                    Tuple3(
+                        w.first.positionalParameters
+                            .sublist(0, w.first.requiredParameterCount),
+                        w.first.positionalParameters
+                            .sublist(w.first.requiredParameterCount),
+                        w.first.namedParameters)),
+                Tuple3(w.first.returnType, w.second, w.first.body))),
+        (u) => Tuple2(
+            FunctionNode(u.second.second.third,
+                typeParameters: u.second.first.first,
+                positionalParameters:
+                    u.second.first.second.first + u.second.first.second.second,
+                namedParameters: u.second.first.second.third,
+                requiredParameterCount: u.second.first.second.first.length,
+                returnType: u.second.second.first,
+                asyncMarker: u.first),
+            u.second.second.second),
+        Tuple2Serializer(
+            asyncMarkerSerializer,
+            Bind(
+                Rebind(
+                    typeParametersSerializer,
+                    Tuple3Serializer(
+                        ListSerializer(variableDeclarationSerializer),
+                        ListSerializer(variableDeclarationSerializer),
+                        ListSerializer(variableDeclarationSerializer))),
+                Tuple3Serializer(
+                    dartTypeSerializer,
+                    Optional(ListSerializer(initializerSerializer)),
+                    Optional(statementSerializer)))));
+
+TextSerializer<FunctionNode> functionNodeSerializer = Wrapped(
+    (w) => Tuple2(w, null),
+    (u) => u.first,
+    functionNodeWithInitializersSerializer);
+
+const Map<int, String> procedureFlagToName = const {
+  Procedure.FlagStatic: "static",
+  Procedure.FlagAbstract: "abstract",
+  Procedure.FlagExternal: "external",
+  Procedure.FlagConst: "const",
+  Procedure.FlagForwardingStub: "forwarding-stub",
+  Procedure.FlagForwardingSemiStub: "forwarding-semi-stub",
+  Procedure.FlagRedirectingFactoryConstructor:
+      "redirecting-factory-constructor",
+  Procedure.FlagNoSuchMethodForwarder: "no-such-method-forwarder",
+  Procedure.FlagExtensionMember: "extension-member",
+  Procedure.FlagMemberSignature: "member-signature",
+  Procedure.FlagNonNullableByDefault: "non-nullable-by-default",
+};
+
+class ProcedureFlagTagger implements Tagger<int> {
+  const ProcedureFlagTagger();
+
+  String tag(int flag) {
+    return procedureFlagToName[flag] ??
+        (throw StateError("Unknown Procedure flag value: ${flag}."));
+  }
 }
 
-FunctionNode wrapSyncFunctionNode(
-    Tuple2<
-            Tuple2<
-                List<TypeParameter>,
-                Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-                    List<VariableDeclaration>>>,
-            Tuple2<DartType, Statement>>
-        tuple) {
-  return new FunctionNode(tuple.second.second,
-      typeParameters: tuple.first.first,
-      positionalParameters:
-          tuple.first.second.first + tuple.first.second.second,
-      namedParameters: tuple.first.second.third,
-      requiredParameterCount: tuple.first.second.first.length,
-      returnType: tuple.second.first,
-      asyncMarker: AsyncMarker.Sync);
+TextSerializer<int> procedureFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        ProcedureFlagTagger(),
+        Map.fromIterable(procedureFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
+
+const Map<int, String> fieldFlagToName = const {
+  Field.FlagFinal: "final",
+  Field.FlagConst: "const",
+  Field.FlagStatic: "static",
+  Field.FlagHasImplicitGetter: "has-implicit-getter",
+  Field.FlagHasImplicitSetter: "has-implicit-setter",
+  Field.FlagCovariant: "covariant",
+  Field.FlagGenericCovariantImpl: "generic-covariant-impl",
+  Field.FlagLate: "late",
+  Field.FlagExtensionMember: "extension-member",
+  Field.FlagNonNullableByDefault: "non-nullable-by-default",
+  Field.FlagInternalImplementation: "internal-implementation",
+};
+
+class FieldFlagTagger implements Tagger<int> {
+  const FieldFlagTagger();
+
+  String tag(int flag) {
+    return fieldFlagToName[flag] ??
+        (throw StateError("Unknown Field flag value: ${flag}."));
+  }
 }
 
-TextSerializer<FunctionNode> asyncFunctionNodeSerializer = new Wrapped(
-    unwrapFunctionNode,
-    wrapAsyncFunctionNode,
-    new Bind(
-        new Rebind(
-            typeParametersSerializer,
-            new Tuple3Serializer(
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer))),
-        new Tuple2Serializer(dartTypeSerializer, statementSerializer)));
+TextSerializer<int> fieldFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        FieldFlagTagger(),
+        Map.fromIterable(fieldFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
 
-FunctionNode wrapAsyncFunctionNode(
-    Tuple2<
-            Tuple2<
-                List<TypeParameter>,
-                Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-                    List<VariableDeclaration>>>,
-            Tuple2<DartType, Statement>>
-        tuple) {
-  return new FunctionNode(tuple.second.second,
-      typeParameters: tuple.first.first,
-      positionalParameters:
-          tuple.first.second.first + tuple.first.second.second,
-      namedParameters: tuple.first.second.third,
-      requiredParameterCount: tuple.first.second.first.length,
-      returnType: tuple.second.first,
-      asyncMarker: AsyncMarker.Async);
+const Map<int, String> constructorFlagToName = const {
+  Constructor.FlagConst: "const",
+  Constructor.FlagExternal: "external",
+  Constructor.FlagSynthetic: "synthetic",
+  Constructor.FlagNonNullableByDefault: "non-nullable-by-default",
+};
+
+class ConstructorFlagTagger implements Tagger<int> {
+  const ConstructorFlagTagger();
+
+  String tag(int flag) {
+    return constructorFlagToName[flag] ??
+        (throw StateError("Unknown Constructor flag value: ${flag}."));
+  }
 }
 
-TextSerializer<FunctionNode> syncStarFunctionNodeSerializer = new Wrapped(
-    unwrapFunctionNode,
-    wrapSyncStarFunctionNode,
-    new Bind(
-        new Rebind(
-            typeParametersSerializer,
-            new Tuple3Serializer(
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer))),
-        new Tuple2Serializer(dartTypeSerializer, statementSerializer)));
+TextSerializer<int> constructorFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        ConstructorFlagTagger(),
+        Map.fromIterable(constructorFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
 
-FunctionNode wrapSyncStarFunctionNode(
-    Tuple2<
-            Tuple2<
-                List<TypeParameter>,
-                Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-                    List<VariableDeclaration>>>,
-            Tuple2<DartType, Statement>>
-        tuple) {
-  return new FunctionNode(tuple.second.second,
-      typeParameters: tuple.first.first,
-      positionalParameters:
-          tuple.first.second.first + tuple.first.second.second,
-      namedParameters: tuple.first.second.third,
-      requiredParameterCount: tuple.first.second.first.length,
-      returnType: tuple.second.first,
-      asyncMarker: AsyncMarker.SyncStar);
+const Map<int, String> redirectingFactoryConstructorFlagToName = const {
+  RedirectingFactoryConstructor.FlagConst: "const",
+  RedirectingFactoryConstructor.FlagExternal: "external",
+  RedirectingFactoryConstructor.FlagNonNullableByDefault:
+      "non-nullable-by-default",
+};
+
+class RedirectingFactoryConstructorFlagTagger implements Tagger<int> {
+  const RedirectingFactoryConstructorFlagTagger();
+
+  String tag(int flag) {
+    return redirectingFactoryConstructorFlagToName[flag] ??
+        (throw StateError(
+            "Unknown RedirectingFactoryConstructor flag value: ${flag}."));
+  }
 }
 
-TextSerializer<FunctionNode> asyncStarFunctionNodeSerializer = new Wrapped(
-    unwrapFunctionNode,
-    wrapAsyncStarFunctionNode,
-    new Bind(
-        new Rebind(
-            typeParametersSerializer,
-            new Tuple3Serializer(
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer),
-                new ListSerializer(variableDeclarationSerializer))),
-        new Tuple2Serializer(dartTypeSerializer, statementSerializer)));
+TextSerializer<int> redirectingFactoryConstructorFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        RedirectingFactoryConstructorFlagTagger(),
+        Map.fromIterable(redirectingFactoryConstructorFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
 
-FunctionNode wrapAsyncStarFunctionNode(
-    Tuple2<
-            Tuple2<
-                List<TypeParameter>,
-                Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-                    List<VariableDeclaration>>>,
-            Tuple2<DartType, Statement>>
-        tuple) {
-  return new FunctionNode(tuple.second.second,
-      typeParameters: tuple.first.first,
-      positionalParameters:
-          tuple.first.second.first + tuple.first.second.second,
-      namedParameters: tuple.first.second.third,
-      requiredParameterCount: tuple.first.second.first.length,
-      returnType: tuple.second.first,
-      asyncMarker: AsyncMarker.AsyncStar);
+class MemberTagger implements Tagger<Member> {
+  const MemberTagger();
+
+  String tag(Member node) {
+    if (node is Field) {
+      return "field";
+    } else if (node is Constructor) {
+      return "constructor";
+    } else if (node is RedirectingFactoryConstructor) {
+      return "redirecting-factory-constructor";
+    } else if (node is Procedure) {
+      switch (node.kind) {
+        case ProcedureKind.Method:
+          return "method";
+        case ProcedureKind.Getter:
+          return "getter";
+        case ProcedureKind.Setter:
+          return "setter";
+        case ProcedureKind.Operator:
+          return "operator";
+        case ProcedureKind.Factory:
+          return "factory";
+        default:
+          throw new UnsupportedError("MemberTagger.tag(${node.kind})");
+      }
+    } else {
+      throw UnimplementedError("MemberTagger.tag(${node.runtimeType})");
+    }
+  }
 }
 
-TextSerializer<FunctionNode> syncYieldingStarFunctionNodeSerializer =
-    new Wrapped(
-        unwrapFunctionNode,
-        wrapSyncYieldingFunctionNode,
-        new Bind(
-            new Rebind(
+TextSerializer<Field> fieldSerializer = Wrapped(
+    (w) => Tuple4(w.name, w.flags, w.type, w.initializer),
+    (u) =>
+        Field(u.first, type: u.third, initializer: u.fourth)..flags = u.second,
+    Tuple4Serializer(nameSerializer, fieldFlagsSerializer, dartTypeSerializer,
+        Optional(expressionSerializer)));
+
+TextSerializer<Procedure> methodSerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, w.function),
+    (u) => Procedure(u.first, ProcedureKind.Method, u.third)..flags = u.second,
+    Tuple3Serializer(
+        nameSerializer, procedureFlagsSerializer, functionNodeSerializer));
+
+TextSerializer<Procedure> getterSerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, w.function),
+    (u) => Procedure(u.first, ProcedureKind.Getter, u.third)..flags = u.second,
+    Tuple3Serializer(
+        nameSerializer, procedureFlagsSerializer, functionNodeSerializer));
+
+TextSerializer<Procedure> setterSerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, w.function),
+    (u) => Procedure(u.first, ProcedureKind.Setter, u.third)..flags = u.second,
+    Tuple3Serializer(
+        nameSerializer, procedureFlagsSerializer, functionNodeSerializer));
+
+TextSerializer<Procedure> operatorSerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, w.function),
+    (u) =>
+        Procedure(u.first, ProcedureKind.Operator, u.third)..flags = u.second,
+    Tuple3Serializer(
+        nameSerializer, procedureFlagsSerializer, functionNodeSerializer));
+
+TextSerializer<Procedure> factorySerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, w.function),
+    (u) => Procedure(u.first, ProcedureKind.Factory, u.third)..flags = u.second,
+    Tuple3Serializer(
+        nameSerializer, procedureFlagsSerializer, functionNodeSerializer));
+
+TextSerializer<Constructor> constructorSerializer = Wrapped(
+    (w) => Tuple3(w.name, w.flags, Tuple2(w.function, w.initializers)),
+    (u) =>
+        Constructor(u.third.first, name: u.first, initializers: u.third.second)
+          ..flags = u.second,
+    Tuple3Serializer(nameSerializer, constructorFlagsSerializer,
+        functionNodeWithInitializersSerializer));
+
+TextSerializer<RedirectingFactoryConstructor>
+    redirectingFactoryConstructorSerializer = Wrapped(
+        (w) => Tuple4(
+            w.name,
+            w.flags,
+            w.targetReference.canonicalName,
+            Tuple2(
+                w.typeParameters,
+                Tuple4(
+                    w.positionalParameters
+                        .take(w.requiredParameterCount)
+                        .toList(),
+                    w.positionalParameters
+                        .skip(w.requiredParameterCount)
+                        .toList(),
+                    w.namedParameters,
+                    w.typeArguments))),
+        (u) => RedirectingFactoryConstructor(u.third,
+            name: u.first,
+            typeParameters: u.fourth.first,
+            positionalParameters:
+                u.fourth.second.first + u.fourth.second.second,
+            requiredParameterCount: u.fourth.second.first.length,
+            namedParameters: u.fourth.second.third,
+            typeArguments: u.fourth.second.fourth)
+          ..flags = u.second,
+        Tuple4Serializer(
+            nameSerializer,
+            redirectingFactoryConstructorFlagsSerializer,
+            CanonicalNameSerializer(),
+            Bind(
                 typeParametersSerializer,
-                new Tuple3Serializer(
-                    new ListSerializer(variableDeclarationSerializer),
-                    new ListSerializer(variableDeclarationSerializer),
-                    new ListSerializer(variableDeclarationSerializer))),
-            new Tuple2Serializer(dartTypeSerializer, statementSerializer)));
+                Tuple4Serializer(
+                    ListSerializer(variableDeclarationSerializer),
+                    ListSerializer(variableDeclarationSerializer),
+                    ListSerializer(variableDeclarationSerializer),
+                    ListSerializer(dartTypeSerializer)))));
 
-FunctionNode wrapSyncYieldingFunctionNode(
-    Tuple2<
-            Tuple2<
-                List<TypeParameter>,
-                Tuple3<List<VariableDeclaration>, List<VariableDeclaration>,
-                    List<VariableDeclaration>>>,
-            Tuple2<DartType, Statement>>
-        tuple) {
-  return new FunctionNode(tuple.second.second,
-      typeParameters: tuple.first.first,
-      positionalParameters:
-          tuple.first.second.first + tuple.first.second.second,
-      namedParameters: tuple.first.second.third,
-      requiredParameterCount: tuple.first.second.first.length,
-      returnType: tuple.second.first,
-      asyncMarker: AsyncMarker.SyncYielding);
-}
+Case<Member> memberSerializer = new Case.uninitialized(const MemberTagger());
 
-Case<FunctionNode> functionNodeSerializer =
-    new Case.uninitialized(const FunctionNodeTagger());
-
-class ProcedureTagger implements Tagger<Procedure> {
-  const ProcedureTagger();
-
-  String tag(Procedure node) {
-    String prefix = node.isStatic ? "static-" : "";
-    switch (node.kind) {
-      case ProcedureKind.Method:
-        return "${prefix}method";
-      default:
-        throw new UnsupportedError("${node.kind}");
-    }
-  }
-}
-
-TextSerializer<Procedure> staticMethodSerializer = new Wrapped(
-    unwrapStaticMethod,
-    wrapStaticMethod,
-    new Tuple2Serializer(nameSerializer, functionNodeSerializer));
-
-Tuple2<Name, FunctionNode> unwrapStaticMethod(Procedure procedure) {
-  return new Tuple2(procedure.name, procedure.function);
-}
-
-Procedure wrapStaticMethod(Tuple2<Name, FunctionNode> tuple) {
-  return new Procedure(tuple.first, ProcedureKind.Method, tuple.second,
-      isStatic: true);
-}
-
-Case<Procedure> procedureSerializer =
-    new Case.uninitialized(const ProcedureTagger());
+TextSerializer<LibraryPart> libraryPartSerializer = Wrapped(
+    (w) => Tuple2(w.partUri, w.annotations),
+    (u) => LibraryPart(u.second, u.first),
+    Tuple2Serializer(DartString(), ListSerializer(expressionSerializer)));
 
 class LibraryTagger implements Tagger<Library> {
   const LibraryTagger();
@@ -1516,22 +1673,390 @@
   }
 }
 
-TextSerializer<Library> libraryContentsSerializer = new Wrapped(
-  unwrapLibraryNode,
-  wrapLibraryNode,
-  new Tuple2Serializer(
-      const UriSerializer(), new ListSerializer(procedureSerializer)),
+const Map<int, String> libraryFlagToName = const {
+  Library.SyntheticFlag: "synthetic",
+  Library.NonNullableByDefaultFlag: "nnbd",
+  Library.NonNullableByDefaultModeBit1Weak: "nnbd-weak",
+  Library.NonNullableByDefaultModeBit2Strong: "nnbd-strong",
+};
+
+class LibraryFlagTagger implements Tagger<int> {
+  const LibraryFlagTagger();
+
+  String tag(int flag) {
+    return libraryFlagToName[flag] ??
+        (throw StateError("Unknown Library flag value: ${flag}."));
+  }
+}
+
+TextSerializer<int> libraryFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        LibraryFlagTagger(),
+        Map.fromIterable(libraryFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
+
+TextSerializer<Library> librarySerializer = new Wrapped(
+  (w) => Tuple7(w.importUri, w.flags, w.parts, [...w.fields, ...w.procedures],
+      w.classes, w.typedefs, w.extensions),
+  (u) => Library(u.first,
+      parts: u.third,
+      fields: u.fourth.where((m) => m is Field).cast<Field>().toList(),
+      procedures:
+          u.fourth.where((m) => m is Procedure).cast<Procedure>().toList(),
+      classes: u.fifth,
+      typedefs: u.sixth,
+      extensions: u.seventh)
+    ..flags = u.second,
+  Tuple7Serializer(
+      UriSerializer(),
+      libraryFlagsSerializer,
+      ListSerializer(libraryPartSerializer),
+      ListSerializer(memberSerializer),
+      ListSerializer(classSerializer),
+      ListSerializer(typedefSerializer),
+      ListSerializer(extensionSerializer)),
 );
 
-Tuple2<Uri, List<Procedure>> unwrapLibraryNode(Library library) {
-  return new Tuple2(library.importUri, library.procedures);
+TextSerializer<Component> componentSerializer = Wrapped(
+    (w) => w.libraries,
+    (u) => Component(nameRoot: CanonicalName.root(), libraries: u),
+    ListSerializer(librarySerializer));
+
+class ShowHideTagger implements Tagger<Combinator> {
+  String tag(Combinator node) => node.isShow ? "show" : "hide";
 }
 
-Library wrapLibraryNode(Tuple2<Uri, List<Procedure>> tuple) {
-  return new Library(tuple.first, procedures: tuple.second);
+TextSerializer<Combinator> showSerializer = Wrapped(
+    (c) => c.names, (ns) => Combinator(true, ns), ListSerializer(DartString()));
+
+TextSerializer<Combinator> hideSerializer = Wrapped((c) => c.names,
+    (ns) => Combinator(false, ns), ListSerializer(DartString()));
+
+Case<Combinator> showHideSerializer = new Case(ShowHideTagger(), {
+  "show": showSerializer,
+  "hide": hideSerializer,
+});
+
+TextSerializer<LibraryDependency> libraryDependencySerializer = Wrapped(
+    (ld) => Tuple5(ld.importedLibraryReference.canonicalName, ld.name,
+        ld.combinators, ld.flags, ld.annotations),
+    (t) => LibraryDependency.byReference(
+        t.fourth, t.fifth, t.first.getReference(), t.second, t.third),
+    Tuple5Serializer(
+        CanonicalNameSerializer(),
+        Optional(DartString()),
+        ListSerializer(showHideSerializer),
+        DartInt(),
+        ListSerializer(expressionSerializer)));
+
+class ConstantTagger extends ConstantVisitor<String>
+    implements Tagger<Constant> {
+  const ConstantTagger();
+
+  String tag(Constant node) => node.accept(this);
+
+  String visitBoolConstant(BoolConstant node) => "const-bool";
+  String visitDoubleConstant(DoubleConstant node) => "const-double";
+  String visitInstanceConstant(InstanceConstant node) => "const-object";
+  String visitIntConstant(IntConstant node) => "const-int";
+  String visitListConstant(ListConstant node) => "const-list";
+  String visitMapConstant(MapConstant node) => "const-map";
+  String visitNullConstant(NullConstant node) => "const-null";
+  String visitPartialInstantiationConstant(PartialInstantiationConstant node) =>
+      "const-apply";
+  String visitSetConstant(SetConstant node) => "const-set";
+  String visitStringConstant(StringConstant node) => "const-string";
+  String visitSymbolConstant(SymbolConstant node) => "const-symbol";
+  String visitTearOffConstant(TearOffConstant node) => "const-tearoff";
+  String visitTypeLiteralConstant(TypeLiteralConstant node) => "const-type";
+  String visitUnevaluatedConstant(UnevaluatedConstant node) => "const-expr";
 }
 
-Case<Library> librarySerializer = new Case.uninitialized(const LibraryTagger());
+TextSerializer<BoolConstant> boolConstantSerializer =
+    Wrapped((w) => w.value, (u) => BoolConstant(u), DartBool());
+
+TextSerializer<DoubleConstant> doubleConstantSerializer =
+    Wrapped((w) => w.value, (u) => DoubleConstant(u), DartDouble());
+
+TextSerializer<IntConstant> intConstantSerializer =
+    Wrapped((w) => w.value, (u) => IntConstant(u), DartInt());
+
+TextSerializer<ListConstant> listConstantSerializer = Wrapped(
+    (w) => Tuple2(w.typeArgument, w.entries),
+    (u) => ListConstant(u.first, u.second),
+    Tuple2Serializer(dartTypeSerializer, ListSerializer(constantSerializer)));
+
+TextSerializer<MapConstant> mapConstantSerializer = Wrapped(
+    (w) => Tuple3(w.keyType, w.valueType, w.entries),
+    (u) => MapConstant(u.first, u.second, u.third),
+    Tuple3Serializer(
+        dartTypeSerializer,
+        dartTypeSerializer,
+        Zip(
+            Tuple2Serializer(ListSerializer(constantSerializer),
+                ListSerializer(constantSerializer)),
+            (k, v) => ConstantMapEntry(k, v),
+            (z) => Tuple2(z.key, z.value))));
+
+TextSerializer<NullConstant> nullConstantSerializer =
+    Wrapped((w) => null, (u) => NullConstant(), Nothing());
+
+TextSerializer<PartialInstantiationConstant>
+    partialInstantiationConstantSerializer = Wrapped(
+        (w) => Tuple2(w.tearOffConstant, w.types),
+        (u) => PartialInstantiationConstant(u.first, u.second),
+        Tuple2Serializer(
+            tearOffConstantSerializer, ListSerializer(dartTypeSerializer)));
+
+TextSerializer<SetConstant> setConstantSerializer = Wrapped(
+    (w) => Tuple2(w.typeArgument, w.entries),
+    (u) => SetConstant(u.first, u.second),
+    Tuple2Serializer(dartTypeSerializer, ListSerializer(constantSerializer)));
+
+TextSerializer<StringConstant> stringConstantSerializer =
+    Wrapped((w) => w.value, (u) => StringConstant(u), DartString());
+
+TextSerializer<SymbolConstant> symbolConstantSerializer = Wrapped(
+    (w) => Tuple2(w.name, w.libraryReference?.canonicalName),
+    (u) => SymbolConstant(u.first, u.second?.getReference()),
+    Tuple2Serializer(DartString(), Optional(CanonicalNameSerializer())));
+
+TextSerializer<TearOffConstant> tearOffConstantSerializer = Wrapped(
+    (w) => w.procedureReference.canonicalName,
+    (u) => TearOffConstant.byReference(u.getReference()),
+    CanonicalNameSerializer());
+
+TextSerializer<TypeLiteralConstant> typeLiteralConstantSerializer =
+    Wrapped((w) => w.type, (u) => TypeLiteralConstant(u), dartTypeSerializer);
+
+TextSerializer<UnevaluatedConstant> unevaluatedConstantSerializer = Wrapped(
+    (w) => w.expression, (u) => UnevaluatedConstant(u), expressionSerializer);
+
+TextSerializer<InstanceConstant> instanceConstantSerializer =
+    Wrapped<
+            Tuple4<CanonicalName, List<DartType>, List<CanonicalName>,
+                List<Constant>>,
+            InstanceConstant>(
+        (w) => Tuple4(
+            w.classReference.canonicalName,
+            w.typeArguments,
+            w.fieldValues.keys.map((r) => r.canonicalName).toList(),
+            w.fieldValues.values.toList()),
+        (u) => InstanceConstant(u.first.getReference(), u.second,
+            Map.fromIterables(u.third.map((c) => c.getReference()), u.fourth)),
+        Tuple4Serializer(
+            CanonicalNameSerializer(),
+            ListSerializer(dartTypeSerializer),
+            ListSerializer(CanonicalNameSerializer()),
+            ListSerializer(constantSerializer)));
+
+Case<Constant> constantSerializer = Case.uninitialized(ConstantTagger());
+
+class InitializerTagger implements Tagger<Initializer> {
+  const InitializerTagger();
+
+  String tag(Initializer node) {
+    if (node is AssertInitializer) {
+      return "assert";
+    } else if (node is FieldInitializer) {
+      return "field";
+    } else if (node is InvalidInitializer) {
+      return "invalid";
+    } else if (node is LocalInitializer) {
+      return "local";
+    } else if (node is RedirectingInitializer) {
+      return "redirecting";
+    } else if (node is SuperInitializer) {
+      return "super";
+    } else {
+      throw UnimplementedError("InitializerTagger.tag(${node.runtimeType}).");
+    }
+  }
+}
+
+TextSerializer<AssertInitializer> assertInitializerSerializer = Wrapped(
+    (w) => w.statement, (u) => AssertInitializer(u), statementSerializer);
+
+TextSerializer<FieldInitializer> fieldInitializerSerializer = Wrapped(
+    (w) => Tuple2(w.fieldReference.canonicalName, w.value),
+    (u) => FieldInitializer.byReference(u.first.getReference(), u.second),
+    Tuple2Serializer(CanonicalNameSerializer(), expressionSerializer));
+
+TextSerializer<InvalidInitializer> invalidInitializerSerializer =
+    Wrapped((_) => null, (_) => InvalidInitializer(), Nothing());
+
+TextSerializer<LocalInitializer> localInitializerSerializer = Wrapped(
+    (w) => w.variable,
+    (u) => LocalInitializer(u),
+    variableDeclarationSerializer);
+
+TextSerializer<RedirectingInitializer> redirectingInitializerSerializer =
+    Wrapped(
+        (w) => Tuple2(w.targetReference.canonicalName, w.arguments),
+        (u) => RedirectingInitializer.byReference(
+            u.first.getReference(), u.second),
+        Tuple2Serializer(CanonicalNameSerializer(), argumentsSerializer));
+
+TextSerializer<SuperInitializer> superInitializerSerializer = Wrapped(
+    (w) => Tuple2(w.targetReference.canonicalName, w.arguments),
+    (u) => SuperInitializer.byReference(u.first.getReference(), u.second),
+    Tuple2Serializer(CanonicalNameSerializer(), argumentsSerializer));
+
+Case<Initializer> initializerSerializer =
+    Case.uninitialized(InitializerTagger());
+
+TextSerializer<Supertype> supertypeSerializer = Wrapped(
+    (w) => Tuple2(w.className.canonicalName, w.typeArguments),
+    (u) => Supertype.byReference(u.first.getReference(), u.second),
+    Tuple2Serializer(
+        CanonicalNameSerializer(), ListSerializer(dartTypeSerializer)));
+
+const Map<int, String> classFlagToName = const {
+  Class.FlagAbstract: "abstract",
+  Class.FlagEnum: "enum",
+  Class.FlagAnonymousMixin: "anonymous-mixin",
+  Class.FlagEliminatedMixin: "eliminated-mixin",
+  Class.FlagMixinDeclaration: "mixin-declaration",
+  Class.FlagHasConstConstructor: "has-const-constructor",
+};
+
+class ClassFlagTagger implements Tagger<int> {
+  const ClassFlagTagger();
+
+  String tag(int flag) {
+    return classFlagToName[flag] ??
+        (throw StateError("Unknown Class flag value: ${flag}."));
+  }
+}
+
+TextSerializer<int> classFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        ClassFlagTagger(),
+        Map.fromIterable(classFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
+
+TextSerializer<Class> classSerializer = Wrapped(
+    (w) => Tuple3(
+        w.name,
+        w.flags,
+        Tuple2(
+            w.typeParameters,
+            Tuple4(w.supertype, w.mixedInType, w.implementedTypes,
+                <Member>[...w.fields, ...w.constructors, ...w.procedures]))),
+    (u) => Class(
+        name: u.first,
+        typeParameters: u.third.first,
+        supertype: u.third.second.first,
+        mixedInType: u.third.second.second,
+        implementedTypes: u.third.second.third,
+        fields: u.third.second.fourth
+            .where((m) => m is Field)
+            .cast<Field>()
+            .toList(),
+        constructors: u.third.second.fourth
+            .where((m) => m is Constructor)
+            .cast<Constructor>()
+            .toList(),
+        procedures: u.third.second.fourth
+            .where((m) => m is Procedure)
+            .cast<Procedure>()
+            .toList())
+      ..flags = u.second,
+    Tuple3Serializer(
+        DartString(),
+        classFlagsSerializer,
+        Bind(
+            typeParametersSerializer,
+            Tuple4Serializer(
+                Optional(supertypeSerializer),
+                Optional(supertypeSerializer),
+                ListSerializer(supertypeSerializer),
+                ListSerializer(memberSerializer)))));
+
+TextSerializer<Typedef> typedefSerializer = Wrapped(
+    (w) => Tuple2(w.name, Tuple2(w.typeParameters, w.type)),
+    (u) => Typedef(u.first, u.second.second, typeParameters: u.second.first),
+    Tuple2Serializer(
+        DartString(), Bind(typeParametersSerializer, dartTypeSerializer)));
+
+const Map<int, String> extensionMemberDescriptorFlagToName = const {
+  ExtensionMemberDescriptor.FlagStatic: "static",
+};
+
+class ExtensionMemberDescriptorFlagTagger implements Tagger<int> {
+  const ExtensionMemberDescriptorFlagTagger();
+
+  String tag(int flag) {
+    return extensionMemberDescriptorFlagToName[flag] ??
+        (throw StateError(
+            "Unknown ExtensionMemberDescriptor flag value: ${flag}."));
+  }
+}
+
+TextSerializer<int> extensionMemberDescriptorFlagsSerializer = Wrapped(
+    (w) => List.generate(30, (i) => w & (1 << i)).where((f) => f != 0).toList(),
+    (u) => u.fold(0, (fs, f) => fs |= f),
+    ListSerializer(Case(
+        ExtensionMemberDescriptorFlagTagger(),
+        Map.fromIterable(extensionMemberDescriptorFlagToName.entries,
+            key: (e) => e.value,
+            value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())))));
+
+const Map<ExtensionMemberKind, String> extensionMemberKindToName = const {
+  ExtensionMemberKind.Field: "field",
+  ExtensionMemberKind.Method: "method",
+  ExtensionMemberKind.Getter: "getter",
+  ExtensionMemberKind.Setter: "setter",
+  ExtensionMemberKind.Operator: "operator",
+  ExtensionMemberKind.TearOff: "tearOff",
+};
+
+class ExtensionMemberKindTagger implements Tagger<ExtensionMemberKind> {
+  const ExtensionMemberKindTagger();
+
+  String tag(ExtensionMemberKind kind) {
+    return extensionMemberKindToName[kind] ??
+        (throw StateError("Unknown ExtensionMemberKind flag value: ${kind}."));
+  }
+}
+
+TextSerializer<ExtensionMemberKind> extensionMemberKindSerializer = Case(
+    ExtensionMemberKindTagger(),
+    Map.fromIterable(extensionMemberKindToName.entries,
+        key: (e) => e.value,
+        value: (e) => Wrapped((_) => null, (_) => e.key, Nothing())));
+
+TextSerializer<ExtensionMemberDescriptor> extensionMemberDescriptorSerializer =
+    Wrapped(
+        (w) => Tuple4(w.name, w.kind, w.flags, w.member.canonicalName),
+        (u) => ExtensionMemberDescriptor()
+          ..name = u.first
+          ..kind = u.second
+          ..flags = u.third
+          ..member = u.fourth.getReference(),
+        Tuple4Serializer(
+            nameSerializer,
+            extensionMemberKindSerializer,
+            extensionMemberDescriptorFlagsSerializer,
+            CanonicalNameSerializer()));
+
+TextSerializer<Extension> extensionSerializer = Wrapped(
+    (w) => Tuple3(w.name, Tuple2(w.typeParameters, w.onType), w.members),
+    (u) => Extension(
+        name: u.first,
+        typeParameters: u.second.first,
+        onType: u.second.second,
+        members: u.third),
+    Tuple3Serializer(
+        DartString(),
+        Bind(typeParametersSerializer, dartTypeSerializer),
+        ListSerializer(extensionMemberDescriptorSerializer)));
 
 void initializeSerializers() {
   expressionSerializer.registerTags({
@@ -1579,6 +2104,17 @@
     "invoke-constructor": constructorInvocationSerializer,
     "invoke-const-constructor": constConstructorInvocationSerializer,
     "fun": functionExpressionSerializer,
+    "lists": listConcatenationSerializer,
+    "sets": setConcatenationSerializer,
+    "maps": mapConcatenationSerializer,
+    "let-block": blockExpressionSerializer,
+    "apply": instantiationSerializer,
+    "not-null": nullCheckSerializer,
+    "with-uri": fileUriExpressionSerializer,
+    "is-loaded": checkLibraryIsLoadedSerializer,
+    "load": loadLibrarySerializer,
+    "const": constantExpressionSerializer,
+    "object": instanceCreationSerializer,
   });
   dartTypeSerializer.registerTags({
     "invalid": invalidTypeSerializer,
@@ -1609,17 +2145,46 @@
     "await-for-in": awaitForInStatementSerializer,
     "assert": assertStatementSerializer,
     "assert-block": assertBlockSerializer,
+    "label": labeledStatementSerializer,
+    "break": breakSerializer,
+    "try-finally": tryFinallySerializer,
+    "try-catch": tryCatchSerializer,
+    "switch": switchStatementSerializer,
+    "continue": continueSwitchStatementSerializer,
+    "local-fun": functionDeclarationSerializer,
   });
-  functionNodeSerializer.registerTags({
-    "sync": syncFunctionNodeSerializer,
-    "async": asyncFunctionNodeSerializer,
-    "sync-star": syncStarFunctionNodeSerializer,
-    "async-star": asyncStarFunctionNodeSerializer,
-    "sync-yielding": syncYieldingStarFunctionNodeSerializer,
+  memberSerializer.registerTags({
+    "field": fieldSerializer,
+    "method": methodSerializer,
+    "getter": getterSerializer,
+    "setter": setterSerializer,
+    "operator": operatorSerializer,
+    "factory": factorySerializer,
+    "constructor": constructorSerializer,
+    "redirecting-factory-constructor": redirectingFactoryConstructorSerializer,
   });
-  procedureSerializer.registerTags({"static-method": staticMethodSerializer});
-  librarySerializer.registerTags({
-    "legacy": libraryContentsSerializer,
-    "null-safe": libraryContentsSerializer,
+  constantSerializer.registerTags({
+    "const-bool": boolConstantSerializer,
+    "const-double": doubleConstantSerializer,
+    "const-int": intConstantSerializer,
+    "const-list": listConstantSerializer,
+    "const-map": mapConstantSerializer,
+    "const-null": nullConstantSerializer,
+    "const-apply": partialInstantiationConstantSerializer,
+    "const-set": setConstantSerializer,
+    "const-string": stringConstantSerializer,
+    "const-symbol": symbolConstantSerializer,
+    "const-tearoff": tearOffConstantSerializer,
+    "const-type": typeLiteralConstantSerializer,
+    "const-expr": unevaluatedConstantSerializer,
+    "const-object": instanceConstantSerializer,
+  });
+  initializerSerializer.registerTags({
+    "assert": assertInitializerSerializer,
+    "field": fieldInitializerSerializer,
+    "invalid": invalidInitializerSerializer,
+    "local": localInitializerSerializer,
+    "redirecting": redirectingInitializerSerializer,
+    "super": superInitializerSerializer,
   });
 }
diff --git a/pkg/kernel/lib/transformations/track_widget_constructor_locations.dart b/pkg/kernel/lib/transformations/track_widget_constructor_locations.dart
index a9e3e13..ec8c8c8 100644
--- a/pkg/kernel/lib/transformations/track_widget_constructor_locations.dart
+++ b/pkg/kernel/lib/transformations/track_widget_constructor_locations.dart
@@ -11,7 +11,7 @@
 
 // Parameter name used to track were widget constructor calls were made from.
 //
-// The parameter name contains a randomly generate hex string to avoid collision
+// The parameter name contains a randomly generated hex string to avoid collision
 // with user generated parameters.
 const String _creationLocationParameterName =
     r'$creationLocationd_0dea112b090073317d4';
@@ -368,8 +368,8 @@
       _hasCreationLocationClass.enclosingLibrary,
     );
     final Field locationField = new Field(fieldName,
-        type: new InterfaceType(
-            _locationClass, clazz.enclosingLibrary.nonNullable),
+        type:
+            new InterfaceType(_locationClass, clazz.enclosingLibrary.nullable),
         isFinal: true,
         reference: clazz.reference.canonicalName
             ?.getChildFromFieldWithName(fieldName)
@@ -389,8 +389,8 @@
       ));
       final VariableDeclaration variable = new VariableDeclaration(
         _creationLocationParameterName,
-        type: new InterfaceType(
-            _locationClass, clazz.enclosingLibrary.nonNullable),
+        type:
+            new InterfaceType(_locationClass, clazz.enclosingLibrary.nullable),
       );
       if (!_maybeAddNamedParameter(constructor.function, variable)) {
         return;
@@ -418,7 +418,11 @@
       if (!hasRedirectingInitializer) {
         constructor.initializers.add(new FieldInitializer(
           locationField,
-          new VariableGet(variable),
+          clazz.enclosingLibrary.isNonNullableByDefault
+              // The parameter is nullable so that it can be optional but the
+              // field is non-nullable so we check it here.
+              ? new NullCheck(new VariableGet(variable))
+              : new VariableGet(variable),
         ));
         // TODO(jacobr): add an assert verifying the locationField is not
         // null. Currently, we cannot safely add this assert because we do not
@@ -535,8 +539,7 @@
           procedure.function,
           new VariableDeclaration(_creationLocationParameterName,
               type: new InterfaceType(
-                  _locationClass, clazz.enclosingLibrary.nonNullable),
-              isRequired: clazz.enclosingLibrary.isNonNullableByDefault),
+                  _locationClass, clazz.enclosingLibrary.nullable)),
         );
       }
     }
@@ -559,8 +562,7 @@
       final VariableDeclaration variable = new VariableDeclaration(
           _creationLocationParameterName,
           type: new InterfaceType(
-              _locationClass, clazz.enclosingLibrary.nonNullable),
-          isRequired: clazz.enclosingLibrary.isNonNullableByDefault);
+              _locationClass, clazz.enclosingLibrary.nullable));
       if (_hasNamedParameter(
           constructor.function, _creationLocationParameterName)) {
         // Constructor was already rewritten. TODO(jacobr): is this case actually hit?
diff --git a/pkg/kernel/test/text_serializer_from_kernel_nodes_test.dart b/pkg/kernel/test/text_serializer_from_kernel_nodes_test.dart
index fd6a3e1..bc84c87 100644
--- a/pkg/kernel/test/text_serializer_from_kernel_nodes_test.dart
+++ b/pkg/kernel/test/text_serializer_from_kernel_nodes_test.dart
@@ -66,7 +66,7 @@
           return new ExpressionStatement(new Let(x, new VariableGet(x)));
         }(),
         expectation: ''
-            '(expr (let (var "x^0" (dynamic) (int 42) ())'
+            '(expr (let "x^0" () (dynamic) (int 42) ()'
             ' (get-var "x^0" _)))',
         serializer: statementSerializer),
     new TestCase<Statement>(
@@ -80,8 +80,8 @@
               new Let(innerLetVar, new VariableGet(outterLetVar))));
         }(),
         expectation: ''
-            '(expr (let (var "x^0" (dynamic) (int 42) ())'
-            ' (let (var "x^1" (bottom) (null) ())'
+            '(expr (let "x^0" () (dynamic) (int 42) ()'
+            ' (let "x^1" () (bottom) (null) ()'
             ' (get-var "x^0" _))))',
         serializer: statementSerializer),
     new TestCase<Statement>(
@@ -95,8 +95,8 @@
               new Let(innerLetVar, new VariableGet(innerLetVar))));
         }(),
         expectation: ''
-            '(expr (let (var "x^0" (dynamic) (int 42) ())'
-            ' (let (var "x^1" (bottom) (null) ())'
+            '(expr (let "x^0" () (dynamic) (int 42) ()'
+            ' (let "x^1" () (bottom) (null) ()'
             ' (get-var "x^1" _))))',
         serializer: statementSerializer),
     () {
@@ -108,13 +108,13 @@
           expectation: '(expr (set-var "x^0" (int 42)))',
           makeSerializationState: () => new SerializationState(
                 new SerializationEnvironment(null)
-                  ..addBinder(x, 'x^0')
-                  ..close(),
+                  ..addBinder(x, nameClue: x.name)
+                  ..extend(),
               ),
           makeDeserializationState: () => new DeserializationState(
               new DeserializationEnvironment(null)
-                ..addBinder('x^0', x)
-                ..close(),
+                ..addBinder(x, "x^0")
+                ..extend(),
               new CanonicalName.root()),
           serializer: statementSerializer);
     }(),
@@ -227,12 +227,12 @@
               ' "package:foo/bar.dart::A::@fields::field"))',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)
-                ..addBinder(x, 'x^0')
-                ..close()),
+                ..addBinder(x, nameClue: 'x')
+                ..extend()),
           makeDeserializationState: () => new DeserializationState(
               new DeserializationEnvironment(null)
-                ..addBinder('x^0', x)
-                ..close(),
+                ..addBinder(x, "x^0")
+                ..extend(),
               component.root),
           serializer: statementSerializer);
     }(),
@@ -256,12 +256,12 @@
               ' "package:foo/bar.dart::A::@fields::field" (int 42)))',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)
-                ..addBinder(x, 'x^0')
-                ..close()),
+                ..addBinder(x, nameClue: 'x')
+                ..extend()),
           makeDeserializationState: () => new DeserializationState(
               new DeserializationEnvironment(null)
-                ..addBinder('x^0', x)
-                ..close(),
+                ..addBinder(x, "x^0")
+                ..extend(),
               component.root),
           serializer: statementSerializer);
     }(),
@@ -288,12 +288,12 @@
               ' () () ()))',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)
-                ..addBinder(x, 'x^0')
-                ..close()),
+                ..addBinder(x, nameClue: 'x')
+                ..extend()),
           makeDeserializationState: () => new DeserializationState(
               new DeserializationEnvironment(null)
-                ..addBinder('x^0', x)
-                ..close(),
+                ..addBinder(x, "x^0")
+                ..extend(),
               component.root),
           serializer: statementSerializer);
     }(),
@@ -389,9 +389,9 @@
               returnType: new TypeParameterType(t, Nullability.legacy),
               asyncMarker: AsyncMarker.Sync))),
           expectation: ''
-              '(expr (fun (sync ("T^0") ((dynamic)) ((dynamic)) ((var '
-              '"t1^1" (par "T^0" _) _ ())) ((var "t2^2" (par "T^0" _) '
-              '_ ())) () (par "T^0" _) (ret (get-var "t1^1" _)))))',
+              '(expr (fun (sync) ("T^0") ((dynamic)) ((dynamic)) ("t1^1" '
+              '() (par "T^0" _) _ ()) ("t2^2" () (par "T^0" _) '
+              '_ ()) () (par "T^0" _) _ (ret (get-var "t1^1" _))))',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)),
           makeDeserializationState: () => new DeserializationState(
@@ -410,18 +410,18 @@
           procedures: [foo]);
       Component component = Component(libraries: [library]);
       component.computeCanonicalNames();
-      return new TestCase<Procedure>(
+      return new TestCase<Member>(
           name: 'foo(x) => x;',
           node: foo,
           expectation: ''
-              '(static-method (public "foo")'
-              ' (sync () () () ((var "x^0" (dynamic) _ ())) () ()'
-              ' (dynamic) (ret (get-var "x^0" _))))',
+              '(method (public "foo") ((static))'
+              ' (sync) () () () ("x^0" () (dynamic) _ ()) () ()'
+              ' (dynamic) _ (ret (get-var "x^0" _)))',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)),
           makeDeserializationState: () => new DeserializationState(
               new DeserializationEnvironment(null), null),
-          serializer: procedureSerializer);
+          serializer: memberSerializer);
     }(),
     () {
       VariableDeclaration x1 = VariableDeclaration('x', type: DynamicType());
@@ -448,16 +448,23 @@
           name: 'foo(x) => x; bar(x) => foo(x);',
           node: library,
           expectation: ''
-              '(legacy "package:foo/bar.dart"'
+              '"package:foo/bar.dart" () ()'
               ''
-              ' ((static-method (public "foo")'
-              ' (sync () () () ((var "x^0" (dynamic) _ ())) () () (dynamic)'
-              ' (ret (get-var "x^0" _))))'
+              ' ((method (public "foo") ((static))'
+              ' (sync) () () () ("x^0" () (dynamic) _ ()) () () (dynamic)'
+              ' _ (ret (get-var "x^0" _)))'
               ''
-              ' (static-method (public "bar")'
-              ' (sync () () () ((var "x^0" (dynamic) _ ())) () () (dynamic)'
-              ' (ret (invoke-static "package:foo/bar.dart::@methods::foo"'
-              ' () ((get-var "x^0" _)) ()))))))',
+              ' (method (public "bar") ((static))'
+              ' (sync) () () () ("x^0" () (dynamic) _ ()) () () (dynamic)'
+              ' _ (ret'
+              ' (invoke-static "package:foo/bar.dart::@methods::foo"'
+              ' () ((get-var "x^0" _)) ()))))'
+              ''
+              ' ()'
+              ''
+              ' ()'
+              ''
+              ' ()',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)),
           makeDeserializationState: () => new DeserializationState(
@@ -480,11 +487,17 @@
           name: 'class A{} A foo() => null;',
           node: library,
           expectation: ''
-              '(legacy "package:foo/bar.dart"'
-              ' ((static-method (public "foo")'
-              ' (sync () () () () () ()'
-              ' (interface "package:foo/bar.dart::A" ())'
-              ' (ret (null))))))',
+              '"package:foo/bar.dart" () ()'
+              ''
+              ' ((method (public "foo") ((static))'
+              ' (sync) () () () () () () (interface "package:foo/bar.dart::A" ())'
+              ' _ (ret (null))))'
+              ''
+              ' ("A" () () () () _ _ () ())'
+              ''
+              ' ()'
+              ''
+              ' ()',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)),
           makeDeserializationState: () => new DeserializationState(
@@ -495,7 +508,7 @@
       return new TestCase<Statement>(
           name: 'dynamic x;',
           node: VariableDeclaration('x', type: const DynamicType()),
-          expectation: '(local (var "x^0" (dynamic) _ ()))',
+          expectation: '(local "x^0" () (dynamic) _ ())',
           makeSerializationState: () =>
               new SerializationState(new SerializationEnvironment(null)),
           makeDeserializationState: () => new DeserializationState(
diff --git a/pkg/kernel/test/text_serializer_test.dart b/pkg/kernel/test/text_serializer_test.dart
index fadf1e2..f4b3631 100644
--- a/pkg/kernel/test/text_serializer_test.dart
+++ b/pkg/kernel/test/text_serializer_test.dart
@@ -10,7 +10,13 @@
 
 void main() {
   initializeSerializers();
-  test();
+  TestRunner testRunner = new TestRunner();
+  testRunner.run();
+  if (testRunner.failures.isNotEmpty) {
+    print('Round trip failures:');
+    testRunner.failures.forEach(print);
+    throw StateError('Round trip failures');
+  }
 }
 
 // Wrappers for testing.
@@ -32,75 +38,73 @@
   return buffer.toString();
 }
 
-void test() {
-  List<String> failures = [];
-  List<String> tests = [
-    '(get-prop (int 0) (public "hashCode"))',
-    '(get-super (public "hashCode"))',
-    '(invoke-method (int 0) (public "foo") () ((int 1) (int 2)) ())',
-    '(invoke-method (int 0) (public "foo") ((dynamic) (void)) '
-        '((int 1) (int 2)) ("others" (list (dynamic) ((int 3) (int 4)))))',
-    '(let (var "x^0" (dynamic) (int 0) ()) (null))',
-    '(let (var "x^0" (dynamic) _ ()) (null))',
-    '(let (const "x^0" (dynamic) (int 0) ()) (null))',
-    '(let (const "x^0" (dynamic) _ ()) (null))',
-    '(let (final "x^0" (dynamic) (int 0) ()) (null))',
-    '(let (final "x^0" (dynamic) _ ()) (null))',
-    r'''(string "Hello, 'string'!")''',
-    r'''(string "Hello, \"string\"!")''',
-    r'''(string "Yeah nah yeah, here is\nthis really long string haiku\n'''
-        r'''blowing in the wind\n")''',
-    '(int 42)',
-    '(int 0)',
-    '(int -1001)',
-    '(double 3.14159)',
-    '(bool true)',
-    '(bool false)',
-    '(null)',
-    r'''(invalid "You can't touch this")''',
-    '(not (bool true))',
-    '(&& (bool true) (bool false))',
-    '(|| (&& (bool true) (not (bool true))) (bool true))',
-    '(concat ((string "The opposite of ") (int 3) '
-        '(string " is ") (int 7)))',
-    '(symbol "unquote-splicing")',
-    '(this)',
-    '(rethrow)',
-    '(throw (string "error"))',
-    '(await (null))',
-    '(cond (bool true) (dynamic) (int 0) (int 1))',
-    '(is (bool true) (invalid))',
-    '(as (bool true) (void))',
-    '(type (bottom))',
-    '(list (dynamic) ((null) (null) (null)))',
-    '(const-list (dynamic) ((int 0) (int 1) (int 2)))',
-    '(set (dynamic) ((bool true) (bool false) (int 0)))',
-    '(const-set (dynamic) ((int 0) (int 1) (int 2)))',
-    '(map (dynamic) (void) ((int 0) (null) (int 1) (null) (int 2) (null)))',
-    '(const-map (dynamic) (void) ((int 0) (null) (int 1) (null) '
-        '(int 2) (null)))',
-    '(type (-> () () () ((dynamic)) () () (dynamic)))',
-    '(type (-> () () () () ((dynamic)) () (dynamic)))',
-    '(type (-> () () () ((dynamic) (dynamic)) () () (dynamic)))',
-    '(type (-> () () () () () () (dynamic)))',
-    '(type (-> () () () ((-> () () () ((dynamic)) () () (dynamic))) () () '
-        '(dynamic)))',
-    '(type (-> ("T^0") ((dynamic)) ((dynamic)) () () () (dynamic)))',
-    '(type (-> ("T^0") ((dynamic)) ((dynamic)) ((par "T^0" _)) () () '
-        '(par "T^0" _)))',
-    '(type (-> ("T^0" "S^1") ((par "S^1" _) (par "T^0" _)) ((dynamic) '
-        '(dynamic)) () () () (dynamic)))',
-  ];
-  for (var test in tests) {
-    var literal = readExpression(test);
-    var output = writeExpression(literal);
-    if (output != test) {
-      failures.add('* input "${test}" gave output "${output}"');
-    }
+class TestRunner {
+  final List<String> failures = [];
+
+  void run() {
+    test('(get-prop (int 0) (public "hashCode"))');
+    test('(get-super (public "hashCode"))');
+    test('(invoke-method (int 0) (public "foo") () ((int 1) (int 2)) ())');
+    test('(invoke-method (int 0) (public "foo") ((dynamic) (void)) '
+        '((int 1) (int 2)) ("others" (list (dynamic) ((int 3) (int 4)))))');
+    test('(let "x^0" () (dynamic) (int 0) () (null))');
+    test('(let "x^0" () (dynamic) _ () (null))');
+    test('(let "x^0" ((const)) (dynamic) (int 0) () (null))');
+    test('(let "x^0" ((const)) (dynamic) _ () (null))');
+    test('(let "x^0" ((final)) (dynamic) (int 0) () (null))');
+    test('(let "x^0" ((final)) (dynamic) _ () (null))');
+    test(r'''(string "Hello, 'string'!")''');
+    test(r'''(string "Hello, \"string\"!")''');
+    test(r'''(string "Yeah nah yeah, here is\nthis really long string haiku\n'''
+        r'''blowing in the wind\n")''');
+    test('(int 42)');
+    test('(int 0)');
+    test('(int -1001)');
+    test('(double 3.14159)');
+    test('(bool true)');
+    test('(bool false)');
+    test('(null)');
+    test(r'''(invalid "You can't touch this")''');
+    test('(not (bool true))');
+    test('(&& (bool true) (bool false))');
+    test('(|| (&& (bool true) (not (bool true))) (bool true))');
+    test('(concat ((string "The opposite of ") (int 3) '
+        '(string " is ") (int 7)))');
+    test('(symbol "unquote-splicing")');
+    test('(this)');
+    test('(rethrow)');
+    test('(throw (string "error"))');
+    test('(await (null))');
+    test('(cond (bool true) (dynamic) (int 0) (int 1))');
+    test('(is (bool true) (invalid))');
+    test('(as (bool true) (void))');
+    test('(type (bottom))');
+    test('(list (dynamic) ((null) (null) (null)))');
+    test('(const-list (dynamic) ((int 0) (int 1) (int 2)))');
+    test('(set (dynamic) ((bool true) (bool false) (int 0)))');
+    test('(const-set (dynamic) ((int 0) (int 1) (int 2)))');
+    test(
+        '(map (dynamic) (void) ((int 0) (null) (int 1) (null) (int 2) (null)))');
+    test('(const-map (dynamic) (void) ((int 0) (null) (int 1) (null) '
+        '(int 2) (null)))');
+    test('(type (-> () () () ((dynamic)) () () (dynamic)))');
+    test('(type (-> () () () () ((dynamic)) () (dynamic)))');
+    test('(type (-> () () () ((dynamic) (dynamic)) () () (dynamic)))');
+    test('(type (-> () () () () () () (dynamic)))');
+    test('(type (-> () () () ((-> () () () ((dynamic)) () () (dynamic))) () () '
+        '(dynamic)))');
+    test('(type (-> ("T^0") ((dynamic)) ((dynamic)) () () () (dynamic)))');
+    test('(type (-> ("T^0") ((dynamic)) ((dynamic)) ((par "T^0" _)) () () '
+        '(par "T^0" _)))');
+    test('(type (-> ("T^0" "S^1") ((par "S^1" _) (par "T^0" _)) ((dynamic) '
+        '(dynamic)) () () () (dynamic)))');
   }
-  if (failures.isNotEmpty) {
-    print('Round trip failures:');
-    failures.forEach(print);
-    throw StateError('Round trip failures');
+
+  void test(String input) {
+    var kernelAst = readExpression(input);
+    var output = writeExpression(kernelAst);
+    if (output != input) {
+      failures.add('* input "${input}" gave output "${output}"');
+    }
   }
 }
diff --git a/pkg/meta/CHANGELOG.md b/pkg/meta/CHANGELOG.md
index 3c6b8de..f79fbff 100644
--- a/pkg/meta/CHANGELOG.md
+++ b/pkg/meta/CHANGELOG.md
@@ -1,6 +1,32 @@
-## 1.2.0-nnbd
+## 1.3.0-nullsafety.2
+
+* Update for the 2.10 dev sdk.
+
+## 1.3.0-nullsafety.1
+
+* Allow the <=2.9.10 stable sdk.
+
+## 1.3.0-nullsafety
 
 * Opt into null safety.
+
+## 1.2.2
+
+* Removed `unawaited` because the attempt to move it from `package:pedantic`
+  caused too many issues. If you see errors about `unawaited` being declared in
+  two places, please update the version constraints for `meta` to `1.2.2` or
+  later.
+
+## 1.2.1
+
+* Fixed a bug by adding an import of dart:async so that the code really is
+  compatible with the lower bound of the SDK constraints.
+
+## 1.2.0
+
+* Introduce `unawaited` to mark invocations that return a `Future` where it's
+  intentional that the future is not being awaited. (Moved from
+  `package:pedantic`.)
 * Introduce `@doNotStore` to annotate methods, getters and functions to
   indicate that values obtained by invoking them should not be stored in a
   field or top-level variable.
diff --git a/pkg/meta/lib/meta.dart b/pkg/meta/lib/meta.dart
index 7f93368..b123407 100644
--- a/pkg/meta/lib/meta.dart
+++ b/pkg/meta/lib/meta.dart
@@ -1,8 +1,9 @@
-// Copyright (c) 2016, the Dart project authors.  Please see the AUTHORS file
+// Copyright (c) 2016, 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.
 
-/// Constants for use in metadata annotations.
+/// Annotations that developers can use to express the intentions that otherwise
+/// can't be deduced by statically analyzing the source code.
 ///
 /// See also `@deprecated` and `@override` in the `dart:core` library.
 ///
@@ -12,7 +13,7 @@
 /// function's name differently.
 ///
 /// For information on installing and importing this library, see the [meta
-/// package on pub.dev](https://pub.dev/packages/meta).  For examples of using
+/// package on pub.dev](https://pub.dev/packages/meta). For examples of using
 /// annotations, see
 /// [Metadata](https://dart.dev/guides/language/language-tour#metadata) in the
 /// language tour.
diff --git a/pkg/meta/lib/meta_meta.dart b/pkg/meta/lib/meta_meta.dart
new file mode 100644
index 0000000..5090b05
--- /dev/null
+++ b/pkg/meta/lib/meta_meta.dart
@@ -0,0 +1,83 @@
+// 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.
+
+/// Annotations that describe the intended use of other annotations.
+library meta_meta;
+
+/// An annotation used on classes that are intended to be used as annotations
+/// to indicate the kinds of declarations and directives for which the
+/// annotation is appropriate.
+///
+/// The kinds are represented by the constants defined in [TargetKind].
+///
+/// Tools, such as the analyzer, can provide feedback if
+///
+/// * the annotation is associated with anything other than a class, where the
+///   class must be usable as an annotation (that is, contain at least one
+///   `const` constructor).
+/// * the annotated annotation is associated with anything other than the kinds
+///   of declarations listed as valid targets.
+@Target({TargetKind.classType})
+class Target {
+  /// The kinds of declarations with which the annotated annotation can be
+  /// associated.
+  final Set<TargetKind> kinds;
+
+  const Target(this.kinds);
+}
+
+/// An enumeration of the kinds of targets to which an annotation can be
+/// applied.
+enum TargetKind {
+  /// Indicates that an annotation is valid on any class declaration.
+  classType,
+
+  /// Indicates that an annotation is valid on any enum declaration.
+  enumType,
+
+  /// Indicates that an annotation is valid on any extension declaration.
+  extension,
+
+  /// Indicates that an annotation is valid on any field declaration, both
+  /// instance and static fields, whether it's in a class, mixin or extension.
+  field,
+
+  /// Indicates that an annotation is valid on any top-level function
+  /// declaration.
+  function,
+
+  /// Indicates that an annotation is valid on the first directive in a library,
+  /// whether that's a `library`, `import`, `export` or `part` directive. This
+  /// doesn't include the `part of` directive in a part file.
+  library,
+
+  /// Indicates that an annotation is valid on any getter declaration, both
+  /// instance or static getters, whether it's in a class, mixin, extension, or
+  /// at the top-level of a library.
+  getter,
+
+  /// Indicates that an annotation is valid on any method declaration, both
+  /// instance and static methods, whether it's in a class, mixin or extension.
+  method,
+
+  /// Indicates that an annotation is valid on any mixin declaration.
+  mixinType,
+
+  /// Indicates that an annotation is valid on any formal parameter declaration,
+  /// whether it's in a function, method, constructor, or closure.
+  parameter,
+
+  /// Indicates that an annotation is valid on any setter declaration, both
+  /// instance or static setters, whether it's in a class, mixin, extension, or
+  /// at the top-level of a library.
+  setter,
+
+  /// Indicates that an annotation is valid on any declaration that introduces a
+  /// type. This includes classes, enums, mixins and typedefs, but does not
+  /// include extensions because extensions don't introduce a type.
+  type,
+
+  /// Indicates that an annotation is valid on any typedef declaration.
+  typedefType,
+}
diff --git a/pkg/meta/pubspec.yaml b/pkg/meta/pubspec.yaml
index 0a745e0..dfad765 100644
--- a/pkg/meta/pubspec.yaml
+++ b/pkg/meta/pubspec.yaml
@@ -1,12 +1,11 @@
 name: meta
-version: 1.2.0-nnbd
-author: Dart Team <misc@dartlang.org>
+version: 1.3.0-nullsafety.2
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/meta
 description: >
- This library contains the definitions of annotations that provide additional
- semantic information about the program being annotated. These annotations are
- intended to be used by tools to provide a better user experience.
+ This library contains the declarations of annotations that developers can use
+ to express the intentions that otherwise can't be deduced by statically
+ analyzing the source code. These annotations are intended to be used by tools
+ to provide a better user experience.
 environment:
-  # This must remain a tight constraint (only allow dev versions) until nnbd is
-  # stable.
-  sdk: '>=2.9.0-18.0 <2.9.0'
+  # This must remain a tight constraint until nnbd is stable
+  sdk: '>=2.10.0-0 <2.10.0'
diff --git a/pkg/modular_test/test/loader/default_package_dependency_error/expectation.txt b/pkg/modular_test/test/loader/default_package_dependency_error/expectation.txt
index 05c6043..e00a4e2 100644
--- a/pkg/modular_test/test/loader/default_package_dependency_error/expectation.txt
+++ b/pkg/modular_test/test/loader/default_package_dependency_error/expectation.txt
@@ -23,6 +23,7 @@
   dependencies: sdk
   lib/dart2js.dart
   lib/meta.dart
+  lib/meta_meta.dart
 
 sdk
   is package? no
diff --git a/pkg/modular_test/test/loader/valid_packages/expectation.txt b/pkg/modular_test/test/loader/valid_packages/expectation.txt
index 680cfc5..e3bfaeb 100644
--- a/pkg/modular_test/test/loader/valid_packages/expectation.txt
+++ b/pkg/modular_test/test/loader/valid_packages/expectation.txt
@@ -32,6 +32,7 @@
   dependencies: sdk
   lib/dart2js.dart
   lib/meta.dart
+  lib/meta_meta.dart
 
 sdk
   is package? no
diff --git a/pkg/nnbd_migration/lib/migration_cli.dart b/pkg/nnbd_migration/lib/migration_cli.dart
index 8573990..7e91a82 100644
--- a/pkg/nnbd_migration/lib/migration_cli.dart
+++ b/pkg/nnbd_migration/lib/migration_cli.dart
@@ -44,7 +44,6 @@
 
 /// Data structure recording command-line options for the migration tool that
 /// have been passed in by the client.
-@visibleForTesting
 class CommandLineOptions {
   static const applyChangesFlag = 'apply-changes';
   static const helpFlag = 'help';
@@ -168,9 +167,6 @@
       _logger.stderr('');
       _logger.stderr('Visit https://dart.dev/tools/pub/cmd/pub-outdated for '
           'more information.');
-      _logger.stderr('');
-      _logger.stderr('You can force migration with '
-          "'--${CommandLineOptions.skipPubOutdatedFlag}' (not recommended).");
       return false;
     }
     return true;
@@ -501,6 +497,10 @@
 
   ResourceProvider get resourceProvider => cli.resourceProvider;
 
+  /// Called after changes have been applied on disk.  Maybe overridden by a
+  /// derived class.
+  void applyHook() {}
+
   /// Blocks until an interrupt signal (control-C) is received.  Tests may
   /// override this method to simulate control-C.
   @visibleForTesting
@@ -702,6 +702,7 @@
         }
       }
     }
+    applyHook();
   }
 
   void _checkDependencies() {
@@ -1025,7 +1026,7 @@
     });
     var state = await _task.finish();
     if (_migrationCli.options.webPreview) {
-      await _task.startPreviewServer(state);
+      await _task.startPreviewServer(state, _migrationCli.applyHook);
     }
     _progressBar.complete();
 
diff --git a/pkg/nnbd_migration/lib/src/decorated_type_operations.dart b/pkg/nnbd_migration/lib/src/decorated_type_operations.dart
index 05ad82a..1ff9b47 100644
--- a/pkg/nnbd_migration/lib/src/decorated_type_operations.dart
+++ b/pkg/nnbd_migration/lib/src/decorated_type_operations.dart
@@ -57,6 +57,11 @@
   }
 
   @override
+  bool isNever(DecoratedType type) {
+    return false;
+  }
+
+  @override
   bool isSameType(DecoratedType type1, DecoratedType type2) {
     return type1 == type2;
   }
diff --git a/pkg/nnbd_migration/lib/src/edge_builder.dart b/pkg/nnbd_migration/lib/src/edge_builder.dart
index d60252d..5f0abe0 100644
--- a/pkg/nnbd_migration/lib/src/edge_builder.dart
+++ b/pkg/nnbd_migration/lib/src/edge_builder.dart
@@ -9,12 +9,13 @@
 import 'package:analyzer/dart/element/element.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/dart/element/type_system.dart';
 import 'package:analyzer/src/dart/element/inheritance_manager3.dart';
 import 'package:analyzer/src/dart/element/type.dart';
+import 'package:analyzer/src/dart/element/type_system.dart' show TypeSystemImpl;
 import 'package:analyzer/src/dart/resolver/flow_analysis_visitor.dart';
 import 'package:analyzer/src/error/best_practices_verifier.dart';
 import 'package:analyzer/src/generated/source.dart';
-import 'package:analyzer/src/generated/type_system.dart';
 import 'package:meta/meta.dart';
 import 'package:nnbd_migration/fix_reason_target.dart';
 import 'package:nnbd_migration/instrumentation.dart';
diff --git a/pkg/nnbd_migration/lib/src/fix_builder.dart b/pkg/nnbd_migration/lib/src/fix_builder.dart
index c53d9a5..4ac58a0 100644
--- a/pkg/nnbd_migration/lib/src/fix_builder.dart
+++ b/pkg/nnbd_migration/lib/src/fix_builder.dart
@@ -19,12 +19,12 @@
 import 'package:analyzer/src/dart/element/member.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
+import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/error/best_practices_verifier.dart';
 import 'package:analyzer/src/generated/element_type_provider.dart';
 import 'package:analyzer/src/generated/migration.dart';
 import 'package:analyzer/src/generated/resolver.dart';
 import 'package:analyzer/src/generated/source.dart';
-import 'package:analyzer/src/generated/type_system.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
 import 'package:analyzer/src/task/strong/checker.dart';
 import 'package:nnbd_migration/fix_reason_target.dart';
diff --git a/pkg/nnbd_migration/lib/src/front_end/non_nullable_fix.dart b/pkg/nnbd_migration/lib/src/front_end/non_nullable_fix.dart
index 9e385ee..f8dfd83 100644
--- a/pkg/nnbd_migration/lib/src/front_end/non_nullable_fix.dart
+++ b/pkg/nnbd_migration/lib/src/front_end/non_nullable_fix.dart
@@ -183,9 +183,11 @@
     _server = null;
   }
 
-  Future<void> startPreviewServer(MigrationState state) async {
+  Future<void> startPreviewServer(
+      MigrationState state, void Function() applyHook) async {
     if (_server == null) {
-      _server = HttpPreviewServer(state, rerun, bindAddress, preferredPort);
+      _server = HttpPreviewServer(
+          state, rerun, applyHook, bindAddress, preferredPort);
       _server.serveHttp();
       _allServers.add(_server);
       var serverHostname = await _server.boundHostname;
diff --git a/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart b/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
index 85b7e2c..38a48e2 100644
--- a/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
+++ b/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
@@ -5,8 +5,8 @@
 import 'package:analyzer/dart/analysis/results.dart';
 import 'package:analyzer/file_system/physical_file_system.dart';
 import 'package:analyzer/src/dart/analysis/session.dart';
+import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/generated/source.dart';
-import 'package:analyzer/src/generated/type_system.dart';
 import 'package:analyzer_plugin/protocol/protocol_common.dart';
 import 'package:nnbd_migration/instrumentation.dart';
 import 'package:nnbd_migration/nnbd_migration.dart';
diff --git a/pkg/nnbd_migration/lib/src/preview/http_preview_server.dart b/pkg/nnbd_migration/lib/src/preview/http_preview_server.dart
index 18eefbb..9c335ff 100644
--- a/pkg/nnbd_migration/lib/src/preview/http_preview_server.dart
+++ b/pkg/nnbd_migration/lib/src/preview/http_preview_server.dart
@@ -35,6 +35,10 @@
   // A function which allows the migration to be rerun, taking changed paths.
   final Future<MigrationState> Function() rerunFunction;
 
+  /// Callback function that should be invoked after successfully applying
+  /// migration.
+  final void Function() applyHook;
+
   /// The internet address the server should bind to.  Should be suitable for
   /// passing to HttpServer.bind, i.e. either a [String] or an
   /// [InternetAddress].
@@ -45,13 +49,13 @@
   final int preferredPort;
 
   /// Initialize a newly created HTTP server.
-  HttpPreviewServer(this.migrationState, this.rerunFunction, this.bindAddress,
-      this.preferredPort)
+  HttpPreviewServer(this.migrationState, this.rerunFunction, this.applyHook,
+      this.bindAddress, this.preferredPort)
       : assert(bindAddress is String || bindAddress is InternetAddress);
 
   Future<String> get authToken async {
     await _serverFuture;
-    previewSite ??= PreviewSite(migrationState, rerunFunction);
+    previewSite ??= PreviewSite(migrationState, rerunFunction, applyHook);
     return previewSite.serviceAuthToken;
   }
 
@@ -93,13 +97,13 @@
 
   /// Handle a GET request received by the HTTP server.
   Future<void> _handleGetRequest(HttpRequest request) async {
-    previewSite ??= PreviewSite(migrationState, rerunFunction);
+    previewSite ??= PreviewSite(migrationState, rerunFunction, applyHook);
     await previewSite.handleGetRequest(request);
   }
 
   /// Handle a POST request received by the HTTP server.
   Future<void> _handlePostRequest(HttpRequest request) async {
-    previewSite ??= PreviewSite(migrationState, rerunFunction);
+    previewSite ??= PreviewSite(migrationState, rerunFunction, applyHook);
     await previewSite.handlePostRequest(request);
   }
 
diff --git a/pkg/nnbd_migration/lib/src/preview/preview_site.dart b/pkg/nnbd_migration/lib/src/preview/preview_site.dart
index 9e02a7b..f77ee13 100644
--- a/pkg/nnbd_migration/lib/src/preview/preview_site.dart
+++ b/pkg/nnbd_migration/lib/src/preview/preview_site.dart
@@ -81,11 +81,15 @@
   // A function provided by DartFix to rerun the migration.
   final Future<MigrationState> Function() rerunFunction;
 
+  /// Callback function that should be invoked after successfully applying
+  /// migration.
+  final void Function() applyHook;
+
   final String serviceAuthToken = _makeAuthToken();
 
   /// Initialize a newly created site to serve a preview of the results of an
   /// NNBD migration.
-  PreviewSite(this.migrationState, this.rerunFunction)
+  PreviewSite(this.migrationState, this.rerunFunction, this.applyHook)
       : super('NNBD Migration Preview') {
     reset();
   }
@@ -266,6 +270,7 @@
       code = SourceEdit.applySequence(code, fileEdit.edits);
       file.writeAsStringSync(code);
     }
+    applyHook();
   }
 
   /// Perform the edit indicated by the [uri].
diff --git a/pkg/nnbd_migration/lib/src/variables.dart b/pkg/nnbd_migration/lib/src/variables.dart
index 9744968..b5d533d 100644
--- a/pkg/nnbd_migration/lib/src/variables.dart
+++ b/pkg/nnbd_migration/lib/src/variables.dart
@@ -286,7 +286,7 @@
   DartType toFinalType(DecoratedType decoratedType) {
     var type = decoratedType.type;
     if (type.isVoid || type.isDynamic) return type;
-    if (type.isBottom || type.isDartCoreNull) {
+    if (type is NeverType || type.isDartCoreNull) {
       if (decoratedType.node.isNullable) {
         return (_typeProvider.nullType as TypeImpl)
             .withNullability(NullabilitySuffix.none);
diff --git a/pkg/nnbd_migration/pubspec.yaml b/pkg/nnbd_migration/pubspec.yaml
index ec7cff3..2495d9c 100644
--- a/pkg/nnbd_migration/pubspec.yaml
+++ b/pkg/nnbd_migration/pubspec.yaml
@@ -6,7 +6,7 @@
   sdk: '>=2.6.0 <3.0.0'
 dependencies:
   _fe_analyzer_shared: ^4.0.0
-  analyzer: ^0.39.11-dev
+  analyzer: ^0.39.12
   analyzer_plugin: ^0.2.4
   args: ^1.4.4
   charcode: ^1.1.2
diff --git a/pkg/nnbd_migration/test/abstract_single_unit.dart b/pkg/nnbd_migration/test/abstract_single_unit.dart
index 6c62f9e..cfb022a 100644
--- a/pkg/nnbd_migration/test/abstract_single_unit.dart
+++ b/pkg/nnbd_migration/test/abstract_single_unit.dart
@@ -52,6 +52,7 @@
             error.errorCode != HintCode.UNUSED_CATCH_CLAUSE &&
             error.errorCode != HintCode.UNUSED_CATCH_STACK &&
             error.errorCode != HintCode.UNUSED_ELEMENT &&
+            error.errorCode != HintCode.UNUSED_ELEMENT_PARAMETER &&
             error.errorCode != HintCode.UNUSED_FIELD &&
             error.errorCode != HintCode.UNUSED_IMPORT &&
             error.errorCode != HintCode.UNUSED_LOCAL_VARIABLE;
diff --git a/pkg/nnbd_migration/test/api_test.dart b/pkg/nnbd_migration/test/api_test.dart
index f197947..b7597fe 100644
--- a/pkg/nnbd_migration/test/api_test.dart
+++ b/pkg/nnbd_migration/test/api_test.dart
@@ -576,6 +576,30 @@
     await _checkSingleFileChanges(content, expected);
   }
 
+  Future<void> test_class_type_param_bound_references_class() async {
+    var content = '''
+class Node<T extends Node<T>> {
+  final List<T> nodes = <T>[];
+}
+class C extends Node<C> {}
+main() {
+  var x = C();
+  x.nodes.add(x);
+}
+''';
+    var expected = '''
+class Node<T extends Node<T>> {
+  final List<T> nodes = <T>[];
+}
+class C extends Node<C> {}
+main() {
+  var x = C();
+  x.nodes.add(x);
+}
+''';
+    await _checkSingleFileChanges(content, expected);
+  }
+
   Future<void> test_class_with_default_constructor() async {
     var content = '''
 void main() => f(Foo());
diff --git a/pkg/nnbd_migration/test/edge_builder_test.dart b/pkg/nnbd_migration/test/edge_builder_test.dart
index bf2f75b..c39e923 100644
--- a/pkg/nnbd_migration/test/edge_builder_test.dart
+++ b/pkg/nnbd_migration/test/edge_builder_test.dart
@@ -7,13 +7,14 @@
 import 'package:analyzer/dart/element/nullability_suffix.dart';
 import 'package:analyzer/dart/element/type.dart';
 import 'package:analyzer/dart/element/type_provider.dart';
+import 'package:analyzer/dart/element/type_system.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
 import 'package:analyzer/src/dart/element/type_provider.dart';
+import 'package:analyzer/src/dart/element/type_system.dart' show TypeSystemImpl;
 import 'package:analyzer/src/dart/error/hint_codes.dart';
 import 'package:analyzer/src/generated/source.dart';
 import 'package:analyzer/src/generated/testing/test_type_provider.dart';
-import 'package:analyzer/src/generated/type_system.dart';
 import 'package:nnbd_migration/fix_reason_target.dart';
 import 'package:nnbd_migration/instrumentation.dart';
 import 'package:nnbd_migration/src/decorated_class_hierarchy.dart';
diff --git a/pkg/nnbd_migration/test/migration_cli_test.dart b/pkg/nnbd_migration/test/migration_cli_test.dart
index cdacccf..ce1f1e3 100644
--- a/pkg/nnbd_migration/test/migration_cli_test.dart
+++ b/pkg/nnbd_migration/test/migration_cli_test.dart
@@ -27,6 +27,7 @@
 import 'package:nnbd_migration/src/front_end/web/file_details.dart';
 import 'package:nnbd_migration/src/front_end/web/navigation_tree.dart';
 import 'package:nnbd_migration/src/messages.dart' as messages;
+import 'package:nnbd_migration/src/preview/preview_site.dart';
 import 'package:path/path.dart' as path;
 import 'package:test/test.dart';
 import 'package:test_reflective_loader/test_reflective_loader.dart';
@@ -81,6 +82,10 @@
 class _MigrationCli extends MigrationCli {
   final _MigrationCliTestBase _test;
 
+  /// If non-null, callback function that will be invoked by the `applyHook`
+  /// override.
+  void Function() _onApplyHook;
+
   _MigrationCli(this._test)
       : super(
             binaryName: 'nnbd_migration',
@@ -108,6 +113,12 @@
   _MigrationCli get cli => super.cli as _MigrationCli;
 
   @override
+  void applyHook() {
+    super.applyHook();
+    cli._onApplyHook?.call();
+  }
+
+  @override
   Future<void> blockUntilSignalInterrupt() async {
     if (_runWhilePreviewServerActive == null) {
       fail('Preview server not expected to have been started');
@@ -554,10 +565,19 @@
   test_lifecycle_apply_changes() async {
     var projectContents = simpleProject();
     var projectDir = await createProjectDir(projectContents);
-    var cliRunner = _createCli().decodeCommandLineArgs(
+    var cli = _createCli();
+    var cliRunner = cli.decodeCommandLineArgs(
         _parseArgs(['--no-web-preview', '--apply-changes', projectDir]));
+    bool applyHookCalled = false;
+    cli._onApplyHook = () {
+      expect(applyHookCalled, false);
+      applyHookCalled = true;
+      // Changes should have been made
+      assertProjectContents(projectDir, simpleProject(migrated: true));
+    };
     await cliRunner.run();
     assertNormalExit(cliRunner);
+    expect(applyHookCalled, true);
     // Check that a summary was printed
     expect(logger.stdoutBuffer.toString(), contains('Applying changes'));
     // And that it refers to test.dart and pubspec.yaml
@@ -565,8 +585,6 @@
     expect(logger.stdoutBuffer.toString(), contains('pubspec.yaml'));
     // And that it does not tell the user they can rerun with `--apply-changes`
     expect(logger.stdoutBuffer.toString(), isNot(contains('--apply-changes')));
-    // Changes should have been made
-    assertProjectContents(projectDir, simpleProject(migrated: true));
   }
 
   test_lifecycle_contextdiscovery_handles_multiple() async {
@@ -815,6 +833,33 @@
     });
   }
 
+  test_lifecycle_preview_apply_changes() async {
+    var projectContents = simpleProject();
+    var projectDir = await createProjectDir(projectContents);
+    var cli = _createCli();
+    bool applyHookCalled = false;
+    cli._onApplyHook = () {
+      expect(applyHookCalled, false);
+      applyHookCalled = true;
+      // Changes should have been made
+      assertProjectContents(projectDir, simpleProject(migrated: true));
+    };
+    await runWithPreviewServer(cli, [projectDir], (url) async {
+      expect(
+          logger.stdoutBuffer.toString(), contains('No analysis issues found'));
+      await assertPreviewServerResponsive(url);
+      var uri = Uri.parse(url);
+      var authToken = uri.queryParameters['authToken'];
+      var response = await http.post(
+          uri.replace(
+              path: PreviewSite.applyMigrationPath,
+              queryParameters: {'authToken': authToken}),
+          headers: {'Content-Type': 'application/json; charset=UTF-8'});
+      assertHttpSuccess(response);
+      expect(applyHookCalled, true);
+    });
+  }
+
   test_lifecycle_preview_extra_forward_slash() async {
     var projectDir = await createProjectDir(simpleProject());
     var cli = _createCli();
diff --git a/pkg/nnbd_migration/test/migration_visitor_test_base.dart b/pkg/nnbd_migration/test/migration_visitor_test_base.dart
index ea65844..3397d54 100644
--- a/pkg/nnbd_migration/test/migration_visitor_test_base.dart
+++ b/pkg/nnbd_migration/test/migration_visitor_test_base.dart
@@ -8,8 +8,8 @@
 import 'package:analyzer/dart/element/type_provider.dart';
 import 'package:analyzer/src/dart/element/element.dart';
 import 'package:analyzer/src/dart/element/type.dart';
+import 'package:analyzer/src/dart/element/type_system.dart';
 import 'package:analyzer/src/generated/source.dart';
-import 'package:analyzer/src/generated/type_system.dart';
 import 'package:analyzer/src/generated/utilities_dart.dart';
 import 'package:meta/meta.dart';
 import 'package:nnbd_migration/instrumentation.dart';
diff --git a/pkg/nnbd_migration/test/preview/preview_site_test.dart b/pkg/nnbd_migration/test/preview/preview_site_test.dart
index 607fb30..f32b003 100644
--- a/pkg/nnbd_migration/test/preview/preview_site_test.dart
+++ b/pkg/nnbd_migration/test/preview/preview_site_test.dart
@@ -44,7 +44,7 @@
     state.migrationInfo = migrationInfo;
     site = PreviewSite(state, () async {
       return state;
-    });
+    }, () {});
   }
 
   void test_apply_regress41391() async {
@@ -198,7 +198,7 @@
     state.migrationInfo = migrationInfo;
     site = PreviewSite(state, () async {
       return state;
-    });
+    }, () {});
   }
 
   void test_applyHintAction() async {
diff --git a/pkg/test_runner/lib/src/browser.dart b/pkg/test_runner/lib/src/browser.dart
index 9c8a16a..67238df 100644
--- a/pkg/test_runner/lib/src/browser.dart
+++ b/pkg/test_runner/lib/src/browser.dart
@@ -145,16 +145,17 @@
 /// or extension, like "math_test". [testNameAlias] is the alias of the
 /// test variable used for import/export (usually relative to its module root).
 /// [testJSDir] is the relative path to the build directory where the
-/// dartdevc-generated JS file is stored.
+/// dartdevc-generated JS file is stored. [nonNullAsserts] enables non-null
+/// assertions for non-nullable method parameters when running with weak null
+/// safety.
 String dartdevcHtml(String testName, String testNameAlias, String testJSDir,
-    Compiler compiler, NnbdMode mode) {
+    Compiler compiler, NnbdMode mode, bool nonNullAsserts) {
   var testId = pathToJSIdentifier(testName);
   var testIdAlias = pathToJSIdentifier(testNameAlias);
-  var isKernel = compiler == Compiler.dartdevk;
   var isNnbd = mode != NnbdMode.legacy;
   var isNnbdStrong = mode == NnbdMode.strong;
-  var sdkPath = isKernel ? 'kernel/amd/dart_sdk' : 'js/amd/dart_sdk';
-  var pkgDir = isKernel ? 'pkg_kernel' : 'pkg';
+  var sdkPath = isNnbdStrong ? 'sound/amd/dart_sdk' : 'kernel/amd/dart_sdk';
+  var pkgDir = isNnbdStrong ? 'pkg_sound' : 'pkg_kernel';
   var packagePaths = testPackages
       .map((p) => '    "$p": "/root_build/gen/utils/dartdevc/$pkgDir/$p",')
       .join("\n");
@@ -232,8 +233,8 @@
   };
 
   if ($isNnbd) {
-    sdk.dart.nullSafety($isNnbdStrong);
     sdk.dart.weakNullSafetyWarnings(!$isNnbdStrong);
+    sdk.dart.nonNullAsserts($nonNullAsserts);
   }
 
   dartMainRunner(function testMainWrapper() {
diff --git a/pkg/test_runner/lib/src/compiler_configuration.dart b/pkg/test_runner/lib/src/compiler_configuration.dart
index 03ff446..59bedc2 100644
--- a/pkg/test_runner/lib/src/compiler_configuration.dart
+++ b/pkg/test_runner/lib/src/compiler_configuration.dart
@@ -419,8 +419,12 @@
 
   List<String> computeCompilerArguments(
       TestFile testFile, List<String> vmOptions, List<String> args) {
+    // TODO(#42403) Handle this option if dart2js supports non-nullable asserts
+    // on non-nullable method arguments.
+    var options = testFile.sharedOptions.toList();
+    options.remove('--null-assertions');
     return [
-      ...testFile.sharedOptions,
+      ...options,
       ..._configuration.sharedOptions,
       ..._experimentsArgument(_configuration, testFile),
       ...testFile.dart2jsOptions,
@@ -510,6 +514,11 @@
   Command _createCommand(String inputFile, String outputFile,
       List<String> sharedOptions, Map<String, String> environment) {
     var args = <String>[];
+    // Remove option for generating non-null assertions for non-nullable
+    // method parameters in weak mode. DDC treats this as a runtime flag for
+    // the bootstrapping code, instead of a compiler option.
+    var options = sharedOptions.toList();
+    options.remove('--null-assertions');
     if (!_useSdk) {
       // If we're testing a built SDK, DDC will find its own summary.
       //
@@ -524,7 +533,7 @@
           .toNativePath();
       args.addAll(["--dart-sdk-summary", sdkSummary]);
     }
-    args.addAll(sharedOptions);
+    args.addAll(options);
     args.addAll(_configuration.sharedOptions);
 
     args.addAll([
@@ -699,10 +708,19 @@
     var args = [
       if (_configuration.useElf) ...[
         "--snapshot-kind=app-aot-elf",
-        "--elf=$tempDir/out.aotsnapshot"
+        "--elf=$tempDir/out.aotsnapshot",
       ] else ...[
         "--snapshot-kind=app-aot-assembly",
-        "--assembly=$tempDir/out.S"
+        "--assembly=$tempDir/out.S",
+      ],
+      // Only splitting with a ELF to avoid having to setup compilation of
+      // multiple assembly files in the test harness. Only splitting tests of
+      // deferred imports because splitting currently requires disable bare
+      // instructions mode, and we want to continue testing bare instructions
+      // mode.
+      if (_configuration.useElf && arguments.last.contains("deferred")) ...[
+        "--loading-unit-manifest=$tempDir/ignored.json",
+        "--use-bare-instructions=false",
       ],
       if (_isAndroid && _isArm) '--no-sim-use-hardfp',
       if (_configuration.isMinified) '--obfuscate',
@@ -1179,8 +1197,12 @@
   @override
   List<String> computeCompilerArguments(
       TestFile testFile, List<String> vmOptions, List<String> args) {
+    // Remove shared option for generating non-null assertions for non-nullable
+    // method parameters in weak mode. It's currently unused by the front end.
+    var options = testFile.sharedOptions.toList();
+    options.remove('--null-assertions');
     var arguments = [
-      ...testFile.sharedOptions,
+      ...options,
       ..._configuration.sharedOptions,
       ..._experimentsArgument(_configuration, testFile),
       if (_configuration.configuration.nnbdMode == NnbdMode.strong) ...[
diff --git a/pkg/test_runner/lib/src/configuration.dart b/pkg/test_runner/lib/src/configuration.dart
index dfc966e..c5d61b0 100644
--- a/pkg/test_runner/lib/src/configuration.dart
+++ b/pkg/test_runner/lib/src/configuration.dart
@@ -459,6 +459,7 @@
         mode.name.substring(0, 1).toUpperCase() + mode.name.substring(1);
 
     if (system == System.android) result += "Android";
+    if (system == System.fuchsia) result += "Fuchsia";
 
     if (sanitizer != Sanitizer.none) {
       result += sanitizer.name.toUpperCase();
diff --git a/pkg/test_runner/lib/src/fuchsia.dart b/pkg/test_runner/lib/src/fuchsia.dart
new file mode 100644
index 0000000..874ded5
--- /dev/null
+++ b/pkg/test_runner/lib/src/fuchsia.dart
@@ -0,0 +1,225 @@
+// 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:convert';
+import 'dart:io';
+
+import 'repository.dart';
+import 'utils.dart';
+
+class FuchsiaEmulator {
+  static final Uri toolsDir =
+      Repository.uri.resolve('third_party/fuchsia/sdk/linux/bin/');
+  static final String femuTool = toolsDir.resolve('femu.sh').toFilePath();
+  static final String fserveTool = toolsDir.resolve('fserve.sh').toFilePath();
+  static final String fpubTool = toolsDir.resolve('fpublish.sh').toFilePath();
+  static final String fsshTool = toolsDir.resolve('fssh.sh').toFilePath();
+  static final RegExp emulatorReadyPattern =
+      RegExp(r'Using unique host name (.+)\.local\.');
+  static final RegExp emulatorPidPattern =
+      RegExp(r'([0-9]+) .* qemu-system-x86');
+  static final String serverReadyPattern = '[pm serve] serving';
+
+  static FuchsiaEmulator _inst;
+
+  Process _emu;
+  Process _server;
+  String _deviceName;
+
+  static Future<void> publishPackage(
+      int emuCpus, String buildDir, String mode) async {
+    if (_inst == null) {
+      _inst = FuchsiaEmulator();
+      await _inst._start(emuCpus);
+    }
+    await _inst._publishPackage(buildDir, mode);
+  }
+
+  static void stop() {
+    _inst?._stop();
+  }
+
+  static List<String> getTestArgs(String mode, List<String> arguments) {
+    return _inst._getSshArgs(
+        mode,
+        arguments.map((arg) =>
+            arg.replaceAll(Repository.uri.toFilePath(), '/pkg/data/')));
+  }
+
+  Future<void> _start(int emuCpus) async {
+    // Start the emulator.
+    DebugLogger.info('Starting Fuchsia emulator with $emuCpus CPUs');
+    _emu = await Process.start('xvfb-run', [
+      femuTool,
+      '--image',
+      'qemu-x64',
+      '-N',
+      '--headless',
+      '-s',
+      '$emuCpus'
+    ]);
+
+    // Wait until the emulator is ready and has a valid device name.
+    var deviceNameFuture = Completer<String>();
+    var emuStdout = StringBuffer();
+    var emuStderr = StringBuffer();
+    _emu.stdout.transform(utf8.decoder).transform(const LineSplitter()).listen(
+        (String line) {
+      if (!deviceNameFuture.isCompleted) {
+        emuStdout.write(line);
+        emuStdout.write('\n');
+        var match = emulatorReadyPattern.firstMatch(line);
+        if (match != null) {
+          deviceNameFuture.complete(match.group(1));
+        }
+      }
+    }, onDone: () {
+      if (!deviceNameFuture.isCompleted) {
+        deviceNameFuture.completeError(
+            'Fuchsia emulator terminated unexpectedly.\n\n' +
+                _formatOutputs(emuStdout.toString(), emuStderr.toString()));
+      }
+      _stop();
+    });
+    _emu.stderr
+        .transform(utf8.decoder)
+        .transform(const LineSplitter())
+        .listen((String line) {
+      if (!deviceNameFuture.isCompleted) {
+        emuStderr.write(line);
+        emuStderr.write('\n');
+      }
+    });
+    _deviceName = await deviceNameFuture.future;
+    DebugLogger.info('Fuchsia emulator ready: $_deviceName');
+
+    // Start the server.
+    DebugLogger.info('Starting Fuchsia package server');
+    _server = await Process.start(fserveTool, [
+      '--bucket',
+      'fuchsia-sdk',
+      '--image',
+      'qemu-x64',
+      '--device-name',
+      _deviceName
+    ]);
+
+    // Wait until the server is ready to serve packages.
+    var serverReadyFuture = Completer<String>();
+    var serverStdout = StringBuffer();
+    var serverStderr = StringBuffer();
+    _server.stdout
+        .transform(utf8.decoder)
+        .transform(const LineSplitter())
+        .listen((String line) {
+      if (!serverReadyFuture.isCompleted) {
+        serverStdout.write(line);
+        serverStdout.write('\n');
+        if (line.contains(serverReadyPattern)) {
+          serverReadyFuture.complete();
+        }
+      }
+    }, onDone: () {
+      if (!serverReadyFuture.isCompleted) {
+        serverReadyFuture.completeError(
+            'Fuchsia package server terminated unexpectedly.\n\n' +
+                _formatOutputs(
+                    serverStdout.toString(), serverStderr.toString()));
+      }
+      _stop();
+    });
+    _server.stderr
+        .transform(utf8.decoder)
+        .transform(const LineSplitter())
+        .listen((String line) {
+      if (!serverReadyFuture.isCompleted) {
+        serverStderr.write(line);
+        serverStderr.write('\n');
+      }
+    });
+    await serverReadyFuture.future;
+    DebugLogger.info('Fuchsia package server ready');
+  }
+
+  List<String> _getSshArgs(String mode, Iterable<String> args) {
+    var sshArgs = [
+      '--device-name',
+      _deviceName,
+      'run',
+      'fuchsia-pkg://fuchsia.com/dart_test_$mode#meta/dart.cmx'
+    ];
+    return sshArgs..addAll(args);
+  }
+
+  Future<void> _publishPackage(String buildDir, String mode) async {
+    var packageFile = '$buildDir/gen/dart_test_$mode/dart_test_$mode.far';
+    DebugLogger.info('Publishing package: $packageFile');
+    var result = await Process.run(fpubTool, [packageFile]);
+    if (result.exitCode != 0) {
+      _stop();
+      _throwResult('Publishing package', result);
+    }
+
+    // Verify that the publication was successful by running hello_test.dart.
+    // This also forces the emulator to download the published package from the
+    // server, rather than waiting until the first tests are run. It can take a
+    // minute or two to transfer, and we don't want to eat into the timeout
+    // timer of the first tests.
+    DebugLogger.info('Verifying publication');
+    result = await Process.run(fsshTool,
+        _getSshArgs(mode, ['/pkg/data/pkg/testing/test/hello_test.dart']));
+    if (result.exitCode != 0 || result.stdout != 'Hello, World!\n') {
+      _stop();
+      _throwResult('Verifying publication', result);
+    }
+    DebugLogger.info('Publication successful');
+  }
+
+  void _stop() {
+    if (_emu != null) {
+      DebugLogger.info('Stopping Fuchsia emulator');
+      _emu.kill(ProcessSignal.sigint);
+      _emu = null;
+
+      // Killing femu.sh seems to leave the underlying emulator running. So
+      // manually find the process and terminate it by PID.
+      var result = Process.runSync('ps', []);
+      var emuPid = int.tryParse(
+          emulatorPidPattern.firstMatch(result.stdout as String)?.group(1) ??
+              "");
+      if (result.exitCode != 0 || emuPid == null) {
+        _throwResult('Searching for emulator process', result);
+      }
+      Process.killPid(emuPid);
+      DebugLogger.info('Fuchsia emulator stopped');
+    }
+
+    if (_server != null) {
+      DebugLogger.info('Stopping Fuchsia package server');
+      _server.kill();
+      _server = null;
+
+      // fserve.sh starts a package manager process in the background. We need
+      // to manually kill this process, using fserve.sh again.
+      var result = Process.runSync(fserveTool, ['--kill']);
+      if (result.exitCode != 0) {
+        _throwResult('Killing package manager', result);
+      }
+      DebugLogger.info('Fuchsia package server stopped');
+    }
+  }
+
+  String _formatOutputs(String stdout, String stderr) {
+    var output = "";
+    if (stdout.isNotEmpty) output += "=== STDOUT ===\n$stdout\n";
+    if (stderr.isNotEmpty) output += "=== STDERR ===\n$stderr\n";
+    return output;
+  }
+
+  void _throwResult(String name, ProcessResult result) {
+    throw '$name failed with exit code: ${result.exitCode}\n\n' +
+        _formatOutputs(result.stdout as String, result.stderr as String);
+  }
+}
diff --git a/pkg/test_runner/lib/src/runtime_configuration.dart b/pkg/test_runner/lib/src/runtime_configuration.dart
index 477c73c..ad3f498 100644
--- a/pkg/test_runner/lib/src/runtime_configuration.dart
+++ b/pkg/test_runner/lib/src/runtime_configuration.dart
@@ -7,6 +7,7 @@
 import 'command.dart';
 import 'compiler_configuration.dart';
 import 'configuration.dart';
+import 'fuchsia.dart';
 import 'repository.dart';
 import 'utils.dart';
 
@@ -42,6 +43,8 @@
       case Runtime.vm:
         if (configuration.system == System.android) {
           return DartkAdbRuntimeConfiguration();
+        } else if (configuration.system == System.fuchsia) {
+          return DartkFuchsiaEmulatorRuntimeConfiguration();
         }
         return StandaloneDartRuntimeConfiguration();
 
@@ -379,6 +382,34 @@
   }
 }
 
+class DartkFuchsiaEmulatorRuntimeConfiguration
+    extends DartVmRuntimeConfiguration {
+  List<Command> computeRuntimeCommands(
+      CommandArtifact artifact,
+      List<String> arguments,
+      Map<String, String> environmentOverrides,
+      List<String> extraLibs,
+      bool isCrashExpected) {
+    var script = artifact.filename;
+    var type = artifact.mimeType;
+    if (script != null &&
+        type != 'application/dart' &&
+        type != 'application/dart-snapshot' &&
+        type != 'application/kernel-ir' &&
+        type != 'application/kernel-ir-fully-linked') {
+      throw "Dart VM cannot run files of type '$type'.";
+    }
+    var runtimeArgs =
+        FuchsiaEmulator.getTestArgs(_configuration.mode.name, arguments);
+    if (isCrashExpected) {
+      runtimeArgs.insert(0, '--suppress-core-dump');
+    }
+    return [
+      VMCommand(FuchsiaEmulator.fsshTool, runtimeArgs, environmentOverrides)
+    ];
+  }
+}
+
 class SelfCheckRuntimeConfiguration extends DartVmRuntimeConfiguration {
   final List<String> selfCheckers = <String>[];
 
diff --git a/pkg/test_runner/lib/src/static_error.dart b/pkg/test_runner/lib/src/static_error.dart
index 38bfe0b..23fd8f3 100644
--- a/pkg/test_runner/lib/src/static_error.dart
+++ b/pkg/test_runner/lib/src/static_error.dart
@@ -546,21 +546,6 @@
       errors[source] = message;
     }
 
-    // Make sure the messages are in front end order.
-    var sources = errors.keys.toList();
-    for (var before = 0; before < ErrorSource.all.length - 1; before++) {
-      var beforeSource = ErrorSource.all[before];
-      for (var after = before + 1; after < ErrorSource.all.length; after++) {
-        var afterSource = ErrorSource.all[after];
-        if (errors.containsKey(beforeSource) &&
-            errors.containsKey(afterSource) &&
-            sources.indexOf(beforeSource) > sources.indexOf(afterSource)) {
-          _fail("The ${beforeSource.name} expectation must come before the "
-              "${afterSource.name} expectation.");
-        }
-      }
-    }
-
     if (errors.isEmpty) {
       _fail("An error expectation must specify at least one error message.");
     }
diff --git a/pkg/test_runner/lib/src/test_configurations.dart b/pkg/test_runner/lib/src/test_configurations.dart
index 9e0d5a1..32201e8 100644
--- a/pkg/test_runner/lib/src/test_configurations.dart
+++ b/pkg/test_runner/lib/src/test_configurations.dart
@@ -10,6 +10,7 @@
 import 'browser_controller.dart';
 import 'co19_test_config.dart';
 import 'configuration.dart';
+import 'fuchsia.dart';
 import 'path.dart';
 import 'process_queue.dart';
 import 'terminal.dart';
@@ -152,6 +153,11 @@
         }
       }
     }
+
+    if (configuration.system == System.fuchsia) {
+      await FuchsiaEmulator.publishPackage(configuration.taskCount,
+          configuration.buildDirectory, configuration.mode.name);
+    }
   }
 
   // If we only need to print out status files for test suites
@@ -170,6 +176,7 @@
     for (var configuration in configurations) {
       configuration.stopServers();
     }
+    FuchsiaEmulator.stop();
 
     DebugLogger.close();
     if (!firstConf.keepGeneratedFiles) {
diff --git a/pkg/test_runner/lib/src/test_suite.dart b/pkg/test_runner/lib/src/test_suite.dart
index b06096b..fe5f5d2 100644
--- a/pkg/test_runner/lib/src/test_suite.dart
+++ b/pkg/test_runner/lib/src/test_suite.dart
@@ -55,14 +55,16 @@
   TestSuite(this.configuration, this.suiteName, this.statusFilePaths) {
     _environmentOverrides = {
       'DART_CONFIGURATION': configuration.configurationDirectory,
+      if (Platform.isWindows) 'DART_SUPPRESS_WER': '1',
+      if (Platform.isWindows && configuration.copyCoreDumps)
+        'DART_CRASHPAD_HANDLER':
+            Uri.base.resolve(buildDir + '/crashpad_handler.exe').toFilePath(),
+      if (configuration.chromePath != null)
+        'CHROME_PATH': Uri.base.resolve(configuration.chromePath).toFilePath(),
+      if (configuration.firefoxPath != null)
+        'FIREFOX_PATH':
+            Uri.base.resolve(configuration.firefoxPath).toFilePath(),
     };
-    if (Platform.isWindows) {
-      _environmentOverrides['DART_SUPPRESS_WER'] = '1';
-      if (configuration.copyCoreDumps) {
-        _environmentOverrides['DART_CRASHPAD_HANDLER'] =
-            Path(buildDir + '/crashpad_handler.exe').absolute.toNativePath();
-      }
-    }
   }
 
   Map<String, String> get environmentOverrides => _environmentOverrides;
@@ -808,8 +810,10 @@
             "${nameFromModuleRoot.directoryPath}/$nameNoExt";
         var jsDir =
             Path(compilationTempDir).relativeTo(Repository.dir).toString();
+        var nullAssertions =
+            testFile.sharedOptions.contains('--null-assertions');
         content = dartdevcHtml(nameNoExt, nameFromModuleRootNoExt, jsDir,
-            configuration.compiler, configuration.nnbdMode);
+            configuration.compiler, configuration.nnbdMode, nullAssertions);
       }
     }
 
diff --git a/pkg/test_runner/test/test_file_test.dart b/pkg/test_runner/test/test_file_test.dart
index 03c1227..847fb49 100644
--- a/pkg/test_runner/test/test_file_test.dart
+++ b/pkg/test_runner/test/test_file_test.dart
@@ -460,6 +460,47 @@
     makeError(line: 12, column: 34, length: 56, cfeError: "Message."),
   ]);
 
+  // Allow front ends in any order.
+  expectParseErrorExpectations("""
+int i = "s";
+/\/      ^^^
+/\/ [cfe] Error message.
+/\/ [analyzer] ErrorCode.BAD_THING
+""", [
+    makeError(
+        line: 1,
+        column: 9,
+        length: 3,
+        analyzerError: "ErrorCode.BAD_THING",
+        cfeError: "Error message."),
+  ]);
+  expectParseErrorExpectations("""
+int i = "s";
+/\/      ^^^
+/\/ [web] Web message.
+/\/ [analyzer] ErrorCode.BAD_THING
+""", [
+    makeError(
+        line: 1,
+        column: 9,
+        length: 3,
+        analyzerError: "ErrorCode.BAD_THING",
+        webError: "Web message."),
+  ]);
+  expectParseErrorExpectations("""
+int i = "s";
+/\/      ^^^
+/\/ [web] Web message.
+/\/ [cfe] Error message.
+""", [
+    makeError(
+        line: 1,
+        column: 9,
+        length: 3,
+        cfeError: "Error message.",
+        webError: "Web message."),
+  ]);
+
   // Must have at least one error message.
   expectFormatError("""
 int i = "s";
@@ -489,26 +530,6 @@
 /\/ [wat] Error message.
 """);
 
-  // Front ends must be ordered.
-  expectFormatError("""
-int i = "s";
-/\/      ^^^
-/\/ [cfe] Error message.
-/\/ [analyzer] ErrorCode.BAD_THING
-""");
-  expectFormatError("""
-int i = "s";
-/\/      ^^^
-/\/ [web] Error message.
-/\/ [analyzer] ErrorCode.BAD_THING
-""");
-  expectFormatError("""
-int i = "s";
-/\/      ^^^
-/\/ [web] Error message.
-/\/ [cfe] Error message
-""");
-
   // Analyzer error must look like an error code.
   expectFormatError("""
 int i = "s";
diff --git a/pkg/test_runner/test/update_errors_test.dart b/pkg/test_runner/test/update_errors_test.dart
index cf51646..6a8e9c7 100644
--- a/pkg/test_runner/test/update_errors_test.dart
+++ b/pkg/test_runner/test/update_errors_test.dart
@@ -15,7 +15,7 @@
 // here as significant, so we obfuscate them using seemingly-pointless string
 // escapes here like `\/`.
 
-Future<void> main() async {
+void main() {
   // Inserts analyzer, CFE, and both errors.
   expectUpdate("""
 int i = "bad";
@@ -287,7 +287,7 @@
 /\/ [cfe] Wrong 1.
 """);
 
-  // Don't crash with RangeError.
+  // Doesn't crash with RangeError.
   expectUpdate("""
 x
 // [error line 1, column 1, length 0]
diff --git a/pkg/vm/bin/kernel_service.dart b/pkg/vm/bin/kernel_service.dart
index 021c858..f0bda92 100644
--- a/pkg/vm/bin/kernel_service.dart
+++ b/pkg/vm/bin/kernel_service.dart
@@ -84,10 +84,10 @@
 // Null Safety command line options
 //
 // Note: The values of these constants must match the
-// values of flag null_safety in ../../../../runtime/vm/flag_list.h.
-// 0 - No null_safety option specified on the command line.
-// 1 - '--no-null-safety' specified on the command line.
-// 2 - '--null-safety' option specified on the command line.
+// values of flag sound_null_safety in ../../../../runtime/vm/flag_list.h.
+// 0 - No --[no-]sound-null-safety option specified on the command line.
+// 1 - '--no-sound-null-safety' specified on the command line.
+// 2 - '--sound-null-safety' option specified on the command line.
 const int kNullSafetyOptionUnspecified = 0;
 const int kNullSafetyOptionWeak = 1;
 const int kNullSafetyOptionStrong = 2;
@@ -363,7 +363,8 @@
         suppressWarnings: suppressWarnings,
         enableAsserts: enableAsserts,
         experimentalFlags: experimentalFlags,
-        bytecode: bytecode);
+        bytecode: bytecode,
+        packageConfig: packageConfig);
     result.generator = new IncrementalCompiler.forExpressionCompilationOnly(
         component,
         result.options,
@@ -538,19 +539,20 @@
 Future _processExpressionCompilationRequest(request) async {
   final SendPort port = request[1];
   final int isolateId = request[2];
-  final String expression = request[3];
-  final List<String> definitions = request[4].cast<String>();
-  final List<String> typeDefinitions = request[5].cast<String>();
-  final String libraryUri = request[6];
-  final String klass = request[7]; // might be null
-  final bool isStatic = request[8];
-  final List dillData = request[9];
-  final int hotReloadCount = request[10];
-  final bool suppressWarnings = request[11];
-  final bool enableAsserts = request[12];
+  final dynamic dart_platform_kernel = request[3];
+  final String expression = request[4];
+  final List<String> definitions = request[5].cast<String>();
+  final List<String> typeDefinitions = request[6].cast<String>();
+  final String libraryUri = request[7];
+  final String klass = request[8]; // might be null
+  final bool isStatic = request[9];
+  final List dillData = request[10];
+  final int blobLoadCount = request[11];
+  final bool suppressWarnings = request[12];
+  final bool enableAsserts = request[13];
   final List<String> experimentalFlags =
-      request[13] != null ? request[13].cast<String>() : null;
-  final bool bytecode = request[14];
+      request[14] != null ? request[14].cast<String>() : null;
+  final bool bytecode = request[15];
 
   IncrementalCompilerWrapper compiler = isolateCompilers[isolateId];
 
@@ -558,7 +560,7 @@
       isolateLoadNotifies[isolateId];
   if (isolateLoadDillData != null) {
     // Check if we can reuse the compiler.
-    if (isolateLoadDillData.hotReloadCount != hotReloadCount ||
+    if (isolateLoadDillData.blobLoadCount != blobLoadCount ||
         isolateLoadDillData.prevDillCount != dillData.length) {
       compiler = isolateCompilers[isolateId] = null;
     }
@@ -571,25 +573,55 @@
       }
       isolateLoadNotifies[isolateId] =
           new _ExpressionCompilationFromDillSettings(
-              hotReloadCount, dillData.length);
-
-      Uri platformUri =
-          computePlatformBinariesLocation().resolve('vm_platform_strong.dill');
-
-      List<List<int>> data = [];
-      data.add(new File.fromUri(platformUri).readAsBytesSync());
-      for (int i = 0; i < dillData.length; i++) {
-        data.add(dillData[i]);
-      }
+              blobLoadCount, dillData.length);
 
       // Create Component initialized from the bytes.
       Component component = new Component();
-      for (List<int> bytes in data) {
+
+      // First try to just load all "dillData". This *might* include the
+      // platform (and we might have the (same) platform both here and in
+      // dart_platform_kernel).
+      for (List<int> bytes in dillData) {
         // TODO(jensj): There might be an issue if main has changed.
         new BinaryBuilderWithMetadata(bytes, alwaysCreateNewNamedNodes: true)
             .readComponent(component);
       }
 
+      // Check if the loaded component has the platform.
+      // If it does not, try to load from dart_platform_kernel or from file.
+      bool foundDartCore = false;
+      for (Library library in component.libraries) {
+        if (library.importUri.scheme == "dart" &&
+            library.importUri.path == "core" &&
+            !library.isSynthetic) {
+          foundDartCore = true;
+          break;
+        }
+      }
+      if (!foundDartCore) {
+        List<int> platformKernel = null;
+        if (dart_platform_kernel is List<int>) {
+          platformKernel = dart_platform_kernel;
+        } else {
+          final Uri platformUri = computePlatformBinariesLocation()
+              .resolve('vm_platform_strong.dill');
+          final File platformFile = new File.fromUri(platformUri);
+          if (platformFile.existsSync()) {
+            platformKernel = platformFile.readAsBytesSync();
+          } else {
+            port.send(new CompilationResult.errors(
+                    ["No platform found to initialize incremental compiler."],
+                    null)
+                .toResponse());
+            return;
+          }
+        }
+
+        new BinaryBuilderWithMetadata(platformKernel,
+                alwaysCreateNewNamedNodes: true)
+            .readComponent(component);
+      }
+
       FileSystem fileSystem =
           _buildFileSystem([dotPackagesFile, <int>[]], null, null, null);
 
@@ -597,17 +629,26 @@
       // destroyed when corresponding isolate is shut down. To achieve that
       // kernel isolate needs to receive a message indicating that particular
       // isolate was shut down. Message should be handled here in this script.
-      compiler = new IncrementalCompilerWrapper.forExpressionCompilationOnly(
-          component, isolateId, fileSystem, null,
-          suppressWarnings: suppressWarnings,
-          enableAsserts: enableAsserts,
-          experimentalFlags: experimentalFlags,
-          bytecode: bytecode,
-          packageConfig: dotPackagesFile);
-      isolateCompilers[isolateId] = compiler;
-      await compiler.compile(
-          component.mainMethod?.enclosingLibrary?.importUri ??
-              component.libraries.last.importUri);
+      try {
+        compiler = new IncrementalCompilerWrapper.forExpressionCompilationOnly(
+            component, isolateId, fileSystem, null,
+            suppressWarnings: suppressWarnings,
+            enableAsserts: enableAsserts,
+            experimentalFlags: experimentalFlags,
+            bytecode: bytecode,
+            packageConfig: dotPackagesFile);
+        isolateCompilers[isolateId] = compiler;
+        await compiler.compile(
+            component.mainMethod?.enclosingLibrary?.importUri ??
+                component.libraries.last.importUri);
+      } catch (e) {
+        port.send(new CompilationResult.errors([
+          "Error when trying to create a compiler for expression compilation: "
+              "'$e'."
+        ], null)
+            .toResponse());
+        return;
+      }
     }
   }
 
@@ -1179,9 +1220,9 @@
 }
 
 class _ExpressionCompilationFromDillSettings {
-  int hotReloadCount;
+  int blobLoadCount;
   int prevDillCount;
 
   _ExpressionCompilationFromDillSettings(
-      this.hotReloadCount, this.prevDillCount);
+      this.blobLoadCount, this.prevDillCount);
 }
diff --git a/pkg/vm/lib/kernel_front_end.dart b/pkg/vm/lib/kernel_front_end.dart
index 06cc08b..254c56e 100644
--- a/pkg/vm/lib/kernel_front_end.dart
+++ b/pkg/vm/lib/kernel_front_end.dart
@@ -6,7 +6,7 @@
 library vm.kernel_front_end;
 
 import 'dart:async';
-import 'dart:io' show File, IOSink, IOException;
+import 'dart:io' show File, IOSink;
 
 import 'package:args/args.dart' show ArgParser, ArgResults;
 
@@ -28,7 +28,6 @@
         ExperimentalFlag,
         FileSystem,
         FileSystemEntity,
-        FileSystemException,
         NnbdMode,
         ProcessedOptions,
         Severity,
@@ -46,6 +45,7 @@
 import 'package:kernel/core_types.dart' show CoreTypes;
 import 'package:kernel/kernel.dart' show loadComponentFromBinary;
 import 'package:kernel/target/targets.dart' show Target, TargetFlags, getTarget;
+import 'package:package_config/package_config.dart' show loadPackageConfigUri;
 
 import 'bytecode/bytecode_serialization.dart' show BytecodeSizeStatistics;
 import 'bytecode/gen_bytecode.dart'
@@ -118,10 +118,8 @@
       help: 'The values for the environment constants (e.g. -Dkey=value).');
   args.addFlag('enable-asserts',
       help: 'Whether asserts will be enabled.', defaultsTo: false);
-  args.addFlag('null-safety',
-      help:
-          'Respect the nullability of types at runtime in casts and instance checks.',
-      defaultsTo: null);
+  args.addFlag('sound-null-safety',
+      help: 'Respect the nullability of types at runtime.', defaultsTo: null);
   args.addFlag('split-output-by-packages',
       help:
           'Split resulting kernel file into multiple files (one per package).',
@@ -189,7 +187,7 @@
   final bool genBytecode = options['gen-bytecode'];
   final bool dropAST = options['drop-ast'];
   final bool enableAsserts = options['enable-asserts'];
-  final bool nullSafety = options['null-safety'];
+  final bool nullSafety = options['sound-null-safety'];
   final bool useProtobufTreeShaker = options['protobuf-tree-shaker'];
   final bool useProtobufTreeShakerV2 = options['protobuf-tree-shaker-v2'];
   final bool splitOutputByPackages = options['split-output-by-packages'];
@@ -664,48 +662,22 @@
 }
 
 /// Convert URI to a package URI if it is inside one of the packages.
+/// TODO(alexmarkov) Remove this conversion after Fuchsia build rules are fixed.
 Future<Uri> convertToPackageUri(
     FileSystem fileSystem, Uri uri, Uri packagesUri) async {
   if (uri.scheme == 'package') {
     return uri;
   }
   // Convert virtual URI to a real file URI.
-  String uriString = (await asFileUri(fileSystem, uri)).toString();
-  List<String> packages;
+  final Uri fileUri = await asFileUri(fileSystem, uri);
   try {
-    packages =
-        await new File((await asFileUri(fileSystem, packagesUri)).toFilePath())
-            .readAsLines();
-  } on IOException {
+    final packageConfig =
+        await loadPackageConfigUri(await asFileUri(fileSystem, packagesUri));
+    return packageConfig.toPackageUri(fileUri) ?? uri;
+  } catch (_) {
     // Can't read packages file - silently give up.
     return uri;
   }
-  // file:///a/b/x/y/main.dart -> package:x.y/main.dart
-  for (var line in packages) {
-    if (line.isEmpty || line.startsWith("#")) {
-      continue;
-    }
-
-    final colon = line.indexOf(':');
-    if (colon == -1) {
-      continue;
-    }
-    final packageName = line.substring(0, colon);
-    String packagePath;
-    try {
-      packagePath = (await asFileUri(
-              fileSystem, packagesUri.resolve(line.substring(colon + 1))))
-          .toString();
-    } on FileSystemException {
-      // Can't resolve package path.
-      continue;
-    }
-    if (uriString.startsWith(packagePath)) {
-      return Uri.parse(
-          'package:$packageName/${uriString.substring(packagePath.length)}');
-    }
-  }
-  return uri;
 }
 
 /// Write a separate kernel binary for each package. The name of the
diff --git a/pkg/vm/lib/transformations/list_factory_specializer.dart b/pkg/vm/lib/transformations/list_factory_specializer.dart
index a759199..37417ca 100644
--- a/pkg/vm/lib/transformations/list_factory_specializer.dart
+++ b/pkg/vm/lib/transformations/list_factory_specializer.dart
@@ -16,33 +16,47 @@
 /// new List.filled(n, x, growable: true) => new _GrowableList.filled(n, x)
 /// new List.filled(n, null) => new _List(n)
 /// new List.filled(n, x) => new _List.filled(n, x)
+/// new List.generate(n, y) => new _GrowableList.generate(n, y)
+/// new List.generate(n, y, growable: false) => new _List.generate(n, y)
 ///
 class ListFactorySpecializer {
   final Procedure _defaultListFactory;
   final Procedure _listFilledFactory;
+  final Procedure _listGenerateFactory;
   final Procedure _growableListFactory;
   final Procedure _growableListFilledFactory;
+  final Procedure _growableListGenerateFactory;
   final Procedure _fixedListFactory;
   final Procedure _fixedListFilledFactory;
+  final Procedure _fixedListGenerateFactory;
 
   ListFactorySpecializer(CoreTypes coreTypes)
       : _defaultListFactory =
             coreTypes.index.getMember('dart:core', 'List', ''),
         _listFilledFactory =
             coreTypes.index.getMember('dart:core', 'List', 'filled'),
+        _listGenerateFactory =
+            coreTypes.index.getMember('dart:core', 'List', 'generate'),
         _growableListFactory =
             coreTypes.index.getMember('dart:core', '_GrowableList', ''),
         _growableListFilledFactory =
             coreTypes.index.getMember('dart:core', '_GrowableList', 'filled'),
+        _growableListGenerateFactory =
+            coreTypes.index.getMember('dart:core', '_GrowableList', 'generate'),
         _fixedListFactory = coreTypes.index.getMember('dart:core', '_List', ''),
         _fixedListFilledFactory =
-            coreTypes.index.getMember('dart:core', '_List', 'filled') {
+            coreTypes.index.getMember('dart:core', '_List', 'filled'),
+        _fixedListGenerateFactory =
+            coreTypes.index.getMember('dart:core', '_List', 'generate') {
     assert(_defaultListFactory.isFactory);
     assert(_listFilledFactory.isFactory);
+    assert(_listGenerateFactory.isFactory);
     assert(_growableListFactory.isFactory);
     assert(_growableListFilledFactory.isFactory);
+    assert(_growableListGenerateFactory.isFactory);
     assert(_fixedListFactory.isFactory);
     assert(_fixedListFilledFactory.isFactory);
+    assert(_fixedListGenerateFactory.isFactory);
   }
 
   TreeNode transformStaticInvocation(StaticInvocation node) {
@@ -64,25 +78,10 @@
       final fill = args.positional[1];
       final fillingWithNull = fill is NullLiteral ||
           (fill is ConstantExpression && fill.constant is NullConstant);
-      bool growable;
-      if (args.named.isEmpty) {
-        growable = false;
-      } else {
-        final namedArg = args.named.single;
-        assert(namedArg.name == 'growable');
-        final value = namedArg.value;
-        if (value is BoolLiteral) {
-          growable = value.value;
-        } else if (value is ConstantExpression) {
-          final constant = value.constant;
-          if (constant is BoolConstant) {
-            growable = constant.value;
-          } else {
-            return node;
-          }
-        } else {
-          return node;
-        }
+      final bool growable =
+          _getConstantOptionalArgument(args, 'growable', false);
+      if (growable == null) {
+        return node;
       }
       if (growable) {
         if (fillingWithNull) {
@@ -105,8 +104,49 @@
             ..fileOffset = node.fileOffset;
         }
       }
+    } else if (target == _listGenerateFactory) {
+      final args = node.arguments;
+      assert(args.positional.length == 2);
+      final length = args.positional[0];
+      final generator = args.positional[1];
+      final bool growable =
+          _getConstantOptionalArgument(args, 'growable', true);
+      if (growable == null) {
+        return node;
+      }
+      if (growable) {
+        return StaticInvocation(_growableListGenerateFactory,
+            Arguments([length, generator], types: args.types))
+          ..fileOffset = node.fileOffset;
+      } else {
+        return StaticInvocation(_fixedListGenerateFactory,
+            Arguments([length, generator], types: args.types))
+          ..fileOffset = node.fileOffset;
+      }
     }
 
     return node;
   }
+
+  /// Returns constant value of the only optional argument in [args],
+  /// or null if it is not a constant. Returns [defaultValue] if optional
+  /// argument is not passed. Argument is asserted to have the given [name].
+  bool /*?*/ _getConstantOptionalArgument(
+      Arguments args, String name, bool defaultValue) {
+    if (args.named.isEmpty) {
+      return defaultValue;
+    }
+    final namedArg = args.named.single;
+    assert(namedArg.name == name);
+    final value = namedArg.value;
+    if (value is BoolLiteral) {
+      return value.value;
+    } else if (value is ConstantExpression) {
+      final constant = value.constant;
+      if (constant is BoolConstant) {
+        return constant.value;
+      }
+    }
+    return null;
+  }
 }
diff --git a/pkg/vm/lib/transformations/mixin_deduplication.dart b/pkg/vm/lib/transformations/mixin_deduplication.dart
index 61d0a9d..42e74cd 100644
--- a/pkg/vm/lib/transformations/mixin_deduplication.dart
+++ b/pkg/vm/lib/transformations/mixin_deduplication.dart
@@ -56,11 +56,14 @@
           otherClass.typeParameters.isNotEmpty) {
         return false;
       }
-      // Deduplicate mixin applications with matching supertype, mixed-in type
-      // and implemented interfaces.
+      // Deduplicate mixin applications with matching supertype, mixed-in type,
+      // implemented interfaces and NNBD mode (CFE may add extra signature
+      // members depending on the NNBD mode).
       return thisClass.supertype == otherClass.supertype &&
           thisClass.mixedInType == otherClass.mixedInType &&
-          listEquals(thisClass.implementedTypes, otherClass.implementedTypes);
+          listEquals(thisClass.implementedTypes, otherClass.implementedTypes) &&
+          thisClass.enclosingLibrary.isNonNullableByDefault ==
+              otherClass.enclosingLibrary.isNonNullableByDefault;
     }
     return false;
   }
diff --git a/pkg/vm/lib/transformations/type_flow/transformer.dart b/pkg/vm/lib/transformations/type_flow/transformer.dart
index 0509644..88c865e 100644
--- a/pkg/vm/lib/transformations/type_flow/transformer.dart
+++ b/pkg/vm/lib/transformations/type_flow/transformer.dart
@@ -309,6 +309,13 @@
     if (_typeFlowAnalysis.isMemberUsed(member)) {
       if (member is Field) {
         _setInferredType(member, _typeFlowAnalysis.fieldType(member));
+
+        final unboxingInfoMetadata =
+            _unboxingInfo.getUnboxingInfoOfMember(member);
+        if (unboxingInfoMetadata != null &&
+            !unboxingInfoMetadata.isFullyBoxed) {
+          _unboxingInfoMetadata.mapping[member] = unboxingInfoMetadata;
+        }
       } else {
         Args<Type> argTypes = _typeFlowAnalysis.argumentTypes(member);
         final uncheckedParameters =
@@ -532,32 +539,42 @@
 
 void _updateUnboxingInfoOfMember(Member member,
     TypeFlowAnalysis typeFlowAnalysis, UnboxingInfoManager unboxingInfo) {
-  if (typeFlowAnalysis.isMemberUsed(member) && (member is! Field)) {
-    final Args<Type> argTypes = typeFlowAnalysis.argumentTypes(member);
-    assertx(argTypes != null);
+  if (typeFlowAnalysis.isMemberUsed(member)) {
+    if (member is Procedure || member is Constructor) {
+      final Args<Type> argTypes = typeFlowAnalysis.argumentTypes(member);
+      assertx(argTypes != null);
 
-    final int firstParamIndex =
-        numTypeParams(member) + (hasReceiverArg(member) ? 1 : 0);
+      final int firstParamIndex =
+          numTypeParams(member) + (hasReceiverArg(member) ? 1 : 0);
 
-    final positionalParams = member.function.positionalParameters;
-    assertx(
-        argTypes.positionalCount == firstParamIndex + positionalParams.length);
+      final positionalParams = member.function.positionalParameters;
+      assertx(argTypes.positionalCount ==
+          firstParamIndex + positionalParams.length);
 
-    for (int i = 0; i < positionalParams.length; i++) {
-      final inferredType = argTypes.values[firstParamIndex + i];
-      unboxingInfo.applyToArg(member, i, inferredType);
+      for (int i = 0; i < positionalParams.length; i++) {
+        final inferredType = argTypes.values[firstParamIndex + i];
+        unboxingInfo.applyToArg(member, i, inferredType);
+      }
+
+      final names = argTypes.names;
+      for (int i = 0; i < names.length; i++) {
+        final inferredType =
+            argTypes.values[firstParamIndex + positionalParams.length + i];
+        unboxingInfo.applyToArg(
+            member, positionalParams.length + i, inferredType);
+      }
+
+      final Type resultType = typeFlowAnalysis.getSummary(member).resultType;
+      unboxingInfo.applyToReturn(member, resultType);
+    } else if (member is Field) {
+      final fieldValue = typeFlowAnalysis.getFieldValue(member).value;
+      if (member.hasSetter) {
+        unboxingInfo.applyToArg(member, 0, fieldValue);
+      }
+      unboxingInfo.applyToReturn(member, fieldValue);
+    } else {
+      assertx(false);
     }
-
-    final names = argTypes.names;
-    for (int i = 0; i < names.length; i++) {
-      final inferredType =
-          argTypes.values[firstParamIndex + positionalParams.length + i];
-      unboxingInfo.applyToArg(
-          member, positionalParams.length + i, inferredType);
-    }
-
-    final Type resultType = typeFlowAnalysis.getSummary(member).resultType;
-    unboxingInfo.applyToReturn(member, resultType);
   }
 }
 
@@ -1407,7 +1424,8 @@
     TypeCheck check = shaker.typeFlowAnalysis.explicitCast(node);
     if (check != null && check.canAlwaysSkip) {
       return StaticInvocation(
-          unsafeCast, Arguments([node.operand], types: [node.type]));
+          unsafeCast, Arguments([node.operand], types: [node.type]))
+        ..fileOffset = node.fileOffset;
     }
     return node;
   }
@@ -1420,7 +1438,8 @@
       return StaticInvocation(
           unsafeCast,
           Arguments([node.operand],
-              types: [node.getStaticType(staticTypeContext)]));
+              types: [node.getStaticType(staticTypeContext)]))
+        ..fileOffset = node.fileOffset;
     }
     return node;
   }
diff --git a/pkg/vm/lib/transformations/type_flow/unboxing_info.dart b/pkg/vm/lib/transformations/type_flow/unboxing_info.dart
index caefba4..33e1899 100644
--- a/pkg/vm/lib/transformations/type_flow/unboxing_info.dart
+++ b/pkg/vm/lib/transformations/type_flow/unboxing_info.dart
@@ -2,8 +2,6 @@
 // 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 'package:kernel/ast.dart';
 import 'package:kernel/core_types.dart';
 import 'package:kernel/external_name.dart' show getExternalName;
@@ -133,10 +131,12 @@
     for (final superType in cls.supers) {
       final superClass = superType.classNode;
       bool linked = false;
-      superClass.procedures.forEach((Procedure procedure) {
-        if (member.name == procedure.name) {
-          _linkMembers(member, procedure);
-          linked = true;
+      superClass.members.forEach((Member superMember) {
+        if (member.isInstanceMember) {
+          if (member.name == superMember.name) {
+            _linkMembers(member, superMember);
+            linked = true;
+          }
         }
       });
       if (!linked) {
@@ -158,17 +158,10 @@
   }
 
   Member _validMemberOrNull(Member member) {
-    if (member == null || (member is! Procedure && member is! Constructor)) {
+    if (member == null ||
+        (member is! Procedure && member is! Constructor && member is! Field)) {
       return null;
     }
-
-    // TODO(dartbug.com/33549): Support setters with unboxed arguments
-    // For this, fields should also be considered in the partition
-    // and be annotated with the UnboxingInfoMetadata.
-    if (member is Procedure && (member.isSetter || member.isGetter)) {
-      return null;
-    }
-
     return member;
   }
 
@@ -187,7 +180,9 @@
     final int memberId = _allUnboxingInfo.length;
     assertx(memberId == _partitionIds.length);
     assertx(_partitionIds.length == _partitionRank.length);
-    final int argsLen = member.function.requiredParameterCount;
+    final int argsLen = member is Field
+        ? (member.hasSetter ? 1 : 0)
+        : member.function.requiredParameterCount;
     _memberIds[member] = memberId;
     _allUnboxingInfo.add(UnboxingInfoMetadata(argsLen));
     _partitionIds.add(memberId);
@@ -202,9 +197,7 @@
     // have boxed parameters and return values.
     return (_isNative(member) ||
         _nativeCodeOracle.isMemberReferencedFromNativeCode(member) ||
-        _isEnclosingClassSubtypeOfNum(member) ||
-        (!_isConstructorOrStatic(member) &&
-            !_needsDynamicInvocationForwarder(member)));
+        _isEnclosingClassSubtypeOfNum(member));
   }
 
   bool _isNative(Member member) {
@@ -221,30 +214,6 @@
             .isSubtypeOf(_typeHierarchy, _coreTypes.numClass));
   }
 
-  bool _needsDynamicInvocationForwarder(Procedure procedure) {
-    for (var param in procedure.function.positionalParameters) {
-      if (!_isTopTypeForAssignability(param.type) &&
-          !param.isCovariant &&
-          !param.isGenericCovariantImpl) {
-        return true;
-      }
-    }
-
-    for (var param in procedure.function.namedParameters) {
-      if (!_isTopTypeForAssignability(param.type) &&
-          !param.isCovariant &&
-          !param.isGenericCovariantImpl) {
-        return true;
-      }
-    }
-
-    return false;
-  }
-
-  bool _isTopTypeForAssignability(DartType type) {
-    return (_coreTypes.isTop(type) || (type == Object) || (type == FutureOr));
-  }
-
   int _getMemberId(Member member) {
     return _memberIds[member];
   }
diff --git a/pkg/vm/lib/transformations/type_flow/utils.dart b/pkg/vm/lib/transformations/type_flow/utils.dart
index b7cebd7..93c10ac 100644
--- a/pkg/vm/lib/transformations/type_flow/utils.dart
+++ b/pkg/vm/lib/transformations/type_flow/utils.dart
@@ -109,7 +109,7 @@
 // Type arguments to procedures is only supported for factory constructors of
 // generic classes at the moment.
 //
-// TODO(sjindel/tfa): Extend suport to normal generic functions.
+// TODO(sjindel/tfa): Extend support to normal generic functions.
 int numTypeParams(Member member) => member is Procedure && member.isFactory
     ? member.function.typeParameters.length
     : 0;
diff --git a/pkg/vm/test/incremental_compiler_test.dart b/pkg/vm/test/incremental_compiler_test.dart
index f65ffa6..59416a2 100644
--- a/pkg/vm/test/incremental_compiler_test.dart
+++ b/pkg/vm/test/incremental_compiler_test.dart
@@ -453,6 +453,7 @@
         "--pause-isolates-on-exit",
         "--enable-vm-service:0",
         "--disable-service-auth-codes",
+        "--disable-dart-dev",
         list.path
       ]);
 
@@ -579,6 +580,7 @@
         "--pause-isolates-on-exit",
         "--enable-vm-service:0",
         "--disable-service-auth-codes",
+        "--disable-dart-dev",
         list.path
       ]);
 
@@ -658,6 +660,7 @@
         '--enable-vm-service=0', // Note: use 0 to avoid port collisions.
         '--pause_isolates_on_start',
         '--disable-service-auth-codes',
+        '--disable-dart-dev',
         outputFile.path
       ];
       final vm = await Process.start(Platform.resolvedExecutable, vmArgs);
@@ -917,6 +920,7 @@
         "--pause-isolates-on-start",
         "--enable-vm-service:0",
         "--disable-service-auth-codes",
+        "--disable-dart-dev",
         scriptOrDill.path
       ]);
 
diff --git a/pkg/vm/test/kernel_front_end_test.dart b/pkg/vm/test/kernel_front_end_test.dart
index 56dfc69..2bc2815 100644
--- a/pkg/vm/test/kernel_front_end_test.dart
+++ b/pkg/vm/test/kernel_front_end_test.dart
@@ -18,6 +18,7 @@
 const String mainScript = 'pkg/vm/bin/gen_kernel.dart';
 const String mainScriptPackageUri = 'package:vm/kernel_front_end.dart';
 const String packagesFile = '.packages';
+const String packageConfigFile = '.dart_tool/package_config.json';
 
 void testCompile(List<String> args) async {
   final compilerExitCode =
@@ -132,4 +133,32 @@
       '$sdkDir/$mainScript',
     ]);
   }, timeout: Timeout.none);
+
+  test('compile-package-config', () async {
+    await testCompile([
+      '--platform',
+      platformPath(),
+      '--packages',
+      '$sdkDir/$packageConfigFile',
+      '--output',
+      outputDill(),
+      '$sdkDir/$mainScript',
+    ]);
+  }, timeout: Timeout.none);
+
+  test('compile-multi-root-package-config', () async {
+    await testCompile([
+      '--platform',
+      platformPath(),
+      '--filesystem-scheme',
+      'test-filesystem-scheme',
+      '--filesystem-root',
+      sdkDir,
+      '--packages',
+      'test-filesystem-scheme:///$packageConfigFile',
+      '--output',
+      outputDill(),
+      'test-filesystem-scheme:///$mainScript',
+    ]);
+  }, timeout: Timeout.none);
 }
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/bench_is_prime.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/bench_is_prime.dart.expect
index 186ea40..d9f0804 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/bench_is_prime.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/bench_is_prime.dart.expect
@@ -30,7 +30,7 @@
   }
 }
 static method main(core::List<core::String*>* args) → dynamic {
-  core::Stopwatch* timer = let final core::Stopwatch #t1 = new core::Stopwatch::•() in block {
+  core::Stopwatch* timer = let final core::Stopwatch* #t1 = new core::Stopwatch::•() in block {
     [@vm.direct-call.metadata=dart.core::Stopwatch.start] [@vm.inferred-type.metadata=!? (skip check)] #t1.{core::Stopwatch::start}();
   } =>#t1;
   for (core::int* i = 0; [@vm.direct-call.metadata=dart.core::_IntegerImplementation.<] [@vm.inferred-type.metadata=dart.core::bool (skip check)] i.{core::num::<}(100); i = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=int (skip check)] i.{core::num::+}(1)) {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/bench_vector.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/bench_vector.dart.expect
index 5fa2ddf..0a75831 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/bench_vector.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/bench_vector.dart.expect
@@ -6,8 +6,8 @@
 import "dart:typed_data";
 
 class _Vector extends core::Object {
-[@vm.inferred-type.metadata=dart.core::_Smi (value: 0)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5]  final field core::int* _offset;
-[@vm.inferred-type.metadata=dart.core::_Smi (value: 10)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6,getterSelectorId:7]  final field core::int* _length;
+[@vm.inferred-type.metadata=dart.core::_Smi (value: 0)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5] [@vm.unboxing-info.metadata=()->i]  final field core::int* _offset;
+[@vm.inferred-type.metadata=dart.core::_Smi (value: 10)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  final field core::int* _length;
 [@vm.inferred-type.metadata=dart.typed_data::_Float64List] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:8,getterSelectorId:9]  final field core::List<core::double*>* _elements;
 [@vm.unboxing-info.metadata=(i)->b]  constructor •([@vm.inferred-type.metadata=dart.core::_Smi (value: 10)] core::int* size) → self::_Vector*
     : self::_Vector::_offset = 0, self::_Vector::_length = size, self::_Vector::_elements = [@vm.inferred-type.metadata=dart.typed_data::_Float64List] typ::Float64List::•(size), super core::Object::•()
@@ -27,7 +27,7 @@
 [@vm.inferred-type.metadata=#lib::_Vector?]static field self::_Vector* v = new self::_Vector::•(10);
 [@vm.inferred-type.metadata=dart.core::_Double?]static field core::double* x = 0.0;
 static method main(core::List<core::String*>* args) → dynamic {
-  core::Stopwatch* timer = let final core::Stopwatch #t3 = new core::Stopwatch::•() in block {
+  core::Stopwatch* timer = let final core::Stopwatch* #t3 = new core::Stopwatch::•() in block {
     [@vm.direct-call.metadata=dart.core::Stopwatch.start] [@vm.inferred-type.metadata=!? (skip check)] #t3.{core::Stopwatch::start}();
   } =>#t3;
   for (core::int* i = 0; [@vm.direct-call.metadata=dart.core::_IntegerImplementation.<] [@vm.inferred-type.metadata=dart.core::bool (skip check)] i.{core::num::<}(100000000); i = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=int (skip check)] i.{core::num::+}(1)) {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/class_generics_basic.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/class_generics_basic.dart.expect
index 933de35..25ef2d6 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/class_generics_basic.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/class_generics_basic.dart.expect
@@ -57,7 +57,7 @@
   synthetic constructor •() → self::C2<self::C2::T*>*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11,getterSelectorId:12]  method id3([@vm.inferred-type.metadata=dart.core::_Double (skip check) (value: 3.0)] generic-covariant-impl core::Comparable<self::C2::T*>* x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11,getterSelectorId:12] [@vm.unboxing-info.metadata=(d)->d]  method id3([@vm.inferred-type.metadata=dart.core::_Double (skip check) (value: 3.0)] generic-covariant-impl core::Comparable<self::C2::T*>* x) → dynamic
     return x;
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  method id4([@vm.inferred-type.metadata=#lib::K<#lib::J*> (skip check)] generic-covariant-impl self::K<self::I<self::C2::T*>*>* x) → dynamic
     return x;
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/const_prop.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/const_prop.dart.expect
index 870e2ea..e53f25a 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/const_prop.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/const_prop.dart.expect
@@ -12,7 +12,7 @@
     return "bar";
 }
 class B extends core::Object /*isEnum*/  {
-[@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6,getterSelectorId:7]  final field core::int* index;
+[@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  final field core::int* index;
 [@vm.inferred-type.metadata=dart.core::_OneByteString (value: B.b2)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:8,getterSelectorId:9]  final field core::String* _name;
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5]  method toString() → core::String*
     return [@vm.inferred-type.metadata=dart.core::_OneByteString (value: B.b2)] this.{=self::B::_name};
@@ -26,7 +26,7 @@
 static method test2({[@vm.inferred-type.metadata=dart.core::_Smi (value: 43)] core::int* arg = #C2}) → void {
   core::print(arg);
 }
-static get getD() → dynamic
+[@vm.unboxing-info.metadata=()->d]static get getD() → dynamic
   return 100.0;
 [@vm.unboxing-info.metadata=(d)->b]static method testDouble([@vm.inferred-type.metadata=dart.core::_Double (value: 3.14)] core::double* arg) → void {
   core::print(arg);
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/devirt.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/devirt.dart.expect
index b8df814..edc8a9b 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/devirt.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/devirt.dart.expect
@@ -6,20 +6,20 @@
   synthetic constructor •() → self::A*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  abstract method foo() → core::int*;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  abstract method foo() → core::int*;
 }
 class B extends self::A {
   synthetic constructor •() → self::B*
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return 1;
 }
 class C extends core::Object implements self::A {
   synthetic constructor •() → self::C*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return 2;
 }
 class D extends self::C {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/future.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/future.dart.expect
index 56fcd59..432f7fc 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/future.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/future.dart.expect
@@ -9,7 +9,7 @@
   synthetic constructor •() → self::C<self::C::T*>*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method test2c([@vm.inferred-type.metadata=dart.core::_Smi (skip check) (value: 3)] generic-covariant-impl FutureOr<self::C::T*>* x) → void {}
+[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->b]  method test2c([@vm.inferred-type.metadata=dart.core::_Smi (skip check) (value: 3)] generic-covariant-impl FutureOr<self::C::T*>* x) → void {}
 [@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method test3c([@vm.inferred-type.metadata=dart.async::_Future<dart.core::int*> (skip check)] generic-covariant-impl asy::Future<self::C::T*>* x) → void {}
 [@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  method test4c([@vm.inferred-type.metadata=dart.async::_Future<dart.core::int*> (skip check)] generic-covariant-impl FutureOr<self::C::T*>* x) → void {}
 [@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  method test2r([@vm.inferred-type.metadata=#lib::C<dart.core::int*> (skip check)] generic-covariant-impl self::C<FutureOr<self::C::T*>*>* x) → void {}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/lists.dart b/pkg/vm/testcases/transformations/type_flow/transformer/lists.dart
new file mode 100644
index 0000000..62e1f09
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/lists.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.
+
+nonConstant() => int.parse('1') == 1;
+
+class A {
+  final literal1 = <int>[];
+  final literal2 = [1, 2, 3];
+  final constLiteral1 = const <int>[];
+  final constLiteral2 = const [1, 2];
+  final defaultConstructor1 = List<int>();
+  final defaultConstructor2 = List<int>(3);
+  final filledFactory1 = List<int>.filled(2, 0);
+  final filledFactory2 = List<int>.filled(2, 0, growable: true);
+  final filledFactory3 = List<int>.filled(2, 0, growable: false);
+  final filledFactory4 = List<int>.filled(2, 0, growable: nonConstant());
+  final filledFactory5 = List<int>.filled(2, null);
+  final filledFactory6 = List<int>.filled(2, null, growable: true);
+  final filledFactory7 = List<int>.filled(2, null, growable: false);
+  final filledFactory8 = List<int>.filled(2, null, growable: nonConstant());
+  final generateFactory1 = List<int>.generate(2, (i) => i);
+  final generateFactory2 = List<int>.generate(2, (i) => i, growable: true);
+  final generateFactory3 = List<int>.generate(2, (i) => i, growable: false);
+  final generateFactory4 =
+      List<int>.generate(2, (i) => i, growable: nonConstant());
+  final generateFactory5 = List<List<int>>.generate(2, (_) => <int>[]);
+}
+
+main() {
+  A x = A();
+  // Make sure fields are not tree-shaken.
+  print(x.literal1);
+  print(x.literal2);
+  print(x.constLiteral1);
+  print(x.constLiteral2);
+  print(x.defaultConstructor1);
+  print(x.defaultConstructor2);
+  print(x.filledFactory1);
+  print(x.filledFactory2);
+  print(x.filledFactory3);
+  print(x.filledFactory4);
+  print(x.filledFactory5);
+  print(x.filledFactory6);
+  print(x.filledFactory7);
+  print(x.filledFactory8);
+  print(x.generateFactory1);
+  print(x.generateFactory2);
+  print(x.generateFactory3);
+  print(x.generateFactory4);
+  print(x.generateFactory5);
+}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/lists.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/lists.dart.expect
new file mode 100644
index 0000000..af082a0
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/lists.dart.expect
@@ -0,0 +1,53 @@
+library #lib;
+import self as self;
+import "dart:core" as core;
+import "dart:_internal" as _in;
+
+class A extends core::Object {
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  final field core::List<core::int*>* literal1 = <core::int*>[];
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  final field core::List<core::int*>* literal2 = <core::int*>[1, 2, 3];
+[@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[])] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  final field core::List<core::int*>* constLiteral1 = #C1;
+[@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[1, 2])] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  final field core::List<core::int*>* constLiteral2 = #C4;
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9,getterSelectorId:10]  final field core::List<core::int*>* defaultConstructor1 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] core::_GrowableList::•<core::int*>(0);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11,getterSelectorId:12]  final field core::List<core::int*>* defaultConstructor2 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::•<core::int*>(3);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  final field core::List<core::int*>* filledFactory1 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::filled<core::int*>(2, 0);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:15,getterSelectorId:16]  final field core::List<core::int*>* filledFactory2 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] core::_GrowableList::filled<core::int*>(2, 0);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:17,getterSelectorId:18]  final field core::List<core::int*>* filledFactory3 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::filled<core::int*>(2, 0);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:19,getterSelectorId:20]  final field core::List<core::int*>* filledFactory4 = let core::int* #t1 = 2 in let core::int* #t2 = 0 in let core::bool #t3 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::filled<core::int*>(#t1, #t2, #t3);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:21,getterSelectorId:22]  final field core::List<core::int*>* filledFactory5 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::•<core::int*>(2);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:23,getterSelectorId:24]  final field core::List<core::int*>* filledFactory6 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] core::_GrowableList::•<core::int*>(2);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:25,getterSelectorId:26]  final field core::List<core::int*>* filledFactory7 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::•<core::int*>(2);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:27,getterSelectorId:28]  final field core::List<core::int*>* filledFactory8 = let core::int* #t4 = 2 in let core::Null? #t5 = null in let core::bool #t6 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::filled<core::int*>(#t4, #t5, #t6);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:29,getterSelectorId:30]  final field core::List<core::int*>* generateFactory1 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] core::_GrowableList::generate<core::int*>(2, (core::int* i) → core::int* => i);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:31,getterSelectorId:32]  final field core::List<core::int*>* generateFactory2 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] core::_GrowableList::generate<core::int*>(2, (core::int* i) → core::int* => i);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:33,getterSelectorId:34]  final field core::List<core::int*>* generateFactory3 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] core::_List::generate<core::int*>(2, (core::int* i) → core::int* => i);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:35,getterSelectorId:36]  final field core::List<core::int*>* generateFactory4 = let core::int* #t7 = 2 in let (core::int*) →* core::int* #t8 = (core::int* i) → core::int* => i in let core::bool #t9 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::generate<core::int*>(#t7, #t8, #t9);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int*>*>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:37,getterSelectorId:38]  final field core::List<core::List<core::int*>*>* generateFactory5 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int*>*>] core::_GrowableList::generate<core::List<core::int*>*>(2, (core::int* _) → core::List<core::int*>* => <core::int*>[]);
+  synthetic constructor •() → self::A*
+    : super core::Object::•()
+    ;
+}
+static method nonConstant() → dynamic
+  return [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1);
+static method main() → dynamic {
+  self::A* x = new self::A::•();
+  core::print([@vm.direct-call.metadata=#lib::A.literal1] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::literal1});
+  core::print([@vm.direct-call.metadata=#lib::A.literal2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::literal2});
+  core::print([@vm.direct-call.metadata=#lib::A.constLiteral1] [@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[])] x.{self::A::constLiteral1});
+  core::print([@vm.direct-call.metadata=#lib::A.constLiteral2] [@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[1, 2])] x.{self::A::constLiteral2});
+  core::print([@vm.direct-call.metadata=#lib::A.defaultConstructor1] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::defaultConstructor1});
+  core::print([@vm.direct-call.metadata=#lib::A.defaultConstructor2] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::defaultConstructor2});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory1] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::filledFactory1});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::filledFactory2});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory3] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::filledFactory3});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory4] [@vm.inferred-type.metadata=!] x.{self::A::filledFactory4});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory5] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::filledFactory5});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory6] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::filledFactory6});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory7] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::filledFactory7});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory8] [@vm.inferred-type.metadata=!] x.{self::A::filledFactory8});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory1] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::generateFactory1});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int*>] x.{self::A::generateFactory2});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory3] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int*>] x.{self::A::generateFactory3});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory4] [@vm.inferred-type.metadata=!] x.{self::A::generateFactory4});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory5] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int*>*>] x.{self::A::generateFactory5});
+}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart b/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart
new file mode 100644
index 0000000..76fafab
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart
@@ -0,0 +1,50 @@
+// 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.
+
+// This test requires non-nullable experiment.
+// @dart = 2.10
+
+nonConstant() => int.parse('1') == 1;
+
+class A {
+  final literal1 = <int>[];
+  final literal2 = [1, 2, 3];
+  final constLiteral1 = const <int>[];
+  final constLiteral2 = const [1, 2];
+  final filledFactory1 = List<int>.filled(2, 0);
+  final filledFactory2 = List<int>.filled(2, 0, growable: true);
+  final filledFactory3 = List<int>.filled(2, 0, growable: false);
+  final filledFactory4 = List<int>.filled(2, 0, growable: nonConstant());
+  final filledFactory5 = List<int?>.filled(2, null);
+  final filledFactory6 = List<int?>.filled(2, null, growable: true);
+  final filledFactory7 = List<int?>.filled(2, null, growable: false);
+  final filledFactory8 = List<int?>.filled(2, null, growable: nonConstant());
+  final generateFactory1 = List<int>.generate(2, (i) => i);
+  final generateFactory2 = List<int>.generate(2, (i) => i, growable: true);
+  final generateFactory3 = List<int>.generate(2, (i) => i, growable: false);
+  final generateFactory4 =
+      List<int>.generate(2, (i) => i, growable: nonConstant());
+  final generateFactory5 = List<List<int>>.generate(2, (_) => <int>[]);
+}
+
+main() {
+  A x = A();
+  print(x.literal1);
+  print(x.literal2);
+  print(x.constLiteral1);
+  print(x.constLiteral2);
+  print(x.filledFactory1);
+  print(x.filledFactory2);
+  print(x.filledFactory3);
+  print(x.filledFactory4);
+  print(x.filledFactory5);
+  print(x.filledFactory6);
+  print(x.filledFactory7);
+  print(x.filledFactory8);
+  print(x.generateFactory1);
+  print(x.generateFactory2);
+  print(x.generateFactory3);
+  print(x.generateFactory4);
+  print(x.generateFactory5);
+}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart.expect
new file mode 100644
index 0000000..bbe4d4f
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/lists_nnbd.dart.expect
@@ -0,0 +1,49 @@
+library #lib /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+import "dart:_internal" as _in;
+
+class A extends core::Object {
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  final field core::List<core::int> literal1 = <core::int>[];
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  final field core::List<core::int> literal2 = <core::int>[1, 2, 3];
+[@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[])] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  final field core::List<core::int> constLiteral1 = #C1;
+[@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[1, 2])] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  final field core::List<core::int> constLiteral2 = #C4;
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9,getterSelectorId:10]  final field core::List<core::int> filledFactory1 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] core::_List::filled<core::int>(2, 0);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11,getterSelectorId:12]  final field core::List<core::int> filledFactory2 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] core::_GrowableList::filled<core::int>(2, 0);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  final field core::List<core::int> filledFactory3 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] core::_List::filled<core::int>(2, 0);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:15,getterSelectorId:16]  final field core::List<core::int> filledFactory4 = let core::int #t1 = 2 in let core::int #t2 = 0 in let core::bool #t3 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::filled<core::int>(#t1, #t2, #t3);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:17,getterSelectorId:18]  final field core::List<core::int?> filledFactory5 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] core::_List::•<core::int?>(2);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int?>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:19,getterSelectorId:20]  final field core::List<core::int?> filledFactory6 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int?>] core::_GrowableList::•<core::int?>(2);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:21,getterSelectorId:22]  final field core::List<core::int?> filledFactory7 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] core::_List::•<core::int?>(2);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:23,getterSelectorId:24]  final field core::List<core::int?> filledFactory8 = let core::int #t4 = 2 in let core::Null? #t5 = null in let core::bool #t6 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::filled<core::int?>(#t4, #t5, #t6);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:25,getterSelectorId:26]  final field core::List<core::int> generateFactory1 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] core::_GrowableList::generate<core::int>(2, (core::int i) → core::int => i);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:27,getterSelectorId:28]  final field core::List<core::int> generateFactory2 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] core::_GrowableList::generate<core::int>(2, (core::int i) → core::int => i);
+[@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:29,getterSelectorId:30]  final field core::List<core::int> generateFactory3 = [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] core::_List::generate<core::int>(2, (core::int i) → core::int => i);
+[@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:31,getterSelectorId:32]  final field core::List<core::int> generateFactory4 = let core::int #t7 = 2 in let (core::int) → core::int #t8 = (core::int i) → core::int => i in let core::bool #t9 = _in::unsafeCast<core::bool>([@vm.inferred-type.metadata=dart.core::bool] self::nonConstant()) in [@vm.inferred-type.metadata=!] core::List::generate<core::int>(#t7, #t8, #t9);
+[@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int>>] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:33,getterSelectorId:34]  final field core::List<core::List<core::int>> generateFactory5 = [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int>>] core::_GrowableList::generate<core::List<core::int>>(2, (core::int _) → core::List<core::int> => <core::int>[]);
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+}
+static method nonConstant() → dynamic
+  return [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1);
+static method main() → dynamic {
+  self::A x = new self::A::•();
+  core::print([@vm.direct-call.metadata=#lib::A.literal1] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] x.{self::A::literal1});
+  core::print([@vm.direct-call.metadata=#lib::A.literal2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] x.{self::A::literal2});
+  core::print([@vm.direct-call.metadata=#lib::A.constLiteral1] [@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[])] x.{self::A::constLiteral1});
+  core::print([@vm.direct-call.metadata=#lib::A.constLiteral2] [@vm.inferred-type.metadata=dart.core::_ImmutableList (value: const <dart.core::int*>[1, 2])] x.{self::A::constLiteral2});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory1] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] x.{self::A::filledFactory1});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] x.{self::A::filledFactory2});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory3] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] x.{self::A::filledFactory3});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory4] [@vm.inferred-type.metadata=!] x.{self::A::filledFactory4});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory5] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] x.{self::A::filledFactory5});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory6] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int?>] x.{self::A::filledFactory6});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory7] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int?>] x.{self::A::filledFactory7});
+  core::print([@vm.direct-call.metadata=#lib::A.filledFactory8] [@vm.inferred-type.metadata=!] x.{self::A::filledFactory8});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory1] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] x.{self::A::generateFactory1});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory2] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::int>] x.{self::A::generateFactory2});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory3] [@vm.inferred-type.metadata=dart.core::_List<dart.core::int>] x.{self::A::generateFactory3});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory4] [@vm.inferred-type.metadata=!] x.{self::A::generateFactory4});
+  core::print([@vm.direct-call.metadata=#lib::A.generateFactory5] [@vm.inferred-type.metadata=dart.core::_GrowableList<dart.core::List<dart.core::int>>] x.{self::A::generateFactory5});
+}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/named_params_shaking_test.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/named_params_shaking_test.dart.expect
index 8db9738..1eb445c 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/named_params_shaking_test.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/named_params_shaking_test.dart.expect
@@ -15,7 +15,7 @@
   }
 }
 class TestNamedOrderSub extends self::TestNamedOrderBase {
-[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  field core::int* x;
+[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->i]  field core::int* x;
   constructor •() → self::TestNamedOrderSub*
     : self::TestNamedOrderSub::x = [@vm.inferred-type.metadata=int] self::dec(), dynamic #t5 = [@vm.inferred-type.metadata=int] self::inc(), dynamic #t6 = [@vm.inferred-type.metadata=int] self::inc(), dynamic #t7 = [@vm.inferred-type.metadata=int] self::inc(), dynamic #t8 = [@vm.inferred-type.metadata=int] self::dec(), super self::TestNamedOrderBase::•(#t5, #t8, #t7, #t6) {
     exp::Expect::equals([@vm.direct-call.metadata=#lib::TestNamedOrderSub.x] [@vm.inferred-type.metadata=int] this.{self::TestNamedOrderSub::x}, 0);
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/no_such_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/no_such_method.dart.expect
index 5e5e550..c1f1292e 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/no_such_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/no_such_method.dart.expect
@@ -39,7 +39,7 @@
     ;
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  abstract method foo() → dynamic;
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:3]  abstract get bar() → dynamic;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5]  abstract method bazz(dynamic a1, dynamic a2, dynamic a3, [dynamic a4 = #C1, dynamic a5 = #C1]) → dynamic;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5] [@vm.unboxing-info.metadata=(i,i,i)->b]  abstract method bazz(dynamic a1, dynamic a2, dynamic a3, [dynamic a4 = #C1, dynamic a5 = #C1]) → dynamic;
 }
 class B extends self::A {
   synthetic constructor •() → self::B*
@@ -52,7 +52,7 @@
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::B.noSuchMethod] [@vm.inferred-type.metadata=#lib::T1 (skip check)] this.{self::B::noSuchMethod}(new core::_InvocationMirror::_withType(#C2, 1, #C3, #C4, [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  no-such-method-forwarder method foo() → dynamic
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::B.noSuchMethod] [@vm.inferred-type.metadata=#lib::T1 (skip check)] this.{self::B::noSuchMethod}(new core::_InvocationMirror::_withType(#C6, 0, #C3, #C4, [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5]  no-such-method-forwarder method bazz([@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] dynamic a1, [@vm.inferred-type.metadata=dart.core::_Smi (value: 2)] dynamic a2, [@vm.inferred-type.metadata=dart.core::_Smi (value: 3)] dynamic a3, [[@vm.inferred-type.metadata=dart.core::_Smi (value: 4)] dynamic a4 = #C1, [@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic a5 = #C1]) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5] [@vm.unboxing-info.metadata=(i,i,i)->b]  no-such-method-forwarder method bazz([@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] dynamic a1, [@vm.inferred-type.metadata=dart.core::_Smi (value: 2)] dynamic a2, [@vm.inferred-type.metadata=dart.core::_Smi (value: 3)] dynamic a3, [[@vm.inferred-type.metadata=dart.core::_Smi (value: 4)] dynamic a4 = #C1, [@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic a5 = #C1]) → dynamic
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::B.noSuchMethod] [@vm.inferred-type.metadata=#lib::T1 (skip check)] this.{self::B::noSuchMethod}(new core::_InvocationMirror::_withType(#C7, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[a1, a2, a3, a4, a5]), [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
 }
 abstract class C extends core::Object {
@@ -71,7 +71,7 @@
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::C.noSuchMethod] [@vm.inferred-type.metadata=#lib::T2 (skip check)] this.{self::C::noSuchMethod}(new core::_InvocationMirror::_withType(#C2, 1, #C3, #C4, [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  no-such-method-forwarder method foo() → dynamic
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::C.noSuchMethod] [@vm.inferred-type.metadata=#lib::T2 (skip check)] this.{self::C::noSuchMethod}(new core::_InvocationMirror::_withType(#C6, 0, #C3, #C4, [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5]  no-such-method-forwarder method bazz([@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] dynamic a1, [@vm.inferred-type.metadata=dart.core::_Smi (value: 2)] dynamic a2, [@vm.inferred-type.metadata=dart.core::_Smi (value: 3)] dynamic a3, [[@vm.inferred-type.metadata=dart.core::_Smi (value: 4)] dynamic a4 = #C1, [@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic a5 = #C1]) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:5] [@vm.unboxing-info.metadata=(i,i,i)->b]  no-such-method-forwarder method bazz([@vm.inferred-type.metadata=dart.core::_Smi (value: 1)] dynamic a1, [@vm.inferred-type.metadata=dart.core::_Smi (value: 2)] dynamic a2, [@vm.inferred-type.metadata=dart.core::_Smi (value: 3)] dynamic a3, [[@vm.inferred-type.metadata=dart.core::_Smi (value: 4)] dynamic a4 = #C1, [@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic a5 = #C1]) → dynamic
     return _in::unsafeCast<dynamic>([@vm.direct-call.metadata=#lib::C.noSuchMethod] [@vm.inferred-type.metadata=#lib::T2 (skip check)] this.{self::C::noSuchMethod}(new core::_InvocationMirror::_withType(#C7, 0, #C3, core::List::unmodifiable<dynamic>(<dynamic>[a1, a2, a3, a4, a5]), [@vm.inferred-type.metadata=dart.collection::UnmodifiableMapView<dart.core::Symbol*, dynamic>] core::Map::unmodifiable<core::Symbol*, dynamic>(#C5))));
 }
 class E extends core::Object implements self::A {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/null_check_elimination_nnbd.dart b/pkg/vm/testcases/transformations/type_flow/transformer/null_check_elimination_nnbd.dart
index 1d5fb04..b529e22 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/null_check_elimination_nnbd.dart
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/null_check_elimination_nnbd.dart
@@ -5,7 +5,7 @@
 // Tests elimination of null checks.
 // This test requires non-nullable experiment.
 
-// @dart = 2.9
+// @dart = 2.10
 
 class A {
   String? nonNullable;
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/create_test.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/create_test.dart.expect
index 84595a6..3333ebe 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/create_test.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/create_test.dart.expect
@@ -65,10 +65,10 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:6]  @#C14
   get mapKeep() → core::Map<core::String*, self::BarKeep*>*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getMap] [@vm.inferred-type.metadata=! (skip check)] this.{pro::GeneratedMessage::$_getMap}<core::String*, self::BarKeep*>(2);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  @#C16
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=()->i]  @#C16
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(4);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  @#C16
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=(i)->b]  @#C16
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi (value: 43)] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(4, v);
   }
@@ -95,10 +95,10 @@
   @#C10
   static method create() → self::BarKeep*
     return new self::BarKeep::_();
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  @#C12
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14] [@vm.unboxing-info.metadata=()->i]  @#C12
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(0);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  @#C12
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14] [@vm.unboxing-info.metadata=(i)->b]  @#C12
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(0, v);
   }
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/decode_test.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/decode_test.dart.expect
index 7727512..6c5087b 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/decode_test.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/decode_test.dart.expect
@@ -62,7 +62,7 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:6]  @#C15
   get mapKeep() → core::Map<core::String*, self::BarKeep*>*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getMap] [@vm.inferred-type.metadata=! (skip check)] this.{pro::GeneratedMessage::$_getMap}<core::String*, self::BarKeep*>(2);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:7]  @#C17
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  @#C17
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(4);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:8,getterSelectorId:9]  @#C19
@@ -92,7 +92,7 @@
   @#C11
   static method create() → self::BarKeep*
     return new self::BarKeep::_();
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:12]  @#C13
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:12] [@vm.unboxing-info.metadata=()->i]  @#C13
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(0);
 }
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/encode_all_fields.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/encode_all_fields.dart.expect
index 2acd6e9..d3b4dbc 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/encode_all_fields.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/encode_all_fields.dart.expect
@@ -72,7 +72,7 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:5]  @#C17
   get mapDrop() → core::Map<core::String*, self::ZopDrop*>*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getMap] [@vm.inferred-type.metadata=! (skip check)] this.{pro::GeneratedMessage::$_getMap}<core::String*, self::ZopDrop*>(3);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6]  @#C19
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:6] [@vm.unboxing-info.metadata=(i)->b]  @#C19
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi (value: 43)] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(4, v);
   }
@@ -101,11 +101,11 @@
   @#C11
   static method create() → self::BarKeep*
     return new self::BarKeep::_();
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9]  @#C13
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9] [@vm.unboxing-info.metadata=(i)->b]  @#C13
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(0, v);
   }
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:10]  @#C25
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:10] [@vm.unboxing-info.metadata=(i)->b]  @#C25
   set bDrop([@vm.inferred-type.metadata=dart.core::_Smi (value: 4)] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(1, v);
   }
@@ -157,7 +157,7 @@
   @#C11
   static method create() → self::ZopDrop*
     return new self::ZopDrop::_();
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11]  @#C13
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11] [@vm.unboxing-info.metadata=(i)->b]  @#C13
   set aDrop([@vm.inferred-type.metadata=dart.core::_Smi (value: 3)] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(0, v);
   }
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/freeze_test.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/freeze_test.dart.expect
index 768a154..803d43d 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/freeze_test.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/protobuf_handler/lib/freeze_test.dart.expect
@@ -69,10 +69,10 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:6]  @#C14
   get mapKeep() → core::Map<core::String*, self::BarKeep*>*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getMap] [@vm.inferred-type.metadata=! (skip check)] this.{pro::GeneratedMessage::$_getMap}<core::String*, self::BarKeep*>(2);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  @#C16
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=()->i]  @#C16
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(4);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  @#C16
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=(i)->b]  @#C16
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi (value: 43)] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(4, v);
   }
@@ -99,10 +99,10 @@
   @#C10
   static method create() → self::BarKeep*
     return new self::BarKeep::_();
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  @#C12
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14] [@vm.unboxing-info.metadata=()->i]  @#C12
   get aKeep() → core::int*
     return [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_getIZ] [@vm.inferred-type.metadata=int (skip check)] this.{pro::GeneratedMessage::$_getIZ}(0);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14]  @#C12
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:13,getterSelectorId:14] [@vm.unboxing-info.metadata=(i)->b]  @#C12
   set aKeep([@vm.inferred-type.metadata=dart.core::_Smi] core::int* v) → void {
     [@vm.direct-call.metadata=protobuf::GeneratedMessage.$_setSignedInt32] [@vm.inferred-type.metadata=!? (skip check)] this.{pro::GeneratedMessage::$_setSignedInt32}(0, v);
   }
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/regress_41452_nnbd_strong.dart b/pkg/vm/testcases/transformations/type_flow/transformer/regress_41452_nnbd_strong.dart
index b60f24c5..bc79497 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/regress_41452_nnbd_strong.dart
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/regress_41452_nnbd_strong.dart
@@ -6,7 +6,7 @@
 // Tests handling of null initializer of covariant field.
 // This test requires non-nullable experiment and NNBD strong mode.
 
-// @dart = 2.9
+// @dart = 2.10
 
 class _SplayTreeNode<Node extends _SplayTreeNode<Node>> {
   Node? left;
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/regress_42413.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/regress_42413.dart.expect
index 0cd08e2..b9f25d4 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/regress_42413.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/regress_42413.dart.expect
@@ -7,7 +7,7 @@
   synthetic constructor •() → self::B*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:1]  get x() → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:1] [@vm.unboxing-info.metadata=()->i]  get x() → dynamic
     return 0;
 }
 class A extends core::Object {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_dynamic_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_dynamic_method.dart.expect
index 873936d..3b1f57e 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_dynamic_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_dynamic_method.dart.expect
@@ -11,7 +11,7 @@
   synthetic constructor •() → self::B*
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=hasThisUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=hasThisUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return [@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=! (skip check)] 1.{core::num::+}([@vm.direct-call.metadata=#lib::B.foo] [@vm.inferred-type.metadata=!? (receiver not int)] [@vm.inferred-type.metadata=#lib::B] self::knownResult().foo() as{TypeError,ForDynamic} core::num) as{TypeError} core::int*;
 }
 class TearOffDynamicMethod extends core::Object {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_interface_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_interface_method.dart.expect
index acbb8df..dde5bb5 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_interface_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_interface_method.dart.expect
@@ -7,15 +7,15 @@
   synthetic constructor •() → self::A*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  abstract method foo() → core::int*;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  abstract method foo() → core::int*;
 }
 class B extends self::A {
   synthetic constructor •() → self::B*
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return _in::unsafeCast<core::int*>([@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=int (skip check)] 1.{core::num::+}(_in::unsafeCast<core::num>([@vm.direct-call.metadata=#lib::B.bar] [@vm.inferred-type.metadata=dart.core::_Smi (value: 3) (receiver not int)] [@vm.inferred-type.metadata=#lib::B] self::knownResult().bar())));
-[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method bar() → core::int*
+[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4] [@vm.unboxing-info.metadata=()->i]  method bar() → core::int*
     return 3;
 }
 class TearOffInterfaceMethod extends core::Object {
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_super_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_super_method.dart.expect
index e630a88..6090bf0 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_super_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/tear_off_super_method.dart.expect
@@ -7,20 +7,20 @@
   synthetic constructor •() → self::A*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  abstract method foo() → core::int*;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  abstract method foo() → core::int*;
 }
 class B extends self::A {
   synthetic constructor •() → self::B*
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return _in::unsafeCast<core::int*>([@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=int (skip check)] 1.{core::num::+}(_in::unsafeCast<core::num>([@vm.direct-call.metadata=#lib::B.foo] [@vm.inferred-type.metadata=int? (receiver not int)] [@vm.inferred-type.metadata=#lib::B] self::knownResult().foo())));
 }
 abstract class Base extends core::Object {
   synthetic constructor •() → self::Base*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method foo() → core::int*
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,methodOrSetterSelectorId:3,getterSelectorId:4] [@vm.unboxing-info.metadata=()->i]  method foo() → core::int*
     return _in::unsafeCast<core::int*>([@vm.direct-call.metadata=dart.core::_IntegerImplementation.+] [@vm.inferred-type.metadata=int (skip check)] 3.{core::num::+}(_in::unsafeCast<core::num>([@vm.direct-call.metadata=#lib::B.foo] [@vm.inferred-type.metadata=int? (receiver not int)] [@vm.inferred-type.metadata=#lib::B] self::knownResult().foo())));
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  method doCall(dynamic x) → core::int*
     return [@vm.call-site-attributes.metadata=receiverType:dynamic] x.call() as{TypeError,ForDynamic} core::int*;
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination.dart.expect
index 333cde8..bfde4ce 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination.dart.expect
@@ -12,7 +12,7 @@
   synthetic constructor •() → self::B<self::B::T*>*
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->i]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T*>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method testT2negative([@vm.inferred-type.metadata=#lib::A<dart.core::String*>] dynamic x) → dynamic
     return x as self::B::T*;
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart
index 710cf8f..5f0e8e8 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart
@@ -5,7 +5,7 @@
 // Tests elimination of type casts.
 // This test requires non-nullable experiment.
 
-// @dart = 2.9
+// @dart = 2.10
 
 class A<T> {}
 
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart.expect
index dc2fe51..74ab653 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd.dart.expect
@@ -12,13 +12,13 @@
   synthetic constructor •() → self::B<self::B::T%>
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->i]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T%>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method testT2([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T%>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  method testT3([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T%>(x);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  method testNullableT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=(i)->i]  method testNullableT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T?>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9,getterSelectorId:10]  method testNullableT2([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T?>(x);
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart
index 588f620..c828095 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart
@@ -5,7 +5,7 @@
 // Tests elimination of type casts.
 // This test requires non-nullable experiment and NNBD strong mode.
 
-// @dart = 2.9
+// @dart = 2.10
 
 class A<T> {}
 
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart.expect
index a7d832c..b944e65 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/type_cast_elimination_nnbd_strong.dart.expect
@@ -12,13 +12,13 @@
   synthetic constructor •() → self::B<self::B::T%>
     : super self::A::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->i]  method testT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T%>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  method testT2negative([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return x as{ForNonNullableByDefault} self::B::T%;
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  method testT3([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T%>(x);
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  method testNullableT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8] [@vm.unboxing-info.metadata=(i)->i]  method testNullableT1([@vm.inferred-type.metadata=dart.core::_Smi (value: 42)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T?>(x);
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9,getterSelectorId:10]  method testNullableT2([@vm.inferred-type.metadata=dart.core::Null? (value: null)] dynamic x) → dynamic
     return _in::unsafeCast<self::B::T?>(x);
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart
new file mode 100644
index 0000000..4de6f85
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart
@@ -0,0 +1,90 @@
+// 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.
+
+final bool kTrue = int.parse('1') == 1 ? true : false;
+final bool kFalse = int.parse('1') == 2 ? true : false;
+int get mint => 0xaabbccddaabbccdd;
+int get smiOrMint => kTrue ? 1 : mint;
+
+abstract class BI1 {
+  int get value;
+}
+
+class BI1A implements BI1 {
+  final int value;
+  BI1A(this.value);
+}
+
+class BI1B implements BI1 {
+  int get value => null;
+}
+
+abstract class BI2 {
+  int get value;
+}
+
+class BI2A implements BI2 {
+  final int value;
+  BI2A(this.value);
+}
+
+class BI2B implements BI2 {
+  int get value => smiOrMint;
+}
+
+abstract class BI3 {
+  int get value;
+  set value(int value);
+}
+
+class BI3A implements BI3 {
+  int value;
+  BI3A(this.value);
+}
+
+class BI3B implements BI3 {
+  int get value => smiOrMint;
+  set value(int v) {}
+}
+
+abstract class UBI {
+  int value;
+}
+
+class UBIA implements UBI {
+  int value;
+  UBIA(this.value);
+}
+
+class UBIB implements UBI {
+  int get value => smiOrMint;
+  set value(int v) {}
+}
+
+main() {
+  // Getter return value needs to be boxed due to BI1B.value returning `null`.
+  final bi1a = BI1A(smiOrMint);
+  final bi1b = BI1B(); // getter returns null
+  use((kTrue ? bi1a : bi1b).value);
+
+  // Getter return value needs to be boxed due to BI2A.value returning `null`.
+  final bi2a = BI2A(null);
+  final bi2b = BI2B(); // getter returns smiOrMint
+  use((kTrue ? bi2a : bi2b).value);
+
+  // Getter return value needs to be boxed due to setter being called with
+  // `null` value.
+  final bi3a = BI3A(smiOrMint);
+  final bi3b = BI3B(); // getter returns smiOrMint
+  (kTrue ? bi3a : bi3b).value = null;
+  use((kTrue ? bi3a : bi3b).value);
+
+  // Getter return value can be unboxed, both UBIA.value / UBIB.value return
+  // non-nullable int.
+  final ubia = UBIA(smiOrMint);
+  final ubib = UBIB(); // getter returns smiOrMint
+  use((kTrue ? ubia : ubib).value);
+}
+
+void use(dynamic object) {}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart.expect
new file mode 100644
index 0000000..c8dbff7d
--- /dev/null
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_getters.dart.expect
@@ -0,0 +1,91 @@
+library #lib;
+import self as self;
+import "dart:core" as core;
+
+abstract class BI1 extends core::Object {
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:1]  abstract get value() → core::int*;
+}
+class BI1A extends core::Object implements self::BI1 {
+[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:2,getterSelectorId:1]  final field core::int* value;
+[@vm.unboxing-info.metadata=(i)->b]  constructor •([@vm.inferred-type.metadata=int] core::int* value) → self::BI1A*
+    : self::BI1A::value = value, super core::Object::•()
+    ;
+}
+class BI1B extends core::Object implements self::BI1 {
+  synthetic constructor •() → self::BI1B*
+    : super core::Object::•()
+    ;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:1]  get value() → core::int*
+    return null;
+}
+abstract class BI2 extends core::Object {
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:3]  abstract get value() → core::int*;
+}
+class BI2A extends core::Object implements self::BI2 {
+[@vm.inferred-type.metadata=dart.core::Null? (value: null)] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:4,getterSelectorId:3]  final field core::int* value;
+  constructor •([@vm.inferred-type.metadata=dart.core::Null? (value: null)] core::int* value) → self::BI2A*
+    : self::BI2A::value = value, super core::Object::•()
+    ;
+}
+class BI2B extends core::Object implements self::BI2 {
+  synthetic constructor •() → self::BI2B*
+    : super core::Object::•()
+    ;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:3]  get value() → core::int*
+    return [@vm.inferred-type.metadata=int] self::smiOrMint;
+}
+abstract class BI3 extends core::Object {
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  abstract get value() → core::int*;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  abstract set value(core::int* value) → void;
+}
+class BI3A extends core::Object implements self::BI3 {
+[@vm.inferred-type.metadata=int?] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  field core::int* value;
+[@vm.unboxing-info.metadata=(i)->b]  constructor •([@vm.inferred-type.metadata=int] core::int* value) → self::BI3A*
+    : self::BI3A::value = value, super core::Object::•()
+    ;
+}
+class BI3B extends core::Object implements self::BI3 {
+  synthetic constructor •() → self::BI3B*
+    : super core::Object::•()
+    ;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  get value() → core::int*
+    return [@vm.inferred-type.metadata=int] self::smiOrMint;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  set value([@vm.inferred-type.metadata=dart.core::Null? (value: null)] core::int* v) → void {}
+}
+abstract class UBI extends core::Object {
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  abstract get value() → core::int*;
+}
+class UBIA extends core::Object implements self::UBI {
+[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:8,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  field core::int* value;
+[@vm.unboxing-info.metadata=(i)->b]  constructor •([@vm.inferred-type.metadata=int] core::int* value) → self::UBIA*
+    : self::UBIA::value = value, super core::Object::•()
+    ;
+}
+class UBIB extends core::Object implements self::UBI {
+  synthetic constructor •() → self::UBIB*
+    : super core::Object::•()
+    ;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:7] [@vm.unboxing-info.metadata=()->i]  get value() → core::int*
+    return [@vm.inferred-type.metadata=int] self::smiOrMint;
+}
+[@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kTrue = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1) ?{core::bool*} true : false;
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
+  return -6144092014192636707;
+[@vm.unboxing-info.metadata=()->i]static get smiOrMint() → core::int*
+  return [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} 1 : [@vm.inferred-type.metadata=int] self::mint;
+static method main() → dynamic {
+  final self::BI1A* bi1a = new self::BI1A::•([@vm.inferred-type.metadata=int] self::smiOrMint);
+  final self::BI1B* bi1b = new self::BI1B::•();
+  self::use([@vm.inferred-type.metadata=int?]([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::BI1*} bi1a : bi1b).{self::BI1::value});
+  final self::BI2A* bi2a = new self::BI2A::•(null);
+  final self::BI2B* bi2b = new self::BI2B::•();
+  self::use([@vm.inferred-type.metadata=int?]([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::BI2*} bi2a : bi2b).{self::BI2::value});
+  final self::BI3A* bi3a = new self::BI3A::•([@vm.inferred-type.metadata=int] self::smiOrMint);
+  final self::BI3B* bi3b = new self::BI3B::•();
+  ([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::BI3*} bi3a : bi3b).{self::BI3::value} = null;
+  self::use([@vm.inferred-type.metadata=int?]([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::BI3*} bi3a : bi3b).{self::BI3::value});
+  final self::UBIA* ubia = new self::UBIA::•([@vm.inferred-type.metadata=int] self::smiOrMint);
+  final self::UBIB* ubib = new self::UBIB::•();
+  self::use([@vm.inferred-type.metadata=int]([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::UBI*} ubia : ubib).{self::UBI::value});
+}
+static method use([@vm.inferred-type.metadata=int?] dynamic object) → void {}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_fields.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_fields.dart.expect
index 438e696..bce3568 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_fields.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_fields.dart.expect
@@ -8,9 +8,9 @@
     ;
 }
 class A extends core::Object {
-[@vm.inferred-type.metadata=dart.core::_Smi] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2]  field dynamic unboxedSmi;
-[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4]  field dynamic unboxedInt;
-[@vm.inferred-type.metadata=dart.core::_Double] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  field dynamic unboxedDouble;
+[@vm.inferred-type.metadata=dart.core::_Smi] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:1,getterSelectorId:2] [@vm.unboxing-info.metadata=(i)->i]  field dynamic unboxedSmi;
+[@vm.inferred-type.metadata=int] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3,getterSelectorId:4] [@vm.unboxing-info.metadata=(i)->i]  field dynamic unboxedInt;
+[@vm.inferred-type.metadata=dart.core::_Double] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6] [@vm.unboxing-info.metadata=(d)->d]  field dynamic unboxedDouble;
 [@vm.inferred-type.metadata=int?] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:7,getterSelectorId:8]  field dynamic boxedNullableInt;
 [@vm.inferred-type.metadata=dart.core::_Double?] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:9,getterSelectorId:10]  field dynamic boxedNullableDouble;
 [@vm.inferred-type.metadata=!] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:11,getterSelectorId:12]  field dynamic boxedNonNullableIntOrDouble;
@@ -23,9 +23,9 @@
 }
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kTrue = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1) ?{core::bool*} true : false;
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kFalse = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(2) ?{core::bool*} true : false;
-static get mint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
   return -6144092014192636707;
-static get smiOrMint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get smiOrMint() → core::int*
   return [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} 1 : [@vm.inferred-type.metadata=int] self::mint;
 static method main() → dynamic {
   final self::A* a = new self::A::•([@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} 1 : 2, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} [@vm.inferred-type.metadata=int] self::smiOrMint : 2, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::double*} 1.1 : 2.2, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} [@vm.inferred-type.metadata=int] self::smiOrMint : null, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::double*} 1.1 : null, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::num*} [@vm.inferred-type.metadata=int] self::smiOrMint : 1.1, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::num*} [@vm.inferred-type.metadata=dart.core::bool?] self::kFalse ?{core::num*} [@vm.inferred-type.metadata=int] self::smiOrMint : 1.1 : null, [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{self::X*} new self::X::•() : null, new self::X::•());
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method.dart.expect
index 87a7918..e019e26 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method.dart.expect
@@ -91,7 +91,7 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:19,getterSelectorId:20]  method returnBoxedX([@vm.inferred-type.metadata=dart.core::Null? (value: null)] self::X* ignored) → dynamic
     return new self::X::•();
 }
-static get mint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
   return -6144092014192636707;
 static method main() → dynamic {
   final core::List<core::Object*>* values = <core::Object*>[new self::Impl1::•(), new self::BaseImpl2::•(), new self::SubImpl3::•()];
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method_tearoff.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method_tearoff.dart.expect
index a28e015..bed2172 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method_tearoff.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_instance_method_tearoff.dart.expect
@@ -91,7 +91,7 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,methodOrSetterSelectorId:19,getterSelectorId:20]  method returnBoxedX(self::X* ignored) → dynamic
     return new self::X::•();
 }
-static get mint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
   return -6144092014192636707;
 static method main() → dynamic {
   final core::List<core::Object*>* values = <core::Object*>[new self::Impl1::•(), new self::BaseImpl2::•(), new self::SubImpl3::•()];
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method.dart.expect
index 7994267..8074925 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method.dart.expect
@@ -9,9 +9,9 @@
 }
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kTrue = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1) ?{core::bool*} true : false;
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kFalse = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(2) ?{core::bool*} true : false;
-static get mint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
   return -6144092014192636707;
-static get smiOrMint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get smiOrMint() → core::int*
   return [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} 1 : [@vm.inferred-type.metadata=int] self::mint;
 [@vm.unboxing-info.metadata=(i,i,d,b,b,b,b,b,b)->b]static method takePositional([@vm.inferred-type.metadata=dart.core::_Smi] core::int* unboxedSmi, [@vm.inferred-type.metadata=int] dynamic unboxedInt, [@vm.inferred-type.metadata=dart.core::_Double] dynamic unboxedDouble, [@vm.inferred-type.metadata=int?] dynamic boxedNullableInt, [@vm.inferred-type.metadata=dart.core::_Double?] dynamic boxedNullableDouble, [@vm.inferred-type.metadata=!] dynamic boxedIntOrDouble, dynamic boxedNullableIntOrDouble, [@vm.inferred-type.metadata=#lib::X?] dynamic boxedNullableX, [@vm.inferred-type.metadata=#lib::X] dynamic boxedX) → void {}
 static method takeOptional([@vm.inferred-type.metadata=dart.core::_Smi] core::int* unboxedSmi, [@vm.inferred-type.metadata=int] dynamic unboxedInt, [@vm.inferred-type.metadata=dart.core::_Double] dynamic unboxedDouble, [@vm.inferred-type.metadata=int?] dynamic boxedNullableInt, [@vm.inferred-type.metadata=dart.core::_Double?] dynamic boxedNullableDouble, [@vm.inferred-type.metadata=!] dynamic boxedIntOrDouble, dynamic boxedNullableIntOrDouble, [@vm.inferred-type.metadata=#lib::X?] dynamic boxedNullableX, [@vm.inferred-type.metadata=#lib::X] dynamic boxedX) → void {}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method_tearoff.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method_tearoff.dart.expect
index 97e7e41..62e1f32 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method_tearoff.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/unboxed_static_method_tearoff.dart.expect
@@ -9,9 +9,9 @@
 }
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kTrue = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(1) ?{core::bool*} true : false;
 [@vm.inferred-type.metadata=dart.core::bool?]static final field core::bool* kFalse = [@vm.direct-call.metadata=dart.core::_IntegerImplementation.==] [@vm.inferred-type.metadata=dart.core::bool (skip check)] [@vm.inferred-type.metadata=int] core::int::parse("1").{core::num::==}(2) ?{core::bool*} true : false;
-static get mint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get mint() → core::int*
   return -6144092014192636707;
-static get smiOrMint() → core::int*
+[@vm.unboxing-info.metadata=()->i]static get smiOrMint() → core::int*
   return [@vm.inferred-type.metadata=dart.core::bool?] self::kTrue ?{core::int*} 1 : [@vm.inferred-type.metadata=int] self::mint;
 static method takePositional(core::int* unboxedSmi, dynamic unboxedInt, dynamic unboxedDouble, dynamic boxedNullableInt, dynamic boxedNullableDouble, dynamic boxedIntOrDouble, dynamic boxedNullableIntOrDouble, dynamic boxedNullableX, dynamic boxedX) → void {}
 static method takeOptional([@vm.inferred-type.metadata=dart.core::_Smi] core::int* unboxedSmi, [@vm.inferred-type.metadata=int] dynamic unboxedInt, [@vm.inferred-type.metadata=dart.core::_Double] dynamic unboxedDouble, [@vm.inferred-type.metadata=int?] dynamic boxedNullableInt, [@vm.inferred-type.metadata=dart.core::_Double?] dynamic boxedNullableDouble, [@vm.inferred-type.metadata=!] dynamic boxedIntOrDouble, dynamic boxedNullableIntOrDouble, [@vm.inferred-type.metadata=#lib::X?] dynamic boxedNullableX, [@vm.inferred-type.metadata=#lib::X] dynamic boxedX) → void {}
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field2.dart.expect b/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field2.dart.expect
index 2035697..850e0b6 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field2.dart.expect
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field2.dart.expect
@@ -26,17 +26,17 @@
 [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:3]  set bar(generic-covariant-impl core::int* value) → void;
 }
 abstract class E extends core::Object {
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:4]  abstract get bar() → core::int*;
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:4] [@vm.unboxing-info.metadata=()->i]  abstract get bar() → core::int*;
 }
 class F extends core::Object implements self::E {
   synthetic constructor •() → self::F*
     : super core::Object::•()
     ;
-[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:4]  get bar() → core::int*
+[@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,getterSelectorId:4] [@vm.unboxing-info.metadata=()->i]  get bar() → core::int*
     return 42;
 }
 class G extends core::Object /*hasConstConstructor*/  {
-[@vm.inferred-type.metadata=dart.core::_Smi] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6]  final field core::int* bazz;
+[@vm.inferred-type.metadata=dart.core::_Smi] [@vm.procedure-attributes.metadata=methodOrSetterCalledDynamically:false,getterCalledDynamically:false,hasThisUses:false,hasNonThisUses:false,hasTearOffUses:false,methodOrSetterSelectorId:5,getterSelectorId:6] [@vm.unboxing-info.metadata=()->i]  final field core::int* bazz;
 }
 abstract class H extends core::Object {
   synthetic constructor •() → self::H*
diff --git a/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field3_nnbd.dart b/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field3_nnbd.dart
index bcc6ec4..ea59290 100644
--- a/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field3_nnbd.dart
+++ b/pkg/vm/testcases/transformations/type_flow/transformer/write_only_field3_nnbd.dart
@@ -5,7 +5,7 @@
 // Test for tree shaking of write-only late fields.
 // This test requires non-nullable experiment.
 
-// @dart = 2.9
+// @dart = 2.10
 
 foo() {}
 
diff --git a/pkg/vm/tool/precompiler2 b/pkg/vm/tool/precompiler2
index dd5b9be..b1199c1 100755
--- a/pkg/vm/tool/precompiler2
+++ b/pkg/vm/tool/precompiler2
@@ -26,8 +26,8 @@
     PACKAGES="$arg"
     ;;
     --enable-asserts | \
-    --null-safety | \
-    --no-null-safety | \
+    --sound-null-safety | \
+    --no-sound-null-safety | \
     --enable-experiment=*)
     GEN_KERNEL_OPTIONS+=("$arg")
     OPTIONS+=("$arg")
diff --git a/pkg/vm_snapshot_analysis/CHANGELOG.md b/pkg/vm_snapshot_analysis/CHANGELOG.md
index 4c1fc39..4eb142c 100644
--- a/pkg/vm_snapshot_analysis/CHANGELOG.md
+++ b/pkg/vm_snapshot_analysis/CHANGELOG.md
@@ -1,5 +1,20 @@
 # Changelog
 
+## 0.5.1-dev.1
+- Move `commands` back to lib.
+
+## 0.5.0+1
+- Fix broken package by moving non-executable file out of bin/ directory.
+
+## 0.5.0
+- Remove `dart:io` dependency from package `lib`, and move `commands` to `bin`.
+- Replace `loadProgramInfo` util method with `loadProgramInfoFromJson`, which
+expects an `Object` parameter instead of a `File` parameter.
+- `buildComparisonTreemap` now expects two `Object` parameters for `oldJson` and
+`newJson` instead of two `File` parameters.
+- `compare` command now prints difference breakdown by node type when this
+information is available.
+
 ## 0.4.0
 
 - Add `buildComparisonTreemap` for constructing treemap representing the diff
diff --git a/pkg/vm_snapshot_analysis/lib/precompiler_trace.dart b/pkg/vm_snapshot_analysis/lib/precompiler_trace.dart
index af86713..42cd027 100644
--- a/pkg/vm_snapshot_analysis/lib/precompiler_trace.dart
+++ b/pkg/vm_snapshot_analysis/lib/precompiler_trace.dart
@@ -5,17 +5,14 @@
 /// Helpers for working with the output of `--trace-precompiler-to` VM flag.
 library vm_snapshot_analysis.precompiler_trace;
 
-import 'dart:io';
 import 'dart:math' as math;
 
 import 'package:vm_snapshot_analysis/name.dart';
 import 'package:vm_snapshot_analysis/program_info.dart';
-import 'package:vm_snapshot_analysis/utils.dart';
 
 /// Build [CallGraph] based on the trace written by `--trace-precompiler-to`
 /// flag.
-Future<CallGraph> loadTrace(File input) async =>
-    _TraceReader(await loadJson(input)).readTrace();
+CallGraph loadTrace(Object inputJson) => _TraceReader(inputJson).readTrace();
 
 /// [CallGraphNode] represents a node of the call-graph. It can either be:
 ///
@@ -439,10 +436,11 @@
             callNodesBySelector[targetName]?.connectTo(funNode);
             callNodesBySelector['$dynPrefix$targetName']?.connectTo(funNode);
           } else if (name.startsWith(extractorPrefix)) {
-            // Handle method tear-off: [tear-off-extractor] get:foo is hit
-            // by get:foo.
-            callNodesBySelector[name.substring(extractorPrefix.length)]
-                ?.connectTo(funNode);
+            // Handle method tear-off: [tear-off-extractor] get:foo can be hit
+            // by dyn:get:foo and get:foo.
+            final targetName = name.substring(extractorPrefix.length);
+            callNodesBySelector[targetName]?.connectTo(funNode);
+            callNodesBySelector['$dynPrefix$targetName']?.connectTo(funNode);
           }
         }
       }
diff --git a/pkg/vm_snapshot_analysis/lib/src/commands/compare.dart b/pkg/vm_snapshot_analysis/lib/src/commands/compare.dart
index 52f8b43..4a9442e 100644
--- a/pkg/vm_snapshot_analysis/lib/src/commands/compare.dart
+++ b/pkg/vm_snapshot_analysis/lib/src/commands/compare.dart
@@ -16,6 +16,8 @@
 import 'package:vm_snapshot_analysis/utils.dart';
 import 'package:vm_snapshot_analysis/v8_profile.dart';
 
+import 'utils.dart';
+
 class CompareCommand extends Command<void> {
   @override
   final String name = 'compare';
@@ -107,9 +109,11 @@
       {int maxWidth = 0,
       bool collapseAnonymousClosures = false,
       HistogramType granularity = HistogramType.bySymbol}) async {
-    final oldSizes = await loadProgramInfo(oldJson,
+    final oldJsonRaw = await loadJsonFromFile(oldJson);
+    final newJsonRaw = await loadJsonFromFile(newJson);
+    final oldSizes = loadProgramInfoFromJson(oldJsonRaw,
         collapseAnonymousClosures: collapseAnonymousClosures);
-    final newSizes = await loadProgramInfo(newJson,
+    final newSizes = loadProgramInfoFromJson(newJsonRaw,
         collapseAnonymousClosures: collapseAnonymousClosures);
 
     if ((oldSizes.snapshotInfo == null) != (newSizes.snapshotInfo == null)) {
@@ -144,10 +148,33 @@
     print('Comparing ${oldJson.path} (old) to ${newJson.path} (new)');
     print('Old   : ${totalOld} bytes.');
     print('New   : ${totalNew} bytes.');
-    print('Change: ${totalDiff > 0 ? '+' : ''}${totalDiff} bytes.');
+    print('Change: ${totalDiff > 0 ? '+' : ''}${totalDiff}'
+        ' (${formatPercent(totalDiff, totalOld, withSign: true)}) bytes.');
 
     if (oldSizes.snapshotInfo != null) {
       print(bucketLegend);
+      print('\nBreakdown by object type:');
+      final oldTypeHistogram =
+          computeHistogram(oldSizes, HistogramType.byNodeType);
+      final newTypeHistogram =
+          computeHistogram(newSizes, HistogramType.byNodeType);
+
+      final diffTypeHistogram = Histogram.fromIterable(
+          Set<String>()
+            ..addAll(oldTypeHistogram.buckets.keys)
+            ..addAll(newTypeHistogram.buckets.keys),
+          sizeOf: (bucket) =>
+              (newTypeHistogram.buckets[bucket] ?? 0) -
+              (oldTypeHistogram.buckets[bucket] ?? 0),
+          bucketFor: (bucket) => bucket,
+          bucketInfo: oldTypeHistogram.bucketInfo);
+
+      printHistogram(oldSizes, diffTypeHistogram,
+          prefix: diffTypeHistogram.bySize
+              .where((bucket) => diffTypeHistogram.buckets[bucket] != 0),
+          maxWidth: maxWidth);
+
+      print(bucketLegend);
     }
   }
 }
diff --git a/pkg/vm_snapshot_analysis/lib/src/commands/explain.dart b/pkg/vm_snapshot_analysis/lib/src/commands/explain.dart
index 2688628..33c1418 100644
--- a/pkg/vm_snapshot_analysis/lib/src/commands/explain.dart
+++ b/pkg/vm_snapshot_analysis/lib/src/commands/explain.dart
@@ -17,6 +17,8 @@
 import 'package:vm_snapshot_analysis/program_info.dart';
 import 'package:vm_snapshot_analysis/utils.dart';
 
+import 'utils.dart';
+
 class ExplainCommand extends Command<void> {
   @override
   final name = 'explain';
@@ -55,16 +57,18 @@
     if (!sizesJson.existsSync()) {
       usageException('Size profile ${sizesJson.path} does not exist!');
     }
+    final sizesJsonRaw = await loadJsonFromFile(sizesJson);
 
     final traceJson = File(argResults.rest[1]);
     if (!traceJson.existsSync()) {
       usageException('Size profile ${traceJson.path} does not exist!');
     }
+    final traceJsonRaw = await loadJsonFromFile(traceJson);
 
-    final callGraph = await loadTrace(traceJson);
+    final callGraph = loadTrace(traceJsonRaw);
     callGraph.computeDominators();
 
-    final programInfo = await loadProgramInfo(sizesJson);
+    final programInfo = loadProgramInfoFromJson(sizesJsonRaw);
 
     final histogram = Histogram.fromIterable<CallGraphNode>(
         callGraph.dynamicCalls, sizeOf: (dynamicCall) {
diff --git a/pkg/vm_snapshot_analysis/lib/src/commands/summary.dart b/pkg/vm_snapshot_analysis/lib/src/commands/summary.dart
index e7e012b..1851f5e 100644
--- a/pkg/vm_snapshot_analysis/lib/src/commands/summary.dart
+++ b/pkg/vm_snapshot_analysis/lib/src/commands/summary.dart
@@ -20,6 +20,8 @@
 import 'package:vm_snapshot_analysis/utils.dart';
 import 'package:vm_snapshot_analysis/v8_profile.dart';
 
+import 'utils.dart';
+
 class SummaryCommand extends Command<void> {
   @override
   final name = 'summary';
@@ -154,7 +156,8 @@
     File traceJson,
     int depsCollapseDepth = 3,
     int topToReport = 30}) async {
-  final info = await loadProgramInfo(input);
+  final inputJson = await loadJsonFromFile(input);
+  final info = loadProgramInfoFromJson(inputJson);
 
   // Compute histogram.
   var histogram = computeHistogram(info, granularity, filter: filter);
@@ -165,7 +168,8 @@
   if (traceJson != null &&
       (granularity == HistogramType.byLibrary ||
           granularity == HistogramType.byPackage)) {
-    var callGraph = await loadTrace(traceJson);
+    final traceJsonRaw = loadJsonFromFile(traceJson);
+    var callGraph = loadTrace(traceJsonRaw);
 
     // Convert call graph into the approximate dependency graph, dropping any
     // dynamic and dispatch table based dependencies from the graph and only
diff --git a/pkg/vm_snapshot_analysis/lib/src/commands/treemap.dart b/pkg/vm_snapshot_analysis/lib/src/commands/treemap.dart
index 66e9a06..059d353 100644
--- a/pkg/vm_snapshot_analysis/lib/src/commands/treemap.dart
+++ b/pkg/vm_snapshot_analysis/lib/src/commands/treemap.dart
@@ -17,9 +17,9 @@
 
 import 'package:path/path.dart' as p;
 import 'package:args/command_runner.dart';
-
 import 'package:vm_snapshot_analysis/treemap.dart';
-import 'package:vm_snapshot_analysis/utils.dart';
+
+import 'utils.dart';
 
 class TreemapCommand extends Command<void> {
   @override
@@ -89,7 +89,7 @@
     {TreemapFormat format = TreemapFormat.objectType}) async {
   // Load symbols data produced by the AOT compiler and convert it to
   // a tree.
-  final inputJson = await loadJson(input);
+  final inputJson = await loadJsonFromFile(input);
   final tree = treemapFromJson(inputJson, format: format);
 
   // Create output directory and copy all auxiliary files from binary_size tool.
diff --git a/pkg/vm_snapshot_analysis/lib/src/commands/utils.dart b/pkg/vm_snapshot_analysis/lib/src/commands/utils.dart
new file mode 100644
index 0000000..f6a5bbe
--- /dev/null
+++ b/pkg/vm_snapshot_analysis/lib/src/commands/utils.dart
@@ -0,0 +1,14 @@
+// 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:convert';
+import 'dart:io';
+
+Future<Object> loadJsonFromFile(File input) async {
+  return await input
+      .openRead()
+      .transform(utf8.decoder)
+      .transform(json.decoder)
+      .first;
+}
diff --git a/pkg/vm_snapshot_analysis/lib/utils.dart b/pkg/vm_snapshot_analysis/lib/utils.dart
index 33e1d84..2023833 100644
--- a/pkg/vm_snapshot_analysis/lib/utils.dart
+++ b/pkg/vm_snapshot_analysis/lib/utils.dart
@@ -3,9 +3,6 @@
 // BSD-style license that can be found in the LICENSE file.
 library vm_snapshot_analysis.utils;
 
-import 'dart:io';
-import 'dart:convert';
-
 import 'package:vm_snapshot_analysis/ascii_table.dart';
 import 'package:vm_snapshot_analysis/program_info.dart';
 import 'package:vm_snapshot_analysis/instruction_sizes.dart'
@@ -13,17 +10,8 @@
 import 'package:vm_snapshot_analysis/treemap.dart';
 import 'package:vm_snapshot_analysis/v8_profile.dart' as v8_profile;
 
-Future<Object> loadJson(File input) async {
-  return await input
-      .openRead()
-      .transform(utf8.decoder)
-      .transform(json.decoder)
-      .first;
-}
-
-Future<ProgramInfo> loadProgramInfo(File input,
-    {bool collapseAnonymousClosures = false}) async {
-  final json = await loadJson(input);
+ProgramInfo loadProgramInfoFromJson(Object json,
+    {bool collapseAnonymousClosures = false}) {
   if (v8_profile.Snapshot.isV8HeapSnapshot(json)) {
     return v8_profile.toProgramInfo(v8_profile.Snapshot.fromJson(json),
         collapseAnonymousClosures: collapseAnonymousClosures);
@@ -34,12 +22,12 @@
 }
 
 /// Compare two size profiles and return result of the comparison as a treemap.
-Future<Map<String, dynamic>> buildComparisonTreemap(File oldJson, File newJson,
+Map<String, dynamic> buildComparisonTreemap(Object oldJson, Object newJson,
     {TreemapFormat format = TreemapFormat.collapsed,
-    bool collapseAnonymousClosures = false}) async {
-  final oldSizes = await loadProgramInfo(oldJson,
+    bool collapseAnonymousClosures = false}) {
+  final oldSizes = loadProgramInfoFromJson(oldJson,
       collapseAnonymousClosures: collapseAnonymousClosures);
-  final newSizes = await loadProgramInfo(newJson,
+  final newSizes = loadProgramInfoFromJson(newJson,
       collapseAnonymousClosures: collapseAnonymousClosures);
 
   final diff = computeDiff(oldSizes, newSizes);
@@ -47,6 +35,12 @@
   return treemapFromInfo(diff, format: format);
 }
 
+String formatPercent(int value, int total, {bool withSign = false}) {
+  final p = value / total * 100.0;
+  final sign = (withSign && value > 0) ? '+' : '';
+  return '${sign}${p.toStringAsFixed(2)}%';
+}
+
 void printHistogram(ProgramInfo info, Histogram histogram,
     {Iterable<String> prefix = const [],
     Iterable<String> suffix = const [],
@@ -61,10 +55,14 @@
     if (wasFiltered) Text.right('Of total'),
   ], maxWidth: maxWidth);
 
-  String formatPercent(int value, int total) {
-    final p = value / total * 100.0;
-    return p.toStringAsFixed(2) + "%";
-  }
+  final visibleRows = [prefix, suffix].expand((l) => l).toList();
+  final visibleSize =
+      visibleRows.fold(0, (sum, key) => sum + histogram.buckets[key]);
+  final numRestRows = histogram.length - (suffix.length + prefix.length);
+  final hiddenRows = Set<String>.from(histogram.bySize)
+      .difference(Set<String>.from(visibleRows));
+  final interestingHiddenRows =
+      hiddenRows.any((k) => histogram.buckets[k] != 0);
 
   if (prefix.isNotEmpty) {
     for (var key in prefix) {
@@ -76,15 +74,10 @@
         if (wasFiltered) formatPercent(size, totalSize),
       ]);
     }
-    table.addSeparator(
-        prefix.length < histogram.length ? Separator.Wave : Separator.Line);
+    table.addSeparator(interestingHiddenRows ? Separator.Wave : Separator.Line);
   }
 
-  final visibleSize = [prefix, suffix]
-      .expand((l) => l)
-      .fold(0, (sum, key) => sum + histogram.buckets[key]);
-  final numRestRows = histogram.length - (suffix.length + prefix.length);
-  if (numRestRows > 0) {
+  if (interestingHiddenRows) {
     final totalRestBytes = histogram.totalSize - visibleSize;
     table.addTextSeparator(
         '$numRestRows more rows accounting for ${totalRestBytes}'
diff --git a/pkg/vm_snapshot_analysis/pubspec.yaml b/pkg/vm_snapshot_analysis/pubspec.yaml
index 4e0bf95..67f347e 100644
--- a/pkg/vm_snapshot_analysis/pubspec.yaml
+++ b/pkg/vm_snapshot_analysis/pubspec.yaml
@@ -1,6 +1,6 @@
 name: vm_snapshot_analysis
 description: Utilities for analysing AOT snapshot size.
-version: 0.4.0
+version: 0.5.1-dev.1
 
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/vm_snapshot_analysis
 
diff --git a/pkg/vm_snapshot_analysis/test/instruction_sizes_test.dart b/pkg/vm_snapshot_analysis/test/instruction_sizes_test.dart
index f2a7741..fb15baf 100644
--- a/pkg/vm_snapshot_analysis/test/instruction_sizes_test.dart
+++ b/pkg/vm_snapshot_analysis/test/instruction_sizes_test.dart
@@ -182,8 +182,8 @@
   group('instruction-sizes', () {
     test('basic-parsing', () async {
       await withSymbolSizes('basic-parsing', testSource, (sizesJson) async {
-        final symbols =
-            instruction_sizes.fromJson(await loadJson(File(sizesJson)));
+        final json = await loadJson(File(sizesJson));
+        final symbols = instruction_sizes.fromJson(json);
         expect(symbols, isNotNull,
             reason: 'Sizes file was successfully parsed');
         expect(symbols.length, greaterThan(0),
@@ -256,7 +256,8 @@
     test('program-info-from-sizes', () async {
       await withSymbolSizes('program-info-from-sizes', testSource,
           (sizesJson) async {
-        final info = await loadProgramInfo(File(sizesJson));
+        final json = await loadJson(File(sizesJson));
+        final info = loadProgramInfoFromJson(json);
         expect(info.root.children, contains('dart:core'));
         expect(info.root.children, contains('dart:typed_data'));
         expect(info.root.children, contains('package:input'));
@@ -303,7 +304,8 @@
 
     test('histograms', () async {
       await withSymbolSizes('histograms', testSource, (sizesJson) async {
-        final info = await loadProgramInfo(File(sizesJson));
+        final json = await loadJson(File(sizesJson));
+        final info = loadProgramInfoFromJson(json);
         final bySymbol = computeHistogram(info, HistogramType.bySymbol);
         expect(
             bySymbol.buckets,
@@ -356,8 +358,10 @@
       await withSymbolSizes('diff-1', testSource, (sizesJson) async {
         await withSymbolSizes('diff-2', testSourceModified,
             (modifiedSizesJson) async {
-          final info = await loadProgramInfo(File(sizesJson));
-          final modifiedInfo = await loadProgramInfo(File(modifiedSizesJson));
+          final infoJson = await loadJson(File(sizesJson));
+          final info = loadProgramInfoFromJson(infoJson);
+          final modifiedJson = await loadJson(File(modifiedSizesJson));
+          final modifiedInfo = loadProgramInfoFromJson(modifiedJson);
           final diff = computeDiff(info, modifiedInfo);
 
           expect(
@@ -403,9 +407,11 @@
       await withSymbolSizes('diff-collapsed-1', testSource, (sizesJson) async {
         await withSymbolSizes('diff-collapsed-2', testSourceModified2,
             (modifiedSizesJson) async {
-          final info = await loadProgramInfo(File(sizesJson),
-              collapseAnonymousClosures: true);
-          final modifiedInfo = await loadProgramInfo(File(modifiedSizesJson),
+          final json = await loadJson(File(sizesJson));
+          final info =
+              loadProgramInfoFromJson(json, collapseAnonymousClosures: true);
+          final modifiedJson = await loadJson(File(modifiedSizesJson));
+          final modifiedInfo = loadProgramInfoFromJson(modifiedJson,
               collapseAnonymousClosures: true);
           final diff = computeDiff(info, modifiedInfo);
 
@@ -442,7 +448,8 @@
     test('program-info-from-profile', () async {
       await withV8Profile('program-info-from-profile', testSource,
           (profileJson) async {
-        final info = await loadProgramInfo(File(profileJson));
+        final infoJson = await loadJson(File(profileJson));
+        final info = loadProgramInfoFromJson(infoJson);
         expect(info.root.children, contains('dart:core'));
         expect(info.root.children, contains('dart:typed_data'));
         expect(info.root.children, contains('package:input'));
@@ -500,7 +507,8 @@
 
     test('histograms', () async {
       await withV8Profile('histograms', testSource, (sizesJson) async {
-        final info = await loadProgramInfo(File(sizesJson));
+        final infoJson = await loadJson(File(sizesJson));
+        final info = loadProgramInfoFromJson(infoJson);
         final bySymbol = computeHistogram(info, HistogramType.bySymbol);
         expect(
             bySymbol.buckets,
@@ -553,8 +561,10 @@
       await withV8Profile('diff-1', testSource, (profileJson) async {
         await withV8Profile('diff-2', testSourceModified,
             (modifiedProfileJson) async {
-          final info = await loadProgramInfo(File(profileJson));
-          final modifiedInfo = await loadProgramInfo(File(modifiedProfileJson));
+          final infoJson = await loadJson(File(profileJson));
+          final info = loadProgramInfoFromJson(infoJson);
+          final modifiedJson = await loadJson(File(modifiedProfileJson));
+          final modifiedInfo = loadProgramInfoFromJson(modifiedJson);
           final diff = computeDiff(info, modifiedInfo);
 
           expect(
@@ -597,9 +607,11 @@
       await withV8Profile('diff-collapsed-1', testSource, (profileJson) async {
         await withV8Profile('diff-collapsed-2', testSourceModified2,
             (modifiedProfileJson) async {
-          final info = await loadProgramInfo(File(profileJson),
+          final infoJson = await loadJson(File(profileJson));
+          final info = loadProgramInfoFromJson(infoJson,
               collapseAnonymousClosures: true);
-          final modifiedInfo = await loadProgramInfo(File(modifiedProfileJson),
+          final modifiedJson = await loadJson(File(modifiedProfileJson));
+          final modifiedInfo = loadProgramInfoFromJson(modifiedJson,
               collapseAnonymousClosures: true);
           final diff = computeDiff(info, modifiedInfo);
 
diff --git a/pkg/vm_snapshot_analysis/test/precompiler_trace_test.dart b/pkg/vm_snapshot_analysis/test/precompiler_trace_test.dart
index f12fdc5..ef294fe 100644
--- a/pkg/vm_snapshot_analysis/test/precompiler_trace_test.dart
+++ b/pkg/vm_snapshot_analysis/test/precompiler_trace_test.dart
@@ -70,7 +70,8 @@
     test('basic-parsing', () async {
       await withFlag('basic-parsing', testSource, '--trace_precompiler_to',
           (json) async {
-        final callGraph = await loadTrace(File(json));
+        final jsonRaw = await loadJson(File(json));
+        final callGraph = loadTrace(jsonRaw);
         callGraph.computeDominators();
 
         final main = callGraph.program
@@ -88,8 +89,8 @@
         expect(retainedClasses, containsAll(['A', 'B', 'K']));
         expect(retainedFunctions, containsAll(['print', 'tearOff']));
 
-        final getTearOffCall =
-            callGraph.dynamicCalls.firstWhere((n) => n.data == 'get:tornOff');
+        final getTearOffCall = callGraph.dynamicCalls
+            .firstWhere((n) => n.data == 'dyn:get:tornOff');
         expect(
             getTearOffCall.dominated.map((n) => n.data.qualifiedName),
             equals([
diff --git a/pkg/vm_snapshot_analysis/test/utils.dart b/pkg/vm_snapshot_analysis/test/utils.dart
index 375a904..2531279 100644
--- a/pkg/vm_snapshot_analysis/test/utils.dart
+++ b/pkg/vm_snapshot_analysis/test/utils.dart
@@ -2,6 +2,7 @@
 // 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:convert';
 import 'dart:io';
 
 import 'package:path/path.dart' as path;
@@ -73,3 +74,11 @@
     tempDir.deleteSync(recursive: true);
   }
 }
+
+Future<Object> loadJson(File input) async {
+  return await input
+      .openRead()
+      .transform(utf8.decoder)
+      .transform(json.decoder)
+      .first;
+}
diff --git a/runtime/BUILD.gn b/runtime/BUILD.gn
index 6da22fb..20efa72 100644
--- a/runtime/BUILD.gn
+++ b/runtime/BUILD.gn
@@ -228,6 +228,8 @@
   if (is_fuchsia) {
     if (using_fuchsia_gn_sdk) {
       extra_deps += [
+        "//build/fuchsia/config/clang:c++-runtime-deps",
+        "$fuchsia_sdk_root/build/config:runtime_library_group",
         "$fuchsia_sdk_root/pkg/fdio",
         "$fuchsia_sdk_root/pkg/trace-engine",
       ]
diff --git a/runtime/bin/BUILD.gn b/runtime/bin/BUILD.gn
index 7431b64..609fa42 100644
--- a/runtime/bin/BUILD.gn
+++ b/runtime/bin/BUILD.gn
@@ -551,7 +551,7 @@
   ]
   args = [
     "--enable-experiment=non-nullable",
-    "--null-safety",
+    "--sound-null-safety",
     "--deterministic",
     "--snapshot_kind=" + dart_core_snapshot_kind,
     "--vm_snapshot_data=" + rebase_path(vm_snapshot_data, root_build_dir),
@@ -878,6 +878,8 @@
   }
   extra_sources = [
     "builtin.cc",
+    "dartdev_isolate.cc",
+    "dartdev_isolate.h",
     "dfe.cc",
     "dfe.h",
     "gzip.cc",
@@ -1056,7 +1058,8 @@
               "snapshot_utils.h",
               "vmservice_impl.cc",
               "vmservice_impl.h",
-            ] + builtin_impl_tests + vm_tests + compiler_tests + heap_tests
+            ] + builtin_impl_tests + vm_tests + compiler_tests + heap_tests +
+            io_impl_tests
 
   if (!is_win) {
     # Adds all symbols to the dynamic symbol table, not just used ones.
diff --git a/runtime/bin/builtin_impl_sources.gni b/runtime/bin/builtin_impl_sources.gni
index fe0251f..90790d3 100644
--- a/runtime/bin/builtin_impl_sources.gni
+++ b/runtime/bin/builtin_impl_sources.gni
@@ -15,8 +15,6 @@
   "crypto_linux.cc",
   "crypto_macos.cc",
   "crypto_win.cc",
-  "dartdev_utils.cc",
-  "dartdev_utils.h",
   "dartutils.cc",
   "dartutils.h",
   "directory.cc",
diff --git a/runtime/bin/dartdev_isolate.cc b/runtime/bin/dartdev_isolate.cc
new file mode 100644
index 0000000..f87dc6f
--- /dev/null
+++ b/runtime/bin/dartdev_isolate.cc
@@ -0,0 +1,262 @@
+// 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.
+
+#include "bin/dartdev_isolate.h"
+
+#if !defined(DART_PRECOMPILED_RUNTIME)
+
+#include <functional>
+#include <memory>
+
+#include "bin/directory.h"
+#include "bin/error_exit.h"
+#include "bin/exe_utils.h"
+#include "bin/file.h"
+#include "bin/lockers.h"
+#include "bin/platform.h"
+#include "bin/process.h"
+#include "include/dart_embedder_api.h"
+#include "platform/utils.h"
+
+#define CHECK_RESULT(result)                                                   \
+  if (Dart_IsError(result)) {                                                  \
+    ProcessError(Dart_GetError(result), kErrorExitCode);                       \
+    if (send_port_id != ILLEGAL_PORT) {                                        \
+      Dart_CloseNativePort(send_port_id);                                      \
+    }                                                                          \
+    Dart_ExitScope();                                                          \
+    Dart_ExitIsolate();                                                        \
+    return;                                                                    \
+  }
+
+namespace dart {
+namespace bin {
+
+DartDevIsolate::DartDevRunner DartDevIsolate::runner_ =
+    DartDevIsolate::DartDevRunner();
+bool DartDevIsolate::should_run_dart_dev_ = false;
+Monitor* DartDevIsolate::DartDevRunner::monitor_ = new Monitor();
+DartDevIsolate::DartDev_Result DartDevIsolate::DartDevRunner::result_ =
+    DartDevIsolate::DartDev_Result_Unknown;
+char** DartDevIsolate::DartDevRunner::script_ = nullptr;
+std::unique_ptr<char*[], void (*)(char*[])>
+    DartDevIsolate::DartDevRunner::argv_ =
+        std::unique_ptr<char*[], void (*)(char**)>(nullptr, [](char**) {});
+intptr_t DartDevIsolate::DartDevRunner::argc_ = 0;
+
+bool DartDevIsolate::ShouldParseCommand(const char* script_uri) {
+  // If script_uri is not a file path or of a known URI scheme, we can assume
+  // that this is a DartDev command.
+  return (!File::ExistsUri(nullptr, script_uri) &&
+          (strncmp(script_uri, "http://", 7) != 0) &&
+          (strncmp(script_uri, "https://", 8) != 0) &&
+          (strncmp(script_uri, "file://", 7) != 0) &&
+          (strncmp(script_uri, "package:", 8) != 0) &&
+          (strncmp(script_uri, "google3://", 10) != 0));
+}
+
+const char* DartDevIsolate::TryResolveDartDevSnapshotPath() {
+  // |dir_prefix| includes the last path seperator.
+  auto dir_prefix = EXEUtils::GetDirectoryPrefixFromExeName();
+
+  // First assume we're in dart-sdk/bin.
+  char* snapshot_path =
+      Utils::SCreate("%ssnapshots/dartdev.dart.snapshot", dir_prefix.get());
+  if (File::Exists(nullptr, snapshot_path)) {
+    return snapshot_path;
+  }
+  free(snapshot_path);
+
+  // If we're not in dart-sdk/bin, we might be in one of the $SDK/out/*
+  // directories. Try to use a snapshot rom a previously built SDK.
+  snapshot_path = Utils::SCreate("%sdartdev.dart.snapshot", dir_prefix.get());
+  if (File::Exists(nullptr, snapshot_path)) {
+    return snapshot_path;
+  }
+  free(snapshot_path);
+
+  Syslog::PrintErr("Could not find DartDev snapshot.\n");
+  return nullptr;
+}
+
+void DartDevIsolate::DartDevRunner::Run(
+    Dart_IsolateGroupCreateCallback create_isolate,
+    const char* packages_file,
+    char** script,
+    CommandLineOptions* dart_options) {
+  create_isolate_ = create_isolate;
+  dart_options_ = dart_options;
+  packages_file_ = packages_file;
+  script_ = script;
+
+  MonitorLocker locker(monitor_);
+  int result = Thread::Start("DartDev Runner", RunCallback,
+                             reinterpret_cast<uword>(this));
+  if (result != 0) {
+    FATAL1("Failed to start DartDev thread: %d", result);
+  }
+  monitor_->WaitMicros(Monitor::kNoTimeout);
+
+  if (result_ == DartDevIsolate::DartDev_Result_Run) {
+    // Clear the DartDev dart_options and replace them with the processed
+    // options provided by DartDev.
+    dart_options_->Reset();
+    for (intptr_t i = 0; i < argc_; ++i) {
+      dart_options_->AddArguments(const_cast<const char**>(argv_.get()), argc_);
+    }
+  }
+}
+
+static Dart_CObject* GetArrayItem(Dart_CObject* message, intptr_t index) {
+  return message->value.as_array.values[index];
+}
+
+void DartDevIsolate::DartDevRunner::DartDevResultCallback(
+    Dart_Port dest_port_id,
+    Dart_CObject* message) {
+  ASSERT(message->type == Dart_CObject_kArray);
+  int32_t type = GetArrayItem(message, 0)->value.as_int32;
+  switch (type) {
+    case DartDevIsolate::DartDev_Result_Run: {
+      result_ = DartDevIsolate::DartDev_Result_Run;
+      ASSERT(GetArrayItem(message, 1)->type == Dart_CObject_kString);
+      if (*script_ != nullptr) {
+        free(*script_);
+      }
+      *script_ = Utils::StrDup(GetArrayItem(message, 1)->value.as_string);
+      ASSERT(GetArrayItem(message, 2)->type == Dart_CObject_kArray);
+      Dart_CObject* args = GetArrayItem(message, 2);
+      argc_ = args->value.as_array.length;
+      Dart_CObject** dart_args = args->value.as_array.values;
+
+      auto deleter = [](char** args) {
+        for (intptr_t i = 0; i < argc_; ++i) {
+          free(args[i]);
+        }
+        delete[] args;
+      };
+
+      argv_ =
+          std::unique_ptr<char*[], void (*)(char**)>(new char*[argc_], deleter);
+      for (intptr_t i = 0; i < argc_; ++i) {
+        argv_[i] = Utils::StrDup(dart_args[i]->value.as_string);
+      }
+      break;
+    }
+    case DartDevIsolate::DartDev_Result_Exit: {
+      ASSERT(GetArrayItem(message, 1)->type == Dart_CObject_kInt32);
+      int32_t dartdev_exit_code = GetArrayItem(message, 1)->value.as_int32;
+
+      // If we're given a non-zero exit code, DartDev is signaling for us to
+      // shutdown.
+      if (dartdev_exit_code != 0) {
+        Process::SetGlobalExitCode(dartdev_exit_code);
+      }
+
+      // If DartDev hasn't signaled for us to do anything else, we can assume
+      // there's nothing else for the VM to run and that we can exit.
+      if (result_ == DartDevIsolate::DartDev_Result_Unknown) {
+        result_ = DartDevIsolate::DartDev_Result_Exit;
+      }
+
+      // DartDev is done processing the command. Unblock the main thread and
+      // continue the launch procedure.
+      DartDevRunner::monitor_->Notify();
+      break;
+    }
+    default:
+      UNREACHABLE();
+  }
+}
+
+void DartDevIsolate::DartDevRunner::RunCallback(uword args) {
+  MonitorLocker locker_(DartDevRunner::monitor_);
+  DartDevRunner* runner = reinterpret_cast<DartDevRunner*>(args);
+  const char* dartdev_path = DartDevIsolate::TryResolveDartDevSnapshotPath();
+  if (dartdev_path == nullptr) {
+    ProcessError("Failed to find DartDev snapshot.", kErrorExitCode);
+    return;
+  }
+  Dart_IsolateFlags flags;
+  Dart_IsolateFlagsInitialize(&flags);
+  char* error;
+  Dart_Isolate dartdev_isolate = runner->create_isolate_(
+      dartdev_path, "dartdev", nullptr, runner->packages_file_, &flags,
+      NULL /* callback_data */, const_cast<char**>(&error));
+  free(const_cast<char*>(dartdev_path));
+
+  if (dartdev_isolate == nullptr) {
+    ProcessError(error, kErrorExitCode);
+    return;
+  }
+
+  Dart_EnterIsolate(dartdev_isolate);
+  Dart_EnterScope();
+
+  // Retrieve the DartDev entrypoint.
+  Dart_Port send_port_id = ILLEGAL_PORT;
+  Dart_Handle root_lib = Dart_RootLibrary();
+  Dart_Handle main_closure =
+      Dart_GetField(root_lib, Dart_NewStringFromCString("main"));
+  CHECK_RESULT(main_closure);
+
+  if (!Dart_IsClosure(main_closure)) {
+    ProcessError("Unable to find 'main' in root library 'dartdev'",
+                 kErrorExitCode);
+    Dart_ExitScope();
+    Dart_ExitIsolate();
+    return;
+  }
+
+  // Create a SendPort that DartDev can use to communicate its results over.
+  send_port_id = Dart_NewNativePort("dartdev", DartDevResultCallback, false);
+  ASSERT(send_port_id != ILLEGAL_PORT);
+  Dart_Handle send_port = Dart_NewSendPort(send_port_id);
+  CHECK_RESULT(send_port);
+
+  const intptr_t kNumIsolateArgs = 7;
+  Dart_Handle isolate_args[kNumIsolateArgs];
+  isolate_args[0] = Dart_Null();   // parentPort
+  isolate_args[1] = main_closure;  // entryPoint
+  isolate_args[2] = runner->dart_options_->CreateRuntimeOptions();  // args
+  isolate_args[3] = send_port;                                      // message
+  isolate_args[4] = Dart_True();  // isSpawnUri
+  isolate_args[5] = Dart_Null();  // controlPort
+  isolate_args[6] = Dart_Null();  // capabilities
+
+  Dart_Handle isolate_lib =
+      Dart_LookupLibrary(Dart_NewStringFromCString("dart:isolate"));
+  Dart_Handle result =
+      Dart_Invoke(isolate_lib, Dart_NewStringFromCString("_startIsolate"),
+                  kNumIsolateArgs, isolate_args);
+  CHECK_RESULT(result);
+  CHECK_RESULT(Dart_RunLoop());
+
+  Dart_CloseNativePort(send_port_id);
+
+  Dart_ExitScope();
+  Dart_ShutdownIsolate();
+}
+
+void DartDevIsolate::DartDevRunner::ProcessError(const char* msg,
+                                                 int32_t exit_code) {
+  Syslog::PrintErr("%s\n", msg);
+  Process::SetGlobalExitCode(exit_code);
+  result_ = DartDevIsolate::DartDev_Result_Exit;
+  DartDevRunner::monitor_->Notify();
+}
+
+DartDevIsolate::DartDev_Result DartDevIsolate::RunDartDev(
+    Dart_IsolateGroupCreateCallback create_isolate,
+    const char* packages_file,
+    char** script,
+    CommandLineOptions* dart_options) {
+  runner_.Run(create_isolate, packages_file, script, dart_options);
+  return runner_.result();
+}
+
+#endif  // if !defined(DART_PRECOMPILED_RUNTIME)
+
+}  // namespace bin
+}  // namespace dart
diff --git a/runtime/bin/dartdev_isolate.h b/runtime/bin/dartdev_isolate.h
new file mode 100644
index 0000000..e2ade66
--- /dev/null
+++ b/runtime/bin/dartdev_isolate.h
@@ -0,0 +1,99 @@
+// 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.
+
+#ifndef RUNTIME_BIN_DARTDEV_ISOLATE_H_
+#define RUNTIME_BIN_DARTDEV_ISOLATE_H_
+
+#if !defined(DART_PRECOMPILED_RUNTIME)
+
+#include <memory>
+
+#include "bin/thread.h"
+#include "include/dart_api.h"
+#include "include/dart_native_api.h"
+#include "platform/globals.h"
+
+namespace dart {
+namespace bin {
+
+class CommandLineOptions;
+
+class DartDevIsolate {
+ public:
+  // Note: keep in sync with pkg/dartdev/lib/vm_interop_handler.dart
+  typedef enum {
+    DartDev_Result_Unknown = -1,
+    DartDev_Result_Run = 1,
+    DartDev_Result_Exit = 2,
+  } DartDev_Result;
+
+  // Returns true if there does not exist a file at |script_uri| or the URI is
+  // not an HTTP resource.
+  static bool ShouldParseCommand(const char* script_uri);
+
+  static void set_should_run_dart_dev(bool enable) {
+    should_run_dart_dev_ = enable;
+  }
+
+  static bool should_run_dart_dev() { return should_run_dart_dev_; }
+
+  // Starts a DartDev instance in a new isolate and runs it to completion.
+  //
+  // Returns true if the VM should run the result in `script`, in which case
+  // `script` and `dart_options` will have been repopulated with the correct
+  // values.
+  static DartDev_Result RunDartDev(
+      Dart_IsolateGroupCreateCallback create_isolate,
+      const char* packages_file,
+      char** script,
+      CommandLineOptions* dart_options);
+
+ protected:
+  class DartDevRunner {
+   public:
+    DartDevRunner() {}
+
+    void Run(Dart_IsolateGroupCreateCallback create_isolate,
+             const char* packages_file,
+             char** script,
+             CommandLineOptions* dart_options);
+
+    DartDev_Result result() const { return result_; }
+
+   private:
+    static void DartDevResultCallback(Dart_Port dest_port_id,
+                                      Dart_CObject* message);
+    static void RunCallback(uword arg);
+    static void ProcessError(const char* msg, int32_t exit_code);
+
+    static DartDev_Result result_;
+    static char** script_;
+    static std::unique_ptr<char*[], void (*)(char**)> argv_;
+    static intptr_t argc_;
+
+    Dart_IsolateGroupCreateCallback create_isolate_;
+    CommandLineOptions* dart_options_;
+    const char* packages_file_;
+    static Monitor* monitor_;
+
+    DISALLOW_ALLOCATION();
+  };
+
+ private:
+  // Attempts to find the DartDev snapshot. If the snapshot cannot be found,
+  // the VM will shutdown.
+  static const char* TryResolveDartDevSnapshotPath();
+
+  static DartDevRunner runner_;
+  static bool should_run_dart_dev_;
+
+  DISALLOW_ALLOCATION();
+  DISALLOW_IMPLICIT_CONSTRUCTORS(DartDevIsolate);
+};
+
+}  // namespace bin
+}  // namespace dart
+
+#endif  // !defined(DART_PRECOMPILED_RUNTIME)
+#endif  // RUNTIME_BIN_DARTDEV_ISOLATE_H_
diff --git a/runtime/bin/dartdev_utils.cc b/runtime/bin/dartdev_utils.cc
deleted file mode 100644
index 3f14bc4..0000000
--- a/runtime/bin/dartdev_utils.cc
+++ /dev/null
@@ -1,53 +0,0 @@
-// 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.
-
-#include "bin/dartdev_utils.h"
-
-#include <memory>
-
-#include "bin/directory.h"
-#include "bin/exe_utils.h"
-#include "bin/file.h"
-#include "platform/utils.h"
-
-namespace dart {
-namespace bin {
-
-bool DartDevUtils::ShouldParseCommand(const char* script_uri) {
-  // If script_uri is not a file path or of a known URI scheme, we can assume
-  // that this is a DartDev command.
-  return (!File::ExistsUri(nullptr, script_uri) &&
-          (strncmp(script_uri, "http://", 7) != 0) &&
-          (strncmp(script_uri, "https://", 8) != 0) &&
-          (strncmp(script_uri, "file://", 7) != 0) &&
-          (strncmp(script_uri, "package:", 8) != 0) &&
-          (strncmp(script_uri, "google3://", 10) != 0));
-}
-
-bool DartDevUtils::TryResolveDartDevSnapshotPath(char** script_name) {
-  // |dir_prefix| includes the last path seperator.
-  auto dir_prefix = EXEUtils::GetDirectoryPrefixFromExeName();
-
-  // First assume we're in dart-sdk/bin.
-  char* snapshot_path =
-      Utils::SCreate("%ssnapshots/dartdev.dart.snapshot", dir_prefix.get());
-  if (File::Exists(nullptr, snapshot_path)) {
-    *script_name = snapshot_path;
-    return true;
-  }
-  free(snapshot_path);
-
-  // If we're not in dart-sdk/bin, we might be in one of the $SDK/out/*
-  // directories. Try to use a snapshot from a previously built SDK.
-  snapshot_path = Utils::SCreate("%sdartdev.dart.snapshot", dir_prefix.get());
-  if (File::Exists(nullptr, snapshot_path)) {
-    *script_name = snapshot_path;
-    return true;
-  }
-  free(snapshot_path);
-  return false;
-}
-
-}  // namespace bin
-}  // namespace dart
diff --git a/runtime/bin/dartdev_utils.h b/runtime/bin/dartdev_utils.h
deleted file mode 100644
index e388d1e..0000000
--- a/runtime/bin/dartdev_utils.h
+++ /dev/null
@@ -1,32 +0,0 @@
-// 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.
-
-#ifndef RUNTIME_BIN_DARTDEV_UTILS_H_
-#define RUNTIME_BIN_DARTDEV_UTILS_H_
-
-#include "platform/globals.h"
-
-namespace dart {
-namespace bin {
-
-class DartDevUtils {
- public:
-  // Returns true if there does not exist a file at |script_uri| or the URI is
-  // not an HTTP resource.
-  static bool ShouldParseCommand(const char* script_uri);
-
-  // Returns true if we were successfully able to find the DartDev snapshot.
-  // Returns false if we were unable to find the snapshot, in which case the
-  // VM should exit.
-  static bool TryResolveDartDevSnapshotPath(char** script_name);
-
- private:
-  DISALLOW_ALLOCATION();
-  DISALLOW_IMPLICIT_CONSTRUCTORS(DartDevUtils);
-};
-
-}  // namespace bin
-}  // namespace dart
-
-#endif  // RUNTIME_BIN_DARTDEV_UTILS_H_
diff --git a/runtime/bin/dartutils.cc b/runtime/bin/dartutils.cc
index 972a07b..a47775c 100644
--- a/runtime/bin/dartutils.cc
+++ b/runtime/bin/dartutils.cc
@@ -12,11 +12,9 @@
 #include "bin/namespace.h"
 #include "bin/platform.h"
 #include "bin/utils.h"
-
 #include "include/dart_api.h"
 #include "include/dart_native_api.h"
 #include "include/dart_tools_api.h"
-
 #include "platform/assert.h"
 #include "platform/globals.h"
 #include "platform/memory_sanitizer.h"
@@ -68,6 +66,29 @@
 #endif  // defined(HOST_OS_WINDOWS)
 }
 
+Dart_Handle CommandLineOptions::CreateRuntimeOptions() {
+  Dart_Handle string_type = DartUtils::GetDartType("dart:core", "String");
+  if (Dart_IsError(string_type)) {
+    return string_type;
+  }
+  Dart_Handle dart_arguments =
+      Dart_NewListOfTypeFilled(string_type, Dart_EmptyString(), count_);
+  if (Dart_IsError(dart_arguments)) {
+    return dart_arguments;
+  }
+  for (int i = 0; i < count_; i++) {
+    Dart_Handle argument_value = DartUtils::NewString(GetArgument(i));
+    if (Dart_IsError(argument_value)) {
+      return argument_value;
+    }
+    Dart_Handle result = Dart_ListSetAt(dart_arguments, i, argument_value);
+    if (Dart_IsError(result)) {
+      return result;
+    }
+  }
+  return dart_arguments;
+}
+
 int64_t DartUtils::GetIntegerValue(Dart_Handle value_obj) {
   int64_t value = 0;
   Dart_Handle result = Dart_IntegerToInt64(value_obj, &value);
diff --git a/runtime/bin/dartutils.h b/runtime/bin/dartutils.h
index 23122ad..65ed5ae 100644
--- a/runtime/bin/dartutils.h
+++ b/runtime/bin/dartutils.h
@@ -55,6 +55,8 @@
     arguments_ = NULL;
   }
 
+  void Reset() { count_ = 0; }
+
   int count() const { return count_; }
   int max_count() const { return max_count_; }
   const char** arguments() const { return arguments_; }
@@ -80,6 +82,8 @@
     }
   }
 
+  Dart_Handle CreateRuntimeOptions();
+
   void operator delete(void* pointer) { abort(); }
 
  private:
diff --git a/runtime/bin/elf_loader.cc b/runtime/bin/elf_loader.cc
index b3981bd..c67f391 100644
--- a/runtime/bin/elf_loader.cc
+++ b/runtime/bin/elf_loader.cc
@@ -527,10 +527,6 @@
     }
   }
 
-  CHECK_ERROR(vm_data == nullptr || *vm_data != nullptr,
-              "Could not find VM snapshot data.");
-  CHECK_ERROR(vm_instrs == nullptr || *vm_instrs != nullptr,
-              "Could not find VM snapshot instructions.");
   CHECK_ERROR(isolate_data == nullptr || *isolate_data != nullptr,
               "Could not find isolate snapshot data.");
   CHECK_ERROR(isolate_instrs == nullptr || *isolate_instrs != nullptr,
diff --git a/runtime/bin/file_win.cc b/runtime/bin/file_win.cc
index 58a9542..8023814 100644
--- a/runtime/bin/file_win.cc
+++ b/runtime/bin/file_win.cc
@@ -18,6 +18,7 @@
 #include <sys/utime.h>  // NOLINT
 
 #include "bin/builtin.h"
+#include "bin/crypto.h"
 #include "bin/directory.h"
 #include "bin/namespace.h"
 #include "bin/utils.h"
@@ -517,6 +518,100 @@
   return (move_status != 0);
 }
 
+static wchar_t* CopyToDartScopeString(wchar_t* string) {
+  wchar_t* wide_path = reinterpret_cast<wchar_t*>(
+      Dart_ScopeAllocate(MAX_PATH * sizeof(wchar_t) + 1));
+  wcscpy(wide_path, string);
+  return wide_path;
+}
+
+static wchar_t* CopyIntoTempFile(const char* src, const char* dest) {
+  // This function will copy the file to a temp file in the destination
+  // directory and return the path of temp file.
+  // Creating temp file name has the same logic as Directory::CreateTemp(),
+  // which tries with the rng and falls back to a uuid if it failed.
+  const char* last_back_slash = strrchr(dest, '\\');
+  // It is possible the path uses forwardslash as path separator.
+  const char* last_forward_slash = strrchr(dest, '/');
+  const char* last_path_separator = NULL;
+  if (last_back_slash == NULL && last_forward_slash == NULL) {
+    return NULL;
+  } else if (last_forward_slash != NULL && last_forward_slash != NULL) {
+    // If both types occur in the path, use the one closer to the end.
+    if (last_back_slash - dest > last_forward_slash - dest) {
+      last_path_separator = last_back_slash;
+    } else {
+      last_path_separator = last_forward_slash;
+    }
+  } else {
+    last_path_separator =
+        (last_forward_slash == NULL) ? last_back_slash : last_forward_slash;
+  }
+  int length_of_parent_dir = last_path_separator - dest + 1;
+  if (length_of_parent_dir + 8 > MAX_PATH) {
+    return NULL;
+  }
+  uint32_t suffix_bytes = 0;
+  const int kSuffixSize = sizeof(suffix_bytes);
+  if (Crypto::GetRandomBytes(kSuffixSize,
+                             reinterpret_cast<uint8_t*>(&suffix_bytes))) {
+    PathBuffer buffer;
+    char* dir = reinterpret_cast<char*>(
+        Dart_ScopeAllocate(1 + sizeof(char) * length_of_parent_dir));
+    memmove(dir, dest, length_of_parent_dir);
+    dir[length_of_parent_dir] = '\0';
+    if (!buffer.Add(dir)) {
+      return NULL;
+    }
+
+    char suffix[8 + 1];
+    Utils::SNPrint(suffix, sizeof(suffix), "%x", suffix_bytes);
+    Utf8ToWideScope source_path(src);
+    if (!buffer.Add(suffix)) {
+      return NULL;
+    }
+    if (CopyFileExW(source_path.wide(), buffer.AsStringW(), NULL, NULL, NULL,
+                    0) != 0) {
+      return CopyToDartScopeString(buffer.AsStringW());
+    }
+    // If CopyFileExW() fails to copy to a temp file with random hex, fall
+    // back to copy to a uuid temp file.
+  }
+  // UUID has a total of 36 characters in the form of
+  // xxxxxxxx-xxxx-Mxxx-Nxxx-xxxxxxxxxxxx.
+  if (length_of_parent_dir + 36 > MAX_PATH) {
+    return NULL;
+  }
+  UUID uuid;
+  RPC_STATUS status = UuidCreateSequential(&uuid);
+  if ((status != RPC_S_OK) && (status != RPC_S_UUID_LOCAL_ONLY)) {
+    return NULL;
+  }
+  RPC_WSTR uuid_string;
+  status = UuidToStringW(&uuid, &uuid_string);
+  if (status != RPC_S_OK) {
+    return NULL;
+  }
+  PathBuffer buffer;
+  char* dir = reinterpret_cast<char*>(
+      Dart_ScopeAllocate(1 + sizeof(char) * length_of_parent_dir));
+  memmove(dir, dest, length_of_parent_dir);
+  dir[length_of_parent_dir] = '\0';
+  Utf8ToWideScope dest_path(dir);
+  if (!buffer.AddW(dest_path.wide()) ||
+      !buffer.AddW(reinterpret_cast<wchar_t*>(uuid_string))) {
+    return NULL;
+  }
+
+  RpcStringFreeW(&uuid_string);
+  Utf8ToWideScope source_path(src);
+  if (CopyFileExW(source_path.wide(), buffer.AsStringW(), NULL, NULL, NULL,
+                  0) != 0) {
+    return CopyToDartScopeString(buffer.AsStringW());
+  }
+  return NULL;
+}
+
 bool File::Copy(Namespace* namespc,
                 const char* old_path,
                 const char* new_path) {
@@ -525,11 +620,29 @@
     SetLastError(ERROR_FILE_NOT_FOUND);
     return false;
   }
-  Utf8ToWideScope system_old_path(old_path);
-  Utf8ToWideScope system_new_path(new_path);
-  bool success = CopyFileExW(system_old_path.wide(), system_new_path.wide(),
-                             NULL, NULL, NULL, 0) != 0;
-  return success;
+
+  wchar_t* temp_file = CopyIntoTempFile(old_path, new_path);
+  if (temp_file == NULL) {
+    // If temp file creation fails, fall back on doing a direct copy.
+    Utf8ToWideScope system_old_path(old_path);
+    Utf8ToWideScope system_new_path(new_path);
+    return CopyFileExW(system_old_path.wide(), system_new_path.wide(), NULL,
+                       NULL, NULL, 0) != 0;
+  }
+  Utf8ToWideScope system_new_dest(new_path);
+
+  // Remove the existing file. Otherwise, renaming will fail.
+  if (Exists(namespc, new_path)) {
+    DeleteFileW(system_new_dest.wide());
+  }
+
+  if (!MoveFileW(temp_file, system_new_dest.wide())) {
+    DWORD error = GetLastError();
+    DeleteFileW(temp_file);
+    SetLastError(error);
+    return false;
+  }
+  return true;
 }
 
 int64_t File::LengthFromPath(Namespace* namespc, const char* name) {
diff --git a/runtime/bin/gen_snapshot.cc b/runtime/bin/gen_snapshot.cc
index f49defc..2cf7ab9 100644
--- a/runtime/bin/gen_snapshot.cc
+++ b/runtime/bin/gen_snapshot.cc
@@ -24,7 +24,6 @@
 #include "bin/thread.h"
 #include "bin/utils.h"
 #include "bin/vmservice_impl.h"
-#include "platform/syslog.h"
 
 #include "include/dart_api.h"
 #include "include/dart_tools_api.h"
@@ -32,6 +31,8 @@
 #include "platform/globals.h"
 #include "platform/growable_array.h"
 #include "platform/hashmap.h"
+#include "platform/syslog.h"
+#include "platform/text_buffer.h"
 
 namespace dart {
 namespace bin {
@@ -114,6 +115,7 @@
   V(blobs_container_filename, blobs_container_filename)                        \
   V(assembly, assembly_filename)                                               \
   V(elf, elf_filename)                                                         \
+  V(loading_unit_manifest, loading_unit_manifest_filename)                     \
   V(load_compilation_trace, load_compilation_trace_filename)                   \
   V(load_type_feedback, load_type_feedback_filename)                           \
   V(save_debugging_info, debugging_info_filename)                              \
@@ -286,7 +288,7 @@
     case kAppAOTElf: {
       if (elf_filename == NULL) {
         Syslog::PrintErr(
-            "Building an AOT snapshot as assembly requires specifying "
+            "Building an AOT snapshot as ELF requires specifying "
             "an output file for --elf.\n\n");
         return -1;
       }
@@ -335,13 +337,21 @@
   return 0;
 }
 
+PRINTF_ATTRIBUTE(1, 2) static void PrintErrAndExit(const char* format, ...) {
+  va_list args;
+  va_start(args, format);
+  Syslog::VPrintErr(format, args);
+  va_end(args);
+
+  Dart_ExitScope();
+  Dart_ShutdownIsolate();
+  exit(kErrorExitCode);
+}
+
 static File* OpenFile(const char* filename) {
   File* file = File::Open(NULL, filename, File::kWriteTruncate);
   if (file == NULL) {
-    Syslog::PrintErr("Error: Unable to write file: %s\n\n", filename);
-    Dart_ExitScope();
-    Dart_ShutdownIsolate();
-    exit(kErrorExitCode);
+    PrintErrAndExit("Error: Unable to write file: %s\n\n", filename);
   }
   return file;
 }
@@ -352,29 +362,20 @@
   File* file = OpenFile(filename);
   RefCntReleaseScope<File> rs(file);
   if (!file->WriteFully(buffer, size)) {
-    Syslog::PrintErr("Error: Unable to write file: %s\n\n", filename);
-    Dart_ExitScope();
-    Dart_ShutdownIsolate();
-    exit(kErrorExitCode);
+    PrintErrAndExit("Error: Unable to write file: %s\n\n", filename);
   }
 }
 
 static void ReadFile(const char* filename, uint8_t** buffer, intptr_t* size) {
   File* file = File::Open(NULL, filename, File::kRead);
   if (file == NULL) {
-    Syslog::PrintErr("Unable to open file %s\n", filename);
-    Dart_ExitScope();
-    Dart_ShutdownIsolate();
-    exit(kErrorExitCode);
+    PrintErrAndExit("Error: Unable to read file: %s\n", filename);
   }
   RefCntReleaseScope<File> rs(file);
   *size = file->Length();
   *buffer = reinterpret_cast<uint8_t*>(malloc(*size));
   if (!file->ReadFully(*buffer, *size)) {
-    Syslog::PrintErr("Unable to read file %s\n", filename);
-    Dart_ExitScope();
-    Dart_ShutdownIsolate();
-    exit(kErrorExitCode);
+    PrintErrAndExit("Error: Unable to read file: %s\n", filename);
   }
 }
 
@@ -579,13 +580,94 @@
                                    intptr_t size) {
   File* file = reinterpret_cast<File*>(callback_data);
   if ((file != nullptr) && !file->WriteFully(buffer, size)) {
-    Syslog::PrintErr("Error: Unable to write snapshot file\n\n");
-    Dart_ExitScope();
-    Dart_ShutdownIsolate();
-    exit(kErrorExitCode);
+    PrintErrAndExit("Error: Unable to write snapshot file\n\n");
   }
 }
 
+static void StreamingCloseCallback(void* callback_data) {
+  File* file = reinterpret_cast<File*>(callback_data);
+  file->Release();
+}
+
+static File* OpenLoadingUnitManifest() {
+  File* manifest_file = OpenFile(loading_unit_manifest_filename);
+  if (!manifest_file->Print("{ \"loadingUnits\": [\n")) {
+    PrintErrAndExit("Error: Unable to write file: %s\n\n",
+                    loading_unit_manifest_filename);
+  }
+  return manifest_file;
+}
+
+static void WriteLoadingUnitManifest(File* manifest_file,
+                                     intptr_t id,
+                                     const char* path) {
+  TextBuffer line(128);
+  if (id != 1) {
+    line.Printf(",");
+  }
+  line.Printf("{ \"id\": %" Pd ", \"path\": \"", id);
+  line.AddEscapedString(path);
+  line.Printf("\" }");
+  if (!manifest_file->Print("%s\n", line.buf())) {
+    PrintErrAndExit("Error: Unable to write file: %s\n\n",
+                    loading_unit_manifest_filename);
+  }
+}
+
+static void CloseLoadingUnitManifest(File* manifest_file) {
+  if (!manifest_file->Print("] }\n")) {
+    PrintErrAndExit("Error: Unable to write file: %s\n\n",
+                    loading_unit_manifest_filename);
+  }
+  manifest_file->Release();
+}
+
+static void NextLoadingUnit(void* callback_data,
+                            intptr_t loading_unit_id,
+                            void** write_callback_data,
+                            void** write_debug_callback_data,
+                            const char* main_filename,
+                            const char* suffix) {
+  char* filename = loading_unit_id == 1
+                       ? strdup(main_filename)
+                       : Utils::SCreate("%s-%" Pd ".part.%s", main_filename,
+                                        loading_unit_id, suffix);
+  File* file = OpenFile(filename);
+  *write_callback_data = file;
+
+  if (debugging_info_filename != nullptr) {
+    char* debug_filename =
+        loading_unit_id == 1
+            ? strdup(debugging_info_filename)
+            : Utils::SCreate("%s-%" Pd ".part.so", debugging_info_filename,
+                             loading_unit_id);
+    File* debug_file = OpenFile(debug_filename);
+    *write_debug_callback_data = debug_file;
+    free(debug_filename);
+  }
+
+  WriteLoadingUnitManifest(reinterpret_cast<File*>(callback_data),
+                           loading_unit_id, filename);
+
+  free(filename);
+}
+
+static void NextAsmCallback(void* callback_data,
+                            intptr_t loading_unit_id,
+                            void** write_callback_data,
+                            void** write_debug_callback_data) {
+  NextLoadingUnit(callback_data, loading_unit_id, write_callback_data,
+                  write_debug_callback_data, assembly_filename, "S");
+}
+
+static void NextElfCallback(void* callback_data,
+                            intptr_t loading_unit_id,
+                            void** write_callback_data,
+                            void** write_debug_callback_data) {
+  NextLoadingUnit(callback_data, loading_unit_id, write_callback_data,
+                  write_debug_callback_data, elf_filename, "so");
+}
+
 static void CreateAndWritePrecompiledSnapshot() {
   ASSERT(IsSnapshottingForPrecompilation());
   Dart_Handle result;
@@ -596,20 +678,30 @@
 
   // Create a precompiled snapshot.
   if (snapshot_kind == kAppAOTAssembly) {
-    File* file = OpenFile(assembly_filename);
-    RefCntReleaseScope<File> rs(file);
-    File* debug_file = nullptr;
-    if (debugging_info_filename != nullptr) {
-      debug_file = OpenFile(debugging_info_filename);
-    } else if (strip) {
+    if (strip && (debugging_info_filename == nullptr)) {
       Syslog::PrintErr(
           "Warning: Generating assembly code without DWARF debugging"
           " information.\n");
     }
-    result = Dart_CreateAppAOTSnapshotAsAssembly(StreamingWriteCallback, file,
-                                                 strip, debug_file);
-    if (debug_file != nullptr) debug_file->Release();
-    CHECK_RESULT(result);
+    if (loading_unit_manifest_filename == nullptr) {
+      File* file = OpenFile(assembly_filename);
+      RefCntReleaseScope<File> rs(file);
+      File* debug_file = nullptr;
+      if (debugging_info_filename != nullptr) {
+        debug_file = OpenFile(debugging_info_filename);
+      }
+      result = Dart_CreateAppAOTSnapshotAsAssembly(StreamingWriteCallback, file,
+                                                   strip, debug_file);
+      if (debug_file != nullptr) debug_file->Release();
+      CHECK_RESULT(result);
+    } else {
+      File* manifest_file = OpenLoadingUnitManifest();
+      result = Dart_CreateAppAOTSnapshotAsAssemblies(
+          NextAsmCallback, manifest_file, strip, StreamingWriteCallback,
+          StreamingCloseCallback);
+      CHECK_RESULT(result);
+      CloseLoadingUnitManifest(manifest_file);
+    }
     if (obfuscate && !strip) {
       Syslog::PrintErr(
           "Warning: The generated assembly code contains unobfuscated DWARF "
@@ -617,20 +709,30 @@
           "         To avoid this, use --strip to remove it.\n");
     }
   } else if (snapshot_kind == kAppAOTElf) {
-    File* file = OpenFile(elf_filename);
-    RefCntReleaseScope<File> rs(file);
-    File* debug_file = nullptr;
-    if (debugging_info_filename != nullptr) {
-      debug_file = OpenFile(debugging_info_filename);
-    } else if (strip) {
+    if (strip && (debugging_info_filename == nullptr)) {
       Syslog::PrintErr(
           "Warning: Generating ELF library without DWARF debugging"
           " information.\n");
     }
-    result = Dart_CreateAppAOTSnapshotAsElf(StreamingWriteCallback, file, strip,
-                                            debug_file);
-    if (debug_file != nullptr) debug_file->Release();
-    CHECK_RESULT(result);
+    if (loading_unit_manifest_filename == nullptr) {
+      File* file = OpenFile(elf_filename);
+      RefCntReleaseScope<File> rs(file);
+      File* debug_file = nullptr;
+      if (debugging_info_filename != nullptr) {
+        debug_file = OpenFile(debugging_info_filename);
+      }
+      result = Dart_CreateAppAOTSnapshotAsElf(StreamingWriteCallback, file,
+                                              strip, debug_file);
+      if (debug_file != nullptr) debug_file->Release();
+      CHECK_RESULT(result);
+    } else {
+      File* manifest_file = OpenLoadingUnitManifest();
+      result = Dart_CreateAppAOTSnapshotAsElfs(NextElfCallback, manifest_file,
+                                               strip, StreamingWriteCallback,
+                                               StreamingCloseCallback);
+      CHECK_RESULT(result);
+      CloseLoadingUnitManifest(manifest_file);
+    }
     if (obfuscate && !strip) {
       Syslog::PrintErr(
           "Warning: The generated ELF library contains unobfuscated DWARF "
diff --git a/runtime/bin/io_impl_sources.gni b/runtime/bin/io_impl_sources.gni
index 84a93ad..846c775 100644
--- a/runtime/bin/io_impl_sources.gni
+++ b/runtime/bin/io_impl_sources.gni
@@ -49,6 +49,7 @@
   "platform_fuchsia.cc",
   "platform_linux.cc",
   "platform_macos.cc",
+  "platform_macos.h",
   "platform_win.cc",
   "process.cc",
   "process.h",
@@ -107,3 +108,5 @@
   "typed_data_utils.cc",
   "typed_data_utils.h",
 ]
+
+io_impl_tests = [ "platform_macos_test.cc" ]
diff --git a/runtime/bin/isolate_data.cc b/runtime/bin/isolate_data.cc
index 1d62d32..75bf2f4 100644
--- a/runtime/bin/isolate_data.cc
+++ b/runtime/bin/isolate_data.cc
@@ -25,13 +25,16 @@
 }
 
 IsolateGroupData::~IsolateGroupData() {
+  for (intptr_t i = 0; i < loading_units_.length(); i++) {
+    delete loading_units_[i];
+  }
   free(script_url);
-  script_url = NULL;
+  script_url = nullptr;
   free(packages_file_);
-  packages_file_ = NULL;
+  packages_file_ = nullptr;
   free(resolved_packages_config_);
-  resolved_packages_config_ = NULL;
-  kernel_buffer_ = NULL;
+  resolved_packages_config_ = nullptr;
+  kernel_buffer_ = nullptr;
   kernel_buffer_size_ = 0;
 }
 
diff --git a/runtime/bin/isolate_data.h b/runtime/bin/isolate_data.h
index 6daf547..bba25d7 100644
--- a/runtime/bin/isolate_data.h
+++ b/runtime/bin/isolate_data.h
@@ -11,6 +11,7 @@
 #include "include/dart_api.h"
 #include "platform/assert.h"
 #include "platform/globals.h"
+#include "platform/growable_array.h"
 #include "platform/utils.h"
 
 namespace dart {
@@ -96,10 +97,15 @@
     return app_snapshot_ != nullptr || isolate_run_app_snapshot_;
   }
 
+  void AddLoadingUnit(AppSnapshot* loading_unit) {
+    loading_units_.Add(loading_unit);
+  }
+
  private:
   friend class IsolateData;  // For packages_file_
 
   std::unique_ptr<AppSnapshot> app_snapshot_;
+  MallocGrowableArray<AppSnapshot*> loading_units_;
   char* resolved_packages_config_;
   std::shared_ptr<uint8_t> kernel_buffer_;
   intptr_t kernel_buffer_size_;
diff --git a/runtime/bin/loader.cc b/runtime/bin/loader.cc
index 02002b3..e5c869a 100644
--- a/runtime/bin/loader.cc
+++ b/runtime/bin/loader.cc
@@ -12,6 +12,7 @@
 #include "bin/file.h"
 #include "bin/gzip.h"
 #include "bin/lockers.h"
+#include "bin/snapshot_utils.h"
 #include "bin/utils.h"
 #include "include/dart_tools_api.h"
 #include "platform/growable_array.h"
@@ -220,6 +221,44 @@
 }
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
+Dart_Handle Loader::DeferredLoadHandler(intptr_t loading_unit_id) {
+  // A synchronous implementation. An asynchronous implementation would be
+  // better, but the standalone embedder only implements AOT for testing.
+
+  auto isolate_group_data =
+      reinterpret_cast<IsolateGroupData*>(Dart_CurrentIsolateGroupData());
+  char* unit_url = Utils::SCreate(
+      "%s-%" Pd ".part.so", isolate_group_data->script_url, loading_unit_id);
+
+  AppSnapshot* loading_unit_snapshot = Snapshot::TryReadAppSnapshot(unit_url);
+  Dart_Handle result;
+  if (loading_unit_snapshot != nullptr) {
+    isolate_group_data->AddLoadingUnit(loading_unit_snapshot);
+    const uint8_t* isolate_snapshot_data = nullptr;
+    const uint8_t* isolate_snapshot_instructions = nullptr;
+    const uint8_t* ignore_vm_snapshot_data;
+    const uint8_t* ignore_vm_snapshot_instructions;
+    loading_unit_snapshot->SetBuffers(
+        &ignore_vm_snapshot_data, &ignore_vm_snapshot_instructions,
+        &isolate_snapshot_data, &isolate_snapshot_instructions);
+    result = Dart_DeferredLoadComplete(loading_unit_id, isolate_snapshot_data,
+                                       isolate_snapshot_instructions);
+    if (Dart_IsApiError(result)) {
+      result =
+          Dart_DeferredLoadCompleteError(loading_unit_id, Dart_GetError(result),
+                                         /*transient*/ false);
+    }
+  } else {
+    char* error_message = Utils::SCreate("Failed to load %s", unit_url);
+    result = Dart_DeferredLoadCompleteError(loading_unit_id, error_message,
+                                            /*transient*/ false);
+    free(error_message);
+  }
+
+  free(unit_url);
+  return result;
+}
+
 void Loader::InitOnce() {
 }
 
diff --git a/runtime/bin/loader.h b/runtime/bin/loader.h
index f4715e9..a9f436d 100644
--- a/runtime/bin/loader.h
+++ b/runtime/bin/loader.h
@@ -26,6 +26,7 @@
   static Dart_Handle LibraryTagHandler(Dart_LibraryTag tag,
                                        Dart_Handle library,
                                        Dart_Handle url);
+  static Dart_Handle DeferredLoadHandler(intptr_t loading_unit_id);
 
   static void InitOnce();
 
diff --git a/runtime/bin/main.cc b/runtime/bin/main.cc
index 25e7c2b..d4ac70f 100644
--- a/runtime/bin/main.cc
+++ b/runtime/bin/main.cc
@@ -5,16 +5,13 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <memory>
 
-#include "include/bin/dart_io_api.h"
-#include "include/dart_api.h"
-#include "include/dart_embedder_api.h"
-#include "include/dart_tools_api.h"
+#include <memory>
 
 #include "bin/builtin.h"
 #include "bin/console.h"
 #include "bin/crashpad.h"
+#include "bin/dartdev_isolate.h"
 #include "bin/dartutils.h"
 #include "bin/dfe.h"
 #include "bin/error_exit.h"
@@ -31,6 +28,10 @@
 #include "bin/thread.h"
 #include "bin/utils.h"
 #include "bin/vmservice_impl.h"
+#include "include/bin/dart_io_api.h"
+#include "include/dart_api.h"
+#include "include/dart_embedder_api.h"
+#include "include/dart_tools_api.h"
 #include "platform/globals.h"
 #include "platform/growable_array.h"
 #include "platform/hashmap.h"
@@ -74,30 +75,6 @@
 
 static void ReadFile(const char* filename, uint8_t** buffer, intptr_t* size);
 
-static Dart_Handle CreateRuntimeOptions(CommandLineOptions* options) {
-  int options_count = options->count();
-  Dart_Handle string_type = DartUtils::GetDartType("dart:core", "String");
-  if (Dart_IsError(string_type)) {
-    return string_type;
-  }
-  Dart_Handle dart_arguments =
-      Dart_NewListOfTypeFilled(string_type, Dart_EmptyString(), options_count);
-  if (Dart_IsError(dart_arguments)) {
-    return dart_arguments;
-  }
-  for (int i = 0; i < options_count; i++) {
-    Dart_Handle argument_value = DartUtils::NewString(options->GetArgument(i));
-    if (Dart_IsError(argument_value)) {
-      return argument_value;
-    }
-    Dart_Handle result = Dart_ListSetAt(dart_arguments, i, argument_value);
-    if (Dart_IsError(result)) {
-      return result;
-    }
-  }
-  return dart_arguments;
-}
-
 #define SAVE_ERROR_AND_EXIT(result)                                            \
   *error = Utils::StrDup(Dart_GetError(result));                               \
   if (Dart_IsCompilationError(result)) {                                       \
@@ -297,6 +274,8 @@
   // isolates in the group.
   Dart_Handle result = Dart_SetLibraryTagHandler(Loader::LibraryTagHandler);
   CHECK_RESULT(result);
+  result = Dart_SetDeferredLoadHandler(Loader::DeferredLoadHandler);
+  CHECK_RESULT(result);
 
   auto isolate_data = reinterpret_cast<IsolateData*>(Dart_IsolateData(isolate));
 
@@ -403,6 +382,15 @@
     CHECK_RESULT(result);
   }
 
+  // Disable pausing the DartDev isolate on start and exit.
+  const char* isolate_name = nullptr;
+  result = Dart_StringToCString(Dart_DebugName(), &isolate_name);
+  CHECK_RESULT(result);
+  if (strstr(isolate_name, "dartdev") != nullptr) {
+    Dart_SetShouldPauseOnStart(false);
+    Dart_SetShouldPauseOnExit(false);
+  }
+
   // Make the isolate runnable so that it is ready to handle messages.
   Dart_ExitScope();
   Dart_ExitIsolate();
@@ -555,6 +543,8 @@
 
   Dart_Handle result = Dart_SetLibraryTagHandler(Loader::LibraryTagHandler);
   CHECK_RESULT(result);
+  result = Dart_SetDeferredLoadHandler(Loader::DeferredLoadHandler);
+  CHECK_RESULT(result);
 
   // Load embedder specific bits and return.
   if (!VmService::Setup(
@@ -937,8 +927,8 @@
     // initial startup message.
     const intptr_t kNumIsolateArgs = 2;
     Dart_Handle isolate_args[kNumIsolateArgs];
-    isolate_args[0] = main_closure;                        // entryPoint
-    isolate_args[1] = CreateRuntimeOptions(dart_options);  // args
+    isolate_args[0] = main_closure;                          // entryPoint
+    isolate_args[1] = dart_options->CreateRuntimeOptions();  // args
 
     Dart_Handle isolate_lib =
         Dart_LookupLibrary(Dart_NewStringFromCString("dart:isolate"));
@@ -1007,7 +997,7 @@
 #endif  // !defined(PRODUCT)
 
 void main(int argc, char** argv) {
-  char* script_name;
+  char* script_name = nullptr;
   const int EXTRA_VM_ARGUMENTS = 10;
   CommandLineOptions vm_options(argc + EXTRA_VM_ARGUMENTS);
   CommandLineOptions dart_options(argc + EXTRA_VM_ARGUMENTS);
@@ -1097,9 +1087,6 @@
     }
   }
 
-  // At this point, script_name now points to either a script or a snapshot
-  // determined by DartDevUtils above.
-
   DartUtils::SetEnvironment(Options::environment());
 
   if (Options::suppress_core_dump()) {
@@ -1110,19 +1097,28 @@
 
   Loader::InitOnce();
 
-  if (app_snapshot == nullptr) {
-    // For testing purposes we add a flag to debug-mode to use the
-    // in-memory ELF loader.
-    const bool force_load_elf_from_memory =
-        false DEBUG_ONLY(|| Options::force_load_elf_from_memory());
-    app_snapshot =
-        Snapshot::TryReadAppSnapshot(script_name, force_load_elf_from_memory);
-  }
-  if (app_snapshot != nullptr) {
-    vm_run_app_snapshot = true;
-    app_snapshot->SetBuffers(&vm_snapshot_data, &vm_snapshot_instructions,
-                             &app_isolate_snapshot_data,
-                             &app_isolate_snapshot_instructions);
+  auto try_load_snapshots_lambda = [&](void) -> void {
+    if (app_snapshot == nullptr) {
+      // For testing purposes we add a flag to debug-mode to use the
+      // in-memory ELF loader.
+      const bool force_load_elf_from_memory =
+          false DEBUG_ONLY(|| Options::force_load_elf_from_memory());
+      app_snapshot =
+          Snapshot::TryReadAppSnapshot(script_name, force_load_elf_from_memory);
+    }
+    if (app_snapshot != nullptr) {
+      vm_run_app_snapshot = true;
+      app_snapshot->SetBuffers(&vm_snapshot_data, &vm_snapshot_instructions,
+                               &app_isolate_snapshot_data,
+                               &app_isolate_snapshot_instructions);
+    }
+  };
+
+  // At this point, script_name now points to a script if DartDev is disabled
+  // or a valid file path was provided as the first non-flag argument.
+  // Otherwise, script_name can be NULL if DartDev should be run.
+  if (script_name != nullptr) {
+    try_load_snapshots_lambda();
   }
 
   if (Options::gen_snapshot_kind() == kAppJIT) {
@@ -1155,16 +1151,18 @@
 // Note: must read platform only *after* VM flags are parsed because
 // they might affect how the platform is loaded.
 #if !defined(DART_PRECOMPILED_RUNTIME)
-  dfe.Init(Options::target_abi_version());
-  uint8_t* application_kernel_buffer = NULL;
-  intptr_t application_kernel_buffer_size = 0;
-  dfe.ReadScript(script_name, &application_kernel_buffer,
-                 &application_kernel_buffer_size);
-  if (application_kernel_buffer != NULL) {
-    // Since we loaded the script anyway, save it.
-    dfe.set_application_kernel_buffer(application_kernel_buffer,
-                                      application_kernel_buffer_size);
-    Options::dfe()->set_use_dfe();
+  if (script_name != nullptr) {
+    dfe.Init(Options::target_abi_version());
+    uint8_t* application_kernel_buffer = NULL;
+    intptr_t application_kernel_buffer_size = 0;
+    dfe.ReadScript(script_name, &application_kernel_buffer,
+                   &application_kernel_buffer_size);
+    if (application_kernel_buffer != NULL) {
+      // Since we loaded the script anyway, save it.
+      dfe.set_application_kernel_buffer(application_kernel_buffer,
+                                        application_kernel_buffer_size);
+      Options::dfe()->set_use_dfe();
+    }
   }
 #endif
 
@@ -1204,10 +1202,29 @@
                                  &ServiceStreamCancelCallback);
   Dart_SetFileModifiedCallback(&FileModifiedCallback);
   Dart_SetEmbedderInformationCallback(&EmbedderInformationCallback);
+  bool ran_dart_dev = false;
+  bool should_run_user_program = true;
+#if !defined(DART_PRECOMPILED_RUNTIME)
+  if (DartDevIsolate::should_run_dart_dev() && !Options::disable_dart_dev() &&
+      Options::gen_snapshot_kind() == SnapshotKind::kNone) {
+    DartDevIsolate::DartDev_Result dartdev_result = DartDevIsolate::RunDartDev(
+        CreateIsolateGroupAndSetup, Options::packages_file(), &script_name,
+        &dart_options);
+    ASSERT(dartdev_result != DartDevIsolate::DartDev_Result_Unknown);
+    ran_dart_dev = true;
+    should_run_user_program =
+        (dartdev_result == DartDevIsolate::DartDev_Result_Run);
+    if (should_run_user_program) {
+      try_load_snapshots_lambda();
+    }
+  }
+#endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
-  // Run the main isolate until we aren't told to restart.
-  while (RunMainIsolate(script_name, &dart_options)) {
-    Syslog::PrintErr("Restarting VM\n");
+  if (should_run_user_program) {
+    // Run the main isolate until we aren't told to restart.
+    while (RunMainIsolate(script_name, &dart_options)) {
+      Syslog::PrintErr("Restarting VM\n");
+    }
   }
 
   // Terminate process exit-code handler.
@@ -1223,6 +1240,9 @@
 
   delete app_snapshot;
   free(app_script_uri);
+  if (ran_dart_dev && script_name != nullptr) {
+    free(script_name);
+  }
 
   // Free copied argument strings if converted.
   if (argv_converted) {
diff --git a/runtime/bin/main_options.cc b/runtime/bin/main_options.cc
index e3f195b..4398c1f 100644
--- a/runtime/bin/main_options.cc
+++ b/runtime/bin/main_options.cc
@@ -9,7 +9,7 @@
 #include <string.h>
 
 #include "bin/abi_version.h"
-#include "bin/dartdev_utils.h"
+#include "bin/dartdev_isolate.h"
 #include "bin/error_exit.h"
 #include "bin/options.h"
 #include "bin/platform.h"
@@ -35,9 +35,6 @@
     NULL,
 };
 
-static const char* kEnableExperiment1 = "--enable-experiment";
-static const char* kEnableExperiment2 = "--enable_experiment";
-
 SnapshotKind Options::gen_snapshot_kind_ = kNone;
 bool Options::enable_vm_service_ = false;
 MallocGrowableArray<const char*> Options::enabled_experiments_ =
@@ -190,17 +187,6 @@
 "      --warn-on-pause-with-no-debugger\n"
 "  This set is subject to change.\n"
 "  Please see these options for further documentation.\n"
-"--write-service-info=<file_uri>\n"
-"  Outputs information necessary to connect to the VM service to the\n"
-"  specified file in JSON format. Useful for clients which are unable to\n"
-"  listen to stdout for the Observatory listening message.\n"
-"--snapshot-kind=<snapshot_kind>\n"
-"--snapshot=<file_name>\n"
-"  These snapshot options are used to generate a snapshot of the loaded\n"
-"  Dart script:\n"
-"    <snapshot-kind> controls the kind of snapshot, it could be\n"
-"                    kernel(default) or app-jit\n"
-"    <file_name> specifies the file into which the snapshot is written\n"
 "--version\n"
 "  Print the VM version.\n"
 "\n"
@@ -392,27 +378,17 @@
     return false;
   }
   vm_options->AddArgument(arg);
-  Utils::CStringUniquePtr tmp = Utils::CreateCStringUniquePtr(
-      Utils::StrDup(value));
+  Utils::CStringUniquePtr tmp =
+      Utils::CreateCStringUniquePtr(Utils::StrDup(value));
   char* save_ptr;  // Needed for strtok_r.
   char* token = strtok_r(const_cast<char*>(tmp.get()), ",", &save_ptr);
   while (token != NULL) {
-    enabled_experiments_.Add(token);
+    enabled_experiments_.Add(Utils::StrDup(token));
     token = strtok_r(NULL, ",", &save_ptr);
   }
   return true;
 }
 
-static void ResolveDartDevSnapshotPath(const char* script,
-                                       char** snapshot_path) {
-  if (!DartDevUtils::TryResolveDartDevSnapshotPath(snapshot_path)) {
-    Syslog::PrintErr(
-        "Could not find DartDev snapshot and '%s' is not a valid script.\n",
-        script);
-    Platform::Exit(kErrorExitCode);
-  }
-}
-
 int Options::ParseArguments(int argc,
                             char** argv,
                             bool vm_run_app_snapshot,
@@ -487,17 +463,11 @@
     }
   }
 
-  if (!Options::disable_dart_dev()) {
-    // Don't start the VM service for the DartDev process. Without doing a
-    // second pass over the argument list to explicitly check for
-    // --disable-dart-dev, this is the earliest we can assume we know whether
-    // or not we're running with DartDev enabled.
-    vm_service_server_port_ = INVALID_VM_SERVICE_SERVER_PORT;
-    vm_service_server_ip_ = DEFAULT_VM_SERVICE_SERVER_IP;
-  }
-
 #if !defined(DART_PRECOMPILED_RUNTIME)
   Options::dfe()->set_use_dfe();
+#else
+  // DartDev is not supported in AOT.
+  Options::disable_dart_dev_ = true;
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
   if (Options::deterministic()) {
     // Both an embedder and VM flag.
@@ -514,24 +484,31 @@
   // The arguments to the VM are at positions 1 through i-1 in argv.
   Platform::SetExecutableArguments(i, argv);
 
-  bool implicitly_use_dart_dev = false;
   bool run_script = false;
   int script_or_cmd_index = -1;
+
   // Get the script name.
   if (i < argc) {
+#if !defined(DART_PRECOMPILED_RUNTIME)
     // If the script name is a valid file or a URL, we'll run the script
     // directly. Otherwise, this might be a DartDev command and we need to try
     // to find the DartDev snapshot so we can forward the command and its
     // arguments.
-    bool is_potential_file_path = !DartDevUtils::ShouldParseCommand(argv[i]);
+    bool is_potential_file_path = !DartDevIsolate::ShouldParseCommand(argv[i]);
+    bool implicitly_use_dart_dev = false;
+#else
+    bool is_potential_file_path = true;
+#endif  // !defined(DART_PRECOMPILED_RUNTIME)
     script_or_cmd_index = i;
     if (Options::disable_dart_dev() ||
         (is_potential_file_path && !enable_vm_service_)) {
       *script_name = Utils::StrDup(argv[i]);
       run_script = true;
       i++;
-    } else {
-      ResolveDartDevSnapshotPath(argv[i], script_name);
+    }
+#if !defined(DART_PRECOMPILED_RUNTIME)
+    else {  // NOLINT
+      DartDevIsolate::set_should_run_dart_dev(true);
     }
     // Handle the special case where the user is running a Dart program without
     // using a DartDev command and wants to use the VM service. Here we'll run
@@ -541,10 +518,13 @@
       implicitly_use_dart_dev = true;
       dart_options->AddArgument("run");
     }
-  } else if (!Options::disable_dart_dev() &&
-             ((Options::help_option() && !Options::verbose_option()) ||
-              (argc == 1)) &&
-             DartDevUtils::TryResolveDartDevSnapshotPath(script_name)) {
+#endif  // !defined(DART_PRECOMPILED_RUNTIME)
+  }
+#if !defined(DART_PRECOMPILED_RUNTIME)
+  else if (!Options::disable_dart_dev() &&  // NOLINT
+           ((Options::help_option() && !Options::verbose_option()) ||
+            (argc == 1))) {
+    DartDevIsolate::set_should_run_dart_dev(true);
     // Let DartDev handle the default help message.
     dart_options->AddArgument("help");
     return 0;
@@ -552,7 +532,7 @@
              (enable_dartdev_analytics || disable_dartdev_analytics)) {
     // The analytics flags are a special case as we don't have a target script
     // or DartDev command but we still want to launch DartDev.
-    ResolveDartDevSnapshotPath(argv[i], script_name);
+    DartDevIsolate::set_should_run_dart_dev(true);
 
     if (enable_dartdev_analytics) {
       dart_options->AddArgument("--enable-analytics");
@@ -561,89 +541,68 @@
       dart_options->AddArgument("--disable-analytics");
     }
     return 0;
-  } else {
-    return -1;
   }
 
+#endif    // !defined(DART_PRECOMPILED_RUNTIME)
+  else {  // NOLINT
+    return -1;
+  }
   const char** vm_argv = temp_vm_options.arguments();
   int vm_argc = temp_vm_options.count();
 
-  if (Options::disable_dart_dev() || run_script) {
-    // Only populate the VM options if we're not running with DartDev.
-    vm_options->AddArguments(vm_argv, vm_argc);
-  } else if (implicitly_use_dart_dev) {
-    // If we're using DartDev implicitly (e.g., dart --observe foo.dart), we
-    // want to forward all the VM arguments to the spawned process to ensure
-    // the program behaves as the user expects even though we're running
-    // through DartDev without their knowledge.
-    dart_options->AddArguments(const_cast<const char**>(argv + 1),
-                               script_or_cmd_index - 1);
-  } else if (i > 1) {
-    // If we're running with DartDev, we're going to ignore the VM options for
-    // this VM instance and print a warning.
+  vm_options->AddArguments(vm_argv, vm_argc);
 
-    int num_experiment_flags = 0;
-    if (!enabled_experiments_.is_empty()) {
-      for (intptr_t j = 1; j < script_or_cmd_index; ++j) {
-        if ((strstr(argv[j], kEnableExperiment1) != nullptr) ||
-            (strstr(argv[j], kEnableExperiment2) != nullptr)) {
-          ++num_experiment_flags;
-        }
-      }
-    }
-    if (num_experiment_flags + 1 != script_or_cmd_index) {
-      Syslog::PrintErr(
-          "Warning: The following flags were passed as VM options and are "
-          "being "
-          "ignored:\n\n");
-      for (int j = 1; j < script_or_cmd_index; ++j) {
-        if ((strstr(argv[j], kEnableExperiment1) == nullptr) &&
-            (strstr(argv[j], kEnableExperiment2) == nullptr)) {
-          Syslog::PrintErr("  %s\n", argv[j]);
-        }
-      }
-      Syslog::PrintErr(
-          "\nThese flags should be passed after the dart command (e.g., 'dart "
-          "run --enable-asserts foo.dart' instead of 'dart --enable-asserts "
-          "run "
-          "foo.dart').\n\n");
-    }
-  }
-
-  if (!enabled_experiments_.is_empty() &&
-      !(Options::disable_dart_dev() || run_script)) {
+#if !defined(DART_PRECOMPILED_RUNTIME)
+  if (!enabled_experiments_.is_empty()) {
     intptr_t num_experiments = enabled_experiments_.length();
-    int option_size = strlen(kEnableExperiment1) + 1;
-    for (intptr_t i = 0; i < num_experiments; ++i) {
-      const char* flag = enabled_experiments_.At(i);
-      option_size += strlen(flag);
-      if (i + 1 != num_experiments) {
-        // Account for comma if there's more experiments to add.
-        ++option_size;
+    if (!(Options::disable_dart_dev() || run_script)) {
+      const char* kEnableExperiment = "--enable-experiment=";
+      int option_size = strlen(kEnableExperiment);
+      for (intptr_t i = 0; i < num_experiments; ++i) {
+        const char* flag = enabled_experiments_.At(i);
+        option_size += strlen(flag);
+        if (i + 1 != num_experiments) {
+          // Account for comma if there's more experiments to add.
+          ++option_size;
+        }
+      }
+      // Make room for null terminator
+      ++option_size;
+
+      char* enabled_experiments_arg = new char[option_size];
+      int offset = snprintf(enabled_experiments_arg, option_size, "%s",
+                            kEnableExperiment);
+      for (intptr_t i = 0; i < num_experiments; ++i) {
+        const char* flag = enabled_experiments_.At(i);
+        const char* kFormat = (i + 1 != num_experiments) ? "%s," : "%s";
+        offset += snprintf(enabled_experiments_arg + offset,
+                           option_size - offset, kFormat, flag);
+        free(const_cast<char*>(flag));
+        ASSERT(offset < option_size);
+      }
+      DartDevIsolate::set_should_run_dart_dev(true);
+      dart_options->AddArgument(enabled_experiments_arg);
+    } else {
+      for (intptr_t i = 0; i < num_experiments; ++i) {
+        free(const_cast<char*>(enabled_experiments_.At(i)));
       }
     }
-    // Make room for null terminator
-    ++option_size;
-
-    char* enabled_experiments_arg = new char[option_size];
-    int offset = snprintf(enabled_experiments_arg, option_size,
-                          "%s=", kEnableExperiment1);
-    for (intptr_t i = 0; i < num_experiments; ++i) {
-      const char* flag = enabled_experiments_.At(i);
-      const char* kFormat = (i + 1 != num_experiments) ? "%s," : "%s";
-      offset += snprintf(enabled_experiments_arg + offset, option_size - offset,
-                         kFormat, flag);
-      ASSERT(offset < option_size);
-    }
-    dart_options->AddArgument(enabled_experiments_arg);
   }
+#endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
   // Parse out options to be passed to dart main.
   while (i < argc) {
+    if (!run_script) {
+      OptionProcessor::TryProcess(argv[i], vm_options);
+    }
     dart_options->AddArgument(argv[i]);
     i++;
   }
 
+  if (!Options::disable_dart_dev() && enable_vm_service_) {
+    dart_options->AddArgument("--launch-dds");
+  }
+
   // Verify consistency of arguments.
 
   // snapshot_depfile is an alias for depfile. Passing them both is an error.
diff --git a/runtime/bin/platform.h b/runtime/bin/platform.h
index f7ac32c..0a7db28 100644
--- a/runtime/bin/platform.h
+++ b/runtime/bin/platform.h
@@ -9,6 +9,10 @@
 #include "platform/globals.h"
 #include "platform/utils.h"
 
+#if defined(HOST_OS_MACOS)
+#include "bin/platform_macos.h"
+#endif  // defined(HOST_OS_MACOS)
+
 namespace dart {
 namespace bin {
 
diff --git a/runtime/bin/platform_macos.cc b/runtime/bin/platform_macos.cc
index bacb7a75..f7c4c8c 100644
--- a/runtime/bin/platform_macos.cc
+++ b/runtime/bin/platform_macos.cc
@@ -6,6 +6,7 @@
 #if defined(HOST_OS_MACOS)
 
 #include "bin/platform.h"
+#include "bin/platform_macos.h"
 
 #include <CoreFoundation/CoreFoundation.h>
 
@@ -14,13 +15,12 @@
 #endif                    // !HOST_OS_IOS
 #include <errno.h>        // NOLINT
 #include <mach-o/dyld.h>
-#include <signal.h>       // NOLINT
-#include <string.h>       // NOLINT
+#include <signal.h>        // NOLINT
 #include <sys/resource.h>  // NOLINT
-#include <sys/sysctl.h>   // NOLINT
-#include <sys/types.h>    // NOLINT
-#include <sys/utsname.h>  // NOLINT
-#include <unistd.h>       // NOLINT
+#include <sys/sysctl.h>    // NOLINT
+#include <sys/types.h>     // NOLINT
+#include <sys/utsname.h>   // NOLINT
+#include <unistd.h>        // NOLINT
 
 #include "bin/console.h"
 #include "bin/file.h"
@@ -114,7 +114,70 @@
 #endif
 }
 
+char* ExtractsOSVersionFromString(char* str) {
+  char* pos = strstr(str, "<key>ProductVersion</key>");
+  if (pos == NULL) {
+    return NULL;
+  }
+  pos = strstr(pos, "<string>");
+  if (pos == NULL) {
+    return NULL;
+  }
+  // Shift the index by the length of "<string>".
+  pos += 8;
+  char* end_pos = strstr(pos, "</string>");
+  if (end_pos == NULL) {
+    return NULL;
+  }
+
+  int length = end_pos - pos;
+  char* result =
+      reinterpret_cast<char*>(Dart_ScopeAllocate(length * sizeof(char)) + 1);
+  strncpy(result, pos, length);
+  result[length] = '\0';
+  return result;
+}
+
+static char* GetOSVersionFromPlist() {
+  const char* path = "/System/Library/CoreServices/SystemVersion.plist";
+  File* file = File::Open(NULL, path, File::kRead);
+  if (file == NULL) {
+    return NULL;
+  }
+  int length = file->Length();
+  if (length < 0) {
+    return NULL;
+  }
+  char* buffer =
+      reinterpret_cast<char*>(Dart_ScopeAllocate(length * sizeof(char) + 1));
+  int bytes = file->ReadFully(buffer, length);
+  buffer[length * sizeof(char)] = '\0';
+  file->Close();
+  file->Release();
+  if (bytes < 0) {
+    return NULL;
+  }
+  return ExtractsOSVersionFromString(buffer);
+}
+
 const char* Platform::OperatingSystemVersion() {
+  char str[64];
+  size_t size = sizeof(str);
+  // This is only available to some versions later than 10.13.*. If it failed,
+  // try to read from "SystemVersion.plist".
+  int res = sysctlbyname("kern.osproductversion", str, &size, NULL, 0);
+  if (res == 0) {
+    int len = snprintf(NULL, 0, "%s", str);
+    char* result_string = DartUtils::ScopedCString(len + 1);
+    strncpy(result_string, str, len);
+    result_string[len] = '\0';
+    return result_string;
+  }
+  char* result_string = GetOSVersionFromPlist();
+  if (result_string != NULL) {
+    return result_string;
+  }
+
   struct utsname info;
   int ret = uname(&info);
   if (ret != 0) {
diff --git a/runtime/bin/platform_macos.h b/runtime/bin/platform_macos.h
new file mode 100644
index 0000000..26a1afe
--- /dev/null
+++ b/runtime/bin/platform_macos.h
@@ -0,0 +1,27 @@
+// 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.
+
+#ifndef RUNTIME_BIN_PLATFORM_MACOS_H_
+#define RUNTIME_BIN_PLATFORM_MACOS_H_
+
+#if !defined(RUNTIME_BIN_PLATFORM_H_)
+#error Do not include platform_macos.h directly;
+#error use platform.h instead.
+#endif
+
+namespace dart {
+namespace bin {
+
+// This function extracts OSVersion from SystemVersion.plist.
+// The format of input should be:
+//   <key>ProductVersion</key>
+//   <string>10.15.4</string>
+// Returns the string representation of OSVersion. For example, "10.15.4" will
+// be returned in the previous example.
+char* ExtractsOSVersionFromString(char* str);
+
+}  // namespace bin
+}  // namespace dart
+
+#endif  // RUNTIME_BIN_PLATFORM_MACOS_H_
diff --git a/runtime/bin/platform_macos_test.cc b/runtime/bin/platform_macos_test.cc
new file mode 100644
index 0000000..052d541
--- /dev/null
+++ b/runtime/bin/platform_macos_test.cc
@@ -0,0 +1,53 @@
+// 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.
+
+#if defined(HOST_OS_MACOS)
+#include "bin/platform.h"
+#include "vm/unit_test.h"
+
+namespace dart {
+
+TEST_CASE(Platform_ExtractsOSVersionFromString) {
+  char str[] =
+      "some overheads\n<key>ProductVersion</key>\nsome bytes<string>Fake "
+      "version</string>";
+  char* result = bin::ExtractsOSVersionFromString(str);
+  EXPECT(result != NULL);
+  EXPECT_STREQ("Fake version", result);
+
+  EXPECT(bin::ExtractsOSVersionFromString("<key>ProductVersion</key>") == NULL);
+
+  // Incomplete file
+  EXPECT(bin::ExtractsOSVersionFromString(
+             "<key>ProductVersion</key><string>Fake version</string") != NULL);
+
+  // A copy of actual SystemVersion.plist on mac.
+  str =
+      "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
+      "<!DOCTYPE plist PUBLIC \"-//Apple//DTD PLIST 1.0//EN\" "
+      "\"http://www.apple.com/DTDs/PropertyList-1.0.dtd\">\n"
+      "<plist version=\"1.0\">\n"
+      "<dict>\n"
+      "        <key>ProductBuildVersion</key>\n"
+      "        <string>19E287</string>\n"
+      "        <key>ProductCopyright</key>\n"
+      "        <string>1983-2020 Apple Inc.</string>\n"
+      "        <key>ProductName</key>\n"
+      "        <string>Mac OS X</string>\n"
+      "        <key>ProductUserVisibleVersion</key>\n"
+      "        <string>10.15.4</string>\n"
+      "        <key>ProductVersion</key>\n"
+      "        <string>10.15.4</string>\n"
+      "        <key>iOSSupportVersion</key>\n"
+      "        <string>13.4</string>\n"
+      "</dict>\n"
+      "</plist>"
+
+      result = bin::ExtractsOSVersionFromString(str);
+  EXPECT(result != NULL);
+  EXPECT_STREQ("10.15.4", result);
+}
+
+}  // namespace dart
+#endif  // defined(HOST_OS_MACOS)
diff --git a/runtime/bin/process_android.cc b/runtime/bin/process_android.cc
index 10082b98..b296299 100644
--- a/runtime/bin/process_android.cc
+++ b/runtime/bin/process_android.cc
@@ -231,6 +231,8 @@
             process_count_--;
           }
         }
+      } else if (pid < 0) {
+        FATAL1("Wait for process exit failed: %d", errno);
       }
     }
   }
diff --git a/runtime/bin/process_linux.cc b/runtime/bin/process_linux.cc
index fac361f..dc8d500 100644
--- a/runtime/bin/process_linux.cc
+++ b/runtime/bin/process_linux.cc
@@ -231,6 +231,8 @@
             process_count_--;
           }
         }
+      } else if (pid < 0) {
+        FATAL1("Wait for process exit failed: %d", errno);
       }
     }
   }
diff --git a/runtime/bin/process_macos.cc b/runtime/bin/process_macos.cc
index 3583a284..624ea8a 100644
--- a/runtime/bin/process_macos.cc
+++ b/runtime/bin/process_macos.cc
@@ -227,6 +227,8 @@
             process_count_--;
           }
         }
+      } else if (pid < 0) {
+        FATAL1("Wait for process exit failed: %d", errno);
       }
     }
   }
diff --git a/runtime/bin/secure_socket_filter.cc b/runtime/bin/secure_socket_filter.cc
index cff4c4d..56060ba 100644
--- a/runtime/bin/secure_socket_filter.cc
+++ b/runtime/bin/secure_socket_filter.cc
@@ -652,21 +652,35 @@
 int SSLFilter::ProcessReadPlaintextBuffer(int start, int end) {
   int length = end - start;
   int bytes_processed = 0;
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Entering ProcessReadPlaintextBuffer with %d bytes\n",
+                  length);
+  }
   if (length > 0) {
     bytes_processed = SSL_read(
         ssl_, reinterpret_cast<char*>((buffers_[kReadPlaintext] + start)),
         length);
     if (bytes_processed < 0) {
       int error = SSL_get_error(ssl_, bytes_processed);
-      USE(error);
+      if (SSL_LOG_DATA) {
+        Syslog::Print("SSL_read returned error %d\n", error);
+      }
       bytes_processed = 0;
     }
   }
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Leaving ProcessReadPlaintextBuffer read %d bytes\n",
+                  bytes_processed);
+  }
   return bytes_processed;
 }
 
 int SSLFilter::ProcessWritePlaintextBuffer(int start, int end) {
   int length = end - start;
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Entering ProcessWritePlaintextBuffer with %d bytes\n",
+                  length);
+  }
   int bytes_processed =
       SSL_write(ssl_, buffers_[kWritePlaintext] + start, length);
   if (bytes_processed < 0) {
@@ -675,15 +689,20 @@
     }
     return 0;
   }
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Leaving ProcessWritePlaintextBuffer wrote %d bytes\n",
+                  bytes_processed);
+  }
   return bytes_processed;
 }
 
 /* Read encrypted data from the circular buffer to the filter */
 int SSLFilter::ProcessReadEncryptedBuffer(int start, int end) {
   int length = end - start;
-  if (SSL_LOG_DATA)
+  if (SSL_LOG_DATA) {
     Syslog::Print("Entering ProcessReadEncryptedBuffer with %d bytes\n",
                   length);
+  }
   int bytes_processed = 0;
   if (length > 0) {
     bytes_processed =
@@ -691,33 +710,41 @@
     if (bytes_processed <= 0) {
       bool retry = BIO_should_retry(socket_side_) != 0;
       if (!retry) {
-        if (SSL_LOG_DATA)
+        if (SSL_LOG_DATA) {
           Syslog::Print("BIO_write failed in ReadEncryptedBuffer\n");
+        }
       }
       bytes_processed = 0;
     }
   }
-  if (SSL_LOG_DATA)
-    Syslog::Print("Leaving ProcessReadEncryptedBuffer wrote %d bytes\n",
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Leaving ProcessReadEncryptedBuffer read %d bytes\n",
                   bytes_processed);
+  }
   return bytes_processed;
 }
 
 int SSLFilter::ProcessWriteEncryptedBuffer(int start, int end) {
   int length = end - start;
   int bytes_processed = 0;
+  if (SSL_LOG_DATA) {
+    Syslog::Print("Entering ProcessWriteEncryptedBuffer with %d bytes\n",
+                  length);
+  }
   if (length > 0) {
     bytes_processed =
         BIO_read(socket_side_, buffers_[kWriteEncrypted] + start, length);
     if (bytes_processed < 0) {
-      if (SSL_LOG_DATA)
+      if (SSL_LOG_DATA) {
         Syslog::Print("WriteEncrypted BIO_read returned error %d\n",
                       bytes_processed);
+      }
       return 0;
     } else {
-      if (SSL_LOG_DATA)
+      if (SSL_LOG_DATA) {
         Syslog::Print("WriteEncrypted  BIO_read wrote %d bytes\n",
                       bytes_processed);
+      }
     }
   }
   return bytes_processed;
diff --git a/runtime/bin/snapshot_utils.cc b/runtime/bin/snapshot_utils.cc
index 4390d24..2adc48e 100644
--- a/runtime/bin/snapshot_utils.cc
+++ b/runtime/bin/snapshot_utils.cc
@@ -304,15 +304,9 @@
 
   const uint8_t* vm_data_buffer = reinterpret_cast<const uint8_t*>(
       Extensions::ResolveSymbol(library, kVmSnapshotDataCSymbol));
-  if (vm_data_buffer == NULL) {
-    FATAL1("Failed to resolve symbol '%s'\n", kVmSnapshotDataCSymbol);
-  }
 
   const uint8_t* vm_instructions_buffer = reinterpret_cast<const uint8_t*>(
       Extensions::ResolveSymbol(library, kVmSnapshotInstructionsCSymbol));
-  if (vm_instructions_buffer == NULL) {
-    FATAL1("Failed to resolve symbol '%s'\n", kVmSnapshotInstructionsCSymbol);
-  }
 
   const uint8_t* isolate_data_buffer = reinterpret_cast<const uint8_t*>(
       Extensions::ResolveSymbol(library, kIsolateSnapshotDataCSymbol));
diff --git a/runtime/include/dart_api.h b/runtime/include/dart_api.h
index db78c76..8c6afd4 100644
--- a/runtime/include/dart_api.h
+++ b/runtime/include/dart_api.h
@@ -3029,6 +3029,59 @@
 Dart_SetLibraryTagHandler(Dart_LibraryTagHandler handler);
 
 /**
+ * Handles deferred loading requests. When this handler is invoked, it should
+ * eventually load the deferred loading unit with the given id and call
+ * Dart_DeferredLoadComplete or Dart_DeferredLoadCompleteError. It is
+ * recommended that the loading occur asynchronously, but it is permitted to
+ * call Dart_DeferredLoadComplete or Dart_DeferredLoadCompleteError before the
+ * handler returns.
+ *
+ * If an error is returned, it will be propogated through
+ * `prefix.loadLibrary()`. This is useful for synchronous
+ * implementations, which must propogate any unwind errors from
+ * Dart_DeferredLoadComplete or Dart_DeferredLoadComplete. Otherwise the handler
+ * should return a non-error such as `Dart_Null()`.
+ */
+typedef Dart_Handle (*Dart_DeferredLoadHandler)(intptr_t loading_unit_id);
+
+/**
+ * Sets the deferred load handler for the current isolate. This handler is
+ * used to handle loading deferred imports in an AppJIT or AppAOT program.
+ */
+DART_EXPORT Dart_Handle
+Dart_SetDeferredLoadHandler(Dart_DeferredLoadHandler handler);
+
+/**
+ * Notifies the VM that a deferred load completed successfully. This function
+ * will eventually cause the corresponding `prefix.loadLibrary()` futures to
+ * complete.
+ *
+ * Requires the current isolate to be the same current isolate during the
+ * invocation of the Dart_DeferredLoadHandler.
+ */
+DART_EXPORT DART_WARN_UNUSED_RESULT Dart_Handle
+Dart_DeferredLoadComplete(intptr_t loading_unit_id,
+                          const uint8_t* snapshot_data,
+                          const uint8_t* snapshot_instructions);
+
+/**
+ * Notifies the VM that a deferred load failed. This function
+ * will eventually cause the corresponding `prefix.loadLibrary()` futures to
+ * complete with an error.
+ *
+ * If `transient` is true, future invocations of `prefix.loadLibrary()` will
+ * trigger new load requests. If false, futures invocation will complete with
+ * the same error.
+ *
+ * Requires the current isolate to be the same current isolate during the
+ * invocation of the Dart_DeferredLoadHandler.
+ */
+DART_EXPORT DART_WARN_UNUSED_RESULT Dart_Handle
+Dart_DeferredLoadCompleteError(intptr_t loading_unit_id,
+                               const char* error_message,
+                               bool transient);
+
+/**
  * Canonicalizes a url with respect to some library.
  *
  * The url is resolved with respect to the library's url and some url
@@ -3522,9 +3575,15 @@
  */
 DART_EXPORT Dart_Handle Dart_Precompile();
 
+typedef void (*Dart_CreateLoadingUnitCallback)(
+    void* callback_data,
+    intptr_t loading_unit_id,
+    void** write_callback_data,
+    void** write_debug_callback_data);
 typedef void (*Dart_StreamingWriteCallback)(void* callback_data,
                                             const uint8_t* buffer,
                                             intptr_t size);
+typedef void (*Dart_StreamingCloseCallback)(void* callback_data);
 
 // On Darwin systems, 'dlsym' adds an '_' to the beginning of the symbol name.
 // Use the '...CSymbol' definitions for resolving through 'dlsym'. The actual
@@ -3580,6 +3639,13 @@
                                     void* callback_data,
                                     bool stripped,
                                     void* debug_callback_data);
+DART_EXPORT DART_WARN_UNUSED_RESULT Dart_Handle
+Dart_CreateAppAOTSnapshotAsAssemblies(
+    Dart_CreateLoadingUnitCallback next_callback,
+    void* next_callback_data,
+    bool stripped,
+    Dart_StreamingWriteCallback write_callback,
+    Dart_StreamingCloseCallback close_callback);
 
 /**
  *  Creates a precompiled snapshot.
@@ -3613,6 +3679,12 @@
                                void* callback_data,
                                bool stripped,
                                void* debug_callback_data);
+DART_EXPORT DART_WARN_UNUSED_RESULT Dart_Handle
+Dart_CreateAppAOTSnapshotAsElfs(Dart_CreateLoadingUnitCallback next_callback,
+                                void* next_callback_data,
+                                bool stripped,
+                                Dart_StreamingWriteCallback write_callback,
+                                Dart_StreamingCloseCallback close_callback);
 
 /**
  *  Like Dart_CreateAppAOTSnapshotAsAssembly, but only includes
diff --git a/runtime/lib/mirrors.cc b/runtime/lib/mirrors.cc
index c5a0f55..532f2f6 100644
--- a/runtime/lib/mirrors.cc
+++ b/runtime/lib/mirrors.cc
@@ -1419,7 +1419,8 @@
   GET_NON_NULL_NATIVE_ARGUMENT(Array, explicit_args, arguments->NativeArgAt(3));
   GET_NON_NULL_NATIVE_ARGUMENT(Array, arg_names, arguments->NativeArgAt(4));
 
-  const Error& error = Error::Handle(zone, klass.EnsureIsFinalized(thread));
+  const Error& error =
+      Error::Handle(zone, klass.EnsureIsAllocateFinalized(thread));
   if (!error.IsNull()) {
     Exceptions::PropagateError(error);
     UNREACHABLE();
@@ -1520,6 +1521,12 @@
                       InvocationMirror::kMethod);
     UNREACHABLE();
   }
+#if defined(DEBUG)
+  // Make sure the receiver is the null value, so that DoArgumentTypesMatch does
+  // not attempt to retrieve the instantiator type arguments from the receiver.
+  explicit_argument = args.At(args_descriptor.FirstArgIndex());
+  ASSERT(explicit_argument.IsNull());
+#endif
   const Object& type_error =
       Object::Handle(redirected_constructor.DoArgumentTypesMatch(
           args, args_descriptor, type_arguments));
diff --git a/runtime/lib/object.cc b/runtime/lib/object.cc
index 04afec9..7b86301 100644
--- a/runtime/lib/object.cc
+++ b/runtime/lib/object.cc
@@ -10,6 +10,7 @@
 #include "vm/heap/heap.h"
 #include "vm/native_entry.h"
 #include "vm/object.h"
+#include "vm/object_store.h"
 #include "vm/stack_frame.h"
 #include "vm/symbols.h"
 
@@ -209,6 +210,36 @@
   return Instance::null();
 }
 
+DEFINE_NATIVE_ENTRY(LibraryPrefix_loadingUnit, 0, 1) {
+  const LibraryPrefix& prefix =
+      LibraryPrefix::CheckedHandle(zone, arguments->NativeArgAt(0));
+  const Library& target = Library::Handle(zone, prefix.GetLibrary(0));
+  const LoadingUnit& unit = LoadingUnit::Handle(zone, target.loading_unit());
+  return Smi::New(unit.IsNull() ? LoadingUnit::kIllegalId : unit.id());
+}
+
+DEFINE_NATIVE_ENTRY(LibraryPrefix_issueLoad, 0, 1) {
+  const Smi& id = Smi::CheckedHandle(zone, arguments->NativeArgAt(0));
+  Array& units = Array::Handle(zone, isolate->object_store()->loading_units());
+  if (units.IsNull()) {
+    // Not actually split.
+    const Library& lib = Library::Handle(zone, Library::CoreLibrary());
+    const String& sel = String::Handle(zone, String::New("_completeLoads"));
+    const Function& func =
+        Function::Handle(zone, lib.LookupFunctionAllowPrivate(sel));
+    ASSERT(!func.IsNull());
+    const Array& args = Array::Handle(zone, Array::New(3));
+    args.SetAt(0, id);
+    args.SetAt(1, String::Handle(zone));
+    args.SetAt(2, Bool::Get(false));
+    return DartEntry::InvokeFunction(func, args);
+  }
+  ASSERT(id.Value() != LoadingUnit::kIllegalId);
+  LoadingUnit& unit = LoadingUnit::Handle(zone);
+  unit ^= units.At(id.Value());
+  return unit.IssueLoad();
+}
+
 DEFINE_NATIVE_ENTRY(Internal_inquireIs64Bit, 0, 0) {
 #if defined(ARCH_IS_64_BIT)
   return Bool::True().raw();
diff --git a/runtime/observatory/lib/service_html.dart b/runtime/observatory/lib/service_html.dart
index ddc42f5..60f552c 100644
--- a/runtime/observatory/lib/service_html.dart
+++ b/runtime/observatory/lib/service_html.dart
@@ -18,7 +18,11 @@
 
   void connect(String address, void onOpen(), void onMessage(dynamic data),
       void onError(), void onClose()) {
-    _webSocket = new WebSocket(address);
+    // The VM service will attempt to redirect our websocket connection request
+    // to DDS, but the dart:html WebSocket doesn't follow redirects. If the
+    // 'implicit-redirect' protocol is provided, the VM service will manually
+    // forward traffic to DDS.
+    _webSocket = new WebSocket(address, ['implicit-redirect']);
     _webSocket.onClose.listen((CloseEvent) => onClose());
     _webSocket.onError.listen((Event) => onError());
     _webSocket.onOpen.listen((Event) => onOpen());
diff --git a/runtime/observatory/lib/src/elements/vm_view.dart b/runtime/observatory/lib/src/elements/vm_view.dart
index 9807fb2..d183dc3 100644
--- a/runtime/observatory/lib/src/elements/vm_view.dart
+++ b/runtime/observatory/lib/src/elements/vm_view.dart
@@ -112,12 +112,109 @@
             .element,
         new NavNotifyElement(_notifications, queue: _r.queue).element
       ]),
+      describeProcess(),
       describeVM(),
       describeIsolateGroups(),
       new ViewFooterElement(queue: _r.queue).element
     ];
   }
 
+  Element describeProcess() {
+    return new DivElement()
+      ..classes = ['content-centered-big']
+      ..children = <HtmlElement>[
+        new HeadingElement.h1()..text = 'Process',
+        new DivElement()
+          ..classes = ['memberList']
+          ..children = <Element>[
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..text = 'pid',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = '${_vm.pid}'
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..text = 'current memory'
+                  ..title =
+                      'current value of the resident set size of the process running this VM',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = _vm.currentRSS != null
+                      ? Utils.formatSize(_vm.currentRSS)
+                      : "unavailable"
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..text = 'peak memory'
+                  ..title =
+                      'highest value of the resident set size of the process running this VM',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = _vm.maxRSS != null
+                      ? Utils.formatSize(_vm.maxRSS)
+                      : "unavailable"
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..text = 'malloc memory',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = _vm.heapAllocatedMemoryUsage != null
+                      ? Utils.formatSize(_vm.heapAllocatedMemoryUsage)
+                      : 'unavailable'
+                  ..title = _vm.heapAllocatedMemoryUsage != null
+                      ? '${_vm.heapAllocatedMemoryUsage} bytes'
+                      : null
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..text = 'malloc allocation count',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = _vm.heapAllocationCount != null
+                      ? '${_vm.heapAllocationCount}'
+                      : 'unavailable'
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..children = <Element>[
+                    new SpanElement()..text = 'view ',
+                    new AnchorElement(href: Uris.nativeMemory())
+                      ..text = 'malloc profile'
+                  ],
+                new DivElement()
+                  ..classes = ['memberName']
+                  ..children = <Element>[
+                    new SpanElement()..text = 'view ',
+                    new AnchorElement(href: Uris.processSnapshot())
+                      ..text = 'process memory'
+                  ]
+              ]
+          ],
+        new BRElement(),
+      ];
+  }
+
   Element describeVM() {
     final uptime = new DateTime.now().difference(_vm.startTime);
     return new DivElement()
@@ -162,6 +259,19 @@
               ..children = <Element>[
                 new DivElement()
                   ..classes = ['memberName']
+                  ..text = 'current memory'
+                  ..title = 'current amount of memory consumed by the Dart VM',
+                new DivElement()
+                  ..classes = ['memberValue']
+                  ..text = _vm.currentMemory != null
+                      ? Utils.formatSize(_vm.currentMemory)
+                      : "unavailable"
+              ],
+            new DivElement()
+              ..classes = ['memberItem']
+              ..children = <Element>[
+                new DivElement()
+                  ..classes = ['memberName']
                   ..text = 'started at',
                 new DivElement()
                   ..classes = ['memberValue']
@@ -187,71 +297,6 @@
                   ..classes = ['memberValue']
                   ..text = '${new DateTime.now()}'
               ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..text = 'pid',
-                new DivElement()
-                  ..classes = ['memberValue']
-                  ..text = '${_vm.pid}'
-              ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..text = 'peak process memory'
-                  ..title =
-                      'highest value of the resident set size of the process running this VM',
-                new DivElement()
-                  ..classes = ['memberValue']
-                  ..text = _vm.maxRSS != null
-                      ? Utils.formatSize(_vm.maxRSS)
-                      : "unavailable"
-              ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..text = 'current process memory'
-                  ..title =
-                      'current value of the resident set size of the process running this VM',
-                new DivElement()
-                  ..classes = ['memberValue']
-                  ..text = _vm.currentRSS != null
-                      ? Utils.formatSize(_vm.currentRSS)
-                      : "unavailable"
-              ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..text = 'malloc memory',
-                new DivElement()
-                  ..classes = ['memberValue']
-                  ..text = _vm.heapAllocatedMemoryUsage != null
-                      ? Utils.formatSize(_vm.heapAllocatedMemoryUsage)
-                      : 'unavailable'
-                  ..title = _vm.heapAllocatedMemoryUsage != null
-                      ? '${_vm.heapAllocatedMemoryUsage} bytes'
-                      : null
-              ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..text = 'malloc allocation count',
-                new DivElement()
-                  ..classes = ['memberValue']
-                  ..text = _vm.heapAllocationCount != null
-                      ? '${_vm.heapAllocationCount}'
-                      : 'unavailable'
-              ],
             new BRElement(),
             new DivElement()
               ..classes = ['memberItem']
@@ -269,24 +314,6 @@
                     new AnchorElement(href: Uris.timeline())..text = 'timeline'
                   ]
               ],
-            new DivElement()
-              ..classes = ['memberItem']
-              ..children = <Element>[
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..children = <Element>[
-                    new SpanElement()..text = 'view ',
-                    new AnchorElement(href: Uris.nativeMemory())
-                      ..text = 'malloc profile'
-                  ],
-                new DivElement()
-                  ..classes = ['memberName']
-                  ..children = <Element>[
-                    new SpanElement()..text = 'view ',
-                    new AnchorElement(href: Uris.processSnapshot())
-                      ..text = 'process memory'
-                  ]
-              ]
           ],
         new BRElement(),
       ];
diff --git a/runtime/observatory/lib/src/models/objects/vm.dart b/runtime/observatory/lib/src/models/objects/vm.dart
index fe25c84..ae8210c 100644
--- a/runtime/observatory/lib/src/models/objects/vm.dart
+++ b/runtime/observatory/lib/src/models/objects/vm.dart
@@ -40,6 +40,7 @@
   /// The current number of allocations on the native heap within the VM.
   int get heapAllocationCount;
 
+  int get currentMemory;
   int get maxRSS;
   int get currentRSS;
 
diff --git a/runtime/observatory/lib/src/service/object.dart b/runtime/observatory/lib/src/service/object.dart
index 5badd86..9c9c76b 100644
--- a/runtime/observatory/lib/src/service/object.dart
+++ b/runtime/observatory/lib/src/service/object.dart
@@ -684,6 +684,7 @@
   int pid = 0;
   int heapAllocatedMemoryUsage = 0;
   int heapAllocationCount = 0;
+  int currentMemory;
   int maxRSS;
   int currentRSS;
   bool profileVM = false;
@@ -1032,6 +1033,7 @@
     heapAllocatedMemoryUsage = map['_heapAllocatedMemoryUsage'];
     heapAllocationCount = map['_heapAllocationCount'];
     embedder = map['_embedder'];
+    currentMemory = map['_currentMemory'];
     maxRSS = map['_maxRSS'];
     currentRSS = map['_currentRSS'];
     profileVM = map['_profilerMode'] == 'VM';
diff --git a/runtime/observatory/tests/service/step_through_mixin_from_sdk_test.dart b/runtime/observatory/tests/service/step_through_mixin_from_sdk_test.dart
index 0b804ee..fc075a0 100644
--- a/runtime/observatory/tests/service/step_through_mixin_from_sdk_test.dart
+++ b/runtime/observatory/tests/service/step_through_mixin_from_sdk_test.dart
@@ -35,19 +35,19 @@
 List<String> expected = [
   "$file:${LINE + 0}:17", // on "Foo" (in "new Foo()")
   "$file:${LINE + 1}:11", // on "="
-  "list.dart:105:25", // on parameter to "contains"
-  "list.dart:106:23", // on "length" in "this.length"
-  "list.dart:107:16", // on "=" in "i = 0"
-  "list.dart:107:23", // on "<" in "i < length"
-  "list.dart:108:15", // on "[" in "this[i]"
+  "list.dart:124:25", // on parameter to "contains"
+  "list.dart:125:23", // on "length" in "this.length"
+  "list.dart:126:16", // on "=" in "i = 0"
+  "list.dart:126:23", // on "<" in "i < length"
+  "list.dart:127:15", // on "[" in "this[i]"
   "$file:${LINE + 13}:23", // on parameter in "operator []"
   "$file:${LINE + 14}:5", // on "return"
-  "list.dart:108:19", // on "=="
-  "list.dart:109:26", // on "length" in "this.length"
-  "list.dart:109:18", // on "!="
-  "list.dart:107:34", // on "++" in "i++"
-  "list.dart:107:23", // on "<" in "i < length"
-  "list.dart:113:5", // on "return"
+  "list.dart:127:19", // on "=="
+  "list.dart:128:26", // on "length" in "this.length"
+  "list.dart:128:18", // on "!="
+  "list.dart:126:34", // on "++" in "i++"
+  "list.dart:126:23", // on "<" in "i < length"
+  "list.dart:132:5", // on "return"
   "$file:${LINE + 4}:5", // on "print"
   "$file:${LINE + 6}:1" // on ending '}'
 ];
diff --git a/runtime/observatory/tests/service/vm_test.dart b/runtime/observatory/tests/service/vm_test.dart
index 862e54f..f4417c4 100644
--- a/runtime/observatory/tests/service/vm_test.dart
+++ b/runtime/observatory/tests/service/vm_test.dart
@@ -12,10 +12,13 @@
     expect(vm.targetCPU, isNotNull);
     expect(vm.architectureBits == 32 || vm.architectureBits == 64, isTrue);
     expect(vm.embedder, equals("Dart VM"));
+    expect(vm.currentMemory, isNotNull);
+    expect(vm.currentMemory, greaterThan(0));
     expect(vm.currentRSS, isNotNull);
     expect(vm.currentRSS, greaterThan(0));
     expect(vm.maxRSS, isNotNull);
     expect(vm.maxRSS, greaterThan(0));
+    expect(vm.maxRSS, greaterThanOrEqualTo(vm.currentRSS));
   },
 ];
 
diff --git a/runtime/platform/globals.h b/runtime/platform/globals.h
index 0ec560e..91d062b 100644
--- a/runtime/platform/globals.h
+++ b/runtime/platform/globals.h
@@ -15,6 +15,14 @@
 #define FALL_THROUGH ((void)0)
 #endif
 
+#if defined(GOOGLE3)
+// google3 builds use NDEBUG to indicate non-debug builds which is different
+// from the way the Dart project expects it: DEBUG indicating a debug build.
+#if !defined(NDEBUG) && !defined(DEBUG)
+#define DEBUG
+#endif  // !NDEBUG && !DEBUG
+#endif  // GOOGLE3
+
 // __STDC_FORMAT_MACROS has to be defined before including <inttypes.h> to
 // enable platform independent printf format specifiers.
 #ifndef __STDC_FORMAT_MACROS
@@ -471,8 +479,10 @@
 typedef intptr_t word;
 typedef uintptr_t uword;
 
-// Size of a class id.
-typedef uint16_t classid_t;
+// Size of a class id assigned to concrete, abstract and top-level classes.
+//
+// We use a signed integer type here to make it comparable with intptr_t.
+typedef int32_t classid_t;
 
 // Byte sizes.
 const int kWordSize = sizeof(word);
diff --git a/runtime/tests/vm/dart/bytecode_and_ast_mix_test_body.dart b/runtime/tests/vm/dart/bytecode_and_ast_mix_test_body.dart
index dac3c07..703a2cc 100644
--- a/runtime/tests/vm/dart/bytecode_and_ast_mix_test_body.dart
+++ b/runtime/tests/vm/dart/bytecode_and_ast_mix_test_body.dart
@@ -16,7 +16,7 @@
 
 main() {
   ClassMirror classB = reflectClass(B);
-  MethodMirror foo = classB.declarations[#foo];
+  MethodMirror foo = classB.declarations[#foo] as MethodMirror;
   final annotation = foo.metadata[0].reflectee;
   Expect.isTrue(annotation.toString().contains('_Override'));
   print('OK');
diff --git a/runtime/tests/vm/dart/causal_stacks/utils.dart b/runtime/tests/vm/dart/causal_stacks/utils.dart
index c1bd59f..50b0bf3 100644
--- a/runtime/tests/vm/dart/causal_stacks/utils.dart
+++ b/runtime/tests/vm/dart/causal_stacks/utils.dart
@@ -149,6 +149,14 @@
   return completer.future;
 }
 
+// ----
+// Scenario: Future.timeout:
+// ----
+
+Future awaitTimeout() async {
+  await (throwAsync().timeout(Duration(seconds: 1)));
+}
+
 // Helpers:
 
 // We want lines that either start with a frame index or an async gap marker.
@@ -587,6 +595,7 @@
             r'^#7      _RawReceivePortImpl._handleMessage \(.+\)$',
           ],
       debugInfoFilename);
+
   final customErrorZoneExpected = const <String>[
     r'#0      throwSync \(.*/utils.dart:16(:3)?\)$',
     r'#1      allYield3 \(.*/utils.dart:39(:3)?\)$',
@@ -638,6 +647,48 @@
             r'#14     _RawReceivePortImpl._handleMessage ',
           ],
       debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'^#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^^<asynchronous suspension>$',
+    r'^#1      awaitTimeout ',
+  ];
+  await doTestAwait(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwait ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwaitThen ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwaitCatchError ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
 }
 
 // For: --no-causal-async-stacks --no-lazy-async-stacks
@@ -957,6 +1008,25 @@
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
   await doTestAwaitCatchError(
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^#1      _RootZone.runUnary ',
+    r'^#2      _FutureListener.handleValue ',
+    r'^#3      Future._propagateToListeners.handleValueCallback ',
+    r'^#4      Future._propagateToListeners ',
+    r'^#5      Future.(_addListener|_prependListeners).<anonymous closure> ',
+    r'^#6      _microtaskLoop ',
+    r'^#7      _startMicrotaskLoop ',
+    r'^#8      _runPendingImmediateCallback ',
+    r'^#9      _RawReceivePortImpl._handleMessage ',
+  ];
+  await doTestAwait(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
 }
 
 // For: --lazy-async-stacks
@@ -1218,4 +1288,35 @@
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
   await doTestAwaitCatchError(
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'^#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^<asynchronous suspension>$',
+    r'^#1      Future.timeout.<anonymous closure> \(dart:async/future_impl.dart\)$',
+    r'^<asynchronous suspension>$',
+    r'^#2      awaitTimeout ',
+    r'^<asynchronous suspension>$',
+  ];
+  await doTestAwait(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#3      doTestAwait ',
+            r'^<asynchronous suspension>$',
+            r'^#4      doTestsLazy ',
+            r'^<asynchronous suspension>$',
+            r'^#5      main ',
+            r'^<asynchronous suspension>$',
+          ],
+      debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#3      doTestAwaitThen.<anonymous closure> ',
+            r'^<asynchronous suspension>$',
+          ],
+      debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
 }
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_1.dart b/runtime/tests/vm/dart/incompatible_loading_unit_1.dart
new file mode 100644
index 0000000..35b3947
--- /dev/null
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_1.dart
@@ -0,0 +1,10 @@
+// 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 "incompatible_loading_unit_1_deferred.dart" deferred as lib;
+
+main() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_1_deferred.dart b/runtime/tests/vm/dart/incompatible_loading_unit_1_deferred.dart
new file mode 100644
index 0000000..c0b9a03
--- /dev/null
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_1_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+void foo() {
+  print("One!");
+}
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_2.dart b/runtime/tests/vm/dart/incompatible_loading_unit_2.dart
new file mode 100644
index 0000000..7a352f6c
--- /dev/null
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_2.dart
@@ -0,0 +1,10 @@
+// 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 "incompatible_loading_unit_2_deferred.dart" deferred as lib;
+
+main() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_2_deferred.dart b/runtime/tests/vm/dart/incompatible_loading_unit_2_deferred.dart
new file mode 100644
index 0000000..2dc3b7a
--- /dev/null
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_2_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+void foo() {
+  print("Two!");
+}
diff --git a/runtime/tests/vm/dart/incompatible_loading_unit_test.dart b/runtime/tests/vm/dart/incompatible_loading_unit_test.dart
new file mode 100644
index 0000000..8231f00
--- /dev/null
+++ b/runtime/tests/vm/dart/incompatible_loading_unit_test.dart
@@ -0,0 +1,97 @@
+// 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:convert";
+import "dart:io";
+
+import "package:expect/expect.dart";
+import "package:path/path.dart" as path;
+
+import "use_flag_test_helper.dart";
+
+main(List<String> args) async {
+  if (!isAOTRuntime) {
+    return; // Running in JIT: AOT binaries not available.
+  }
+
+  if (Platform.isAndroid) {
+    return; // SDK tree not available on the test device.
+  }
+
+  // These are the tools we need to be available to run on a given platform:
+  if (!File(platformDill).existsSync()) {
+    throw "Cannot run test as $platformDill does not exist";
+  }
+  if (!await testExecutable(genSnapshot)) {
+    throw "Cannot run test as $genSnapshot not available";
+  }
+
+  await withTempDir("incompatible-loading-unit-test", (String tempDir) async {
+    final source1 = path.join(
+        sdkDir, "runtime/tests/vm/dart_2/incompatible_loading_unit_1.dart");
+    final source2 = path.join(
+        sdkDir, "runtime/tests/vm/dart_2/incompatible_loading_unit_2.dart");
+    final dill1 = path.join(tempDir, "incompatible_loading_unit_1.dart.dill");
+    final dill2 = path.join(tempDir, "incompatible_loading_unit_2.dart.dill");
+    final snapshot1 = path.join(tempDir, "incompatible_loading_unit_1.so");
+    final snapshot2 = path.join(tempDir, "incompatible_loading_unit_2.so");
+    final manifest1 = path.join(tempDir, "incompatible_loading_unit_1.txt");
+    final manifest2 = path.join(tempDir, "incompatible_loading_unit_2.txt");
+    final deferredSnapshot1 = snapshot1 + "-2.part.so";
+    final deferredSnapshot2 = snapshot2 + "-2.part.so";
+
+    // Compile source to kernel.
+    await run(genKernel, <String>[
+      "--aot",
+      "--platform=$platformDill",
+      "-o",
+      dill1,
+      source1,
+    ]);
+    await run(genKernel, <String>[
+      "--aot",
+      "--platform=$platformDill",
+      "-o",
+      dill2,
+      source2,
+    ]);
+
+    // Compile kernel to ELF.
+    await run(genSnapshot, <String>[
+      "--snapshot-kind=app-aot-elf",
+      "--use-bare-instructions=false",
+      "--elf=$snapshot1",
+      "--loading-unit-manifest=$manifest1",
+      dill1,
+    ]);
+    var manifest = jsonDecode(await new File(manifest1).readAsString());
+    Expect.equals(2, manifest["loadingUnits"].length);
+    Expect.isTrue(await new File(deferredSnapshot1).exists());
+
+    await run(genSnapshot, <String>[
+      "--snapshot-kind=app-aot-elf",
+      "--use-bare-instructions=false",
+      "--elf=$snapshot2",
+      "--loading-unit-manifest=$manifest2",
+      dill2,
+    ]);
+    manifest = jsonDecode(await new File(manifest1).readAsString());
+    Expect.equals(2, manifest["loadingUnits"].length);
+    Expect.isTrue(await new File(deferredSnapshot2).exists());
+
+    // Works when used normally.
+    var lines = await runOutput(aotRuntime, <String>[snapshot1]);
+    Expect.listEquals(["One!"], lines);
+
+    lines = await runOutput(aotRuntime, <String>[snapshot2]);
+    Expect.listEquals(["Two!"], lines);
+
+    // Fails gracefully when mixing snapshot parts.
+    await new File(deferredSnapshot2).rename(deferredSnapshot1);
+    lines = await runError(aotRuntime, <String>[snapshot1]);
+    Expect.equals(
+        "DeferredLoadException: 'Deferred loading unit is from a different program than the main loading unit'",
+        lines[1]);
+  });
+}
diff --git a/runtime/tests/vm/dart/isolates/thread_pool_test.dart b/runtime/tests/vm/dart/isolates/thread_pool_test.dart
index ff8a7e6..7a301bc0 100644
--- a/runtime/tests/vm/dart/isolates/thread_pool_test.dart
+++ b/runtime/tests/vm/dart/isolates/thread_pool_test.dart
@@ -11,7 +11,7 @@
 import 'package:expect/expect.dart';
 
 import 'test_utils.dart';
-import '../../../../../tests/ffi_2/dylib_utils.dart';
+import '../../../../../tests/ffi/dylib_utils.dart';
 
 // This should be larger than max-new-space-size/tlab-size.
 const int threadCount = 200;
diff --git a/runtime/tests/vm/dart/null_safety_autodetection_in_kernel_compiler_test.dart b/runtime/tests/vm/dart/null_safety_autodetection_in_kernel_compiler_test.dart
index 348b154..4244601 100644
--- a/runtime/tests/vm/dart/null_safety_autodetection_in_kernel_compiler_test.dart
+++ b/runtime/tests/vm/dart/null_safety_autodetection_in_kernel_compiler_test.dart
@@ -26,7 +26,9 @@
     ''');
 
     final testDillPath = path.join(temp, 'test.dill');
-    await runGenKernel('BUILD DILL FILE', [
+    await runGenKernelWithoutStandardOptions('BUILD DILL FILE', [
+      "--platform",
+      platformDill,
       '--enable-experiment=non-nullable',
       '--output=$testDillPath',
       testScriptPath,
diff --git a/runtime/tests/vm/dart/regress_42656_opt_in_lib.dart b/runtime/tests/vm/dart/regress_42656_opt_in_lib.dart
new file mode 100644
index 0000000..44effe7
--- /dev/null
+++ b/runtime/tests/vm/dart/regress_42656_opt_in_lib.dart
@@ -0,0 +1,22 @@
+// 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.
+
+// Opted-in library for regress_42656_test.dart.
+
+import 'regress_42656_opt_out_lib.dart' show MixinB;
+
+mixin MixinA {
+  int x = 42;
+
+  @override
+  String toString() => 'MixinA';
+}
+
+abstract class C1 with MixinA {}
+
+class C2 extends C1 {}
+
+abstract class D1 with MixinB {}
+
+class D2 extends D1 {}
diff --git a/runtime/tests/vm/dart/regress_42656_opt_out_lib.dart b/runtime/tests/vm/dart/regress_42656_opt_out_lib.dart
new file mode 100644
index 0000000..59beba9
--- /dev/null
+++ b/runtime/tests/vm/dart/regress_42656_opt_out_lib.dart
@@ -0,0 +1,23 @@
+// 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.
+
+// Opted-out library for regress_42656_test.dart.
+// @dart = 2.8
+
+import 'regress_42656_opt_in_lib.dart' show MixinA;
+
+class MixinB {
+  int y = 3;
+
+  @override
+  String toString() => 'MixinB';
+}
+
+abstract class E1 with MixinA {}
+
+class E2 extends E1 {}
+
+abstract class F1 with MixinB {}
+
+class F2 extends F1 {}
diff --git a/runtime/tests/vm/dart/regress_42656_test.dart b/runtime/tests/vm/dart/regress_42656_test.dart
new file mode 100644
index 0000000..d41d4ed
--- /dev/null
+++ b/runtime/tests/vm/dart/regress_42656_test.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.
+
+// Verifies that mixin deduplication correctly handles identical anonymous
+// mixins from opt-in and opt-out libraries.
+// Regression test for https://github.com/dart-lang/sdk/issues/42656.
+
+// Requirements=nnbd-weak
+
+import 'package:expect/expect.dart';
+import 'regress_42656_opt_in_lib.dart';
+import 'regress_42656_opt_out_lib.dart';
+
+void main() {
+  Expect.equals('MixinA', C2().toString());
+  Expect.equals('MixinB', D2().toString());
+  Expect.equals('MixinA', E2().toString());
+  Expect.equals('MixinB', F2().toString());
+  Expect.isFalse(C2() == C2());
+  Expect.isFalse(D2() == D2());
+  Expect.isFalse(E2() == E2());
+  Expect.isFalse(F2() == F2());
+  Expect.equals(42, C2().x);
+  Expect.equals(3, D2().y);
+  Expect.equals(42, E2().x);
+  Expect.equals(3, F2().y);
+}
diff --git a/runtime/tests/vm/dart/run_appended_aot_snapshot_test.dart b/runtime/tests/vm/dart/run_appended_aot_snapshot_test.dart
index 78471fb..48b1b01 100644
--- a/runtime/tests/vm/dart/run_appended_aot_snapshot_test.dart
+++ b/runtime/tests/vm/dart/run_appended_aot_snapshot_test.dart
@@ -29,8 +29,8 @@
     final extraGenKernelOptions = Platform.executableArguments
         .where((arg) =>
             arg.startsWith('--enable-experiment=') ||
-            arg == '--null-safety' ||
-            arg == '--no-null-safety')
+            arg == '--sound-null-safety' ||
+            arg == '--no-sound-null-safety')
         .toList();
 
     {
diff --git a/runtime/tests/vm/dart/sdk_hash_test.dart b/runtime/tests/vm/dart/sdk_hash_test.dart
index 6b05e96..855e007 100644
--- a/runtime/tests/vm/dart/sdk_hash_test.dart
+++ b/runtime/tests/vm/dart/sdk_hash_test.dart
@@ -30,11 +30,8 @@
 
     {
       final result = await Process.run(dart, [
-        genKernel,
-        '--platform',
-        platformDill,
-        '-o',
-        dillPath,
+        '--snapshot-kind=kernel',
+        '--snapshot=$dillPath',
         sourcePath,
       ]);
       Expect.equals('', result.stderr);
@@ -57,8 +54,9 @@
       // tags (both UInt32).
       Expect.listEquals(tagComponentFile, bytes.sublist(0, 4));
       Expect.listEquals(tagBinaryFormatVersion, bytes.sublist(4, 8));
+      Expect.notEquals('0000000000', ascii.decode(bytes.sublist(8, 10)));
       // Flip the first byte in the hash:
-      bytes[8] ^= bytes[8];
+      bytes[8] = ~bytes[8];
       myFile.writeAsBytesSync(bytes);
     }
 
diff --git a/runtime/tests/vm/dart/snapshot_test_helper.dart b/runtime/tests/vm/dart/snapshot_test_helper.dart
index 974050e..00d1afe 100644
--- a/runtime/tests/vm/dart/snapshot_test_helper.dart
+++ b/runtime/tests/vm/dart/snapshot_test_helper.dart
@@ -63,12 +63,21 @@
 }
 
 Future<Result> runGenKernel(String prefix, List<String> arguments) {
-  final augmentedArguments = <String>[]
-    ..add(genKernel)
-    ..add("--platform")
-    ..add(platformDill)
-    ..addAll(arguments);
-  return runBinary(prefix, checkedInDartVM, augmentedArguments);
+  final augmentedArguments = <String>[
+    "--platform",
+    platformDill,
+    ...Platform.executableArguments.where((arg) =>
+        arg.startsWith('--enable-experiment=') ||
+        arg == '--sound-null-safety' ||
+        arg == '--no-sound-null-safety'),
+    ...arguments,
+  ];
+  return runGenKernelWithoutStandardOptions(prefix, augmentedArguments);
+}
+
+Future<Result> runGenKernelWithoutStandardOptions(
+    String prefix, List<String> arguments) {
+  return runBinary(prefix, checkedInDartVM, [genKernel, ...arguments]);
 }
 
 Future<Result> runGenSnapshot(String prefix, List<String> arguments) {
diff --git a/runtime/tests/vm/dart/splay_test.dart b/runtime/tests/vm/dart/splay_test.dart
index 30e4582..f0498a9 100644
--- a/runtime/tests/vm/dart/splay_test.dart
+++ b/runtime/tests/vm/dart/splay_test.dart
@@ -27,6 +27,7 @@
 // VMOptions=--verify_after_gc
 // VMOptions=--verify_before_gc --verify_after_gc
 // VMOptions=--verify_store_buffer
+// VMOptions=--stress_write_barrier_elimination
 
 import "dart:math";
 import 'package:benchmark_harness/benchmark_harness.dart';
diff --git a/runtime/tests/vm/dart/split_aot_kernel_generation_test.dart b/runtime/tests/vm/dart/split_aot_kernel_generation_test.dart
index 19865cd..1f8d33b 100644
--- a/runtime/tests/vm/dart/split_aot_kernel_generation_test.dart
+++ b/runtime/tests/vm/dart/split_aot_kernel_generation_test.dart
@@ -17,15 +17,7 @@
     final outputDillPath = path.join(temp, 'output.dill');
     final snapshotPath = path.join(temp, 'aot.snapshot');
 
-    final extraGenKernelOptions = Platform.executableArguments
-        .where((arg) =>
-            arg.startsWith('--enable-experiment=') ||
-            arg == '--null-safety' ||
-            arg == '--no-null-safety')
-        .toList();
-
     await runGenKernel('BUILD INTERMEDIATE DILL FILE', [
-      ...extraGenKernelOptions,
       '--no-aot',
       '--link-platform',
       '--output=$intermediateDillPath',
@@ -33,7 +25,6 @@
     ]);
 
     await runGenKernel('BUILD FINAL DILL FILE', [
-      ...extraGenKernelOptions,
       '--aot',
       '--from-dill=$intermediateDillPath',
       '--link-platform',
diff --git a/runtime/tests/vm/dart/type_casts_with_null_safety_autodetection_test.dart b/runtime/tests/vm/dart/type_casts_with_null_safety_autodetection_test.dart
index 701f409..4b38663 100644
--- a/runtime/tests/vm/dart/type_casts_with_null_safety_autodetection_test.dart
+++ b/runtime/tests/vm/dart/type_casts_with_null_safety_autodetection_test.dart
@@ -20,7 +20,7 @@
   File.fromUri(Platform.script.resolve(script)).copySync(scriptInTemp);
 
   // Do not add Platform.executableArguments into arguments to avoid passing
-  // --null-safety / --no-null-safety arguments.
+  // --sound-null-safety / --no-sound-null-safety arguments.
   final result = await runBinary("RUN $script", Platform.executable, [
     '--enable-experiment=non-nullable',
     '--deterministic',
diff --git a/runtime/tests/vm/dart/typed_data_vfp_regress_42745_test.dart b/runtime/tests/vm/dart/typed_data_vfp_regress_42745_test.dart
new file mode 100644
index 0000000..294f0ea
--- /dev/null
+++ b/runtime/tests/vm/dart/typed_data_vfp_regress_42745_test.dart
@@ -0,0 +1,17 @@
+// 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.
+// VMOptions=--no-use-vfp
+
+import 'dart:typed_data';
+
+import 'package:expect/expect.dart';
+
+final Float32List l = int.parse('1') == 1
+    ? Float32List(2)
+    : Float32List.view(Uint32List(2).buffer);
+
+main() {
+  l[int.parse('1') == 1 ? 0 : 1] = 1.2;
+  Expect.approxEquals(l[0], 1.2);
+}
diff --git a/runtime/tests/vm/dart/unboxed_many_fields_test.dart b/runtime/tests/vm/dart/unboxed_many_fields_test.dart
index 84b4f1d..79fd30f 100644
--- a/runtime/tests/vm/dart/unboxed_many_fields_test.dart
+++ b/runtime/tests/vm/dart/unboxed_many_fields_test.dart
@@ -6,17 +6,12 @@
 
 import 'package:expect/expect.dart';
 
+import 'unboxed_parameter_helper.dart';
+
 // The VM class finalizer ensures that we only unbox fields which can be
 // represented in the unboxed field bitmap in the target architecture (even when
 // cross-compiling from 64-bit to 32-bit), see `Class::CalculateFieldOffsets()`.
 
-// Make an integer that would look like an object pointer (irrespective of
-// we compile to 32-bit or 64-bit and whether we use little or big endian
-// encoding of the integer).
-int get integerFieldValue =>
-    int.parse('1') == 1 ? constIntegerFieldValue : 0x8000900180009001;
-const int constIntegerFieldValue = 0x8000000180000001;
-
 int i = 0;
 final Object objectFieldValue = Foo('i${i++}');
 
diff --git a/runtime/tests/vm/dart/unboxed_parameter_helper.dart b/runtime/tests/vm/dart/unboxed_parameter_helper.dart
index b0ee815..91ad154 100644
--- a/runtime/tests/vm/dart/unboxed_parameter_helper.dart
+++ b/runtime/tests/vm/dart/unboxed_parameter_helper.dart
@@ -11,3 +11,10 @@
   final double v = bd.getFloat64(0, Endian.host);
   return v;
 }
+
+// Make an integer that would look like an object pointer (irrespective of
+// we compile to 32-bit or 64-bit and whether we use little or big endian
+// encoding of the integer).
+int get integerFieldValue =>
+    int.parse('1') == 1 ? constIntegerFieldValue : 0x8000900180009001;
+const int constIntegerFieldValue = 0x8000000180000001;
diff --git a/runtime/tests/vm/dart/unboxed_retval_test.dart b/runtime/tests/vm/dart/unboxed_retval_test.dart
new file mode 100644
index 0000000..6132480
--- /dev/null
+++ b/runtime/tests/vm/dart/unboxed_retval_test.dart
@@ -0,0 +1,49 @@
+// 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 'package:expect/expect.dart';
+
+import 'unboxed_parameter_helper.dart';
+
+abstract class I {
+  int get value;
+  int getValue();
+}
+
+class Foo implements I {
+  int value;
+  Foo(this.value);
+  int getValue() => value;
+}
+
+class Bar implements I {
+  int get value => integerFieldValue;
+  int getValue() => value;
+}
+
+final objects = <dynamic>[Foo(integerFieldValue), Bar()];
+final tearoffs = <dynamic>[Foo(integerFieldValue).getValue, Bar().getValue];
+
+main() {
+  // Dynamic accesses to getter, method and tear-off
+  Expect.equals(objects[0].value, integerFieldValue);
+  Expect.equals(objects[0].getValue(), integerFieldValue);
+  Expect.equals(objects[1].value, integerFieldValue);
+  Expect.equals(objects[1].getValue(), integerFieldValue);
+  Expect.equals(tearoffs[0](), integerFieldValue);
+  Expect.equals(tearoffs[1](), integerFieldValue);
+
+  // Interface-based accesses to getter, method and tear-off
+  final Foo foo = objects[0] as Foo;
+  final int Function() fooGetValue = foo.getValue;
+  Expect.equals(foo.value, integerFieldValue);
+  Expect.equals(foo.getValue(), integerFieldValue);
+  Expect.equals(fooGetValue(), integerFieldValue);
+
+  final Bar bar = objects[1] as Bar;
+  final int Function() barGetValue = bar.getValue;
+  Expect.equals(bar.value, integerFieldValue);
+  Expect.equals(bar.getValue(), integerFieldValue);
+  Expect.equals(barGetValue(), integerFieldValue);
+}
diff --git a/runtime/tests/vm/dart/use_flag_test_helper.dart b/runtime/tests/vm/dart/use_flag_test_helper.dart
index e9f9737..d6854ac 100644
--- a/runtime/tests/vm/dart/use_flag_test_helper.dart
+++ b/runtime/tests/vm/dart/use_flag_test_helper.dart
@@ -146,7 +146,7 @@
   }
 }
 
-Future<Iterable<String>> runOutput(String executable, List<String> args) async {
+Future<List<String>> runOutput(String executable, List<String> args) async {
   final result = await runHelper(executable, args);
 
   if (result.exitCode != 0) {
@@ -160,7 +160,7 @@
       .toList();
 }
 
-Future<Iterable<String>> runError(String executable, List<String> args) async {
+Future<List<String>> runError(String executable, List<String> args) async {
   final result = await runHelper(executable, args);
 
   if (result.exitCode == 0) {
diff --git a/runtime/tests/vm/dart/v8_snapshot_profile_writer_test.dart b/runtime/tests/vm/dart/v8_snapshot_profile_writer_test.dart
index 7ef3be5..11abcb0 100644
--- a/runtime/tests/vm/dart/v8_snapshot_profile_writer_test.dart
+++ b/runtime/tests/vm/dart/v8_snapshot_profile_writer_test.dart
@@ -245,8 +245,8 @@
       platformDill,
       ...Platform.executableArguments.where((arg) =>
           arg.startsWith('--enable-experiment=') ||
-          arg == '--null-safety' ||
-          arg == '--no-null-safety'),
+          arg == '--sound-null-safety' ||
+          arg == '--no-sound-null-safety'),
       '-o',
       dillPath,
       _thisTestPath
diff --git a/runtime/tests/vm/dart_2/causal_stacks/utils.dart b/runtime/tests/vm/dart_2/causal_stacks/utils.dart
index a7df656..ec787cf 100644
--- a/runtime/tests/vm/dart_2/causal_stacks/utils.dart
+++ b/runtime/tests/vm/dart_2/causal_stacks/utils.dart
@@ -149,6 +149,14 @@
   return completer.future;
 }
 
+// ----
+// Scenario: Future.timeout:
+// ----
+
+Future awaitTimeout() async {
+  await (throwAsync().timeout(Duration(seconds: 1)));
+}
+
 // Helpers:
 
 // We want lines that either start with a frame index or an async gap marker.
@@ -587,6 +595,7 @@
             r'^#7      _RawReceivePortImpl._handleMessage \(.+\)$',
           ],
       debugInfoFilename);
+
   final customErrorZoneExpected = const <String>[
     r'#0      throwSync \(.*/utils.dart:16(:3)?\)$',
     r'#1      allYield3 \(.*/utils.dart:39(:3)?\)$',
@@ -638,6 +647,48 @@
             r'#14     _RawReceivePortImpl._handleMessage ',
           ],
       debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'^#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^^<asynchronous suspension>$',
+    r'^#1      awaitTimeout ',
+  ];
+  await doTestAwait(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwait ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwaitThen ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#2      doTestAwaitCatchError ',
+            r'^#3      doTestsCausal ',
+            r'^<asynchronous suspension>$',
+            r'^#4      main \(.+\)$',
+            r'^#5      _startIsolate.<anonymous closure> ',
+            r'^#6      _RawReceivePortImpl._handleMessage ',
+          ],
+      debugInfoFilename);
 }
 
 // For: --no-causal-async-stacks --no-lazy-async-stacks
@@ -957,6 +1008,25 @@
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
   await doTestAwaitCatchError(
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^#1      _RootZone.runUnary ',
+    r'^#2      _FutureListener.handleValue ',
+    r'^#3      Future._propagateToListeners.handleValueCallback ',
+    r'^#4      Future._propagateToListeners ',
+    r'^#5      Future.(_addListener|_prependListeners).<anonymous closure> ',
+    r'^#6      _microtaskLoop ',
+    r'^#7      _startMicrotaskLoop ',
+    r'^#8      _runPendingImmediateCallback ',
+    r'^#9      _RawReceivePortImpl._handleMessage ',
+  ];
+  await doTestAwait(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
 }
 
 // For: --lazy-async-stacks
@@ -1218,4 +1288,35 @@
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
   await doTestAwaitCatchError(
       customErrorZone, customErrorZoneExpected, debugInfoFilename);
+
+  final awaitTimeoutExpected = const <String>[
+    r'^#0      throwAsync \(.*/utils.dart:21(:3)?\)$',
+    r'^<asynchronous suspension>$',
+    r'^#1      Future.timeout.<anonymous closure> \(dart:async/future_impl.dart\)$',
+    r'^<asynchronous suspension>$',
+    r'^#2      awaitTimeout ',
+    r'^<asynchronous suspension>$',
+  ];
+  await doTestAwait(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#3      doTestAwait ',
+            r'^<asynchronous suspension>$',
+            r'^#4      doTestsLazy ',
+            r'^<asynchronous suspension>$',
+            r'^#5      main ',
+            r'^<asynchronous suspension>$',
+          ],
+      debugInfoFilename);
+  await doTestAwaitThen(
+      awaitTimeout,
+      awaitTimeoutExpected +
+          const <String>[
+            r'^#3      doTestAwaitThen.<anonymous closure> ',
+            r'^<asynchronous suspension>$',
+          ],
+      debugInfoFilename);
+  await doTestAwaitCatchError(
+      awaitTimeout, awaitTimeoutExpected + const <String>[], debugInfoFilename);
 }
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_1.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_1.dart
new file mode 100644
index 0000000..35b3947
--- /dev/null
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_1.dart
@@ -0,0 +1,10 @@
+// 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 "incompatible_loading_unit_1_deferred.dart" deferred as lib;
+
+main() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_1_deferred.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_1_deferred.dart
new file mode 100644
index 0000000..c0b9a03
--- /dev/null
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_1_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+void foo() {
+  print("One!");
+}
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_2.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_2.dart
new file mode 100644
index 0000000..7a352f6c
--- /dev/null
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_2.dart
@@ -0,0 +1,10 @@
+// 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 "incompatible_loading_unit_2_deferred.dart" deferred as lib;
+
+main() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_2_deferred.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_2_deferred.dart
new file mode 100644
index 0000000..2dc3b7a
--- /dev/null
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_2_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+void foo() {
+  print("Two!");
+}
diff --git a/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart b/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart
new file mode 100644
index 0000000..8231f00
--- /dev/null
+++ b/runtime/tests/vm/dart_2/incompatible_loading_unit_test.dart
@@ -0,0 +1,97 @@
+// 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:convert";
+import "dart:io";
+
+import "package:expect/expect.dart";
+import "package:path/path.dart" as path;
+
+import "use_flag_test_helper.dart";
+
+main(List<String> args) async {
+  if (!isAOTRuntime) {
+    return; // Running in JIT: AOT binaries not available.
+  }
+
+  if (Platform.isAndroid) {
+    return; // SDK tree not available on the test device.
+  }
+
+  // These are the tools we need to be available to run on a given platform:
+  if (!File(platformDill).existsSync()) {
+    throw "Cannot run test as $platformDill does not exist";
+  }
+  if (!await testExecutable(genSnapshot)) {
+    throw "Cannot run test as $genSnapshot not available";
+  }
+
+  await withTempDir("incompatible-loading-unit-test", (String tempDir) async {
+    final source1 = path.join(
+        sdkDir, "runtime/tests/vm/dart_2/incompatible_loading_unit_1.dart");
+    final source2 = path.join(
+        sdkDir, "runtime/tests/vm/dart_2/incompatible_loading_unit_2.dart");
+    final dill1 = path.join(tempDir, "incompatible_loading_unit_1.dart.dill");
+    final dill2 = path.join(tempDir, "incompatible_loading_unit_2.dart.dill");
+    final snapshot1 = path.join(tempDir, "incompatible_loading_unit_1.so");
+    final snapshot2 = path.join(tempDir, "incompatible_loading_unit_2.so");
+    final manifest1 = path.join(tempDir, "incompatible_loading_unit_1.txt");
+    final manifest2 = path.join(tempDir, "incompatible_loading_unit_2.txt");
+    final deferredSnapshot1 = snapshot1 + "-2.part.so";
+    final deferredSnapshot2 = snapshot2 + "-2.part.so";
+
+    // Compile source to kernel.
+    await run(genKernel, <String>[
+      "--aot",
+      "--platform=$platformDill",
+      "-o",
+      dill1,
+      source1,
+    ]);
+    await run(genKernel, <String>[
+      "--aot",
+      "--platform=$platformDill",
+      "-o",
+      dill2,
+      source2,
+    ]);
+
+    // Compile kernel to ELF.
+    await run(genSnapshot, <String>[
+      "--snapshot-kind=app-aot-elf",
+      "--use-bare-instructions=false",
+      "--elf=$snapshot1",
+      "--loading-unit-manifest=$manifest1",
+      dill1,
+    ]);
+    var manifest = jsonDecode(await new File(manifest1).readAsString());
+    Expect.equals(2, manifest["loadingUnits"].length);
+    Expect.isTrue(await new File(deferredSnapshot1).exists());
+
+    await run(genSnapshot, <String>[
+      "--snapshot-kind=app-aot-elf",
+      "--use-bare-instructions=false",
+      "--elf=$snapshot2",
+      "--loading-unit-manifest=$manifest2",
+      dill2,
+    ]);
+    manifest = jsonDecode(await new File(manifest1).readAsString());
+    Expect.equals(2, manifest["loadingUnits"].length);
+    Expect.isTrue(await new File(deferredSnapshot2).exists());
+
+    // Works when used normally.
+    var lines = await runOutput(aotRuntime, <String>[snapshot1]);
+    Expect.listEquals(["One!"], lines);
+
+    lines = await runOutput(aotRuntime, <String>[snapshot2]);
+    Expect.listEquals(["Two!"], lines);
+
+    // Fails gracefully when mixing snapshot parts.
+    await new File(deferredSnapshot2).rename(deferredSnapshot1);
+    lines = await runError(aotRuntime, <String>[snapshot1]);
+    Expect.equals(
+        "DeferredLoadException: 'Deferred loading unit is from a different program than the main loading unit'",
+        lines[1]);
+  });
+}
diff --git a/runtime/tests/vm/dart_2/null_safety_autodetection_in_kernel_compiler_test.dart b/runtime/tests/vm/dart_2/null_safety_autodetection_in_kernel_compiler_test.dart
index 348b154..4244601 100644
--- a/runtime/tests/vm/dart_2/null_safety_autodetection_in_kernel_compiler_test.dart
+++ b/runtime/tests/vm/dart_2/null_safety_autodetection_in_kernel_compiler_test.dart
@@ -26,7 +26,9 @@
     ''');
 
     final testDillPath = path.join(temp, 'test.dill');
-    await runGenKernel('BUILD DILL FILE', [
+    await runGenKernelWithoutStandardOptions('BUILD DILL FILE', [
+      "--platform",
+      platformDill,
       '--enable-experiment=non-nullable',
       '--output=$testDillPath',
       testScriptPath,
diff --git a/runtime/tests/vm/dart_2/sdk_hash_test.dart b/runtime/tests/vm/dart_2/sdk_hash_test.dart
index 6b05e96..b6f166c 100644
--- a/runtime/tests/vm/dart_2/sdk_hash_test.dart
+++ b/runtime/tests/vm/dart_2/sdk_hash_test.dart
@@ -30,11 +30,8 @@
 
     {
       final result = await Process.run(dart, [
-        genKernel,
-        '--platform',
-        platformDill,
-        '-o',
-        dillPath,
+        '--snapshot-kind=kernel',
+        '--snapshot=$dillPath',
         sourcePath,
       ]);
       Expect.equals('', result.stderr);
@@ -57,8 +54,9 @@
       // tags (both UInt32).
       Expect.listEquals(tagComponentFile, bytes.sublist(0, 4));
       Expect.listEquals(tagBinaryFormatVersion, bytes.sublist(4, 8));
+      Expect.notEquals('0000000000', ascii.decode(bytes.sublist(8, 18)));
       // Flip the first byte in the hash:
-      bytes[8] ^= bytes[8];
+      bytes[8] = ~bytes[8];
       myFile.writeAsBytesSync(bytes);
     }
 
diff --git a/runtime/tests/vm/dart_2/snapshot_test_helper.dart b/runtime/tests/vm/dart_2/snapshot_test_helper.dart
index b2754d0..56472f1 100644
--- a/runtime/tests/vm/dart_2/snapshot_test_helper.dart
+++ b/runtime/tests/vm/dart_2/snapshot_test_helper.dart
@@ -63,12 +63,21 @@
 }
 
 Future<Result> runGenKernel(String prefix, List<String> arguments) {
-  final augmentedArguments = <String>[]
-    ..add(genKernel)
-    ..add("--platform")
-    ..add(platformDill)
-    ..addAll(arguments);
-  return runBinary(prefix, checkedInDartVM, augmentedArguments);
+  final augmentedArguments = <String>[
+    "--platform",
+    platformDill,
+    ...Platform.executableArguments.where((arg) =>
+        arg.startsWith('--enable-experiment=') ||
+        arg == '--sound-null-safety' ||
+        arg == '--no-sound-null-safety'),
+    ...arguments,
+  ];
+  return runGenKernelWithoutStandardOptions(prefix, augmentedArguments);
+}
+
+Future<Result> runGenKernelWithoutStandardOptions(
+    String prefix, List<String> arguments) {
+  return runBinary(prefix, checkedInDartVM, [genKernel, ...arguments]);
 }
 
 Future<Result> runGenSnapshot(String prefix, List<String> arguments) {
diff --git a/runtime/tests/vm/dart_2/splay_test.dart b/runtime/tests/vm/dart_2/splay_test.dart
index eae1cbb..1fec471 100644
--- a/runtime/tests/vm/dart_2/splay_test.dart
+++ b/runtime/tests/vm/dart_2/splay_test.dart
@@ -27,6 +27,7 @@
 // VMOptions=--verify_after_gc
 // VMOptions=--verify_before_gc --verify_after_gc
 // VMOptions=--verify_store_buffer
+// VMOptions=--stress_write_barrier_elimination
 
 import "dart:math";
 import 'package:benchmark_harness/benchmark_harness.dart';
diff --git a/runtime/tests/vm/dart_2/split_aot_kernel_generation_test.dart b/runtime/tests/vm/dart_2/split_aot_kernel_generation_test.dart
index 19865cd..1f8d33b 100644
--- a/runtime/tests/vm/dart_2/split_aot_kernel_generation_test.dart
+++ b/runtime/tests/vm/dart_2/split_aot_kernel_generation_test.dart
@@ -17,15 +17,7 @@
     final outputDillPath = path.join(temp, 'output.dill');
     final snapshotPath = path.join(temp, 'aot.snapshot');
 
-    final extraGenKernelOptions = Platform.executableArguments
-        .where((arg) =>
-            arg.startsWith('--enable-experiment=') ||
-            arg == '--null-safety' ||
-            arg == '--no-null-safety')
-        .toList();
-
     await runGenKernel('BUILD INTERMEDIATE DILL FILE', [
-      ...extraGenKernelOptions,
       '--no-aot',
       '--link-platform',
       '--output=$intermediateDillPath',
@@ -33,7 +25,6 @@
     ]);
 
     await runGenKernel('BUILD FINAL DILL FILE', [
-      ...extraGenKernelOptions,
       '--aot',
       '--from-dill=$intermediateDillPath',
       '--link-platform',
diff --git a/runtime/tests/vm/dart_2/typed_data_vfp_regress_42745_test.dart b/runtime/tests/vm/dart_2/typed_data_vfp_regress_42745_test.dart
new file mode 100644
index 0000000..294f0ea
--- /dev/null
+++ b/runtime/tests/vm/dart_2/typed_data_vfp_regress_42745_test.dart
@@ -0,0 +1,17 @@
+// 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.
+// VMOptions=--no-use-vfp
+
+import 'dart:typed_data';
+
+import 'package:expect/expect.dart';
+
+final Float32List l = int.parse('1') == 1
+    ? Float32List(2)
+    : Float32List.view(Uint32List(2).buffer);
+
+main() {
+  l[int.parse('1') == 1 ? 0 : 1] = 1.2;
+  Expect.approxEquals(l[0], 1.2);
+}
diff --git a/runtime/tests/vm/dart_2/unboxed_many_fields_test.dart b/runtime/tests/vm/dart_2/unboxed_many_fields_test.dart
index 84b4f1d..79fd30f 100644
--- a/runtime/tests/vm/dart_2/unboxed_many_fields_test.dart
+++ b/runtime/tests/vm/dart_2/unboxed_many_fields_test.dart
@@ -6,17 +6,12 @@
 
 import 'package:expect/expect.dart';
 
+import 'unboxed_parameter_helper.dart';
+
 // The VM class finalizer ensures that we only unbox fields which can be
 // represented in the unboxed field bitmap in the target architecture (even when
 // cross-compiling from 64-bit to 32-bit), see `Class::CalculateFieldOffsets()`.
 
-// Make an integer that would look like an object pointer (irrespective of
-// we compile to 32-bit or 64-bit and whether we use little or big endian
-// encoding of the integer).
-int get integerFieldValue =>
-    int.parse('1') == 1 ? constIntegerFieldValue : 0x8000900180009001;
-const int constIntegerFieldValue = 0x8000000180000001;
-
 int i = 0;
 final Object objectFieldValue = Foo('i${i++}');
 
diff --git a/runtime/tests/vm/dart_2/unboxed_parameter_helper.dart b/runtime/tests/vm/dart_2/unboxed_parameter_helper.dart
index b0ee815..91ad154 100644
--- a/runtime/tests/vm/dart_2/unboxed_parameter_helper.dart
+++ b/runtime/tests/vm/dart_2/unboxed_parameter_helper.dart
@@ -11,3 +11,10 @@
   final double v = bd.getFloat64(0, Endian.host);
   return v;
 }
+
+// Make an integer that would look like an object pointer (irrespective of
+// we compile to 32-bit or 64-bit and whether we use little or big endian
+// encoding of the integer).
+int get integerFieldValue =>
+    int.parse('1') == 1 ? constIntegerFieldValue : 0x8000900180009001;
+const int constIntegerFieldValue = 0x8000000180000001;
diff --git a/runtime/tests/vm/dart_2/unboxed_retval_test.dart b/runtime/tests/vm/dart_2/unboxed_retval_test.dart
new file mode 100644
index 0000000..6132480
--- /dev/null
+++ b/runtime/tests/vm/dart_2/unboxed_retval_test.dart
@@ -0,0 +1,49 @@
+// 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 'package:expect/expect.dart';
+
+import 'unboxed_parameter_helper.dart';
+
+abstract class I {
+  int get value;
+  int getValue();
+}
+
+class Foo implements I {
+  int value;
+  Foo(this.value);
+  int getValue() => value;
+}
+
+class Bar implements I {
+  int get value => integerFieldValue;
+  int getValue() => value;
+}
+
+final objects = <dynamic>[Foo(integerFieldValue), Bar()];
+final tearoffs = <dynamic>[Foo(integerFieldValue).getValue, Bar().getValue];
+
+main() {
+  // Dynamic accesses to getter, method and tear-off
+  Expect.equals(objects[0].value, integerFieldValue);
+  Expect.equals(objects[0].getValue(), integerFieldValue);
+  Expect.equals(objects[1].value, integerFieldValue);
+  Expect.equals(objects[1].getValue(), integerFieldValue);
+  Expect.equals(tearoffs[0](), integerFieldValue);
+  Expect.equals(tearoffs[1](), integerFieldValue);
+
+  // Interface-based accesses to getter, method and tear-off
+  final Foo foo = objects[0] as Foo;
+  final int Function() fooGetValue = foo.getValue;
+  Expect.equals(foo.value, integerFieldValue);
+  Expect.equals(foo.getValue(), integerFieldValue);
+  Expect.equals(fooGetValue(), integerFieldValue);
+
+  final Bar bar = objects[1] as Bar;
+  final int Function() barGetValue = bar.getValue;
+  Expect.equals(bar.value, integerFieldValue);
+  Expect.equals(bar.getValue(), integerFieldValue);
+  Expect.equals(barGetValue(), integerFieldValue);
+}
diff --git a/runtime/tests/vm/dart_2/use_flag_test_helper.dart b/runtime/tests/vm/dart_2/use_flag_test_helper.dart
index fe9c511..24f0687 100644
--- a/runtime/tests/vm/dart_2/use_flag_test_helper.dart
+++ b/runtime/tests/vm/dart_2/use_flag_test_helper.dart
@@ -144,7 +144,7 @@
   }
 }
 
-Future<Iterable<String>> runOutput(String executable, List<String> args) async {
+Future<List<String>> runOutput(String executable, List<String> args) async {
   final result = await runHelper(executable, args);
 
   if (result.exitCode != 0) {
@@ -158,7 +158,7 @@
       .toList();
 }
 
-Future<Iterable<String>> runError(String executable, List<String> args) async {
+Future<List<String>> runError(String executable, List<String> args) async {
   final result = await runHelper(executable, args);
 
   if (result.exitCode == 0) {
diff --git a/runtime/tests/vm/vm.status b/runtime/tests/vm/vm.status
index 0ab4172..e18c310 100644
--- a/runtime/tests/vm/vm.status
+++ b/runtime/tests/vm/vm.status
@@ -127,6 +127,10 @@
 dart/redirection_type_shuffling_test: SkipByDesign # Imports dart:mirrors
 dart_2/redirection_type_shuffling_test: SkipByDesign # Imports dart:mirrors
 
+[ $system == android ]
+dart/sdk_hash_test: SkipByDesign # The test doesn't know location of cross-platform gen_snapshot
+dart_2/sdk_hash_test: SkipByDesign # The test doesn't know location of cross-platform gen_snapshot
+
 [ $system == fuchsia ]
 cc/CorelibIsolateStartup: Skip # OOM crash can bring down the OS.
 cc/Read: Fail # TODO(zra): Investigate, ../../dart/runtime/bin/file_test.cc: 34: error: expected: !file->WriteByte(1)
diff --git a/runtime/vm/BUILD.gn b/runtime/vm/BUILD.gn
index 1716f3d..3c042b1 100644
--- a/runtime/vm/BUILD.gn
+++ b/runtime/vm/BUILD.gn
@@ -74,7 +74,11 @@
   if (is_fuchsia) {
     if (using_fuchsia_gn_sdk) {
       extra_deps = [
-        "$fuchsia_sdk_root/fidl/fuchsia.deprecatedtimezone",
+        "$fuchsia_sdk_root/fidl/fuchsia.intl",
+        "$fuchsia_sdk_root/pkg/async",
+        "$fuchsia_sdk_root/pkg/async-default",
+        "$fuchsia_sdk_root/pkg/async-loop",
+        "$fuchsia_sdk_root/pkg/async-loop-default",
         "$fuchsia_sdk_root/pkg/inspect",
         "$fuchsia_sdk_root/pkg/inspect_service_cpp",
         "$fuchsia_sdk_root/pkg/sys_cpp",
@@ -83,7 +87,9 @@
       ]
     } else if (using_fuchsia_sdk) {
       extra_deps = [
-        "$fuchsia_sdk_root/fidl:fuchsia.deprecatedtimezone",
+        "$fuchsia_sdk_root/fidl:fuchsia.intl",
+        "$fuchsia_sdk_root/pkg:async-loop",
+        "$fuchsia_sdk_root/pkg:async-loop-default",
         "$fuchsia_sdk_root/pkg:inspect",
         "$fuchsia_sdk_root/pkg:inspect_service_cpp",
         "$fuchsia_sdk_root/pkg:sys_cpp",
@@ -92,9 +98,7 @@
       ]
     } else {
       extra_deps = [
-        # TODO(US-399): Remove time_service specific code when it is no longer
-        # necessary.
-        "//sdk/fidl/fuchsia.deprecatedtimezone",
+        "//sdk/fidl/fuchsia.intl",
         "//sdk/lib/sys/cpp",
         "//sdk/lib/sys/inspect/cpp",
         "//zircon/public/lib/fbl",
diff --git a/runtime/vm/benchmark_test.cc b/runtime/vm/benchmark_test.cc
index 633a3f2..1d00e78 100644
--- a/runtime/vm/benchmark_test.cc
+++ b/runtime/vm/benchmark_test.cc
@@ -359,7 +359,7 @@
 // Measure compile of all kernel Service(CFE) functions.
 //
 BENCHMARK(KernelServiceCompileAll) {
-  if (FLAG_null_safety == kNullSafetyOptionStrong) {
+  if (FLAG_sound_null_safety == kNullSafetyOptionStrong) {
     // TODO(bkonyi): remove this check when we build the CFE in strong mode.
     return;
   }
diff --git a/runtime/vm/bootstrap.cc b/runtime/vm/bootstrap.cc
index 57445f7..774a398 100644
--- a/runtime/vm/bootstrap.cc
+++ b/runtime/vm/bootstrap.cc
@@ -142,6 +142,10 @@
     library = Library::LookupLibrary(thread, dart_builtin);
     isolate->object_store()->set_builtin_library(library);
 
+    if (FLAG_precompiled_mode) {
+      loader.ReadLoadingUnits();
+    }
+
     return Error::null();
   }
 
diff --git a/runtime/vm/bootstrap_natives.h b/runtime/vm/bootstrap_natives.h
index a805629..00f2e1c 100644
--- a/runtime/vm/bootstrap_natives.h
+++ b/runtime/vm/bootstrap_natives.h
@@ -33,6 +33,8 @@
   V(Type_equality, 2)                                                          \
   V(LibraryPrefix_isLoaded, 1)                                                 \
   V(LibraryPrefix_setLoaded, 1)                                                \
+  V(LibraryPrefix_loadingUnit, 1)                                              \
+  V(LibraryPrefix_issueLoad, 1)                                                \
   V(Identical_comparison, 2)                                                   \
   V(Integer_bitAndFromInteger, 2)                                              \
   V(Integer_bitOrFromInteger, 2)                                               \
diff --git a/runtime/vm/class_finalizer.cc b/runtime/vm/class_finalizer.cc
index 7531621..f535c91 100644
--- a/runtime/vm/class_finalizer.cc
+++ b/runtime/vm/class_finalizer.cc
@@ -59,8 +59,8 @@
   }
 }
 
-void AddSuperType(const AbstractType& type,
-                  GrowableArray<intptr_t>* finalized_super_classes) {
+static void AddSuperType(const AbstractType& type,
+                         GrowableArray<intptr_t>* finalized_super_classes) {
   ASSERT(type.HasTypeClass());
   ASSERT(!type.IsDynamicType());
   if (type.IsObjectType()) {
@@ -1151,14 +1151,6 @@
   }
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
-  if (cls.is_patch()) {
-    // The fields and functions of a patch class are copied to the
-    // patched class after parsing. There is nothing to finalize.
-    ASSERT(Array::Handle(cls.functions()).Length() == 0);
-    ASSERT(Array::Handle(cls.fields()).Length() == 0);
-    cls.set_is_finalized();
-    return;
-  }
   // Ensure super class is finalized.
   const Class& super = Class::Handle(cls.SuperClass());
   if (!super.IsNull()) {
@@ -1170,33 +1162,69 @@
   // Mark as loaded and finalized.
   cls.Finalize();
   FinalizeMemberTypes(cls);
-  // Run additional checks after all types are finalized.
-  if (FLAG_use_cha_deopt) {
-    GrowableArray<intptr_t> cids;
-    CollectFinalizedSuperClasses(cls, &cids);
-    CollectImmediateSuperInterfaces(cls, &cids);
-    RemoveCHAOptimizedCode(cls, cids);
-  }
-
-  if (FLAG_use_cha_deopt) {
-    Zone* zone = thread->zone();
-    ClassTable* class_table = thread->isolate()->class_table();
-    auto& interface_class = Class::Handle(zone);
-
-    // We scan every interface this [cls] implements and invalidate all CHA code
-    // which depends on knowing the implementors of that interface.
-    GrowableArray<intptr_t> cids;
-    InterfaceFinder finder(zone, class_table, &cids);
-    finder.FindAllInterfaces(cls);
-    for (intptr_t j = 0; j < cids.length(); ++j) {
-      interface_class = class_table->At(cids[j]);
-      interface_class.DisableCHAImplementorUsers();
-    }
-  }
 
   if (cls.is_enum_class()) {
     AllocateEnumValues(cls);
   }
+
+  // The rest of finalization for non-top-level class has to be done with
+  // stopped mutators. It will be done by AllocateFinalizeClass. before new
+  // instance of a class is created in GetAllocationStubForClass.
+  if (cls.IsTopLevel()) {
+    cls.set_is_allocate_finalized();
+  }
+}
+
+ErrorPtr ClassFinalizer::AllocateFinalizeClass(const Class& cls) {
+  ASSERT(cls.is_finalized());
+  if (cls.is_allocate_finalized()) {
+    return Error::null();
+  }
+
+  Thread* thread = Thread::Current();
+  HANDLESCOPE(thread);
+
+  if (FLAG_trace_class_finalization) {
+    THR_Print("Allocate finalize %s\n", cls.ToCString());
+  }
+
+#if defined(SUPPORT_TIMELINE)
+  TimelineBeginEndScope tbes(thread, Timeline::GetCompilerStream(),
+                             "AllocateFinalizeClass");
+  if (tbes.enabled()) {
+    tbes.SetNumArguments(1);
+    tbes.CopyArgument(0, "class", cls.ToCString());
+  }
+#endif  // defined(SUPPORT_TIMELINE)
+
+  // Run additional checks after all types are finalized.
+  if (FLAG_use_cha_deopt && !cls.IsTopLevel()) {
+    {
+      GrowableArray<intptr_t> cids;
+      CollectFinalizedSuperClasses(cls, &cids);
+      CollectImmediateSuperInterfaces(cls, &cids);
+      RemoveCHAOptimizedCode(cls, cids);
+    }
+
+    Zone* zone = thread->zone();
+    ClassTable* class_table = thread->isolate()->class_table();
+    auto& interface_class = Class::Handle(zone);
+
+    // We scan every interface this [cls] implements and invalidate all CHA
+    // code which depends on knowing the implementors of that interface.
+    {
+      GrowableArray<intptr_t> cids;
+      InterfaceFinder finder(zone, class_table, &cids);
+      finder.FindAllInterfaces(cls);
+      for (intptr_t j = 0; j < cids.length(); ++j) {
+        interface_class = class_table->At(cids[j]);
+        interface_class.DisableCHAImplementorUsers();
+      }
+    }
+  }
+
+  cls.set_is_allocate_finalized();
+  return Error::null();
 }
 
 ErrorPtr ClassFinalizer::LoadClassMembers(const Class& cls) {
@@ -1426,7 +1454,7 @@
       continue;
     }
     cls = table->At(cid);
-    if (cls.is_patch() || !cls.is_declaration_loaded()) {
+    if (!cls.is_declaration_loaded()) {
       continue;
     }
     if (cls.SuperClass() == I->object_store()->object_class()) {
@@ -1490,7 +1518,12 @@
   void VisitObject(ObjectPtr obj) {
     if (obj->IsClass()) {
       ClassPtr cls = Class::RawCast(obj);
-      cls->ptr()->id_ = Map(cls->ptr()->id_);
+      const classid_t old_cid = cls->ptr()->id_;
+      if (ClassTable::IsTopLevelCid(old_cid)) {
+        // We don't remap cids of top level classes.
+        return;
+      }
+      cls->ptr()->id_ = Map(old_cid);
     } else if (obj->IsField()) {
       FieldPtr field = Field::RawCast(obj);
       field->ptr()->guarded_cid_ = Map(field->ptr()->guarded_cid_);
diff --git a/runtime/vm/class_finalizer.h b/runtime/vm/class_finalizer.h
index a087ac5..3fd0baf 100644
--- a/runtime/vm/class_finalizer.h
+++ b/runtime/vm/class_finalizer.h
@@ -62,8 +62,11 @@
   // Register class in the lists of direct subclasses and direct implementors.
   static void RegisterClassInHierarchy(Zone* zone, const Class& cls);
 
-  // Finalize the class including its fields and functions.
+  // Ensures members of the class are loaded, class layout is finalized and size
+  // registered in class table.
   static void FinalizeClass(const Class& cls);
+  // Makes class instantiatable and usable by generated code.
+  static ErrorPtr AllocateFinalizeClass(const Class& cls);
 
   // Completes loading of the class, this populates the function
   // and fields of the class.
diff --git a/runtime/vm/class_id.h b/runtime/vm/class_id.h
index b71fa12..f943cc4 100644
--- a/runtime/vm/class_id.h
+++ b/runtime/vm/class_id.h
@@ -47,6 +47,7 @@
   V(ICData)                                                                    \
   V(MegamorphicCache)                                                          \
   V(SubtypeTestCache)                                                          \
+  V(LoadingUnit)                                                               \
   V(Error)                                                                     \
   V(ApiError)                                                                  \
   V(LanguageError)                                                             \
diff --git a/runtime/vm/class_table.cc b/runtime/vm/class_table.cc
index c458acb..582ff56 100644
--- a/runtime/vm/class_table.cc
+++ b/runtime/vm/class_table.cc
@@ -4,6 +4,7 @@
 
 #include "vm/class_table.h"
 
+#include <limits>
 #include <memory>
 
 #include "platform/atomic.h"
@@ -81,7 +82,10 @@
 ClassTable::ClassTable(SharedClassTable* shared_class_table)
     : top_(kNumPredefinedCids),
       capacity_(0),
-      table_(NULL),
+      tlc_top_(0),
+      tlc_capacity_(0),
+      table_(nullptr),
+      tlc_table_(nullptr),
       old_class_tables_(new MallocGrowableArray<ClassPtr*>()),
       shared_class_table_(shared_class_table) {
   if (Dart::vm_isolate() == NULL) {
@@ -122,6 +126,7 @@
     delete old_class_tables_;
   }
   free(table_.load());
+  free(tlc_table_.load());
 }
 
 void ClassTable::AddOldTable(ClassPtr* old_class_table) {
@@ -149,7 +154,8 @@
 void ClassTable::Register(const Class& cls) {
   ASSERT(Thread::Current()->IsMutatorThread());
 
-  const intptr_t index = cls.id();
+  const classid_t cid = cls.id();
+  ASSERT(!IsTopLevelCid(cid));
 
   // During the transition period we would like [SharedClassTable] to operate in
   // parallel to [ClassTable].
@@ -158,12 +164,12 @@
       cls.is_abstract() ? 0 : Class::host_instance_size(cls.raw());
 
   const intptr_t expected_cid =
-      shared_class_table_->Register(index, instance_size);
+      shared_class_table_->Register(cid, instance_size);
 
-  if (index != kIllegalCid) {
-    ASSERT(index > 0 && index < kNumPredefinedCids && index < top_);
-    ASSERT(table_.load()[index] == nullptr);
-    table_.load()[index] = cls.raw();
+  if (cid != kIllegalCid) {
+    ASSERT(cid > 0 && cid < kNumPredefinedCids && cid < top_);
+    ASSERT(table_.load()[cid] == nullptr);
+    table_.load()[cid] = cls.raw();
   } else {
     if (top_ == capacity_) {
       const intptr_t new_capacity = capacity_ + kCapacityIncrement;
@@ -177,6 +183,28 @@
   ASSERT(expected_cid == cls.id());
 }
 
+void ClassTable::RegisterTopLevel(const Class& cls) {
+  if (top_ >= std::numeric_limits<classid_t>::max()) {
+    FATAL1("Fatal error in ClassTable::RegisterTopLevel: invalid index %" Pd
+           "\n",
+           top_);
+  }
+
+  ASSERT(Thread::Current()->IsMutatorThread());
+
+  const intptr_t index = cls.id();
+  ASSERT(index == kIllegalCid);
+
+  if (tlc_top_ == tlc_capacity_) {
+    const intptr_t new_capacity = tlc_capacity_ + kCapacityIncrement;
+    GrowTopLevel(new_capacity);
+  }
+  ASSERT(tlc_top_ < tlc_capacity_);
+  cls.set_id(ClassTable::CidFromTopLevelIndex(tlc_top_));
+  tlc_table_.load()[tlc_top_] = cls.raw();
+  tlc_top_++;  // Increment next index.
+}
+
 intptr_t SharedClassTable::Register(intptr_t index, intptr_t size) {
   if (!Class::is_valid_id(top_)) {
     FATAL1("Fatal error in SharedClassTable::Register: invalid index %" Pd "\n",
@@ -202,6 +230,11 @@
 }
 
 void ClassTable::AllocateIndex(intptr_t index) {
+  if (IsTopLevelCid(index)) {
+    AllocateTopLevelIndex(index);
+    return;
+  }
+
   // This is called by a snapshot reader.
   shared_class_table_->AllocateIndex(index);
   ASSERT(Class::is_valid_id(index));
@@ -220,6 +253,21 @@
   ASSERT(capacity_ == shared_class_table_->capacity_);
 }
 
+void ClassTable::AllocateTopLevelIndex(intptr_t cid) {
+  ASSERT(IsTopLevelCid(cid));
+  const intptr_t tlc_index = IndexFromTopLevelCid(cid);
+
+  if (tlc_index >= tlc_capacity_) {
+    const intptr_t new_capacity = tlc_index + kCapacityIncrement;
+    GrowTopLevel(new_capacity);
+  }
+
+  ASSERT(tlc_table_.load()[tlc_index] == nullptr);
+  if (tlc_index >= tlc_top_) {
+    tlc_top_ = tlc_index + 1;
+  }
+}
+
 void ClassTable::Grow(intptr_t new_capacity) {
   ASSERT(new_capacity > capacity_);
 
@@ -243,6 +291,29 @@
   capacity_ = new_capacity;
 }
 
+void ClassTable::GrowTopLevel(intptr_t new_capacity) {
+  ASSERT(new_capacity > tlc_capacity_);
+
+  auto old_table = tlc_table_.load();
+  auto new_table = static_cast<ClassPtr*>(
+      malloc(new_capacity * sizeof(ClassPtr)));  // NOLINT
+  intptr_t i;
+  for (i = 0; i < tlc_capacity_; i++) {
+    // Don't use memmove, which changes this from a relaxed atomic operation
+    // to a non-atomic operation.
+    new_table[i] = old_table[i];
+  }
+  for (; i < new_capacity; i++) {
+    // Don't use memset, which changes this from a relaxed atomic operation
+    // to a non-atomic operation.
+    new_table[i] = 0;
+  }
+  old_class_tables_->Add(old_table);
+
+  tlc_table_.store(new_table);
+  tlc_capacity_ = new_capacity;
+}
+
 void SharedClassTable::AllocateIndex(intptr_t index) {
   // This is called by a snapshot reader.
   ASSERT(Class::is_valid_id(index));
@@ -320,9 +391,16 @@
   capacity_ = new_capacity;
 }
 
-void ClassTable::Unregister(intptr_t index) {
-  shared_class_table_->Unregister(index);
-  table_.load()[index] = nullptr;
+void ClassTable::Unregister(intptr_t cid) {
+  ASSERT(!IsTopLevelCid(cid));
+  shared_class_table_->Unregister(cid);
+  table_.load()[cid] = nullptr;
+}
+
+void ClassTable::UnregisterTopLevel(intptr_t cid) {
+  ASSERT(IsTopLevelCid(cid));
+  const intptr_t tlc_index = IndexFromTopLevelCid(cid);
+  tlc_table_.load()[tlc_index] = nullptr;
 }
 
 void SharedClassTable::Unregister(intptr_t index) {
@@ -376,6 +454,12 @@
     ObjectPtr* to = reinterpret_cast<ObjectPtr*>(&table[top_ - 1]);
     visitor->VisitPointers(from, to);
   }
+  if (tlc_top_ != 0) {
+    auto* tlc_table = tlc_table_.load();
+    ObjectPtr* from = reinterpret_cast<ObjectPtr*>(&tlc_table[0]);
+    ObjectPtr* to = reinterpret_cast<ObjectPtr*>(&tlc_table[tlc_top_ - 1]);
+    visitor->VisitPointers(from, to);
+  }
   visitor->clear_gc_root_type();
 }
 
@@ -420,13 +504,18 @@
   }
 }
 
-void ClassTable::SetAt(intptr_t index, ClassPtr raw_cls) {
+void ClassTable::SetAt(intptr_t cid, ClassPtr raw_cls) {
+  if (IsTopLevelCid(cid)) {
+    tlc_table_.load()[IndexFromTopLevelCid(cid)] = raw_cls;
+    return;
+  }
+
   // This is called by snapshot reader and class finalizer.
-  ASSERT(index < capacity_);
+  ASSERT(cid < capacity_);
   const intptr_t size =
       raw_cls == nullptr ? 0 : Class::host_instance_size(raw_cls);
-  shared_class_table_->SetSizeAt(index, size);
-  table_.load()[index] = raw_cls;
+  shared_class_table_->SetSizeAt(cid, size);
+  table_.load()[cid] = raw_cls;
 }
 
 #ifndef PRODUCT
diff --git a/runtime/vm/class_table.h b/runtime/vm/class_table.h
index 6bb42d2..8068db1 100644
--- a/runtime/vm/class_table.h
+++ b/runtime/vm/class_table.h
@@ -123,11 +123,7 @@
     ASSERT(cid < top_);
     trace_allocation_table_.load()[cid] = trace ? 1 : 0;
   }
-  bool TraceAllocationFor(intptr_t cid) {
-    ASSERT(cid > 0);
-    ASSERT(cid < top_);
-    return trace_allocation_table_.load()[cid] != 0;
-  }
+  bool TraceAllocationFor(intptr_t cid);
 #endif  // !defined(PRODUCT)
 
   void CopyBeforeHotReload(intptr_t** copy, intptr_t* copy_num_cids) {
@@ -258,20 +254,34 @@
 
   SharedClassTable* shared_class_table() const { return shared_class_table_; }
 
-  void CopyBeforeHotReload(ClassPtr** copy, intptr_t* copy_num_cids) {
+  void CopyBeforeHotReload(ClassPtr** copy,
+                           ClassPtr** tlc_copy,
+                           intptr_t* copy_num_cids,
+                           intptr_t* copy_num_tlc_cids) {
     // The [IsolateReloadContext] will need to maintain a copy of the old class
     // table until instances have been morphed.
     const intptr_t num_cids = NumCids();
-    const intptr_t bytes = sizeof(ClassPtr) * num_cids;
-    auto class_table = static_cast<ClassPtr*>(malloc(bytes));
+    const intptr_t num_tlc_cids = NumTopLevelCids();
+    auto class_table =
+        static_cast<ClassPtr*>(malloc(sizeof(ClassPtr) * num_cids));
+    auto tlc_class_table =
+        static_cast<ClassPtr*>(malloc(sizeof(ClassPtr) * num_tlc_cids));
+
+    // Don't use memmove, which changes this from a relaxed atomic operation
+    // to a non-atomic operation.
     auto table = table_.load();
     for (intptr_t i = 0; i < num_cids; i++) {
-      // Don't use memmove, which changes this from a relaxed atomic operation
-      // to a non-atomic operation.
       class_table[i] = table[i];
     }
-    *copy_num_cids = num_cids;
+    auto tlc_table = tlc_table_.load();
+    for (intptr_t i = 0; i < num_tlc_cids; i++) {
+      tlc_class_table[i] = tlc_table[i];
+    }
+
     *copy = class_table;
+    *tlc_copy = tlc_class_table;
+    *copy_num_cids = num_cids;
+    *copy_num_tlc_cids = num_tlc_cids;
   }
 
   void ResetBeforeHotReload() {
@@ -283,64 +293,79 @@
   }
 
   void ResetAfterHotReload(ClassPtr* old_table,
+                           ClassPtr* old_tlc_table,
                            intptr_t num_old_cids,
+                           intptr_t num_old_tlc_cids,
                            bool is_rollback) {
     // The [IsolateReloadContext] is no longer source-of-truth for GC after we
     // return, so we restore size information for all classes.
     if (is_rollback) {
-      SetNumCids(num_old_cids);
+      SetNumCids(num_old_cids, num_old_tlc_cids);
+
+      // Don't use memmove, which changes this from a relaxed atomic operation
+      // to a non-atomic operation.
       auto table = table_.load();
       for (intptr_t i = 0; i < num_old_cids; i++) {
-        // Don't use memmove, which changes this from a relaxed atomic operation
-        // to a non-atomic operation.
         table[i] = old_table[i];
       }
+      auto tlc_table = tlc_table_.load();
+      for (intptr_t i = 0; i < num_old_tlc_cids; i++) {
+        tlc_table[i] = old_tlc_table[i];
+      }
     } else {
       CopySizesFromClassObjects();
     }
 
-    // Can't free this table immediately as another thread (e.g., concurrent
+    // Can't free these tables immediately as another thread (e.g., concurrent
     // marker or sweeper) may be between loading the table pointer and loading
     // the table element. The table will be freed at the next major GC or
     // isolate shutdown.
     AddOldTable(old_table);
+    AddOldTable(old_tlc_table);
   }
 
   // Thread-safe.
-  ClassPtr At(intptr_t index) const {
-    ASSERT(IsValidIndex(index));
-    return table_.load()[index];
+  ClassPtr At(intptr_t cid) const {
+    ASSERT(IsValidIndex(cid));
+    if (IsTopLevelCid(cid)) {
+      return tlc_table_.load()[IndexFromTopLevelCid(cid)];
+    }
+    return table_.load()[cid];
   }
 
   intptr_t SizeAt(intptr_t index) const {
+    if (IsTopLevelCid(index)) {
+      return 0;
+    }
     return shared_class_table_->SizeAt(index);
   }
 
   void SetAt(intptr_t index, ClassPtr raw_cls);
 
-  bool IsValidIndex(intptr_t index) const {
-    return shared_class_table_->IsValidIndex(index);
+  bool IsValidIndex(intptr_t cid) const {
+    if (IsTopLevelCid(cid)) {
+      return IndexFromTopLevelCid(cid) < tlc_top_;
+    }
+    return shared_class_table_->IsValidIndex(cid);
   }
 
-  bool HasValidClassAt(intptr_t index) const {
-    ASSERT(IsValidIndex(index));
-    return table_.load()[index] != nullptr;
+  bool HasValidClassAt(intptr_t cid) const {
+    ASSERT(IsValidIndex(cid));
+    if (IsTopLevelCid(cid)) {
+      return tlc_table_.load()[IndexFromTopLevelCid(cid)] != nullptr;
+    }
+    return table_.load()[cid] != nullptr;
   }
 
   intptr_t NumCids() const { return shared_class_table_->NumCids(); }
+  intptr_t NumTopLevelCids() const { return tlc_top_; }
   intptr_t Capacity() const { return shared_class_table_->Capacity(); }
 
-  // Used to drop recently added classes.
-  void SetNumCids(intptr_t num_cids) {
-    shared_class_table_->SetNumCids(num_cids);
-
-    ASSERT(num_cids <= top_);
-    top_ = num_cids;
-  }
-
   void Register(const Class& cls);
+  void RegisterTopLevel(const Class& cls);
   void AllocateIndex(intptr_t index);
   void Unregister(intptr_t index);
+  void UnregisterTopLevel(intptr_t index);
 
   void Remap(intptr_t* old_to_new_cids);
 
@@ -374,6 +399,17 @@
   // Deallocates table copies. Do not call during concurrent access to table.
   void FreeOldTables();
 
+  static bool IsTopLevelCid(intptr_t cid) { return cid >= kTopLevelCidOffset; }
+
+  static intptr_t IndexFromTopLevelCid(intptr_t cid) {
+    ASSERT(IsTopLevelCid(cid));
+    return cid - kTopLevelCidOffset;
+  }
+
+  static intptr_t CidFromTopLevelIndex(intptr_t index) {
+    return kTopLevelCidOffset + index;
+  }
+
  private:
   friend class GCMarker;
   friend class MarkingWeakVisitor;
@@ -387,25 +423,55 @@
   static const int kInitialCapacity = SharedClassTable::kInitialCapacity;
   static const int kCapacityIncrement = SharedClassTable::kCapacityIncrement;
 
+  static const intptr_t kTopLevelCidOffset = (1 << 16);
+
   void AddOldTable(ClassPtr* old_table);
+  void AllocateTopLevelIndex(intptr_t index);
 
   void Grow(intptr_t index);
+  void GrowTopLevel(intptr_t index);
 
   ClassPtr* table() { return table_.load(); }
   void set_table(ClassPtr* table);
 
+  // Used to drop recently added classes.
+  void SetNumCids(intptr_t num_cids, intptr_t num_tlc_cids) {
+    shared_class_table_->SetNumCids(num_cids);
+
+    ASSERT(num_cids <= top_);
+    top_ = num_cids;
+
+    ASSERT(num_tlc_cids <= tlc_top_);
+    tlc_top_ = num_tlc_cids;
+  }
+
   intptr_t top_;
   intptr_t capacity_;
 
+  intptr_t tlc_top_;
+  intptr_t tlc_capacity_;
+
   // Copy-on-write is used for table_, with old copies stored in
   // old_class_tables_.
   AcqRelAtomic<ClassPtr*> table_;
+  AcqRelAtomic<ClassPtr*> tlc_table_;
   MallocGrowableArray<ClassPtr*>* old_class_tables_;
   SharedClassTable* shared_class_table_;
 
   DISALLOW_COPY_AND_ASSIGN(ClassTable);
 };
 
+#if !defined(PRODUCT)
+DART_FORCE_INLINE bool SharedClassTable::TraceAllocationFor(intptr_t cid) {
+  ASSERT(cid > 0);
+  if (ClassTable::IsTopLevelCid(cid)) {
+    return false;
+  }
+  ASSERT(cid < top_);
+  return trace_allocation_table_.load()[cid] != 0;
+}
+#endif  // !defined(PRODUCT)
+
 }  // namespace dart
 
 #endif  // RUNTIME_VM_CLASS_TABLE_H_
diff --git a/runtime/vm/clustered_snapshot.cc b/runtime/vm/clustered_snapshot.cc
index c9e1319..637cf2e 100644
--- a/runtime/vm/clustered_snapshot.cc
+++ b/runtime/vm/clustered_snapshot.cc
@@ -155,8 +155,10 @@
     ClassPtr cls = Class::RawCast(object);
     intptr_t class_id = cls->ptr()->id_;
 
-    // Classes expected to be dropped by the precompiler should not be traced.
-    ASSERT(class_id != kIllegalCid);
+    if (class_id == kIllegalCid) {
+      // Classes expected to be dropped by the precompiler should not be traced.
+      s->UnexpectedObject(cls, "Class with illegal cid");
+    }
     if (class_id < kNumPredefinedCids) {
       // These classes are allocated by Object::Init or Object::InitOnce, so the
       // deserializer must find them in the class table instead of allocating
@@ -224,7 +226,7 @@
     s->Write<uint32_t>(cls->ptr()->state_bits_);
 
     // In AOT, the bitmap of unboxed fields should also be serialized
-    if (FLAG_precompiled_mode) {
+    if (FLAG_precompiled_mode && !ClassTable::IsTopLevelCid(class_id)) {
       s->WriteUnsigned64(
           CalculateTargetUnboxedFieldsBitmap(s, class_id).Value());
     }
@@ -391,7 +393,7 @@
       table->AllocateIndex(class_id);
       table->SetAt(class_id, cls);
 
-      if (FLAG_precompiled_mode) {
+      if (FLAG_precompiled_mode && !ClassTable::IsTopLevelCid(class_id)) {
         const UnboxedFieldBitmap unboxed_fields_map(d->ReadUnsigned64());
         shared_class_table->SetUnboxedFieldsMapAt(class_id, unboxed_fields_map);
       }
@@ -1522,6 +1524,8 @@
     CodePtr code = Code::RawCast(object);
     objects_.Add(code);
 
+    s->InCurrentLoadingUnit(code, /*record*/ true);
+
     if (!(s->kind() == Snapshot::kFullAOT && FLAG_use_bare_instructions)) {
       s->Push(code->ptr()->object_pool_);
     }
@@ -1529,10 +1533,14 @@
     s->Push(code->ptr()->exception_handlers_);
     s->Push(code->ptr()->pc_descriptors_);
     s->Push(code->ptr()->catch_entry_);
-    s->Push(code->ptr()->compressed_stackmaps_);
+    if (s->InCurrentLoadingUnit(code->ptr()->compressed_stackmaps_)) {
+      s->Push(code->ptr()->compressed_stackmaps_);
+    }
     if (!FLAG_precompiled_mode || !FLAG_dwarf_stack_traces_mode) {
       s->Push(code->ptr()->inlined_id_to_function_);
-      s->Push(code->ptr()->code_source_map_);
+      if (s->InCurrentLoadingUnit(code->ptr()->code_source_map_)) {
+        s->Push(code->ptr()->code_source_map_);
+      }
     }
     if (s->kind() == Snapshot::kFullJIT) {
       s->Push(code->ptr()->deopt_info_array_);
@@ -1626,13 +1634,21 @@
       WriteField(code, exception_handlers_);
       WriteField(code, pc_descriptors_);
       WriteField(code, catch_entry_);
-      WriteField(code, compressed_stackmaps_);
+      if (s->InCurrentLoadingUnit(code->ptr()->compressed_stackmaps_)) {
+        WriteField(code, compressed_stackmaps_);
+      } else {
+        WriteFieldValue(compressed_stackmaps_, CompressedStackMaps::null());
+      }
       if (FLAG_precompiled_mode && FLAG_dwarf_stack_traces_mode) {
         WriteFieldValue(inlined_id_to_function_, Array::null());
         WriteFieldValue(code_source_map_, CodeSourceMap::null());
       } else {
         WriteField(code, inlined_id_to_function_);
-        WriteField(code, code_source_map_);
+        if (s->InCurrentLoadingUnit(code->ptr()->code_source_map_)) {
+          WriteField(code, code_source_map_);
+        } else {
+          WriteFieldValue(code_source_map_, CodeSourceMap::null());
+        }
       }
       if (kind == Snapshot::kFullJIT) {
         WriteField(code, deopt_info_array_);
@@ -2927,6 +2943,73 @@
 };
 
 #if !defined(DART_PRECOMPILED_RUNTIME)
+class LoadingUnitSerializationCluster : public SerializationCluster {
+ public:
+  LoadingUnitSerializationCluster() : SerializationCluster("LoadingUnit") {}
+  ~LoadingUnitSerializationCluster() {}
+
+  void Trace(Serializer* s, ObjectPtr object) {
+    LoadingUnitPtr unit = LoadingUnit::RawCast(object);
+    objects_.Add(unit);
+    s->Push(unit->ptr()->parent_);
+  }
+
+  void WriteAlloc(Serializer* s) {
+    s->WriteCid(kLoadingUnitCid);
+    const intptr_t count = objects_.length();
+    s->WriteUnsigned(count);
+    for (intptr_t i = 0; i < count; i++) {
+      LoadingUnitPtr unit = objects_[i];
+      s->AssignRef(unit);
+    }
+  }
+
+  void WriteFill(Serializer* s) {
+    const intptr_t count = objects_.length();
+    for (intptr_t i = 0; i < count; i++) {
+      LoadingUnitPtr unit = objects_[i];
+      AutoTraceObject(unit);
+      WriteField(unit, parent_);
+      s->Write<int32_t>(unit->ptr()->id_);
+    }
+  }
+
+ private:
+  GrowableArray<LoadingUnitPtr> objects_;
+};
+#endif  // !DART_PRECOMPILED_RUNTIME
+
+class LoadingUnitDeserializationCluster : public DeserializationCluster {
+ public:
+  LoadingUnitDeserializationCluster() {}
+  ~LoadingUnitDeserializationCluster() {}
+
+  void ReadAlloc(Deserializer* d) {
+    start_index_ = d->next_index();
+    PageSpace* old_space = d->heap()->old_space();
+    const intptr_t count = d->ReadUnsigned();
+    for (intptr_t i = 0; i < count; i++) {
+      d->AssignRef(
+          AllocateUninitialized(old_space, LoadingUnit::InstanceSize()));
+    }
+    stop_index_ = d->next_index();
+  }
+
+  void ReadFill(Deserializer* d) {
+    for (intptr_t id = start_index_; id < stop_index_; id++) {
+      LoadingUnitPtr unit = static_cast<LoadingUnitPtr>(d->Ref(id));
+      Deserializer::InitializeHeader(unit, kLoadingUnitCid,
+                                     LoadingUnit::InstanceSize());
+      unit->ptr()->parent_ = static_cast<LoadingUnitPtr>(d->ReadRef());
+      unit->ptr()->base_objects_ = Array::null();
+      unit->ptr()->id_ = d->Read<int32_t>();
+      unit->ptr()->loaded_ = false;
+      unit->ptr()->load_outstanding_ = false;
+    }
+  }
+};
+
+#if !defined(DART_PRECOMPILED_RUNTIME)
 class LanguageErrorSerializationCluster : public SerializationCluster {
  public:
   LanguageErrorSerializationCluster() : SerializationCluster("LanguageError") {}
@@ -4794,6 +4877,7 @@
       clusters_by_cid_(NULL),
       stack_(),
       num_cids_(0),
+      num_tlc_cids_(0),
       num_base_objects_(0),
       num_written_objects_(0),
       next_ref_index_(1),
@@ -4811,6 +4895,7 @@
 #endif
 {
   num_cids_ = thread->isolate()->class_table()->NumCids();
+  num_tlc_cids_ = thread->isolate()->class_table()->NumTopLevelCids();
   clusters_by_cid_ = new SerializationCluster*[num_cids_];
   for (intptr_t i = 0; i < num_cids_; i++) {
     clusters_by_cid_[i] = NULL;
@@ -5009,7 +5094,7 @@
 
   switch (cid) {
     case kClassCid:
-      return new (Z) ClassSerializationCluster(num_cids_);
+      return new (Z) ClassSerializationCluster(num_cids_ + num_tlc_cids_);
     case kTypeArgumentsCid:
       return new (Z) TypeArgumentsSerializationCluster();
     case kPatchClassCid:
@@ -5058,6 +5143,8 @@
       return new (Z) MegamorphicCacheSerializationCluster();
     case kSubtypeTestCacheCid:
       return new (Z) SubtypeTestCacheSerializationCluster();
+    case kLoadingUnitCid:
+      return new (Z) LoadingUnitSerializationCluster();
     case kLanguageErrorCid:
       return new (Z) LanguageErrorSerializationCluster();
     case kUnhandledExceptionCid:
@@ -5110,6 +5197,24 @@
 #endif  // !DART_PRECOMPILED_RUNTIME
 }
 
+bool Serializer::InCurrentLoadingUnit(ObjectPtr obj, bool record) {
+  if (loading_units_ == nullptr) return true;
+
+  intptr_t unit_id = heap_->GetLoadingUnit(obj);
+  if (unit_id == WeakTable::kNoValue) {
+    // Not found in early assignment. Conservatively choose the root.
+    // TODO(41974): Are these always type testing stubs?
+    unit_id = LoadingUnit::kRootId;
+  }
+  if (unit_id != current_loading_unit_id_) {
+    if (record) {
+      (*loading_units_)[unit_id]->AddDeferredObject(obj);
+    }
+    return false;
+  }
+  return true;
+}
+
 #if !defined(DART_PRECOMPILED_RUNTIME)
 void Serializer::WriteInstructions(InstructionsPtr instr,
                                    uint32_t unchecked_offset,
@@ -5117,6 +5222,11 @@
                                    intptr_t index) {
   ASSERT(code != Code::null());
 
+  if (!InCurrentLoadingUnit(code)) {
+    Write<uint32_t>(0);
+    return;
+  }
+
   const intptr_t offset = image_writer_->GetTextOffsetFor(instr, code);
 #if defined(DART_PRECOMPILER)
   if (profile_writer_ != nullptr) {
@@ -5331,44 +5441,6 @@
     Trace(stack_.RemoveLast());
   }
 
-  intptr_t code_order_length = 0;
-#if defined(DART_PRECOMPILER) && !defined(TARGET_ARCH_IA32)
-  if ((kind_ == Snapshot::kFullAOT) && FLAG_use_bare_instructions) {
-    auto code_objects =
-        static_cast<CodeSerializationCluster*>(clusters_by_cid_[kCodeCid])
-            ->discovered_objects();
-
-    GrowableArray<ImageWriterCommand> writer_commands;
-    RelocateCodeObjects(vm_, code_objects, &writer_commands);
-    image_writer_->PrepareForSerialization(&writer_commands);
-
-    // We permute the code objects in the [CodeSerializationCluster] so they
-    // will arrive in the order in which the [Code]'s instructions will be in
-    // memory at AOT runtime.
-    GrowableArray<CodePtr> code_order;
-    RawCodeSet code_set;
-    for (auto& command : writer_commands) {
-      if (command.op == ImageWriterCommand::InsertInstructionOfCode) {
-        CodePtr code = command.insert_instruction_of_code.code;
-        ASSERT(!code_set.HasKey(code));
-        code_set.Insert(code);
-        code_order.Add(code);
-        code_order_length++;
-      }
-    }
-    for (CodePtr code : *code_objects) {
-      if (!code_set.HasKey(code)) {
-        code_set.Insert(code);
-        code_order.Add(code);
-      }
-    }
-    RELEASE_ASSERT(code_order.length() == code_objects->length());
-    for (intptr_t i = 0; i < code_objects->length(); ++i) {
-      (*code_objects)[i] = code_order[i];
-    }
-  }
-#endif  // defined(DART_PRECOMPILER) && !defined(TARGET_ARCH_IA32)
-
   intptr_t num_clusters = 0;
   for (intptr_t cid = 1; cid < num_cids_; cid++) {
     SerializationCluster* cluster = clusters_by_cid_[cid];
@@ -5377,6 +5449,8 @@
     }
   }
 
+  intptr_t code_order_length = PrepareCodeOrder();
+
 #if defined(DART_PRECOMPILER)
   // Before we finalize the count of written objects, pick canonical versions
   // of WSR objects that will be serialized and then remove any non-serialized
@@ -5417,6 +5491,12 @@
   // We should have assigned a ref to every object we pushed.
   ASSERT((next_ref_index_ - 1) == num_objects);
 
+  if (loading_units_ != nullptr) {
+    LoadingUnitSerializationData* unit =
+        (*loading_units_)[current_loading_unit_id_];
+    unit->set_num_objects(num_objects);
+  }
+
 #if defined(DART_PRECOMPILER)
   // When writing snapshot profile, we want to retain some of the program
   // structure information (e.g. information about libraries, classes and
@@ -5437,6 +5517,48 @@
     }
   }
 }
+
+intptr_t Serializer::PrepareCodeOrder() {
+  intptr_t code_order_length = 0;
+#if defined(DART_PRECOMPILER) && !defined(TARGET_ARCH_IA32)
+  if ((kind_ == Snapshot::kFullAOT) && FLAG_use_bare_instructions) {
+    auto code_objects =
+        static_cast<CodeSerializationCluster*>(clusters_by_cid_[kCodeCid])
+            ->discovered_objects();
+
+    GrowableArray<ImageWriterCommand> writer_commands;
+    RelocateCodeObjects(vm_, code_objects, &writer_commands);
+    image_writer_->PrepareForSerialization(&writer_commands);
+
+    // We permute the code objects in the x[CodeSerializationCluster] so they
+    // will arrive in the order in which the [Code]'s instructions will be in
+    // memory at AOT runtime.
+    GrowableArray<CodePtr> code_order;
+    RawCodeSet code_set;
+    for (auto& command : writer_commands) {
+      if (command.op == ImageWriterCommand::InsertInstructionOfCode) {
+        CodePtr code = command.insert_instruction_of_code.code;
+        ASSERT(!code_set.HasKey(code));
+        code_set.Insert(code);
+        code_order.Add(code);
+        code_order_length++;
+      }
+    }
+    for (CodePtr code : *code_objects) {
+      if (!code_set.HasKey(code)) {
+        code_set.Insert(code);
+        code_order.Add(code);
+      }
+    }
+    RELEASE_ASSERT(code_order.length() == code_objects->length());
+    for (intptr_t i = 0; i < code_objects->length(); ++i) {
+      (*code_objects)[i] = code_order[i];
+    }
+  }
+#endif  // defined(DART_PRECOMPILER) && !defined(TARGET_ARCH_IA32)
+  return code_order_length;
+}
+
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
 #if defined(DART_PRECOMPILER) || defined(DART_PRECOMPILED_RUNTIME)
@@ -5562,7 +5684,8 @@
 void Serializer::PrintSnapshotSizes() {
 #if !defined(DART_PRECOMPILED_RUNTIME)
   if (FLAG_print_snapshot_sizes_verbose) {
-    OS::PrintErr("             Cluster   Objs     Size Fraction Cumulative\n");
+    OS::PrintErr(
+        "                  Cluster   Objs     Size Fraction Cumulative\n");
     GrowableArray<SerializationCluster*> clusters_by_size;
     for (intptr_t cid = 1; cid < num_cids_; cid++) {
       SerializationCluster* cluster = clusters_by_cid_[cid];
@@ -5606,7 +5729,7 @@
       SerializationCluster* cluster = clusters_by_size[i];
       double fraction = static_cast<double>(cluster->size()) / total_size;
       cumulative_fraction += fraction;
-      OS::PrintErr("%20s %6" Pd " %8" Pd " %lf %lf\n", cluster->name(),
+      OS::PrintErr("%25s %6" Pd " %8" Pd " %lf %lf\n", cluster->name(),
                    cluster->num_objects(), cluster->size(), fraction,
                    cumulative_fraction);
     }
@@ -5731,6 +5854,8 @@
 static const char* kObjectStoreFieldNames[] = {
 #define DECLARE_OBJECT_STORE_FIELD(Type, Name) #Name,
     OBJECT_STORE_FIELD_LIST(DECLARE_OBJECT_STORE_FIELD,
+                            DECLARE_OBJECT_STORE_FIELD,
+                            DECLARE_OBJECT_STORE_FIELD,
                             DECLARE_OBJECT_STORE_FIELD)
 #undef DECLARE_OBJECT_STORE_FIELD
 };
@@ -5747,8 +5872,8 @@
     }
   } else {
     // Base objects carried over from WriteVMSnapshot.
-    num_base_objects_ += num_base_objects;
-    next_ref_index_ += num_base_objects;
+    num_base_objects_ = num_base_objects;
+    next_ref_index_ = num_base_objects + 1;
   }
 
   // Push roots.
@@ -5819,7 +5944,56 @@
 
   PrintSnapshotSizes();
 
-  heap_->ResetObjectIdTable();
+  // TODO(rmacnak): This also carries over object ids from loading units that
+  // aren't dominators. It would be more robust to remember the written objects
+  // in each loading and re-assign objects when setting up the base objects.
+  // Then a reference to a non-dominating object would produce an error instead
+  // of corruption.
+  if (kind() != Snapshot::kFullAOT) {
+    heap_->ResetObjectIdTable();
+  }
+}
+
+void Serializer::WriteUnitSnapshot(LoadingUnitSerializationData* unit,
+                                   uint32_t program_hash) {
+  Write(program_hash);
+
+  NoSafepointScope no_safepoint;
+
+  intptr_t num_base_objects = unit->parent()->num_objects();
+  ASSERT(num_base_objects != 0);
+  num_base_objects_ = num_base_objects;
+  next_ref_index_ = num_base_objects + 1;
+
+  intptr_t num_deferred_objects = unit->deferred_objects()->length();
+  for (intptr_t i = 0; i < num_deferred_objects; i++) {
+    const Object* deferred_object = (*unit->deferred_objects())[i];
+    ASSERT(deferred_object->IsCode());
+    CodePtr code = static_cast<CodePtr>(deferred_object->raw());
+    Push(code->ptr()->compressed_stackmaps_);
+    Push(code->ptr()->code_source_map_);
+  }
+
+  Serialize();
+
+  Write(num_deferred_objects);
+  for (intptr_t i = 0; i < num_deferred_objects; i++) {
+    const Object* deferred_object = (*unit->deferred_objects())[i];
+    ASSERT(deferred_object->IsCode());
+    CodePtr code = static_cast<CodePtr>(deferred_object->raw());
+    WriteRootRef(code, "deferred-code");
+    WriteInstructions(code->ptr()->instructions_,
+                      code->ptr()->unchecked_offset_, code, -1);
+    WriteRootRef(code->ptr()->compressed_stackmaps_, "deferred-code");
+    WriteRootRef(code->ptr()->code_source_map_, "deferred-code");
+  }
+
+  FlushBytesWrittenToRoot();
+  object_currently_writing_.stream_start_ = stream_.Position();
+
+#if defined(DEBUG)
+  Write<int32_t>(kSectionMarker);
+#endif
 }
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
@@ -5934,6 +6108,8 @@
       return new (Z) MegamorphicCacheDeserializationCluster();
     case kSubtypeTestCacheCid:
       return new (Z) SubtypeTestCacheDeserializationCluster();
+    case kLoadingUnitCid:
+      return new (Z) LoadingUnitDeserializationCluster();
     case kLanguageErrorCid:
       return new (Z) LanguageErrorDeserializationCluster();
     case kUnhandledExceptionCid:
@@ -6222,8 +6398,15 @@
 #endif
 
   const uint32_t offset = Read<uint32_t>();
-  InstructionsPtr instr = image_reader_->GetInstructionsAt(offset);
-  uint32_t unchecked_offset = ReadUnsigned();
+  InstructionsPtr instr;
+  uint32_t unchecked_offset;
+  if (offset == 0) {
+    instr = StubCode::NotLoaded().instructions();
+    unchecked_offset = 0;
+  } else {
+    instr = image_reader_->GetInstructionsAt(offset);
+    unchecked_offset = ReadUnsigned();
+  }
 
   code->ptr()->instructions_ = instr;
 #if defined(DART_PRECOMPILED_RUNTIME)
@@ -6456,12 +6639,86 @@
   for (intptr_t i = 0; i < num_clusters_; i++) {
     clusters_[i]->PostLoad(refs, kind_, zone_);
   }
+  const Array& units = Array::Handle(isolate->object_store()->loading_units());
+  if (!units.IsNull()) {
+    LoadingUnit& unit = LoadingUnit::Handle();
+    unit ^= units.At(LoadingUnit::kRootId);
+    unit.set_base_objects(refs);
+  }
   isolate->isolate_object_store()->PreallocateObjects();
 
   // Setup native resolver for bootstrap impl.
   Bootstrap::SetupNativeResolver();
 }
 
+ApiErrorPtr Deserializer::ReadUnitSnapshot(const LoadingUnit& unit) {
+  Array& units =
+      Array::Handle(thread()->isolate()->object_store()->loading_units());
+  uint32_t main_program_hash = Smi::Value(Smi::RawCast(units.At(0)));
+  uint32_t unit_program_hash = Read<uint32_t>();
+  if (main_program_hash != unit_program_hash) {
+    return ApiError::New(
+        String::Handle(String::New("Deferred loading unit is from a different "
+                                   "program than the main loading unit")));
+  }
+
+  Array& refs = Array::Handle();
+  Prepare();
+
+  {
+    NoSafepointScope no_safepoint;
+    HeapLocker hl(thread(), heap_->old_space());
+
+    // N.B.: Skipping index 0 because ref 0 is illegal.
+    const Array& base_objects =
+        Array::Handle(LoadingUnit::Handle(unit.parent()).base_objects());
+    for (intptr_t i = 1; i < base_objects.Length(); i++) {
+      AddBaseObject(base_objects.At(i));
+    }
+
+    Deserialize();
+
+    intptr_t num_deferred = Read<intptr_t>();
+    for (intptr_t i = 0; i < num_deferred; i++) {
+      CodePtr code = static_cast<CodePtr>(ReadRef());
+      ReadInstructions(code, -1, -1);
+      if (code->ptr()->owner_->IsFunction()) {
+        FunctionPtr func = static_cast<FunctionPtr>(code->ptr()->owner_);
+        uword entry_point = code->ptr()->entry_point_;
+        ASSERT(entry_point != 0);
+        func->ptr()->entry_point_ = entry_point;
+        uword unchecked_entry_point = code->ptr()->unchecked_entry_point_;
+        ASSERT(unchecked_entry_point != 0);
+        func->ptr()->unchecked_entry_point_ = unchecked_entry_point;
+      }
+      code->ptr()->compressed_stackmaps_ =
+          static_cast<CompressedStackMapsPtr>(ReadRef());
+      code->ptr()->code_source_map_ = static_cast<CodeSourceMapPtr>(ReadRef());
+    }
+
+#if defined(DEBUG)
+    int32_t section_marker = Read<int32_t>();
+    ASSERT(section_marker == kSectionMarker);
+#endif
+
+    refs = refs_;
+    refs_ = NULL;
+  }
+
+#if defined(DEBUG)
+  Isolate* isolate = thread()->isolate();
+  isolate->ValidateClassTable();
+  isolate->heap()->Verify();
+#endif
+
+  for (intptr_t i = 0; i < num_clusters_; i++) {
+    clusters_[i]->PostLoad(refs, kind_, zone_);
+  }
+  unit.set_base_objects(refs);
+
+  return ApiError::null();
+}
+
 #if !defined(DART_PRECOMPILED_RUNTIME)
 FullSnapshotWriter::FullSnapshotWriter(Snapshot::Kind kind,
                                        uint8_t** vm_snapshot_data_buffer,
@@ -6536,12 +6793,16 @@
   return num_objects;
 }
 
-void FullSnapshotWriter::WriteProgramSnapshot(intptr_t num_base_objects) {
+void FullSnapshotWriter::WriteProgramSnapshot(
+    intptr_t num_base_objects,
+    GrowableArray<LoadingUnitSerializationData*>* units) {
   TIMELINE_DURATION(thread(), Isolate, "WriteProgramSnapshot");
 
   Serializer serializer(thread(), kind_, isolate_snapshot_data_buffer_, alloc_,
                         kInitialSize, isolate_image_writer_, /*vm=*/false,
                         profile_writer_);
+  serializer.set_loading_units(units);
+  serializer.set_current_loading_unit_id(LoadingUnit::kRootId);
   ObjectStore* object_store = isolate()->object_store();
   ASSERT(object_store != NULL);
 
@@ -6577,7 +6838,43 @@
   isolate_snapshot_size_ = serializer.bytes_written();
 }
 
-void FullSnapshotWriter::WriteFullSnapshot() {
+void FullSnapshotWriter::WriteUnitSnapshot(
+    GrowableArray<LoadingUnitSerializationData*>* units,
+    LoadingUnitSerializationData* unit,
+    uint32_t program_hash) {
+  TIMELINE_DURATION(thread(), Isolate, "WriteUnitSnapshot");
+
+  Serializer serializer(thread(), kind_, isolate_snapshot_data_buffer_, alloc_,
+                        kInitialSize, isolate_image_writer_, /*vm=*/false,
+                        profile_writer_);
+  serializer.set_loading_units(units);
+  serializer.set_current_loading_unit_id(unit->id());
+
+  serializer.ReserveHeader();
+  serializer.WriteVersionAndFeatures(false);
+  serializer.WriteUnitSnapshot(unit, program_hash);
+  serializer.FillHeader(serializer.kind());
+  clustered_isolate_size_ = serializer.bytes_written();
+
+  if (Snapshot::IncludesCode(kind_)) {
+    isolate_image_writer_->SetProfileWriter(profile_writer_);
+    isolate_image_writer_->Write(serializer.stream(), false);
+#if defined(DART_PRECOMPILER)
+    isolate_image_writer_->DumpStatistics();
+#endif
+
+    mapped_data_size_ += isolate_image_writer_->data_size();
+    mapped_text_size_ += isolate_image_writer_->text_size();
+    isolate_image_writer_->ResetOffsets();
+    isolate_image_writer_->ClearProfileWriter();
+  }
+
+  // The clustered part + the direct mapped data part.
+  isolate_snapshot_size_ = serializer.bytes_written();
+}
+
+void FullSnapshotWriter::WriteFullSnapshot(
+    GrowableArray<LoadingUnitSerializationData*>* data) {
   intptr_t num_base_objects;
   if (vm_snapshot_data_buffer() != NULL) {
     num_base_objects = WriteVMSnapshot();
@@ -6587,7 +6884,7 @@
   }
 
   if (isolate_snapshot_data_buffer() != NULL) {
-    WriteProgramSnapshot(num_base_objects);
+    WriteProgramSnapshot(num_base_objects, data);
   }
 
   if (FLAG_print_snapshot_sizes) {
@@ -6714,14 +7011,14 @@
 #undef SET_FLAG
 
 #if defined(DART_PRECOMPILED_RUNTIME)
-    if (FLAG_null_safety == kNullSafetyOptionUnspecified) {
+    if (FLAG_sound_null_safety == kNullSafetyOptionUnspecified) {
       if (strncmp(cursor, "null-safety", end - cursor) == 0) {
-        FLAG_null_safety = kNullSafetyOptionStrong;
+        FLAG_sound_null_safety = kNullSafetyOptionStrong;
         cursor = end;
         continue;
       }
       if (strncmp(cursor, "no-null-safety", end - cursor) == 0) {
-        FLAG_null_safety = kNullSafetyOptionWeak;
+        FLAG_sound_null_safety = kNullSafetyOptionWeak;
         cursor = end;
         continue;
       }
@@ -6846,6 +7143,49 @@
   auto object_store = thread_->isolate()->object_store();
   deserializer.ReadProgramSnapshot(object_store);
 
+  PatchGlobalObjectPool();
+  InitializeBSS();
+
+  return ApiError::null();
+}
+
+ApiErrorPtr FullSnapshotReader::ReadUnitSnapshot(const LoadingUnit& unit) {
+  SnapshotHeaderReader header_reader(kind_, buffer_, size_);
+  intptr_t offset = 0;
+  char* error =
+      header_reader.VerifyVersionAndFeatures(thread_->isolate(), &offset);
+  if (error != nullptr) {
+    return ConvertToApiError(error);
+  }
+
+  Deserializer deserializer(thread_, kind_, buffer_, size_, data_image_,
+                            instructions_image_, offset);
+  ApiErrorPtr api_error = deserializer.VerifyImageAlignment();
+  if (api_error != ApiError::null()) {
+    return api_error;
+  }
+
+  if (Snapshot::IncludesCode(kind_)) {
+    ASSERT(data_image_ != NULL);
+    thread_->isolate()->SetupImagePage(data_image_,
+                                       /* is_executable */ false);
+    ASSERT(instructions_image_ != NULL);
+    thread_->isolate()->SetupImagePage(instructions_image_,
+                                       /* is_executable */ true);
+  }
+
+  api_error = deserializer.ReadUnitSnapshot(unit);
+  if (api_error != ApiError::null()) {
+    return api_error;
+  }
+
+  PatchGlobalObjectPool();
+  InitializeBSS();
+
+  return ApiError::null();
+}
+
+void FullSnapshotReader::PatchGlobalObjectPool() {
 #if defined(DART_PRECOMPILED_RUNTIME)
   if (FLAG_use_bare_instructions) {
     // By default, every switchable call site will put (ic_data, code) into the
@@ -6859,7 +7199,8 @@
     // existing UnlinkedCall entries in the object pool to be it's entrypoint.
     auto zone = thread_->zone();
     const auto& pool = ObjectPool::Handle(
-        zone, ObjectPool::RawCast(object_store->global_object_pool()));
+        zone, ObjectPool::RawCast(
+                  thread_->isolate()->object_store()->global_object_pool()));
     auto& entry = Object::Handle(zone);
     auto& smi = Smi::Handle(zone);
     for (intptr_t i = 0; i < pool.Length(); i++) {
@@ -6881,7 +7222,11 @@
       }
     }
   }
+#endif  // defined(DART_PRECOMPILED_RUNTIME)
+}
 
+void FullSnapshotReader::InitializeBSS() {
+#if defined(DART_PRECOMPILED_RUNTIME)
   // Initialize entries in the isolate portion of the BSS segment.
   ASSERT(Snapshot::IncludesCode(kind_));
   Image image(instructions_image_);
@@ -6893,8 +7238,6 @@
     BSS::Initialize(thread_, bss_start, /*vm=*/false);
   }
 #endif  // defined(DART_PRECOMPILED_RUNTIME)
-
-  return ApiError::null();
 }
 
 }  // namespace dart
diff --git a/runtime/vm/clustered_snapshot.h b/runtime/vm/clustered_snapshot.h
index 9adda50..252be23 100644
--- a/runtime/vm/clustered_snapshot.h
+++ b/runtime/vm/clustered_snapshot.h
@@ -26,13 +26,6 @@
 
 namespace dart {
 
-// Forward declarations.
-class Serializer;
-class Deserializer;
-class ObjectStore;
-class ImageWriter;
-class ImageReader;
-
 // For full snapshots, we use a clustered snapshot format that trades longer
 // serialization time for faster deserialization time and smaller snapshots.
 // Objects are clustered by class to allow writing type information once per
@@ -50,6 +43,37 @@
 // require the graph has been fully loaded, such as rehashing, though most
 // clusters do not require fixups.
 
+// Forward declarations.
+class Serializer;
+class Deserializer;
+class ObjectStore;
+class ImageWriter;
+class ImageReader;
+
+class LoadingUnitSerializationData : public ZoneAllocated {
+ public:
+  LoadingUnitSerializationData(intptr_t id,
+                               LoadingUnitSerializationData* parent)
+      : id_(id), parent_(parent), deferred_objects_(), num_objects_(0) {}
+
+  intptr_t id() const { return id_; }
+  LoadingUnitSerializationData* parent() const { return parent_; }
+  intptr_t num_objects() const { return num_objects_; }
+  void set_num_objects(intptr_t value) { num_objects_ = value; }
+  void AddDeferredObject(ObjectPtr obj) {
+    deferred_objects_.Add(&Object::ZoneHandle(obj));
+  }
+  GrowableArray<const Object*>* deferred_objects() {
+    return &deferred_objects_;
+  }
+
+ private:
+  intptr_t id_;
+  LoadingUnitSerializationData* parent_;
+  GrowableArray<const Object*> deferred_objects_;
+  intptr_t num_objects_;
+};
+
 class SerializationCluster : public ZoneAllocated {
  public:
   explicit SerializationCluster(const char* name)
@@ -142,7 +166,8 @@
   // Reference value for objects that either are not reachable from the roots or
   // should never have a reference in the snapshot (because they are dropped,
   // for example). Should be the default value for Heap::GetObjectId.
-  static const intptr_t kUnreachableReference = 0;
+  static constexpr intptr_t kUnreachableReference = 0;
+  COMPILE_ASSERT(kUnreachableReference == WeakTable::kNoValue);
 
   static constexpr bool IsReachableReference(intptr_t ref) {
     return ref == kUnallocatedReference || IsAllocatedReference(ref);
@@ -163,6 +188,8 @@
   intptr_t WriteVMSnapshot(const Array& symbols);
   void WriteProgramSnapshot(intptr_t num_base_objects,
                             ObjectStore* object_store);
+  void WriteUnitSnapshot(LoadingUnitSerializationData* unit,
+                         uint32_t program_hash);
 
   void AddVMIsolateBaseObjects();
 
@@ -384,6 +411,7 @@
   void TraceDataOffset(uint32_t offset);
   intptr_t GetDataSize() const;
 
+  intptr_t PrepareCodeOrder();
   void WriteDispatchTable(const Array& entries);
 
   Snapshot::Kind kind() const { return kind_; }
@@ -399,6 +427,14 @@
   // Returns true if [obj] has an artificial profile node associated with it.
   bool CreateArtificalNodeIfNeeded(ObjectPtr obj);
 
+  bool InCurrentLoadingUnit(ObjectPtr obj, bool record = false);
+  void set_loading_units(GrowableArray<LoadingUnitSerializationData*>* units) {
+    loading_units_ = units;
+  }
+  void set_current_loading_unit_id(intptr_t id) {
+    current_loading_unit_id_ = id;
+  }
+
  private:
   static const char* ReadOnlyObjectType(intptr_t cid);
 
@@ -451,6 +487,7 @@
   SerializationCluster** clusters_by_cid_;
   GrowableArray<ObjectPtr> stack_;
   intptr_t num_cids_;
+  intptr_t num_tlc_cids_;
   intptr_t num_base_objects_;
   intptr_t num_written_objects_;
   intptr_t next_ref_index_;
@@ -480,6 +517,9 @@
   IntMap<intptr_t> deduped_instructions_sources_;
 #endif
 
+  intptr_t current_loading_unit_id_ = 0;
+  GrowableArray<LoadingUnitSerializationData*>* loading_units_ = nullptr;
+
   DISALLOW_IMPLICIT_CONSTRUCTORS(Serializer);
 };
 
@@ -576,6 +616,7 @@
   ApiErrorPtr VerifyImageAlignment();
 
   void ReadProgramSnapshot(ObjectStore* object_store);
+  ApiErrorPtr ReadUnitSnapshot(const LoadingUnit& unit);
   void ReadVMSnapshot();
 
   void AddVMIsolateBaseObjects();
@@ -719,7 +760,11 @@
   Heap* heap() const { return isolate()->heap(); }
 
   // Writes a full snapshot of the program(VM isolate, regular isolate group).
-  void WriteFullSnapshot();
+  void WriteFullSnapshot(
+      GrowableArray<LoadingUnitSerializationData*>* data = nullptr);
+  void WriteUnitSnapshot(GrowableArray<LoadingUnitSerializationData*>* units,
+                         LoadingUnitSerializationData* unit,
+                         uint32_t program_hash);
 
   intptr_t VmIsolateSnapshotSize() const { return vm_isolate_snapshot_size_; }
   intptr_t IsolateSnapshotSize() const { return isolate_snapshot_size_; }
@@ -729,7 +774,8 @@
   intptr_t WriteVMSnapshot();
 
   // Writes a full snapshot of regular Dart isolate group.
-  void WriteProgramSnapshot(intptr_t num_base_objects);
+  void WriteProgramSnapshot(intptr_t num_base_objects,
+                            GrowableArray<LoadingUnitSerializationData*>* data);
 
   Thread* thread_;
   Snapshot::Kind kind_;
@@ -761,9 +807,12 @@
 
   ApiErrorPtr ReadVMSnapshot();
   ApiErrorPtr ReadProgramSnapshot();
+  ApiErrorPtr ReadUnitSnapshot(const LoadingUnit& unit);
 
  private:
   ApiErrorPtr ConvertToApiError(char* message);
+  void PatchGlobalObjectPool();
+  void InitializeBSS();
 
   Snapshot::Kind kind_;
   Thread* thread_;
diff --git a/runtime/vm/compiler/aot/aot_call_specializer.cc b/runtime/vm/compiler/aot/aot_call_specializer.cc
index 579659b..6493a81 100644
--- a/runtime/vm/compiler/aot/aot_call_specializer.cc
+++ b/runtime/vm/compiler/aot/aot_call_specializer.cc
@@ -52,11 +52,11 @@
 static void GetUniqueDynamicTarget(Isolate* isolate,
                                    const String& fname,
                                    Object* function) {
-  UniqueFunctionsSet functions_set(
+  UniqueFunctionsMap functions_map(
       isolate->object_store()->unique_dynamic_targets());
   ASSERT(fname.IsSymbol());
-  *function = functions_set.GetOrNull(fname);
-  ASSERT(functions_set.Release().raw() ==
+  *function = functions_map.GetOrNull(fname);
+  ASSERT(functions_map.Release().raw() ==
          isolate->object_store()->unique_dynamic_targets());
 }
 
diff --git a/runtime/vm/compiler/aot/precompiler.cc b/runtime/vm/compiler/aot/precompiler.cc
index e4af5d3..c604a7c 100644
--- a/runtime/vm/compiler/aot/precompiler.cc
+++ b/runtime/vm/compiler/aot/precompiler.cc
@@ -900,7 +900,7 @@
     return;
   }
 
-  const Class& cls = Class::Handle(Z, instance.clazz());
+  Class& cls = Class::Handle(Z, instance.clazz());
   AddInstantiatedClass(cls);
 
   if (instance.IsClosure()) {
@@ -918,6 +918,17 @@
     return;
   }
 
+  if (instance.IsLibraryPrefix()) {
+    const LibraryPrefix& prefix = LibraryPrefix::Cast(instance);
+    ASSERT(prefix.is_deferred_load());
+    const Library& target = Library::Handle(Z, prefix.GetLibrary(0));
+    cls = target.toplevel_class();
+    if (!classes_to_retain_.HasKey(&cls)) {
+      classes_to_retain_.Insert(&Class::ZoneHandle(Z, cls.raw()));
+    }
+    return;
+  }
+
   // Can't ask immediate objects if they're canonical.
   if (instance.IsSmi()) return;
 
@@ -1028,6 +1039,14 @@
     if (name.Equals(Symbols::_ClosureCall())) return true;
   }
 
+  // We have to retain functions which can be a target of a SwitchableCall
+  // at AOT runtime, since the AOT runtime needs to be able to find the
+  // function object in the class.
+  if (function.NeedsMonomorphicCheckedEntry(Z) ||
+      Function::IsDynamicInvocationForwarderName(function.name())) {
+    return true;
+  }
+
   return false;
 }
 
@@ -1299,18 +1318,24 @@
           // hit method extractor get:foo, because it will hit an existing
           // method foo first.
           selector2 = Field::NameFromGetter(selector);
-          selector3 = Symbols::Lookup(thread(), selector2);
-          if (IsSent(selector3)) {
+          if (IsSent(selector2)) {
             AddFunction(function);
           }
           selector2 = Function::CreateDynamicInvocationForwarderName(selector2);
-          selector3 = Symbols::Lookup(thread(), selector2);
-          if (IsSent(selector3)) {
-            AddFunction(function);
+          if (IsSent(selector2)) {
+            selector2 =
+                Function::CreateDynamicInvocationForwarderName(selector);
+            function2 = function.GetDynamicInvocationForwarder(selector2);
+            AddFunction(function2);
           }
         } else if (function.kind() == FunctionLayout::kRegularFunction) {
           selector2 = Field::LookupGetterSymbol(selector);
-          if (IsSent(selector2)) {
+          selector3 = String::null();
+          if (!selector2.IsNull()) {
+            selector3 =
+                Function::CreateDynamicInvocationForwarderName(selector2);
+          }
+          if (IsSent(selector2) || IsSent(selector3)) {
             metadata = kernel::ProcedureAttributesOf(function, Z);
             found_metadata = true;
 
@@ -1327,21 +1352,35 @@
           }
         }
 
-        if (function.kind() == FunctionLayout::kImplicitSetter ||
-            function.kind() == FunctionLayout::kSetterFunction ||
-            function.kind() == FunctionLayout::kRegularFunction) {
+        const bool is_getter =
+            function.kind() == FunctionLayout::kImplicitGetter ||
+            function.kind() == FunctionLayout::kGetterFunction;
+        const bool is_setter =
+            function.kind() == FunctionLayout::kImplicitSetter ||
+            function.kind() == FunctionLayout::kSetterFunction;
+        const bool is_regular =
+            function.kind() == FunctionLayout::kRegularFunction;
+        if (is_getter || is_setter || is_regular) {
           selector2 = Function::CreateDynamicInvocationForwarderName(selector);
           if (IsSent(selector2)) {
-            if (function.kind() == FunctionLayout::kImplicitSetter) {
+            if (function.kind() == FunctionLayout::kImplicitGetter ||
+                function.kind() == FunctionLayout::kImplicitSetter) {
               field = function.accessor_field();
               metadata = kernel::ProcedureAttributesOf(field, Z);
             } else if (!found_metadata) {
               metadata = kernel::ProcedureAttributesOf(function, Z);
             }
 
-            if (metadata.method_or_setter_called_dynamically) {
-              function2 = function.GetDynamicInvocationForwarder(selector2);
-              AddFunction(function2);
+            if (is_getter) {
+              if (metadata.getter_called_dynamically) {
+                function2 = function.GetDynamicInvocationForwarder(selector2);
+                AddFunction(function2);
+              }
+            } else {
+              if (metadata.method_or_setter_called_dynamically) {
+                function2 = function.GetDynamicInvocationForwarder(selector2);
+                AddFunction(function2);
+              }
             }
           }
         }
@@ -1376,16 +1415,38 @@
   table->UpdateValue(fname, farray);
 }
 
+static void AddNamesToFunctionsTable(Zone* zone,
+                                     Table* table,
+                                     const String& fname,
+                                     const Function& function,
+                                     String* mangled_name,
+                                     Function* dyn_function) {
+  AddNameToFunctionsTable(zone, table, fname, function);
+
+  *dyn_function = function.raw();
+  if (kernel::NeedsDynamicInvocationForwarder(function)) {
+    *mangled_name = function.name();
+    *mangled_name =
+        Function::CreateDynamicInvocationForwarderName(*mangled_name);
+    *dyn_function = function.GetDynamicInvocationForwarder(*mangled_name,
+                                                           /*allow_add=*/true);
+  }
+  *mangled_name = Function::CreateDynamicInvocationForwarderName(fname);
+  AddNameToFunctionsTable(zone, table, *mangled_name, *dyn_function);
+}
+
 void Precompiler::CollectDynamicFunctionNames() {
   if (!FLAG_collect_dynamic_function_names) {
     return;
   }
-  Library& lib = Library::Handle(Z);
-  Class& cls = Class::Handle(Z);
-  Array& functions = Array::Handle(Z);
-  Function& function = Function::Handle(Z);
-  String& fname = String::Handle(Z);
-  Array& farray = Array::Handle(Z);
+  auto& lib = Library::Handle(Z);
+  auto& cls = Class::Handle(Z);
+  auto& functions = Array::Handle(Z);
+  auto& function = Function::Handle(Z);
+  auto& fname = String::Handle(Z);
+  auto& farray = Array::Handle(Z);
+  auto& mangled_name = String::Handle(Z);
+  auto& dyn_function = Function::Handle(Z);
 
   Table table(HashTables::New<Table>(100));
   for (intptr_t i = 0; i < libraries_.Length(); i++) {
@@ -1394,27 +1455,34 @@
     while (it.HasNext()) {
       cls = it.GetNextClass();
       functions = cls.functions();
-      for (intptr_t j = 0; j < functions.Length(); j++) {
+
+      const intptr_t length = functions.Length();
+      for (intptr_t j = 0; j < length; j++) {
         function ^= functions.At(j);
         if (function.IsDynamicFunction()) {
           fname = function.name();
           if (function.IsSetterFunction() ||
               function.IsImplicitSetterFunction()) {
-            AddNameToFunctionsTable(zone(), &table, fname, function);
+            AddNamesToFunctionsTable(zone(), &table, fname, function,
+                                     &mangled_name, &dyn_function);
           } else if (function.IsGetterFunction() ||
                      function.IsImplicitGetterFunction()) {
             // Enter both getter and non getter name.
-            AddNameToFunctionsTable(zone(), &table, fname, function);
+            AddNamesToFunctionsTable(zone(), &table, fname, function,
+                                     &mangled_name, &dyn_function);
             fname = Field::NameFromGetter(fname);
-            AddNameToFunctionsTable(zone(), &table, fname, function);
+            AddNamesToFunctionsTable(zone(), &table, fname, function,
+                                     &mangled_name, &dyn_function);
           } else if (function.IsMethodExtractor()) {
             // Skip. We already add getter names for regular methods below.
             continue;
           } else {
             // Regular function. Enter both getter and non getter name.
-            AddNameToFunctionsTable(zone(), &table, fname, function);
+            AddNamesToFunctionsTable(zone(), &table, fname, function,
+                                     &mangled_name, &dyn_function);
             fname = Field::GetterName(fname);
-            AddNameToFunctionsTable(zone(), &table, fname, function);
+            AddNamesToFunctionsTable(zone(), &table, fname, function,
+                                     &mangled_name, &dyn_function);
           }
         }
       }
@@ -1424,7 +1492,8 @@
   // Locate all entries with one function only
   Table::Iterator iter(&table);
   String& key = String::Handle(Z);
-  UniqueFunctionsSet functions_set(HashTables::New<UniqueFunctionsSet>(20));
+  String& key_demangled = String::Handle(Z);
+  UniqueFunctionsMap functions_map(HashTables::New<UniqueFunctionsMap>(20));
   while (iter.MoveNext()) {
     intptr_t curr_key = iter.Current();
     key ^= table.GetKey(curr_key);
@@ -1432,8 +1501,25 @@
     ASSERT(!farray.IsNull());
     if (farray.Length() == 1) {
       function ^= farray.At(0);
-      cls = function.Owner();
-      functions_set.Insert(function);
+
+      // It looks like there is exactly one target for the given name. Though we
+      // have to be careful: e.g. A name like `dyn:get:foo` might have a target
+      // `foo()`. Though the actual target would be a lazily created method
+      // extractor `get:foo` for the `foo` function.
+      //
+      // We'd like to prevent eager creation of functions which we normally
+      // create lazily.
+      // => We disable unique target optimization if the target belongs to the
+      //    lazily created functions.
+      key_demangled = key.raw();
+      if (Function::IsDynamicInvocationForwarderName(key)) {
+        key_demangled = Function::DemangleDynamicInvocationForwarderName(key);
+      }
+      if (function.name() != key.raw() &&
+          function.name() != key_demangled.raw()) {
+        continue;
+      }
+      functions_map.UpdateOrInsert(key, function);
     }
   }
 
@@ -1442,18 +1528,18 @@
   get_runtime_type_is_unique_ = !farray.IsNull() && (farray.Length() == 1);
 
   if (FLAG_print_unique_targets) {
-    UniqueFunctionsSet::Iterator unique_iter(&functions_set);
+    UniqueFunctionsMap::Iterator unique_iter(&functions_map);
     while (unique_iter.MoveNext()) {
       intptr_t curr_key = unique_iter.Current();
-      function ^= functions_set.GetKey(curr_key);
+      function ^= functions_map.GetPayload(curr_key, 0);
       THR_Print("* %s\n", function.ToQualifiedCString());
     }
     THR_Print("%" Pd " of %" Pd " dynamic selectors are unique\n",
-              functions_set.NumOccupied(), table.NumOccupied());
+              functions_map.NumOccupied(), table.NumOccupied());
   }
 
   isolate()->object_store()->set_unique_dynamic_targets(
-      functions_set.Release());
+      functions_map.Release());
   table.Release();
 }
 
@@ -1461,6 +1547,7 @@
   Library& lib = Library::Handle(Z);
   Class& cls = Class::Handle(Z);
   Array& functions = Array::Handle(Z);
+  String& name = String::Handle(Z);
   Function& function = Function::Handle(Z);
   Function& function2 = Function::Handle(Z);
   GrowableObjectArray& closures = GrowableObjectArray::Handle(Z);
@@ -1487,6 +1574,19 @@
           AddTypesOf(function);
         }
       }
+
+      {
+        functions = cls.invocation_dispatcher_cache();
+        InvocationDispatcherTable dispatchers(functions);
+        for (auto dispatcher : dispatchers) {
+          name = dispatcher.Get<Class::kInvocationDispatcherName>();
+          if (name.IsNull()) break;  // Reached last entry.
+          function = dispatcher.Get<Class::kInvocationDispatcherFunction>();
+          if (possibly_retained_functions_.ContainsKey(function)) {
+            AddTypesOf(function);
+          }
+        }
+      }
     }
   }
 
@@ -1601,6 +1701,26 @@
   GrowableObjectArray& retained_functions = GrowableObjectArray::Handle(Z);
   GrowableObjectArray& closures = GrowableObjectArray::Handle(Z);
 
+  auto drop_function = [&](const Function& function) {
+    if (function.HasCode()) {
+      code = function.CurrentCode();
+      function.ClearCode();
+      // Wrap the owner of the code object in case the code object will be
+      // serialized but the function object will not.
+      owner = code.owner();
+      owner = WeakSerializationReference::Wrap(Z, owner);
+      code.set_owner(owner);
+    }
+    dropped_function_count_++;
+    if (FLAG_trace_precompiler) {
+      THR_Print("Dropping function %s\n",
+                function.ToLibNamePrefixedQualifiedCString());
+    }
+  };
+
+  auto& dispatchers_array = Array::Handle(Z);
+  auto& name = String::Handle(Z);
+  auto& desc = Array::Handle(Z);
   for (intptr_t i = 0; i < libraries_.Length(); i++) {
     lib ^= libraries_.At(i);
     ClassDictionaryIterator it(lib, ClassDictionaryIterator::kIteratePrivate);
@@ -1610,26 +1730,12 @@
       retained_functions = GrowableObjectArray::New();
       for (intptr_t j = 0; j < functions.Length(); j++) {
         function ^= functions.At(j);
-        bool retain = functions_to_retain_.ContainsKey(function);
         function.DropUncompiledImplicitClosureFunction();
         function.ClearBytecode();
-        if (retain) {
+        if (functions_to_retain_.ContainsKey(function)) {
           retained_functions.Add(function);
         } else {
-          if (function.HasCode()) {
-            code = function.CurrentCode();
-            function.ClearCode();
-            // Wrap the owner of the code object in case the code object will be
-            // serialized but the function object will not.
-            owner = code.owner();
-            owner = WeakSerializationReference::Wrap(Z, owner);
-            code.set_owner(owner);
-          }
-          dropped_function_count_++;
-          if (FLAG_trace_precompiler) {
-            THR_Print("Dropping function %s\n",
-                      function.ToLibNamePrefixedQualifiedCString());
-          }
+          drop_function(function);
         }
       }
 
@@ -1639,6 +1745,35 @@
       } else {
         cls.SetFunctions(Object::empty_array());
       }
+
+      retained_functions = GrowableObjectArray::New();
+      {
+        dispatchers_array = cls.invocation_dispatcher_cache();
+        InvocationDispatcherTable dispatchers(dispatchers_array);
+        for (auto dispatcher : dispatchers) {
+          name = dispatcher.Get<Class::kInvocationDispatcherName>();
+          if (name.IsNull()) break;  // Reached last entry.
+          desc = dispatcher.Get<Class::kInvocationDispatcherArgsDesc>();
+          function = dispatcher.Get<Class::kInvocationDispatcherFunction>();
+          if (functions_to_retain_.ContainsKey(function)) {
+            retained_functions.Add(name);
+            retained_functions.Add(desc);
+            retained_functions.Add(function);
+          } else {
+            drop_function(function);
+          }
+        }
+      }
+      if (retained_functions.Length() > 0) {
+        // Last entry must be null.
+        retained_functions.Add(Object::null_object());
+        retained_functions.Add(Object::null_object());
+        retained_functions.Add(Object::null_object());
+        functions = Array::MakeFixedLength(retained_functions);
+      } else {
+        functions = Object::empty_array().raw();
+      }
+      cls.set_invocation_dispatcher_cache(functions);
     }
   }
 
@@ -1646,25 +1781,11 @@
   retained_functions = GrowableObjectArray::New();
   for (intptr_t j = 0; j < closures.Length(); j++) {
     function ^= closures.At(j);
-    bool retain = functions_to_retain_.ContainsKey(function);
     function.ClearBytecode();
-    if (retain) {
+    if (functions_to_retain_.ContainsKey(function)) {
       retained_functions.Add(function);
     } else {
-      if (function.HasCode()) {
-        code = function.CurrentCode();
-        function.ClearCode();
-        // Wrap the owner of the code object in case the code object will be
-        // serialized but the function object will not.
-        owner = code.owner();
-        owner = WeakSerializationReference::Wrap(Z, owner);
-        code.set_owner(owner);
-      }
-      dropped_function_count_++;
-      if (FLAG_trace_precompiler) {
-        THR_Print("Dropping function %s\n",
-                  function.ToLibNamePrefixedQualifiedCString());
-      }
+      drop_function(function);
     }
   }
   isolate()->object_store()->set_closure_functions(retained_functions);
@@ -2198,7 +2319,7 @@
     } else {
       toplevel_class = lib.toplevel_class();
 
-      I->class_table()->Unregister(toplevel_class.id());
+      I->class_table()->UnregisterTopLevel(toplevel_class.id());
       toplevel_class.set_id(kIllegalCid);  // We check this when serializing.
 
       dropped_library_count_++;
@@ -2404,8 +2525,6 @@
 }
 
 // Return false if bailed out.
-// If optimized_result_code is not NULL then it is caller's responsibility
-// to install code.
 bool PrecompileParsedFunctionHelper::Compile(CompilationPipeline* pipeline) {
   ASSERT(CompilerState::Current().is_aot());
   if (optimized() && !parsed_function()->function().IsOptimizable()) {
diff --git a/runtime/vm/compiler/aot/precompiler.h b/runtime/vm/compiler/aot/precompiler.h
index 5fdbc37..5f84a82 100644
--- a/runtime/vm/compiler/aot/precompiler.h
+++ b/runtime/vm/compiler/aot/precompiler.h
@@ -381,26 +381,12 @@
   static bool ReportStats() { return false; }
 
   static bool IsMatch(const Object& a, const Object& b) {
-    Zone* zone = Thread::Current()->zone();
-    String& a_s = String::Handle(zone);
-    String& b_s = String::Handle(zone);
-    a_s = a.IsFunction() ? Function::Cast(a).name() : String::Cast(a).raw();
-    b_s = b.IsFunction() ? Function::Cast(b).name() : String::Cast(b).raw();
-    ASSERT(a_s.IsSymbol() && b_s.IsSymbol());
-    return a_s.raw() == b_s.raw();
+    return String::Cast(a).raw() == String::Cast(b).raw();
   }
-  static uword Hash(const Object& obj) {
-    if (obj.IsFunction()) {
-      return String::Handle(Function::Cast(obj).name()).Hash();
-    } else {
-      ASSERT(String::Cast(obj).IsSymbol());
-      return String::Cast(obj).Hash();
-    }
-  }
-  static ObjectPtr NewKey(const Function& function) { return function.raw(); }
+  static uword Hash(const Object& obj) { return String::Cast(obj).Hash(); }
 };
 
-typedef UnorderedHashSet<FunctionsTraits> UniqueFunctionsSet;
+typedef UnorderedHashMap<FunctionsTraits> UniqueFunctionsMap;
 
 #if defined(DART_PRECOMPILER) && !defined(TARGET_ARCH_IA32)
 // ObfuscationMap maps Strings to Strings.
diff --git a/runtime/vm/compiler/assembler/assembler_arm.cc b/runtime/vm/compiler/assembler/assembler_arm.cc
index 1973790..f1997a9 100644
--- a/runtime/vm/compiler/assembler/assembler_arm.cc
+++ b/runtime/vm/compiler/assembler/assembler_arm.cc
@@ -1978,7 +1978,6 @@
 void Assembler::ExtractClassIdFromTags(Register result, Register tags) {
   ASSERT(target::ObjectLayout::kClassIdTagPos == 16);
   ASSERT(target::ObjectLayout::kClassIdTagSize == 16);
-  ASSERT(sizeof(classid_t) == sizeof(uint16_t));
   Lsr(result, tags, Operand(target::ObjectLayout::kClassIdTagPos), AL);
 }
 
diff --git a/runtime/vm/compiler/assembler/assembler_arm64.cc b/runtime/vm/compiler/assembler/assembler_arm64.cc
index 24d45a2..2118d49 100644
--- a/runtime/vm/compiler/assembler/assembler_arm64.cc
+++ b/runtime/vm/compiler/assembler/assembler_arm64.cc
@@ -1132,7 +1132,6 @@
 void Assembler::ExtractClassIdFromTags(Register result, Register tags) {
   ASSERT(target::ObjectLayout::kClassIdTagPos == 16);
   ASSERT(target::ObjectLayout::kClassIdTagSize == 16);
-  ASSERT(sizeof(classid_t) == sizeof(uint16_t));
   LsrImmediate(result, tags, target::ObjectLayout::kClassIdTagPos, kWord);
 }
 
diff --git a/runtime/vm/compiler/assembler/assembler_x64.cc b/runtime/vm/compiler/assembler/assembler_x64.cc
index 99b4608..b84015a 100644
--- a/runtime/vm/compiler/assembler/assembler_x64.cc
+++ b/runtime/vm/compiler/assembler/assembler_x64.cc
@@ -2133,7 +2133,6 @@
 void Assembler::ExtractClassIdFromTags(Register result, Register tags) {
   ASSERT(target::ObjectLayout::kClassIdTagPos == 16);
   ASSERT(target::ObjectLayout::kClassIdTagSize == 16);
-  ASSERT(sizeof(classid_t) == sizeof(uint16_t));
   movl(result, tags);
   shrl(result, Immediate(target::ObjectLayout::kClassIdTagPos));
 }
@@ -2152,7 +2151,6 @@
 void Assembler::LoadClassId(Register result, Register object) {
   ASSERT(target::ObjectLayout::kClassIdTagPos == 16);
   ASSERT(target::ObjectLayout::kClassIdTagSize == 16);
-  ASSERT(sizeof(classid_t) == sizeof(uint16_t));
   const intptr_t class_id_offset =
       target::Object::tags_offset() +
       target::ObjectLayout::kClassIdTagPos / kBitsPerByte;
@@ -2183,7 +2181,6 @@
   ASSERT(kSmiTagShift == 1);
   ASSERT(target::ObjectLayout::kClassIdTagPos == 16);
   ASSERT(target::ObjectLayout::kClassIdTagSize == 16);
-  ASSERT(sizeof(classid_t) == sizeof(uint16_t));
   const intptr_t class_id_offset =
       target::Object::tags_offset() +
       target::ObjectLayout::kClassIdTagPos / kBitsPerByte;
diff --git a/runtime/vm/compiler/assembler/disassembler_arm64.cc b/runtime/vm/compiler/assembler/disassembler_arm64.cc
index 57c6b66..e0992ae 100644
--- a/runtime/vm/compiler/assembler/disassembler_arm64.cc
+++ b/runtime/vm/compiler/assembler/disassembler_arm64.cc
@@ -711,6 +711,8 @@
     // Integer src/dst.
     if (instr->Bits(22, 2) == 0) {
       Format(instr, "str'sz 'rt, 'memop");
+    } else if (instr->Bits(23, 1) == 1) {
+      Format(instr, "ldrs'sz 'rt, 'memop");
     } else {
       Format(instr, "ldr'sz 'rt, 'memop");
     }
diff --git a/runtime/vm/compiler/backend/flow_graph_compiler.cc b/runtime/vm/compiler/backend/flow_graph_compiler.cc
index 3b4ac917..bc98ea2 100644
--- a/runtime/vm/compiler/backend/flow_graph_compiler.cc
+++ b/runtime/vm/compiler/backend/flow_graph_compiler.cc
@@ -2359,6 +2359,18 @@
 #else
   TypeUsageInfo* type_usage_info = thread()->type_usage_info();
 
+  // Special case: non-nullable Object.
+  // Top types should be handled by the caller and cannot reach here.
+  ASSERT(!dst_type.IsTopTypeForSubtyping());
+  if (dst_type.IsObjectType()) {
+    ASSERT(dst_type.IsNonNullable() && isolate()->null_safety());
+    __ CompareObject(TypeTestABI::kInstanceReg, Object::null_object());
+    __ BranchIf(NOT_EQUAL, done);
+    // Fall back to type testing stub.
+    __ LoadObject(TypeTestABI::kDstTypeReg, dst_type);
+    return;
+  }
+
   // If the int type is assignable to [dst_type] we special case it on the
   // caller side!
   const Type& int_type = Type::Handle(zone(), Type::IntType());
diff --git a/runtime/vm/compiler/backend/il.cc b/runtime/vm/compiler/backend/il.cc
index 8e46a8c..308d0b9 100644
--- a/runtime/vm/compiler/backend/il.cc
+++ b/runtime/vm/compiler/backend/il.cc
@@ -202,7 +202,6 @@
     if (cid == kNullCid && !exclude_null) continue;
     cls = table->At(cid);
     if (!include_abstract && cls.is_abstract()) continue;
-    if (cls.is_patch()) continue;
     if (cls.IsTopLevel()) continue;
 
     // We are either interested in [CidRange]es of subclasses or subtypes.
@@ -310,7 +309,7 @@
         for (; j < current_cid; ++j) {
           if (table->HasValidClassAt(j)) {
             klass = table->At(j);
-            if (!klass.is_patch() && !klass.IsTopLevel()) {
+            if (!klass.IsTopLevel()) {
               // If we care about abstract classes also, we cannot skip over any
               // arbitrary abstract class, only those which are subtypes.
               if (include_abstract) {
diff --git a/runtime/vm/compiler/backend/il_arm.cc b/runtime/vm/compiler/backend/il_arm.cc
index 6c3f917..5b4b827 100644
--- a/runtime/vm/compiler/backend/il_arm.cc
+++ b/runtime/vm/compiler/backend/il_arm.cc
@@ -2386,7 +2386,9 @@
 }
 
 void GuardFieldClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
 
   const intptr_t value_cid = value()->Type()->ToCid();
   const intptr_t field_cid = field().guarded_cid();
@@ -2861,7 +2863,9 @@
 }
 
 void StoreInstanceFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
 
   compiler::Label skip_store;
 
@@ -3194,32 +3198,24 @@
   ASSERT(locs()->in(kElementTypePos).reg() == kElemTypeReg);
   ASSERT(locs()->in(kLengthPos).reg() == kLengthReg);
 
+  compiler::Label slow_path, done;
   if (compiler->is_optimizing() && !FLAG_precompiled_mode &&
       num_elements()->BindsToConstant() &&
       compiler::target::IsSmi(num_elements()->BoundConstant())) {
     const intptr_t length =
         compiler::target::SmiValue(num_elements()->BoundConstant());
     if (Array::IsValidLength(length)) {
-      compiler::Label slow_path, done;
       InlineArrayAllocation(compiler, length, &slow_path, &done);
-      __ Bind(&slow_path);
-      __ PushObject(Object::null_object());  // Make room for the result.
-      __ Push(kLengthReg);                   // length.
-      __ Push(kElemTypeReg);
-      compiler->GenerateRuntimeCall(token_pos(), deopt_id(),
-                                    kAllocateArrayRuntimeEntry, 2, locs());
-      __ Drop(2);
-      __ Pop(kResultReg);
-      __ Bind(&done);
-      return;
     }
   }
 
+  __ Bind(&slow_path);
   auto object_store = compiler->isolate()->object_store();
   const auto& allocate_array_stub =
       Code::ZoneHandle(compiler->zone(), object_store->allocate_array_stub());
   compiler->GenerateStubCall(token_pos(), allocate_array_stub,
                              PcDescriptorsLayout::kOther, locs(), deopt_id());
+  __ Bind(&done);
   ASSERT(locs()->out(0).reg() == kResultReg);
 }
 
@@ -3274,7 +3270,9 @@
 }
 
 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
 
   const Register instance_reg = locs()->in(0).reg();
   if (IsUnboxedLoad() && compiler->is_optimizing()) {
diff --git a/runtime/vm/compiler/backend/il_arm64.cc b/runtime/vm/compiler/backend/il_arm64.cc
index 273bba0..bf7a7f6 100644
--- a/runtime/vm/compiler/backend/il_arm64.cc
+++ b/runtime/vm/compiler/backend/il_arm64.cc
@@ -2071,7 +2071,10 @@
 }
 
 void GuardFieldClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   const intptr_t value_cid = value()->Type()->ToCid();
   const intptr_t field_cid = field().guarded_cid();
   const intptr_t nullability = field().is_nullable() ? kNullCid : kIllegalCid;
@@ -2399,7 +2402,10 @@
 }
 
 void StoreInstanceFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   compiler::Label skip_store;
 
   const Register instance_reg = locs()->in(0).reg();
@@ -2719,30 +2725,24 @@
   ASSERT(locs()->in(kElementTypePos).reg() == kElemTypeReg);
   ASSERT(locs()->in(kLengthPos).reg() == kLengthReg);
 
+  compiler::Label slow_path, done;
   if (compiler->is_optimizing() && !FLAG_precompiled_mode &&
       num_elements()->BindsToConstant() &&
       num_elements()->BoundConstant().IsSmi()) {
     const intptr_t length = Smi::Cast(num_elements()->BoundConstant()).Value();
     if (Array::IsValidLength(length)) {
-      compiler::Label slow_path, done;
       InlineArrayAllocation(compiler, length, &slow_path, &done);
-      __ Bind(&slow_path);
-      __ PushObject(Object::null_object());   // Make room for the result.
-      __ PushPair(kElemTypeReg, kLengthReg);  // length.
-      compiler->GenerateRuntimeCall(token_pos(), deopt_id(),
-                                    kAllocateArrayRuntimeEntry, 2, locs());
-      __ Drop(2);
-      __ Pop(kResultReg);
-      __ Bind(&done);
-      return;
     }
   }
+
+  __ Bind(&slow_path);
   auto object_store = compiler->isolate()->object_store();
   const auto& allocate_array_stub =
       Code::ZoneHandle(compiler->zone(), object_store->allocate_array_stub());
   compiler->GenerateStubCall(token_pos(), allocate_array_stub,
                              PcDescriptorsLayout::kOther, locs(), deopt_id());
   ASSERT(locs()->out(0).reg() == kResultReg);
+  __ Bind(&done);
 }
 
 LocationSummary* LoadFieldInstr::MakeLocationSummary(Zone* zone,
@@ -2791,7 +2791,10 @@
 }
 
 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   const Register instance_reg = locs()->in(0).reg();
   if (IsUnboxedLoad() && compiler->is_optimizing()) {
     ASSERT(!calls_initializer());
diff --git a/runtime/vm/compiler/backend/il_deserializer.cc b/runtime/vm/compiler/backend/il_deserializer.cc
index 47ac11a..30d4520 100644
--- a/runtime/vm/compiler/backend/il_deserializer.cc
+++ b/runtime/vm/compiler/backend/il_deserializer.cc
@@ -2138,9 +2138,8 @@
       return false;
     }
     if (is_forwarder) {
-      // Go back four characters to start at the 'dyn:' we stripped earlier.
-      tmp_string_ = String::FromUTF8(
-          reinterpret_cast<const uint8_t*>(func_start - 4), name_len + 4);
+      tmp_string_ = name_function_.name();
+      tmp_string_ = Function::CreateDynamicInvocationForwarderName(tmp_string_);
       name_function_ =
           name_function_.GetDynamicInvocationForwarder(tmp_string_);
     }
diff --git a/runtime/vm/compiler/backend/il_ia32.cc b/runtime/vm/compiler/backend/il_ia32.cc
index 219ec45..e95db90 100644
--- a/runtime/vm/compiler/backend/il_ia32.cc
+++ b/runtime/vm/compiler/backend/il_ia32.cc
@@ -1882,7 +1882,10 @@
 }
 
 void GuardFieldClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   const intptr_t value_cid = value()->Type()->ToCid();
   const intptr_t field_cid = field().guarded_cid();
   const intptr_t nullability = field().is_nullable() ? kNullCid : kIllegalCid;
@@ -2213,7 +2216,10 @@
 }
 
 void StoreInstanceFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   compiler::Label skip_store;
 
   const Register instance_reg = locs()->in(0).reg();
@@ -2510,23 +2516,15 @@
       num_elements()->BoundConstant().IsSmi()) {
     const intptr_t length = Smi::Cast(num_elements()->BoundConstant()).Value();
     if (Array::IsValidLength(length)) {
-      compiler::Label slow_path, done;
       InlineArrayAllocation(compiler, length, &slow_path, &done);
-      __ Bind(&slow_path);
-      __ PushObject(Object::null_object());  // Make room for the result.
-      __ pushl(kLengthReg);
-      __ pushl(kElemTypeReg);
-      compiler->GenerateRuntimeCall(token_pos(), deopt_id(),
-                                    kAllocateArrayRuntimeEntry, 2, locs());
-      __ Drop(2);
-      __ popl(kResultReg);
-      __ Bind(&done);
-      return;
     }
   }
 
   __ Bind(&slow_path);
-  compiler->GenerateStubCall(token_pos(), StubCode::AllocateArray(),
+  auto object_store = compiler->isolate()->object_store();
+  const auto& allocate_array_stub =
+      Code::ZoneHandle(compiler->zone(), object_store->allocate_array_stub());
+  compiler->GenerateStubCall(token_pos(), allocate_array_stub,
                              PcDescriptorsLayout::kOther, locs(), deopt_id());
   __ Bind(&done);
   ASSERT(locs()->out(0).reg() == kResultReg);
@@ -2568,7 +2566,9 @@
 }
 
 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
 
   Register instance_reg = locs()->in(0).reg();
   if (IsUnboxedLoad() && compiler->is_optimizing()) {
diff --git a/runtime/vm/compiler/backend/il_x64.cc b/runtime/vm/compiler/backend/il_x64.cc
index d01f34f..f15c658 100644
--- a/runtime/vm/compiler/backend/il_x64.cc
+++ b/runtime/vm/compiler/backend/il_x64.cc
@@ -2064,7 +2064,10 @@
 }
 
 void GuardFieldClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   const intptr_t value_cid = value()->Type()->ToCid();
   const intptr_t field_cid = field().guarded_cid();
   const intptr_t nullability = field().is_nullable() ? kNullCid : kIllegalCid;
@@ -2421,7 +2424,10 @@
 }
 
 void StoreInstanceFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   compiler::Label skip_store;
 
   const Register instance_reg = locs()->in(0).reg();
@@ -2752,18 +2758,7 @@
       num_elements()->BoundConstant().IsSmi()) {
     const intptr_t length = Smi::Cast(num_elements()->BoundConstant()).Value();
     if (Array::IsValidLength(length)) {
-      compiler::Label slow_path, done;
       InlineArrayAllocation(compiler, length, &slow_path, &done);
-      __ Bind(&slow_path);
-      __ PushObject(Object::null_object());  // Make room for the result.
-      __ pushq(kLengthReg);
-      __ pushq(kElemTypeReg);
-      compiler->GenerateRuntimeCall(token_pos(), deopt_id(),
-                                    kAllocateArrayRuntimeEntry, 2, locs());
-      __ Drop(2);
-      __ popq(kResultReg);
-      __ Bind(&done);
-      return;
     }
   }
 
@@ -2825,7 +2820,10 @@
 }
 
 void LoadFieldInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
-  ASSERT(sizeof(classid_t) == kInt16Size);
+  ASSERT(compiler::target::ObjectLayout::kClassIdTagSize == 16);
+  ASSERT(sizeof(FieldLayout::guarded_cid_) == 2);
+  ASSERT(sizeof(FieldLayout::is_nullable_) == 2);
+
   Register instance_reg = locs()->in(0).reg();
   if (IsUnboxedLoad() && compiler->is_optimizing()) {
     ASSERT(!calls_initializer());
diff --git a/runtime/vm/compiler/backend/inliner.cc b/runtime/vm/compiler/backend/inliner.cc
index 4b47da7..7b04675 100644
--- a/runtime/vm/compiler/backend/inliner.cc
+++ b/runtime/vm/compiler/backend/inliner.cc
@@ -194,6 +194,12 @@
         if (current->IsRedefinition()) {
           continue;
         }
+        // UnboxedConstant is often folded into the indexing
+        // instructions (similar to Constant instructions which
+        // belong to initial definitions and not counted here).
+        if (current->IsUnboxedConstant()) {
+          continue;
+        }
         ++instruction_count_;
         // Count inputs of certain instructions as if separate PushArgument
         // instructions are used for inputs. This is done in order to
diff --git a/runtime/vm/compiler/backend/inliner_test.cc b/runtime/vm/compiler/backend/inliner_test.cc
index 2db1229..081e794 100644
--- a/runtime/vm/compiler/backend/inliner_test.cc
+++ b/runtime/vm/compiler/backend/inliner_test.cc
@@ -227,12 +227,10 @@
         kMatchAndMoveJoinEntry,
         kMatchAndMoveCheckStackOverflow,
         kMatchAndMoveUnboxInt64,
-        kMatchAndMoveUnboxInt64,
         kMatchAndMoveBranchTrue,
 
         // Loop body
         kMatchAndMoveTargetEntry,
-        kWordSize == 8 ? kMatchAndMoveUnboxInt64 : kNop,
         kMatchAndMoveGenericCheckBound,
         kMatchAndMoveStoreIndexed,
         kMatchAndMoveCheckedSmiOp,
@@ -242,7 +240,6 @@
         kMatchAndMoveJoinEntry,
         kMatchAndMoveCheckStackOverflow,
         kMatchAndMoveUnboxInt64,
-        kMatchAndMoveUnboxInt64,
         kMatchAndMoveBranchFalse,
 
         // After loop
diff --git a/runtime/vm/compiler/call_specializer.cc b/runtime/vm/compiler/call_specializer.cc
index ab58fa0..c84bdaf 100644
--- a/runtime/vm/compiler/call_specializer.cc
+++ b/runtime/vm/compiler/call_specializer.cc
@@ -1588,15 +1588,23 @@
     auto& type_class = Class::Handle(zone_);
 #define TRY_INLINE(iface, member_name, type, cid)                              \
   if (!member_name.IsNull()) {                                                 \
+    const bool is_float_access =                                               \
+        cid == kTypedDataFloat32ArrayCid || cid == kTypedDataFloat64ArrayCid;  \
     if (receiver_type->IsAssignableTo(member_name)) {                          \
       if (is_length_getter) {                                                  \
         type_class = member_name.type_class();                                 \
         ReplaceWithLengthGetter(call);                                         \
       } else if (is_index_get) {                                               \
+        if (is_float_access && !FlowGraphCompiler::SupportsUnboxedDoubles()) { \
+          return;                                                              \
+        }                                                                      \
         if (!index_type->IsNullableInt()) return;                              \
         type_class = member_name.type_class();                                 \
         ReplaceWithIndexGet(call, cid);                                        \
       } else {                                                                 \
+        if (is_float_access && !FlowGraphCompiler::SupportsUnboxedDoubles()) { \
+          return;                                                              \
+        }                                                                      \
         if (!index_type->IsNullableInt()) return;                              \
         if (!value_type->IsAssignableTo(type)) return;                         \
         type_class = member_name.type_class();                                 \
diff --git a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
index a7cbc05..4f25c9f 100644
--- a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
+++ b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
@@ -2014,14 +2014,6 @@
       type, variable->name(), AssertAssignableInstr::kParameterCheck);
 }
 
-Fragment StreamingFlowGraphBuilder::CheckTypeArgumentBound(
-    const AbstractType& parameter,
-    const AbstractType& bound,
-    const String& dst_name) {
-  return flow_graph_builder_->AssertSubtype(TokenPosition::kNoSource, parameter,
-                                            bound, dst_name);
-}
-
 Fragment StreamingFlowGraphBuilder::EnterScope(
     intptr_t kernel_offset,
     const LocalScope** scope /* = nullptr */) {
@@ -2339,16 +2331,27 @@
     instructions += CheckNull(position, receiver, getter_name);
   }
 
-  if (!direct_call.target_.IsNull()) {
+  const String* mangled_name = &getter_name;
+  const Function* direct_call_target = &direct_call.target_;
+  if (H.IsRoot(itarget_name)) {
+    mangled_name = &String::ZoneHandle(
+        Z, Function::CreateDynamicInvocationForwarderName(getter_name));
+    if (!direct_call_target->IsNull()) {
+      direct_call_target = &Function::ZoneHandle(
+          direct_call.target_.GetDynamicInvocationForwarder(*mangled_name));
+    }
+  }
+
+  if (!direct_call_target->IsNull()) {
     ASSERT(CompilerState::Current().is_aot());
     instructions +=
-        StaticCall(position, direct_call.target_, 1, Array::null_array(),
+        StaticCall(position, *direct_call_target, 1, Array::null_array(),
                    ICData::kNoRebind, &result_type);
   } else {
     const intptr_t kTypeArgsLen = 0;
     const intptr_t kNumArgsChecked = 1;
     instructions +=
-        InstanceCall(position, getter_name, Token::kGET, kTypeArgsLen, 1,
+        InstanceCall(position, *mangled_name, Token::kGET, kTypeArgsLen, 1,
                      Array::null_array(), kNumArgsChecked, *interface_target,
                      *tearoff_interface_target, &result_type);
   }
diff --git a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.h b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.h
index c36a7c8..f3a2fee 100644
--- a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.h
+++ b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.h
@@ -263,9 +263,6 @@
   Fragment BuildImplicitClosureCreation(const Function& target);
   Fragment CheckBoolean(TokenPosition position);
   Fragment CheckArgumentType(LocalVariable* variable, const AbstractType& type);
-  Fragment CheckTypeArgumentBound(const AbstractType& parameter,
-                                  const AbstractType& bound,
-                                  const String& dst_name);
   Fragment EnterScope(intptr_t kernel_offset,
                       const LocalScope** scope = nullptr);
   Fragment ExitScope(intptr_t kernel_offset);
diff --git a/runtime/vm/compiler/frontend/kernel_fingerprints.cc b/runtime/vm/compiler/frontend/kernel_fingerprints.cc
index b20ba94..5b16ddd 100644
--- a/runtime/vm/compiler/frontend/kernel_fingerprints.cc
+++ b/runtime/vm/compiler/frontend/kernel_fingerprints.cc
@@ -227,9 +227,11 @@
     case kDynamicType:
     case kVoidType:
     case kBottomType:
-    case kNeverType:
       // those contain nothing.
       break;
+    case kNeverType:
+      BuildHash(static_cast<uint32_t>(ReadNullability()));
+      break;
     case kInterfaceType:
       CalculateInterfaceTypeFingerprint(false);
       break;
diff --git a/runtime/vm/compiler/frontend/kernel_to_il.cc b/runtime/vm/compiler/frontend/kernel_to_il.cc
index 4ecc873..2a05f82 100644
--- a/runtime/vm/compiler/frontend/kernel_to_il.cc
+++ b/runtime/vm/compiler/frontend/kernel_to_il.cc
@@ -2559,17 +2559,18 @@
   // type and then invokes original setter we simply generate the type check
   // and inlined field store. Scope builder takes care of setting correct
   // type check mode in this case.
-  const bool is_setter = function.IsDynamicInvocationForwarder() ||
-                         function.IsImplicitSetterFunction();
-  const bool is_method = !function.IsStaticFunction();
+  const auto& target = Function::Handle(
+      Z, function.IsDynamicInvocationForwarder() ? function.ForwardingTarget()
+                                                 : function.raw());
+  ASSERT(target.IsImplicitGetterOrSetter());
 
-  Field& field = Field::ZoneHandle(Z);
-  if (function.IsDynamicInvocationForwarder()) {
-    Function& target = Function::Handle(function.ForwardingTarget());
-    field = target.accessor_field();
-  } else {
-    field = function.accessor_field();
-  }
+  const bool is_method = !function.IsStaticFunction();
+  const bool is_setter = target.IsImplicitSetterFunction();
+  const bool is_getter = target.IsImplicitGetterFunction() ||
+                         target.IsImplicitStaticGetterFunction();
+  ASSERT(is_setter || is_getter);
+
+  const auto& field = Field::ZoneHandle(Z, target.accessor_field());
 
   graph_entry_ =
       new (Z) GraphEntryInstr(*parsed_function_, Compiler::kNoOSRDeoptId);
@@ -2579,18 +2580,20 @@
 
   Fragment body(normal_entry);
   if (is_setter) {
-    LocalVariable* setter_value =
+    auto const setter_value =
         parsed_function_->ParameterVariable(is_method ? 1 : 0);
-
-    // We only expect to generate a dynamic invocation forwarder if
-    // the value needs type check.
-    ASSERT(!function.IsDynamicInvocationForwarder() ||
-           setter_value->needs_type_check());
     if (is_method) {
       body += LoadLocal(parsed_function_->ParameterVariable(0));
     }
     body += LoadLocal(setter_value);
-    if (setter_value->needs_type_check()) {
+
+    // The dyn:* forwarder has to check the parameters that the
+    // actual target will not check.
+    // Though here we manually inline the target, so the dyn:* forwarder has to
+    // check all parameters.
+    const bool needs_type_check = function.IsDynamicInvocationForwarder() ||
+                                  setter_value->needs_type_check();
+    if (needs_type_check) {
       body += CheckAssignable(setter_value->type(), setter_value->name(),
                               AssertAssignableInstr::kParameterCheck);
     }
@@ -2612,7 +2615,7 @@
       }
     }
     body += NullConstant();
-  } else if (is_method) {
+  } else if (is_getter && is_method) {
     ASSERT(!field.needs_load_guard()
                 NOT_IN_PRODUCT(|| I->HasAttemptedReload()));
     body += LoadLocal(parsed_function_->ParameterVariable(0));
@@ -2661,15 +2664,15 @@
     const Function& function) {
   auto& name = String::Handle(Z, function.name());
   name = Function::DemangleDynamicInvocationForwarderName(name);
-  const auto& owner = Class::Handle(Z, function.Owner());
-  const auto& target =
-      Function::ZoneHandle(Z, owner.LookupDynamicFunction(name));
+  const auto& target = Function::ZoneHandle(Z, function.ForwardingTarget());
   ASSERT(!target.IsNull());
-  ASSERT(!target.IsImplicitGetterFunction());
 
-  if (target.IsImplicitSetterFunction()) {
+  if (target.IsImplicitSetterFunction() || target.IsImplicitGetterFunction()) {
     return BuildGraphOfFieldAccessor(function);
   }
+  if (target.IsMethodExtractor()) {
+    return BuildGraphOfMethodExtractor(target);
+  }
 
   graph_entry_ = new (Z) GraphEntryInstr(*parsed_function_, osr_id_);
 
@@ -3233,8 +3236,7 @@
 
 Fragment FlowGraphBuilder::BuildNullAssertions() {
   Fragment code;
-  if (I->null_safety() || !I->asserts() || !FLAG_null_assertions ||
-      !KernelIsolate::GetExperimentalFlag("non-nullable")) {
+  if (I->null_safety() || !I->asserts() || !FLAG_null_assertions) {
     return code;
   }
 
diff --git a/runtime/vm/compiler/frontend/kernel_translation_helper.cc b/runtime/vm/compiler/frontend/kernel_translation_helper.cc
index 93a9b49..fbaa46d 100644
--- a/runtime/vm/compiler/frontend/kernel_translation_helper.cc
+++ b/runtime/vm/compiler/frontend/kernel_translation_helper.cc
@@ -1798,6 +1798,56 @@
   return;
 }
 
+LoadingUnitsMetadataHelper::LoadingUnitsMetadataHelper(
+    KernelReaderHelper* helper)
+    : MetadataHelper(helper, tag(), /* precompiler_only = */ true) {}
+
+void LoadingUnitsMetadataHelper::ReadMetadata(intptr_t node_offset) {
+  intptr_t md_offset = GetNextMetadataPayloadOffset(node_offset);
+  if (md_offset < 0) {
+    return;
+  }
+
+  AlternativeReadingScopeWithNewData alt(&helper_->reader_,
+                                         &H.metadata_payloads(), md_offset);
+
+  Thread* T = Thread::Current();
+  Zone* Z = T->zone();
+  intptr_t unit_count = helper_->ReadUInt();
+  Array& loading_units = Array::Handle(Z, Array::New(unit_count + 1));
+  LoadingUnit& unit = LoadingUnit::Handle(Z);
+  LoadingUnit& parent = LoadingUnit::Handle(Z);
+  Library& lib = Library::Handle(Z);
+
+  for (int i = 0; i < unit_count; i++) {
+    intptr_t id = helper_->ReadUInt();
+    unit = LoadingUnit::New();
+    unit.set_id(id);
+
+    intptr_t parent_id = helper_->ReadUInt();
+    parent ^= loading_units.At(parent_id);
+    ASSERT(parent.IsNull() == (parent_id == 0));
+    unit.set_parent(parent);
+
+    intptr_t library_count = helper_->ReadUInt();
+    for (intptr_t j = 0; j < library_count; j++) {
+      const String& uri =
+          translation_helper_.DartSymbolPlain(helper_->ReadStringReference());
+      lib = Library::LookupLibrary(T, uri);
+      if (lib.IsNull()) {
+        FATAL1("Missing library: %s\n", uri.ToCString());
+      }
+      lib.set_loading_unit(unit);
+    }
+
+    loading_units.SetAt(id, unit);
+  }
+
+  ObjectStore* object_store = Isolate::Current()->object_store();
+  ASSERT(object_store->loading_units() == Array::null());
+  object_store->set_loading_units(loading_units);
+}
+
 CallSiteAttributesMetadataHelper::CallSiteAttributesMetadataHelper(
     KernelReaderHelper* helper,
     TypeTranslator* type_translator)
@@ -3367,11 +3417,35 @@
   }
 }
 
+static void SetupUnboxingInfoOfReturnValue(
+    const Function& function,
+    const UnboxingInfoMetadata* metadata) {
+  switch (metadata->return_info) {
+    case UnboxingInfoMetadata::kUnboxedIntCandidate:
+      if (FlowGraphCompiler::SupportsUnboxedInt64()) {
+        function.set_unboxed_integer_return();
+      }
+      break;
+    case UnboxingInfoMetadata::kUnboxedDoubleCandidate:
+      if (FlowGraphCompiler::SupportsUnboxedDoubles()) {
+        function.set_unboxed_double_return();
+      }
+      break;
+    case UnboxingInfoMetadata::kUnboxingCandidate:
+      UNREACHABLE();
+      break;
+    case UnboxingInfoMetadata::kBoxed:
+      break;
+    default:
+      UNREACHABLE();
+      break;
+  }
+}
+
 void TypeTranslator::SetupUnboxingInfoMetadata(const Function& function,
                                                intptr_t library_kernel_offset) {
   const intptr_t kernel_offset =
       function.kernel_offset() + library_kernel_offset;
-
   const auto unboxing_info =
       unboxing_info_metadata_helper_.GetUnboxingInfoMetadata(kernel_offset);
 
@@ -3382,26 +3456,30 @@
     for (intptr_t i = 0; i < unboxing_info->unboxed_args_info.length(); i++) {
       SetupUnboxingInfoOfParameter(function, i, unboxing_info);
     }
+    SetupUnboxingInfoOfReturnValue(function, unboxing_info);
+  }
+}
 
-    switch (unboxing_info->return_info) {
-      case UnboxingInfoMetadata::kUnboxedIntCandidate:
-        if (FlowGraphCompiler::SupportsUnboxedInt64()) {
-          function.set_unboxed_integer_return();
-        }
-        break;
-      case UnboxingInfoMetadata::kUnboxedDoubleCandidate:
-        if (FlowGraphCompiler::SupportsUnboxedDoubles()) {
-          function.set_unboxed_double_return();
-        }
-        break;
-      case UnboxingInfoMetadata::kUnboxingCandidate:
-        UNREACHABLE();
-        break;
-      case UnboxingInfoMetadata::kBoxed:
-        break;
-      default:
-        UNREACHABLE();
-        break;
+void TypeTranslator::SetupUnboxingInfoMetadataForFieldAccessors(
+    const Function& field_accessor,
+    intptr_t library_kernel_offset) {
+  const intptr_t kernel_offset =
+      field_accessor.kernel_offset() + library_kernel_offset;
+  const auto unboxing_info =
+      unboxing_info_metadata_helper_.GetUnboxingInfoMetadata(kernel_offset);
+
+  // TODO(dartbug.com/32292): accept unboxed parameters and return value
+  // when FLAG_use_table_dispatch == false.
+  if (FLAG_precompiled_mode && unboxing_info != nullptr &&
+      FLAG_use_table_dispatch && FLAG_use_bare_instructions) {
+    if (field_accessor.IsImplicitSetterFunction()) {
+      for (intptr_t i = 0; i < unboxing_info->unboxed_args_info.length(); i++) {
+        SetupUnboxingInfoOfParameter(field_accessor, i, unboxing_info);
+      }
+    } else {
+      ASSERT(field_accessor.IsImplicitGetterFunction() ||
+             field_accessor.IsImplicitStaticGetterFunction());
+      SetupUnboxingInfoOfReturnValue(field_accessor, unboxing_info);
     }
   }
 }
diff --git a/runtime/vm/compiler/frontend/kernel_translation_helper.h b/runtime/vm/compiler/frontend/kernel_translation_helper.h
index 23f3151..e2c8540a 100644
--- a/runtime/vm/compiler/frontend/kernel_translation_helper.h
+++ b/runtime/vm/compiler/frontend/kernel_translation_helper.h
@@ -1029,6 +1029,20 @@
   DISALLOW_COPY_AND_ASSIGN(ObfuscationProhibitionsMetadataHelper);
 };
 
+class LoadingUnitsMetadataHelper : public MetadataHelper {
+ public:
+  static const char* tag() { return "vm.loading-units.metadata"; }
+
+  explicit LoadingUnitsMetadataHelper(KernelReaderHelper* helper);
+
+  void ReadLoadingUnits() { ReadMetadata(0); }
+
+ private:
+  void ReadMetadata(intptr_t node_offset);
+
+  DISALLOW_COPY_AND_ASSIGN(LoadingUnitsMetadataHelper);
+};
+
 struct CallSiteAttributesMetadata {
   const AbstractType* receiver_type = nullptr;
 };
@@ -1267,6 +1281,7 @@
   friend class UnboxingInfoMetadataHelper;
   friend class VariableDeclarationHelper;
   friend class ObfuscationProhibitionsMetadataHelper;
+  friend class LoadingUnitsMetadataHelper;
   friend bool NeedsDynamicInvocationForwarder(const Function& function);
 
  private:
@@ -1454,6 +1469,9 @@
  private:
   void SetupUnboxingInfoMetadata(const Function& function,
                                  intptr_t library_kernel_offset);
+  void SetupUnboxingInfoMetadataForFieldAccessors(
+      const Function& field_accessor,
+      intptr_t library_kernel_offset);
 
   void BuildTypeInternal();
   void BuildInterfaceType(bool simple);
diff --git a/runtime/vm/compiler/frontend/prologue_builder.cc b/runtime/vm/compiler/frontend/prologue_builder.cc
index ea3375b..6bf2aff 100644
--- a/runtime/vm/compiler/frontend/prologue_builder.cc
+++ b/runtime/vm/compiler/frontend/prologue_builder.cc
@@ -40,7 +40,8 @@
 
 bool PrologueBuilder::HasEmptyPrologue(const Function& function) {
   return !function.HasOptionalParameters() && !function.IsGeneric() &&
-         !function.CanReceiveDynamicInvocation();
+         !function.CanReceiveDynamicInvocation() &&
+         !function.IsClosureFunction();
 }
 
 BlockEntryInstr* PrologueBuilder::BuildPrologue(BlockEntryInstr* entry,
@@ -81,6 +82,8 @@
   }
 
   const bool is_empty_prologue = prologue.entry == prologue.current;
+  // Double-check we create empty prologues when HasEmptyPrologue returns true.
+  ASSERT(!HasEmptyPrologue(function_) || is_empty_prologue);
 
   // Always do this to preserve deoptid numbering.
   JoinEntryInstr* normal_code = BuildJoinEntry();
diff --git a/runtime/vm/compiler/frontend/scope_builder.cc b/runtime/vm/compiler/frontend/scope_builder.cc
index e8b8a2c..13529c2 100644
--- a/runtime/vm/compiler/frontend/scope_builder.cc
+++ b/runtime/vm/compiler/frontend/scope_builder.cc
@@ -32,15 +32,7 @@
   // In AOT mode we don't dynamically generate such trampolines but instead rely
   // on a static analysis to discover which methods can be invoked dynamically,
   // and generate the necessary trampolines during precompilation.
-  if (method.name() == Symbols::Call().raw() ||
-      method.CanReceiveDynamicInvocation()) {
-    // Currently we consider all call methods to be invoked dynamically and
-    // don't mangle their names.
-    // TODO(vegorov) remove this once we also introduce special type checking
-    // entry point for closures.
-    return false;
-  }
-  return true;
+  return !method.CanReceiveDynamicInvocation();
 }
 
 ScopeBuilder::ScopeBuilder(ParsedFunction* parsed_function)
@@ -354,13 +346,13 @@
       break;
     }
     case FunctionLayout::kDynamicInvocationForwarder: {
+      const String& name = String::Handle(Z, function.name());
+      ASSERT(Function::IsDynamicInvocationForwarderName(name));
+
+      const auto& target = Function::ZoneHandle(Z, function.ForwardingTarget());
+      ASSERT(!target.IsNull());
+
       if (helper_.PeekTag() == kField) {
-#ifdef DEBUG
-        String& name = String::Handle(Z, function.name());
-        ASSERT(Function::IsDynamicInvocationForwarderName(name));
-        name = Function::DemangleDynamicInvocationForwarderName(name);
-        ASSERT(Field::IsSetterName(name));
-#endif
         // Create [this] variable.
         const Class& klass = Class::Handle(Z, function.Owner());
         parsed_function_->set_receiver_var(
@@ -369,29 +361,36 @@
         scope_->InsertParameterAt(0, parsed_function_->receiver_var());
 
         // Create setter value variable.
-        result_->setter_value = MakeVariable(
-            TokenPosition::kNoSource, TokenPosition::kNoSource,
-            Symbols::Value(),
-            AbstractType::ZoneHandle(Z, function.ParameterTypeAt(1)));
-        scope_->InsertParameterAt(1, result_->setter_value);
-      } else {
-        helper_.ReadUntilFunctionNode();
-        function_node_helper.ReadUntilExcluding(
-            FunctionNodeHelper::kPositionalParameters);
-
-        // Create [this] variable.
-        intptr_t pos = 0;
-        Class& klass = Class::Handle(Z, function.Owner());
-        parsed_function_->set_receiver_var(
-            MakeVariable(TokenPosition::kNoSource, TokenPosition::kNoSource,
-                         Symbols::This(), H.GetDeclarationType(klass)));
-        scope_->InsertParameterAt(pos++, parsed_function_->receiver_var());
-
-        // Create all positional and named parameters.
-        AddPositionalAndNamedParameters(
-            pos, kTypeCheckEverythingNotCheckedInNonDynamicallyInvokedMethod,
-            attrs);
+        if (target.IsImplicitSetterFunction()) {
+          result_->setter_value = MakeVariable(
+              TokenPosition::kNoSource, TokenPosition::kNoSource,
+              Symbols::Value(),
+              AbstractType::ZoneHandle(Z, function.ParameterTypeAt(1)));
+          scope_->InsertParameterAt(1, result_->setter_value);
+        }
+        break;
       }
+
+      // We do not create dyn:* forwarders for method extractors, since those
+      // can never return unboxed values (they return a closure).
+      ASSERT(!target.IsMethodExtractor());
+
+      helper_.ReadUntilFunctionNode();
+      function_node_helper.ReadUntilExcluding(
+          FunctionNodeHelper::kPositionalParameters);
+
+      // Create [this] variable.
+      intptr_t pos = 0;
+      Class& klass = Class::Handle(Z, function.Owner());
+      parsed_function_->set_receiver_var(
+          MakeVariable(TokenPosition::kNoSource, TokenPosition::kNoSource,
+                       Symbols::This(), H.GetDeclarationType(klass)));
+      scope_->InsertParameterAt(pos++, parsed_function_->receiver_var());
+
+      // Create all positional and named parameters.
+      AddPositionalAndNamedParameters(
+          pos, kTypeCheckEverythingNotCheckedInNonDynamicallyInvokedMethod,
+          attrs);
       break;
     }
     case FunctionLayout::kMethodExtractor: {
@@ -540,6 +539,8 @@
   FunctionNodeHelper function_node_helper(&helper_);
   function_node_helper.ReadUntilExcluding(FunctionNodeHelper::kTypeParameters);
 
+  const auto& function = parsed_function_->function();
+
   intptr_t list_length =
       helper_.ReadListLength();  // read type_parameters list length.
   for (intptr_t i = 0; i < list_length; ++i) {
@@ -565,10 +566,8 @@
   }
 
   if (function_node_helper.async_marker_ == FunctionNodeHelper::kSyncYielding) {
-    intptr_t offset = parsed_function_->function().num_fixed_parameters();
-    for (intptr_t i = 0;
-         i < parsed_function_->function().NumOptionalPositionalParameters();
-         i++) {
+    intptr_t offset = function.num_fixed_parameters();
+    for (intptr_t i = 0; i < function.NumOptionalPositionalParameters(); i++) {
       parsed_function_->ParameterVariable(offset + i)->set_is_forced_stack();
     }
   }
@@ -627,6 +626,14 @@
       }
     }
   }
+
+  // Mark known chained futures such as _Future::timeout()'s _future.
+  if (function.recognized_kind() == MethodRecognizer::kFutureTimeout &&
+      depth_.function_ == 1) {
+    LocalVariable* future = scope_->LookupVariable(Symbols::_future(), true);
+    ASSERT(future != nullptr);
+    future->set_is_chained_future();
+  }
 }
 
 void ScopeBuilder::VisitInitializer() {
diff --git a/runtime/vm/compiler/jit/compiler.cc b/runtime/vm/compiler/jit/compiler.cc
index fbb7557..1139cdc 100644
--- a/runtime/vm/compiler/jit/compiler.cc
+++ b/runtime/vm/compiler/jit/compiler.cc
@@ -502,8 +502,6 @@
 }
 
 // Return null if bailed out.
-// If optimized_result_code is not NULL then it is caller's responsibility
-// to install code.
 CodePtr CompileParsedFunctionHelper::Compile(CompilationPipeline* pipeline) {
   ASSERT(!FLAG_precompiled_mode);
   const Function& function = parsed_function()->function();
@@ -659,7 +657,7 @@
         //      those writes are observed atomically.
         //
         thread()->isolate_group()->RunWithStoppedMutators(
-            install_code_fun, install_code_fun, /*use_force_growth=*/true);
+            install_code_fun, /*use_force_growth=*/true);
       }
       if (!result->IsNull()) {
         // Must be called outside of safepoint.
diff --git a/runtime/vm/compiler/method_recognizer.cc b/runtime/vm/compiler/method_recognizer.cc
index 98a4a34..2d4d7d6 100644
--- a/runtime/vm/compiler/method_recognizer.cc
+++ b/runtime/vm/compiler/method_recognizer.cc
@@ -4,6 +4,7 @@
 
 #include "vm/compiler/method_recognizer.h"
 
+#include "vm/log.h"
 #include "vm/object.h"
 #include "vm/reusable_handles.h"
 #include "vm/symbols.h"
@@ -198,16 +199,16 @@
   GrowableArray<Library*> libs(3);
   Libraries(&libs);
   Function& func = Function::Handle();
+  bool fingerprints_match = true;
 
   for (intptr_t i = 1; i < MethodRecognizer::kNumRecognizedMethods; i++) {
     const MethodRecognizer::Kind kind = static_cast<MethodRecognizer::Kind>(i);
     func = Library::GetFunction(libs, recognized_methods[i].class_name,
                                 recognized_methods[i].function_name);
     if (!func.IsNull()) {
-      CHECK_FINGERPRINT3(func, recognized_methods[i].class_name,
-                         recognized_methods[i].function_name,
-                         recognized_methods[i].enum_name,
-                         recognized_methods[i].fp);
+      fingerprints_match =
+          func.CheckSourceFingerprint(recognized_methods[i].fp) &&
+          fingerprints_match;
       func.set_recognized_kind(kind);
       switch (kind) {
 #define RECOGNIZE_METHOD(class_name, function_name, enum_name, fp)             \
@@ -220,19 +221,21 @@
           break;
       }
     } else if (!FLAG_precompiled_mode) {
-      FATAL2("Missing %s::%s\n", recognized_methods[i].class_name,
-             recognized_methods[i].function_name);
+      fingerprints_match = false;
+      OS::PrintErr("Missing %s::%s\n", recognized_methods[i].class_name,
+                   recognized_methods[i].function_name);
     }
   }
 
 #define SET_FUNCTION_BIT(class_name, function_name, dest, fp, setter, value)   \
   func = Library::GetFunction(libs, #class_name, #function_name);              \
   if (!func.IsNull()) {                                                        \
-    CHECK_FINGERPRINT3(func, class_name, function_name, dest, fp);             \
+    fingerprints_match =                                                       \
+        func.CheckSourceFingerprint(fp) && fingerprints_match;                 \
     func.setter(value);                                                        \
   } else if (!FLAG_precompiled_mode) {                                         \
     OS::PrintErr("Missing %s::%s\n", #class_name, #function_name);             \
-    UNREACHABLE();                                                             \
+    fingerprints_match = false;                                                \
   }
 
 #define SET_IS_POLYMORPHIC_TARGET(class_name, function_name, dest, fp)         \
@@ -244,6 +247,14 @@
 #undef SET_RECOGNIZED_KIND
 #undef SET_IS_POLYMORPHIC_TARGET
 #undef SET_FUNCTION_BIT
+
+  if (!fingerprints_match) {
+    FATAL(
+        "FP mismatch while recognizing methods. If the behavior of "
+        "these functions has changed, then changes are also needed in "
+        "the VM's compiler. Otherwise the fingerprint can simply be "
+        "updated in recognized_methods_list.h\n");
+  }
 }
 
 void MethodRecognizer::Libraries(GrowableArray<Library*>* libs) {
@@ -258,15 +269,7 @@
   libs->Add(&Library::ZoneHandle(Library::FfiLibrary()));
 }
 
-Token::Kind MethodTokenRecognizer::RecognizeTokenKind(const String& name_) {
-  Thread* thread = Thread::Current();
-  REUSABLE_STRING_HANDLESCOPE(thread);
-  String& name = thread->StringHandle();
-  name = name_.raw();
-  ASSERT(name.IsSymbol());
-  if (Function::IsDynamicInvocationForwarderName(name)) {
-    name = Function::DemangleDynamicInvocationForwarderName(name);
-  }
+static Token::Kind RecognizeTokenKindHelper(const String& name) {
   if (name.raw() == Symbols::Plus().raw()) {
     return Token::kADD;
   } else if (name.raw() == Symbols::Minus().raw()) {
@@ -313,6 +316,18 @@
   return Token::kILLEGAL;
 }
 
+Token::Kind MethodTokenRecognizer::RecognizeTokenKind(const String& name) {
+  ASSERT(name.IsSymbol());
+  if (Function::IsDynamicInvocationForwarderName(name)) {
+    Thread* thread = Thread::Current();
+    const auto& demangled_name = String::Handle(
+        thread->zone(), Function::DemangleDynamicInvocationForwarderName(name));
+    return RecognizeTokenKindHelper(demangled_name);
+  } else {
+    return RecognizeTokenKindHelper(name);
+  }
+}
+
 #define RECOGNIZE_FACTORY(symbol, class_name, constructor_name, cid, fp)       \
   {Symbols::k##symbol##Id, cid, fp, #symbol ", " #cid},  // NOLINT
 
diff --git a/runtime/vm/compiler/method_recognizer.h b/runtime/vm/compiler/method_recognizer.h
index 30b0443..949e031 100644
--- a/runtime/vm/compiler/method_recognizer.h
+++ b/runtime/vm/compiler/method_recognizer.h
@@ -65,12 +65,6 @@
   static Token::Kind RecognizeTokenKind(const String& name);
 };
 
-#define CHECK_FINGERPRINT2(f, p0, p1, fp)                                      \
-  ASSERT(f.CheckSourceFingerprint(#p0 ", " #p1, fp))
-
-#define CHECK_FINGERPRINT3(f, p0, p1, p2, fp)                                  \
-  ASSERT(f.CheckSourceFingerprint(#p0 ", " #p1 ", " #p2, fp))
-
 // Class that recognizes factories and returns corresponding result cid.
 class FactoryRecognizer : public AllStatic {
  public:
diff --git a/runtime/vm/compiler/recognized_methods_list.h b/runtime/vm/compiler/recognized_methods_list.h
index 849cff7..d497854 100644
--- a/runtime/vm/compiler/recognized_methods_list.h
+++ b/runtime/vm/compiler/recognized_methods_list.h
@@ -12,365 +12,366 @@
 // When adding a new function, add a 0 as the fingerprint and run the build in
 // debug mode to get the correct fingerprint from the mismatch error.
 #define OTHER_RECOGNIZED_LIST(V)                                               \
-  V(::, identical, ObjectIdentical, 0xc6e9467a)                                \
-  V(ClassID, getID, ClassIDgetID, 0xf0376ced)                                  \
-  V(Object, Object., ObjectConstructor, 0x8f3ae7ea)                            \
-  V(List, ., ListFactory, 0xdf9970a9)                                          \
-  V(_List, ., ObjectArrayAllocate, 0x03ddbd3a)                                 \
-  V(_List, []=, ObjectArraySetIndexed, 0x4d5e74cf)                             \
-  V(_GrowableList, []=, GrowableArraySetIndexed, 0x4d5e74cf)                   \
-  V(_TypedList, _getInt8, ByteArrayBaseGetInt8, 0xa24c2704)                    \
-  V(_TypedList, _getUint8, ByteArrayBaseGetUint8, 0xa491df3e)                  \
-  V(_TypedList, _getInt16, ByteArrayBaseGetInt16, 0xb65ae1fc)                  \
-  V(_TypedList, _getUint16, ByteArrayBaseGetUint16, 0xb4b776e5)                \
-  V(_TypedList, _getInt32, ByteArrayBaseGetInt32, 0xb460abe4)                  \
-  V(_TypedList, _getUint32, ByteArrayBaseGetUint32, 0x8c066c71)                \
-  V(_TypedList, _getInt64, ByteArrayBaseGetInt64, 0xacf2f222)                  \
-  V(_TypedList, _getUint64, ByteArrayBaseGetUint64, 0xa74b200b)                \
-  V(_TypedList, _getFloat32, ByteArrayBaseGetFloat32, 0xa33a9f77)              \
-  V(_TypedList, _getFloat64, ByteArrayBaseGetFloat64, 0x87d86b60)              \
-  V(_TypedList, _getFloat32x4, ByteArrayBaseGetFloat32x4, 0x3e76086e)          \
-  V(_TypedList, _getInt32x4, ByteArrayBaseGetInt32x4, 0xfea5f17f)              \
-  V(_TypedList, _setInt8, ByteArrayBaseSetInt8, 0xd2c4e74b)                    \
-  V(_TypedList, _setUint8, ByteArrayBaseSetUint8, 0xec62b082)                  \
-  V(_TypedList, _setInt16, ByteArrayBaseSetInt16, 0xc3566903)                  \
-  V(_TypedList, _setUint16, ByteArrayBaseSetUint16, 0xdb50780f)                \
-  V(_TypedList, _setInt32, ByteArrayBaseSetInt32, 0xbeeeea8a)                  \
-  V(_TypedList, _setUint32, ByteArrayBaseSetUint32, 0xca02f10a)                \
-  V(_TypedList, _setInt64, ByteArrayBaseSetInt64, 0xcf587ccf)                  \
-  V(_TypedList, _setUint64, ByteArrayBaseSetUint64, 0xe01a1df0)                \
-  V(_TypedList, _setFloat32, ByteArrayBaseSetFloat32, 0xb6a6294f)              \
-  V(_TypedList, _setFloat64, ByteArrayBaseSetFloat64, 0xce7dad17)              \
-  V(_TypedList, _setFloat32x4, ByteArrayBaseSetFloat32x4, 0x4b773b59)          \
-  V(_TypedList, _setInt32x4, ByteArrayBaseSetInt32x4, 0xfa2a6f88)              \
-  V(ByteData, ., ByteDataFactory, 0x0d31f187)                                  \
-  V(_ByteDataView, get:offsetInBytes, ByteDataViewOffsetInBytes, 0x0d956c6d)   \
-  V(_ByteDataView, get:_typedData, ByteDataViewTypedData, 0x28cc4efc)          \
-  V(_TypedListView, get:offsetInBytes, TypedDataViewOffsetInBytes, 0x0d956c6d) \
-  V(_TypedListView, get:_typedData, TypedDataViewTypedData, 0x28cc4efc)        \
-  V(_ByteDataView, ._, TypedData_ByteDataView_factory, 0xb839ff59)             \
-  V(_Int8ArrayView, ._, TypedData_Int8ArrayView_factory, 0x3d000a8d)           \
-  V(_Uint8ArrayView, ._, TypedData_Uint8ArrayView_factory, 0xff69de0f)         \
+  V(::, identical, ObjectIdentical, 0x8fd6ea58)                                \
+  V(ClassID, getID, ClassIDgetID, 0x0401ffad)                                  \
+  V(Object, Object., ObjectConstructor, 0x256e7170)                            \
+  V(List, ., ListFactory, 0xbec87d33)                                          \
+  V(_List, ., ObjectArrayAllocate, 0x6de199a1)                                 \
+  V(_List, []=, ObjectArraySetIndexed, 0xba15978f)                             \
+  V(_GrowableList, []=, GrowableArraySetIndexed, 0xba15978f)                   \
+  V(_TypedList, _getInt8, ByteArrayBaseGetInt8, 0xc28aff37)                    \
+  V(_TypedList, _getUint8, ByteArrayBaseGetUint8, 0xc3e7212d)                  \
+  V(_TypedList, _getInt16, ByteArrayBaseGetInt16, 0xdaa7b952)                  \
+  V(_TypedList, _getUint16, ByteArrayBaseGetUint16, 0xdc2919bc)                \
+  V(_TypedList, _getInt32, ByteArrayBaseGetInt32, 0xc57f53af)                  \
+  V(_TypedList, _getUint32, ByteArrayBaseGetUint32, 0xc5c49520)                \
+  V(_TypedList, _getInt64, ByteArrayBaseGetInt64, 0xa2c7e6a4)                  \
+  V(_TypedList, _getUint64, ByteArrayBaseGetUint64, 0xd8c29ffe)                \
+  V(_TypedList, _getFloat32, ByteArrayBaseGetFloat32, 0xaf15f28a)              \
+  V(_TypedList, _getFloat64, ByteArrayBaseGetFloat64, 0xbe4987b7)              \
+  V(_TypedList, _getFloat32x4, ByteArrayBaseGetFloat32x4, 0x76c82c28)          \
+  V(_TypedList, _getInt32x4, ByteArrayBaseGetInt32x4, 0x29abed4e)              \
+  V(_TypedList, _setInt8, ByteArrayBaseSetInt8, 0xfc13ad87)                    \
+  V(_TypedList, _setUint8, ByteArrayBaseSetUint8, 0xc9e4212d)                  \
+  V(_TypedList, _setInt16, ByteArrayBaseSetInt16, 0xd570aa0c)                  \
+  V(_TypedList, _setUint16, ByteArrayBaseSetUint16, 0xe8acb234)                \
+  V(_TypedList, _setInt32, ByteArrayBaseSetInt32, 0xd8651525)                  \
+  V(_TypedList, _setUint32, ByteArrayBaseSetUint32, 0xd3f10d97)                \
+  V(_TypedList, _setInt64, ByteArrayBaseSetInt64, 0xe357b95f)                  \
+  V(_TypedList, _setUint64, ByteArrayBaseSetUint64, 0xf4d19bea)                \
+  V(_TypedList, _setFloat32, ByteArrayBaseSetFloat32, 0xd6272645)              \
+  V(_TypedList, _setFloat64, ByteArrayBaseSetFloat64, 0xca4af137)              \
+  V(_TypedList, _setFloat32x4, ByteArrayBaseSetFloat32x4, 0x71767f7f)          \
+  V(_TypedList, _setInt32x4, ByteArrayBaseSetInt32x4, 0xf0483280)              \
+  V(ByteData, ., ByteDataFactory, 0x63fefa4b)                                  \
+  V(_ByteDataView, get:offsetInBytes, ByteDataViewOffsetInBytes, 0xe51b926b)   \
+  V(_ByteDataView, get:_typedData, ByteDataViewTypedData, 0x3c781fb9)          \
+  V(_TypedListView, get:offsetInBytes, TypedDataViewOffsetInBytes, 0xe51b926b) \
+  V(_TypedListView, get:_typedData, TypedDataViewTypedData, 0x3c781fb9)        \
+  V(_ByteDataView, ._, TypedData_ByteDataView_factory, 0xe9e9dad9)             \
+  V(_Int8ArrayView, ._, TypedData_Int8ArrayView_factory, 0x016014a7)           \
+  V(_Uint8ArrayView, ._, TypedData_Uint8ArrayView_factory, 0x8c3fc232)         \
   V(_Uint8ClampedArrayView, ._, TypedData_Uint8ClampedArrayView_factory,       \
-    0xdff11b9a)                                                                \
-  V(_Int16ArrayView, ._, TypedData_Int16ArrayView_factory, 0x1635c91e)         \
-  V(_Uint16ArrayView, ._, TypedData_Uint16ArrayView_factory, 0x287cbc66)       \
-  V(_Int32ArrayView, ._, TypedData_Int32ArrayView_factory, 0xf5270227)         \
-  V(_Uint32ArrayView, ._, TypedData_Uint32ArrayView_factory, 0xbb74a021)       \
-  V(_Int64ArrayView, ._, TypedData_Int64ArrayView_factory, 0xf348a583)         \
-  V(_Uint64ArrayView, ._, TypedData_Uint64ArrayView_factory, 0x10589491)       \
-  V(_Float32ArrayView, ._, TypedData_Float32ArrayView_factory, 0xbb4124b3)     \
-  V(_Float64ArrayView, ._, TypedData_Float64ArrayView_factory, 0x5f0b81e9)     \
-  V(_Float32x4ArrayView, ._, TypedData_Float32x4ArrayView_factory, 0xd8c71a39) \
-  V(_Int32x4ArrayView, ._, TypedData_Int32x4ArrayView_factory, 0x9bfbd6d5)     \
-  V(_Float64x2ArrayView, ._, TypedData_Float64x2ArrayView_factory, 0x1a383408) \
-  V(::, _toClampedUint8, ConvertIntToClampedUint8, 0x59765a4a)                 \
+    0x36da9706)                                                                \
+  V(_Int16ArrayView, ._, TypedData_Int16ArrayView_factory, 0x09a366f8)         \
+  V(_Uint16ArrayView, ._, TypedData_Uint16ArrayView_factory, 0x8f74c30f)       \
+  V(_Int32ArrayView, ._, TypedData_Int32ArrayView_factory, 0x8c100d16)         \
+  V(_Uint32ArrayView, ._, TypedData_Uint32ArrayView_factory, 0x4f7f073e)       \
+  V(_Int64ArrayView, ._, TypedData_Int64ArrayView_factory, 0xb85546cc)         \
+  V(_Uint64ArrayView, ._, TypedData_Uint64ArrayView_factory, 0x019c229a)       \
+  V(_Float32ArrayView, ._, TypedData_Float32ArrayView_factory, 0x2290e5a1)     \
+  V(_Float64ArrayView, ._, TypedData_Float64ArrayView_factory, 0xbe62c734)     \
+  V(_Float32x4ArrayView, ._, TypedData_Float32x4ArrayView_factory, 0x5bb7771d) \
+  V(_Int32x4ArrayView, ._, TypedData_Int32x4ArrayView_factory, 0x30b9f2a2)     \
+  V(_Float64x2ArrayView, ._, TypedData_Float64x2ArrayView_factory, 0x96490d01) \
+  V(::, _toClampedUint8, ConvertIntToClampedUint8, 0x143ed675)                 \
   V(::, copyRangeFromUint8ListToOneByteString,                                 \
-    CopyRangeFromUint8ListToOneByteString, 0x00000000)                         \
-  V(_StringBase, _interpolate, StringBaseInterpolate, 0xc0a650e4)              \
-  V(_IntegerImplementation, toDouble, IntegerToDouble, 0x22a26db3)             \
-  V(_Double, _add, DoubleAdd, 0x2f5c036a)                                      \
-  V(_Double, _sub, DoubleSub, 0x6d3cec71)                                      \
-  V(_Double, _mul, DoubleMul, 0x648e67af)                                      \
-  V(_Double, _div, DoubleDiv, 0x6d72d7d4)                                      \
-  V(::, min, MathMin, 0x935b799b)                                              \
-  V(::, max, MathMax, 0xe188dec2)                                              \
-  V(::, _doublePow, MathDoublePow, 0x5ae04e61)                                 \
-  V(::, _intPow, MathIntPow, 0x569ffd3f)                                       \
-  V(Float32x4, _Float32x4FromDoubles, Float32x4FromDoubles, 0xbe902b89)        \
-  V(Float32x4, Float32x4.zero, Float32x4Zero, 0x9b875c7f)                      \
-  V(Float32x4, _Float32x4Splat, Float32x4Splat, 0xd0cf3e6c)                    \
-  V(Float32x4, Float32x4.fromInt32x4Bits, Int32x4ToFloat32x4, 0x7339b2bd)      \
-  V(Float32x4, Float32x4.fromFloat64x2, Float64x2ToFloat32x4, 0x5de0e788)      \
-  V(_Float32x4, shuffle, Float32x4Shuffle, 0x5bc2446e)                         \
-  V(_Float32x4, shuffleMix, Float32x4ShuffleMix, 0x61887391)                   \
-  V(_Float32x4, get:signMask, Float32x4GetSignMask, 0x2931936f)                \
-  V(_Float32x4, equal, Float32x4Equal, 0x63e87fb9)                             \
-  V(_Float32x4, greaterThan, Float32x4GreaterThan, 0x71db0fc2)                 \
-  V(_Float32x4, greaterThanOrEqual, Float32x4GreaterThanOrEqual, 0x6dfbf3fa)   \
-  V(_Float32x4, lessThan, Float32x4LessThan, 0x69a60360)                       \
-  V(_Float32x4, lessThanOrEqual, Float32x4LessThanOrEqual, 0x6604e583)         \
-  V(_Float32x4, notEqual, Float32x4NotEqual, 0x83dcc786)                       \
-  V(_Float32x4, min, Float32x4Min, 0xf70ed6d5)                                 \
-  V(_Float32x4, max, Float32x4Max, 0xd93e58a6)                                 \
-  V(_Float32x4, scale, Float32x4Scale, 0xea28b605)                             \
-  V(_Float32x4, sqrt, Float32x4Sqrt, 0xacff17f7)                               \
-  V(_Float32x4, reciprocalSqrt, Float32x4ReciprocalSqrt, 0xa5e00f7d)           \
-  V(_Float32x4, reciprocal, Float32x4Reciprocal, 0x9c5a3fb7)                   \
-  V(_Float32x4, unary-, Float32x4Negate, 0xae8af7f1)                           \
-  V(_Float32x4, abs, Float32x4Abs, 0xb34e9b8d)                                 \
-  V(_Float32x4, clamp, Float32x4Clamp, 0xbed4ce62)                             \
-  V(_Float32x4, _withX, Float32x4WithX, 0xf0211c74)                            \
-  V(_Float32x4, _withY, Float32x4WithY, 0x074539fc)                            \
-  V(_Float32x4, _withZ, Float32x4WithZ, 0xf026c2e5)                            \
-  V(_Float32x4, _withW, Float32x4WithW, 0xe364aa0f)                            \
-  V(Float64x2, _Float64x2FromDoubles, Float64x2FromDoubles, 0x1ca49394)        \
-  V(Float64x2, Float64x2.zero, Float64x2Zero, 0x5e70f315)                      \
-  V(Float64x2, _Float64x2Splat, Float64x2Splat, 0x05711520)                    \
-  V(Float64x2, Float64x2.fromFloat32x4, Float32x4ToFloat64x2, 0x956c2161)      \
-  V(_Float64x2, get:x, Float64x2GetX, 0x00b83193)                              \
-  V(_Float64x2, get:y, Float64x2GetY, 0xee498cb6)                              \
-  V(_Float64x2, unary-, Float64x2Negate, 0x71748e87)                           \
-  V(_Float64x2, abs, Float64x2Abs, 0x76383223)                                 \
-  V(_Float64x2, sqrt, Float64x2Sqrt, 0x6fe8ae8d)                               \
-  V(_Float64x2, get:signMask, Float64x2GetSignMask, 0x2931936f)                \
-  V(_Float64x2, scale, Float64x2Scale, 0xad124c9b)                             \
-  V(_Float64x2, _withX, Float64x2WithX, 0xb30ab30a)                            \
-  V(_Float64x2, _withY, Float64x2WithY, 0xca2ed092)                            \
-  V(_Float64x2, min, Float64x2Min,  0x57938495)                                \
-  V(_Float64x2, max, Float64x2Max,  0x39c30666)                                \
-  V(Int32x4, _Int32x4FromInts, Int32x4FromInts, 0xbce3fab8)                    \
-  V(Int32x4, _Int32x4FromBools, Int32x4FromBools, 0x45ef1b0f)                  \
-  V(Int32x4, Int32x4.fromFloat32x4Bits, Float32x4ToInt32x4, 0x64c906dc)        \
-  V(_Int32x4, get:flagX, Int32x4GetFlagX, 0x9f8da5bb)                          \
-  V(_Int32x4, get:flagY, Int32x4GetFlagY, 0xbafddc9b)                          \
-  V(_Int32x4, get:flagZ, Int32x4GetFlagZ, 0xc8a777ee)                          \
-  V(_Int32x4, get:flagW, Int32x4GetFlagW, 0xd1c78a2f)                          \
-  V(_Int32x4, get:signMask, Int32x4GetSignMask, 0x2931936f)                    \
-  V(_Int32x4, shuffle, Int32x4Shuffle, 0x00cff856)                             \
-  V(_Int32x4, shuffleMix, Int32x4ShuffleMix, 0x57a21961)                       \
-  V(_Int32x4, select, Int32x4Select, 0xafd1fc25)                               \
-  V(_Int32x4, _withFlagX, Int32x4WithFlagX, 0x7d654214)                        \
-  V(_Int32x4, _withFlagY, Int32x4WithFlagY, 0x7e67ec85)                        \
-  V(_Int32x4, _withFlagZ, Int32x4WithFlagZ, 0x9363a67c)                        \
-  V(_Int32x4, _withFlagW, Int32x4WithFlagW, 0x7035cb54)                        \
-  V(_HashVMBase, get:_index, LinkedHashMap_getIndex, 0x09db1d9d)               \
-  V(_HashVMBase, set:_index, LinkedHashMap_setIndex, 0xb643fb19)               \
-  V(_HashVMBase, get:_data, LinkedHashMap_getData, 0x9a54182a)                 \
-  V(_HashVMBase, set:_data, LinkedHashMap_setData, 0x8bc58326)                 \
-  V(_HashVMBase, get:_usedData, LinkedHashMap_getUsedData, 0xf3cf0e2e)         \
-  V(_HashVMBase, set:_usedData, LinkedHashMap_setUsedData, 0x75261d2a)         \
-  V(_HashVMBase, get:_hashMask, LinkedHashMap_getHashMask, 0xfbd541dd)         \
-  V(_HashVMBase, set:_hashMask, LinkedHashMap_setHashMask, 0x7d2c50d9)         \
-  V(_HashVMBase, get:_deletedKeys, LinkedHashMap_getDeletedKeys, 0xfdd43ee1)   \
-  V(_HashVMBase, set:_deletedKeys, LinkedHashMap_setDeletedKeys, 0x7f2b4ddd)   \
-  V(::, _classRangeCheck, ClassRangeCheck, 0xca52e30a)                         \
-  V(::, _asyncStackTraceHelper, AsyncStackTraceHelper, 0xaeaed5cb)             \
-  V(::, _abi, FfiAbi, 0xf2e89620)                                              \
-  V(::, _asFunctionInternal, FfiAsFunctionInternal, 0x77414ede)                \
-  V(::, _nativeCallbackFunction, FfiNativeCallbackFunction, 0x5bd261b8)        \
-  V(::, _loadInt8, FfiLoadInt8, 0x9b1e4a8d)                                    \
-  V(::, _loadInt16, FfiLoadInt16, 0x2824dc24)                                  \
-  V(::, _loadInt32, FfiLoadInt32, 0x3f9bf49d)                                  \
-  V(::, _loadInt64, FfiLoadInt64, 0xbb4e2186)                                  \
-  V(::, _loadUint8, FfiLoadUint8, 0xc93d1241)                                  \
-  V(::, _loadUint16, FfiLoadUint16, 0x4bc4c8ae)                                \
-  V(::, _loadUint32, FfiLoadUint32, 0x5fd2e17c)                                \
-  V(::, _loadUint64, FfiLoadUint64, 0xec4e4e0a)                                \
-  V(::, _loadIntPtr, FfiLoadIntPtr, 0x1ad8e69f)                                \
-  V(::, _loadFloat, FfiLoadFloat, 0x234b92dc)                                  \
-  V(::, _loadDouble, FfiLoadDouble, 0x97c755b3)                                \
-  V(::, _loadPointer, FfiLoadPointer, 0xd9d293a5)                              \
-  V(::, _storeInt8, FfiStoreInt8, 0x9a637adf)                                  \
-  V(::, _storeInt16, FfiStoreInt16, 0x7c5ad40b)                                \
-  V(::, _storeInt32, FfiStoreInt32, 0xc729a9da)                                \
-  V(::, _storeInt64, FfiStoreInt64, 0x748af071)                                \
-  V(::, _storeUint8, FfiStoreUint8, 0xea22235e)                                \
-  V(::, _storeUint16, FfiStoreUint16, 0x0c61dd74)                              \
-  V(::, _storeUint32, FfiStoreUint32, 0x32962fcb)                              \
-  V(::, _storeUint64, FfiStoreUint64, 0xe55a10c2)                              \
-  V(::, _storeIntPtr, FfiStoreIntPtr, 0xc75ef10f)                              \
-  V(::, _storeFloat, FfiStoreFloat, 0x34a22e07)                                \
-  V(::, _storeDouble, FfiStoreDouble, 0x09226ca7)                              \
-  V(::, _storePointer, FfiStorePointer, 0x3c7143a8)                            \
-  V(::, _fromAddress, FfiFromAddress, 0x612a64d5)                              \
-  V(Pointer, get:address, FfiGetAddress, 0x29a505a1)                           \
-  V(::, reachabilityFence, ReachabilityFence, 0x0)                             \
+    CopyRangeFromUint8ListToOneByteString, 0x89d6a60a)                         \
+  V(_StringBase, _interpolate, StringBaseInterpolate, 0xbf682f1c)              \
+  V(_IntegerImplementation, toDouble, IntegerToDouble, 0x5f8db5f5)             \
+  V(_Double, _add, DoubleAdd, 0x4326962a)                                      \
+  V(_Double, _sub, DoubleSub, 0x81077f31)                                      \
+  V(_Double, _mul, DoubleMul, 0x7858fa6f)                                      \
+  V(_Double, _div, DoubleDiv, 0x813d6a94)                                      \
+  V(::, min, MathMin, 0xe6a2f504)                                              \
+  V(::, max, MathMax, 0x4cfa6f6b)                                              \
+  V(::, _doublePow, MathDoublePow, 0x973546e3)                                 \
+  V(::, _intPow, MathIntPow, 0x5449a6fb)                                       \
+  V(Float32x4, _Float32x4FromDoubles, Float32x4FromDoubles, 0x4ddbf1d0)        \
+  V(Float32x4, Float32x4.zero, Float32x4Zero, 0x730d827d)                      \
+  V(Float32x4, _Float32x4Splat, Float32x4Splat, 0x36ae87e8)                    \
+  V(Float32x4, Float32x4.fromInt32x4Bits, Int32x4ToFloat32x4, 0x8704457d)      \
+  V(Float32x4, Float32x4.fromFloat64x2, Float64x2ToFloat32x4, 0x71ab7a48)      \
+  V(_Float32x4, shuffle, Float32x4Shuffle, 0x6f8cd72e)                         \
+  V(_Float32x4, shuffleMix, Float32x4ShuffleMix, 0xd9fe42cf)                   \
+  V(_Float32x4, get:signMask, Float32x4GetSignMask, 0x00b7b96d)                \
+  V(_Float32x4, equal, Float32x4Equal, 0x77b31279)                             \
+  V(_Float32x4, greaterThan, Float32x4GreaterThan, 0x85a5a282)                 \
+  V(_Float32x4, greaterThanOrEqual, Float32x4GreaterThanOrEqual, 0x81c686ba)   \
+  V(_Float32x4, lessThan, Float32x4LessThan, 0x7d709620)                       \
+  V(_Float32x4, lessThanOrEqual, Float32x4LessThanOrEqual, 0x79cf7843)         \
+  V(_Float32x4, notEqual, Float32x4NotEqual, 0x97a75a46)                       \
+  V(_Float32x4, min, Float32x4Min, 0x0ad96995)                                 \
+  V(_Float32x4, max, Float32x4Max, 0xed08eb66)                                 \
+  V(_Float32x4, scale, Float32x4Scale, 0xfdf348c5)                             \
+  V(_Float32x4, sqrt, Float32x4Sqrt, 0x84853df5)                               \
+  V(_Float32x4, reciprocalSqrt, Float32x4ReciprocalSqrt, 0x7d66357b)           \
+  V(_Float32x4, reciprocal, Float32x4Reciprocal, 0x73e065b5)                   \
+  V(_Float32x4, unary-, Float32x4Negate, 0x86111def)                           \
+  V(_Float32x4, abs, Float32x4Abs, 0x8ad4c18b)                                 \
+  V(_Float32x4, clamp, Float32x4Clamp, 0x374a9da0)                             \
+  V(_Float32x4, _withX, Float32x4WithX, 0xfd53a072)                            \
+  V(_Float32x4, _withY, Float32x4WithY, 0xf5f5b506)                            \
+  V(_Float32x4, _withZ, Float32x4WithZ, 0xf2122f63)                            \
+  V(_Float32x4, _withW, Float32x4WithW, 0xef6f231e)                            \
+  V(Float64x2, _Float64x2FromDoubles, Float64x2FromDoubles, 0x9688f476)        \
+  V(Float64x2, Float64x2.zero, Float64x2Zero, 0x35f71913)                      \
+  V(Float64x2, _Float64x2Splat, Float64x2Splat, 0xf2e6bce9)                    \
+  V(Float64x2, Float64x2.fromFloat32x4, Float32x4ToFloat64x2, 0xa936b421)      \
+  V(_Float64x2, get:x, Float64x2GetX, 0xd83e5791)                              \
+  V(_Float64x2, get:y, Float64x2GetY, 0xc5cfb2b4)                              \
+  V(_Float64x2, unary-, Float64x2Negate, 0x48fab485)                           \
+  V(_Float64x2, abs, Float64x2Abs, 0x4dbe5821)                                 \
+  V(_Float64x2, sqrt, Float64x2Sqrt, 0x476ed48b)                               \
+  V(_Float64x2, get:signMask, Float64x2GetSignMask, 0x00b7b96d)                \
+  V(_Float64x2, scale, Float64x2Scale, 0xc0dcdf5b)                             \
+  V(_Float64x2, _withX, Float64x2WithX, 0xc03d3708)                            \
+  V(_Float64x2, _withY, Float64x2WithY, 0xb8df4b9c)                            \
+  V(_Float64x2, min, Float64x2Min,  0x6b5e1755)                                \
+  V(_Float64x2, max, Float64x2Max,  0x4d8d9926)                                \
+  V(Int32x4, _Int32x4FromInts, Int32x4FromInts, 0xa646ec55)                    \
+  V(Int32x4, _Int32x4FromBools, Int32x4FromBools, 0x5e05beed)                  \
+  V(Int32x4, Int32x4.fromFloat32x4Bits, Float32x4ToInt32x4, 0x7893999c)        \
+  V(_Int32x4, get:flagX, Int32x4GetFlagX, 0x7713cbb9)                          \
+  V(_Int32x4, get:flagY, Int32x4GetFlagY, 0x92840299)                          \
+  V(_Int32x4, get:flagZ, Int32x4GetFlagZ, 0xa02d9dec)                          \
+  V(_Int32x4, get:flagW, Int32x4GetFlagW, 0xa94db02d)                          \
+  V(_Int32x4, get:signMask, Int32x4GetSignMask, 0x00b7b96d)                    \
+  V(_Int32x4, shuffle, Int32x4Shuffle, 0x149a8b16)                             \
+  V(_Int32x4, shuffleMix, Int32x4ShuffleMix, 0xd017e89f)                       \
+  V(_Int32x4, select, Int32x4Select, 0x2847cb63)                               \
+  V(_Int32x4, _withFlagX, Int32x4WithFlagX, 0xa365d5a6)                        \
+  V(_Int32x4, _withFlagY, Int32x4WithFlagY, 0x945670e9)                        \
+  V(_Int32x4, _withFlagZ, Int32x4WithFlagZ, 0x938c5d97)                        \
+  V(_Int32x4, _withFlagW, Int32x4WithFlagW, 0x9ebace9b)                        \
+  V(_HashVMBase, get:_index, LinkedHashMap_getIndex, 0xe161439b)               \
+  V(_HashVMBase, set:_index, LinkedHashMap_setIndex, 0x8c899997)               \
+  V(_HashVMBase, get:_data, LinkedHashMap_getData, 0xb1d039ec)                 \
+  V(_HashVMBase, set:_data, LinkedHashMap_setData, 0x7c713c68)                 \
+  V(_HashVMBase, get:_usedData, LinkedHashMap_getUsedData, 0xcb55342c)         \
+  V(_HashVMBase, set:_usedData, LinkedHashMap_setUsedData, 0x4b6bbba8)         \
+  V(_HashVMBase, get:_hashMask, LinkedHashMap_getHashMask, 0xd35b67db)         \
+  V(_HashVMBase, set:_hashMask, LinkedHashMap_setHashMask, 0x5371ef57)         \
+  V(_HashVMBase, get:_deletedKeys, LinkedHashMap_getDeletedKeys, 0xd55a64df)   \
+  V(_HashVMBase, set:_deletedKeys, LinkedHashMap_setDeletedKeys, 0x5570ec5b)   \
+  V(::, _classRangeCheck, ClassRangeCheck, 0x44ba948a)                         \
+  V(::, _asyncStackTraceHelper, AsyncStackTraceHelper, 0x92cea920)             \
+  V(::, _abi, FfiAbi, 0x00a48dda)                                              \
+  V(::, _asFunctionInternal, FfiAsFunctionInternal, 0x4ea3f661)                \
+  V(::, _nativeCallbackFunction, FfiNativeCallbackFunction, 0xe7a60ce3)        \
+  V(::, _loadInt8, FfiLoadInt8, 0x7b779ed3)                                    \
+  V(::, _loadInt16, FfiLoadInt16, 0x58b6f02a)                                  \
+  V(::, _loadInt32, FfiLoadInt32, 0x5a94fec0)                                  \
+  V(::, _loadInt64, FfiLoadInt64, 0x4b627ea0)                                  \
+  V(::, _loadUint8, FfiLoadUint8, 0x4dc0dbce)                                  \
+  V(::, _loadUint16, FfiLoadUint16, 0x79491be7)                                \
+  V(::, _loadUint32, FfiLoadUint32, 0x62e14f52)                                \
+  V(::, _loadUint64, FfiLoadUint64, 0x7178bcc9)                                \
+  V(::, _loadIntPtr, FfiLoadIntPtr, 0x584c733b)                                \
+  V(::, _loadFloat, FfiLoadFloat, 0x7f0471da)                                  \
+  V(::, _loadDouble, FfiLoadDouble, 0x7d37b396)                                \
+  V(::, _loadPointer, FfiLoadPointer, 0x3691c04d)                              \
+  V(::, _storeInt8, FfiStoreInt8, 0x118e5bc9)                                  \
+  V(::, _storeInt16, FfiStoreInt16, 0x0a8b9fef)                                \
+  V(::, _storeInt32, FfiStoreInt32, 0x2e23d91a)                                \
+  V(::, _storeInt64, FfiStoreInt64, 0x2411ba37)                                \
+  V(::, _storeUint8, FfiStoreUint8, 0x37ab7fb3)                                \
+  V(::, _storeUint16, FfiStoreUint16, 0x153b579b)                              \
+  V(::, _storeUint32, FfiStoreUint32, 0x18159582)                              \
+  V(::, _storeUint64, FfiStoreUint64, 0x1516def6)                              \
+  V(::, _storeIntPtr, FfiStoreIntPtr, 0x3a401365)                              \
+  V(::, _storeFloat, FfiStoreFloat, 0x23292bbb)                                \
+  V(::, _storeDouble, FfiStoreDouble, 0x013dc7a1)                              \
+  V(::, _storePointer, FfiStorePointer, 0x43c38f62)                            \
+  V(::, _fromAddress, FfiFromAddress, 0xab4ae553)                              \
+  V(Pointer, get:address, FfiGetAddress, 0x012b2b9f)                           \
+  V(::, reachabilityFence, ReachabilityFence, 0xad39d0a6)                      \
   V(_Utf8Decoder, _scan, Utf8DecoderScan, 0x78f44c3c)                          \
+  V(_Future, timeout, FutureTimeout, 0x010f8ad4)                               \
 
 // List of intrinsics:
 // (class-name, function-name, intrinsification method, fingerprint).
 #define CORE_LIB_INTRINSIC_LIST(V)                                             \
-  V(_Smi, ~, Smi_bitNegate, 0x2f002cba)                                        \
-  V(_Smi, get:bitLength, Smi_bitLength, 0x277b8ace)                            \
-  V(_Smi, _bitAndFromSmi, Smi_bitAndFromSmi, 0x90b94dd3)                       \
-  V(_BigIntImpl, _lsh, Bigint_lsh, 0x776e33c7)                                 \
-  V(_BigIntImpl, _rsh, Bigint_rsh, 0x2bf277fc)                                 \
-  V(_BigIntImpl, _absAdd, Bigint_absAdd, 0x147eb8ec)                           \
-  V(_BigIntImpl, _absSub, Bigint_absSub, 0xed4c4e74)                           \
-  V(_BigIntImpl, _mulAdd, Bigint_mulAdd, 0x634f75a0)                           \
-  V(_BigIntImpl, _sqrAdd, Bigint_sqrAdd, 0xc0a29ed4)                           \
+  V(_Smi, ~, Smi_bitNegate, 0x068652b8)                                        \
+  V(_Smi, get:bitLength, Smi_bitLength, 0xff01b0cc)                            \
+  V(_Smi, _bitAndFromSmi, Smi_bitAndFromSmi, 0xa483e093)                       \
+  V(_BigIntImpl, _lsh, Bigint_lsh, 0x772fb5fd)                                 \
+  V(_BigIntImpl, _rsh, Bigint_rsh, 0xb52a24b8)                                 \
+  V(_BigIntImpl, _absAdd, Bigint_absAdd, 0x90dc61a8)                           \
+  V(_BigIntImpl, _absSub, Bigint_absSub, 0x76887330)                           \
+  V(_BigIntImpl, _mulAdd, Bigint_mulAdd, 0xb2741296)                           \
+  V(_BigIntImpl, _sqrAdd, Bigint_sqrAdd, 0xcee0facc)                           \
   V(_BigIntImpl, _estimateQuotientDigit, Bigint_estimateQuotientDigit,         \
-    0x03b20399)                                                                \
-  V(_BigIntMontgomeryReduction, _mulMod, Montgomery_mulMod, 0x3b707797)        \
-  V(_Double, >, Double_greaterThan, 0x682a02bc)                                \
-  V(_Double, >=, Double_greaterEqualThan, 0x2961f8ee)                          \
-  V(_Double, <, Double_lessThan, 0xcbff42e5)                                   \
-  V(_Double, <=, Double_lessEqualThan, 0xd2253d90)                             \
-  V(_Double, ==, Double_equal, 0x6a306911)                                     \
-  V(_Double, +, Double_add, 0xf7d8da94)                                        \
-  V(_Double, -, Double_sub, 0xc8dda725)                                        \
-  V(_Double, *, Double_mul, 0x2dac85a2)                                        \
-  V(_Double, /, Double_div, 0x6cf1f09e)                                        \
-  V(_Double, get:hashCode, Double_hashCode, 0x22a75218)                        \
-  V(_Double, get:_identityHashCode, Double_identityHash, 0xf46be6d6)           \
-  V(_Double, get:isNaN, Double_getIsNaN, 0xb177a8f6)                           \
-  V(_Double, get:isInfinite, Double_getIsInfinite, 0xa1e96db5)                 \
-  V(_Double, get:isNegative, Double_getIsNegative, 0xb15ff274)                 \
-  V(_Double, _mulFromInteger, Double_mulFromInteger, 0xe2853768)               \
-  V(_Double, .fromInteger, DoubleFromInteger, 0x89504536)                      \
-  V(_GrowableList, ._withData, GrowableArray_Allocate, 0x5cfd6a7f)             \
-  V(_RegExp, _ExecuteMatch, RegExp_ExecuteMatch, 0xb961fc8d)                   \
-  V(_RegExp, _ExecuteMatchSticky, RegExp_ExecuteMatchSticky, 0xb22daf53)       \
-  V(Object, ==, ObjectEquals, 0x91ead0d6)                                      \
-  V(Object, get:runtimeType, ObjectRuntimeType, 0x8cdba093)                    \
-  V(Object, _haveSameRuntimeType, ObjectHaveSameRuntimeType, 0xcee5d65a)       \
-  V(_StringBase, get:hashCode, String_getHashCode, 0x22a75237)                 \
-  V(_StringBase, get:_identityHashCode, String_identityHash, 0xf46be6f5)       \
-  V(_StringBase, get:isEmpty, StringBaseIsEmpty, 0xd7218394)                   \
-  V(_StringBase, _substringMatches, StringBaseSubstringMatches, 0x46fc3731)    \
-  V(_StringBase, [], StringBaseCharAt, 0xe67164fe)                             \
-  V(_OneByteString, get:hashCode, OneByteString_getHashCode, 0x22a75237)       \
+    0x14527ed9)                                                                \
+  V(_BigIntMontgomeryReduction, _mulMod, Montgomery_mulMod, 0x08df2795)        \
+  V(_Double, >, Double_greaterThan, 0xe88b6ffc)                                \
+  V(_Double, >=, Double_greaterEqualThan, 0x1fb70bae)                          \
+  V(_Double, <, Double_lessThan, 0xae875025)                                   \
+  V(_Double, <=, Double_lessEqualThan, 0xc87a5050)                             \
+  V(_Double, ==, Double_equal, 0x5299f1d2)                                     \
+  V(_Double, +, Double_add, 0x783a47d4)                                        \
+  V(_Double, -, Double_sub, 0x493f1465)                                        \
+  V(_Double, *, Double_mul, 0xae0df2e2)                                        \
+  V(_Double, /, Double_div, 0xed535dde)                                        \
+  V(_Double, get:hashCode, Double_hashCode, 0xfa2d7816)                        \
+  V(_Double, get:_identityHashCode, Double_identityHash, 0xcbf20cd4)           \
+  V(_Double, get:isNaN, Double_getIsNaN, 0x88fdcef4)                           \
+  V(_Double, get:isInfinite, Double_getIsInfinite, 0x796f93b3)                 \
+  V(_Double, get:isNegative, Double_getIsNegative, 0x88e61872)                 \
+  V(_Double, _mulFromInteger, Double_mulFromInteger, 0xc5afaa28)               \
+  V(_Double, .fromInteger, DoubleFromInteger, 0x9d1ad7f6)                      \
+  V(_GrowableList, ._withData, GrowableArray_Allocate, 0x00be5928)             \
+  V(_RegExp, _ExecuteMatch, RegExp_ExecuteMatch, 0x6817556e)                   \
+  V(_RegExp, _ExecuteMatchSticky, RegExp_ExecuteMatchSticky, 0x60e30834)       \
+  V(Object, ==, ObjectEquals, 0xbc3cad49)                                      \
+  V(Object, get:runtimeType, ObjectRuntimeType, 0x6461c691)                    \
+  V(Object, _haveSameRuntimeType, ObjectHaveSameRuntimeType, 0xa66bfc58)       \
+  V(_StringBase, get:hashCode, String_getHashCode, 0xfa2d7835)                 \
+  V(_StringBase, get:_identityHashCode, String_identityHash, 0xcbf20cf3)       \
+  V(_StringBase, get:isEmpty, StringBaseIsEmpty, 0xbdfe9c92)                   \
+  V(_StringBase, _substringMatches, StringBaseSubstringMatches, 0xf5c3c873)    \
+  V(_StringBase, [], StringBaseCharAt, 0xfa3bf7be)                             \
+  V(_OneByteString, get:hashCode, OneByteString_getHashCode, 0xfa2d7835)       \
   V(_OneByteString, _substringUncheckedNative,                                 \
-    OneByteString_substringUnchecked,  0x94c41563)                             \
-  V(_OneByteString, ==, OneByteString_equality, 0xe1ea0c11)                    \
-  V(_TwoByteString, ==, TwoByteString_equality, 0xe1ea0c11)                    \
-  V(_Type, get:hashCode, Type_getHashCode, 0x22a75237)                         \
-  V(_Type, ==, Type_equality, 0x91ead098)                                      \
-  V(::, _getHash, Object_getHash, 0xb05aa13f)                                  \
-  V(::, _setHash, Object_setHash, 0xcb404dd2)                                  \
+    OneByteString_substringUnchecked,  0x0d39e4a1)                             \
+  V(_OneByteString, ==, OneByteString_equality, 0x3399ded1)                    \
+  V(_TwoByteString, ==, TwoByteString_equality, 0x3399ded1)                    \
+  V(_Type, get:hashCode, Type_getHashCode, 0xfa2d7835)                         \
+  V(_Type, ==, Type_equality, 0xbc3cad0b)                                      \
+  V(::, _getHash, Object_getHash, 0x87e0c73d)                                  \
+  V(::, _setHash, Object_setHash, 0xcb4f51d2)                                  \
 
 #define CORE_INTEGER_LIB_INTRINSIC_LIST(V)                                     \
   V(_IntegerImplementation, _addFromInteger, Integer_addFromInteger,           \
-    0xc7bd74ae)                                                                \
-  V(_IntegerImplementation, +, Integer_add, 0x49774600)                        \
+    0xdb88076e)                                                                \
+  V(_IntegerImplementation, +, Integer_add, 0x9b2718c0)                        \
   V(_IntegerImplementation, _subFromInteger, Integer_subFromInteger,           \
-    0x8e0de2a2)                                                                \
-  V(_IntegerImplementation, -, Integer_sub, 0x1a853bf1)                        \
+    0xa1d87562)                                                                \
+  V(_IntegerImplementation, -, Integer_sub, 0x6c350eb1)                        \
   V(_IntegerImplementation, _mulFromInteger, Integer_mulFromInteger,           \
-    0x95751a41)                                                                \
-  V(_IntegerImplementation, *, Integer_mul, 0xefe7fbce)                        \
+    0xa93fad01)                                                                \
+  V(_IntegerImplementation, *, Integer_mul, 0x4197ce8e)                        \
   V(_IntegerImplementation, _moduloFromInteger, Integer_moduloFromInteger,     \
-    0xbc75fece)                                                                \
-  V(_IntegerImplementation, ~/, Integer_truncDivide, 0x42d9b723)               \
-  V(_IntegerImplementation, unary-, Integer_negate, 0xdb5f0d70)                \
+    0xd040918e)                                                                \
+  V(_IntegerImplementation, ~/, Integer_truncDivide, 0x79adb402)               \
+  V(_IntegerImplementation, unary-, Integer_negate, 0xf07a7709)                \
   V(_IntegerImplementation, _bitAndFromInteger, Integer_bitAndFromInteger,     \
-    0xb7e724d2)                                                                \
-  V(_IntegerImplementation, &, Integer_bitAnd, 0xd9888ca4)                     \
+    0xcbb1b792)                                                                \
+  V(_IntegerImplementation, &, Integer_bitAnd, 0x2b385f64)                     \
   V(_IntegerImplementation, _bitOrFromInteger, Integer_bitOrFromInteger,       \
-    0xa97501aa)                                                                \
-  V(_IntegerImplementation, |, Integer_bitOr, 0xc82cc85c)                      \
+    0xbd3f946a)                                                                \
+  V(_IntegerImplementation, |, Integer_bitOr, 0x19dc9b1c)                      \
   V(_IntegerImplementation, _bitXorFromInteger, Integer_bitXorFromInteger,     \
-    0x9ab4d16e)                                                                \
-  V(_IntegerImplementation, ^, Integer_bitXor, 0xc1ed9463)                     \
+    0xae7f642e)                                                                \
+  V(_IntegerImplementation, ^, Integer_bitXor, 0x139d6723)                     \
   V(_IntegerImplementation, _greaterThanFromInteger,                           \
-    Integer_greaterThanFromInt, 0x3366ff66)                                    \
-  V(_IntegerImplementation, >, Integer_greaterThan, 0xe74b678c)                \
-  V(_IntegerImplementation, ==, Integer_equal, 0xdf47652c)                     \
+    Integer_greaterThanFromInt, 0x47319226)                                    \
+  V(_IntegerImplementation, >, Integer_greaterThan, 0xc9d374cc)                \
+  V(_IntegerImplementation, ==, Integer_equal, 0xca4e7087)                     \
   V(_IntegerImplementation, _equalToInteger, Integer_equalToInteger,           \
-    0x39d3cd05)                                                                \
-  V(_IntegerImplementation, <, Integer_lessThan, 0xcbff42e5)                   \
-  V(_IntegerImplementation, <=, Integer_lessEqualThan, 0xd2253d90)             \
-  V(_IntegerImplementation, >=, Integer_greaterEqualThan, 0x2961f8ee)          \
-  V(_IntegerImplementation, <<, Integer_shl, 0x972a7fd6)                       \
-  V(_IntegerImplementation, >>, Integer_sar, 0xfe022e7b)                       \
-  V(_Double, toInt, DoubleToInteger, 0x14433ded)                               \
+    0x4d9e5fc5)                                                                \
+  V(_IntegerImplementation, <, Integer_lessThan, 0xae875025)                   \
+  V(_IntegerImplementation, <=, Integer_lessEqualThan, 0xc87a5050)             \
+  V(_IntegerImplementation, >=, Integer_greaterEqualThan, 0x1fb70bae)          \
+  V(_IntegerImplementation, <<, Integer_shl, 0xe8da5296)                       \
+  V(_IntegerImplementation, >>, Integer_sar, 0x4fb2013b)                       \
+  V(_Double, toInt, DoubleToInteger, 0xebc963eb)                               \
 
 #define MATH_LIB_INTRINSIC_LIST(V)                                             \
-  V(::, sqrt, MathSqrt, 0x2c20a879)                                            \
-  V(_Random, _nextState, Random_nextState, 0x30682e3d)                         \
+  V(::, sqrt, MathSqrt, 0x98d7cb39)                                            \
+  V(_Random, _nextState, Random_nextState, 0x3077323d)                         \
 
 #define GRAPH_MATH_LIB_INTRINSIC_LIST(V)                                       \
-  V(::, sin, MathSin, 0x18e743c0)                                              \
-  V(::, cos, MathCos, 0x6623c0ce)                                              \
-  V(::, tan, MathTan, 0x3584ee62)                                              \
-  V(::, asin, MathAsin, 0xb023f0df)                                            \
-  V(::, acos, MathAcos, 0x165661fa)                                            \
-  V(::, atan, MathAtan, 0xc91eca17)                                            \
-  V(::, atan2, MathAtan2, 0x79b3a5e6)                                          \
+  V(::, sin, MathSin, 0x859e6680)                                              \
+  V(::, cos, MathCos, 0xd2dae38e)                                              \
+  V(::, tan, MathTan, 0xa23c1122)                                              \
+  V(::, asin, MathAsin, 0x1cdb139f)                                            \
+  V(::, acos, MathAcos, 0x830d84ba)                                            \
+  V(::, atan, MathAtan, 0x35d5ecd7)                                            \
+  V(::, atan2, MathAtan2, 0xb4e03ae8)                                          \
 
 #define TYPED_DATA_LIB_INTRINSIC_LIST(V)                                       \
-  V(Int8List, ., TypedData_Int8Array_factory, 0x6ce2f102)                      \
-  V(Uint8List, ., TypedData_Uint8Array_factory, 0x1163d489)                    \
-  V(Uint8ClampedList, ., TypedData_Uint8ClampedArray_factory, 0x0b0e9f0f)      \
-  V(Int16List, ., TypedData_Int16Array_factory, 0x6addd02d)                    \
-  V(Uint16List, ., TypedData_Uint16Array_factory, 0x139a6464)                  \
-  V(Int32List, ., TypedData_Int32Array_factory, 0x40dad19a)                    \
-  V(Uint32List, ., TypedData_Uint32Array_factory, 0x988357c5)                  \
-  V(Int64List, ., TypedData_Int64Array_factory, 0xef0a3469)                    \
-  V(Uint64List, ., TypedData_Uint64Array_factory, 0xf49c0472)                  \
-  V(Float32List, ., TypedData_Float32Array_factory, 0x779b26f8)                \
-  V(Float64List, ., TypedData_Float64Array_factory, 0xf623554b)                \
-  V(Float32x4List, ., TypedData_Float32x4Array_factory, 0x9edf5402)            \
-  V(Int32x4List, ., TypedData_Int32x4Array_factory, 0x915e8e68)                \
-  V(Float64x2List, ., TypedData_Float64x2Array_factory, 0x0d206864)            \
+  V(Int8List, ., TypedData_Int8Array_factory, 0x80ad83c2)                      \
+  V(Uint8List, ., TypedData_Uint8Array_factory, 0x252e6749)                    \
+  V(Uint8ClampedList, ., TypedData_Uint8ClampedArray_factory, 0x1ed931cf)      \
+  V(Int16List, ., TypedData_Int16Array_factory, 0x7ea862ed)                    \
+  V(Uint16List, ., TypedData_Uint16Array_factory, 0x2764f724)                  \
+  V(Int32List, ., TypedData_Int32Array_factory, 0x54a5645a)                    \
+  V(Uint32List, ., TypedData_Uint32Array_factory, 0xac4dea85)                  \
+  V(Int64List, ., TypedData_Int64Array_factory, 0x02d4c729)                    \
+  V(Uint64List, ., TypedData_Uint64Array_factory, 0x08669732)                  \
+  V(Float32List, ., TypedData_Float32Array_factory, 0x8b65b9b8)                \
+  V(Float64List, ., TypedData_Float64Array_factory, 0x09ede80b)                \
+  V(Float32x4List, ., TypedData_Float32x4Array_factory, 0xb2a9e6c2)            \
+  V(Int32x4List, ., TypedData_Int32x4Array_factory, 0xa5292128)                \
+  V(Float64x2List, ., TypedData_Float64x2Array_factory, 0x20eafb24)            \
 
 #define GRAPH_TYPED_DATA_INTRINSICS_LIST(V)                                    \
-  V(_Int8List, [], Int8ArrayGetIndexed, 0xdab47d5d)                            \
-  V(_Int8List, []=, Int8ArraySetIndexed, 0x09ba0f32)                           \
-  V(_Uint8List, [], Uint8ArrayGetIndexed, 0xa9468b1d)                          \
-  V(_Uint8List, []=, Uint8ArraySetIndexed, 0xa6fd9dce)                         \
-  V(_ExternalUint8Array, [], ExternalUint8ArrayGetIndexed, 0xa9468b1d)         \
-  V(_ExternalUint8Array, []=, ExternalUint8ArraySetIndexed, 0xa6fd9dce)        \
-  V(_Uint8ClampedList, [], Uint8ClampedArrayGetIndexed, 0xa9468b1d)            \
-  V(_Uint8ClampedList, []=, Uint8ClampedArraySetIndexed, 0x7d60b42e)           \
+  V(_Int8List, [], Int8ArrayGetIndexed, 0xd61e79bd)                            \
+  V(_Int8List, []=, Int8ArraySetIndexed, 0x6e0b2e72)                           \
+  V(_Uint8List, [], Uint8ArrayGetIndexed, 0xe1a67dfd)                          \
+  V(_Uint8List, []=, Uint8ArraySetIndexed, 0x89499a2e)                         \
+  V(_ExternalUint8Array, [], ExternalUint8ArrayGetIndexed, 0xe1a67dfd)         \
+  V(_ExternalUint8Array, []=, ExternalUint8ArraySetIndexed, 0x89499a2e)        \
+  V(_Uint8ClampedList, [], Uint8ClampedArrayGetIndexed, 0xe1a67dfd)            \
+  V(_Uint8ClampedList, []=, Uint8ClampedArraySetIndexed, 0x5facb08e)           \
   V(_ExternalUint8ClampedArray, [], ExternalUint8ClampedArrayGetIndexed,       \
-    0xa9468b1d)                                                                \
+    0xe1a67dfd)                                                                \
   V(_ExternalUint8ClampedArray, []=, ExternalUint8ClampedArraySetIndexed,      \
-    0x7d60b42e)                                                                \
-  V(_Int16List, [], Int16ArrayGetIndexed, 0x2b783e9d)                          \
-  V(_Int16List, []=, Int16ArraySetIndexed, 0x894edd67)                         \
-  V(_Uint16List, [], Uint16ArrayGetIndexed, 0x3d599bdd)                        \
-  V(_Uint16List, []=, Uint16ArraySetIndexed, 0x146065d0)                       \
-  V(_Int32List, [], Int32ArrayGetIndexed, 0x645ac57e)                          \
-  V(_Int32List, []=, Int32ArraySetIndexed, 0x58343408)                         \
-  V(_Uint32List, [], Uint32ArrayGetIndexed, 0xe6f6183e)                        \
-  V(_Uint32List, []=, Uint32ArraySetIndexed, 0x7ee99568)                       \
-  V(_Int64List, [], Int64ArrayGetIndexed, 0x57d917de)                          \
-  V(_Int64List, []=, Int64ArraySetIndexed, 0x94485c32)                         \
-  V(_Uint64List, [], Uint64ArrayGetIndexed, 0x7fb017de)                        \
-  V(_Uint64List, []=, Uint64ArraySetIndexed, 0x1c695796)                       \
-  V(_Float64List, [], Float64ArrayGetIndexed, 0x9e20a2c3)                      \
-  V(_Float64List, []=, Float64ArraySetIndexed, 0xcd01ec0c)                     \
-  V(_Float32List, [], Float32ArrayGetIndexed, 0x7c01bb83)                      \
-  V(_Float32List, []=, Float32ArraySetIndexed, 0xcb87f800)                     \
-  V(_Float32x4List, [], Float32x4ArrayGetIndexed, 0x5a2a83fc)                  \
-  V(_Float32x4List, []=, Float32x4ArraySetIndexed, 0x5ae5c9f3)                 \
-  V(_Int32x4List, [], Int32x4ArrayGetIndexed, 0x05ef16d4)                      \
-  V(_Int32x4List, []=, Int32x4ArraySetIndexed, 0x2e8437b1)                     \
-  V(_Float64x2List, [], Float64x2ArrayGetIndexed, 0xe7fbf246)                  \
-  V(_Float64x2List, []=, Float64x2ArraySetIndexed, 0xce826d19)                 \
-  V(_TypedList, get:length, TypedListLength, 0x05176aac)                       \
-  V(_TypedListView, get:length, TypedListViewLength, 0x05176aac)               \
-  V(_ByteDataView, get:length, ByteDataViewLength, 0x05176aac)                 \
-  V(_Float32x4, get:x, Float32x4ShuffleX, 0x00b83193)                          \
-  V(_Float32x4, get:y, Float32x4ShuffleY, 0xee498cb6)                          \
-  V(_Float32x4, get:z, Float32x4ShuffleZ, 0x2414f84c)                          \
-  V(_Float32x4, get:w, Float32x4ShuffleW, 0x06553cce)                          \
-  V(_Float32x4, *, Float32x4Mul, 0xf817cb64)                                   \
-  V(_Float32x4, /, Float32x4Div, 0xd36681e1)                                   \
-  V(_Float32x4, -, Float32x4Sub, 0xeff9bb27)                                   \
-  V(_Float32x4, +, Float32x4Add, 0xcac0f0b6)                                   \
-  V(_Float64x2, *, Float64x2Mul, 0x589c7905)                                   \
-  V(_Float64x2, /, Float64x2Div, 0x33eb2fa1)                                   \
-  V(_Float64x2, -, Float64x2Sub, 0x507e68c8)                                   \
-  V(_Float64x2, +, Float64x2Add, 0x2b459e57)                                   \
+    0x5facb08e)                                                                \
+  V(_Int16List, [], Int16ArrayGetIndexed, 0x1726ae5d)                          \
+  V(_Int16List, []=, Int16ArraySetIndexed, 0xde0f4d87)                         \
+  V(_Uint16List, [], Uint16ArrayGetIndexed, 0x26c2525d)                        \
+  V(_Uint16List, []=, Uint16ArraySetIndexed, 0x69ae5b30)                       \
+  V(_Int32List, [], Int32ArrayGetIndexed, 0x407e58de)                          \
+  V(_Int32List, []=, Int32ArraySetIndexed, 0x61194108)                         \
+  V(_Uint32List, [], Uint32ArrayGetIndexed, 0xf078bf3e)                        \
+  V(_Uint32List, []=, Uint32ArraySetIndexed, 0x70f53c88)                       \
+  V(_Int64List, [], Int64ArrayGetIndexed, 0x7c21b69e)                          \
+  V(_Int64List, []=, Int64ArraySetIndexed, 0xcaa7c6ca)                         \
+  V(_Uint64List, [], Uint64ArrayGetIndexed, 0x0a7aa11e)                        \
+  V(_Uint64List, []=, Uint64ArraySetIndexed, 0xd1374e92)                       \
+  V(_Float64List, [], Float64ArrayGetIndexed, 0x9e4b2403)                      \
+  V(_Float64List, []=, Float64ArraySetIndexed, 0x0a43d538)                     \
+  V(_Float32List, [], Float32ArrayGetIndexed, 0xbdf87ee3)                      \
+  V(_Float32List, []=, Float32ArraySetIndexed, 0x2e3e1a4a)                     \
+  V(_Float32x4List, [], Float32x4ArrayGetIndexed, 0xa90520bc)                  \
+  V(_Float32x4List, []=, Float32x4ArraySetIndexed, 0xb9c7400f)                 \
+  V(_Int32x4List, [], Int32x4ArrayGetIndexed, 0xfbcc0e74)                      \
+  V(_Int32x4List, []=, Int32x4ArraySetIndexed, 0x79152aaf)                     \
+  V(_Float64x2List, [], Float64x2ArrayGetIndexed, 0xd90a31e6)                  \
+  V(_Float64x2List, []=, Float64x2ArraySetIndexed, 0x4fd191fb)                 \
+  V(_TypedList, get:length, TypedListLength, 0xdc9d90aa)                       \
+  V(_TypedListView, get:length, TypedListViewLength, 0xdc9d90aa)               \
+  V(_ByteDataView, get:length, ByteDataViewLength, 0xdc9d90aa)                 \
+  V(_Float32x4, get:x, Float32x4ShuffleX, 0xd83e5791)                          \
+  V(_Float32x4, get:y, Float32x4ShuffleY, 0xc5cfb2b4)                          \
+  V(_Float32x4, get:z, Float32x4ShuffleZ, 0xfb9b1e4a)                          \
+  V(_Float32x4, get:w, Float32x4ShuffleW, 0xdddb62cc)                          \
+  V(_Float32x4, *, Float32x4Mul, 0x0be25e24)                                   \
+  V(_Float32x4, /, Float32x4Div, 0xe73114a1)                                   \
+  V(_Float32x4, -, Float32x4Sub, 0x03c44de7)                                   \
+  V(_Float32x4, +, Float32x4Add, 0xde8b8376)                                   \
+  V(_Float64x2, *, Float64x2Mul, 0x6c670bc5)                                   \
+  V(_Float64x2, /, Float64x2Div, 0x47b5c261)                                   \
+  V(_Float64x2, -, Float64x2Sub, 0x6448fb88)                                   \
+  V(_Float64x2, +, Float64x2Add, 0x3f103117)                                   \
 
 #define GRAPH_CORE_INTRINSICS_LIST(V)                                          \
-  V(_List, get:length, ObjectArrayLength, 0x05176aac)                          \
-  V(_List, [], ObjectArrayGetIndexed, 0x7e13418e)                              \
-  V(_List, _setIndexed, ObjectArraySetIndexedUnchecked, 0x91b2c203)            \
-  V(_ImmutableList, get:length, ImmutableArrayLength, 0x05176aac)              \
-  V(_ImmutableList, [], ImmutableArrayGetIndexed, 0x7e13418e)                  \
-  V(_GrowableList, get:length, GrowableArrayLength, 0x05176aac)                \
-  V(_GrowableList, get:_capacity, GrowableArrayCapacity, 0x2a661633)           \
-  V(_GrowableList, _setData, GrowableArraySetData, 0x9e2350fe)                 \
-  V(_GrowableList, _setLength, GrowableArraySetLength, 0x8d94d91d)             \
-  V(_GrowableList, [], GrowableArrayGetIndexed, 0x7e13418e)                    \
-  V(_GrowableList, _setIndexed, GrowableArraySetIndexedUnchecked, 0x91b2c203)  \
-  V(_StringBase, get:length, StringBaseLength, 0x05176aac)                     \
-  V(_OneByteString, codeUnitAt, OneByteStringCodeUnitAt, 0xb0959953)           \
-  V(_TwoByteString, codeUnitAt, TwoByteStringCodeUnitAt, 0xb0959953)           \
+  V(_List, get:length, ObjectArrayLength, 0xdc9d90aa)                          \
+  V(_List, [], ObjectArrayGetIndexed, 0xd159dece)                              \
+  V(_List, _setIndexed, ObjectArraySetIndexedUnchecked, 0xf5780f43)            \
+  V(_ImmutableList, get:length, ImmutableArrayLength, 0xdc9d90aa)              \
+  V(_ImmutableList, [], ImmutableArrayGetIndexed, 0xd159dece)                  \
+  V(_GrowableList, get:length, GrowableArrayLength, 0xdc9d90aa)                \
+  V(_GrowableList, get:_capacity, GrowableArrayCapacity, 0x01ec3c31)           \
+  V(_GrowableList, _setData, GrowableArraySetData, 0x8ecf0a40)                 \
+  V(_GrowableList, _setLength, GrowableArraySetLength, 0x63da779b)             \
+  V(_GrowableList, [], GrowableArrayGetIndexed, 0xd159dece)                    \
+  V(_GrowableList, _setIndexed, GrowableArraySetIndexedUnchecked, 0x012e9e24)  \
+  V(_StringBase, get:length, StringBaseLength, 0xdc9d90aa)                     \
+  V(_OneByteString, codeUnitAt, OneByteStringCodeUnitAt, 0xc4602c13)           \
+  V(_TwoByteString, codeUnitAt, TwoByteStringCodeUnitAt, 0xc4602c13)           \
   V(_ExternalOneByteString, codeUnitAt, ExternalOneByteStringCodeUnitAt,       \
-    0xb0959953)                                                                \
+    0xc4602c13)                                                                \
   V(_ExternalTwoByteString, codeUnitAt, ExternalTwoByteStringCodeUnitAt,       \
-    0xb0959953)                                                                \
-  V(_Double, unary-, DoubleFlipSignBit, 0x039c6e4a)                            \
-  V(_Double, truncateToDouble, DoubleTruncate, 0x2960d21d)                     \
-  V(_Double, roundToDouble, DoubleRound, 0x1cd615c4)                           \
-  V(_Double, floorToDouble, DoubleFloor, 0x1b41170c)                           \
-  V(_Double, ceilToDouble, DoubleCeil, 0x25a81a9d)                             \
-  V(_Double, _modulo, DoubleMod, 0x42a93471)
+    0xc4602c13)                                                                \
+  V(_Double, unary-, DoubleFlipSignBit, 0xdb229448)                            \
+  V(_Double, truncateToDouble, DoubleTruncate, 0x00e6f81b)                     \
+  V(_Double, roundToDouble, DoubleRound, 0xf45c3bc2)                           \
+  V(_Double, floorToDouble, DoubleFloor, 0xf2c73d0a)                           \
+  V(_Double, ceilToDouble, DoubleCeil, 0xfd2e409b)                             \
+  V(_Double, _modulo, DoubleMod, 0x5673c731)
 
 #define GRAPH_INTRINSICS_LIST(V)                                               \
   GRAPH_CORE_INTRINSICS_LIST(V)                                                \
@@ -378,20 +379,20 @@
   GRAPH_MATH_LIB_INTRINSIC_LIST(V)                                             \
 
 #define DEVELOPER_LIB_INTRINSIC_LIST(V)                                        \
-  V(_UserTag, makeCurrent, UserTag_makeCurrent, 0x472d1eb5)                    \
-  V(::, _getDefaultTag, UserTag_defaultTag, 0x5c124271)                        \
-  V(::, _getCurrentTag, Profiler_getCurrentTag, 0x5d6d8a14)                    \
-  V(::, _isDartStreamEnabled, Timeline_isDartStreamEnabled, 0xcf6f3099)        \
+  V(_UserTag, makeCurrent, UserTag_makeCurrent, 0x1eb344b3)                    \
+  V(::, _getDefaultTag, UserTag_defaultTag, 0x2ef2e42c)                        \
+  V(::, _getCurrentTag, Profiler_getCurrentTag, 0x33c3ec15)                    \
+  V(::, _isDartStreamEnabled, Timeline_isDartStreamEnabled, 0x7dfcaa18)        \
 
 #define ASYNC_LIB_INTRINSIC_LIST(V)                                            \
-  V(::, _clearAsyncThreadStackTrace, ClearAsyncThreadStackTrace, 0x341efd8e)   \
-  V(::, _setAsyncThreadStackTrace, SetAsyncThreadStackTrace, 0x5f29f453)       \
+  V(::, _clearAsyncThreadStackTrace, ClearAsyncThreadStackTrace, 0x20fecac6)   \
+  V(::, _setAsyncThreadStackTrace, SetAsyncThreadStackTrace, 0x39346953)       \
 
 #define INTERNAL_LIB_INTRINSIC_LIST(V)                                         \
-  V(::, allocateOneByteString, AllocateOneByteString, 0x3e7f209a)              \
-  V(::, allocateTwoByteString, AllocateTwoByteString, 0x46445c37)              \
-  V(::, writeIntoOneByteString, WriteIntoOneByteString, 0x63d30528)            \
-  V(::, writeIntoTwoByteString, WriteIntoTwoByteString, 0x5b280bf1)            \
+  V(::, allocateOneByteString, AllocateOneByteString, 0xc86bebfa)              \
+  V(::, allocateTwoByteString, AllocateTwoByteString, 0xd0312797)              \
+  V(::, writeIntoOneByteString, WriteIntoOneByteString, 0xe0d28307)            \
+  V(::, writeIntoTwoByteString, WriteIntoTwoByteString, 0xd82789d0)            \
 
 #define ALL_INTRINSICS_NO_INTEGER_LIB_LIST(V)                                  \
   ASYNC_LIB_INTRINSIC_LIST(V)                                                  \
@@ -412,61 +413,64 @@
 
 // A list of core functions that internally dispatch based on received id.
 #define POLYMORPHIC_TARGET_LIST(V)                                             \
-  V(_StringBase, [], StringBaseCharAt, 0xe67164fe)                             \
-  V(_TypedList, _getInt8, ByteArrayBaseGetInt8, 0xa24c2704)                    \
-  V(_TypedList, _getUint8, ByteArrayBaseGetUint8, 0xa491df3e)                  \
-  V(_TypedList, _getInt16, ByteArrayBaseGetInt16, 0xb65ae1fc)                  \
-  V(_TypedList, _getUint16, ByteArrayBaseGetUint16, 0xb4b776e5)                \
-  V(_TypedList, _getInt32, ByteArrayBaseGetInt32, 0xb460abe4)                  \
-  V(_TypedList, _getUint32, ByteArrayBaseGetUint32, 0x8c066c71)                \
-  V(_TypedList, _getInt64, ByteArrayBaseGetInt64, 0xacf2f222)                  \
-  V(_TypedList, _getUint64, ByteArrayBaseGetUint64, 0xa74b200b)                \
-  V(_TypedList, _getFloat32, ByteArrayBaseGetFloat32, 0xa33a9f77)              \
-  V(_TypedList, _getFloat64, ByteArrayBaseGetFloat64, 0x87d86b60)              \
-  V(_TypedList, _getFloat32x4, ByteArrayBaseGetFloat32x4, 0x3e76086e)          \
-  V(_TypedList, _getInt32x4, ByteArrayBaseGetInt32x4, 0xfea5f17f)              \
-  V(_TypedList, _setInt8, ByteArrayBaseSetInt8, 0xd2c4e74b)                    \
-  V(_TypedList, _setUint8, ByteArrayBaseSetInt8, 0xec62b082)                   \
-  V(_TypedList, _setInt16, ByteArrayBaseSetInt16, 0xc3566903)                  \
-  V(_TypedList, _setUint16, ByteArrayBaseSetInt16, 0xdb50780f)                 \
-  V(_TypedList, _setInt32, ByteArrayBaseSetInt32, 0xbeeeea8a)                  \
-  V(_TypedList, _setUint32, ByteArrayBaseSetUint32, 0xca02f10a)                \
-  V(_TypedList, _setInt64, ByteArrayBaseSetInt64, 0xcf587ccf)                  \
-  V(_TypedList, _setUint64, ByteArrayBaseSetUint64, 0xe01a1df0)                \
-  V(_TypedList, _setFloat32, ByteArrayBaseSetFloat32, 0xb6a6294f)              \
-  V(_TypedList, _setFloat64, ByteArrayBaseSetFloat64, 0xce7dad17)              \
-  V(_TypedList, _setFloat32x4, ByteArrayBaseSetFloat32x4, 0x4b773b59)          \
-  V(_TypedList, _setInt32x4, ByteArrayBaseSetInt32x4, 0xfa2a6f88)              \
-  V(Object, get:runtimeType, ObjectRuntimeType, 0x8cdba093)
+  V(_StringBase, [], StringBaseCharAt, 0xfa3bf7be)                             \
+  V(_TypedList, _getInt8, ByteArrayBaseGetInt8, 0xc28aff37)                    \
+  V(_TypedList, _getUint8, ByteArrayBaseGetUint8, 0xc3e7212d)                  \
+  V(_TypedList, _getInt16, ByteArrayBaseGetInt16, 0xdaa7b952)                  \
+  V(_TypedList, _getUint16, ByteArrayBaseGetUint16, 0xdc2919bc)                \
+  V(_TypedList, _getInt32, ByteArrayBaseGetInt32, 0xc57f53af)                  \
+  V(_TypedList, _getUint32, ByteArrayBaseGetUint32, 0xc5c49520)                \
+  V(_TypedList, _getInt64, ByteArrayBaseGetInt64, 0xa2c7e6a4)                  \
+  V(_TypedList, _getUint64, ByteArrayBaseGetUint64, 0xd8c29ffe)                \
+  V(_TypedList, _getFloat32, ByteArrayBaseGetFloat32, 0xaf15f28a)              \
+  V(_TypedList, _getFloat64, ByteArrayBaseGetFloat64, 0xbe4987b7)              \
+  V(_TypedList, _getFloat32x4, ByteArrayBaseGetFloat32x4, 0x76c82c28)          \
+  V(_TypedList, _getInt32x4, ByteArrayBaseGetInt32x4, 0x29abed4e)              \
+  V(_TypedList, _setInt8, ByteArrayBaseSetInt8, 0xfc13ad87)                    \
+  V(_TypedList, _setUint8, ByteArrayBaseSetInt8, 0xc9e4212d)                   \
+  V(_TypedList, _setInt16, ByteArrayBaseSetInt16, 0xd570aa0c)                  \
+  V(_TypedList, _setUint16, ByteArrayBaseSetInt16, 0xe8acb234)                 \
+  V(_TypedList, _setInt32, ByteArrayBaseSetInt32, 0xd8651525)                  \
+  V(_TypedList, _setUint32, ByteArrayBaseSetUint32, 0xd3f10d97)                \
+  V(_TypedList, _setInt64, ByteArrayBaseSetInt64, 0xe357b95f)                  \
+  V(_TypedList, _setUint64, ByteArrayBaseSetUint64, 0xf4d19bea)                \
+  V(_TypedList, _setFloat32, ByteArrayBaseSetFloat32, 0xd6272645)              \
+  V(_TypedList, _setFloat64, ByteArrayBaseSetFloat64, 0xca4af137)              \
+  V(_TypedList, _setFloat32x4, ByteArrayBaseSetFloat32x4, 0x71767f7f)          \
+  V(_TypedList, _setInt32x4, ByteArrayBaseSetInt32x4, 0xf0483280)              \
+  V(Object, get:runtimeType, ObjectRuntimeType, 0x6461c691)
 
 // List of recognized list factories:
 // (factory-name-symbol, class-name-string, constructor-name-string,
 //  result-cid, fingerprint).
 #define RECOGNIZED_LIST_FACTORY_LIST(V)                                        \
-  V(_ListFactory, _List, ., kArrayCid, 0x03ddbd3a)                             \
-  V(_ListFilledFactory, _List, .filled, kArrayCid, 0x0)                        \
-  V(_GrowableListWithData, _GrowableList, ._withData, kGrowableObjectArrayCid, \
-    0x5cfd6a7f)                                                                \
-  V(_GrowableListFilledFactory, _GrowableList, .filled,                        \
-    kGrowableObjectArrayCid, 0x0)                                              \
+  V(_ListFactory, _List, ., kArrayCid, 0x6de199a1)                             \
+  V(_ListFilledFactory, _List, .filled, kArrayCid, 0x871c7eb6)                 \
+  V(_ListGenerateFactory, _List, .generate, kArrayCid, 0x045b9063)             \
   V(_GrowableListFactory, _GrowableList, ., kGrowableObjectArrayCid,           \
-    0x3eed680b)                                                                \
-  V(_Int8ArrayFactory, Int8List, ., kTypedDataInt8ArrayCid, 0x6ce2f102)        \
-  V(_Uint8ArrayFactory, Uint8List, ., kTypedDataUint8ArrayCid, 0x1163d489)     \
+    0xdc1f9e09)                                                                \
+  V(_GrowableListFilledFactory, _GrowableList, .filled,                        \
+    kGrowableObjectArrayCid, 0xbc894d36)                                       \
+  V(_GrowableListGenerateFactory, _GrowableList, .generate,                    \
+    kGrowableObjectArrayCid, 0xf6fbbee3)                                       \
+  V(_GrowableListWithData, _GrowableList, ._withData, kGrowableObjectArrayCid, \
+    0x00be5928)                                                                \
+  V(_Int8ArrayFactory, Int8List, ., kTypedDataInt8ArrayCid, 0x80ad83c2)        \
+  V(_Uint8ArrayFactory, Uint8List, ., kTypedDataUint8ArrayCid, 0x252e6749)     \
   V(_Uint8ClampedArrayFactory, Uint8ClampedList, .,                            \
-    kTypedDataUint8ClampedArrayCid, 0x0b0e9f0f)                                \
-  V(_Int16ArrayFactory, Int16List, ., kTypedDataInt16ArrayCid, 0x6addd02d)     \
-  V(_Uint16ArrayFactory, Uint16List, ., kTypedDataUint16ArrayCid, 0x139a6464)  \
-  V(_Int32ArrayFactory, Int32List, ., kTypedDataInt32ArrayCid, 0x40dad19a)     \
-  V(_Uint32ArrayFactory, Uint32List, ., kTypedDataUint32ArrayCid, 0x988357c5)  \
-  V(_Int64ArrayFactory, Int64List, ., kTypedDataInt64ArrayCid, 0xef0a3469)     \
-  V(_Uint64ArrayFactory, Uint64List, ., kTypedDataUint64ArrayCid, 0xf49c0472)  \
+    kTypedDataUint8ClampedArrayCid, 0x1ed931cf)                                \
+  V(_Int16ArrayFactory, Int16List, ., kTypedDataInt16ArrayCid, 0x7ea862ed)     \
+  V(_Uint16ArrayFactory, Uint16List, ., kTypedDataUint16ArrayCid, 0x2764f724)  \
+  V(_Int32ArrayFactory, Int32List, ., kTypedDataInt32ArrayCid, 0x54a5645a)     \
+  V(_Uint32ArrayFactory, Uint32List, ., kTypedDataUint32ArrayCid, 0xac4dea85)  \
+  V(_Int64ArrayFactory, Int64List, ., kTypedDataInt64ArrayCid, 0x02d4c729)     \
+  V(_Uint64ArrayFactory, Uint64List, ., kTypedDataUint64ArrayCid, 0x08669732)  \
   V(_Float64ArrayFactory, Float64List, ., kTypedDataFloat64ArrayCid,           \
-    0xf623554b)                                                                \
+    0x09ede80b)                                                                \
   V(_Float32ArrayFactory, Float32List, ., kTypedDataFloat32ArrayCid,           \
-    0x779b26f8)                                                                \
+    0x8b65b9b8)                                                                \
   V(_Float32x4ArrayFactory, Float32x4List, ., kTypedDataFloat32x4ArrayCid,     \
-    0x9edf5402)
+    0xb2a9e6c2)
 
 // clang-format on
 
diff --git a/runtime/vm/compiler/runtime_api.cc b/runtime/vm/compiler/runtime_api.cc
index 8948126..16b4c0c 100644
--- a/runtime/vm/compiler/runtime_api.cc
+++ b/runtime/vm/compiler/runtime_api.cc
@@ -994,6 +994,10 @@
   return -kWordSize;
 }
 
+word LoadingUnit::NextFieldOffset() {
+  return -kWordSize;
+}
+
 word Context::NextFieldOffset() {
   return -kWordSize;
 }
diff --git a/runtime/vm/compiler/runtime_api.h b/runtime/vm/compiler/runtime_api.h
index d24e36d..1a028a0 100644
--- a/runtime/vm/compiler/runtime_api.h
+++ b/runtime/vm/compiler/runtime_api.h
@@ -1177,6 +1177,12 @@
   static word NextFieldOffset();
 };
 
+class LoadingUnit : public AllStatic {
+ public:
+  static word InstanceSize();
+  static word NextFieldOffset();
+};
+
 class Context : public AllStatic {
  public:
   static word header_size();
diff --git a/runtime/vm/compiler/runtime_offsets_extracted.h b/runtime/vm/compiler/runtime_offsets_extracted.h
index 918643c..0f16b0f 100644
--- a/runtime/vm/compiler/runtime_offsets_extracted.h
+++ b/runtime/vm/compiler/runtime_offsets_extracted.h
@@ -76,7 +76,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     56;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    90;
+    92;
 static constexpr dart::compiler::target::word Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -198,9 +198,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    712;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     716;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    720;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -225,7 +225,7 @@
     Thread_allocate_object_slow_entry_point_offset = 292;
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 200;
-static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 748;
+static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 752;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     96;
 static constexpr dart::compiler::target::word
@@ -238,7 +238,7 @@
     Thread_call_to_runtime_entry_point_offset = 272;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 148;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 756;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 760;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -256,7 +256,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    732;
+    736;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -276,7 +276,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    720;
+    724;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -284,7 +284,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    744;
+    748;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     68;
@@ -323,11 +323,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 112;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 724;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 728;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 728;
+    Thread_saved_shadow_call_stack_offset = 732;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    736;
+    740;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -360,7 +360,7 @@
     Thread_write_barrier_entry_point_offset = 264;
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     40;
-static constexpr dart::compiler::target::word Thread_callback_code_offset = 740;
+static constexpr dart::compiler::target::word Thread_callback_code_offset = 744;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 12;
 static constexpr dart::compiler::target::word Type_arguments_offset = 16;
@@ -402,7 +402,7 @@
     4, 12, 8, 16};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        680, 684, 688, 692, 696, -1, 700, -1, 704, 708, -1, -1, -1, -1, -1, -1};
+        684, 688, 692, 696, 700, -1, 704, -1, 708, 712, -1, -1, -1, -1, -1, -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 8;
 static constexpr dart::compiler::target::word Array_InstanceSize = 12;
 static constexpr dart::compiler::target::word Array_header_size = 12;
@@ -454,7 +454,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     64;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 28;
-static constexpr dart::compiler::target::word Library_InstanceSize = 80;
+static constexpr dart::compiler::target::word Library_InstanceSize = 84;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 20;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 28;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -488,6 +488,7 @@
 static constexpr dart::compiler::target::word StackTrace_InstanceSize = 20;
 static constexpr dart::compiler::target::word String_InstanceSize = 12;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 12;
@@ -569,7 +570,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     112;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    170;
+    172;
 static constexpr dart::compiler::target::word Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -692,9 +693,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    1432;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     1440;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    1448;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -720,7 +721,7 @@
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word Thread_api_top_scope_offset =
-    1504;
+    1512;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     192;
 static constexpr dart::compiler::target::word
@@ -733,7 +734,7 @@
     Thread_call_to_runtime_entry_point_offset = 528;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 280;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1520;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1528;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -751,7 +752,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    1472;
+    1480;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -771,7 +772,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    1448;
+    1456;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -779,7 +780,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    1496;
+    1504;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     136;
@@ -818,11 +819,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 208;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 672;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1456;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1464;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 1464;
+    Thread_saved_shadow_call_stack_offset = 1472;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    1480;
+    1488;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -856,7 +857,7 @@
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     80;
 static constexpr dart::compiler::target::word Thread_callback_code_offset =
-    1488;
+    1496;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset =
     16;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 16;
@@ -899,8 +900,8 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, -1,   -1,   1376, 1384,
-        1392, 1400, 1408, -1,   1416, 1424, -1,   -1};
+        1352, 1360, 1368, 1376, -1,   -1,   1384, 1392,
+        1400, 1408, 1416, -1,   1424, 1432, -1,   -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word Array_header_size = 24;
@@ -952,7 +953,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     128;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 48;
-static constexpr dart::compiler::target::word Library_InstanceSize = 152;
+static constexpr dart::compiler::target::word Library_InstanceSize = 160;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 40;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 56;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -987,6 +988,7 @@
 static constexpr dart::compiler::target::word String_InstanceSize = 16;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize =
     16;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 16;
@@ -1066,7 +1068,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     56;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    90;
+    92;
 static constexpr dart::compiler::target::word Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -1188,9 +1190,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    680;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     684;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    688;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -1215,7 +1217,7 @@
     Thread_allocate_object_slow_entry_point_offset = 292;
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 200;
-static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 716;
+static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 720;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     96;
 static constexpr dart::compiler::target::word
@@ -1228,7 +1230,7 @@
     Thread_call_to_runtime_entry_point_offset = 272;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 148;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 724;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 728;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -1246,7 +1248,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    700;
+    704;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -1266,7 +1268,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    688;
+    692;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -1274,7 +1276,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    712;
+    716;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     68;
@@ -1313,11 +1315,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 112;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 692;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 696;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 696;
+    Thread_saved_shadow_call_stack_offset = 700;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    704;
+    708;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -1350,7 +1352,7 @@
     Thread_write_barrier_entry_point_offset = 264;
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     40;
-static constexpr dart::compiler::target::word Thread_callback_code_offset = 708;
+static constexpr dart::compiler::target::word Thread_callback_code_offset = 712;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 12;
 static constexpr dart::compiler::target::word Type_arguments_offset = 16;
@@ -1441,7 +1443,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     64;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 28;
-static constexpr dart::compiler::target::word Library_InstanceSize = 80;
+static constexpr dart::compiler::target::word Library_InstanceSize = 84;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 20;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 28;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -1475,6 +1477,7 @@
 static constexpr dart::compiler::target::word StackTrace_InstanceSize = 20;
 static constexpr dart::compiler::target::word String_InstanceSize = 12;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 12;
@@ -1556,7 +1559,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     112;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    170;
+    172;
 static constexpr dart::compiler::target::word Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -1679,9 +1682,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    1504;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     1512;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    1520;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -1707,7 +1710,7 @@
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word Thread_api_top_scope_offset =
-    1576;
+    1584;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     192;
 static constexpr dart::compiler::target::word
@@ -1720,7 +1723,7 @@
     Thread_call_to_runtime_entry_point_offset = 528;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 280;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1592;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1600;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -1738,7 +1741,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    1544;
+    1552;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -1758,7 +1761,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    1520;
+    1528;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -1766,7 +1769,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    1568;
+    1576;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     136;
@@ -1805,11 +1808,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 208;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 672;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1528;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1536;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 1536;
+    Thread_saved_shadow_call_stack_offset = 1544;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    1552;
+    1560;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -1843,7 +1846,7 @@
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     80;
 static constexpr dart::compiler::target::word Thread_callback_code_offset =
-    1560;
+    1568;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset =
     16;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 16;
@@ -1886,9 +1889,9 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424,
-        1432, 1440, 1448, 1456, -1,   -1,   -1,   -1,   1464, 1472, -1,
-        -1,   1480, 1488, 1496, -1,   -1,   -1,   -1,   -1,   -1};
+        1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424, 1432,
+        1440, 1448, 1456, 1464, -1,   -1,   -1,   -1,   1472, 1480, -1,
+        -1,   1488, 1496, 1504, -1,   -1,   -1,   -1,   -1,   -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word Array_header_size = 24;
@@ -1940,7 +1943,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     128;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 48;
-static constexpr dart::compiler::target::word Library_InstanceSize = 152;
+static constexpr dart::compiler::target::word Library_InstanceSize = 160;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 40;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 56;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -1975,6 +1978,7 @@
 static constexpr dart::compiler::target::word String_InstanceSize = 16;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize =
     16;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 16;
@@ -2056,7 +2060,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     56;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    90;
+    92;
 static constexpr dart::compiler::target::word Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -2175,9 +2179,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    712;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     716;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    720;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -2202,7 +2206,7 @@
     Thread_allocate_object_slow_entry_point_offset = 292;
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 200;
-static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 748;
+static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 752;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     96;
 static constexpr dart::compiler::target::word
@@ -2215,7 +2219,7 @@
     Thread_call_to_runtime_entry_point_offset = 272;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 148;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 756;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 760;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -2233,7 +2237,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    732;
+    736;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -2253,7 +2257,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    720;
+    724;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -2261,7 +2265,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    744;
+    748;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     68;
@@ -2300,11 +2304,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 112;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 724;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 728;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 728;
+    Thread_saved_shadow_call_stack_offset = 732;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    736;
+    740;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -2337,7 +2341,7 @@
     Thread_write_barrier_entry_point_offset = 264;
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     40;
-static constexpr dart::compiler::target::word Thread_callback_code_offset = 740;
+static constexpr dart::compiler::target::word Thread_callback_code_offset = 744;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 12;
 static constexpr dart::compiler::target::word Type_arguments_offset = 16;
@@ -2376,7 +2380,7 @@
     4, 12, 8, 16};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        680, 684, 688, 692, 696, -1, 700, -1, 704, 708, -1, -1, -1, -1, -1, -1};
+        684, 688, 692, 696, 700, -1, 704, -1, 708, 712, -1, -1, -1, -1, -1, -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 8;
 static constexpr dart::compiler::target::word Array_InstanceSize = 12;
 static constexpr dart::compiler::target::word Array_header_size = 12;
@@ -2428,7 +2432,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     64;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 28;
-static constexpr dart::compiler::target::word Library_InstanceSize = 80;
+static constexpr dart::compiler::target::word Library_InstanceSize = 84;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 20;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 28;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -2462,6 +2466,7 @@
 static constexpr dart::compiler::target::word StackTrace_InstanceSize = 20;
 static constexpr dart::compiler::target::word String_InstanceSize = 12;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 12;
@@ -2543,7 +2548,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     112;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    170;
+    172;
 static constexpr dart::compiler::target::word Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -2663,9 +2668,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    1432;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     1440;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    1448;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -2691,7 +2696,7 @@
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word Thread_api_top_scope_offset =
-    1504;
+    1512;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     192;
 static constexpr dart::compiler::target::word
@@ -2704,7 +2709,7 @@
     Thread_call_to_runtime_entry_point_offset = 528;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 280;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1520;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1528;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -2722,7 +2727,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    1472;
+    1480;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -2742,7 +2747,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    1448;
+    1456;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -2750,7 +2755,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    1496;
+    1504;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     136;
@@ -2789,11 +2794,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 208;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 672;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1456;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1464;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 1464;
+    Thread_saved_shadow_call_stack_offset = 1472;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    1480;
+    1488;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -2827,7 +2832,7 @@
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     80;
 static constexpr dart::compiler::target::word Thread_callback_code_offset =
-    1488;
+    1496;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset =
     16;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 16;
@@ -2867,8 +2872,8 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, -1,   -1,   1376, 1384,
-        1392, 1400, 1408, -1,   1416, 1424, -1,   -1};
+        1352, 1360, 1368, 1376, -1,   -1,   1384, 1392,
+        1400, 1408, 1416, -1,   1424, 1432, -1,   -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word Array_header_size = 24;
@@ -2920,7 +2925,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     128;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 48;
-static constexpr dart::compiler::target::word Library_InstanceSize = 152;
+static constexpr dart::compiler::target::word Library_InstanceSize = 160;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 40;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 56;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -2955,6 +2960,7 @@
 static constexpr dart::compiler::target::word String_InstanceSize = 16;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize =
     16;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 16;
@@ -3034,7 +3040,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     56;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    90;
+    92;
 static constexpr dart::compiler::target::word Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -3153,9 +3159,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    680;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     684;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    688;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -3180,7 +3186,7 @@
     Thread_allocate_object_slow_entry_point_offset = 292;
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 200;
-static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 716;
+static constexpr dart::compiler::target::word Thread_api_top_scope_offset = 720;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     96;
 static constexpr dart::compiler::target::word
@@ -3193,7 +3199,7 @@
     Thread_call_to_runtime_entry_point_offset = 272;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 148;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 724;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 728;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -3211,7 +3217,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    700;
+    704;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -3231,7 +3237,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    688;
+    692;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -3239,7 +3245,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    712;
+    716;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     68;
@@ -3278,11 +3284,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 112;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 692;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 696;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 696;
+    Thread_saved_shadow_call_stack_offset = 700;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    704;
+    708;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -3315,7 +3321,7 @@
     Thread_write_barrier_entry_point_offset = 264;
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     40;
-static constexpr dart::compiler::target::word Thread_callback_code_offset = 708;
+static constexpr dart::compiler::target::word Thread_callback_code_offset = 712;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 12;
 static constexpr dart::compiler::target::word Type_arguments_offset = 16;
@@ -3403,7 +3409,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     64;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 28;
-static constexpr dart::compiler::target::word Library_InstanceSize = 80;
+static constexpr dart::compiler::target::word Library_InstanceSize = 84;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 20;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 28;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -3437,6 +3443,7 @@
 static constexpr dart::compiler::target::word StackTrace_InstanceSize = 20;
 static constexpr dart::compiler::target::word String_InstanceSize = 12;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 12;
@@ -3518,7 +3525,7 @@
 static constexpr dart::compiler::target::word Class_declaration_type_offset =
     112;
 static constexpr dart::compiler::target::word Class_num_type_arguments_offset =
-    170;
+    172;
 static constexpr dart::compiler::target::word Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -3638,9 +3645,9 @@
 static constexpr dart::compiler::target::word
     Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word Thread_active_exception_offset =
-    1504;
-static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
     1512;
+static constexpr dart::compiler::target::word Thread_active_stacktrace_offset =
+    1520;
 static constexpr dart::compiler::target::word
     Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -3666,7 +3673,7 @@
 static constexpr dart::compiler::target::word
     Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word Thread_api_top_scope_offset =
-    1576;
+    1584;
 static constexpr dart::compiler::target::word Thread_async_stack_trace_offset =
     192;
 static constexpr dart::compiler::target::word
@@ -3679,7 +3686,7 @@
     Thread_call_to_runtime_entry_point_offset = 528;
 static constexpr dart::compiler::target::word
     Thread_call_to_runtime_stub_offset = 280;
-static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1592;
+static constexpr dart::compiler::target::word Thread_dart_stream_offset = 1600;
 static constexpr dart::compiler::target::word
     Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word Thread_optimize_entry_offset =
@@ -3697,7 +3704,7 @@
 static constexpr dart::compiler::target::word
     Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word Thread_execution_state_offset =
-    1544;
+    1552;
 static constexpr dart::compiler::target::word
     Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -3717,7 +3724,7 @@
 static constexpr dart::compiler::target::word
     Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word Thread_global_object_pool_offset =
-    1520;
+    1528;
 static constexpr dart::compiler::target::word
     Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -3725,7 +3732,7 @@
 static constexpr dart::compiler::target::word
     Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word Thread_exit_through_ffi_offset =
-    1568;
+    1576;
 static constexpr dart::compiler::target::word Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word Thread_field_table_values_offset =
     136;
@@ -3764,11 +3771,11 @@
 static constexpr dart::compiler::target::word Thread_object_null_offset = 208;
 static constexpr dart::compiler::target::word
     Thread_predefined_symbols_address_offset = 672;
-static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1528;
+static constexpr dart::compiler::target::word Thread_resume_pc_offset = 1536;
 static constexpr dart::compiler::target::word
-    Thread_saved_shadow_call_stack_offset = 1536;
+    Thread_saved_shadow_call_stack_offset = 1544;
 static constexpr dart::compiler::target::word Thread_safepoint_state_offset =
-    1552;
+    1560;
 static constexpr dart::compiler::target::word
     Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -3802,7 +3809,7 @@
 static constexpr dart::compiler::target::word Thread_write_barrier_mask_offset =
     80;
 static constexpr dart::compiler::target::word Thread_callback_code_offset =
-    1560;
+    1568;
 static constexpr dart::compiler::target::word TimelineStream_enabled_offset =
     16;
 static constexpr dart::compiler::target::word TwoByteString_data_offset = 16;
@@ -3842,9 +3849,9 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424,
-        1432, 1440, 1448, 1456, -1,   -1,   -1,   -1,   1464, 1472, -1,
-        -1,   1480, 1488, 1496, -1,   -1,   -1,   -1,   -1,   -1};
+        1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424, 1432,
+        1440, 1448, 1456, 1464, -1,   -1,   -1,   -1,   1472, 1480, -1,
+        -1,   1488, 1496, 1504, -1,   -1,   -1,   -1,   -1,   -1};
 static constexpr dart::compiler::target::word ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word Array_header_size = 24;
@@ -3896,7 +3903,7 @@
 static constexpr dart::compiler::target::word KernelProgramInfo_InstanceSize =
     128;
 static constexpr dart::compiler::target::word LanguageError_InstanceSize = 48;
-static constexpr dart::compiler::target::word Library_InstanceSize = 152;
+static constexpr dart::compiler::target::word Library_InstanceSize = 160;
 static constexpr dart::compiler::target::word LibraryPrefix_InstanceSize = 40;
 static constexpr dart::compiler::target::word LinkedHashMap_InstanceSize = 56;
 static constexpr dart::compiler::target::word LocalVarDescriptors_InstanceSize =
@@ -3931,6 +3938,7 @@
 static constexpr dart::compiler::target::word String_InstanceSize = 16;
 static constexpr dart::compiler::target::word SubtypeTestCache_InstanceSize =
     16;
+static constexpr dart::compiler::target::word LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word TwoByteString_InstanceSize = 16;
@@ -4018,7 +4026,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 56;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 90;
+    AOT_Class_num_type_arguments_offset = 92;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -4145,9 +4153,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 712;
+    AOT_Thread_active_exception_offset = 716;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 716;
+    AOT_Thread_active_stacktrace_offset = 720;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -4173,7 +4181,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 200;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    748;
+    752;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 96;
 static constexpr dart::compiler::target::word
@@ -4188,7 +4196,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 148;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    756;
+    760;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -4207,7 +4215,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 732;
+    AOT_Thread_execution_state_offset = 736;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -4227,7 +4235,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 720;
+    AOT_Thread_global_object_pool_offset = 724;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -4235,7 +4243,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 744;
+    AOT_Thread_exit_through_ffi_offset = 748;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 68;
@@ -4275,11 +4283,11 @@
     112;
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset = 724;
+static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 728;
+    AOT_Thread_saved_shadow_call_stack_offset = 732;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 736;
+    AOT_Thread_safepoint_state_offset = 740;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -4315,7 +4323,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 40;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    740;
+    744;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -4364,7 +4372,7 @@
     4, 12, 8, 16};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        680, 684, 688, 692, 696, -1, 700, -1, 704, 708, -1, -1, -1, -1, -1, -1};
+        684, 688, 692, 696, 700, -1, 704, -1, 708, 712, -1, -1, -1, -1, -1, -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 12;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 12;
@@ -4420,7 +4428,7 @@
     AOT_KernelProgramInfo_InstanceSize = 64;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     28;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 76;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 80;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     20;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -4463,6 +4471,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 12;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
@@ -4554,7 +4563,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 112;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 170;
+    AOT_Class_num_type_arguments_offset = 172;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -4681,9 +4690,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 1432;
+    AOT_Thread_active_exception_offset = 1440;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 1440;
+    AOT_Thread_active_stacktrace_offset = 1448;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -4709,7 +4718,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    1504;
+    1512;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 192;
 static constexpr dart::compiler::target::word
@@ -4724,7 +4733,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 280;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    1520;
+    1528;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -4743,7 +4752,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 1472;
+    AOT_Thread_execution_state_offset = 1480;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -4763,7 +4772,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 1448;
+    AOT_Thread_global_object_pool_offset = 1456;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -4771,7 +4780,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 1496;
+    AOT_Thread_exit_through_ffi_offset = 1504;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 136;
@@ -4812,11 +4821,11 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 672;
 static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset =
-    1456;
+    1464;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 1464;
+    AOT_Thread_saved_shadow_call_stack_offset = 1472;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 1480;
+    AOT_Thread_safepoint_state_offset = 1488;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -4852,7 +4861,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 80;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    1488;
+    1496;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 16;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -4901,8 +4910,8 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, -1,   -1,   1376, 1384,
-        1392, 1400, 1408, -1,   1416, 1424, -1,   -1};
+        1352, 1360, 1368, 1376, -1,   -1,   1384, 1392,
+        1400, 1408, 1416, -1,   1424, 1432, -1,   -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 24;
@@ -4959,7 +4968,7 @@
     AOT_KernelProgramInfo_InstanceSize = 128;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     48;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 144;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 152;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     40;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -5002,6 +5011,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 16;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 16;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
@@ -5096,7 +5106,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 112;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 170;
+    AOT_Class_num_type_arguments_offset = 172;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -5223,9 +5233,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 1504;
+    AOT_Thread_active_exception_offset = 1512;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 1512;
+    AOT_Thread_active_stacktrace_offset = 1520;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -5251,7 +5261,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    1576;
+    1584;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 192;
 static constexpr dart::compiler::target::word
@@ -5266,7 +5276,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 280;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    1592;
+    1600;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -5285,7 +5295,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 1544;
+    AOT_Thread_execution_state_offset = 1552;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -5305,7 +5315,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 1520;
+    AOT_Thread_global_object_pool_offset = 1528;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -5313,7 +5323,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 1568;
+    AOT_Thread_exit_through_ffi_offset = 1576;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 136;
@@ -5354,11 +5364,11 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 672;
 static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset =
-    1528;
+    1536;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 1536;
+    AOT_Thread_saved_shadow_call_stack_offset = 1544;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 1552;
+    AOT_Thread_safepoint_state_offset = 1560;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -5394,7 +5404,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 80;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    1560;
+    1568;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 16;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -5443,9 +5453,9 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424,
-        1432, 1440, 1448, 1456, -1,   -1,   -1,   -1,   1464, 1472, -1,
-        -1,   1480, 1488, 1496, -1,   -1,   -1,   -1,   -1,   -1};
+        1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424, 1432,
+        1440, 1448, 1456, 1464, -1,   -1,   -1,   -1,   1472, 1480, -1,
+        -1,   1488, 1496, 1504, -1,   -1,   -1,   -1,   -1,   -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 24;
@@ -5502,7 +5512,7 @@
     AOT_KernelProgramInfo_InstanceSize = 128;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     48;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 144;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 152;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     40;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -5545,6 +5555,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 16;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 16;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
@@ -5637,7 +5648,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 56;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 90;
+    AOT_Class_num_type_arguments_offset = 92;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 44;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 104;
@@ -5760,9 +5771,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 376;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 712;
+    AOT_Thread_active_exception_offset = 716;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 716;
+    AOT_Thread_active_stacktrace_offset = 720;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 128;
 static constexpr dart::compiler::target::word
@@ -5788,7 +5799,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 200;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    748;
+    752;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 96;
 static constexpr dart::compiler::target::word
@@ -5803,7 +5814,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 148;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    756;
+    760;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 48;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -5822,7 +5833,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 252;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 732;
+    AOT_Thread_execution_state_offset = 736;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 256;
 static constexpr dart::compiler::target::word
@@ -5842,7 +5853,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 372;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 720;
+    AOT_Thread_global_object_pool_offset = 724;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 340;
 static constexpr dart::compiler::target::word
@@ -5850,7 +5861,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 140;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 744;
+    AOT_Thread_exit_through_ffi_offset = 748;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 44;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 68;
@@ -5890,11 +5901,11 @@
     112;
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 344;
-static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset = 724;
+static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 728;
+    AOT_Thread_saved_shadow_call_stack_offset = 732;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 736;
+    AOT_Thread_safepoint_state_offset = 740;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 244;
 static constexpr dart::compiler::target::word
@@ -5930,7 +5941,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 40;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    740;
+    744;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -5976,7 +5987,7 @@
     4, 12, 8, 16};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        680, 684, 688, 692, 696, -1, 700, -1, 704, 708, -1, -1, -1, -1, -1, -1};
+        684, 688, 692, 696, 700, -1, 704, -1, 708, 712, -1, -1, -1, -1, -1, -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 12;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 12;
@@ -6032,7 +6043,7 @@
     AOT_KernelProgramInfo_InstanceSize = 64;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     28;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 76;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 80;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     20;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -6075,6 +6086,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 12;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 8;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 20;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 4;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
@@ -6166,7 +6178,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 112;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 170;
+    AOT_Class_num_type_arguments_offset = 172;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -6289,9 +6301,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 1432;
+    AOT_Thread_active_exception_offset = 1440;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 1440;
+    AOT_Thread_active_stacktrace_offset = 1448;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -6317,7 +6329,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    1504;
+    1512;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 192;
 static constexpr dart::compiler::target::word
@@ -6332,7 +6344,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 280;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    1520;
+    1528;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -6351,7 +6363,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 1472;
+    AOT_Thread_execution_state_offset = 1480;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -6371,7 +6383,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 1448;
+    AOT_Thread_global_object_pool_offset = 1456;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -6379,7 +6391,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 1496;
+    AOT_Thread_exit_through_ffi_offset = 1504;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 136;
@@ -6420,11 +6432,11 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 672;
 static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset =
-    1456;
+    1464;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 1464;
+    AOT_Thread_saved_shadow_call_stack_offset = 1472;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 1480;
+    AOT_Thread_safepoint_state_offset = 1488;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -6460,7 +6472,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 80;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    1488;
+    1496;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 16;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -6506,8 +6518,8 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, -1,   -1,   1376, 1384,
-        1392, 1400, 1408, -1,   1416, 1424, -1,   -1};
+        1352, 1360, 1368, 1376, -1,   -1,   1384, 1392,
+        1400, 1408, 1416, -1,   1424, 1432, -1,   -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 24;
@@ -6564,7 +6576,7 @@
     AOT_KernelProgramInfo_InstanceSize = 128;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     48;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 144;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 152;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     40;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -6607,6 +6619,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 16;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 16;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
@@ -6701,7 +6714,7 @@
 static constexpr dart::compiler::target::word
     AOT_Class_declaration_type_offset = 112;
 static constexpr dart::compiler::target::word
-    AOT_Class_num_type_arguments_offset = 170;
+    AOT_Class_num_type_arguments_offset = 172;
 static constexpr dart::compiler::target::word AOT_Class_super_type_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Class_host_type_arguments_field_offset_in_words_offset = 184;
@@ -6824,9 +6837,9 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_AllocateArray_entry_point_offset = 736;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_exception_offset = 1504;
+    AOT_Thread_active_exception_offset = 1512;
 static constexpr dart::compiler::target::word
-    AOT_Thread_active_stacktrace_offset = 1512;
+    AOT_Thread_active_stacktrace_offset = 1520;
 static constexpr dart::compiler::target::word
     AOT_Thread_array_write_barrier_code_offset = 240;
 static constexpr dart::compiler::target::word
@@ -6852,7 +6865,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_allocate_object_slow_stub_offset = 384;
 static constexpr dart::compiler::target::word AOT_Thread_api_top_scope_offset =
-    1576;
+    1584;
 static constexpr dart::compiler::target::word
     AOT_Thread_async_stack_trace_offset = 192;
 static constexpr dart::compiler::target::word
@@ -6867,7 +6880,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_call_to_runtime_stub_offset = 280;
 static constexpr dart::compiler::target::word AOT_Thread_dart_stream_offset =
-    1592;
+    1600;
 static constexpr dart::compiler::target::word
     AOT_Thread_dispatch_table_array_offset = 96;
 static constexpr dart::compiler::target::word AOT_Thread_optimize_entry_offset =
@@ -6886,7 +6899,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_enter_safepoint_stub_offset = 488;
 static constexpr dart::compiler::target::word
-    AOT_Thread_execution_state_offset = 1544;
+    AOT_Thread_execution_state_offset = 1552;
 static constexpr dart::compiler::target::word
     AOT_Thread_exit_safepoint_stub_offset = 496;
 static constexpr dart::compiler::target::word
@@ -6906,7 +6919,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_float_zerow_address_offset = 728;
 static constexpr dart::compiler::target::word
-    AOT_Thread_global_object_pool_offset = 1520;
+    AOT_Thread_global_object_pool_offset = 1528;
 static constexpr dart::compiler::target::word
     AOT_Thread_interpret_call_entry_point_offset = 664;
 static constexpr dart::compiler::target::word
@@ -6914,7 +6927,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_invoke_dart_code_stub_offset = 264;
 static constexpr dart::compiler::target::word
-    AOT_Thread_exit_through_ffi_offset = 1568;
+    AOT_Thread_exit_through_ffi_offset = 1576;
 static constexpr dart::compiler::target::word AOT_Thread_isolate_offset = 88;
 static constexpr dart::compiler::target::word
     AOT_Thread_field_table_values_offset = 136;
@@ -6955,11 +6968,11 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_predefined_symbols_address_offset = 672;
 static constexpr dart::compiler::target::word AOT_Thread_resume_pc_offset =
-    1528;
+    1536;
 static constexpr dart::compiler::target::word
-    AOT_Thread_saved_shadow_call_stack_offset = 1536;
+    AOT_Thread_saved_shadow_call_stack_offset = 1544;
 static constexpr dart::compiler::target::word
-    AOT_Thread_safepoint_state_offset = 1552;
+    AOT_Thread_safepoint_state_offset = 1560;
 static constexpr dart::compiler::target::word
     AOT_Thread_slow_type_test_stub_offset = 472;
 static constexpr dart::compiler::target::word
@@ -6995,7 +7008,7 @@
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_mask_offset = 80;
 static constexpr dart::compiler::target::word AOT_Thread_callback_code_offset =
-    1560;
+    1568;
 static constexpr dart::compiler::target::word
     AOT_TimelineStream_enabled_offset = 16;
 static constexpr dart::compiler::target::word AOT_TwoByteString_data_offset =
@@ -7041,9 +7054,9 @@
     8, 24, 16, 32};
 static constexpr dart::compiler::target::word
     AOT_Thread_write_barrier_wrappers_thread_offset[] = {
-        1344, 1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424,
-        1432, 1440, 1448, 1456, -1,   -1,   -1,   -1,   1464, 1472, -1,
-        -1,   1480, 1488, 1496, -1,   -1,   -1,   -1,   -1,   -1};
+        1352, 1360, 1368, 1376, 1384, 1392, 1400, 1408, 1416, 1424, 1432,
+        1440, 1448, 1456, 1464, -1,   -1,   -1,   -1,   1472, 1480, -1,
+        -1,   1488, 1496, 1504, -1,   -1,   -1,   -1,   -1,   -1};
 static constexpr dart::compiler::target::word AOT_ApiError_InstanceSize = 16;
 static constexpr dart::compiler::target::word AOT_Array_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_Array_header_size = 24;
@@ -7100,7 +7113,7 @@
     AOT_KernelProgramInfo_InstanceSize = 128;
 static constexpr dart::compiler::target::word AOT_LanguageError_InstanceSize =
     48;
-static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 144;
+static constexpr dart::compiler::target::word AOT_Library_InstanceSize = 152;
 static constexpr dart::compiler::target::word AOT_LibraryPrefix_InstanceSize =
     40;
 static constexpr dart::compiler::target::word AOT_LinkedHashMap_InstanceSize =
@@ -7143,6 +7156,7 @@
 static constexpr dart::compiler::target::word AOT_String_InstanceSize = 16;
 static constexpr dart::compiler::target::word
     AOT_SubtypeTestCache_InstanceSize = 16;
+static constexpr dart::compiler::target::word AOT_LoadingUnit_InstanceSize = 32;
 static constexpr dart::compiler::target::word
     AOT_TransferableTypedData_InstanceSize = 8;
 static constexpr dart::compiler::target::word AOT_TwoByteString_InstanceSize =
diff --git a/runtime/vm/compiler/runtime_offsets_list.h b/runtime/vm/compiler/runtime_offsets_list.h
index 958adc1..d241c74 100644
--- a/runtime/vm/compiler/runtime_offsets_list.h
+++ b/runtime/vm/compiler/runtime_offsets_list.h
@@ -337,6 +337,7 @@
   SIZEOF(StackTrace, InstanceSize, StackTraceLayout)                           \
   SIZEOF(String, InstanceSize, StringLayout)                                   \
   SIZEOF(SubtypeTestCache, InstanceSize, SubtypeTestCacheLayout)               \
+  SIZEOF(LoadingUnit, InstanceSize, LoadingUnitLayout)                         \
   SIZEOF(TransferableTypedData, InstanceSize, TransferableTypedDataLayout)     \
   SIZEOF(TwoByteString, InstanceSize, TwoByteStringLayout)                     \
   SIZEOF(Type, InstanceSize, TypeLayout)                                       \
diff --git a/runtime/vm/compiler/stub_code_compiler_arm.cc b/runtime/vm/compiler/stub_code_compiler_arm.cc
index e858c7d..2ef0df4 100644
--- a/runtime/vm/compiler/stub_code_compiler_arm.cc
+++ b/runtime/vm/compiler/stub_code_compiler_arm.cc
@@ -3716,6 +3716,12 @@
   __ bkpt(0);
 }
 
+void StubCodeCompiler::GenerateNotLoadedStub(Assembler* assembler) {
+  __ EnterStubFrame();
+  __ CallRuntime(kNotLoadedRuntimeEntry, 0);
+  __ bkpt(0);
+}
+
 // Instantiate type arguments from instantiator and function type args.
 // R3 uninstantiated type arguments.
 // R2 instantiator type arguments.
diff --git a/runtime/vm/compiler/stub_code_compiler_arm64.cc b/runtime/vm/compiler/stub_code_compiler_arm64.cc
index 20eb970..8050974 100644
--- a/runtime/vm/compiler/stub_code_compiler_arm64.cc
+++ b/runtime/vm/compiler/stub_code_compiler_arm64.cc
@@ -3900,6 +3900,12 @@
   __ brk(0);
 }
 
+void StubCodeCompiler::GenerateNotLoadedStub(Assembler* assembler) {
+  __ EnterStubFrame();
+  __ CallRuntime(kNotLoadedRuntimeEntry, 0);
+  __ brk(0);
+}
+
 // Instantiate type arguments from instantiator and function type args.
 // R3 uninstantiated type arguments.
 // R2 instantiator type arguments.
diff --git a/runtime/vm/compiler/stub_code_compiler_ia32.cc b/runtime/vm/compiler/stub_code_compiler_ia32.cc
index 6649df4..96bf0ff 100644
--- a/runtime/vm/compiler/stub_code_compiler_ia32.cc
+++ b/runtime/vm/compiler/stub_code_compiler_ia32.cc
@@ -2965,6 +2965,12 @@
   __ int3();  // Marker stub.
 }
 
+void StubCodeCompiler::GenerateNotLoadedStub(Assembler* assembler) {
+  __ EnterStubFrame();
+  __ CallRuntime(kNotLoadedRuntimeEntry, 0);
+  __ int3();
+}
+
 // Instantiate type arguments from instantiator and function type args.
 // EBX: uninstantiated type arguments.
 // EDX: instantiator type arguments.
diff --git a/runtime/vm/compiler/stub_code_compiler_x64.cc b/runtime/vm/compiler/stub_code_compiler_x64.cc
index 23ec342..7096c77 100644
--- a/runtime/vm/compiler/stub_code_compiler_x64.cc
+++ b/runtime/vm/compiler/stub_code_compiler_x64.cc
@@ -3793,6 +3793,12 @@
   __ int3();
 }
 
+void StubCodeCompiler::GenerateNotLoadedStub(Assembler* assembler) {
+  __ EnterStubFrame();
+  __ CallRuntime(kNotLoadedRuntimeEntry, 0);
+  __ int3();
+}
+
 // Instantiate type arguments from instantiator and function type args.
 // RBX: uninstantiated type arguments.
 // RDX: instantiator type arguments.
diff --git a/runtime/vm/compiler_test.cc b/runtime/vm/compiler_test.cc
index e7b6d31..fc900fa 100644
--- a/runtime/vm/compiler_test.cc
+++ b/runtime/vm/compiler_test.cc
@@ -225,6 +225,7 @@
 
     Dart_KernelCompilationResult compilation_result =
         KernelIsolate::CompileExpressionToKernel(
+            /*platform_kernel=*/nullptr, /*platform_kernel_size=*/0,
             expr_text.ToCString(), Array::empty_array(), Array::empty_array(),
             String::Handle(lib_handle.url()).ToCString(), "A",
             /* is_static= */ false);
diff --git a/runtime/vm/dart.cc b/runtime/vm/dart.cc
index c7f2b50..99aa048 100644
--- a/runtime/vm/dart.cc
+++ b/runtime/vm/dart.cc
@@ -657,14 +657,6 @@
   return isolate;
 }
 
-static bool IsSnapshotCompatible(Snapshot::Kind vm_kind,
-                                 Snapshot::Kind isolate_kind) {
-  if (vm_kind == isolate_kind) return true;
-  if (vm_kind == Snapshot::kFull && isolate_kind == Snapshot::kFullJIT)
-    return true;
-  return Snapshot::IsFull(isolate_kind);
-}
-
 #if defined(DART_PRECOMPILED_RUNTIME)
 static bool CloneIntoChildIsolateAOT(Thread* T,
                                      Isolate* I,
@@ -763,7 +755,7 @@
   //   generating the kernel file
   // - if loading from an appJIT, based on the mode used
   //   when generating the snapshot.
-  ASSERT(FLAG_null_safety == kNullSafetyOptionUnspecified);
+  ASSERT(FLAG_sound_null_safety == kNullSafetyOptionUnspecified);
 
   // If snapshot is an appJIT/AOT snapshot we will figure out the mode by
   // sniffing the feature string in the snapshot.
@@ -1025,7 +1017,7 @@
         buffer.AddString(" no-null-safety");
       }
     } else {
-      if (FLAG_null_safety == kNullSafetyOptionStrong) {
+      if (FLAG_sound_null_safety == kNullSafetyOptionStrong) {
         buffer.AddString(" null-safety");
       } else {
         buffer.AddString(" no-null-safety");
diff --git a/runtime/vm/dart_api_impl.cc b/runtime/vm/dart_api_impl.cc
index f82a6ba..a6c66f3 100644
--- a/runtime/vm/dart_api_impl.cc
+++ b/runtime/vm/dart_api_impl.cc
@@ -148,16 +148,9 @@
 static InstancePtr GetListInstance(Zone* zone, const Object& obj) {
   if (obj.IsInstance()) {
     ObjectStore* object_store = Isolate::Current()->object_store();
-    Type& list_rare_type =
+    const Type& list_rare_type =
         Type::Handle(zone, object_store->non_nullable_list_rare_type());
-    if (list_rare_type.IsNull()) {
-      const Library& core_lib = Library::Handle(zone, Library::CoreLibrary());
-      const Class& list_class =
-          Class::Handle(zone, core_lib.LookupClass(Symbols::List()));
-      ASSERT(!list_class.IsNull());
-      list_rare_type ^= list_class.RareType();
-      object_store->set_non_nullable_list_rare_type(list_rare_type);
-    }
+    ASSERT(!list_rare_type.IsNull());
     const Instance& instance = Instance::Cast(obj);
     const Class& obj_class = Class::Handle(zone, obj.clazz());
     if (Class::IsSubtypeOf(obj_class, Object::null_type_arguments(),
@@ -172,16 +165,9 @@
 static InstancePtr GetMapInstance(Zone* zone, const Object& obj) {
   if (obj.IsInstance()) {
     ObjectStore* object_store = Isolate::Current()->object_store();
-    Type& map_rare_type =
+    const Type& map_rare_type =
         Type::Handle(zone, object_store->non_nullable_map_rare_type());
-    if (map_rare_type.IsNull()) {
-      const Library& core_lib = Library::Handle(zone, Library::CoreLibrary());
-      const Class& map_class =
-          Class::Handle(zone, core_lib.LookupClass(Symbols::Map()));
-      ASSERT(!map_class.IsNull());
-      map_rare_type ^= map_class.RareType();
-      object_store->set_non_nullable_map_rare_type(map_rare_type);
-    }
+    ASSERT(!map_rare_type.IsNull());
     const Instance& instance = Instance::Cast(obj);
     const Class& obj_class = Class::Handle(zone, obj.clazz());
     if (Class::IsSubtypeOf(obj_class, Object::null_type_arguments(),
@@ -1160,7 +1146,7 @@
                is_new_group ? nullptr : group, isolate_data));
     if (error_obj.IsNull()) {
 #if defined(DEBUG) && !defined(DART_PRECOMPILED_RUNTIME)
-      if (FLAG_check_function_fingerprints && source->kernel_buffer == NULL) {
+      if (FLAG_check_function_fingerprints && !FLAG_precompiled_mode) {
         Library::CheckFunctionFingerprints();
       }
 #endif  // defined(DEBUG) && !defined(DART_PRECOMPILED_RUNTIME).
@@ -2416,14 +2402,9 @@
   const Object& obj = Object::Handle(Z, Api::UnwrapHandle(handle));
   if (obj.IsInstance()) {
     ObjectStore* object_store = T->isolate()->object_store();
-    Type& future_rare_type =
+    const Type& future_rare_type =
         Type::Handle(Z, object_store->non_nullable_future_rare_type());
-    if (future_rare_type.IsNull()) {
-      const Class& future_class = Class::Handle(object_store->future_class());
-      ASSERT(!future_class.IsNull());
-      future_rare_type ^= future_class.RareType();
-      object_store->set_non_nullable_future_rare_type(future_rare_type);
-    }
+    ASSERT(!future_rare_type.IsNull());
     const Class& obj_class = Class::Handle(Z, obj.clazz());
     bool is_future = Class::IsSubtypeOf(
         obj_class, Object::null_type_arguments(), Nullability::kNonNullable,
@@ -3051,7 +3032,7 @@
   DARTSCOPE(Thread::Current());
   if (T->isolate()->null_safety() && element_type_id != Dart_CoreType_Dynamic) {
     return Api::NewError(
-        "Cannot use legacy types with --null-safety enabled. "
+        "Cannot use legacy types with --sound-null-safety enabled. "
         "Use Dart_NewListOfType or Dart_NewListOfTypeFilled instead.");
   }
   CHECK_LENGTH(length, Array::kMaxElements);
@@ -3825,11 +3806,14 @@
   CHECK_LENGTH(length, ExternalTypedData::MaxElements(cid));
   Zone* zone = thread->zone();
   intptr_t bytes = length * ExternalTypedData::ElementSizeInBytes(cid);
-  const ExternalTypedData& result = ExternalTypedData::Handle(
-      zone,
-      ExternalTypedData::New(cid, reinterpret_cast<uint8_t*>(data), length,
-                             thread->heap()->SpaceForExternal(bytes)));
-  if (callback != NULL) {
+  auto& cls = Class::Handle(zone, thread->isolate()->class_table()->At(cid));
+  auto& result = Object::Handle(zone, cls.EnsureIsAllocateFinalized(thread));
+  if (result.IsError()) {
+    return Api::NewHandle(thread, result.raw());
+  }
+  result = ExternalTypedData::New(cid, reinterpret_cast<uint8_t*>(data), length,
+                                  thread->heap()->SpaceForExternal(bytes));
+  if (callback != nullptr) {
     AllocateFinalizableHandle(thread, result, peer, external_allocation_size,
                               callback);
   }
@@ -4270,6 +4254,8 @@
         CURRENT_FUNC);
   }
   Class& cls = Class::Handle(Z, type_obj.type_class());
+  CHECK_ERROR_HANDLE(cls.EnsureIsAllocateFinalized(T));
+
   TypeArguments& type_arguments =
       TypeArguments::Handle(Z, type_obj.arguments());
 
@@ -5419,6 +5405,14 @@
   return Api::NewHandle(T, String::New(resolved_uri));
 }
 
+DART_EXPORT Dart_Handle
+Dart_SetDeferredLoadHandler(Dart_DeferredLoadHandler handler) {
+  Isolate* isolate = Isolate::Current();
+  CHECK_ISOLATE(isolate);
+  isolate->group()->set_deferred_load_handler(handler);
+  return Api::Success();
+}
+
 DART_EXPORT Dart_Handle Dart_LoadScriptFromKernel(const uint8_t* buffer,
                                                   intptr_t buffer_size) {
 #if defined(DART_PRECOMPILED_RUNTIME)
@@ -5599,7 +5593,7 @@
                                      Dart_Handle* type_arguments) {
   if (Thread::Current()->isolate()->null_safety()) {
     return Api::NewError(
-        "Cannot use legacy types with --null-safety enabled. "
+        "Cannot use legacy types with --sound-null-safety enabled. "
         "Use Dart_GetNullableType or Dart_GetNonNullableType instead.");
   }
   return GetTypeCommon(library, class_name, number_of_type_arguments,
@@ -5774,6 +5768,9 @@
       kernel::KernelLoader::LoadEntireProgram(program.get(), false);
   program.reset();
 
+  IsolateGroupSource* source = Isolate::Current()->source();
+  source->add_loaded_blob(Z, td);
+
   return Api::NewHandle(T, result.raw());
 #endif  // defined(DART_PRECOMPILED_RUNTIME)
 }
@@ -5858,6 +5855,78 @@
   return Api::Success();
 }
 
+static Dart_Handle DeferredLoadComplete(intptr_t loading_unit_id,
+                                        bool error,
+                                        const uint8_t* snapshot_data,
+                                        const uint8_t* snapshot_instructions,
+                                        const char* error_message,
+                                        bool transient_error) {
+  DARTSCOPE(Thread::Current());
+  API_TIMELINE_DURATION(T);
+  Isolate* I = T->isolate();
+  CHECK_CALLBACK_STATE(T);
+
+  const Array& loading_units =
+      Array::Handle(I->object_store()->loading_units());
+  if (loading_units.IsNull() || (loading_unit_id < LoadingUnit::kRootId) ||
+      (loading_unit_id >= loading_units.Length())) {
+    return Api::NewError("Invalid loading unit");
+  }
+  LoadingUnit& unit = LoadingUnit::Handle();
+  unit ^= loading_units.At(loading_unit_id);
+  if (unit.loaded()) {
+    return Api::NewError("Unit already loaded");
+  }
+
+  if (error) {
+    CHECK_NULL(error_message);
+    unit.CompleteLoad(String::Handle(String::New(error_message)),
+                      transient_error);
+  } else {
+#if defined(SUPPORT_TIMELINE)
+    TimelineBeginEndScope tbes(T, Timeline::GetIsolateStream(),
+                               "ReadUnitSnapshot");
+#endif  // defined(SUPPORT_TIMELINE)
+    const Snapshot* snapshot = Snapshot::SetupFromBuffer(snapshot_data);
+    if (snapshot == NULL) {
+      return Api::NewError("Invalid snapshot");
+    }
+    if (!IsSnapshotCompatible(Dart::vm_snapshot_kind(), snapshot->kind())) {
+      const String& message = String::Handle(String::NewFormatted(
+          "Incompatible snapshot kinds: vm '%s', isolate '%s'",
+          Snapshot::KindToCString(Dart::vm_snapshot_kind()),
+          Snapshot::KindToCString(snapshot->kind())));
+      return Api::NewHandle(T, ApiError::New(message));
+    }
+
+    FullSnapshotReader reader(snapshot, snapshot_instructions, T);
+    const Error& error = Error::Handle(reader.ReadUnitSnapshot(unit));
+    if (!error.IsNull()) {
+      return Api::NewHandle(T, error.raw());
+    }
+
+    unit.CompleteLoad(String::Handle(), false);
+  }
+
+  return Api::Success();
+}
+
+DART_EXPORT Dart_Handle
+Dart_DeferredLoadComplete(intptr_t loading_unit_id,
+                          const uint8_t* snapshot_data,
+                          const uint8_t* snapshot_instructions) {
+  return DeferredLoadComplete(loading_unit_id, false, snapshot_data,
+                              snapshot_instructions, nullptr, false);
+}
+
+DART_EXPORT Dart_Handle
+Dart_DeferredLoadCompleteError(intptr_t loading_unit_id,
+                               const char* error_message,
+                               bool transient) {
+  return DeferredLoadComplete(loading_unit_id, true, nullptr, nullptr,
+                              error_message, transient);
+}
+
 DART_EXPORT Dart_Handle
 Dart_SetNativeResolver(Dart_Handle library,
                        Dart_NativeEntryResolver resolver,
@@ -6033,16 +6102,16 @@
                                        const uint8_t* kernel_buffer,
                                        intptr_t kernel_buffer_size) {
 #if defined(DART_PRECOMPILED_RUNTIME)
-  ASSERT(FLAG_null_safety != kNullSafetyOptionUnspecified);
-  return (FLAG_null_safety == kNullSafetyOptionStrong);
+  ASSERT(FLAG_sound_null_safety != kNullSafetyOptionUnspecified);
+  return (FLAG_sound_null_safety == kNullSafetyOptionStrong);
 #else
   bool null_safety;
-  if (FLAG_null_safety == kNullSafetyOptionUnspecified) {
+  if (FLAG_sound_null_safety == kNullSafetyOptionUnspecified) {
     null_safety = Dart::DetectNullSafety(
         script_uri, snapshot_data, snapshot_instructions, kernel_buffer,
         kernel_buffer_size, package_config, original_working_directory);
   } else {
-    null_safety = (FLAG_null_safety == kNullSafetyOptionStrong);
+    null_safety = (FLAG_sound_null_safety == kNullSafetyOptionStrong);
   }
   return null_safety;
 #endif  // defined(DART_PRECOMPILED_RUNTIME)
@@ -6423,6 +6492,127 @@
 #if !defined(TARGET_ARCH_IA32) && defined(DART_PRECOMPILER)
 static const intptr_t kInitialSize = 2 * MB;
 static const intptr_t kInitialDebugSize = 1 * MB;
+
+static void CreateAppAOTSnapshot(
+    Dart_StreamingWriteCallback callback,
+    void* callback_data,
+    bool strip,
+    bool as_elf,
+    void* debug_callback_data,
+    GrowableArray<LoadingUnitSerializationData*>* units,
+    LoadingUnitSerializationData* unit,
+    uint32_t program_hash) {
+  Thread* T = Thread::Current();
+
+  NOT_IN_PRODUCT(TimelineBeginEndScope tbes2(T, Timeline::GetIsolateStream(),
+                                             "WriteAppAOTSnapshot"));
+
+  uint8_t* vm_snapshot_data_buffer = nullptr;
+  uint8_t* vm_snapshot_instructions_buffer = nullptr;
+  uint8_t* isolate_snapshot_data_buffer = nullptr;
+  uint8_t* isolate_snapshot_instructions_buffer = nullptr;
+
+  const bool generate_debug = debug_callback_data != nullptr;
+
+  if (as_elf) {
+    StreamingWriteStream elf_stream(kInitialSize, callback, callback_data);
+    StreamingWriteStream debug_stream(generate_debug ? kInitialDebugSize : 0,
+                                      callback, debug_callback_data);
+
+    auto const dwarf = strip ? nullptr : new (Z) Dwarf(Z);
+    auto const elf = new (Z) Elf(Z, &elf_stream, Elf::Type::Snapshot, dwarf);
+    // Re-use the same DWARF object if the snapshot is unstripped.
+    auto const debug_elf =
+        generate_debug ? new (Z) Elf(Z, &debug_stream, Elf::Type::DebugInfo,
+                                     strip ? new (Z) Dwarf(Z) : dwarf)
+                       : nullptr;
+
+    BlobImageWriter vm_image_writer(T, &vm_snapshot_instructions_buffer,
+                                    ApiReallocate, kInitialSize, debug_elf,
+                                    elf);
+    BlobImageWriter isolate_image_writer(
+        T, &isolate_snapshot_instructions_buffer, ApiReallocate, kInitialSize,
+        debug_elf, elf);
+    FullSnapshotWriter writer(Snapshot::kFullAOT, &vm_snapshot_data_buffer,
+                              &isolate_snapshot_data_buffer, ApiReallocate,
+                              &vm_image_writer, &isolate_image_writer);
+
+    if (unit == nullptr || unit->id() == LoadingUnit::kRootId) {
+      writer.WriteFullSnapshot(units);
+    } else {
+      writer.WriteUnitSnapshot(units, unit, program_hash);
+    }
+
+    elf->Finalize();
+    if (debug_elf != nullptr) {
+      debug_elf->Finalize();
+    }
+  } else {
+    StreamingWriteStream debug_stream(generate_debug ? kInitialDebugSize : 0,
+                                      callback, debug_callback_data);
+
+    auto const elf = generate_debug
+                         ? new (Z) Elf(Z, &debug_stream, Elf::Type::DebugInfo,
+                                       new (Z) Dwarf(Z))
+                         : nullptr;
+
+    AssemblyImageWriter image_writer(T, callback, callback_data, strip, elf);
+    uint8_t* vm_snapshot_data_buffer = NULL;
+    uint8_t* isolate_snapshot_data_buffer = NULL;
+    FullSnapshotWriter writer(Snapshot::kFullAOT, &vm_snapshot_data_buffer,
+                              &isolate_snapshot_data_buffer, ApiReallocate,
+                              &image_writer, &image_writer);
+
+    if (unit == nullptr || unit->id() == LoadingUnit::kRootId) {
+      writer.WriteFullSnapshot(units);
+    } else {
+      writer.WriteUnitSnapshot(units, unit, program_hash);
+    }
+    image_writer.Finalize();
+  }
+}
+
+static void Split(Dart_CreateLoadingUnitCallback next_callback,
+                  void* next_callback_data,
+                  bool strip,
+                  bool as_elf,
+                  Dart_StreamingWriteCallback write_callback,
+                  Dart_StreamingCloseCallback close_callback) {
+  Thread* T = Thread::Current();
+  ProgramVisitor::AssignUnits(T);
+
+  const Array& loading_units =
+      Array::Handle(T->isolate()->object_store()->loading_units());
+  const uint32_t program_hash = ProgramVisitor::Hash(T);
+  loading_units.SetAt(0, Smi::Handle(Z, Smi::New(program_hash)));
+  GrowableArray<LoadingUnitSerializationData*> data;
+  data.SetLength(loading_units.Length());
+  data[0] = nullptr;
+
+  LoadingUnit& loading_unit = LoadingUnit::Handle();
+  LoadingUnit& parent = LoadingUnit::Handle();
+  for (intptr_t id = 1; id < loading_units.Length(); id++) {
+    loading_unit ^= loading_units.At(id);
+    parent = loading_unit.parent();
+    LoadingUnitSerializationData* parent_data =
+        parent.IsNull() ? nullptr : data[parent.id()];
+    data[id] = new LoadingUnitSerializationData(id, parent_data);
+  }
+
+  for (intptr_t id = 1; id < loading_units.Length(); id++) {
+    void* write_callback_data = nullptr;
+    void* write_debug_callback_data = nullptr;
+    next_callback(next_callback_data, id, &write_callback_data,
+                  &write_debug_callback_data);
+    CreateAppAOTSnapshot(write_callback, write_callback_data, strip, as_elf,
+                         write_debug_callback_data, &data, data[id],
+                         program_hash);
+    close_callback(write_callback_data);
+    if (write_debug_callback_data != nullptr) {
+      close_callback(write_debug_callback_data);
+    }
+  }
+}
 #endif
 
 DART_EXPORT Dart_Handle
@@ -6442,26 +6632,43 @@
   API_TIMELINE_DURATION(T);
   CHECK_NULL(callback);
 
-  TIMELINE_DURATION(T, Isolate, "WriteAppAOTSnapshot");
-  const bool generate_debug = debug_callback_data != nullptr;
+  // Mark as not split.
+  T->isolate()->object_store()->set_loading_units(Object::null_array());
 
-  StreamingWriteStream debug_stream(generate_debug ? kInitialDebugSize : 0,
-                                    callback, debug_callback_data);
+  CreateAppAOTSnapshot(callback, callback_data, strip, /*as_elf*/ false,
+                       debug_callback_data, nullptr, nullptr, 0);
 
-  auto const elf = generate_debug
-                       ? new (Z) Elf(Z, &debug_stream, Elf::Type::DebugInfo,
-                                     new (Z) Dwarf(Z))
-                       : nullptr;
+  return Api::Success();
+#endif
+}
 
-  AssemblyImageWriter image_writer(T, callback, callback_data, strip, elf);
-  uint8_t* vm_snapshot_data_buffer = NULL;
-  uint8_t* isolate_snapshot_data_buffer = NULL;
-  FullSnapshotWriter writer(Snapshot::kFullAOT, &vm_snapshot_data_buffer,
-                            &isolate_snapshot_data_buffer, ApiReallocate,
-                            &image_writer, &image_writer);
+DART_EXPORT Dart_Handle Dart_CreateAppAOTSnapshotAsAssemblies(
+    Dart_CreateLoadingUnitCallback next_callback,
+    void* next_callback_data,
+    bool strip,
+    Dart_StreamingWriteCallback write_callback,
+    Dart_StreamingCloseCallback close_callback) {
+#if defined(TARGET_ARCH_IA32)
+  return Api::NewError("AOT compilation is not supported on IA32.");
+#elif defined(TARGET_OS_WINDOWS)
+  return Api::NewError("Assembly generation is not implemented for Windows.");
+#elif !defined(DART_PRECOMPILER)
+  return Api::NewError(
+      "This VM was built without support for AOT compilation.");
+#else
+  if (FLAG_use_bare_instructions) {
+    return Api::NewError(
+        "Splitting is not compatible with --use_bare_instructions.");
+  }
 
-  writer.WriteFullSnapshot();
-  image_writer.Finalize();
+  DARTSCOPE(Thread::Current());
+  API_TIMELINE_DURATION(T);
+  CHECK_NULL(next_callback);
+  CHECK_NULL(write_callback);
+  CHECK_NULL(close_callback);
+
+  Split(next_callback, next_callback_data, strip, /*as_elf*/ false,
+        write_callback, close_callback);
 
   return Api::Success();
 #endif
@@ -6507,45 +6714,44 @@
 #else
   DARTSCOPE(Thread::Current());
   API_TIMELINE_DURATION(T);
+  CHECK_NULL(callback);
 
-  NOT_IN_PRODUCT(TimelineBeginEndScope tbes2(T, Timeline::GetIsolateStream(),
-                                             "WriteAppAOTSnapshot"));
+  // Mark as not split.
+  T->isolate()->object_store()->set_loading_units(Object::null_array());
 
-  uint8_t* vm_snapshot_data_buffer = nullptr;
-  uint8_t* vm_snapshot_instructions_buffer = nullptr;
-  uint8_t* isolate_snapshot_data_buffer = nullptr;
-  uint8_t* isolate_snapshot_instructions_buffer = nullptr;
+  CreateAppAOTSnapshot(callback, callback_data, strip, /*as_elf*/ true,
+                       debug_callback_data, nullptr, nullptr, 0);
 
-  const bool generate_debug = debug_callback_data != nullptr;
+  return Api::Success();
+#endif
+}
 
-  StreamingWriteStream elf_stream(kInitialSize, callback, callback_data);
-  StreamingWriteStream debug_stream(generate_debug ? kInitialDebugSize : 0,
-                                    callback, debug_callback_data);
-
-  auto const dwarf = strip ? nullptr : new (Z) Dwarf(Z);
-  auto const elf = new (Z) Elf(Z, &elf_stream, Elf::Type::Snapshot, dwarf);
-  // Re-use the same DWARF object if the snapshot is unstripped.
-  auto const debug_elf =
-      generate_debug ? new (Z) Elf(Z, &debug_stream, Elf::Type::DebugInfo,
-                                   strip ? new (Z) Dwarf(Z) : dwarf)
-                     : nullptr;
-
-  BlobImageWriter vm_image_writer(T, &vm_snapshot_instructions_buffer,
-                                  ApiReallocate, kInitialSize, debug_elf, elf);
-  BlobImageWriter isolate_image_writer(T, &isolate_snapshot_instructions_buffer,
-                                       ApiReallocate, kInitialSize, debug_elf,
-                                       elf);
-  FullSnapshotWriter writer(Snapshot::kFullAOT, &vm_snapshot_data_buffer,
-                            &isolate_snapshot_data_buffer, ApiReallocate,
-                            &vm_image_writer, &isolate_image_writer);
-
-  writer.WriteFullSnapshot();
-
-  elf->Finalize();
-  if (debug_elf != nullptr) {
-    debug_elf->Finalize();
+DART_EXPORT Dart_Handle
+Dart_CreateAppAOTSnapshotAsElfs(Dart_CreateLoadingUnitCallback next_callback,
+                                void* next_callback_data,
+                                bool strip,
+                                Dart_StreamingWriteCallback write_callback,
+                                Dart_StreamingCloseCallback close_callback) {
+#if defined(TARGET_ARCH_IA32)
+  return Api::NewError("AOT compilation is not supported on IA32.");
+#elif !defined(DART_PRECOMPILER)
+  return Api::NewError(
+      "This VM was built without support for AOT compilation.");
+#else
+  if (FLAG_use_bare_instructions) {
+    return Api::NewError(
+        "Splitting is not compatible with --use_bare_instructions.");
   }
 
+  DARTSCOPE(Thread::Current());
+  API_TIMELINE_DURATION(T);
+  CHECK_NULL(next_callback);
+  CHECK_NULL(write_callback);
+  CHECK_NULL(close_callback);
+
+  Split(next_callback, next_callback_data, strip, /*as_elf*/ true,
+        write_callback, close_callback);
+
   return Api::Success();
 #endif
 }
diff --git a/runtime/vm/dart_api_impl_test.cc b/runtime/vm/dart_api_impl_test.cc
index 1940670..7063353 100644
--- a/runtime/vm/dart_api_impl_test.cc
+++ b/runtime/vm/dart_api_impl_test.cc
@@ -5335,7 +5335,7 @@
     EXPECT_STREQ("null", str);
   } else {
     EXPECT_ERROR(string_list,
-                 "Cannot use legacy types with --null-safety enabled. "
+                 "Cannot use legacy types with --sound-null-safety enabled. "
                  "Use Dart_NewListOfType or Dart_NewListOfTypeFilled instead.");
   }
 
@@ -5356,7 +5356,7 @@
     EXPECT_STREQ("null", str);
   } else {
     EXPECT_ERROR(int_list,
-                 "Cannot use legacy types with --null-safety enabled. "
+                 "Cannot use legacy types with --sound-null-safety enabled. "
                  "Use Dart_NewListOfType or Dart_NewListOfTypeFilled instead.");
   }
 }
@@ -6222,7 +6222,7 @@
   if (Dart_IsError(type)) {
     EXPECT_ERROR(
         type,
-        "Cannot use legacy types with --null-safety enabled. "
+        "Cannot use legacy types with --sound-null-safety enabled. "
         "Use Dart_GetNullableType or Dart_GetNonNullableType instead.");
 
     nonNullableType = Dart_GetNonNullableType(lib, name, 0, nullptr);
diff --git a/runtime/vm/dart_entry.cc b/runtime/vm/dart_entry.cc
index 3a82369..aa310f9 100644
--- a/runtime/vm/dart_entry.cc
+++ b/runtime/vm/dart_entry.cc
@@ -110,7 +110,7 @@
 #if !defined(DART_PRECOMPILED_RUNTIME)
     UNREACHABLE();
 #else
-    if (FLAG_precompiled_mode && FLAG_use_bare_instructions) {
+    if (FLAG_use_bare_instructions) {
       Thread* thread = Thread::Current();
       thread->set_global_object_pool(
           thread->isolate()->object_store()->global_object_pool());
@@ -215,8 +215,6 @@
   const ArgumentsDescriptor args_desc(arguments_descriptor);
   const intptr_t receiver_index = args_desc.FirstArgIndex();
   const intptr_t type_args_len = args_desc.TypeArgsLen();
-  const intptr_t args_count = args_desc.Count();
-  const intptr_t named_args_count = args_desc.NamedCount();
   const auto& getter_name = Symbols::GetCall();
 
   auto& instance = Instance::Handle(zone);
@@ -226,11 +224,19 @@
   // The null instance cannot resolve to a callable, so we can stop there.
   for (instance ^= arguments.At(receiver_index); !instance.IsNull();
        instance ^= arguments.At(receiver_index)) {
-    // If the current instance is a compatible callable, return its function.
-    if (instance.IsCallable(&function) &&
-        function.AreValidArgumentCounts(type_args_len, args_count,
-                                        named_args_count, nullptr)) {
-      return function.raw();
+    // The instance is a callable, so check that its function is compatible.
+    if (instance.IsCallable(&function)) {
+      bool matches = function.AreValidArguments(args_desc, nullptr);
+
+      if (matches && type_args_len > 0 && function.IsClosureFunction()) {
+        // Though the closure function is generic, the closure itself may
+        // not be because it closes over delayed function type arguments.
+        matches = Closure::Cast(instance).IsGeneric(thread);
+      }
+
+      if (matches) {
+        return function.raw();
+      }
     }
 
     // Special case: closures are implemented with a call getter instead of a
diff --git a/runtime/vm/debugger.cc b/runtime/vm/debugger.cc
index 6f3e711..eaa2fbd 100644
--- a/runtime/vm/debugger.cc
+++ b/runtime/vm/debugger.cc
@@ -1962,10 +1962,14 @@
   GrowableObjectArray& closures = GrowableObjectArray::Handle(zone);
   Function& function = Function::Handle(zone);
   Code& code = Code::Handle(zone);
-  intptr_t num_classes = class_table.NumCids();
-  for (intptr_t i = 1; i < num_classes; i++) {
-    if (class_table.HasValidClassAt(i)) {
-      cls = class_table.At(i);
+
+  const intptr_t num_classes = class_table.NumCids();
+  const intptr_t num_tlc_classes = class_table.NumTopLevelCids();
+  for (intptr_t i = 1; i < num_classes + num_tlc_classes; i++) {
+    const classid_t cid =
+        i < num_classes ? i : ClassTable::CidFromTopLevelIndex(i - num_classes);
+    if (class_table.HasValidClassAt(cid)) {
+      cls = class_table.At(cid);
 
       // Disable optimized functions.
       functions = cls.functions();
@@ -3297,9 +3301,12 @@
 
   const ClassTable& class_table = *isolate_->class_table();
   const intptr_t num_classes = class_table.NumCids();
-  for (intptr_t i = 1; i < num_classes; i++) {
-    if (class_table.HasValidClassAt(i)) {
-      cls = class_table.At(i);
+  const intptr_t num_tlc_classes = class_table.NumTopLevelCids();
+  for (intptr_t i = 1; i < num_classes + num_tlc_classes; i++) {
+    const classid_t cid =
+        i < num_classes ? i : ClassTable::CidFromTopLevelIndex(i - num_classes);
+    if (class_table.HasValidClassAt(cid)) {
+      cls = class_table.At(cid);
       // If the class is not finalized, e.g. if it hasn't been parsed
       // yet entirely, we can ignore it. If it contains a function with
       // an unresolved breakpoint, we will detect it if and when the
@@ -3426,11 +3433,15 @@
 
     const ClassTable& class_table = *isolate_->class_table();
     const intptr_t num_classes = class_table.NumCids();
-    for (intptr_t i = 1; i < num_classes; i++) {
-      if (!class_table.HasValidClassAt(i)) {
+    const intptr_t num_tlc_classes = class_table.NumTopLevelCids();
+    for (intptr_t i = 1; i < num_classes + num_tlc_classes; i++) {
+      const classid_t cid =
+          i < num_classes ? i
+                          : ClassTable::CidFromTopLevelIndex(i - num_classes);
+      if (!class_table.HasValidClassAt(cid)) {
         continue;
       }
-      cls = class_table.At(i);
+      cls = class_table.At(cid);
       // This class is relevant to us only if it belongs to the
       // library to which |script| belongs.
       if (cls.library() != lib.raw()) {
diff --git a/runtime/vm/debugger_api_impl_test.cc b/runtime/vm/debugger_api_impl_test.cc
index 8ca5a67..bcd63b0 100644
--- a/runtime/vm/debugger_api_impl_test.cc
+++ b/runtime/vm/debugger_api_impl_test.cc
@@ -180,6 +180,7 @@
   } else {
     Dart_KernelCompilationResult compilation_result =
         KernelIsolate::CompileExpressionToKernel(
+            /* platform_kernel= */ nullptr, /* platform_kernel_size= */ 0,
             expr.ToCString(),
             /* definitions= */ Array::empty_array(),
             /* type_defintions= */ Array::empty_array(),
diff --git a/runtime/vm/dwarf.cc b/runtime/vm/dwarf.cc
index db73b08..8b927ec 100644
--- a/runtime/vm/dwarf.cc
+++ b/runtime/vm/dwarf.cc
@@ -727,15 +727,23 @@
   }
 
   // Advance pc to end of the compilation unit if not already there.
-  const intptr_t last_code_index = codes_.length() - 1;
-  const Code& last_code = *(codes_[last_code_index]);
-  const intptr_t last_pc_offset = last_code.Size();
-  const char* last_asm_name = namer.SnapshotNameFor(last_code_index, last_code);
+  if (codes_.length() != 0) {
+    const intptr_t last_code_index = codes_.length() - 1;
+    const Code& last_code = *(codes_[last_code_index]);
+    const intptr_t last_pc_offset = last_code.Size();
+    const char* last_asm_name =
+        namer.SnapshotNameFor(last_code_index, last_code);
 
-  stream->u1(DW_LNS_advance_pc);
-  ASSERT(previous_asm_name != nullptr);
-  stream->DistanceBetweenSymbolOffsets(last_asm_name, last_pc_offset,
-                                       previous_asm_name, previous_pc_offset);
+    stream->u1(DW_LNS_advance_pc);
+    if (previous_asm_name != nullptr) {
+      stream->DistanceBetweenSymbolOffsets(
+          last_asm_name, last_pc_offset, previous_asm_name, previous_pc_offset);
+    } else {
+      // No LNP entries (e.g., only stub code).
+      ASSERT(previous_pc_offset == 0);
+      stream->uleb128(last_pc_offset);
+    }
+  }
 
   // End of contiguous machine code.
   stream->u1(0);  // This is an extended opcode
diff --git a/runtime/vm/elf.cc b/runtime/vm/elf.cc
index 2ce45e3..606ef61 100644
--- a/runtime/vm/elf.cc
+++ b/runtime/vm/elf.cc
@@ -1125,17 +1125,20 @@
   // Need these to turn offsets into relocated addresses.
   auto const vm_start =
       symbol_to_address_map.LookupValue(kVmSnapshotInstructionsAsmSymbol);
-  ASSERT(vm_start > 0);
+  // vm_start is absent in deferred loading peices.
   auto const isolate_start =
       symbol_to_address_map.LookupValue(kIsolateSnapshotInstructionsAsmSymbol);
   ASSERT(isolate_start > 0);
   auto const vm_text = FindSectionForAddress(vm_start);
-  ASSERT(vm_text != nullptr);
+  // vm_text is absent in deferred loading peices.
   auto const isolate_text = FindSectionForAddress(isolate_start);
   ASSERT(isolate_text != nullptr);
 
   SnapshotTextObjectNamer namer(zone_);
   const auto& codes = dwarf_->codes();
+  if (codes.length() == 0) {
+    return;
+  }
   for (intptr_t i = 0; i < codes.length(); i++) {
     const auto& code = *codes[i];
     auto const name = namer.SnapshotNameFor(i, code);
@@ -1300,7 +1303,8 @@
     auto const name = kBuildIdSegmentNames[i];
     auto const symbol = LookupSymbol(dynstrtab_, dynsym_, name);
     if (symbol == nullptr) {
-      FATAL1("No symbol %s found for expected segment\n", name);
+      stream.WriteFixed(static_cast<uint32_t>(0));
+      continue;
     }
     auto const bits = sections_[symbol->section_index]->AsBitsContainer();
     if (bits == nullptr) {
diff --git a/runtime/vm/flag_list.h b/runtime/vm/flag_list.h
index f9f9346..fb19f98 100644
--- a/runtime/vm/flag_list.h
+++ b/runtime/vm/flag_list.h
@@ -63,6 +63,7 @@
     "Use --[no-]dwarf-stack-traces instead.")                                  \
   P(causal_async_stacks, bool, !USING_PRODUCT, "Improved async stacks")        \
   P(lazy_async_stacks, bool, false, "Reconstruct async stacks from listeners") \
+  P(lazy_dispatchers, bool, true, "Generate dispatchers lazily")               \
   P(use_bare_instructions, bool, true, "Enable bare instructions mode.")       \
   R(dedup_instructions, true, bool, false,                                     \
     "Canonicalize instructions when precompiling.")
@@ -137,7 +138,6 @@
   P(idle_duration_micros, int, 500 * kMicrosecondsPerMillisecond,              \
     "Allow idle tasks to run for this long.")                                  \
   P(interpret_irregexp, bool, false, "Use irregexp bytecode interpreter")      \
-  P(lazy_dispatchers, bool, true, "Generate dispatchers lazily")               \
   P(link_natives_lazily, bool, false, "Link native calls lazily")              \
   R(log_marker_tasks, false, bool, false,                                      \
     "Log debugging information for old gen GC marking tasks.")                 \
diff --git a/runtime/vm/hash.h b/runtime/vm/hash.h
index cbd4c83..7365500 100644
--- a/runtime/vm/hash.h
+++ b/runtime/vm/hash.h
@@ -27,6 +27,16 @@
   return (hash == 0) ? 1 : hash;
 }
 
+inline uint32_t HashBytes(const uint8_t* bytes, intptr_t size) {
+  uint32_t hash = size;
+  while (size > 0) {
+    hash = CombineHashes(hash, *bytes);
+    bytes++;
+    size--;
+  }
+  return hash;
+}
+
 }  // namespace dart
 
 #endif  // RUNTIME_VM_HASH_H_
diff --git a/runtime/vm/heap/compactor.cc b/runtime/vm/heap/compactor.cc
index 4f2723c..a4c5370 100644
--- a/runtime/vm/heap/compactor.cc
+++ b/runtime/vm/heap/compactor.cc
@@ -569,29 +569,27 @@
 }
 
 void GCCompactor::SetupImagePageBoundaries() {
-  for (intptr_t i = 0; i < kMaxImagePages; i++) {
-    image_page_ranges_[i].base = 0;
-    image_page_ranges_[i].size = 0;
-  }
-  intptr_t next_offset = 0;
+  MallocGrowableArray<ImagePageRange> ranges(4);
+
   OldPage* image_page = Dart::vm_isolate()->heap()->old_space()->image_pages_;
   while (image_page != NULL) {
-    RELEASE_ASSERT(next_offset <= kMaxImagePages);
-    image_page_ranges_[next_offset].base = image_page->object_start();
-    image_page_ranges_[next_offset].size =
-        image_page->object_end() - image_page->object_start();
+    ImagePageRange range = {image_page->object_start(),
+                            image_page->object_end()};
+    ranges.Add(range);
     image_page = image_page->next();
-    next_offset++;
   }
   image_page = heap_->old_space()->image_pages_;
   while (image_page != NULL) {
-    RELEASE_ASSERT(next_offset <= kMaxImagePages);
-    image_page_ranges_[next_offset].base = image_page->object_start();
-    image_page_ranges_[next_offset].size =
-        image_page->object_end() - image_page->object_start();
+    ImagePageRange range = {image_page->object_start(),
+                            image_page->object_end()};
+    ranges.Add(range);
     image_page = image_page->next();
-    next_offset++;
   }
+
+  ranges.Sort(CompareImagePageRanges);
+  intptr_t image_page_count;
+  ranges.StealBuffer(&image_page_ranges_, &image_page_count);
+  image_page_hi_ = image_page_count - 1;
 }
 
 DART_FORCE_INLINE
@@ -602,8 +600,17 @@
   }
 
   uword old_addr = ObjectLayout::ToAddr(old_target);
-  for (intptr_t i = 0; i < kMaxImagePages; i++) {
-    if ((old_addr - image_page_ranges_[i].base) < image_page_ranges_[i].size) {
+  intptr_t lo = 0;
+  intptr_t hi = image_page_hi_;
+  while (lo <= hi) {
+    intptr_t mid = (hi - lo + 1) / 2 + lo;
+    ASSERT(mid >= lo);
+    ASSERT(mid <= hi);
+    if (old_addr < image_page_ranges_[mid].start) {
+      hi = mid - 1;
+    } else if (old_addr >= image_page_ranges_[mid].end) {
+      lo = mid + 1;
+    } else {
       return;  // Not moved (unaligned image page).
     }
   }
diff --git a/runtime/vm/heap/compactor.h b/runtime/vm/heap/compactor.h
index 0de8b14..4ba033b 100644
--- a/runtime/vm/heap/compactor.h
+++ b/runtime/vm/heap/compactor.h
@@ -28,7 +28,7 @@
       : HandleVisitor(thread),
         ObjectPointerVisitor(thread->isolate_group()),
         heap_(heap) {}
-  ~GCCompactor() {}
+  ~GCCompactor() { free(image_page_ranges_); }
 
   void Compact(OldPage* pages, FreeList* freelist, Mutex* mutex);
 
@@ -47,13 +47,21 @@
   Heap* heap_;
 
   struct ImagePageRange {
-    uword base;
-    uword size;
+    uword start;
+    uword end;
   };
-  // There are up to 4 images to consider:
-  // {instructions, data} x {vm isolate, current isolate}
-  static const intptr_t kMaxImagePages = 4;
-  ImagePageRange image_page_ranges_[kMaxImagePages];
+  static int CompareImagePageRanges(const ImagePageRange* a,
+                                    const ImagePageRange* b) {
+    if (a->start < b->start) {
+      return -1;
+    } else if (a->start == b->start) {
+      return 0;
+    } else {
+      return 1;
+    }
+  }
+  intptr_t image_page_hi_ = 0;
+  ImagePageRange* image_page_ranges_ = nullptr;
 
   // The typed data views whose inner pointer must be updated after sliding is
   // complete.
diff --git a/runtime/vm/heap/heap.h b/runtime/vm/heap/heap.h
index fb57895..841edb1 100644
--- a/runtime/vm/heap/heap.h
+++ b/runtime/vm/heap/heap.h
@@ -45,6 +45,7 @@
 #endif
     kCanonicalHashes,
     kObjectIds,
+    kLoadingUnits,
     kNumWeakSelectors
   };
 
@@ -234,6 +235,15 @@
   }
   void ResetObjectIdTable();
 
+  void SetLoadingUnit(ObjectPtr raw_obj, intptr_t object_id) {
+    ASSERT(Thread::Current()->IsMutatorThread());
+    SetWeakEntry(raw_obj, kLoadingUnits, object_id);
+  }
+  intptr_t GetLoadingUnit(ObjectPtr raw_obj) const {
+    ASSERT(Thread::Current()->IsMutatorThread());
+    return GetWeakEntry(raw_obj, kLoadingUnits);
+  }
+
   // Used by the GC algorithms to propagate weak entries.
   intptr_t GetWeakEntry(ObjectPtr raw_obj, WeakSelector sel) const;
   void SetWeakEntry(ObjectPtr raw_obj, WeakSelector sel, intptr_t val);
diff --git a/runtime/vm/heap/pages.cc b/runtime/vm/heap/pages.cc
index a542ec4..23fbc56 100644
--- a/runtime/vm/heap/pages.cc
+++ b/runtime/vm/heap/pages.cc
@@ -1612,13 +1612,6 @@
     grow_heap = 0;
   }
   heap_->RecordData(PageSpace::kPageGrowth, grow_heap);
-
-  // Limit shrinkage: allow growth by at least half the pages freed by GC.
-  const intptr_t freed_pages =
-      (before.CombinedUsedInWords() - after.CombinedUsedInWords()) /
-      kOldPageSizeInWords;
-  grow_heap = Utils::Maximum(grow_heap, freed_pages / 2);
-  heap_->RecordData(PageSpace::kAllowedGrowth, grow_heap);
   last_usage_ = after;
 
   RecordUpdate(before, after, grow_heap, "gc");
diff --git a/runtime/vm/heap/weak_table.h b/runtime/vm/heap/weak_table.h
index 1a81be4..f145dfe 100644
--- a/runtime/vm/heap/weak_table.h
+++ b/runtime/vm/heap/weak_table.h
@@ -15,6 +15,8 @@
 
 class WeakTable {
  public:
+  static constexpr intptr_t kNoValue = 0;
+
   WeakTable() : size_(kMinSize), used_(0), count_(0) {
     ASSERT(Utils::IsPowerOfTwo(size_));
     data_ = reinterpret_cast<intptr_t*>(calloc(size_, kEntrySize * kWordSize));
@@ -104,7 +106,7 @@
       obj = ObjectAtExclusive(idx);
     }
     ASSERT(ValueAtExclusive(idx) == 0);
-    return 0;
+    return kNoValue;
   }
 
   // Removes and returns the value associated with |key|. Returns 0 if there is
@@ -123,7 +125,7 @@
       obj = ObjectAtExclusive(idx);
     }
     ASSERT(ValueAtExclusive(idx) == 0);
-    return 0;
+    return kNoValue;
   }
 
   void Forward(ObjectPointerVisitor* visitor);
diff --git a/runtime/vm/instructions_arm.cc b/runtime/vm/instructions_arm.cc
index d46838f..e3a570c 100644
--- a/runtime/vm/instructions_arm.cc
+++ b/runtime/vm/instructions_arm.cc
@@ -20,7 +20,7 @@
       target_code_pool_index_(-1) {
   ASSERT(code.ContainsInstructionAt(pc));
   // Last instruction: blx lr.
-  ASSERT(*(reinterpret_cast<uword*>(pc) - 1) == 0xe12fff3e);
+  ASSERT(*(reinterpret_cast<uint32_t*>(pc) - 1) == 0xe12fff3e);
 
   Register reg;
   InstructionPattern::DecodeLoadWordFromPool(pc - 2 * Instr::kInstrSize, &reg,
@@ -34,7 +34,7 @@
       data_pool_index_(-1) {
   ASSERT(code.ContainsInstructionAt(pc));
   // Last instruction: blx lr.
-  ASSERT(*(reinterpret_cast<uword*>(pc) - 1) == 0xe12fff3e);
+  ASSERT(*(reinterpret_cast<uint32_t*>(pc) - 1) == 0xe12fff3e);
 
   Register reg;
   uword data_load_end = InstructionPattern::DecodeLoadWordFromPool(
@@ -53,7 +53,7 @@
       target_code_pool_index_(-1) {
   ASSERT(code.ContainsInstructionAt(pc));
   // Last instruction: blx lr.
-  ASSERT(*(reinterpret_cast<uword*>(end_) - 1) == 0xe12fff3e);
+  ASSERT(*(reinterpret_cast<uint32_t*>(end_) - 1) == 0xe12fff3e);
 
   Register reg;
   uword native_function_load_end = InstructionPattern::DecodeLoadWordFromPool(
@@ -278,7 +278,7 @@
     : SwitchableCallPatternBase(code) {
   ASSERT(code.ContainsInstructionAt(pc));
   // Last instruction: blx lr.
-  ASSERT(*(reinterpret_cast<uword*>(pc) - 1) == 0xe12fff3e);
+  ASSERT(*(reinterpret_cast<uint32_t*>(pc) - 1) == 0xe12fff3e);
 
   Register reg;
   uword data_load_end = InstructionPattern::DecodeLoadWordFromPool(
@@ -301,7 +301,7 @@
     : SwitchableCallPatternBase(code) {
   ASSERT(code.ContainsInstructionAt(pc));
   // Last instruction: blx lr.
-  ASSERT(*(reinterpret_cast<uword*>(pc) - 1) == 0xe12fff3e);
+  ASSERT(*(reinterpret_cast<uint32_t*>(pc) - 1) == 0xe12fff3e);
 
   Register reg;
   uword data_load_end = InstructionPattern::DecodeLoadWordFromPool(
@@ -429,7 +429,7 @@
   // Ensure the caller of the type testing stub (whose return address is [pc_])
   // branched via `blx R9` or a pc-relative call.
   uword pc = pc_ - Instr::kInstrSize;
-  const uword blx_r9 = 0xe12fff39;
+  const uint32_t blx_r9 = 0xe12fff39;
   if (*reinterpret_cast<uint32_t*>(pc) != blx_r9) {
     PcRelativeCallPattern pattern(pc);
     RELEASE_ASSERT(pattern.IsValid());
diff --git a/runtime/vm/interpreter.cc b/runtime/vm/interpreter.cc
index d296e6e..5b16c67c 100644
--- a/runtime/vm/interpreter.cc
+++ b/runtime/vm/interpreter.cc
@@ -232,9 +232,9 @@
     return false;
   }
 
-  DART_FORCE_INLINE static bool IsFinalized(ClassPtr cls) {
+  DART_FORCE_INLINE static bool IsAllocateFinalized(ClassPtr cls) {
     return Class::ClassFinalizedBits::decode(cls->ptr()->state_bits_) ==
-           ClassLayout::kFinalized;
+           ClassLayout::kAllocateFinalized;
   }
 };
 
@@ -746,6 +746,7 @@
                                                  const KBCInstr** pc,
                                                  ObjectPtr** FP,
                                                  ObjectPtr** SP) {
+  ObjectPtr null_value = Object::null();
   const intptr_t type_args_len =
       InterpreterHelpers::ArgDescTypeArgsLen(argdesc_);
   const intptr_t receiver_idx = type_args_len > 0 ? 1 : 0;
@@ -757,11 +758,11 @@
   if (UNLIKELY(!lookup_cache_.Lookup(receiver_cid, target_name, argdesc_,
                                      &target))) {
     // Table lookup miss.
-    top[0] = 0;  // Clean up slot as it may be visited by GC.
+    top[0] = null_value;  // Clean up slot as it may be visited by GC.
     top[1] = call_base[receiver_idx];
     top[2] = target_name;
     top[3] = argdesc_;
-    top[4] = 0;  // Result slot.
+    top[4] = null_value;  // Result slot.
 
     Exit(thread, *FP, top + 5, *pc);
     NativeArguments native_args(thread, 3, /* argv */ top + 1,
@@ -774,12 +775,61 @@
     target = static_cast<FunctionPtr>(top[4]);
     target_name = static_cast<StringPtr>(top[2]);
     argdesc_ = static_cast<ArrayPtr>(top[3]);
-    ASSERT(target->IsFunction());
-    lookup_cache_.Insert(receiver_cid, target_name, argdesc_, target);
   }
 
-  top[0] = target;
-  return Invoke(thread, call_base, top, pc, FP, SP);
+  if (target != Function::null()) {
+    lookup_cache_.Insert(receiver_cid, target_name, argdesc_, target);
+    top[0] = target;
+    return Invoke(thread, call_base, top, pc, FP, SP);
+  }
+
+  // The miss handler should only fail to return a function if lazy dispatchers
+  // are disabled, in which case we need to call DRT_InvokeNoSuchMethod, which
+  // walks the receiver appropriately in this case.
+  ASSERT(!FLAG_lazy_dispatchers);
+
+  // The receiver, name, and argument descriptor are already in the appropriate
+  // places on the stack from the previous call.
+  ASSERT(top[4] == null_value);
+
+  // Allocate array of arguments.
+  {
+    const intptr_t argc =
+        InterpreterHelpers::ArgDescArgCount(argdesc_) + receiver_idx;
+    ASSERT_EQUAL(top - call_base, argc);
+
+    top[5] = Smi::New(argc);  // length
+    top[6] = null_value;      // type
+    Exit(thread, *FP, top + 7, *pc);
+    NativeArguments native_args(thread, 2, /* argv */ top + 5,
+                                /* result */ top + 4);
+    if (!InvokeRuntime(thread, this, DRT_AllocateArray, native_args)) {
+      return false;
+    }
+
+    // Copy arguments into the newly allocated array.
+    ArrayPtr array = Array::RawCast(top[4]);
+    for (intptr_t i = 0; i < argc; i++) {
+      array->ptr()->data()[i] = call_base[i];
+    }
+  }
+
+  {
+    Exit(thread, *FP, top + 5, *pc);
+    NativeArguments native_args(thread, 4, /* argv */ top + 1,
+                                /* result */ top);
+    if (!InvokeRuntime(thread, this, DRT_InvokeNoSuchMethod, native_args)) {
+      return false;
+    }
+
+    // Pop the call args and push the result.
+    ObjectPtr result = top[0];
+    *SP = call_base;
+    **SP = result;
+    pp_ = InterpreterHelpers::FrameBytecode(*FP)->ptr()->object_pool_;
+  }
+
+  return true;
 }
 
 // Note:
@@ -1543,7 +1593,7 @@
               reentering ? "Re-entering" : "Entering",
               reinterpret_cast<uword>(this), reinterpret_cast<uword>(fp_),
               thread->top_exit_frame_info(),
-              Function::Handle(function).ToCString());
+              Function::Handle(function).ToFullyQualifiedCString());
   }
 #endif
 
@@ -2550,7 +2600,7 @@
   {
     BYTECODE(Allocate, D);
     ClassPtr cls = Class::RawCast(LOAD_CONSTANT(rD));
-    if (LIKELY(InterpreterHelpers::IsFinalized(cls))) {
+    if (LIKELY(InterpreterHelpers::IsAllocateFinalized(cls))) {
       const intptr_t class_id = cls->ptr()->id_;
       const intptr_t instance_size = cls->ptr()->host_instance_size_in_words_
                                      << kWordSizeLog2;
@@ -2580,7 +2630,7 @@
     BYTECODE(AllocateT, 0);
     ClassPtr cls = Class::RawCast(SP[0]);
     TypeArgumentsPtr type_args = TypeArguments::RawCast(SP[-1]);
-    if (LIKELY(InterpreterHelpers::IsFinalized(cls))) {
+    if (LIKELY(InterpreterHelpers::IsAllocateFinalized(cls))) {
       const intptr_t class_id = cls->ptr()->id_;
       const intptr_t instance_size = cls->ptr()->host_instance_size_in_words_
                                      << kWordSizeLog2;
@@ -3492,33 +3542,31 @@
     // Invoke noSuchMethod.
     SP[1] = null_value;
     SP[2] = receiver;
-    SP[3] = argdesc_;
-    SP[4] = null_value;  // Array of arguments (will be filled).
+    SP[3] = Symbols::Call().raw();  // We failed to resolve the 'call' function.
+    SP[4] = argdesc_;
+    SP[5] = null_value;  // Array of arguments (will be filled).
 
     // Allocate array of arguments.
     {
-      SP[5] = Smi::New(argc);  // length
-      SP[6] = null_value;      // type
-      Exit(thread, FP, SP + 7, pc);
+      SP[6] = Smi::New(argc);  // length
+      SP[7] = null_value;      // type
+      Exit(thread, FP, SP + 8, pc);
       if (!InvokeRuntime(thread, this, DRT_AllocateArray,
-                         NativeArguments(thread, 2, SP + 5, SP + 4))) {
+                         NativeArguments(thread, 2, SP + 6, SP + 5))) {
         HANDLE_EXCEPTION;
       }
     }
 
     // Copy arguments into the newly allocated array.
     ObjectPtr* argv = FrameArguments(FP, argc);
-    ArrayPtr array = static_cast<ArrayPtr>(SP[4]);
+    ArrayPtr array = static_cast<ArrayPtr>(SP[5]);
     ASSERT(array->GetClassId() == kArrayCid);
     for (intptr_t i = 0; i < argc; i++) {
       array->ptr()->data()[i] = argv[i];
     }
 
-    // We failed to resolve 'call' function.
-    SP[5] = Symbols::Call().raw();
-
-    // Invoke noSuchMethod passing down receiver, argument descriptor,
-    // array of arguments, and target name.
+    // Invoke noSuchMethod passing down receiver, target name, argument
+    // descriptor, and array of arguments.
     {
       Exit(thread, FP, SP + 6, pc);
       if (!InvokeRuntime(thread, this, DRT_InvokeNoSuchMethod,
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
index eaa3b25..118bf68 100644
--- a/runtime/vm/isolate.cc
+++ b/runtime/vm/isolate.cc
@@ -88,15 +88,15 @@
                     deterministic,
                     "Enable deterministic mode.");
 
-int FLAG_null_safety = kNullSafetyOptionUnspecified;
-static void NullSafetyHandler(bool value) {
-  FLAG_null_safety = value ? kNullSafetyOptionStrong : kNullSafetyOptionWeak;
+int FLAG_sound_null_safety = kNullSafetyOptionUnspecified;
+static void SoundNullSafetyHandler(bool value) {
+  FLAG_sound_null_safety =
+      value ? kNullSafetyOptionStrong : kNullSafetyOptionWeak;
 }
 
-DEFINE_FLAG_HANDLER(
-    NullSafetyHandler,
-    null_safety,
-    "Respect the nullability of types in casts and instance checks.");
+DEFINE_FLAG_HANDLER(SoundNullSafetyHandler,
+                    sound_null_safety,
+                    "Respect the nullability of types at runtime.");
 
 DEFINE_FLAG(bool,
             disable_thread_pool_limit,
@@ -148,6 +148,63 @@
   }
 }
 
+void IsolateGroupSource::add_loaded_blob(
+    Zone* zone,
+    const ExternalTypedData& external_typed_data) {
+  Array& loaded_blobs = Array::Handle();
+  bool saved_external_typed_data = false;
+  if (loaded_blobs_ != nullptr) {
+    loaded_blobs = loaded_blobs_;
+
+    // Walk the array, and (if stuff was removed) compact and reuse the space.
+    // Note that the space has to be compacted as the ordering is important.
+    WeakProperty& weak_property = WeakProperty::Handle();
+    WeakProperty& weak_property_tmp = WeakProperty::Handle();
+    ExternalTypedData& existing_entry = ExternalTypedData::Handle(zone);
+    intptr_t next_entry_index = 0;
+    for (intptr_t i = 0; i < loaded_blobs.Length(); i++) {
+      weak_property ^= loaded_blobs.At(i);
+      if (weak_property.key() != ExternalTypedData::null()) {
+        if (i != next_entry_index) {
+          existing_entry = ExternalTypedData::RawCast(weak_property.key());
+          weak_property_tmp ^= loaded_blobs.At(next_entry_index);
+          weak_property_tmp.set_key(existing_entry);
+        }
+        next_entry_index++;
+      }
+    }
+    if (next_entry_index < loaded_blobs.Length()) {
+      // There's now space to re-use.
+      weak_property ^= loaded_blobs.At(next_entry_index);
+      weak_property.set_key(external_typed_data);
+      next_entry_index++;
+      saved_external_typed_data = true;
+    }
+    if (next_entry_index < loaded_blobs.Length()) {
+      ExternalTypedData& nullExternalTypedData =
+          ExternalTypedData::Handle(zone);
+      while (next_entry_index < loaded_blobs.Length()) {
+        // Null out any extra spaces.
+        weak_property ^= loaded_blobs.At(next_entry_index);
+        weak_property.set_key(nullExternalTypedData);
+        next_entry_index++;
+      }
+    }
+  }
+  if (!saved_external_typed_data) {
+    const WeakProperty& weak_property =
+        WeakProperty::Handle(WeakProperty::New(Heap::kOld));
+    weak_property.set_key(external_typed_data);
+
+    intptr_t length = loaded_blobs.IsNull() ? 0 : loaded_blobs.Length();
+    Array& new_array =
+        Array::Handle(Array::Grow(loaded_blobs, length + 1, Heap::kOld));
+    new_array.SetAt(length, weak_property);
+    loaded_blobs_ = new_array.raw();
+  }
+  num_blob_loads_++;
+}
+
 void IdleTimeHandler::InitializeWithHeap(Heap* heap) {
   MutexLocker ml(&mutex_);
   ASSERT(heap_ == nullptr && heap != nullptr);
@@ -827,7 +884,11 @@
     return;
   }
 #endif  // !defined(PRODUCT) && !defined(DART_PRECOMPILED_RUNTIME)
-  class_table()->Register(cls);
+  if (cls.IsTopLevel()) {
+    class_table()->RegisterTopLevel(cls);
+  } else {
+    class_table()->Register(cls);
+  }
 }
 
 #if defined(DEBUG)
@@ -1812,6 +1873,18 @@
   return Api::UnwrapHandle(api_result);
 }
 
+ObjectPtr Isolate::CallDeferredLoadHandler(intptr_t id) {
+  Thread* thread = Thread::Current();
+  Api::Scope api_scope(thread);
+  Dart_Handle api_result;
+  {
+    TransitionVMToNative transition(thread);
+    RELEASE_ASSERT(HasDeferredLoadHandler());
+    api_result = group()->deferred_load_handler()(id);
+  }
+  return Api::UnwrapHandle(api_result);
+}
+
 void Isolate::SetupImagePage(const uint8_t* image_buffer, bool is_executable) {
   Image image(image_buffer);
   heap()->SetupImagePage(image.object_start(), image.object_size(),
@@ -2671,9 +2744,9 @@
   visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&deoptimized_code_array_));
   visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(&sticky_error_));
   if (isolate_group_ != nullptr) {
-    if (isolate_group_->source()->hot_reload_blobs_ != nullptr) {
+    if (isolate_group_->source()->loaded_blobs_ != nullptr) {
       visitor->VisitPointer(reinterpret_cast<ObjectPtr*>(
-          &(isolate_group_->source()->hot_reload_blobs_)));
+          &(isolate_group_->source()->loaded_blobs_)));
     }
   }
 #if !defined(PRODUCT)
diff --git a/runtime/vm/isolate.h b/runtime/vm/isolate.h
index 2c217e6..eb8d5cc 100644
--- a/runtime/vm/isolate.h
+++ b/runtime/vm/isolate.h
@@ -99,7 +99,7 @@
 constexpr int kNullSafetyOptionUnspecified = 0;
 constexpr int kNullSafetyOptionWeak = 1;
 constexpr int kNullSafetyOptionStrong = 2;
-extern int FLAG_null_safety;
+extern int FLAG_sound_null_safety;
 
 class PendingLazyDeopt {
  public:
@@ -200,10 +200,13 @@
         flags(flags),
         script_kernel_buffer(nullptr),
         script_kernel_size(-1),
-        hot_reload_blobs_(nullptr),
-        num_hot_reloads_(0) {}
+        loaded_blobs_(nullptr),
+        num_blob_loads_(0) {}
   ~IsolateGroupSource() { free(name); }
 
+  void add_loaded_blob(Zone* zone_,
+                       const ExternalTypedData& external_typed_data);
+
   // The arguments used for spawning in
   // `Dart_CreateIsolateGroupFromKernel` / `Dart_CreateIsolate`.
   const char* script_uri;
@@ -223,9 +226,9 @@
   // Any newly spawned isolates need to use this permutation map.
   std::unique_ptr<intptr_t[]> cid_permutation_map;
 
-  // List of weak pointers to external typed data for hot reload blobs.
-  ArrayPtr hot_reload_blobs_;
-  intptr_t num_hot_reloads_;
+  // List of weak pointers to external typed data for loaded blobs.
+  ArrayPtr loaded_blobs_;
+  intptr_t num_blob_loads_;
 };
 
 // Tracks idle time and notifies heap when idle time expired.
@@ -407,6 +410,12 @@
   void set_library_tag_handler(Dart_LibraryTagHandler handler) {
     library_tag_handler_ = handler;
   }
+  Dart_DeferredLoadHandler deferred_load_handler() const {
+    return deferred_load_handler_;
+  }
+  void set_deferred_load_handler(Dart_DeferredLoadHandler handler) {
+    deferred_load_handler_ = handler;
+  }
 
   intptr_t GetClassSizeForHeapWalkAt(intptr_t cid);
 
@@ -602,6 +611,7 @@
   intptr_t isolate_count_ = 0;
   bool initial_spawn_successful_ = false;
   Dart_LibraryTagHandler library_tag_handler_ = nullptr;
+  Dart_DeferredLoadHandler deferred_load_handler_ = nullptr;
   int64_t start_time_micros_;
 
 #if !defined(PRODUCT) && !defined(DART_PRECOMPILED_RUNTIME)
@@ -843,6 +853,10 @@
   ObjectPtr CallTagHandler(Dart_LibraryTag tag,
                            const Object& arg1,
                            const Object& arg2);
+  bool HasDeferredLoadHandler() const {
+    return group()->deferred_load_handler() != nullptr;
+  }
+  ObjectPtr CallDeferredLoadHandler(intptr_t id);
 
   void SetupImagePage(const uint8_t* snapshot_buffer, bool is_executable);
 
diff --git a/runtime/vm/isolate_reload.cc b/runtime/vm/isolate_reload.cc
index 6c83404..b9ccfa0 100644
--- a/runtime/vm/isolate_reload.cc
+++ b/runtime/vm/isolate_reload.cc
@@ -404,11 +404,6 @@
 };
 
 bool IsolateReloadContext::IsSameClass(const Class& a, const Class& b) {
-  if (a.is_patch() != b.is_patch()) {
-    // TODO(johnmccutchan): Should we just check the class kind bits?
-    return false;
-  }
-
   // TODO(turnidge): We need to look at generic type arguments for
   // synthetic mixin classes.  Their names are not necessarily unique
   // currently.
@@ -463,6 +458,7 @@
       group_reload_context_(group_reload_context),
       isolate_(isolate),
       saved_class_table_(nullptr),
+      saved_tlc_class_table_(nullptr),
       old_classes_set_storage_(Array::null()),
       class_map_storage_(Array::null()),
       removed_class_set_storage_(Array::null()),
@@ -481,6 +477,7 @@
 IsolateReloadContext::~IsolateReloadContext() {
   ASSERT(zone_ == Thread::Current()->zone());
   ASSERT(saved_class_table_.load(std::memory_order_relaxed) == nullptr);
+  ASSERT(saved_tlc_class_table_.load(std::memory_order_relaxed) == nullptr);
 }
 
 void IsolateGroupReloadContext::ReportError(const Error& error) {
@@ -624,65 +621,13 @@
       const auto& typed_data = ExternalTypedData::Handle(
           Z, ExternalTypedData::NewFinalizeWithFree(
                  const_cast<uint8_t*>(kernel_buffer), kernel_buffer_size));
-
       kernel_program = kernel::Program::ReadFromTypedData(typed_data);
     }
 
     ExternalTypedData& external_typed_data =
         ExternalTypedData::Handle(Z, kernel_program.get()->typed_data()->raw());
     IsolateGroupSource* source = Isolate::Current()->source();
-    Array& hot_reload_blobs = Array::Handle();
-    bool saved_external_typed_data = false;
-    if (source->hot_reload_blobs_ != nullptr) {
-      hot_reload_blobs = source->hot_reload_blobs_;
-
-      // Walk the array, and (if stuff was removed) compact and reuse the space.
-      // Note that the space has to be compacted as the ordering is important.
-      WeakProperty& weak_property = WeakProperty::Handle();
-      WeakProperty& weak_property_tmp = WeakProperty::Handle();
-      ExternalTypedData& existing_entry = ExternalTypedData::Handle(Z);
-      intptr_t next_entry_index = 0;
-      for (intptr_t i = 0; i < hot_reload_blobs.Length(); i++) {
-        weak_property ^= hot_reload_blobs.At(i);
-        if (weak_property.key() != ExternalTypedData::null()) {
-          if (i != next_entry_index) {
-            existing_entry = ExternalTypedData::RawCast(weak_property.key());
-            weak_property_tmp ^= hot_reload_blobs.At(next_entry_index);
-            weak_property_tmp.set_key(existing_entry);
-          }
-          next_entry_index++;
-        }
-      }
-      if (next_entry_index < hot_reload_blobs.Length()) {
-        // There's now space to re-use.
-        weak_property ^= hot_reload_blobs.At(next_entry_index);
-        weak_property.set_key(external_typed_data);
-        next_entry_index++;
-        saved_external_typed_data = true;
-      }
-      if (next_entry_index < hot_reload_blobs.Length()) {
-        ExternalTypedData& nullExternalTypedData = ExternalTypedData::Handle(Z);
-        while (next_entry_index < hot_reload_blobs.Length()) {
-          // Null out any extra spaces.
-          weak_property ^= hot_reload_blobs.At(next_entry_index);
-          weak_property.set_key(nullExternalTypedData);
-          next_entry_index++;
-        }
-      }
-    }
-    if (!saved_external_typed_data) {
-      const WeakProperty& weak_property =
-          WeakProperty::Handle(WeakProperty::New(Heap::kOld));
-      weak_property.set_key(external_typed_data);
-
-      intptr_t length =
-          hot_reload_blobs.IsNull() ? 0 : hot_reload_blobs.Length();
-      Array& new_array =
-          Array::Handle(Array::Grow(hot_reload_blobs, length + 1, Heap::kOld));
-      new_array.SetAt(length, weak_property);
-      source->hot_reload_blobs_ = new_array.raw();
-    }
-    source->num_hot_reloads_++;
+    source->add_loaded_blob(Z, external_typed_data);
 
     modified_libs_ = new (Z) BitVector(Z, num_old_libs_);
     kernel::KernelLoader::FindModifiedLibraries(
@@ -1189,7 +1134,11 @@
 void IsolateReloadContext::RegisterClass(const Class& new_cls) {
   const Class& old_cls = Class::Handle(OldClassOrNull(new_cls));
   if (old_cls.IsNull()) {
-    I->class_table()->Register(new_cls);
+    if (new_cls.IsTopLevel()) {
+      I->class_table()->RegisterTopLevel(new_cls);
+    } else {
+      I->class_table()->Register(new_cls);
+    }
 
     if (FLAG_identity_reload) {
       TIR_Print("Could not find replacement class for %s\n",
@@ -1343,7 +1292,9 @@
   // Copy the class table for isolate.
   ClassTable* class_table = I->class_table();
   ClassPtr* saved_class_table = nullptr;
-  class_table->CopyBeforeHotReload(&saved_class_table, &saved_num_cids_);
+  ClassPtr* saved_tlc_class_table = nullptr;
+  class_table->CopyBeforeHotReload(&saved_class_table, &saved_tlc_class_table,
+                                   &saved_num_cids_, &saved_num_tlc_cids_);
 
   // Copy classes into saved_class_table_ first. Make sure there are no
   // safepoints until saved_class_table_ is filled up and saved so class raw
@@ -1353,6 +1304,8 @@
 
     // The saved_class_table_ is now source of truth for GC.
     saved_class_table_.store(saved_class_table, std::memory_order_release);
+    saved_tlc_class_table_.store(saved_tlc_class_table,
+                                 std::memory_order_release);
 
     // We can therefore wipe out all of the old entries (if that table is used
     // for GC during the hot-reload we have a bug).
@@ -1372,6 +1325,14 @@
       }
     }
   }
+  for (intptr_t i = 0; i < saved_num_tlc_cids_; i++) {
+    const intptr_t cid = ClassTable::CidFromTopLevelIndex(i);
+    if (class_table->IsValidIndex(cid) && class_table->HasValidClassAt(cid)) {
+      cls = class_table->At(cid);
+      bool already_present = old_classes_set.Insert(cls);
+      ASSERT(!already_present);
+    }
+  }
   old_classes_set_storage_ = old_classes_set.Release().raw();
   TIR_Print("---- System had %" Pd " classes\n", saved_num_cids_);
 }
@@ -1520,8 +1481,9 @@
 
 void IsolateReloadContext::RollbackClasses() {
   TIR_Print("---- ROLLING BACK CLASS TABLE\n");
-  ASSERT(saved_num_cids_ > 0);
+  ASSERT((saved_num_cids_ + saved_num_tlc_cids_) > 0);
   ASSERT(saved_class_table_.load(std::memory_order_relaxed) != nullptr);
+  ASSERT(saved_tlc_class_table_.load(std::memory_order_relaxed) != nullptr);
 
   DiscardSavedClassTable(/*is_rollback=*/true);
 }
@@ -1743,6 +1705,10 @@
       TIR_Print("Identity reload failed! B#C=%" Pd " A#C=%" Pd "\n",
                 saved_num_cids_, I->class_table()->NumCids());
     }
+    if (saved_num_tlc_cids_ != I->class_table()->NumTopLevelCids()) {
+      TIR_Print("Identity reload failed! B#TLC=%" Pd " A#TLC=%" Pd "\n",
+                saved_num_tlc_cids_, I->class_table()->NumTopLevelCids());
+    }
     const auto& saved_libs = GrowableObjectArray::Handle(saved_libraries_);
     const GrowableObjectArray& libs =
         GrowableObjectArray::Handle(I->object_store()->libraries());
@@ -1887,20 +1853,29 @@
 }
 
 ClassPtr IsolateReloadContext::GetClassForHeapWalkAt(intptr_t cid) {
-  ClassPtr* class_table = saved_class_table_.load(std::memory_order_acquire);
-  if (class_table != NULL) {
-    ASSERT(cid > 0);
-    ASSERT(cid < saved_num_cids_);
-    return class_table[cid];
+  ClassPtr* class_table = nullptr;
+  intptr_t index = -1;
+  if (ClassTable::IsTopLevelCid(cid)) {
+    class_table = saved_tlc_class_table_.load(std::memory_order_acquire);
+    index = ClassTable::IndexFromTopLevelCid(cid);
+    ASSERT(index < saved_num_tlc_cids_);
   } else {
-    return isolate_->class_table()->At(cid);
+    class_table = saved_class_table_.load(std::memory_order_acquire);
+    index = cid;
+    ASSERT(cid > 0 && cid < saved_num_cids_);
   }
+  if (class_table != nullptr) {
+    return class_table[index];
+  }
+  return isolate_->class_table()->At(cid);
 }
 
 intptr_t IsolateGroupReloadContext::GetClassSizeForHeapWalkAt(classid_t cid) {
+  if (ClassTable::IsTopLevelCid(cid)) {
+    return 0;
+  }
   intptr_t* size_table = saved_size_table_.load(std::memory_order_acquire);
   if (size_table != nullptr) {
-    ASSERT(cid > 0);
     ASSERT(cid < saved_num_cids_);
     return size_table[cid];
   } else {
@@ -1911,9 +1886,13 @@
 void IsolateReloadContext::DiscardSavedClassTable(bool is_rollback) {
   ClassPtr* local_saved_class_table =
       saved_class_table_.load(std::memory_order_relaxed);
-  I->class_table()->ResetAfterHotReload(local_saved_class_table,
-                                        saved_num_cids_, is_rollback);
+  ClassPtr* local_saved_tlc_class_table =
+      saved_tlc_class_table_.load(std::memory_order_relaxed);
+  I->class_table()->ResetAfterHotReload(
+      local_saved_class_table, local_saved_tlc_class_table, saved_num_cids_,
+      saved_num_tlc_cids_, is_rollback);
   saved_class_table_.store(nullptr, std::memory_order_release);
+  saved_tlc_class_table_.store(nullptr, std::memory_order_release);
 }
 
 void IsolateGroupReloadContext::DiscardSavedClassTable(bool is_rollback) {
@@ -1937,6 +1916,13 @@
     auto class_table = reinterpret_cast<ObjectPtr*>(&(saved_class_table[0]));
     visitor->VisitPointers(class_table, saved_num_cids_);
   }
+  ClassPtr* saved_tlc_class_table =
+      saved_class_table_.load(std::memory_order_relaxed);
+  if (saved_tlc_class_table != NULL) {
+    auto class_table =
+        reinterpret_cast<ObjectPtr*>(&(saved_tlc_class_table[0]));
+    visitor->VisitPointers(class_table, saved_num_tlc_cids_);
+  }
 }
 
 ObjectStore* IsolateReloadContext::object_store() {
diff --git a/runtime/vm/isolate_reload.h b/runtime/vm/isolate_reload.h
index 2295441..b06ca57 100644
--- a/runtime/vm/isolate_reload.h
+++ b/runtime/vm/isolate_reload.h
@@ -384,7 +384,9 @@
   std::shared_ptr<IsolateGroupReloadContext> group_reload_context_;
   Isolate* isolate_;
   intptr_t saved_num_cids_ = -1;
+  intptr_t saved_num_tlc_cids_ = -1;
   std::atomic<ClassPtr*> saved_class_table_;
+  std::atomic<ClassPtr*> saved_tlc_class_table_;
   MallocGrowableArray<LibraryInfo> library_infos_;
 
   ClassPtr OldClassOrNull(const Class& replacement_or_new);
diff --git a/runtime/vm/kernel.cc b/runtime/vm/kernel.cc
index 84f456c..19070a4 100644
--- a/runtime/vm/kernel.cc
+++ b/runtime/vm/kernel.cc
@@ -718,12 +718,42 @@
 bool NeedsDynamicInvocationForwarder(const Function& function) {
   Zone* zone = Thread::Current()->zone();
 
+  // Right now closures do not need a dyn:* forwarder.
+  // See https://github.com/dart-lang/sdk/issues/40813
+  if (function.IsClosureFunction()) return false;
+
+  // Method extractors have no parameters to check and return value is a closure
+  // and therefore not an unboxed primitive type.
+  if (function.IsMethodExtractor()) {
+    return false;
+  }
+
+  // Invoke field dispatchers are dynamically generated, will invoke a getter to
+  // obtain the field value and then invoke ".call()" on the result.
+  // Those dynamically generated dispathers don't have proper kernel metadata
+  // associated with them - we can therefore not query if there are dynamic
+  // calls to them or not and are therefore conservative.
+  if (function.IsInvokeFieldDispatcher()) {
+    return true;
+  }
+
+  // The dyn:* forwarders perform unboxing of parameters before calling the
+  // actual target (which accepts unboxed parameters) and boxes return values
+  // of the return value.
+  if (function.HasUnboxedParameters() || function.HasUnboxedReturnValue()) {
+    return true;
+  }
+
+  // There are no parameters to type check for getters and if the return value
+  // is boxed, then the dyn:* forwarder is not needed.
+  if (function.IsImplicitGetterFunction()) {
+    return false;
+  }
+
   // Covariant parameters (both explicitly covariant and generic-covariant-impl)
   // are checked in the body of a function and therefore don't need checks in a
   // dynamic invocation forwarder. So dynamic invocation forwarder is only
   // needed if there are non-covariant parameters of non-top type.
-
-  ASSERT(!function.IsImplicitGetterFunction());
   if (function.IsImplicitSetterFunction()) {
     const auto& field = Field::Handle(zone, function.accessor_field());
     return !(field.is_covariant() || field.is_generic_covariant_impl());
diff --git a/runtime/vm/kernel_isolate.cc b/runtime/vm/kernel_isolate.cc
index ae0b54a..968c212 100644
--- a/runtime/vm/kernel_isolate.cc
+++ b/runtime/vm/kernel_isolate.cc
@@ -476,6 +476,8 @@
 
   Dart_KernelCompilationResult SendAndWaitForResponse(
       Dart_Port kernel_port,
+      const uint8_t* platform_kernel,
+      intptr_t platform_kernel_size,
       const char* expression,
       const Array& definitions,
       const Array& type_definitions,
@@ -494,6 +496,25 @@
     send_port.value.as_send_port.id = port_;
     send_port.value.as_send_port.origin_id = ILLEGAL_PORT;
 
+    Dart_CObject dart_platform_kernel;
+    if (platform_kernel != NULL) {
+      dart_platform_kernel.type = Dart_CObject_kExternalTypedData;
+      dart_platform_kernel.value.as_external_typed_data.type =
+          Dart_TypedData_kUint8;
+      dart_platform_kernel.value.as_external_typed_data.length =
+          platform_kernel_size;
+      dart_platform_kernel.value.as_external_typed_data.data =
+          const_cast<uint8_t*>(platform_kernel);
+      dart_platform_kernel.value.as_external_typed_data.peer =
+          const_cast<uint8_t*>(platform_kernel);
+      dart_platform_kernel.value.as_external_typed_data.callback =
+          PassThroughFinalizer;
+    } else {
+      // If NULL, the kernel service looks up the platform dill file
+      // next to the executable.
+      dart_platform_kernel.type = Dart_CObject_kNull;
+    }
+
     Dart_CObject expression_object;
     expression_object.type = Dart_CObject_kString;
     expression_object.value.as_string = const_cast<char*>(expression);
@@ -560,19 +581,17 @@
     if (source->script_kernel_buffer != nullptr) {
       num_dills++;
     }
-    Array& hot_reload_blobs = Array::Handle();
-    if (source->hot_reload_blobs_ != nullptr) {
-      hot_reload_blobs = source->hot_reload_blobs_;
+    Array& loaded_blobs = Array::Handle();
+    if (source->loaded_blobs_ != nullptr) {
+      loaded_blobs = source->loaded_blobs_;
       WeakProperty& weak_property = WeakProperty::Handle();
-      for (intptr_t i = 0; i < hot_reload_blobs.Length(); i++) {
-        weak_property ^= hot_reload_blobs.At(i);
+      for (intptr_t i = 0; i < loaded_blobs.Length(); i++) {
+        weak_property ^= loaded_blobs.At(i);
         if (weak_property.key() != ExternalTypedData::null()) {
           num_dills++;
         }
       }
     }
-    // TODO(jensj): Get the platform somehow. Currently the dart side simply
-    // loads the dill from file.
 
     Dart_CObject dills_object;
     dills_object.type = Dart_CObject_kArray;
@@ -584,10 +603,10 @@
                            source->kernel_buffer_size);
     dill_num = setDillData(dills_array, dill_num, source->script_kernel_buffer,
                            source->script_kernel_size);
-    if (!hot_reload_blobs.IsNull()) {
+    if (!loaded_blobs.IsNull()) {
       WeakProperty& weak_property = WeakProperty::Handle();
-      for (intptr_t i = 0; i < hot_reload_blobs.Length(); i++) {
-        weak_property ^= hot_reload_blobs.At(i);
+      for (intptr_t i = 0; i < loaded_blobs.Length(); i++) {
+        weak_property ^= loaded_blobs.At(i);
         if (weak_property.key() != ExternalTypedData::null()) {
           ExternalTypedData& externalTypedData = ExternalTypedData::Handle(
               thread->zone(), ExternalTypedData::RawCast(weak_property.key()));
@@ -601,9 +620,9 @@
     }
     dills_object.value.as_array.values = dills_array;
 
-    Dart_CObject hot_reload_count;
-    hot_reload_count.type = Dart_CObject_kInt64;
-    hot_reload_count.value.as_int64 = source->num_hot_reloads_;
+    Dart_CObject num_blob_loads;
+    num_blob_loads.type = Dart_CObject_kInt64;
+    num_blob_loads.value.as_int64 = source->num_blob_loads_;
 
     Dart_CObject suppress_warnings;
     suppress_warnings.type = Dart_CObject_kBool;
@@ -637,6 +656,7 @@
     Dart_CObject* message_arr[] = {&tag,
                                    &send_port,
                                    &isolate_id,
+                                   &dart_platform_kernel,
                                    &expression_object,
                                    &definitions_object,
                                    &type_definitions_object,
@@ -644,7 +664,7 @@
                                    &class_object,
                                    &is_static_object,
                                    &dills_object,
-                                   &hot_reload_count,
+                                   &num_blob_loads,
                                    &suppress_warnings,
                                    &enable_asserts,
                                    &experimental_flags_object,
@@ -777,7 +797,7 @@
     null_safety.value.as_int32 =
         (isolate != NULL) ? (isolate->null_safety() ? kNullSafetyOptionStrong
                                                     : kNullSafetyOptionWeak)
-                          : FLAG_null_safety;
+                          : FLAG_sound_null_safety;
 
     intptr_t num_experimental_flags = experimental_flags->length();
     Dart_CObject** experimental_flags_array =
@@ -1088,6 +1108,8 @@
 }
 
 Dart_KernelCompilationResult KernelIsolate::CompileExpressionToKernel(
+    const uint8_t* platform_kernel,
+    intptr_t platform_kernel_size,
     const char* expression,
     const Array& definitions,
     const Array& type_definitions,
@@ -1105,9 +1127,10 @@
   TransitionVMToNative transition(Thread::Current());
   KernelCompilationRequest request;
   ASSERT(is_static || (klass != nullptr));
-  return request.SendAndWaitForResponse(kernel_port, expression, definitions,
-                                        type_definitions, library_url, klass,
-                                        is_static, experimental_flags_);
+  return request.SendAndWaitForResponse(
+      kernel_port, platform_kernel, platform_kernel_size, expression,
+      definitions, type_definitions, library_url, klass, is_static,
+      experimental_flags_);
 }
 
 Dart_KernelCompilationResult KernelIsolate::UpdateInMemorySources(
diff --git a/runtime/vm/kernel_isolate.h b/runtime/vm/kernel_isolate.h
index fbf31e2..e45022d 100644
--- a/runtime/vm/kernel_isolate.h
+++ b/runtime/vm/kernel_isolate.h
@@ -64,6 +64,8 @@
       Dart_SourceFile source_files[]);
 
   static Dart_KernelCompilationResult CompileExpressionToKernel(
+      const uint8_t* platform_kernel,
+      intptr_t platform_kernel_size,
       const char* expression,
       const Array& definitions,
       const Array& type_definitions,
diff --git a/runtime/vm/kernel_loader.cc b/runtime/vm/kernel_loader.cc
index 37a5469..184aa5b 100644
--- a/runtime/vm/kernel_loader.cc
+++ b/runtime/vm/kernel_loader.cc
@@ -231,6 +231,11 @@
   helper.ReadProhibitions();
 }
 
+void KernelLoader::ReadLoadingUnits() {
+  LoadingUnitsMetadataHelper helper(&helper_);
+  helper.ReadLoadingUnits();
+}
+
 Object& KernelLoader::LoadEntireProgram(Program* program,
                                         bool process_pending_classes) {
   Thread* thread = Thread::Current();
@@ -274,11 +279,19 @@
       if (pair != NULL) {
         // At least two entries with content. Unless the content is the same
         // that's not valid.
-        if (pair->sources->CompareTo(script_source) != 0 ||
-            !pair->line_starts->CanonicalizeEquals(line_starts)) {
-          FATAL(
+        const bool src_differ = pair->sources->CompareTo(script_source) != 0;
+        const bool line_starts_differ =
+            !pair->line_starts->CanonicalizeEquals(line_starts);
+        if (src_differ || line_starts_differ) {
+          FATAL3(
               "Invalid kernel binary: Contains at least two source entries "
-              "that do not agree.");
+              "that do not agree. URI '%s', difference: %s. Subprogram count: "
+              "%" Pd ".",
+              uri_string.ToCString(),
+              src_differ && line_starts_differ
+                  ? "src and line starts"
+                  : (src_differ ? "src" : "line starts"),
+              subprogram_count);
         }
       } else {
         UriToSourceTableEntry* tmp = new UriToSourceTableEntry();
@@ -539,7 +552,7 @@
     for (intptr_t j = 0; j < annotation_count; ++j) {
       const intptr_t tag = helper_.PeekTag();
       if (tag == kConstantExpression) {
-        helper_.ReadByte();  // Skip the tag.
+        helper_.ReadByte();      // Skip the tag.
         helper_.ReadPosition();  // Skip fileOffset.
         helper_.SkipDartType();  // Skip type.
 
@@ -670,7 +683,7 @@
 
         const intptr_t tag = helper_.PeekTag();
         if (tag == kConstantExpression) {
-          helper_.ReadByte();  // Skip the tag.
+          helper_.ReadByte();      // Skip the tag.
           helper_.ReadPosition();  // Skip fileOffset.
           helper_.SkipDartType();  // Skip type.
 
@@ -1040,15 +1053,17 @@
       library_helper.GetNonNullableByDefaultCompiledMode();
   if (!I->null_safety() && mode == NNBDCompiledMode::kStrong) {
     H.ReportError(
-        "Library '%s' was compiled with null safety (in strong mode) and it "
-        "requires --null-safety option at runtime",
+        "Library '%s' was compiled with sound null safety (in strong mode) and "
+        "it "
+        "requires --sound-null-safety option at runtime",
         String::Handle(library.url()).ToCString());
   }
   if (I->null_safety() && (mode == NNBDCompiledMode::kWeak ||
                            mode == NNBDCompiledMode::kDisabled)) {
     H.ReportError(
-        "Library '%s' was compiled without null safety (in weak mode) and it "
-        "cannot be used with --null-safety at runtime",
+        "Library '%s' was compiled without sound null safety (in weak mode) "
+        "and it "
+        "cannot be used with --sound-null-safety at runtime",
         String::Handle(library.url()).ToCString());
   }
   library.set_nnbd_compiled_mode(mode);
@@ -1104,6 +1119,7 @@
   Class& toplevel_class =
       Class::Handle(Z, Class::New(library, Symbols::TopLevel(), script,
                                   TokenPosition::kNoSource, register_class));
+  toplevel_class.set_is_abstract();
   toplevel_class.set_is_declaration_loaded();
   toplevel_class.set_is_type_finalized();
   library.set_toplevel_class(toplevel_class);
@@ -1867,7 +1883,7 @@
         // TODO(sjindel): Refactor `ExternalName` handling to do this as well
         // and avoid the "potential natives" list.
 
-        helper_.ReadByte();  // Skip the tag.
+        helper_.ReadByte();      // Skip the tag.
         helper_.ReadPosition();  // Skip fileOffset.
         helper_.SkipDartType();  // Skip type.
         const intptr_t offset_in_constant_table = helper_.ReadUInt();
@@ -2228,6 +2244,7 @@
   getter.set_accessor_field(field);
   getter.set_is_extension_member(field.is_extension_member());
   H.SetupFieldAccessorFunction(klass, getter, field_type);
+  T.SetupUnboxingInfoMetadataForFieldAccessors(getter, library_kernel_offset_);
 
   if (field.NeedsSetter()) {
     // Only static fields can be const.
@@ -2249,6 +2266,8 @@
     setter.set_accessor_field(field);
     setter.set_is_extension_member(field.is_extension_member());
     H.SetupFieldAccessorFunction(klass, setter, field_type);
+    T.SetupUnboxingInfoMetadataForFieldAccessors(getter,
+                                                 library_kernel_offset_);
   }
 }
 
diff --git a/runtime/vm/kernel_loader.h b/runtime/vm/kernel_loader.h
index 8e79898..7826867 100644
--- a/runtime/vm/kernel_loader.h
+++ b/runtime/vm/kernel_loader.h
@@ -223,6 +223,7 @@
   static void FinishLoading(const Class& klass);
 
   void ReadObfuscationProhibitions();
+  void ReadLoadingUnits();
 
  private:
   // Check for the presence of a (possibly const) constructor for the
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index db3458a..64a51b7 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -173,6 +173,7 @@
 ClassPtr Object::icdata_class_ = static_cast<ClassPtr>(RAW_NULL);
 ClassPtr Object::megamorphic_cache_class_ = static_cast<ClassPtr>(RAW_NULL);
 ClassPtr Object::subtypetestcache_class_ = static_cast<ClassPtr>(RAW_NULL);
+ClassPtr Object::loadingunit_class_ = static_cast<ClassPtr>(RAW_NULL);
 ClassPtr Object::api_error_class_ = static_cast<ClassPtr>(RAW_NULL);
 ClassPtr Object::language_error_class_ = static_cast<ClassPtr>(RAW_NULL);
 ClassPtr Object::unhandled_exception_class_ = static_cast<ClassPtr>(RAW_NULL);
@@ -736,7 +737,7 @@
     cls.set_next_field_offset(host_next_field_offset, target_next_field_offset);
     cls.set_id(Class::kClassId);
     cls.set_state_bits(0);
-    cls.set_is_finalized();
+    cls.set_is_allocate_finalized();
     cls.set_is_declaration_loaded();
     cls.set_is_type_finalized();
     cls.set_type_arguments_field_offset_in_words(Class::kNoTypeArguments,
@@ -744,7 +745,7 @@
     cls.set_num_type_arguments(0);
     cls.set_num_native_fields(0);
     cls.InitEmptyFields();
-    isolate->RegisterClass(cls);
+    isolate->class_table()->Register(cls);
   }
 
   // Allocate and initialize the null class.
@@ -755,7 +756,7 @@
   // Allocate and initialize Never class.
   cls = Class::New<Instance, RTN::Instance>(kNeverCid, isolate);
   cls.set_num_type_arguments(0);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
   isolate->object_store()->set_never_class(cls);
@@ -765,7 +766,7 @@
       Class::New<FreeListElement::FakeInstance,
                  RTN::FreeListElement::FakeInstance>(kFreeListElement, isolate);
   cls.set_num_type_arguments(0);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
 
@@ -774,7 +775,7 @@
                    RTN::ForwardingCorpse::FakeInstance>(kForwardingCorpse,
                                                         isolate);
   cls.set_num_type_arguments(0);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
 
@@ -890,6 +891,9 @@
   cls = Class::New<SubtypeTestCache, RTN::SubtypeTestCache>(isolate);
   subtypetestcache_class_ = cls.raw();
 
+  cls = Class::New<LoadingUnit, RTN::LoadingUnit>(isolate);
+  loadingunit_class_ = cls.raw();
+
   cls = Class::New<ApiError, RTN::ApiError>(isolate);
   api_error_class_ = cls.raw();
 
@@ -1057,20 +1061,20 @@
   cls = Class::New<Instance, RTN::Instance>(kDynamicCid, isolate);
   cls.set_is_abstract();
   cls.set_num_type_arguments(0);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
   dynamic_class_ = cls.raw();
 
   cls = Class::New<Instance, RTN::Instance>(kVoidCid, isolate);
   cls.set_num_type_arguments(0);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
   void_class_ = cls.raw();
 
   cls = Class::New<Type, RTN::Type>(isolate);
-  cls.set_is_finalized();
+  cls.set_is_allocate_finalized();
   cls.set_is_declaration_loaded();
   cls.set_is_type_finalized();
 
@@ -1286,6 +1290,7 @@
   icdata_class_ = static_cast<ClassPtr>(RAW_NULL);
   megamorphic_cache_class_ = static_cast<ClassPtr>(RAW_NULL);
   subtypetestcache_class_ = static_cast<ClassPtr>(RAW_NULL);
+  loadingunit_class_ = static_cast<ClassPtr>(RAW_NULL);
   api_error_class_ = static_cast<ClassPtr>(RAW_NULL);
   language_error_class_ = static_cast<ClassPtr>(RAW_NULL);
   unhandled_exception_class_ = static_cast<ClassPtr>(RAW_NULL);
@@ -1388,6 +1393,7 @@
   SET_CLASS_NAME(icdata, ICData);
   SET_CLASS_NAME(megamorphic_cache, MegamorphicCache);
   SET_CLASS_NAME(subtypetestcache, SubtypeTestCache);
+  SET_CLASS_NAME(loadingunit, LoadingUnit);
   SET_CLASS_NAME(api_error, ApiError);
   SET_CLASS_NAME(language_error, LanguageError);
   SET_CLASS_NAME(unhandled_exception, UnhandledException);
@@ -1844,7 +1850,7 @@
 
     cls = Class::New<Instance, RTN::Instance>(kNeverCid, isolate);
     cls.set_num_type_arguments(0);
-    cls.set_is_finalized();
+    cls.set_is_allocate_finalized();
     cls.set_is_declaration_loaded();
     cls.set_is_type_finalized();
     cls.set_name(Symbols::Never());
@@ -2009,7 +2015,7 @@
                                               /*register_class=*/false);
     cls.set_instance_size(0, 0);
     cls.set_next_field_offset(-kWordSize, -compiler::target::kWordSize);
-    isolate->RegisterClass(cls);
+    isolate->class_table()->Register(cls);
     RegisterPrivateClass(cls, Symbols::_ByteBuffer(), lib);
     pending_classes.Add(cls);
 
@@ -2458,7 +2464,7 @@
     cls = Class::New<Instance, RTN::Instance>(kByteBufferCid, isolate,
                                               /*register_isolate=*/false);
     cls.set_instance_size_in_words(0, 0);
-    isolate->RegisterClass(cls);
+    isolate->class_table()->Register(cls);
 
     cls = Class::New<Integer, RTN::Integer>(isolate);
     object_store->set_integer_implementation_class(cls);
@@ -2841,7 +2847,7 @@
     // possible in this case.
     result.set_is_declaration_loaded();
     result.set_is_type_finalized();
-    result.set_is_finalized();
+    result.set_is_allocate_finalized();
   } else if (FakeObject::kClassId != kClosureCid) {
     // VM backed classes are almost ready: run checks and resolve class
     // references, but do not recompute size.
@@ -2851,7 +2857,7 @@
   NOT_IN_PRECOMPILED(result.set_binary_declaration_offset(0));
   result.InitEmptyFields();
   if (register_class) {
-    isolate->RegisterClass(result);
+    isolate->class_table()->Register(result);
   }
   return result.raw();
 }
@@ -3654,7 +3660,11 @@
 }
 
 bool Function::IsDynamicInvocationForwarderName(const String& name) {
-  return name.StartsWith(Symbols::DynamicPrefix());
+  return IsDynamicInvocationForwarderName(name.raw());
+}
+
+bool Function::IsDynamicInvocationForwarderName(StringPtr name) {
+  return String::StartsWith(name, Symbols::DynamicPrefix().raw());
 }
 
 StringPtr Function::DemangleDynamicInvocationForwarderName(const String& name) {
@@ -3664,6 +3674,10 @@
                       name.Length() - kDynamicPrefixLength);
 }
 
+StringPtr Function::CreateDynamicInvocationForwarderName(const String& name) {
+  return Symbols::FromConcat(Thread::Current(), Symbols::DynamicPrefix(), name);
+}
+
 #if !defined(DART_PRECOMPILED_RUNTIME)
 FunctionPtr Function::CreateDynamicInvocationForwarder(
     const String& mangled_name) const {
@@ -3706,18 +3720,17 @@
   return forwarder.raw();
 }
 
-StringPtr Function::CreateDynamicInvocationForwarderName(const String& name) {
-  return Symbols::FromConcat(Thread::Current(), Symbols::DynamicPrefix(), name);
-}
-
 FunctionPtr Function::GetDynamicInvocationForwarder(
     const String& mangled_name,
     bool allow_add /* = true */) const {
   ASSERT(IsDynamicInvocationForwarderName(mangled_name));
-  const Class& owner = Class::Handle(Owner());
-  Function& result = Function::Handle(owner.GetInvocationDispatcher(
-      mangled_name, Array::null_array(),
-      FunctionLayout::kDynamicInvocationForwarder, /*create_if_absent=*/false));
+  auto zone = Thread::Current()->zone();
+  const Class& owner = Class::Handle(zone, Owner());
+  Function& result = Function::Handle(
+      zone,
+      owner.GetInvocationDispatcher(mangled_name, Array::null_array(),
+                                    FunctionLayout::kDynamicInvocationForwarder,
+                                    /*create_if_absent=*/false));
 
   if (!result.IsNull()) {
     return result.raw();
@@ -3778,7 +3791,7 @@
     if (raw() == isolate->class_table()->At(id())) {
       // Sets the new size in the class table.
       isolate->class_table()->SetAt(id(), raw());
-      if (FLAG_precompiled_mode) {
+      if (FLAG_precompiled_mode && !ClassTable::IsTopLevelCid(id())) {
         isolate->group()->shared_class_table()->SetUnboxedFieldsMapAt(
             id(), host_bitmap);
       }
@@ -4079,6 +4092,69 @@
   return value.raw();
 }
 
+// Creates a new array of boxed arguments suitable for invoking the callable
+// from the original boxed arguments for a static call. Also sets the contents
+// of the handle pointed to by [callable_args_desc_array_out] to an appropriate
+// arguments descriptor array for the new arguments.
+//
+// Assumes [arg_names] are consistent with [static_args_descriptor].
+static ArrayPtr CreateCallableArgumentsFromStatic(
+    Zone* zone,
+    const Instance& receiver,
+    const Array& static_args,
+    const Array& arg_names,
+    const ArgumentsDescriptor& static_args_descriptor) {
+  const intptr_t num_static_type_args = static_args_descriptor.TypeArgsLen();
+  const intptr_t num_static_args = static_args_descriptor.Count();
+  // Double check that the static args descriptor expects boxed arguments
+  // and the static args descriptor is consistent with the static arguments.
+  ASSERT_EQUAL(static_args_descriptor.Size(), num_static_args);
+  ASSERT_EQUAL(static_args.Length(),
+               num_static_args + (num_static_type_args > 0 ? 1 : 0));
+  // Add an additional slot to store the callable as the receiver.
+  const auto& callable_args =
+      Array::Handle(zone, Array::New(static_args.Length() + 1));
+  const intptr_t first_arg_index = static_args_descriptor.FirstArgIndex();
+  auto& temp = Object::Handle(zone);
+  // Copy the static args into the corresponding slots of the callable args.
+  if (num_static_type_args > 0) {
+    temp = static_args.At(0);
+    callable_args.SetAt(0, temp);
+  }
+  for (intptr_t i = first_arg_index; i < static_args.Length(); i++) {
+    temp = static_args.At(i);
+    callable_args.SetAt(i + 1, temp);
+  }
+  // Set the receiver slot in the callable args.
+  callable_args.SetAt(first_arg_index, receiver);
+  return callable_args.raw();
+}
+
+// Return the result of invoking the callable contained in the arguments.
+// Performs non-covariant type checks when the callable function does not
+// expect to be called dynamically.
+static ObjectPtr InvokeCallableWithChecks(Zone* zone,
+                                          const Array& args,
+                                          const Array& args_descriptor_array) {
+  auto& result = Object::Handle(
+      zone, DartEntry::ResolveCallable(args, args_descriptor_array));
+  if (result.IsError()) {
+    return result.raw();
+  }
+  const auto& function =
+      Function::Handle(zone, Function::RawCast(result.raw()));
+  if (!function.IsNull() && !function.CanReceiveDynamicInvocation()) {
+    // Let DoArgumentTypesMatch extract the appropriate instantiator
+    // and function tavs from the arguments (including the callable).
+    ArgumentsDescriptor call_args_descriptor(args_descriptor_array);
+    result = function.DoArgumentTypesMatch(args, call_args_descriptor);
+    if (result.IsError()) {
+      return result.raw();
+    }
+  }
+  return DartEntry::InvokeCallable(function, args, args_descriptor_array);
+}
+
 ObjectPtr Class::Invoke(const String& function_name,
                         const Array& args,
                         const Array& arg_names,
@@ -4086,11 +4162,16 @@
                         bool check_is_entrypoint) const {
   Thread* thread = Thread::Current();
   Zone* zone = thread->zone();
-
-  // TODO(regis): Support invocation of generic functions with type arguments.
-  const int kTypeArgsLen = 0;
   CHECK_ERROR(EnsureIsFinalized(thread));
 
+  // We don't pass any explicit type arguments, which will be understood as
+  // using dynamic for any function type arguments by lower layers.
+  const int kTypeArgsLen = 0;
+  const Array& args_descriptor_array = Array::Handle(
+      zone, ArgumentsDescriptor::NewBoxed(kTypeArgsLen, args.Length(),
+                                          arg_names, Heap::kNew));
+  ArgumentsDescriptor args_descriptor(args_descriptor_array);
+
   Function& function =
       Function::Handle(zone, LookupStaticFunction(function_name));
 
@@ -4107,37 +4188,34 @@
       if (check_is_entrypoint) {
         CHECK_ERROR(EntryPointFieldInvocationError(function_name));
       }
-      // Make room for the closure (receiver) in the argument list.
-      const intptr_t num_args = args.Length();
-      const Array& call_args = Array::Handle(zone, Array::New(num_args + 1));
-      Object& temp = Object::Handle(zone);
-      for (int i = 0; i < num_args; i++) {
-        temp = args.At(i);
-        call_args.SetAt(i + 1, temp);
-      }
-      call_args.SetAt(0, getter_result);
-      const Array& call_args_descriptor_array = Array::Handle(
-          zone, ArgumentsDescriptor::NewBoxed(kTypeArgsLen, call_args.Length(),
+      const auto& call_args_descriptor_array = Array::Handle(
+          zone, ArgumentsDescriptor::NewBoxed(args_descriptor.TypeArgsLen(),
+                                              args_descriptor.Count() + 1,
                                               arg_names, Heap::kNew));
-      // Call the closure.
-      return DartEntry::InvokeClosure(call_args, call_args_descriptor_array);
+      const auto& call_args = Array::Handle(
+          zone,
+          CreateCallableArgumentsFromStatic(zone, Instance::Cast(getter_result),
+                                            args, arg_names, args_descriptor));
+      return InvokeCallableWithChecks(zone, call_args,
+                                      call_args_descriptor_array);
     }
   }
-  const Array& args_descriptor_array = Array::Handle(
-      zone, ArgumentsDescriptor::NewBoxed(kTypeArgsLen, args.Length(),
-                                          arg_names, Heap::kNew));
-  ArgumentsDescriptor args_descriptor(args_descriptor_array);
-  const TypeArguments& type_args = Object::null_type_arguments();
-  if (function.IsNull() || !function.AreValidArguments(args_descriptor, NULL) ||
+
+  if (function.IsNull() ||
+      !function.AreValidArguments(args_descriptor, nullptr) ||
       (respect_reflectable && !function.is_reflectable())) {
     return ThrowNoSuchMethod(
         AbstractType::Handle(zone, RareType()), function_name, args, arg_names,
         InvocationMirror::kStatic, InvocationMirror::kMethod);
   }
-  ObjectPtr type_error =
-      function.DoArgumentTypesMatch(args, args_descriptor, type_args);
-  if (type_error != Error::null()) {
-    return type_error;
+  // This is a static function, so we pass an empty instantiator tav.
+  ASSERT(function.is_static());
+  if (!function.CanReceiveDynamicInvocation()) {
+    ObjectPtr type_error = function.DoArgumentTypesMatch(
+        args, args_descriptor, Object::empty_type_arguments());
+    if (type_error != Error::null()) {
+      return type_error;
+    }
   }
   return DartEntry::InvokeFunction(function, args, args_descriptor_array);
 }
@@ -4212,6 +4290,32 @@
   return error.raw();
 }
 
+// Ensure that code outdated by finalized class is cleaned up, new instance of
+// this class is ready to be allocated.
+ErrorPtr Class::EnsureIsAllocateFinalized(Thread* thread) const {
+  ASSERT(!IsNull());
+  // Finalized classes have already been parsed.
+  if (is_allocate_finalized()) {
+    return Error::null();
+  }
+  if (Compiler::IsBackgroundCompilation()) {
+    Compiler::AbortBackgroundCompilation(
+        DeoptId::kNone, "Class allocate finalization while compiling");
+  }
+  ASSERT(thread->IsMutatorThread());
+  ASSERT(thread != NULL);
+  Error& error = Error::Handle(thread->zone(), EnsureIsFinalized(thread));
+  if (!error.IsNull()) {
+    ASSERT(thread == Thread::Current());
+    if (thread->long_jump_base() != NULL) {
+      Report::LongJump(error);
+      UNREACHABLE();
+    }
+  }
+  error ^= ClassFinalizer::AllocateFinalizeClass(*this);
+  return error.raw();
+}
+
 void Class::SetFields(const Array& value) const {
   ASSERT(!value.IsNull());
 #if defined(DEBUG)
@@ -4347,7 +4451,7 @@
     result.set_is_abstract();
   }
   if (register_class) {
-    isolate->RegisterClass(result);
+    isolate->class_table()->Register(result);
   }
   return result.raw();
 }
@@ -4405,7 +4509,7 @@
         compiler::target::RoundedAllocationSize(target_instance_size));
     cls.set_next_field_offset(host_instance_size, target_instance_size);
     cls.set_num_native_fields(field_count);
-    cls.set_is_finalized();
+    cls.set_is_allocate_finalized();
     cls.set_is_declaration_loaded();
     cls.set_is_type_finalized();
     cls.set_is_synthesized_class();
@@ -4445,7 +4549,7 @@
   result.set_next_field_offset(host_next_field_offset,
                                target_next_field_offset);
   result.set_is_prefinalized();
-  isolate->RegisterClass(result);
+  isolate->class_table()->Register(result);
   return result.raw();
 }
 
@@ -4463,7 +4567,7 @@
   result.set_next_field_offset(host_next_field_offset,
                                target_next_field_offset);
   result.set_is_prefinalized();
-  isolate->RegisterClass(result);
+  isolate->class_table()->Register(result);
   return result.raw();
 }
 
@@ -4482,7 +4586,7 @@
   result.set_next_field_offset(host_next_field_offset,
                                target_next_field_offset);
   result.set_is_prefinalized();
-  isolate->RegisterClass(result);
+  isolate->class_table()->Register(result);
   return result.raw();
 }
 
@@ -4501,7 +4605,7 @@
   result.set_next_field_offset(host_next_field_offset,
                                target_next_field_offset);
   result.set_is_prefinalized();
-  isolate->RegisterClass(result);
+  isolate->class_table()->Register(result);
   return result.raw();
 }
 
@@ -4522,7 +4626,7 @@
   result.set_next_field_offset(host_next_field_offset,
                                target_next_field_offset);
   result.set_is_prefinalized();
-  isolate->RegisterClass(result);
+  isolate->class_table()->Register(result);
   return result.raw();
 }
 
@@ -4676,6 +4780,8 @@
       return Symbols::MegamorphicCache().ToCString();
     case kSubtypeTestCacheCid:
       return Symbols::SubtypeTestCache().ToCString();
+    case kLoadingUnitCid:
+      return Symbols::LoadingUnit().ToCString();
     case kApiErrorCid:
       return Symbols::ApiError().ToCString();
     case kLanguageErrorCid:
@@ -4757,10 +4863,6 @@
                                           raw_ptr()->state_bits_));
 }
 
-void Class::set_is_patch() const {
-  set_state_bits(PatchBit::update(true, raw_ptr()->state_bits_));
-}
-
 void Class::set_is_synthesized_class() const {
   set_state_bits(SynthesizedClassBit::update(true, raw_ptr()->state_bits_));
 }
@@ -4796,6 +4898,12 @@
                                             raw_ptr()->state_bits_));
 }
 
+void Class::set_is_allocate_finalized() const {
+  ASSERT(!is_allocate_finalized());
+  set_state_bits(ClassFinalizedBits::update(ClassLayout::kAllocateFinalized,
+                                            raw_ptr()->state_bits_));
+}
+
 void Class::set_is_prefinalized() const {
   ASSERT(!is_finalized());
   set_state_bits(ClassFinalizedBits::update(ClassLayout::kPreFinalized,
@@ -5440,10 +5548,9 @@
   NoSafepointScope no_safepoint;
   const Library& lib = Library::Handle(library());
   const char* library_name = lib.IsNull() ? "" : lib.ToCString();
-  const char* patch_prefix = is_patch() ? "Patch " : "";
   const char* class_name = String::Handle(Name()).ToCString();
-  return OS::SCreate(Thread::Current()->zone(), "%s %sClass: %s", library_name,
-                     patch_prefix, class_name);
+  return OS::SCreate(Thread::Current()->zone(), "%s Class: %s", library_name,
+                     class_name);
 }
 
 // Thomas Wang, Integer Hash Functions.
@@ -7723,83 +7830,358 @@
   return true;
 }
 
+// Checks each supplied function type argument is a subtype of the corresponding
+// bound. Also takes the number of type arguments to skip over because they
+// belong to parent functions and are not included in the type parameters.
+// Returns null if all checks succeed, otherwise returns a non-null Error for
+// one of the failures.
+static ObjectPtr TypeArgumentsAreBoundSubtypes(
+    Zone* zone,
+    const TokenPosition& token_pos,
+    const TypeArguments& type_parameters,
+    intptr_t num_parent_type_args,
+    const TypeArguments& instantiator_type_arguments,
+    const TypeArguments& function_type_arguments) {
+  ASSERT(!type_parameters.IsNull());
+  ASSERT(!function_type_arguments.IsNull());
+  const intptr_t kNumTypeArgs = function_type_arguments.Length();
+  ASSERT_EQUAL(num_parent_type_args + type_parameters.Length(), kNumTypeArgs);
+
+  // Don't bother allocating handles, there's nothing to check.
+  if (kNumTypeArgs - num_parent_type_args == 0) return Error::null();
+
+  auto& type = AbstractType::Handle(zone);
+  auto& bound = AbstractType::Handle(zone);
+  auto& name = String::Handle(zone);
+  for (intptr_t i = num_parent_type_args; i < kNumTypeArgs; i++) {
+    type = type_parameters.TypeAt(i - num_parent_type_args);
+    ASSERT(type.IsTypeParameter());
+    const auto& parameter = TypeParameter::Cast(type);
+    bound = parameter.bound();
+    name = parameter.name();
+    // Only perform non-covariant checks where the bound is not the top type.
+    if (parameter.IsGenericCovariantImpl() || bound.IsTopTypeForSubtyping()) {
+      continue;
+    }
+    if (!AbstractType::InstantiateAndTestSubtype(&type, &bound,
+                                                 instantiator_type_arguments,
+                                                 function_type_arguments)) {
+      return Error::RawCast(ThrowTypeError(token_pos, type, bound, name));
+    }
+  }
+
+  return Error::null();
+}
+
+// Returns a TypeArguments object where, for each type parameter local to this
+// function, the entry in the TypeArguments is an instantiated version of its
+// bound. In the instantiated bound, any local function type parameter
+// references are replaced with the corresponding bound if that bound can be
+// fully instantiated without local function type parameters, otherwise dynamic.
+static TypeArgumentsPtr InstantiateTypeParametersToBounds(
+    Zone* zone,
+    const TokenPosition& token_pos,
+    const TypeArguments& type_parameters,
+    const TypeArguments& instantiator_type_args,
+    intptr_t num_parent_type_args,
+    const TypeArguments& parent_type_args) {
+  ASSERT(!type_parameters.IsNull());
+  const intptr_t kNumCurrentTypeArgs = type_parameters.Length();
+  const intptr_t kNumTypeArgs = kNumCurrentTypeArgs + num_parent_type_args;
+  auto& function_type_args = TypeArguments::Handle(zone);
+
+  bool all_bounds_instantiated = true;
+
+  // Create a type argument vector large enough for the parents' and current
+  // type arguments.
+  function_type_args = TypeArguments::New(kNumTypeArgs);
+  auto& type = AbstractType::Handle(zone);
+  auto& bound = AbstractType::Handle(zone);
+  // First copy over the parent type args (or the dynamic type if null).
+  for (intptr_t i = 0; i < num_parent_type_args; i++) {
+    type = parent_type_args.IsNull() ? Type::DynamicType()
+                                     : parent_type_args.TypeAt(i);
+    function_type_args.SetTypeAt(i, type);
+  }
+  // Now try fully instantiating the bounds of each parameter using only
+  // the instantiator and parent function type arguments. If possible, keep the
+  // instantiated bound as the entry. Otherwise, just set that entry to dynamic.
+  for (intptr_t i = num_parent_type_args; i < kNumTypeArgs; i++) {
+    type = type_parameters.TypeAt(i - num_parent_type_args);
+    const auto& param = TypeParameter::Cast(type);
+    bound = param.bound();
+    // Only instantiate up to the parent type parameters.
+    if (!bound.IsInstantiated(kAny, num_parent_type_args)) {
+      bound = bound.InstantiateFrom(instantiator_type_args, function_type_args,
+                                    num_parent_type_args, Heap::kNew);
+    }
+    if (!bound.IsInstantiated()) {
+      // There are local type variables used in this bound.
+      bound = Type::DynamicType();
+      all_bounds_instantiated = false;
+    }
+    function_type_args.SetTypeAt(i, bound);
+  }
+
+  // If all the bounds were instantiated in the first pass, then there can't
+  // be any self or mutual recursion, so skip the bounds subtype check.
+  if (all_bounds_instantiated) return function_type_args.raw();
+
+  // Do another pass, using the set of TypeArguments we just created. If a given
+  // bound was instantiated in the last pass, just copy it over. (We don't need
+  // to iterate to a fixed point, since there should be no self or mutual
+  // recursion in the bounds.)
+  const auto& first_round =
+      TypeArguments::Handle(zone, function_type_args.raw());
+  function_type_args = TypeArguments::New(kNumTypeArgs);
+  // Again, copy over the parent type arguments first.
+  for (intptr_t i = 0; i < num_parent_type_args; i++) {
+    type = first_round.TypeAt(i);
+    function_type_args.SetTypeAt(i, type);
+  }
+  for (intptr_t i = num_parent_type_args; i < kNumTypeArgs; i++) {
+    type = type_parameters.TypeAt(i - num_parent_type_args);
+    const auto& param = TypeParameter::Cast(type);
+    bound = first_round.TypeAt(i);
+    // The dynamic type is never a bound, even when implicit, so it also marks
+    // bounds that were not already fully instantiated.
+    if (bound.raw() == Type::DynamicType()) {
+      bound = param.bound();
+      bound = bound.InstantiateFrom(instantiator_type_args, first_round,
+                                    kAllFree, Heap::kNew);
+    }
+    function_type_args.SetTypeAt(i, bound);
+  }
+
+  return function_type_args.raw();
+}
+
+// Retrieves the function type arguments, if any. This could be explicitly
+// passed type from the arguments array, delayed type arguments in closures,
+// or instantiated bounds for the type parameters if no other source for
+// function type arguments are found.
+static TypeArgumentsPtr RetrieveFunctionTypeArguments(
+    Thread* thread,
+    Zone* zone,
+    const Function& function,
+    const Instance& receiver,
+    const TypeArguments& instantiator_type_args,
+    const TypeArguments& type_params,
+    const Array& args,
+    const ArgumentsDescriptor& args_desc) {
+  ASSERT(!function.IsNull());
+
+  const intptr_t kNumCurrentTypeArgs = function.NumTypeParameters(thread);
+  const intptr_t kNumParentTypeArgs = function.NumParentTypeParameters();
+  const intptr_t kNumTypeArgs = kNumCurrentTypeArgs + kNumParentTypeArgs;
+  // Non-generic functions don't receive type arguments.
+  if (kNumTypeArgs == 0) return Object::empty_type_arguments().raw();
+  // Closure functions require that the receiver be provided (and is a closure).
+  ASSERT(!function.IsClosureFunction() || receiver.IsClosure());
+
+  // Only closure functions should have possibly generic parents.
+  ASSERT(function.IsClosureFunction() || kNumParentTypeArgs == 0);
+  const auto& parent_type_args =
+      function.IsClosureFunction()
+          ? TypeArguments::Handle(
+                zone, Closure::Cast(receiver).function_type_arguments())
+          : Object::null_type_arguments();
+  // We don't try to instantiate the parent type parameters to their bounds
+  // if not provided or check any closed-over type arguments against the parent
+  // type parameter bounds (since they have been type checked already).
+  if (kNumCurrentTypeArgs == 0) return parent_type_args.raw();
+
+  auto& function_type_args = TypeArguments::Handle(zone);
+  if (function.IsClosureFunction()) {
+    const auto& closure = Closure::Cast(receiver);
+    function_type_args = closure.delayed_type_arguments();
+    if (function_type_args.raw() == Object::empty_type_arguments().raw()) {
+      // There are no delayed type arguments, so set back to null.
+      function_type_args = TypeArguments::null();
+    }
+  }
+
+  if (function_type_args.IsNull() && args_desc.TypeArgsLen() > 0) {
+    function_type_args ^= args.At(0);
+  }
+
+  if (function_type_args.IsNull()) {
+    // We have no explicitly provided function type arguments, so generate
+    // some by instantiating the parameters to bounds.
+    return InstantiateTypeParametersToBounds(
+        zone, function.token_pos(), type_params, instantiator_type_args,
+        kNumParentTypeArgs, parent_type_args);
+  }
+
+  if (kNumParentTypeArgs > 0) {
+    function_type_args = function_type_args.Prepend(
+        zone, parent_type_args, kNumParentTypeArgs, kNumTypeArgs);
+  }
+
+  return function_type_args.raw();
+}
+
+// Retrieves the instantiator type arguments, if any, from the receiver.
+static TypeArgumentsPtr RetrieveInstantiatorTypeArguments(
+    Zone* zone,
+    const Function& function,
+    const Instance& receiver) {
+  if (function.IsClosureFunction()) {
+    ASSERT(receiver.IsClosure());
+    const auto& closure = Closure::Cast(receiver);
+    return closure.instantiator_type_arguments();
+  }
+  if (!receiver.IsNull()) {
+    const auto& cls = Class::Handle(zone, receiver.clazz());
+    if (cls.NumTypeArguments() > 0) {
+      return receiver.GetTypeArguments();
+    }
+  }
+  return Object::empty_type_arguments().raw();
+}
+
+ObjectPtr Function::DoArgumentTypesMatch(
+    const Array& args,
+    const ArgumentsDescriptor& args_desc) const {
+  Thread* thread = Thread::Current();
+  Zone* zone = thread->zone();
+
+  auto& receiver = Instance::Handle(zone);
+  if (IsClosureFunction() || HasThisParameter()) {
+    receiver ^= args.At(args_desc.FirstArgIndex());
+  }
+  const auto& instantiator_type_arguments = TypeArguments::Handle(
+      zone, RetrieveInstantiatorTypeArguments(zone, *this, receiver));
+  return Function::DoArgumentTypesMatch(args, args_desc,
+                                        instantiator_type_arguments);
+}
+
 ObjectPtr Function::DoArgumentTypesMatch(
     const Array& args,
     const ArgumentsDescriptor& args_desc,
-    const TypeArguments& instantiator_type_args) const {
+    const TypeArguments& instantiator_type_arguments) const {
   Thread* thread = Thread::Current();
   Zone* zone = thread->zone();
-  Function& instantiated_func = Function::Handle(zone, raw());
 
-  if (!HasInstantiatedSignature()) {
-    instantiated_func = InstantiateSignatureFrom(instantiator_type_args,
-                                                 Object::null_type_arguments(),
-                                                 kAllFree, Heap::kNew);
+  auto& receiver = Instance::Handle(zone);
+  if (IsClosureFunction() || HasThisParameter()) {
+    receiver ^= args.At(args_desc.FirstArgIndex());
   }
-  AbstractType& argument_type = AbstractType::Handle(zone);
-  AbstractType& parameter_type = AbstractType::Handle(zone);
+
+  const auto& params = TypeArguments::Handle(zone, type_parameters());
+  const auto& function_type_arguments = TypeArguments::Handle(
+      zone, RetrieveFunctionTypeArguments(thread, zone, *this, receiver,
+                                          instantiator_type_arguments, params,
+                                          args, args_desc));
+  return Function::DoArgumentTypesMatch(
+      args, args_desc, instantiator_type_arguments, function_type_arguments);
+}
+
+ObjectPtr Function::DoArgumentTypesMatch(
+    const Array& args,
+    const ArgumentsDescriptor& args_desc,
+    const TypeArguments& instantiator_type_arguments,
+    const TypeArguments& function_type_arguments) const {
+  // We need a concrete (possibly empty) type arguments vector, not the
+  // implicitly filled with dynamic one.
+  ASSERT(!function_type_arguments.IsNull());
+
+  Thread* thread = Thread::Current();
+  Zone* zone = thread->zone();
+
+  // Perform any non-covariant bounds checks on the provided function type
+  // arguments to make sure they are appropriate subtypes of the bounds.
+  const intptr_t kNumLocalTypeArgs = NumTypeParameters(thread);
+  if (kNumLocalTypeArgs > 0) {
+    const intptr_t kNumParentTypeArgs = NumParentTypeParameters();
+    ASSERT_EQUAL(kNumLocalTypeArgs + kNumParentTypeArgs,
+                 function_type_arguments.Length());
+    const auto& params = TypeArguments::Handle(zone, type_parameters());
+    const auto& result = Object::Handle(
+        zone, TypeArgumentsAreBoundSubtypes(
+                  zone, token_pos(), params, kNumParentTypeArgs,
+                  instantiator_type_arguments, function_type_arguments));
+    if (result.IsError()) {
+      return result.raw();
+    }
+  } else {
+    ASSERT_EQUAL(NumParentTypeParameters(), function_type_arguments.Length());
+  }
+
+  AbstractType& type = AbstractType::Handle(zone);
   Instance& argument = Instance::Handle(zone);
 
-  // Check types of the provided arguments against the expected parameter types.
-  for (intptr_t i = args_desc.FirstArgIndex(); i < args_desc.PositionalCount();
-       ++i) {
-    argument ^= args.At(i);
-    argument_type = argument.GetType(Heap::kNew);
-    parameter_type = instantiated_func.ParameterTypeAt(i);
-
-    // If the argument type is dynamic or the parameter is null, move on.
-    if (parameter_type.IsDynamicType() || argument_type.IsNullType()) {
-      continue;
+  auto check_argument = [](const Instance& argument, const AbstractType& type,
+                           const TypeArguments& instantiator_type_args,
+                           const TypeArguments& function_type_args) -> bool {
+    // If the argument type is the top type, no need to check.
+    if (type.IsTopTypeForSubtyping()) return true;
+    if (argument.IsNull()) {
+      return Instance::NullIsAssignableTo(type);
     }
-    if (!argument.IsInstanceOf(parameter_type, instantiator_type_args,
-                               Object::null_type_arguments())) {
-      String& argument_name = String::Handle(zone, ParameterNameAt(i));
-      return ThrowTypeError(token_pos(), argument, parameter_type,
-                            argument_name);
+    return argument.IsAssignableTo(type, instantiator_type_args,
+                                   function_type_args);
+  };
+
+  // Check types of the provided arguments against the expected parameter types.
+  const intptr_t arg_offset = args_desc.FirstArgIndex();
+  // Only check explicit arguments.
+  const intptr_t arg_start = arg_offset + NumImplicitParameters();
+  const intptr_t num_positional_args = args_desc.PositionalCount();
+  for (intptr_t arg_index = arg_start; arg_index < num_positional_args;
+       ++arg_index) {
+    argument ^= args.At(arg_index);
+    // Adjust for type arguments when they're present.
+    const intptr_t param_index = arg_index - arg_offset;
+    type = ParameterTypeAt(param_index);
+
+    if (!check_argument(argument, type, instantiator_type_arguments,
+                        function_type_arguments)) {
+      auto& name = String::Handle(zone, ParameterNameAt(param_index));
+      return ThrowTypeError(token_pos(), argument, type, name);
     }
   }
 
-  const intptr_t num_arguments = args_desc.Count();
   const intptr_t num_named_arguments = args_desc.NamedCount();
   if (num_named_arguments == 0) {
     return Error::null();
   }
 
+  const int num_parameters = NumParameters();
+  const int num_fixed_params = num_fixed_parameters();
+
   String& argument_name = String::Handle(zone);
   String& parameter_name = String::Handle(zone);
 
   // Check types of named arguments against expected parameter type.
-  for (intptr_t i = 0; i < num_named_arguments; i++) {
-    argument_name = args_desc.NameAt(i);
+  for (intptr_t named_index = 0; named_index < num_named_arguments;
+       named_index++) {
+    argument_name = args_desc.NameAt(named_index);
     ASSERT(argument_name.IsSymbol());
-    bool found = false;
-    const intptr_t num_positional_args = num_arguments - num_named_arguments;
-    const int num_parameters = NumParameters();
+    argument ^= args.At(args_desc.PositionAt(named_index));
 
     // Try to find the named parameter that matches the provided argument.
-    for (intptr_t j = num_positional_args; !found && (j < num_parameters);
-         j++) {
-      parameter_name = ParameterNameAt(j);
-      ASSERT(argument_name.IsSymbol());
-      if (argument_name.Equals(parameter_name)) {
-        found = true;
-        argument ^= args.At(args_desc.PositionAt(i));
-        argument_type = argument.GetType(Heap::kNew);
-        parameter_type = instantiated_func.ParameterTypeAt(j);
+    // Even when annotated with @required, named parameters are still stored
+    // as if they were optional and so come after the fixed parameters.
+    // Currently O(n^2) as there's no guarantee from either the CFE or the
+    // VM that named parameters and named arguments are sorted in the same way.
+    intptr_t param_index = num_fixed_params;
+    for (; param_index < num_parameters; param_index++) {
+      parameter_name = ParameterNameAt(param_index);
+      ASSERT(parameter_name.IsSymbol());
 
-        // If the argument type is dynamic or the parameter is null, move on.
-        if (parameter_type.IsDynamicType() || argument_type.IsNullType()) {
-          continue;
-        }
-        if (!argument.IsInstanceOf(parameter_type, instantiator_type_args,
-                                   Object::null_type_arguments())) {
-          String& argument_name = String::Handle(zone, ParameterNameAt(i));
-          return ThrowTypeError(token_pos(), argument, parameter_type,
-                                argument_name);
-        }
+      if (!parameter_name.Equals(argument_name)) continue;
+
+      type = ParameterTypeAt(param_index);
+      if (!check_argument(argument, type, instantiator_type_arguments,
+                          function_type_arguments)) {
+        auto& name = String::Handle(zone, ParameterNameAt(param_index));
+        return ThrowTypeError(token_pos(), argument, type, name);
       }
+      break;
     }
-    ASSERT(found);
+    // Only should fail if AreValidArguments returns a false positive.
+    ASSERT(param_index < num_parameters);
   }
   return Error::null();
 }
@@ -8746,7 +9128,15 @@
 ScriptPtr Function::script() const {
   // NOTE(turnidge): If you update this function, you probably want to
   // update Class::PatchFieldsAndFunctions() at the same time.
-  Object& data = Object::Handle(raw_ptr()->data_);
+  const Object& data = Object::Handle(raw_ptr()->data_);
+  if (IsDynamicInvocationForwarder()) {
+    const auto& forwarding_target = Function::Handle(ForwardingTarget());
+    return forwarding_target.script();
+  }
+  if (IsImplicitGetterOrSetter()) {
+    const auto& field = Field::Handle(accessor_field());
+    return field.Script();
+  }
   if (data.IsArray()) {
     Object& script = Object::Handle(Array::Cast(data).At(0));
     if (script.IsScript()) {
@@ -9150,7 +9540,11 @@
   }
 }
 
-bool Function::CheckSourceFingerprint(const char* prefix, int32_t fp) const {
+bool Function::CheckSourceFingerprint(int32_t fp) const {
+#if !defined(DEBUG)
+  return true;  // Only check on debug.
+#endif
+
   if (Isolate::Current()->obfuscate() || FLAG_precompiled_mode ||
       (Dart::vm_snapshot_kind() != Snapshot::kNone)) {
     return true;  // The kernel structure has been altered, skip checking.
@@ -9162,31 +9556,14 @@
     return true;
   }
 
-#if 1
-  // The non-nullable experiment changes the fingerprints, we only track
-  // one fingerprint set, until we unfork and settle on a single snapshot
-  // version this check has to be bypassed.
-  // TODO(36376) - Restore checking fingerprints of recognized methods.
-#else
   if (SourceFingerprint() != fp) {
-    const bool recalculatingFingerprints = false;
-    if (recalculatingFingerprints) {
-      // This output can be copied into a file, then used with sed
-      // to replace the old values.
-      // sed -i.bak -f /tmp/newkeys \
-      //    runtime/vm/compiler/recognized_methods_list.h
-      THR_Print("s/0x%08x/0x%08x/\n", fp, SourceFingerprint());
-    } else {
-      THR_Print(
-          "FP mismatch while recognizing method %s: expecting 0x%08x found "
-          "0x%08x.\nIf the behavior of this function has changed, then changes "
-          "are also needed in the VM's compiler. Otherwise the fingerprint can "
-          "simply be updated in recognized_methods_list.h\n",
-          ToFullyQualifiedCString(), fp, SourceFingerprint());
-      return false;
-    }
+    // This output can be copied into a file, then used with sed
+    // to replace the old values.
+    // sed -i.bak -f /tmp/newkeys \
+    //    runtime/vm/compiler/recognized_methods_list.h
+    THR_Print("s/0x%08x/0x%08x/\n", fp, SourceFingerprint());
+    return false;
   }
-#endif
   return true;
 }
 
@@ -9223,16 +9600,43 @@
   // monomorphic entry).
   //
   // See runtime_entry.cc:DEFINE_RUNTIME_ENTRY(UnlinkedCall)
-  if (HasOptionalParameters() || IsGeneric()) {
+  if (PrologueNeedsArgumentsDescriptor()) {
     return false;
   }
 
+  // All dyn:* forwarders are called via SwitchableCalls and all except the ones
+  // with `PrologueNeedsArgumentsDescriptor()` transition into monomorphic
+  // state.
+  if (Function::IsDynamicInvocationForwarderName(name())) {
+    return true;
+  }
+
   // If table dispatch is disabled, all instance calls use switchable calls.
   if (!(FLAG_precompiled_mode && FLAG_use_bare_instructions &&
         FLAG_use_table_dispatch)) {
     return true;
   }
 
+  // Only if there are dynamic callers and if we didn't create a dyn:* forwarder
+  // for it do we need the monomorphic checked entry.
+  return HasDynamicCallers(zone) &&
+         !kernel::NeedsDynamicInvocationForwarder(*this);
+#else
+  UNREACHABLE();
+  return true;
+#endif
+}
+
+bool Function::HasDynamicCallers(Zone* zone) const {
+#if !defined(DART_PRECOMPILED_RUNTIME)
+  // Issue(dartbug.com/42719):
+  // Right now the metadata of _Closure.call says there are no dynamic callers -
+  // even though there can be. To be conservative we return true.
+  if ((name() == Symbols::GetCall().raw() || name() == Symbols::Call().raw()) &&
+      Class::IsClosureClass(Owner())) {
+    return true;
+  }
+
   // Use the results of TFA to determine whether this function is ever
   // called dynamically, i.e. using switchable calls.
   kernel::ProcedureAttributesMetadata metadata;
@@ -9248,6 +9652,12 @@
 #endif
 }
 
+bool Function::PrologueNeedsArgumentsDescriptor() const {
+  // The prologue of those functions need to examine the arg descriptor for
+  // various purposes.
+  return IsGeneric() || HasOptionalParameters();
+}
+
 bool Function::MayHaveUncheckedEntryPoint() const {
   return FLAG_enable_multiple_entrypoints &&
          (NeedsArgumentTypeChecks() || IsImplicitClosureFunction());
@@ -11138,6 +11548,10 @@
   StorePointer(&raw_ptr()->kernel_data_, data.raw());
 }
 
+void Library::set_loading_unit(const LoadingUnit& value) const {
+  StorePointer(&raw_ptr()->loading_unit_, value.raw());
+}
+
 void Library::SetName(const String& name) const {
   // Only set name once.
   ASSERT(!Loaded());
@@ -12135,6 +12549,7 @@
   StorePointer(&raw_ptr()->resolved_names_, Array::null());
   StorePointer(&raw_ptr()->exported_names_, Array::null());
   StorePointer(&raw_ptr()->loaded_scripts_, Array::null());
+  StorePointer(&raw_ptr()->dependencies_, Array::null());
 }
 
 void Library::AddImport(const Namespace& ns) const {
@@ -12314,15 +12729,18 @@
   // Note "args" is already the internal arguments with the receiver as the
   // first element.
   ArgumentsDescriptor args_descriptor(args_descriptor_array);
-  if (function.IsNull() || !function.AreValidArguments(args_descriptor, NULL) ||
+  if (function.IsNull() ||
+      !function.AreValidArguments(args_descriptor, nullptr) ||
       (respect_reflectable && !function.is_reflectable())) {
     return DartEntry::InvokeNoSuchMethod(receiver, target_name, args,
                                          args_descriptor_array);
   }
-  ObjectPtr type_error = function.DoArgumentTypesMatch(args, args_descriptor,
-                                                       instantiator_type_args);
-  if (type_error != Error::null()) {
-    return type_error;
+  if (!function.CanReceiveDynamicInvocation()) {
+    ObjectPtr type_error = function.DoArgumentTypesMatch(
+        args, args_descriptor, instantiator_type_args);
+    if (type_error != Error::null()) {
+      return type_error;
+    }
   }
   return DartEntry::InvokeFunction(function, args, args_descriptor_array);
 }
@@ -12464,13 +12882,22 @@
                           const Array& arg_names,
                           bool respect_reflectable,
                           bool check_is_entrypoint) const {
-  // TODO(regis): Support invocation of generic functions with type arguments.
-  const int kTypeArgsLen = 0;
+  Thread* thread = Thread::Current();
+  Zone* zone = thread->zone();
 
-  Function& function = Function::Handle();
-  Object& obj = Object::Handle(LookupLocalOrReExportObject(function_name));
-  if (obj.IsFunction()) {
-    function ^= obj.raw();
+  // We don't pass any explicit type arguments, which will be understood as
+  // using dynamic for any function type arguments by lower layers.
+  const int kTypeArgsLen = 0;
+  const Array& args_descriptor_array = Array::Handle(
+      zone, ArgumentsDescriptor::NewBoxed(kTypeArgsLen, args.Length(),
+                                          arg_names, Heap::kNew));
+  ArgumentsDescriptor args_descriptor(args_descriptor_array);
+
+  auto& function = Function::Handle(zone);
+  auto& result =
+      Object::Handle(zone, LookupLocalOrReExportObject(function_name));
+  if (result.IsFunction()) {
+    function ^= result.raw();
   }
 
   if (!function.IsNull() && check_is_entrypoint) {
@@ -12479,45 +12906,43 @@
 
   if (function.IsNull()) {
     // Didn't find a method: try to find a getter and invoke call on its result.
-    const Object& getter_result = Object::Handle(InvokeGetter(
-        function_name, false, respect_reflectable, check_is_entrypoint));
+    const Object& getter_result = Object::Handle(
+        zone, InvokeGetter(function_name, false, respect_reflectable,
+                           check_is_entrypoint));
     if (getter_result.raw() != Object::sentinel().raw()) {
       if (check_is_entrypoint) {
         CHECK_ERROR(EntryPointFieldInvocationError(function_name));
       }
-      // Make room for the closure (receiver) in arguments.
-      intptr_t numArgs = args.Length();
-      const Array& call_args = Array::Handle(Array::New(numArgs + 1));
-      Object& temp = Object::Handle();
-      for (int i = 0; i < numArgs; i++) {
-        temp = args.At(i);
-        call_args.SetAt(i + 1, temp);
-      }
-      call_args.SetAt(0, getter_result);
-      const Array& call_args_descriptor_array =
-          Array::Handle(ArgumentsDescriptor::NewBoxed(
-              kTypeArgsLen, call_args.Length(), arg_names, Heap::kNew));
-      // Call closure.
-      return DartEntry::InvokeClosure(call_args, call_args_descriptor_array);
+      const auto& call_args_descriptor_array = Array::Handle(
+          zone, ArgumentsDescriptor::NewBoxed(args_descriptor.TypeArgsLen(),
+                                              args_descriptor.Count() + 1,
+                                              arg_names, Heap::kNew));
+      const auto& call_args = Array::Handle(
+          zone,
+          CreateCallableArgumentsFromStatic(zone, Instance::Cast(getter_result),
+                                            args, arg_names, args_descriptor));
+      return InvokeCallableWithChecks(zone, call_args,
+                                      call_args_descriptor_array);
     }
   }
 
-  const Array& args_descriptor_array =
-      Array::Handle(ArgumentsDescriptor::NewBoxed(kTypeArgsLen, args.Length(),
-                                                  arg_names, Heap::kNew));
-  ArgumentsDescriptor args_descriptor(args_descriptor_array);
-  const TypeArguments& type_args = Object::null_type_arguments();
-  if (function.IsNull() || !function.AreValidArguments(args_descriptor, NULL) ||
+  if (function.IsNull() ||
+      !function.AreValidArguments(args_descriptor, nullptr) ||
       (respect_reflectable && !function.is_reflectable())) {
     return ThrowNoSuchMethod(
-        AbstractType::Handle(Class::Handle(toplevel_class()).RareType()),
+        AbstractType::Handle(zone,
+                             Class::Handle(zone, toplevel_class()).RareType()),
         function_name, args, arg_names, InvocationMirror::kTopLevel,
         InvocationMirror::kMethod);
   }
-  ObjectPtr type_error =
-      function.DoArgumentTypesMatch(args, args_descriptor, type_args);
-  if (type_error != Error::null()) {
-    return type_error;
+  // This is a static function, so we pass an empty instantiator tav.
+  ASSERT(function.is_static());
+  if (!function.CanReceiveDynamicInvocation()) {
+    ObjectPtr type_error = function.DoArgumentTypesMatch(
+        args, args_descriptor, Object::empty_type_arguments());
+    if (type_error != Error::null()) {
+      return type_error;
+    }
   }
   return DartEntry::InvokeFunction(function, args, args_descriptor_array);
 }
@@ -13505,15 +13930,16 @@
 void Library::CheckFunctionFingerprints() {
   GrowableArray<Library*> all_libs;
   Function& func = Function::Handle();
-  bool has_errors = false;
+  bool fingerprints_match = true;
 
 #define CHECK_FINGERPRINTS(class_name, function_name, dest, fp)                \
   func = GetFunction(all_libs, #class_name, #function_name);                   \
   if (func.IsNull()) {                                                         \
-    has_errors = true;                                                         \
+    fingerprints_match = false;                                                \
     OS::PrintErr("Function not found %s.%s\n", #class_name, #function_name);   \
   } else {                                                                     \
-    CHECK_FINGERPRINT3(func, class_name, function_name, dest, fp);             \
+    fingerprints_match =                                                       \
+        func.CheckSourceFingerprint(fp) && fingerprints_match;                 \
   }
 
 #define CHECK_FINGERPRINTS2(class_name, function_name, dest, fp)               \
@@ -13553,10 +13979,11 @@
 #define CHECK_FACTORY_FINGERPRINTS(symbol, class_name, factory_name, cid, fp)  \
   func = GetFunction(all_libs, #class_name, #factory_name);                    \
   if (func.IsNull()) {                                                         \
-    has_errors = true;                                                         \
+    fingerprints_match = false;                                                \
     OS::PrintErr("Function not found %s.%s\n", #class_name, #factory_name);    \
   } else {                                                                     \
-    CHECK_FINGERPRINT2(func, symbol, cid, fp);                                 \
+    fingerprints_match =                                                       \
+        func.CheckSourceFingerprint(fp) && fingerprints_match;                 \
   }
 
   all_libs.Add(&Library::ZoneHandle(Library::CoreLibrary()));
@@ -13564,8 +13991,12 @@
 
 #undef CHECK_FACTORY_FINGERPRINTS
 
-  if (has_errors) {
-    FATAL("Fingerprint mismatch.");
+  if (!fingerprints_match) {
+    FATAL(
+        "FP mismatch while recognizing methods. If the behavior of "
+        "these functions has changed, then changes are also needed in "
+        "the VM's compiler. Otherwise the fingerprint can simply be "
+        "updated in recognized_methods_list.h\n");
   }
 }
 #endif  // defined(DEBUG) && !defined(DART_PRECOMPILED_RUNTIME).
@@ -17145,6 +17576,71 @@
   return "SubtypeTestCache";
 }
 
+LoadingUnitPtr LoadingUnit::New() {
+  ASSERT(Object::loadingunit_class() != Class::null());
+  LoadingUnit& result = LoadingUnit::Handle();
+  {
+    // LoadingUnit objects are long living objects, allocate them in the
+    // old generation.
+    ObjectPtr raw = Object::Allocate(LoadingUnit::kClassId,
+                                     LoadingUnit::InstanceSize(), Heap::kOld);
+    NoSafepointScope no_safepoint;
+    result ^= raw;
+  }
+  result.set_id(kIllegalId);
+  result.set_loaded(false);
+  result.set_load_outstanding(false);
+  return result.raw();
+}
+
+LoadingUnitPtr LoadingUnit::parent() const {
+  return raw_ptr()->parent_;
+}
+void LoadingUnit::set_parent(const LoadingUnit& value) const {
+  StorePointer(&raw_ptr()->parent_, value.raw());
+}
+
+ArrayPtr LoadingUnit::base_objects() const {
+  return raw_ptr()->base_objects_;
+}
+void LoadingUnit::set_base_objects(const Array& value) const {
+  StorePointer(&raw_ptr()->base_objects_, value.raw());
+}
+
+const char* LoadingUnit::ToCString() const {
+  return "LoadingUnit";
+}
+
+ObjectPtr LoadingUnit::IssueLoad() const {
+  ASSERT(!loaded());
+  ASSERT(!load_outstanding());
+  set_load_outstanding(true);
+  return Isolate::Current()->CallDeferredLoadHandler(id());
+}
+
+void LoadingUnit::CompleteLoad(const String& error_message,
+                               bool transient_error) const {
+  ASSERT(!loaded());
+  ASSERT(load_outstanding());
+  set_loaded(error_message.IsNull());
+  set_load_outstanding(false);
+
+  const Library& lib = Library::Handle(Library::CoreLibrary());
+  const String& sel = String::Handle(String::New("_completeLoads"));
+  const Function& func = Function::Handle(lib.LookupFunctionAllowPrivate(sel));
+  ASSERT(!func.IsNull());
+  const Array& args = Array::Handle(Array::New(3));
+  args.SetAt(0, Smi::Handle(Smi::New(id())));
+  args.SetAt(1, error_message);
+  args.SetAt(2, Bool::Get(transient_error));
+  const Object& result = Object::Handle(DartEntry::InvokeFunction(func, args));
+  if (result.IsUnwindError()) {
+    Thread::Current()->set_sticky_error(Error::Cast(result));
+  } else if (result.IsError()) {
+    UNREACHABLE();
+  }
+}
+
 const char* Error::ToErrorCString() const {
   if (IsNull()) {
     return "Error: null";
@@ -17438,10 +17934,10 @@
 
   Class& klass = Class::Handle(zone, clazz());
   CHECK_ERROR(klass.EnsureIsFinalized(thread));
-  TypeArguments& type_args = TypeArguments::Handle(zone);
-  if (klass.NumTypeArguments() > 0) {
-    type_args = GetTypeArguments();
-  }
+  const auto& inst_type_args =
+      klass.NumTypeArguments() > 0
+          ? TypeArguments::Handle(zone, GetTypeArguments())
+          : Object::null_type_arguments();
 
   const String& internal_getter_name =
       String::Handle(zone, Field::GetterName(getter_name));
@@ -17487,7 +17983,7 @@
 
   return InvokeInstanceFunction(*this, function, internal_getter_name, args,
                                 args_descriptor, respect_reflectable,
-                                type_args);
+                                inst_type_args);
 }
 
 ObjectPtr Instance::InvokeSetter(const String& setter_name,
@@ -17499,10 +17995,10 @@
 
   const Class& klass = Class::Handle(zone, clazz());
   CHECK_ERROR(klass.EnsureIsFinalized(thread));
-  TypeArguments& type_args = TypeArguments::Handle(zone);
-  if (klass.NumTypeArguments() > 0) {
-    type_args = GetTypeArguments();
-  }
+  const auto& inst_type_args =
+      klass.NumTypeArguments() > 0
+          ? TypeArguments::Handle(zone, GetTypeArguments())
+          : Object::null_type_arguments();
 
   const String& internal_setter_name =
       String::Handle(zone, Field::SetterName(setter_name));
@@ -17534,7 +18030,7 @@
 
   return InvokeInstanceFunction(*this, setter, internal_setter_name, args,
                                 args_descriptor, respect_reflectable,
-                                type_args);
+                                inst_type_args);
 }
 
 ObjectPtr Instance::Invoke(const String& function_name,
@@ -17546,6 +18042,7 @@
   Zone* zone = thread->zone();
   Class& klass = Class::Handle(zone, clazz());
   CHECK_ERROR(klass.EnsureIsFinalized(thread));
+
   Function& function = Function::Handle(
       zone, Resolver::ResolveDynamicAnyArgs(zone, klass, function_name));
 
@@ -17553,16 +18050,17 @@
     CHECK_ERROR(function.VerifyCallEntryPoint());
   }
 
-  // TODO(regis): Support invocation of generic functions with type arguments.
+  // We don't pass any explicit type arguments, which will be understood as
+  // using dynamic for any function type arguments by lower layers.
   const int kTypeArgsLen = 0;
   const Array& args_descriptor = Array::Handle(
       zone, ArgumentsDescriptor::NewBoxed(kTypeArgsLen, args.Length(),
                                           arg_names, Heap::kNew));
 
-  TypeArguments& type_args = TypeArguments::Handle(zone);
-  if (klass.NumTypeArguments() > 0) {
-    type_args = GetTypeArguments();
-  }
+  const auto& inst_type_args =
+      klass.NumTypeArguments() > 0
+          ? TypeArguments::Handle(zone, GetTypeArguments())
+          : Object::null_type_arguments();
 
   if (function.IsNull()) {
     // Didn't find a method: try to find a getter and invoke call on its result.
@@ -17584,21 +18082,20 @@
       const Object& getter_result = Object::Handle(
           zone, InvokeInstanceFunction(*this, function, getter_name,
                                        getter_args, getter_args_descriptor,
-                                       respect_reflectable, type_args));
+                                       respect_reflectable, inst_type_args));
       if (getter_result.IsError()) {
         return getter_result.raw();
       }
       // Replace the closure as the receiver in the arguments list.
       args.SetAt(0, getter_result);
-      // Call the closure.
-      return DartEntry::InvokeClosure(args, args_descriptor);
+      return InvokeCallableWithChecks(zone, args, args_descriptor);
     }
   }
 
   // Found an ordinary method.
   return InvokeInstanceFunction(*this, function, function_name, args,
                                 args_descriptor, respect_reflectable,
-                                type_args);
+                                inst_type_args);
 }
 
 ObjectPtr Instance::EvaluateCompiledExpression(
@@ -18453,7 +18950,9 @@
 
 AbstractTypePtr AbstractType::NormalizeFutureOrType(Heap::Space space) const {
   if (IsFutureOrType()) {
-    const AbstractType& unwrapped_type = AbstractType::Handle(UnwrapFutureOr());
+    Zone* zone = Thread::Current()->zone();
+    const AbstractType& unwrapped_type =
+        AbstractType::Handle(zone, UnwrapFutureOr());
     const classid_t cid = unwrapped_type.type_class_id();
     if (cid == kDynamicCid || cid == kVoidCid) {
       return unwrapped_type.raw();
@@ -18471,38 +18970,14 @@
     }
     if (cid == kNeverCid && unwrapped_type.IsNonNullable()) {
       ObjectStore* object_store = Isolate::Current()->object_store();
-      if (object_store->non_nullable_future_never_type() == Type::null()) {
-        const Class& cls = Class::Handle(object_store->future_class());
-        ASSERT(!cls.IsNull());
-        const TypeArguments& type_args =
-            TypeArguments::Handle(TypeArguments::New(1));
-        type_args.SetTypeAt(0, Type::Handle(object_store->never_type()));
-        Type& type =
-            Type::Handle(Type::New(cls, type_args, TokenPosition::kNoSource,
-                                   Nullability::kNonNullable));
-        type.SetIsFinalized();
-        type ^= type.Canonicalize();
-        object_store->set_non_nullable_future_never_type(type);
-      }
       const Type& future_never_type =
-          Type::Handle(object_store->non_nullable_future_never_type());
+          Type::Handle(zone, object_store->non_nullable_future_never_type());
+      ASSERT(!future_never_type.IsNull());
       return future_never_type.ToNullability(nullability(), space);
     }
     if (cid == kNullCid) {
       ObjectStore* object_store = Isolate::Current()->object_store();
-      if (object_store->nullable_future_null_type() == Type::null()) {
-        const Class& cls = Class::Handle(object_store->future_class());
-        ASSERT(!cls.IsNull());
-        const TypeArguments& type_args =
-            TypeArguments::Handle(TypeArguments::New(1));
-        Type& type = Type::Handle(object_store->null_type());
-        type_args.SetTypeAt(0, type);
-        type = Type::New(cls, type_args, TokenPosition::kNoSource,
-                         Nullability::kNullable);
-        type.SetIsFinalized();
-        type ^= type.Canonicalize();
-        object_store->set_nullable_future_null_type(type);
-      }
+      ASSERT(object_store->nullable_future_null_type() != Type::null());
       return object_store->nullable_future_null_type();
     }
     if (IsNullable() && unwrapped_type.IsNullable()) {
@@ -21252,22 +21727,6 @@
   return HashImpl(characters, len);
 }
 
-uint16_t String::CharAt(intptr_t index) const {
-  intptr_t class_id = raw()->GetClassId();
-  ASSERT(IsStringClassId(class_id));
-  if (class_id == kOneByteStringCid) {
-    return OneByteString::CharAt(*this, index);
-  }
-  if (class_id == kTwoByteStringCid) {
-    return TwoByteString::CharAt(*this, index);
-  }
-  if (class_id == kExternalOneByteStringCid) {
-    return ExternalOneByteString::CharAt(*this, index);
-  }
-  ASSERT(class_id == kExternalTwoByteStringCid);
-  return ExternalTwoByteString::CharAt(*this, index);
-}
-
 intptr_t String::CharSize() const {
   intptr_t class_id = raw()->GetClassId();
   if (class_id == kOneByteStringCid || class_id == kExternalOneByteStringCid) {
@@ -21413,13 +21872,15 @@
   return 0;
 }
 
-bool String::StartsWith(const String& other) const {
-  if (other.IsNull() || (other.Length() > this->Length())) {
-    return false;
-  }
-  intptr_t slen = other.Length();
-  for (int i = 0; i < slen; i++) {
-    if (this->CharAt(i) != other.CharAt(i)) {
+bool String::StartsWith(StringPtr str, StringPtr prefix) {
+  if (prefix == String::null()) return false;
+
+  const intptr_t length = String::LengthOf(str);
+  const intptr_t prefix_length = String::LengthOf(prefix);
+  if (prefix_length > length) return false;
+
+  for (intptr_t i = 0; i < prefix_length; i++) {
+    if (String::CharAt(str, i) != String::CharAt(prefix, i)) {
       return false;
     }
   }
@@ -23624,6 +24085,16 @@
   return "TransferableTypedData";
 }
 
+intptr_t Closure::NumTypeParameters(Thread* thread) const {
+  if (delayed_type_arguments() != Object::null_type_arguments().raw() &&
+      delayed_type_arguments() != Object::empty_type_arguments().raw()) {
+    return 0;
+  } else {
+    const auto& closure_function = Function::Handle(thread->zone(), function());
+    return closure_function.NumTypeParameters(thread);
+  }
+}
+
 const char* Closure::ToCString() const {
   Zone* zone = Thread::Current()->zone();
   const Function& fun = Function::Handle(zone, function());
diff --git a/runtime/vm/object.h b/runtime/vm/object.h
index ccb84d4..cd5126d 100644
--- a/runtime/vm/object.h
+++ b/runtime/vm/object.h
@@ -9,6 +9,7 @@
 #error "Should not include runtime"
 #endif
 
+#include <limits>
 #include <tuple>
 
 #include "include/dart_api.h"
@@ -516,6 +517,7 @@
   static ClassPtr icdata_class() { return icdata_class_; }
   static ClassPtr megamorphic_cache_class() { return megamorphic_cache_class_; }
   static ClassPtr subtypetestcache_class() { return subtypetestcache_class_; }
+  static ClassPtr loadingunit_class() { return loadingunit_class_; }
   static ClassPtr weak_serialization_reference_class() {
     return weak_serialization_reference_class_;
   }
@@ -808,6 +810,7 @@
   static ClassPtr icdata_class_;             // Class of ICData.
   static ClassPtr megamorphic_cache_class_;  // Class of MegamorphiCache.
   static ClassPtr subtypetestcache_class_;   // Class of SubtypeTestCache.
+  static ClassPtr loadingunit_class_;        // Class of LoadingUnit.
   static ClassPtr api_error_class_;          // Class of ApiError.
   static ClassPtr language_error_class_;     // Class of LanguageError.
   static ClassPtr unhandled_exception_class_;  // Class of UnhandledException.
@@ -906,8 +909,7 @@
 };
 
 // The NNBDMode reflects the opted-in status of libraries.
-// Note that the weak or strong testing mode is not reflected in NNBDMode, but
-// imposed globally by the value of --null-safety.
+// Note that the weak or strong checking mode is not reflected in NNBDMode.
 enum class NNBDMode {
   // Status of the library:
   kLegacyLib = 0,   // Library is legacy.
@@ -1021,7 +1023,7 @@
   }
   intptr_t id() const { return raw_ptr()->id_; }
   void set_id(intptr_t value) const {
-    ASSERT(is_valid_id(value));
+    ASSERT(value >= 0 && value < std::numeric_limits<classid_t>::max());
     StoreNonPointer(&raw_ptr()->id_, value);
   }
   static intptr_t id_offset() { return OFFSET_OF(ClassLayout, id_); }
@@ -1359,9 +1361,6 @@
   }
   void set_is_type_finalized() const;
 
-  bool is_patch() const { return PatchBit::decode(raw_ptr()->state_bits_); }
-  void set_is_patch() const;
-
   bool is_synthesized_class() const {
     return SynthesizedClassBit::decode(raw_ptr()->state_bits_);
   }
@@ -1372,10 +1371,18 @@
 
   bool is_finalized() const {
     return ClassFinalizedBits::decode(raw_ptr()->state_bits_) ==
-           ClassLayout::kFinalized;
+               ClassLayout::kFinalized ||
+           ClassFinalizedBits::decode(raw_ptr()->state_bits_) ==
+               ClassLayout::kAllocateFinalized;
   }
   void set_is_finalized() const;
 
+  bool is_allocate_finalized() const {
+    return ClassFinalizedBits::decode(raw_ptr()->state_bits_) ==
+           ClassLayout::kAllocateFinalized;
+  }
+  void set_is_allocate_finalized() const;
+
   bool is_prefinalized() const {
     return ClassFinalizedBits::decode(raw_ptr()->state_bits_) ==
            ClassLayout::kPreFinalized;
@@ -1529,6 +1536,7 @@
   void EnsureDeclarationLoaded() const;
 
   ErrorPtr EnsureIsFinalized(Thread* thread) const;
+  ErrorPtr EnsureIsAllocateFinalized(Thread* thread) const;
 
   // Allocate a class used for VM internal objects.
   template <class FakeObject, class TargetFakeObject>
@@ -1666,7 +1674,6 @@
     kClassLoadingPos = kClassFinalizedPos + kClassFinalizedSize,  // = 4
     kClassLoadingSize = 2,
     kAbstractBit = kClassLoadingPos + kClassLoadingSize,  // = 6
-    kPatchBit,
     kSynthesizedClassBit,
     kMixinAppAliasBit,
     kMixinTypeAppliedBit,
@@ -1688,7 +1695,6 @@
                                            kClassLoadingPos,
                                            kClassLoadingSize> {};
   class AbstractBit : public BitField<uint32_t, bool, kAbstractBit, 1> {};
-  class PatchBit : public BitField<uint32_t, bool, kPatchBit, 1> {};
   class SynthesizedClassBit
       : public BitField<uint32_t, bool, kSynthesizedClassBit, 1> {};
   class FieldsMarkedNullableBit
@@ -1767,6 +1773,7 @@
   friend class InterpreterHelpers;
   friend class Intrinsifier;
   friend class ProgramWalker;
+  friend class Precompiler;
 };
 
 // Classification of type genericity according to type parameter owners.
@@ -2749,6 +2756,10 @@
   void set_accessor_field(const Field& value) const;
   FieldPtr accessor_field() const;
 
+  bool IsRegularFunction() const {
+    return kind() == FunctionLayout::kRegularFunction;
+  }
+
   bool IsMethodExtractor() const {
     return kind() == FunctionLayout::kMethodExtractor;
   }
@@ -2824,10 +2835,15 @@
     return (kind() == FunctionLayout::kConstructor) && is_static();
   }
 
+  static bool ClosureBodiesContainNonCovariantChecks() {
+    return FLAG_precompiled_mode || FLAG_lazy_dispatchers;
+  }
+
   // Whether this function can receive an invocation where the number and names
   // of arguments have not been checked.
   bool CanReceiveDynamicInvocation() const {
-    return IsClosureFunction() || IsFfiTrampoline();
+    return (IsClosureFunction() && ClosureBodiesContainNonCovariantChecks()) ||
+           IsFfiTrampoline();
   }
 
   bool HasThisParameter() const {
@@ -2894,11 +2910,13 @@
   bool IsInFactoryScope() const;
 
   bool NeedsArgumentTypeChecks() const {
-    return IsClosureFunction() ||
+    return (IsClosureFunction() && ClosureBodiesContainNonCovariantChecks()) ||
            !(is_static() || (kind() == FunctionLayout::kConstructor));
   }
 
   bool NeedsMonomorphicCheckedEntry(Zone* zone) const;
+  bool HasDynamicCallers(Zone* zone) const;
+  bool PrologueNeedsArgumentsDescriptor() const;
 
   bool MayHaveUncheckedEntryPoint() const;
 
@@ -3118,12 +3136,52 @@
                               String* error_message) const;
 
   // Returns a TypeError if the provided arguments don't match the function
-  // parameter types, NULL otherwise. Assumes AreValidArguments is called first.
+  // parameter types, null otherwise. Assumes AreValidArguments is called first.
+  //
+  // If the function has a non-null receiver in the arguments, the instantiator
+  // type arguments are retrieved from the receiver, otherwise the null type
+  // arguments vector is used.
+  //
+  // If the function is generic, the appropriate function type arguments are
+  // retrieved either from the arguments array or the receiver (if a closure).
+  // If no function type arguments are available in either location, the bounds
+  // of the function type parameters are instantiated and used as the function
+  // type arguments.
+  //
+  // The local function type arguments (_not_ parent function type arguments)
+  // are also checked against the bounds of the corresponding parameters to
+  // ensure they are appropriate subtypes if the function is generic.
+  ObjectPtr DoArgumentTypesMatch(const Array& args,
+                                 const ArgumentsDescriptor& arg_names) const;
+
+  // Returns a TypeError if the provided arguments don't match the function
+  // parameter types, null otherwise. Assumes AreValidArguments is called first.
+  //
+  // If the function is generic, the appropriate function type arguments are
+  // retrieved either from the arguments array or the receiver (if a closure).
+  // If no function type arguments are available in either location, the bounds
+  // of the function type parameters are instantiated and used as the function
+  // type arguments.
+  //
+  // The local function type arguments (_not_ parent function type arguments)
+  // are also checked against the bounds of the corresponding parameters to
+  // ensure they are appropriate subtypes if the function is generic.
   ObjectPtr DoArgumentTypesMatch(
       const Array& args,
       const ArgumentsDescriptor& arg_names,
       const TypeArguments& instantiator_type_args) const;
 
+  // Returns a TypeError if the provided arguments don't match the function
+  // parameter types, null otherwise. Assumes AreValidArguments is called first.
+  //
+  // The local function type arguments (_not_ parent function type arguments)
+  // are also checked against the bounds of the corresponding parameters to
+  // ensure they are appropriate subtypes if the function is generic.
+  ObjectPtr DoArgumentTypesMatch(const Array& args,
+                                 const ArgumentsDescriptor& arg_names,
+                                 const TypeArguments& instantiator_type_args,
+                                 const TypeArguments& function_type_args) const;
+
   // Returns true if the type argument count, total argument count and the names
   // of optional arguments are valid for calling this function.
   // Otherwise, it returns false and the reason (if error_message is not NULL).
@@ -3254,6 +3312,15 @@
 #endif  //  !defined(DART_PRECOMPILED_RUNTIME)
   }
 
+#if !defined(DART_PRECOMPILED_RUNTIME)
+  bool HasUnboxedParameters() const {
+    return raw_ptr()->unboxed_parameters_info_.HasUnboxedParameters();
+  }
+  bool HasUnboxedReturnValue() const {
+    return raw_ptr()->unboxed_parameters_info_.HasUnboxedReturnValue();
+  }
+#endif  //  !defined(DART_PRECOMPILED_RUNTIME)
+
   // Returns true if the type of this function is a subtype of the type of
   // the other function.
   bool IsSubtypeOf(const Function& other, Heap::Space space) const;
@@ -3282,6 +3349,12 @@
     return kind() == FunctionLayout::kImplicitGetter;
   }
 
+  // Returns true if this function represents an implicit static getter
+  // function.
+  bool IsImplicitStaticGetterFunction() const {
+    return kind() == FunctionLayout::kImplicitStaticGetter;
+  }
+
   // Returns true if this function represents an explicit setter function.
   bool IsSetterFunction() const {
     return kind() == FunctionLayout::kSetterFunction;
@@ -3501,12 +3574,13 @@
   FunctionPtr GetMethodExtractor(const String& getter_name) const;
 
   static bool IsDynamicInvocationForwarderName(const String& name);
+  static bool IsDynamicInvocationForwarderName(StringPtr name);
 
   static StringPtr DemangleDynamicInvocationForwarderName(const String& name);
 
-#if !defined(DART_PRECOMPILED_RUNTIME)
   static StringPtr CreateDynamicInvocationForwarderName(const String& name);
 
+#if !defined(DART_PRECOMPILED_RUNTIME)
   FunctionPtr CreateDynamicInvocationForwarder(
       const String& mangled_name) const;
 
@@ -3519,7 +3593,7 @@
   int32_t SourceFingerprint() const;
 
   // Return false and report an error if the fingerprint does not match.
-  bool CheckSourceFingerprint(const char* prefix, int32_t fp) const;
+  bool CheckSourceFingerprint(int32_t fp) const;
 
   // Works with map [deopt-id] -> ICData.
   void SaveICDataMap(
@@ -4611,6 +4685,9 @@
   }
   void SetLoaded() const;
 
+  LoadingUnitPtr loading_unit() const { return raw_ptr()->loading_unit_; }
+  void set_loading_unit(const LoadingUnit& value) const;
+
   static intptr_t InstanceSize() {
     return RoundedAllocationSize(sizeof(LibraryLayout));
   }
@@ -4800,6 +4877,8 @@
 
   intptr_t index() const { return raw_ptr()->index_; }
   void set_index(intptr_t value) const {
+    ASSERT(value == -1 ||
+           value >= 0 && value < std::numeric_limits<classid_t>::max());
     StoreNonPointer(&raw_ptr()->index_, value);
   }
 
@@ -5208,14 +5287,17 @@
   };
 
   EntryType TypeAt(intptr_t index) const {
+    ASSERT((index >= 0) && (index <= Length()));
     return TypeBits::decode(raw_ptr()->entry_bits()[index]);
   }
 
   Patchability PatchableAt(intptr_t index) const {
+    ASSERT((index >= 0) && (index <= Length()));
     return PatchableBit::decode(raw_ptr()->entry_bits()[index]);
   }
 
   void SetTypeAt(intptr_t index, EntryType type, Patchability patchable) const {
+    ASSERT(index >= 0 && index <= Length());
     const uint8_t bits =
         PatchableBit::encode(patchable) | TypeBits::encode(type);
     StoreNonPointer(&raw_ptr()->entry_bits()[index], bits);
@@ -5275,8 +5357,13 @@
   static intptr_t IndexFromOffset(intptr_t offset) {
     ASSERT(
         Utils::IsAligned(offset + kHeapObjectTag, compiler::target::kWordSize));
-    return (offset + kHeapObjectTag - data_offset()) /
-           sizeof(ObjectPoolLayout::Entry);
+#if defined(DART_PRECOMPILER)
+    return (offset + kHeapObjectTag -
+            compiler::target::ObjectPool::element_offset(0)) /
+           compiler::target::kWordSize;
+#else
+    return (offset + kHeapObjectTag - element_offset(0)) / kWordSize;
+#endif
   }
 
   static intptr_t OffsetFromIndex(intptr_t index) {
@@ -5406,6 +5493,10 @@
     return memcmp(a->ptr(), b->ptr(), InstanceSize(Size(a))) == 0;
   }
 
+  uint32_t Hash() const {
+    return HashBytes(reinterpret_cast<const uint8_t*>(PayloadStart()), Size());
+  }
+
   CodeStatistics* stats() const;
   void set_stats(CodeStatistics* stats) const;
 
@@ -6713,6 +6804,7 @@
   static const intptr_t kAwaitJumpVarIndex = 0;
   static const intptr_t kAsyncCompleterIndex = 1;
   static const intptr_t kControllerIndex = 1;
+  static const intptr_t kChainedFutureIndex = 2;
 
   static intptr_t variable_offset(intptr_t context_index) {
     return OFFSET_OF_RETURNED_VALUE(ContextLayout, data) +
@@ -6970,6 +7062,48 @@
   friend class Deserializer;
 };
 
+class LoadingUnit : public Object {
+ public:
+  static constexpr intptr_t kIllegalId = 0;
+  COMPILE_ASSERT(kIllegalId == WeakTable::kNoValue);
+  static constexpr intptr_t kRootId = 1;
+
+  static LoadingUnitPtr New();
+
+  static intptr_t InstanceSize() {
+    return RoundedAllocationSize(sizeof(LoadingUnitLayout));
+  }
+
+  LoadingUnitPtr parent() const;
+  void set_parent(const LoadingUnit& value) const;
+
+  ArrayPtr base_objects() const;
+  void set_base_objects(const Array& value) const;
+
+  intptr_t id() const { return raw_ptr()->id_; }
+  void set_id(intptr_t id) const { StoreNonPointer(&raw_ptr()->id_, id); }
+
+  // True once the VM deserializes this unit's snapshot.
+  bool loaded() const { return raw_ptr()->loaded_; }
+  void set_loaded(bool value) const {
+    StoreNonPointer(&raw_ptr()->loaded_, value);
+  }
+
+  // True once the VM invokes the embedder's deferred load callback until the
+  // embedder calls Dart_DeferredLoadComplete[Error].
+  bool load_outstanding() const { return raw_ptr()->load_outstanding_; }
+  void set_load_outstanding(bool value) const {
+    StoreNonPointer(&raw_ptr()->load_outstanding_, value);
+  }
+
+  ObjectPtr IssueLoad() const;
+  void CompleteLoad(const String& error_message, bool transient_error) const;
+
+ private:
+  FINAL_HEAP_OBJECT_IMPLEMENTATION(LoadingUnit, Object);
+  friend class Class;
+};
+
 class Error : public Object {
  public:
   virtual const char* ToErrorCString() const;
@@ -8569,7 +8703,10 @@
     DISALLOW_IMPLICIT_CONSTRUCTORS(CodePointIterator);
   };
 
-  intptr_t Length() const { return Smi::Value(raw_ptr()->length_); }
+  intptr_t Length() const { return LengthOf(raw()); }
+  static intptr_t LengthOf(StringPtr obj) {
+    return Smi::Value(obj->ptr()->length_);
+  }
   static intptr_t length_offset() { return OFFSET_OF(StringLayout, length_); }
 
   intptr_t Hash() const {
@@ -8606,7 +8743,8 @@
 
   virtual ObjectPtr HashCode() const { return Integer::New(Hash()); }
 
-  uint16_t CharAt(intptr_t index) const;
+  uint16_t CharAt(intptr_t index) const { return CharAt(raw(), index); }
+  static uint16_t CharAt(StringPtr str, intptr_t index);
 
   intptr_t CharSize() const;
 
@@ -8644,7 +8782,11 @@
 
   intptr_t CompareTo(const String& other) const;
 
-  bool StartsWith(const String& other) const;
+  bool StartsWith(const String& other) const {
+    NoSafepointScope no_safepoint;
+    return StartsWith(raw(), other.raw());
+  }
+  static bool StartsWith(StringPtr str, StringPtr prefix);
   bool EndsWith(const String& other) const;
 
   // Strings are canonicalized using the symbol table.
@@ -8857,9 +8999,15 @@
 class OneByteString : public AllStatic {
  public:
   static uint16_t CharAt(const String& str, intptr_t index) {
-    ASSERT((index >= 0) && (index < str.Length()));
     ASSERT(str.IsOneByteString());
-    return raw_ptr(str)->data()[index];
+    NoSafepointScope no_safepoint;
+    return OneByteString::CharAt(static_cast<OneByteStringPtr>(str.raw()),
+                                 index);
+  }
+
+  static uint16_t CharAt(OneByteStringPtr str, intptr_t index) {
+    ASSERT(index >= 0 && index < String::LengthOf(str));
+    return str->ptr()->data()[index];
   }
 
   static void SetCharAt(const String& str, intptr_t index, uint8_t code_unit) {
@@ -8950,11 +9098,6 @@
                                              intptr_t length,
                                              Heap::Space space);
 
-  static void SetPeer(const String& str,
-                      void* peer,
-                      intptr_t external_allocation_size,
-                      Dart_WeakPersistentHandleFinalizer callback);
-
   static const ClassId kClassId = kOneByteStringCid;
 
   static OneByteStringPtr null() {
@@ -8999,9 +9142,15 @@
 class TwoByteString : public AllStatic {
  public:
   static uint16_t CharAt(const String& str, intptr_t index) {
-    ASSERT((index >= 0) && (index < str.Length()));
     ASSERT(str.IsTwoByteString());
-    return raw_ptr(str)->data()[index];
+    NoSafepointScope no_safepoint;
+    return TwoByteString::CharAt(static_cast<TwoByteStringPtr>(str.raw()),
+                                 index);
+  }
+
+  static uint16_t CharAt(TwoByteStringPtr str, intptr_t index) {
+    ASSERT(index >= 0 && index < String::LengthOf(str));
+    return str->ptr()->data()[index];
   }
 
   static void SetCharAt(const String& str, intptr_t index, uint16_t ch) {
@@ -9073,11 +9222,6 @@
                                     const String& str,
                                     Heap::Space space);
 
-  static void SetPeer(const String& str,
-                      void* peer,
-                      intptr_t external_allocation_size,
-                      Dart_WeakPersistentHandleFinalizer callback);
-
   static TwoByteStringPtr null() {
     return static_cast<TwoByteStringPtr>(Object::null());
   }
@@ -9121,8 +9265,15 @@
 class ExternalOneByteString : public AllStatic {
  public:
   static uint16_t CharAt(const String& str, intptr_t index) {
+    ASSERT(str.IsExternalOneByteString());
     NoSafepointScope no_safepoint;
-    return *CharAddr(str, index);
+    return ExternalOneByteString::CharAt(
+        static_cast<ExternalOneByteStringPtr>(str.raw()), index);
+  }
+
+  static uint16_t CharAt(ExternalOneByteStringPtr str, intptr_t index) {
+    ASSERT(index >= 0 && index < String::LengthOf(str));
+    return str->ptr()->external_data_[index];
   }
 
   static void* GetPeer(const String& str) { return raw_ptr(str)->peer_; }
@@ -9212,8 +9363,15 @@
 class ExternalTwoByteString : public AllStatic {
  public:
   static uint16_t CharAt(const String& str, intptr_t index) {
+    ASSERT(str.IsExternalTwoByteString());
     NoSafepointScope no_safepoint;
-    return *CharAddr(str, index);
+    return ExternalTwoByteString::CharAt(
+        static_cast<ExternalTwoByteStringPtr>(str.raw()), index);
+  }
+
+  static uint16_t CharAt(ExternalTwoByteStringPtr str, intptr_t index) {
+    ASSERT(index >= 0 && index < String::LengthOf(str));
+    return str->ptr()->external_data_[index];
   }
 
   static void* GetPeer(const String& str) { return raw_ptr(str)->peer_; }
@@ -10401,6 +10559,11 @@
     return OFFSET_OF(ClosureLayout, context_);
   }
 
+  bool IsGeneric(Thread* thread) const { return NumTypeParameters(thread) > 0; }
+  intptr_t NumTypeParameters(Thread* thread) const;
+  // No need for NumParentTypeParameters, as a closure is always closed over
+  // its parents type parameters (i.e., function_type_parameters() above).
+
   SmiPtr hash() const { return raw_ptr()->hash_; }
   static intptr_t hash_offset() { return OFFSET_OF(ClosureLayout, hash_); }
 
@@ -11164,6 +11327,23 @@
   StoreSmi(&raw_ptr()->hash_, Smi::New(value));
 }
 
+inline uint16_t String::CharAt(StringPtr str, intptr_t index) {
+  switch (str->GetClassId()) {
+    case kOneByteStringCid:
+      return OneByteString::CharAt(static_cast<OneByteStringPtr>(str), index);
+    case kTwoByteStringCid:
+      return TwoByteString::CharAt(static_cast<TwoByteStringPtr>(str), index);
+    case kExternalOneByteStringCid:
+      return ExternalOneByteString::CharAt(
+          static_cast<ExternalOneByteStringPtr>(str), index);
+    case kExternalTwoByteStringCid:
+      return ExternalTwoByteString::CharAt(
+          static_cast<ExternalTwoByteStringPtr>(str), index);
+  }
+  UNREACHABLE();
+  return 0;
+}
+
 // A view on an [Array] as a list of tuples, optionally starting at an offset.
 //
 // Example: We store a list of (kind, function, code) tuples into the
diff --git a/runtime/vm/object_service.cc b/runtime/vm/object_service.cc
index 2e4bc9b..3231fda 100644
--- a/runtime/vm/object_service.cc
+++ b/runtime/vm/object_service.cc
@@ -96,7 +96,7 @@
   jsobj.AddProperty("const", is_const());
   jsobj.AddProperty("_finalized", is_finalized());
   jsobj.AddProperty("_implemented", is_implemented());
-  jsobj.AddProperty("_patch", is_patch());
+  jsobj.AddProperty("_patch", false);
   jsobj.AddProperty("_traceAllocations", TraceAllocation(isolate));
 
   const Class& superClass = Class::Handle(SuperClass());
@@ -1030,6 +1030,20 @@
   jsobj.AddProperty("_cache", Array::Handle(cache()));
 }
 
+void LoadingUnit::PrintJSONImpl(JSONStream* stream, bool ref) const {
+  JSONObject jsobj(stream);
+  AddCommonObjectProperties(&jsobj, "Object", ref);
+  jsobj.AddServiceId(*this);
+  if (ref) {
+    return;
+  }
+  jsobj.AddProperty("_parent", LoadingUnit::Handle(parent()));
+  jsobj.AddProperty("_baseObjects", Array::Handle(base_objects()));
+  jsobj.AddProperty("_id", static_cast<intptr_t>(id()));
+  jsobj.AddProperty("_loaded", loaded());
+  jsobj.AddProperty("_loadOutstanding", load_outstanding());
+}
+
 void Error::PrintJSONImpl(JSONStream* stream, bool ref) const {
   UNREACHABLE();
 }
diff --git a/runtime/vm/object_store.cc b/runtime/vm/object_store.cc
index c14a52a..9683d81 100644
--- a/runtime/vm/object_store.cc
+++ b/runtime/vm/object_store.cc
@@ -103,7 +103,7 @@
 
 ObjectStore::ObjectStore() {
 #define INIT_FIELD(Type, name) name##_ = Type::null();
-  OBJECT_STORE_FIELD_LIST(INIT_FIELD, INIT_FIELD)
+  OBJECT_STORE_FIELD_LIST(INIT_FIELD, INIT_FIELD, INIT_FIELD, INIT_FIELD)
 #undef INIT_FIELD
 
   for (ObjectPtr* current = from(); current <= to(); current++) {
@@ -136,7 +136,8 @@
 #define PRINT_OBJECT_STORE_FIELD(type, name)                                   \
   value = name##_;                                                             \
   fields.AddProperty(#name "_", value);
-    OBJECT_STORE_FIELD_LIST(PRINT_OBJECT_STORE_FIELD, PRINT_OBJECT_STORE_FIELD);
+    OBJECT_STORE_FIELD_LIST(PRINT_OBJECT_STORE_FIELD, PRINT_OBJECT_STORE_FIELD,
+                            PRINT_OBJECT_STORE_FIELD, PRINT_OBJECT_STORE_FIELD);
 #undef PRINT_OBJECT_STORE_FIELD
   }
 }
@@ -333,4 +334,60 @@
 #endif
 }
 
+void ObjectStore::LazyInitCoreTypes() {
+  if (non_nullable_list_rare_type_ == Type::null()) {
+    ASSERT(non_nullable_map_rare_type_ == Type::null());
+    Thread* thread = Thread::Current();
+    Zone* zone = thread->zone();
+    const Library& core_lib = Library::Handle(zone, Library::CoreLibrary());
+    Class& cls = Class::Handle(zone, core_lib.LookupClass(Symbols::List()));
+    ASSERT(!cls.IsNull());
+    Type& type = Type::Handle(zone);
+    type ^= cls.RareType();
+    set_non_nullable_list_rare_type(type);
+    cls = core_lib.LookupClass(Symbols::Map());
+    ASSERT(!cls.IsNull());
+    type ^= cls.RareType();
+    set_non_nullable_map_rare_type(type);
+  }
+}
+
+void ObjectStore::LazyInitFutureTypes() {
+  if (non_nullable_future_rare_type_ == Type::null()) {
+    ASSERT(non_nullable_future_never_type_ == Type::null() &&
+           nullable_future_null_type_ == Type::null());
+    Thread* thread = Thread::Current();
+    Zone* zone = thread->zone();
+    Class& cls = Class::Handle(zone, future_class());
+    if (cls.IsNull()) {
+      const Library& async_lib = Library::Handle(zone, async_library());
+      ASSERT(!async_lib.IsNull());
+      cls = async_lib.LookupClass(Symbols::Future());
+      ASSERT(!cls.IsNull());
+    }
+    TypeArguments& type_args = TypeArguments::Handle(zone);
+    Type& type = Type::Handle(zone);
+    type = never_type();
+    ASSERT(!type.IsNull());
+    type_args = TypeArguments::New(1);
+    type_args.SetTypeAt(0, type);
+    type = Type::New(cls, type_args, TokenPosition::kNoSource,
+                     Nullability::kNonNullable);
+    type.SetIsFinalized();
+    type ^= type.Canonicalize();
+    set_non_nullable_future_never_type(type);
+    type = null_type();
+    ASSERT(!type.IsNull());
+    type_args = TypeArguments::New(1);
+    type_args.SetTypeAt(0, type);
+    type = Type::New(cls, type_args, TokenPosition::kNoSource,
+                     Nullability::kNullable);
+    type.SetIsFinalized();
+    type ^= type.Canonicalize();
+    set_nullable_future_null_type(type);
+    type ^= cls.RareType();
+    set_non_nullable_future_rare_type(type);
+  }
+}
+
 }  // namespace dart
diff --git a/runtime/vm/object_store.h b/runtime/vm/object_store.h
index 4b28057..5d7a535 100644
--- a/runtime/vm/object_store.h
+++ b/runtime/vm/object_store.h
@@ -37,7 +37,9 @@
 //
 // R_ - needs getter only
 // RW - needs getter and setter
-#define OBJECT_STORE_FIELD_LIST(R_, RW)                                        \
+// CW - needs lazy Core init getter and setter
+// FW - needs lazy Future init getter and setter
+#define OBJECT_STORE_FIELD_LIST(R_, RW, CW, FW)                                \
   RW(Class, object_class)                                                      \
   RW(Type, object_type)                                                        \
   RW(Type, legacy_object_type)                                                 \
@@ -80,9 +82,11 @@
   RW(Type, string_type)                                                        \
   RW(Type, legacy_string_type)                                                 \
   RW(Type, non_nullable_string_type)                                           \
-  RW(Type, non_nullable_list_rare_type)   /* maybe be null, lazily built */    \
-  RW(Type, non_nullable_map_rare_type)    /* maybe be null, lazily built */    \
-  RW(Type, non_nullable_future_rare_type) /* maybe be null, lazily built */    \
+  CW(Type, non_nullable_list_rare_type)    /* maybe be null, lazily built */   \
+  CW(Type, non_nullable_map_rare_type)     /* maybe be null, lazily built */   \
+  FW(Type, non_nullable_future_rare_type)  /* maybe be null, lazily built */   \
+  FW(Type, non_nullable_future_never_type) /* maybe be null, lazily built */   \
+  FW(Type, nullable_future_null_type)      /* maybe be null, lazily built */   \
   RW(TypeArguments, type_argument_int)                                         \
   RW(TypeArguments, type_argument_legacy_int)                                  \
   RW(TypeArguments, type_argument_non_nullable_int)                            \
@@ -103,8 +107,6 @@
   RW(Field, pragma_name)                                                       \
   RW(Field, pragma_options)                                                    \
   RW(Class, future_class)                                                      \
-  RW(Type, non_nullable_future_never_type) /* maybe be null, lazily built */   \
-  RW(Type, nullable_future_null_type)      /* maybe be null, lazily built */   \
   RW(Class, completer_class)                                                   \
   RW(Class, symbol_class)                                                      \
   RW(Class, one_byte_string_class)                                             \
@@ -151,6 +153,7 @@
   RW(Library, wasm_library)                                                    \
   RW(GrowableObjectArray, libraries)                                           \
   RW(Array, libraries_map)                                                     \
+  RW(Array, loading_units)                                                     \
   RW(GrowableObjectArray, closure_functions)                                   \
   RW(GrowableObjectArray, pending_classes)                                     \
   RW(Instance, stack_overflow)                                                 \
@@ -353,9 +356,29 @@
 #define DECLARE_GETTER_AND_SETTER(Type, name)                                  \
   DECLARE_GETTER(Type, name)                                                   \
   void set_##name(const Type& value) { name##_ = value.raw(); }
-  OBJECT_STORE_FIELD_LIST(DECLARE_GETTER, DECLARE_GETTER_AND_SETTER)
+#define DECLARE_LAZY_INIT_GETTER(Type, name, init)                             \
+  Type##Ptr name() {                                                           \
+    if (name##_ == Type::null()) {                                             \
+      init();                                                                  \
+    }                                                                          \
+    return name##_;                                                            \
+  }                                                                            \
+  static intptr_t name##_offset() { return OFFSET_OF(ObjectStore, name##_); }
+#define DECLARE_LAZY_INIT_CORE_GETTER_AND_SETTER(Type, name)                   \
+  DECLARE_LAZY_INIT_GETTER(Type, name, LazyInitCoreTypes)                      \
+  void set_##name(const Type& value) { name##_ = value.raw(); }
+#define DECLARE_LAZY_INIT_FUTURE_GETTER_AND_SETTER(Type, name)                 \
+  DECLARE_LAZY_INIT_GETTER(Type, name, LazyInitFutureTypes)                    \
+  void set_##name(const Type& value) { name##_ = value.raw(); }
+  OBJECT_STORE_FIELD_LIST(DECLARE_GETTER,
+                          DECLARE_GETTER_AND_SETTER,
+                          DECLARE_LAZY_INIT_CORE_GETTER_AND_SETTER,
+                          DECLARE_LAZY_INIT_FUTURE_GETTER_AND_SETTER)
 #undef DECLARE_GETTER
 #undef DECLARE_GETTER_AND_SETTER
+#undef DECLARE_LAZY_INIT_GETTER
+#undef DECLARE_LAZY_INIT_CORE_GETTER_AND_SETTER
+#undef DECLARE_LAZY_INIT_FUTURE_GETTER_AND_SETTER
 
   LibraryPtr bootstrap_library(BootstrapLibraryId index) {
     switch (index) {
@@ -403,12 +426,17 @@
 #endif
 
  private:
+  void LazyInitCoreTypes();
+  void LazyInitFutureTypes();
+
   // Finds a core library private method in Object.
   FunctionPtr PrivateObjectLookup(const String& name);
 
   ObjectPtr* from() { return reinterpret_cast<ObjectPtr*>(&object_class_); }
 #define DECLARE_OBJECT_STORE_FIELD(type, name) type##Ptr name##_;
   OBJECT_STORE_FIELD_LIST(DECLARE_OBJECT_STORE_FIELD,
+                          DECLARE_OBJECT_STORE_FIELD,
+                          DECLARE_OBJECT_STORE_FIELD,
                           DECLARE_OBJECT_STORE_FIELD)
 #undef DECLARE_OBJECT_STORE_FIELD
   ObjectPtr* to() {
@@ -432,6 +460,7 @@
 
   friend class Serializer;
   friend class Deserializer;
+  friend class ProgramVisitor;
 
   DISALLOW_COPY_AND_ASSIGN(ObjectStore);
 };
diff --git a/runtime/vm/object_test.cc b/runtime/vm/object_test.cc
index 42714c5..2d3b16e 100644
--- a/runtime/vm/object_test.cc
+++ b/runtime/vm/object_test.cc
@@ -2,6 +2,8 @@
 // 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.
 
+#include <limits>
+
 #include "include/dart_api.h"
 
 #include "bin/builtin.h"
@@ -151,6 +153,88 @@
   EXPECT_EQ(kNumOptionalParameters, function.NumOptionalParameters());
 }
 
+ISOLATE_UNIT_TEST_CASE(SixtyThousandDartClasses) {
+  auto zone = thread->zone();
+  auto isolate = thread->isolate();
+  auto class_table = isolate->class_table();
+
+  const intptr_t start_cid = class_table->NumCids();
+  const intptr_t num_classes = std::numeric_limits<uint16_t>::max() - start_cid;
+
+  const Script& script = Script::Handle(zone);
+  String& name = String::Handle(zone);
+  Class& cls = Class::Handle(zone);
+  Field& field = Field::Handle(zone);
+  Array& fields = Array::Handle(zone);
+  Instance& instance = Instance::Handle(zone);
+  Instance& instance2 = Instance::Handle(zone);
+
+  const auto& instances =
+      GrowableObjectArray::Handle(zone, GrowableObjectArray::New());
+
+  // Create many top-level classes - they should not consume 16-bit range.
+  for (intptr_t i = 0; i < (1 << 16); ++i) {
+    cls = CreateDummyClass(Symbols::TopLevel(), script);
+    cls.Finalize();
+    EXPECT(cls.id() > std::numeric_limits<uint16_t>::max());
+  }
+
+  // Create many concrete classes - they should occupy the entire 16-bit space.
+  for (intptr_t i = 0; i < num_classes; ++i) {
+    name = Symbols::New(thread, OS::SCreate(zone, "MyClass%" Pd "", i));
+    cls = CreateDummyClass(name, script);
+    EXPECT_EQ(start_cid + i, cls.id());
+
+    const intptr_t num_fields = (i % 10);
+    fields = Array::New(num_fields);
+    for (intptr_t f = 0; f < num_fields; ++f) {
+      name =
+          Symbols::New(thread, OS::SCreate(zone, "myField_%" Pd "_%" Pd, i, f));
+      field = Field::New(name, false, false, false, true, false, cls,
+                         Object::dynamic_type(), TokenPosition::kMinSource,
+                         TokenPosition::kMinSource);
+      fields.SetAt(f, field);
+    }
+
+    cls.set_interfaces(Array::empty_array());
+    cls.SetFunctions(Array::empty_array());
+    cls.SetFields(fields);
+    cls.Finalize();
+
+    instance = Instance::New(cls);
+    for (intptr_t f = 0; f < num_fields; ++f) {
+      field ^= fields.At(f);
+      name = Symbols::New(thread,
+                          OS::SCreate(zone, "myFieldValue_%" Pd "_%" Pd, i, f));
+      instance.SetField(field, name);
+    }
+    instances.Add(instance);
+  }
+  EXPECT_EQ((1 << 16) - 1, class_table->NumCids());
+
+  // Ensure GC runs and can recognize all those new instances.
+  isolate->heap()->CollectAllGarbage();
+
+  // Ensure the instances are what we expect.
+  for (intptr_t i = 0; i < num_classes; ++i) {
+    instance ^= instances.At(i);
+    cls = instance.clazz();
+    fields = cls.fields();
+
+    name = cls.Name();
+    EXPECT(strstr(name.ToCString(), OS::SCreate(zone, "MyClass%" Pd "", i)) !=
+           0);
+    EXPECT_EQ((i % 10), fields.Length());
+
+    for (intptr_t f = 0; f < fields.Length(); ++f) {
+      field ^= fields.At(f);
+      instance2 ^= instance.GetField(field);
+      EXPECT(strstr(instance2.ToCString(),
+                    OS::SCreate(zone, "myFieldValue_%" Pd "_%" Pd, i, f)) != 0);
+    }
+  }
+}
+
 ISOLATE_UNIT_TEST_CASE(TypeArguments) {
   const Type& type1 = Type::Handle(Type::Double());
   const Type& type2 = Type::Handle(Type::StringType());
@@ -4325,7 +4409,7 @@
   // Test that Instance::OperatorEquals can call a user-defined operator==.
   const char* kScript =
       "class A {\n"
-      "  bool operator==(A other) { return true; }\n"
+      "  bool operator==(covariant A other) { return true; }\n"
       "}\n"
       "main() {\n"
       "  A a = new A();\n"
diff --git a/runtime/vm/os_fuchsia.cc b/runtime/vm/os_fuchsia.cc
index ff576ff..be98736 100644
--- a/runtime/vm/os_fuchsia.cc
+++ b/runtime/vm/os_fuchsia.cc
@@ -11,7 +11,10 @@
 #include <fcntl.h>
 #include <stdint.h>
 
-#include <fuchsia/deprecatedtimezone/cpp/fidl.h>
+#include <fuchsia/intl/cpp/fidl.h>
+#include <lib/async/default.h>
+#include <lib/async-loop/loop.h>
+#include <lib/async-loop/default.h>
 #include <lib/inspect/cpp/inspect.h>
 #include <lib/sys/cpp/component_context.h>
 #include <lib/sys/cpp/service_directory.h>
@@ -21,17 +24,31 @@
 #include <zircon/syscalls/object.h>
 #include <zircon/types.h>
 
+#include "unicode/errorcode.h"
+#include "unicode/timezone.h"
+
 #include "platform/assert.h"
+#include "platform/syslog.h"
 #include "platform/utils.h"
 #include "vm/zone.h"
 
 namespace {
 
+static constexpr int32_t kMsPerSec = 1000;
+
 // The data directory containing ICU timezone data files.
 static constexpr char kICUTZDataDir[] = "/config/data/tzdata/icu/44/le";
 
+// This is the general OK status.
+static constexpr int32_t kOk = 0;
+
+// This status means that the error code is not initialized yet ("set" was not
+// yet called).  Error codes are usually either 0 (kOk), or negative.
+static constexpr int32_t kUninitialized = 1;
+
 // The status codes for tzdata file open and read.
 enum class TZDataStatus {
+  // The operation completed without error.
   OK = 0,
   // The open call for the tzdata file did not succeed.
   COULD_NOT_OPEN = -1,
@@ -41,6 +58,8 @@
 
 // Adds a facility for introspecting timezone data errors.  Allows insight into
 // the internal state of the VM even if error reporting facilities fail.
+//
+// Under normal operation, all metric values below should be zero.
 class InspectMetrics {
  public:
   // Does not take ownership of inspector.
@@ -48,9 +67,14 @@
       : inspector_(inspector),
         root_(inspector_->GetRoot()),
         metrics_(root_.CreateChild("os")),
-        dst_status_(metrics_.CreateInt("dst_status", 0)),
-        tz_data_status_(metrics_.CreateInt("tz_data_status", 0)),
-        tz_data_close_status_(metrics_.CreateInt("tz_data_close_status", 0)) {}
+        dst_status_(metrics_.CreateInt("dst_status", kUninitialized)),
+        tz_data_status_(metrics_.CreateInt("tz_data_status", kUninitialized)),
+        tz_data_close_status_(
+            metrics_.CreateInt("tz_data_close_status", kUninitialized)),
+        get_profile_status_(
+            metrics_.CreateInt("get_profile_status", kUninitialized)),
+        profiles_timezone_content_status_(
+            metrics_.CreateInt("timezone_content_status", kOk)) {}
 
   // Sets the last status code for DST offset calls.
   void SetDSTOffsetStatus(zx_status_t status) {
@@ -64,6 +88,17 @@
     tz_data_close_status_.Set(status);
   }
 
+  // Sets the last status code for the call to PropertyProvider::GetProfile.
+  void SetProfileStatus(zx_status_t status) {
+    get_profile_status_.Set(static_cast<int32_t>(status));
+  }
+
+  // Sets the last status seen while examining timezones returned from
+  // PropertyProvider::GetProfile.
+  void SetTimeZoneContentStatus(zx_status_t status) {
+    profiles_timezone_content_status_.Set(static_cast<int32_t>(status));
+  }
+
  private:
   // The inspector that all metrics are being reported into.
   inspect::Inspector* inspector_;
@@ -82,11 +117,21 @@
 
   // The return code for the close() call for tzdata files.
   inspect::IntProperty tz_data_close_status_;
+
+  // The return code of the GetProfile call in GetTimeZoneName.  If this is
+  // nonzero, then os_fuchsia.cc reported a default timezone as a fallback.
+  inspect::IntProperty get_profile_status_;
+
+  // U_ILLEGAL_ARGUMENT_ERROR(=1) if timezones read from ProfileProvider were
+  // incorrect. Otherwise 0.  If this metric reports U_ILLEGAL_ARGUMENT_ERROR,
+  // the os_fuchsia.cc module reported a default timezone as a fallback.
+  inspect::IntProperty profiles_timezone_content_status_;
 };
 
 // Initialized on OS:Init(), deinitialized on OS::Cleanup.
 std::unique_ptr<sys::ComponentInspector> component_inspector;
 std::unique_ptr<InspectMetrics> metrics;
+async_loop_t* message_loop = nullptr;
 
 // Initializes the source of timezone data if available.  Timezone data file in
 // Fuchsia is at a fixed directory path.  Returns true on success.
@@ -132,50 +177,85 @@
   return static_cast<intptr_t>(getpid());
 }
 
+// This is the default timezone returned if it could not be obtained.  For
+// Fuchsia, the default device timezone is always UTC.
+static const char kDefaultTimezone[] = "UTC";
+
 // TODO(FL-98): Change this to talk to fuchsia.dart to get timezone service to
 // directly get timezone.
 //
 // Putting this hack right now due to CP-120 as I need to remove
 // component:ConnectToEnvironmentServices and this is the only thing that is
 // blocking it and FL-98 will take time.
-static fuchsia::deprecatedtimezone::TimezoneSyncPtr tz;
+static fuchsia::intl::PropertyProviderSyncPtr property_provider;
 
 static zx_status_t GetLocalAndDstOffsetInSeconds(int64_t seconds_since_epoch,
                                                  int32_t* local_offset,
                                                  int32_t* dst_offset) {
-  zx_status_t status = tz->GetTimezoneOffsetMinutes(seconds_since_epoch * 1000,
-                                                    local_offset, dst_offset);
-  metrics->SetDSTOffsetStatus(status);
-  if (status != ZX_OK) {
-    return status;
+  const char* timezone_id = OS::GetTimeZoneName(seconds_since_epoch);
+  std::unique_ptr<icu::TimeZone> timezone(
+      icu::TimeZone::createTimeZone(timezone_id));
+  UErrorCode error = U_ZERO_ERROR;
+  const auto ms_since_epoch =
+      static_cast<UDate>(kMsPerSec * seconds_since_epoch);
+  // The units of time that local_offset and dst_offset are returned from this
+  // function is, usefully, not documented, but it seems that the units are
+  // milliseconds.  Add these variables here for clarity.
+  int32_t local_offset_ms = 0;
+  int32_t dst_offset_ms = 0;
+  timezone->getOffset(ms_since_epoch, /*local_time=*/false, local_offset_ms,
+                      dst_offset_ms, error);
+  metrics->SetDSTOffsetStatus(error);
+  if (error != U_ZERO_ERROR) {
+    icu::ErrorCode icu_error;
+    icu_error.set(error);
+    Syslog::PrintErr("could not get DST offset: %s\n", icu_error.errorName());
+    return ZX_ERR_INTERNAL;
   }
-  *local_offset *= 60;
-  *dst_offset *= 60;
+  // We must return offset in seconds, so convert.
+  *local_offset = local_offset_ms / kMsPerSec;
+  *dst_offset = dst_offset_ms / kMsPerSec;
   return ZX_OK;
 }
 
 const char* OS::GetTimeZoneName(int64_t seconds_since_epoch) {
   // TODO(abarth): Handle time zone changes.
-  static const auto* tz_name = new std::string([] {
-    std::string result;
-    tz->GetTimezoneId(&result);
-    return result;
-  }());
+  static const std::unique_ptr<std::string> tz_name =
+      std::make_unique<std::string>([]() -> std::string {
+        fuchsia::intl::Profile profile;
+        const zx_status_t status = property_provider->GetProfile(&profile);
+        metrics->SetProfileStatus(status);
+        if (status != ZX_OK) {
+          return kDefaultTimezone;
+        }
+        const std::vector<fuchsia::intl::TimeZoneId>& timezones =
+            profile.time_zones();
+        if (timezones.empty()) {
+          metrics->SetTimeZoneContentStatus(U_ILLEGAL_ARGUMENT_ERROR);
+          // Empty timezone array is not up to fuchsia::intl spec.  The serving
+          // endpoint is broken and should be fixed.
+          Syslog::PrintErr("got empty timezone value\n");
+          return kDefaultTimezone;
+        }
+        return timezones[0].id;
+      }());
   return tz_name->c_str();
 }
 
 int OS::GetTimeZoneOffsetInSeconds(int64_t seconds_since_epoch) {
-  int32_t local_offset, dst_offset;
-  zx_status_t status = GetLocalAndDstOffsetInSeconds(
+  int32_t local_offset = 0;
+  int32_t dst_offset = 0;
+  const zx_status_t status = GetLocalAndDstOffsetInSeconds(
       seconds_since_epoch, &local_offset, &dst_offset);
   return status == ZX_OK ? local_offset + dst_offset : 0;
 }
 
 int OS::GetLocalTimeZoneAdjustmentInSeconds() {
-  int32_t local_offset, dst_offset;
   zx_time_t now = 0;
   zx_clock_get(ZX_CLOCK_UTC, &now);
-  zx_status_t status = GetLocalAndDstOffsetInSeconds(
+  int32_t local_offset = 0;
+  int32_t dst_offset = 0;
+  const zx_status_t status = GetLocalAndDstOffsetInSeconds(
       now / ZX_SEC(1), &local_offset, &dst_offset);
   return status == ZX_OK ? local_offset : 0;
 }
@@ -199,7 +279,7 @@
 }
 
 int64_t OS::GetCurrentMonotonicMicros() {
-  int64_t ticks = GetCurrentMonotonicTicks();
+  const int64_t ticks = GetCurrentMonotonicTicks();
   ASSERT(GetCurrentMonotonicFrequency() == kNanosecondsPerSecond);
   return ticks / kNanosecondsPerMicrosecond;
 }
@@ -342,17 +422,28 @@
 }
 
 void OS::Init() {
+  if (async_get_default_dispatcher() == NULL) {
+    async_loop_create(&kAsyncLoopConfigAttachToCurrentThread, &message_loop);
+    async_set_default_dispatcher(async_loop_get_dispatcher(message_loop));
+    async_loop_start_thread(message_loop, "Fuchsia async loop", nullptr);
+  }
+
   sys::ComponentContext* context = dart::ComponentContext();
   component_inspector = std::make_unique<sys::ComponentInspector>(context);
   metrics = std::make_unique<InspectMetrics>(component_inspector->inspector());
 
   InitializeTZData();
-  context->svc()->Connect(tz.NewRequest());
+  auto services = sys::ServiceDirectory::CreateFromNamespace();
+  services->Connect(property_provider.NewRequest());
 }
 
 void OS::Cleanup() {
   metrics = nullptr;
   component_inspector = nullptr;
+  if (message_loop != nullptr) {
+    async_loop_destroy(message_loop);
+    message_loop = nullptr;
+  }
 }
 
 void OS::PrepareToAbort() {}
diff --git a/runtime/vm/program_visitor.cc b/runtime/vm/program_visitor.cc
index 41582a3..14708e3 100644
--- a/runtime/vm/program_visitor.cc
+++ b/runtime/vm/program_visitor.cc
@@ -1092,7 +1092,7 @@
 
   static Value ValueOf(Pair kv) { return kv; }
 
-  static inline intptr_t Hashcode(Key key) { return key->Size(); }
+  static inline intptr_t Hashcode(Key key) { return key->Hash(); }
 
   static inline bool IsKeyEqual(Pair pair, Key key) {
     return pair->Equals(*key);
@@ -1300,4 +1300,154 @@
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 }
 
+#if defined(DART_PRECOMPILER)
+class AssignLoadingUnitsCodeVisitor : public CodeVisitor {
+ public:
+  explicit AssignLoadingUnitsCodeVisitor(Zone* zone)
+      : heap_(Thread::Current()->heap()),
+        func_(Function::Handle(zone)),
+        cls_(Class::Handle(zone)),
+        lib_(Library::Handle(zone)),
+        unit_(LoadingUnit::Handle(zone)),
+        obj_(Object::Handle(zone)) {}
+
+  void VisitCode(const Code& code) {
+    intptr_t id;
+    if (code.IsFunctionCode()) {
+      func_ ^= code.owner();
+      cls_ = func_.Owner();
+      lib_ = cls_.library();
+      unit_ = lib_.loading_unit();
+      id = unit_.id();
+    } else if (code.IsAllocationStubCode()) {
+      cls_ ^= code.owner();
+      lib_ = cls_.library();
+      unit_ = lib_.loading_unit();
+      id = unit_.id();
+    } else if (code.IsStubCode()) {
+      id = LoadingUnit::kRootId;
+    } else {
+      UNREACHABLE();
+    }
+
+    ASSERT(heap_->GetLoadingUnit(code.raw()) == WeakTable::kNoValue);
+    heap_->SetLoadingUnit(code.raw(), id);
+
+    obj_ = code.code_source_map();
+    MergeAssignment(obj_, id);
+    obj_ = code.compressed_stackmaps();
+    MergeAssignment(obj_, id);
+  }
+
+  void MergeAssignment(const Object& obj, intptr_t id) {
+    intptr_t old_id = heap_->GetLoadingUnit(obj_.raw());
+    if (old_id == WeakTable::kNoValue) {
+      heap_->SetLoadingUnit(obj_.raw(), id);
+    } else if (old_id == id) {
+      // Shared with another code in the same loading unit.
+    } else {
+      // Shared with another code in a different loading unit.
+      // Could assign to dominating loading unit.
+      heap_->SetLoadingUnit(obj_.raw(), LoadingUnit::kRootId);
+    }
+  }
+
+ private:
+  Heap* heap_;
+  Function& func_;
+  Class& cls_;
+  Library& lib_;
+  LoadingUnit& unit_;
+  Object& obj_;
+};
+
+void ProgramVisitor::AssignUnits(Thread* thread) {
+  StackZone stack_zone(thread);
+  HANDLESCOPE(thread);
+  Zone* zone = thread->zone();
+
+  // VM stubs.
+  Instructions& inst = Instructions::Handle(zone);
+  Code& code = Code::Handle(zone);
+  for (intptr_t i = 0; i < StubCode::NumEntries(); i++) {
+    inst = StubCode::EntryAt(i).instructions();
+    thread->heap()->SetLoadingUnit(inst.raw(), LoadingUnit::kRootId);
+  }
+
+  // Isolate stubs.
+  ObjectStore* object_store = thread->isolate()->object_store();
+  ObjectPtr* from = object_store->from();
+  ObjectPtr* to = object_store->to_snapshot(Snapshot::kFullAOT);
+  for (ObjectPtr* p = from; p <= to; p++) {
+    if ((*p)->IsCode()) {
+      code ^= *p;
+      inst = code.instructions();
+      thread->heap()->SetLoadingUnit(inst.raw(), LoadingUnit::kRootId);
+    }
+  }
+
+  // Function code / allocation stubs.
+  AssignLoadingUnitsCodeVisitor visitor(zone);
+  WalkProgram(zone, thread->isolate(), &visitor);
+}
+
+class ProgramHashVisitor : public CodeVisitor {
+ public:
+  explicit ProgramHashVisitor(Zone* zone)
+      : str_(String::Handle(zone)),
+        pool_(ObjectPool::Handle(zone)),
+        obj_(Object::Handle(zone)),
+        instr_(Instructions::Handle(zone)),
+        hash_(0) {}
+
+  void VisitClass(const Class& cls) {
+    str_ = cls.Name();
+    Hash(str_);
+  }
+
+  void VisitFunction(const Function& function) {
+    str_ = function.name();
+    Hash(str_);
+  }
+
+  void VisitCode(const Code& code) {
+    pool_ = code.object_pool();
+    for (intptr_t i = 0; i < pool_.Length(); i++) {
+      if (pool_.TypeAt(i) == ObjectPool::EntryType::kTaggedObject) {
+        obj_ = pool_.ObjectAt(i);
+        if (obj_.IsInstance()) {
+          Hash(Instance::Cast(obj_));
+        }
+      }
+    }
+    instr_ = code.instructions();
+    hash_ = CombineHashes(hash_, instr_.Hash());
+  }
+
+  void Hash(const Instance& instance) {
+    hash_ = CombineHashes(hash_, instance.CanonicalizeHash());
+  }
+
+  uint32_t hash() const { return FinalizeHash(hash_, String::kHashBits); }
+
+ private:
+  String& str_;
+  ObjectPool& pool_;
+  Object& obj_;
+  Instructions& instr_;
+  uint32_t hash_;
+};
+
+uint32_t ProgramVisitor::Hash(Thread* thread) {
+  StackZone stack_zone(thread);
+  HANDLESCOPE(thread);
+  Zone* zone = thread->zone();
+
+  ProgramHashVisitor visitor(zone);
+  WalkProgram(zone, thread->isolate(), &visitor);
+  return visitor.hash();
+}
+
+#endif  // defined(DART_PRECOMPILED_RUNTIME)
+
 }  // namespace dart
diff --git a/runtime/vm/program_visitor.h b/runtime/vm/program_visitor.h
index e10ffd2..d535f1f 100644
--- a/runtime/vm/program_visitor.h
+++ b/runtime/vm/program_visitor.h
@@ -96,6 +96,10 @@
   static void WalkProgram(Zone* zone, Isolate* isolate, ClassVisitor* visitor);
 
   static void Dedup(Thread* thread);
+#if defined(DART_PRECOMPILER)
+  static void AssignUnits(Thread* thread);
+  static uint32_t Hash(Thread* thread);
+#endif
 
  private:
 #if !defined(DART_PRECOMPILED_RUNTIME)
diff --git a/runtime/vm/raw_object.cc b/runtime/vm/raw_object.cc
index d29e083..9797fc2 100644
--- a/runtime/vm/raw_object.cc
+++ b/runtime/vm/raw_object.cc
@@ -544,6 +544,7 @@
 REGULAR_VISITOR(MirrorReference)
 REGULAR_VISITOR(UserTag)
 REGULAR_VISITOR(SubtypeTestCache)
+REGULAR_VISITOR(LoadingUnit)
 REGULAR_VISITOR(KernelProgramInfo)
 VARIABLE_VISITOR(TypeArguments, Smi::Value(raw_obj->ptr()->length_))
 VARIABLE_VISITOR(LocalVarDescriptors, raw_obj->ptr()->num_entries_)
diff --git a/runtime/vm/raw_object.h b/runtime/vm/raw_object.h
index 3089d0b..3e634e4 100644
--- a/runtime/vm/raw_object.h
+++ b/runtime/vm/raw_object.h
@@ -138,7 +138,7 @@
   // See Object::MakeUnusedSpaceTraversable.
   COMPILE_ASSERT(kCardRememberedBit == 0);
 
-  COMPILE_ASSERT(kClassIdTagSize == (sizeof(classid_t) * kBitsPerByte));
+  COMPILE_ASSERT(8 * sizeof(uint16_t) == kClassIdTagSize);
 
   // Encodes the object size in the tag in units of object alignment.
   class SizeTag {
@@ -704,7 +704,8 @@
   enum ClassFinalizedState {
     kAllocated = 0,  // Initial state.
     kPreFinalized,   // VM classes: size precomputed, but no checks done.
-    kFinalized,      // Class parsed, finalized and ready for use.
+    kFinalized,      // Class parsed, code compiled, not ready for allocation.
+    kAllocateFinalized,  // CHA invalidated, class is ready for allocation.
   };
   enum ClassLoadingState {
     // Class object is created, but it is not filled up.
@@ -930,6 +931,7 @@
   class UnboxedParameterBitmap {
    public:
     static constexpr intptr_t kBitsPerParameter = 2;
+    static constexpr intptr_t kParameterBitmask = (1 << kBitsPerParameter) - 1;
     static constexpr intptr_t kCapacity =
         (kBitsPerByte * sizeof(uint64_t)) / kBitsPerParameter;
 
@@ -942,37 +944,44 @@
       if (position >= kCapacity) {
         return false;
       }
-      ASSERT(Utils::TestBit(bitmap_, 2 * position) ||
-             !Utils::TestBit(bitmap_, 2 * position + 1));
-      return Utils::TestBit(bitmap_, 2 * position);
+      ASSERT(Utils::TestBit(bitmap_, kBitsPerParameter * position) ||
+             !Utils::TestBit(bitmap_, kBitsPerParameter * position + 1));
+      return Utils::TestBit(bitmap_, kBitsPerParameter * position);
     }
     DART_FORCE_INLINE bool IsUnboxedInteger(intptr_t position) const {
       if (position >= kCapacity) {
         return false;
       }
-      return Utils::TestBit(bitmap_, 2 * position) &&
-             !Utils::TestBit(bitmap_, 2 * position + 1);
+      return Utils::TestBit(bitmap_, kBitsPerParameter * position) &&
+             !Utils::TestBit(bitmap_, kBitsPerParameter * position + 1);
     }
     DART_FORCE_INLINE bool IsUnboxedDouble(intptr_t position) const {
       if (position >= kCapacity) {
         return false;
       }
-      return Utils::TestBit(bitmap_, 2 * position) &&
-             Utils::TestBit(bitmap_, 2 * position + 1);
+      return Utils::TestBit(bitmap_, kBitsPerParameter * position) &&
+             Utils::TestBit(bitmap_, kBitsPerParameter * position + 1);
     }
     DART_FORCE_INLINE void SetUnboxedInteger(intptr_t position) {
       ASSERT(position < kCapacity);
-      bitmap_ |= Utils::Bit<decltype(bitmap_)>(2 * position);
-      ASSERT(!Utils::TestBit(bitmap_, 2 * position + 1));
+      bitmap_ |= Utils::Bit<decltype(bitmap_)>(kBitsPerParameter * position);
+      ASSERT(!Utils::TestBit(bitmap_, kBitsPerParameter * position + 1));
     }
     DART_FORCE_INLINE void SetUnboxedDouble(intptr_t position) {
       ASSERT(position < kCapacity);
-      bitmap_ |= Utils::Bit<decltype(bitmap_)>(2 * position);
-      bitmap_ |= Utils::Bit<decltype(bitmap_)>(2 * position + 1);
+      bitmap_ |= Utils::Bit<decltype(bitmap_)>(kBitsPerParameter * position);
+      bitmap_ |=
+          Utils::Bit<decltype(bitmap_)>(kBitsPerParameter * position + 1);
     }
     DART_FORCE_INLINE uint64_t Value() const { return bitmap_; }
     DART_FORCE_INLINE bool IsEmpty() const { return bitmap_ == 0; }
     DART_FORCE_INLINE void Reset() { bitmap_ = 0; }
+    DART_FORCE_INLINE bool HasUnboxedParameters() const {
+      return (bitmap_ >> kBitsPerParameter) != 0;
+    }
+    DART_FORCE_INLINE bool HasUnboxedReturnValue() const {
+      return (bitmap_ & kParameterBitmask) != 0;
+    }
 
    private:
     uint64_t bitmap_;
@@ -1186,9 +1195,9 @@
 #endif
   TokenPosition token_pos_;
   TokenPosition end_token_pos_;
-  classid_t guarded_cid_;
-  classid_t is_nullable_;  // kNullCid if field can contain null value and
-                           // kInvalidCid otherwise.
+  uint16_t guarded_cid_;
+  uint16_t is_nullable_;  // kNullCid if field can contain null value and
+                          // kInvalidCid otherwise.
 
 #if !defined(DART_PRECOMPILED_RUNTIME)
   typedef BitField<uint32_t, bool, 0, 1> IsDeclaredInBytecode;
@@ -1214,6 +1223,9 @@
 #endif  // !defined(DART_PRECOMPILED_RUNTIME)
 
   friend class CidRewriteVisitor;
+  friend class GuardFieldClassInstr;     // For sizeof(guarded_cid_/...)
+  friend class LoadFieldInstr;           // For sizeof(guarded_cid_/...)
+  friend class StoreInstanceFieldInstr;  // For sizeof(guarded_cid_/...)
 };
 
 class ScriptLayout : public ObjectLayout {
@@ -1303,6 +1315,7 @@
   GrowableObjectArrayPtr metadata_;  // Metadata on classes, methods etc.
   ClassPtr toplevel_class_;          // Class containing top-level elements.
   GrowableObjectArrayPtr used_scripts_;
+  LoadingUnitPtr loading_unit_;
   ArrayPtr imports_;  // List of Namespaces imported without prefix.
   ArrayPtr exports_;  // List of re-exported Namespaces.
   ArrayPtr dependencies_;
@@ -1389,7 +1402,7 @@
 
 #if defined(DART_PRECOMPILED_RUNTIME)
   VISIT_NOTHING();
-  classid_t cid_;
+  uint16_t cid_;
 #else
   VISIT_FROM(ObjectPtr, target_);
   ObjectPtr target_;
@@ -1975,8 +1988,8 @@
   CodePtr target_;
   VISIT_TO(ObjectPtr, target_);
   uword entry_point_;
-  classid_t lower_limit_;
-  classid_t upper_limit_;
+  uint16_t lower_limit_;
+  uint16_t upper_limit_;
 };
 
 class MonomorphicSmiableCallLayout : public ObjectLayout {
@@ -2054,6 +2067,17 @@
   VISIT_TO(ObjectPtr, cache_);
 };
 
+class LoadingUnitLayout : public ObjectLayout {
+  RAW_HEAP_OBJECT_IMPLEMENTATION(LoadingUnit);
+  VISIT_FROM(ObjectPtr, parent_);
+  LoadingUnitPtr parent_;
+  ArrayPtr base_objects_;
+  VISIT_TO(ObjectPtr, base_objects_);
+  int32_t id_;
+  bool load_outstanding_;
+  bool loaded_;
+};
+
 class ErrorLayout : public ObjectLayout {
   RAW_HEAP_OBJECT_IMPLEMENTATION(Error);
 };
@@ -2117,9 +2141,8 @@
     switch (kind) {
       case Snapshot::kFull:
       case Snapshot::kFullJIT:
-        return reinterpret_cast<ObjectPtr*>(&imports_);
       case Snapshot::kFullAOT:
-        return reinterpret_cast<ObjectPtr*>(&importer_);
+        return reinterpret_cast<ObjectPtr*>(&imports_);
       case Snapshot::kMessage:
       case Snapshot::kNone:
       case Snapshot::kInvalid:
@@ -2233,7 +2256,7 @@
   AbstractTypePtr bound_;  // ObjectType if no explicit bound specified.
   FunctionPtr parameterized_function_;
   VISIT_TO(ObjectPtr, parameterized_function_)
-  classid_t parameterized_class_id_;
+  uint16_t parameterized_class_id_;
   TokenPosition token_pos_;
   int16_t index_;
   uint8_t flags_;
diff --git a/runtime/vm/raw_object_fields.cc b/runtime/vm/raw_object_fields.cc
index 13c759b..8b6b184 100644
--- a/runtime/vm/raw_object_fields.cc
+++ b/runtime/vm/raw_object_fields.cc
@@ -71,6 +71,7 @@
   F(Library, metadata_)                                                        \
   F(Library, toplevel_class_)                                                  \
   F(Library, used_scripts_)                                                    \
+  F(Library, loading_unit_)                                                    \
   F(Library, imports_)                                                         \
   F(Library, exports_)                                                         \
   F(Library, kernel_data_)                                                     \
@@ -128,6 +129,8 @@
   F(MegamorphicCache, buckets_)                                                \
   F(MegamorphicCache, mask_)                                                   \
   F(SubtypeTestCache, cache_)                                                  \
+  F(LoadingUnit, parent_)                                                      \
+  F(LoadingUnit, base_objects_)                                                \
   F(ApiError, message_)                                                        \
   F(LanguageError, previous_error_)                                            \
   F(LanguageError, script_)                                                    \
diff --git a/runtime/vm/raw_object_snapshot.cc b/runtime/vm/raw_object_snapshot.cc
index ebe73f8..2ef43f3 100644
--- a/runtime/vm/raw_object_snapshot.cc
+++ b/runtime/vm/raw_object_snapshot.cc
@@ -575,6 +575,7 @@
 MESSAGE_SNAPSHOT_UNREACHABLE(SingleTargetCache);
 MESSAGE_SNAPSHOT_UNREACHABLE(String);
 MESSAGE_SNAPSHOT_UNREACHABLE(SubtypeTestCache);
+MESSAGE_SNAPSHOT_UNREACHABLE(LoadingUnit);
 MESSAGE_SNAPSHOT_UNREACHABLE(TypedDataBase);
 MESSAGE_SNAPSHOT_UNREACHABLE(UnlinkedCall);
 MESSAGE_SNAPSHOT_UNREACHABLE(MonomorphicSmiableCall);
diff --git a/runtime/vm/resolver.cc b/runtime/vm/resolver.cc
index d05a03d..68a1e4d 100644
--- a/runtime/vm/resolver.cc
+++ b/runtime/vm/resolver.cc
@@ -71,61 +71,50 @@
   }
   Function& function = Function::Handle(zone);
 
-  String& demangled = String::Handle(zone);
+  const String& demangled = String::Handle(
+      zone,
+      Function::IsDynamicInvocationForwarderName(function_name)
+          ? Function::DemangleDynamicInvocationForwarderName(function_name)
+          : function_name.raw());
 
-  const bool is_getter = Field::IsGetterName(function_name);
+  const bool is_getter = Field::IsGetterName(demangled);
+  String& demangled_getter_name = String::Handle();
   if (is_getter) {
-    demangled = Field::NameFromGetter(function_name);
+    demangled_getter_name = Field::NameFromGetter(demangled);
   }
 
-  if (Function::IsDynamicInvocationForwarderName(function_name)) {
-    demangled = Function::DemangleDynamicInvocationForwarderName(function_name);
-#ifdef DART_PRECOMPILED_RUNTIME
-    // In precompiled mode, the non-dynamic version of the function may be
-    // tree-shaken away, so can't necessarily resolve the demanged name.
-    while (!cls.IsNull()) {
+  const bool is_dyn_call = demangled.raw() != function_name.raw();
+
+  while (!cls.IsNull()) {
+    if (is_dyn_call) {
+      // Try to find a dyn:* forwarder & return it.
       function = cls.GetInvocationDispatcher(
           function_name, Array::null_array(),
           FunctionLayout::kDynamicInvocationForwarder,
           /*create_if_absent=*/false);
-      if (!function.IsNull()) break;
-      cls = cls.SuperClass();
     }
-    // Some functions don't require dynamic invocation forwarders, for example
-    // if there are no parameters or all the parameters are marked
-    // `generic-covariant` (meaning there's no work for the dynamic invocation
-    // forwarder to do, see `kernel::DynamicInvocationForwarder`). For these
-    // functions, we won't have built a `dyn:` version, but it's safe to just
-    // return the original version directly.
-    return !function.IsNull() ? function.raw()
-                              : ResolveDynamicAnyArgs(zone, receiver_class,
-                                                      demangled, allow_add);
-#else
-    function =
-        ResolveDynamicAnyArgs(zone, receiver_class, demangled, allow_add);
-    return function.IsNull() ? function.raw()
-                             : function.GetDynamicInvocationForwarder(
-                                   function_name, allow_add);
-#endif
-  }
+    if (!function.IsNull()) return function.raw();
 
-  // Now look for an instance function whose name matches function_name
-  // in the class.
-  while (!cls.IsNull()) {
-    function = cls.LookupDynamicFunction(function_name);
-    if (!function.IsNull()) {
-      return function.raw();
+    function = cls.LookupDynamicFunction(demangled);
+#if !defined(DART_PRECOMPILED_RUNTIME)
+    // In JIT we might need to lazily create a dyn:* forwarder.
+    if (is_dyn_call && !function.IsNull()) {
+      function =
+          function.GetDynamicInvocationForwarder(function_name, allow_add);
     }
+#endif
+    if (!function.IsNull()) return function.raw();
+
     // Getter invocation might actually be a method extraction.
-    if (is_getter && function.IsNull()) {
-      function = cls.LookupDynamicFunction(demangled);
+    if (is_getter) {
+      function = cls.LookupDynamicFunction(demangled_getter_name);
       if (!function.IsNull()) {
         if (allow_add && FLAG_lazy_dispatchers) {
           // We were looking for the getter but found a method with the same
           // name. Create a method extractor and return it.
           // The extractor does not exist yet, so using GetMethodExtractor is
           // not necessary here.
-          function = function.CreateMethodExtractor(function_name);
+          function = function.CreateMethodExtractor(demangled);
           return function.raw();
         } else {
           return Function::null();
diff --git a/runtime/vm/runtime_entry.cc b/runtime/vm/runtime_entry.cc
index 98813d1..c8a92c5 100644
--- a/runtime/vm/runtime_entry.cc
+++ b/runtime/vm/runtime_entry.cc
@@ -51,6 +51,10 @@
             reoptimization_counter_threshold,
             4000,
             "Counter threshold before a function gets reoptimized.");
+DEFINE_FLAG(bool,
+            stress_write_barrier_elimination,
+            false,
+            "Stress test write barrier elimination.");
 DEFINE_FLAG(bool, trace_deoptimization, false, "Trace deoptimization");
 DEFINE_FLAG(bool,
             trace_deoptimization_verbose,
@@ -253,6 +257,10 @@
   Exceptions::ThrowByType(Exceptions::kIntegerDivisionByZeroException, args);
 }
 
+static Heap::Space SpaceForRuntimeAllocation() {
+  return FLAG_stress_write_barrier_elimination ? Heap::kOld : Heap::kNew;
+}
+
 // Allocation of a fixed length array of given element type.
 // This runtime entry is never called for allocating a List of a generic type,
 // because a prior run time call instantiates the element type if necessary.
@@ -281,8 +289,9 @@
     Exceptions::Throw(thread, exception);
   }
 
-  const Array& array =
-      Array::Handle(zone, Array::New(static_cast<intptr_t>(len), Heap::kNew));
+  const Array& array = Array::Handle(
+      zone,
+      Array::New(static_cast<intptr_t>(len), SpaceForRuntimeAllocation()));
   arguments.SetReturn(array);
   TypeArguments& element_type =
       TypeArguments::CheckedHandle(zone, arguments.ArgAt(1));
@@ -303,14 +312,25 @@
   return caller_frame->GetTokenPos();
 }
 
+// Result of an invoke may be an unhandled exception, in which case we
+// rethrow it.
+static void ThrowIfError(const Object& result) {
+  if (!result.IsNull() && result.IsError()) {
+    Exceptions::PropagateError(Error::Cast(result));
+  }
+}
+
 // Allocate a new object.
 // Arg0: class of the object that needs to be allocated.
 // Arg1: type arguments of the object that needs to be allocated.
 // Return value: newly allocated object.
 DEFINE_RUNTIME_ENTRY(AllocateObject, 2) {
   const Class& cls = Class::CheckedHandle(zone, arguments.ArgAt(0));
+  const Error& error =
+      Error::Handle(zone, cls.EnsureIsAllocateFinalized(thread));
+  ThrowIfError(error);
   const Instance& instance =
-      Instance::Handle(zone, Instance::New(cls, Heap::kNew));
+      Instance::Handle(zone, Instance::New(cls, SpaceForRuntimeAllocation()));
 
   arguments.SetReturn(instance);
   if (cls.NumTypeArguments() == 0) {
@@ -479,8 +499,8 @@
 // Return value: newly allocated context.
 DEFINE_RUNTIME_ENTRY(AllocateContext, 1) {
   const Smi& num_variables = Smi::CheckedHandle(zone, arguments.ArgAt(0));
-  const Context& context =
-      Context::Handle(zone, Context::New(num_variables.Value()));
+  const Context& context = Context::Handle(
+      zone, Context::New(num_variables.Value(), SpaceForRuntimeAllocation()));
   arguments.SetReturn(context);
 }
 
@@ -490,8 +510,8 @@
 // Return value: newly allocated context.
 DEFINE_RUNTIME_ENTRY(CloneContext, 1) {
   const Context& ctx = Context::CheckedHandle(zone, arguments.ArgAt(0));
-  Context& cloned_ctx =
-      Context::Handle(zone, Context::New(ctx.num_variables()));
+  Context& cloned_ctx = Context::Handle(
+      zone, Context::New(ctx.num_variables(), SpaceForRuntimeAllocation()));
   cloned_ctx.set_parent(Context::Handle(zone, ctx.parent()));
   Object& inst = Object::Handle(zone);
   for (int i = 0; i < ctx.num_variables(); i++) {
@@ -501,14 +521,6 @@
   arguments.SetReturn(cloned_ctx);
 }
 
-// Result of an invoke may be an unhandled exception, in which case we
-// rethrow it.
-static void ThrowIfError(const Object& result) {
-  if (!result.IsNull() && result.IsError()) {
-    Exceptions::PropagateError(Error::Cast(result));
-  }
-}
-
 // Invoke field getter before dispatch.
 // Arg0: instance.
 // Arg1: field name (may be demangled during call).
@@ -1207,8 +1219,7 @@
     // A call site in the monomorphic state does not load the arguments
     // descriptor, so do not allow transition to this state if the callee
     // needs it.
-    if (target_function.HasOptionalParameters() ||
-        target_function.IsGeneric()) {
+    if (target_function.PrologueNeedsArgumentsDescriptor()) {
       return;
     }
 
@@ -1643,8 +1654,8 @@
   //
   // Because of this we also don't generate monomorphic checks for those
   // functions.
-  if (!target_function.IsNull() && !target_function.HasOptionalParameters() &&
-      !target_function.IsGeneric()) {
+  if (!target_function.IsNull() &&
+      !target_function.PrologueNeedsArgumentsDescriptor()) {
     // Patch to monomorphic call.
     ASSERT(target_function.HasCode());
     const Code& target_code =
@@ -1655,6 +1666,7 @@
     if (unlinked.can_patch_to_monomorphic()) {
       object = expected_cid.raw();
       code = target_code.raw();
+      ASSERT(code.HasMonomorphicEntry());
     } else {
       object = MonomorphicSmiableCall::New(expected_cid.Value(), target_code);
       code = StubCode::MonomorphicSmiableCheck().raw();
@@ -1896,8 +1908,7 @@
 
   if ((number_of_checks == 0) &&
       (!FLAG_precompiled_mode || ic_data.receiver_cannot_be_smi()) &&
-      !target_function.HasOptionalParameters() &&
-      !target_function.IsGeneric()) {
+      !target_function.PrologueNeedsArgumentsDescriptor()) {
     // This call site is unlinked: transition to a monomorphic direct call.
     // Note we cannot do this if the target has optional parameters because
     // the monomorphic direct call does not load the arguments descriptor.
@@ -1908,6 +1919,7 @@
         Code::Handle(zone_, target_function.EnsureHasCode());
     const Smi& expected_cid =
         Smi::Handle(zone_, Smi::New(receiver_.GetClassId()));
+    ASSERT(target_code.HasMonomorphicEntry());
     CodePatcher::PatchSwitchableCallAtWithMutatorsStopped(
         thread_, caller_frame_->pc(), caller_code_, expected_cid, target_code);
     arguments_.SetArgAt(0, target_code);
@@ -2128,7 +2140,7 @@
 //   Arg0: receiver
 //   Arg1: target name
 //   Arg2: arguments descriptor
-//   Returns: target function
+//   Returns: target function (can only be null if !FLAG_lazy_dispatchers)
 // Modifies the instance call table in current interpreter.
 DEFINE_RUNTIME_ENTRY(InterpretedInstanceCallMissHandler, 3) {
 #if defined(DART_PRECOMPILED_RUNTIME)
@@ -2152,11 +2164,164 @@
     target_function =
         InlineCacheMissHelper(receiver_class, arg_desc, target_name);
   }
-  ASSERT(!target_function.IsNull());
+  ASSERT(!target_function.IsNull() || !FLAG_lazy_dispatchers);
   arguments.SetReturn(target_function);
 #endif
 }
 
+// Used to find the correct receiver and function to invoke or to fall back to
+// invoking noSuchMethod when lazy dispatchers are disabled. Returns the
+// result of the invocation or an Error.
+static ObjectPtr InvokeCallThroughGetterOrNoSuchMethod(
+    Zone* zone,
+    const Instance& receiver,
+    const String& target_name,
+    const Array& orig_arguments,
+    const Array& orig_arguments_desc) {
+  ASSERT(!FLAG_lazy_dispatchers);
+  const bool is_dynamic_call =
+      Function::IsDynamicInvocationForwarderName(target_name);
+  String& demangled_target_name = String::Handle(zone, target_name.raw());
+  if (is_dynamic_call) {
+    demangled_target_name =
+        Function::DemangleDynamicInvocationForwarderName(target_name);
+  }
+
+  Class& cls = Class::Handle(zone, receiver.clazz());
+  Function& function = Function::Handle(zone);
+
+  // Dart distinguishes getters and regular methods and allows their calls
+  // to mix with conversions, and its selectors are independent of arity. So do
+  // a zigzagged lookup to see if this call failed because of an arity mismatch,
+  // need for conversion, or there really is no such method.
+
+  const bool is_getter = Field::IsGetterName(demangled_target_name);
+  if (is_getter) {
+    // Tear-off of a method
+    // o.foo (o.get:foo) failed, closurize o.foo() if it exists.
+    const auto& function_name =
+        String::Handle(zone, Field::NameFromGetter(demangled_target_name));
+    while (!cls.IsNull()) {
+      // We don't generate dyn:* forwarders for method extractors so there is no
+      // need to try to find a dyn:get:foo first (see assertion below)
+      if (function.IsNull()) {
+        function = cls.LookupDynamicFunction(function_name);
+      }
+      if (!function.IsNull()) {
+#if !defined(DART_PRECOMPILED_RUNTIME)
+        ASSERT(!kernel::NeedsDynamicInvocationForwarder(Function::Handle(
+            function.GetMethodExtractor(demangled_target_name))));
+#endif
+        const Function& closure_function =
+            Function::Handle(zone, function.ImplicitClosureFunction());
+        const Object& result = Object::Handle(
+            zone, closure_function.ImplicitInstanceClosure(receiver));
+        return result.raw();
+      }
+      cls = cls.SuperClass();
+    }
+
+    // Fall through for noSuchMethod
+  } else {
+    // Call through field.
+    // o.foo(...) failed, invoke noSuchMethod is foo exists but has the wrong
+    // number of arguments, or try (o.foo).call(...)
+
+    if ((target_name.raw() == Symbols::Call().raw()) && receiver.IsClosure()) {
+      // Special case: closures are implemented with a call getter instead of a
+      // call method and with lazy dispatchers the field-invocation-dispatcher
+      // would perform the closure call.
+      auto& result = Object::Handle(
+          zone,
+          DartEntry::ResolveCallable(orig_arguments, orig_arguments_desc));
+      if (result.IsError()) {
+        return result.raw();
+      }
+      function ^= result.raw();
+      if (is_dynamic_call && !function.IsNull() &&
+          !function.CanReceiveDynamicInvocation()) {
+        ArgumentsDescriptor args_desc(orig_arguments_desc);
+        result = function.DoArgumentTypesMatch(orig_arguments, args_desc);
+        if (result.IsError()) {
+          return result.raw();
+        }
+      }
+      result = DartEntry::InvokeCallable(function, orig_arguments,
+                                         orig_arguments_desc);
+      return result.raw();
+    }
+
+    // Dynamic call sites have to use the dynamic getter as well (if it was
+    // created).
+    const auto& getter_name =
+        String::Handle(zone, Field::GetterName(demangled_target_name));
+    const auto& dyn_getter_name = String::Handle(
+        zone, is_dynamic_call
+                  ? Function::CreateDynamicInvocationForwarderName(getter_name)
+                  : getter_name.raw());
+    ArgumentsDescriptor args_desc(orig_arguments_desc);
+    while (!cls.IsNull()) {
+      // If there is a function with the target name but mismatched arguments
+      // we need to call `receiver.noSuchMethod()`.
+      function = cls.LookupDynamicFunction(target_name);
+      if (!function.IsNull()) {
+        ASSERT(!function.AreValidArguments(args_desc, NULL));
+        break;  // mismatch, invoke noSuchMethod
+      }
+      if (is_dynamic_call) {
+        function = cls.LookupDynamicFunction(demangled_target_name);
+        if (!function.IsNull()) {
+          ASSERT(!function.AreValidArguments(args_desc, NULL));
+          break;  // mismatch, invoke noSuchMethod
+        }
+      }
+
+      // If there is a getter we need to call-through-getter.
+      if (is_dynamic_call) {
+        function = cls.LookupDynamicFunction(dyn_getter_name);
+      }
+      if (function.IsNull()) {
+        function = cls.LookupDynamicFunction(getter_name);
+      }
+      if (!function.IsNull()) {
+        const Array& getter_arguments = Array::Handle(Array::New(1));
+        getter_arguments.SetAt(0, receiver);
+        const Object& getter_result = Object::Handle(
+            zone, DartEntry::InvokeFunction(function, getter_arguments));
+        if (getter_result.IsError()) {
+          return getter_result.raw();
+        }
+        ASSERT(getter_result.IsNull() || getter_result.IsInstance());
+
+        orig_arguments.SetAt(args_desc.FirstArgIndex(), getter_result);
+        auto& result = Object::Handle(
+            zone,
+            DartEntry::ResolveCallable(orig_arguments, orig_arguments_desc));
+        if (result.IsError()) {
+          return result.raw();
+        }
+        function ^= result.raw();
+        if (is_dynamic_call && !function.IsNull() &&
+            !function.CanReceiveDynamicInvocation()) {
+          result = function.DoArgumentTypesMatch(orig_arguments, args_desc);
+          if (result.IsError()) {
+            return result.raw();
+          }
+        }
+        result = DartEntry::InvokeCallable(function, orig_arguments,
+                                           orig_arguments_desc);
+        return result.raw();
+      }
+      cls = cls.SuperClass();
+    }
+  }
+
+  const Object& result = Object::Handle(
+      zone, DartEntry::InvokeNoSuchMethod(receiver, demangled_target_name,
+                                          orig_arguments, orig_arguments_desc));
+  return result.raw();
+}
+
 // Invoke appropriate noSuchMethod or closure from getter.
 // Arg0: receiver
 // Arg1: ICData or MegamorphicCache
@@ -2177,119 +2342,12 @@
     target_name = MegamorphicCache::Cast(ic_data_or_cache).target_name();
   }
 
-  const bool is_dynamic_call =
-      Function::IsDynamicInvocationForwarderName(target_name);
-  if (is_dynamic_call) {
-    target_name = Function::DemangleDynamicInvocationForwarderName(target_name);
-  }
-
-  Class& cls = Class::Handle(zone, receiver.clazz());
-  Function& function = Function::Handle(zone);
-
-  // Dart distinguishes getters and regular methods and allows their calls
-  // to mix with conversions, and its selectors are independent of arity. So do
-  // a zigzagged lookup to see if this call failed because of an arity mismatch,
-  // need for conversion, or there really is no such method.
-
-#define NO_SUCH_METHOD()                                                       \
-  const Object& result = Object::Handle(                                       \
-      zone, DartEntry::InvokeNoSuchMethod(                                     \
-                receiver, target_name, orig_arguments, orig_arguments_desc));  \
-  ThrowIfError(result);                                                        \
+  const auto& result = Object::Handle(
+      zone,
+      InvokeCallThroughGetterOrNoSuchMethod(
+          zone, receiver, target_name, orig_arguments, orig_arguments_desc));
+  ThrowIfError(result);
   arguments.SetReturn(result);
-
-#define CLOSURIZE(some_function)                                               \
-  const Function& closure_function =                                           \
-      Function::Handle(zone, some_function.ImplicitClosureFunction());         \
-  const Object& result = Object::Handle(                                       \
-      zone, closure_function.ImplicitInstanceClosure(receiver));               \
-  arguments.SetReturn(result);
-
-  const bool is_getter = Field::IsGetterName(target_name);
-  if (is_getter) {
-    // o.foo (o.get:foo) failed, closurize o.foo() if it exists.
-    String& field_name =
-        String::Handle(zone, Field::NameFromGetter(target_name));
-    while (!cls.IsNull()) {
-      function = cls.LookupDynamicFunction(field_name);
-      if (!function.IsNull()) {
-        CLOSURIZE(function);
-        return;
-      }
-      cls = cls.SuperClass();
-    }
-
-    // Fall through for noSuchMethod
-  } else {
-    // o.foo(...) failed, invoke noSuchMethod is foo exists but has the wrong
-    // number of arguments, or try (o.foo).call(...)
-
-    if ((target_name.raw() == Symbols::Call().raw()) && receiver.IsClosure()) {
-      // Special case: closures are implemented with a call getter instead of a
-      // call method and with lazy dispatchers the field-invocation-dispatcher
-      // would perform the closure call.
-      auto& result = Object::Handle(
-          zone,
-          DartEntry::ResolveCallable(orig_arguments, orig_arguments_desc));
-      ThrowIfError(result);
-      const Function& callable_function =
-          Function::Handle(zone, Function::RawCast(result.raw()));
-      if (is_dynamic_call && !callable_function.IsNull()) {
-        // TODO(dartbug.com/40813): Move checks that are currently compiled
-        // in the closure body to here as they are also moved to
-        // FlowGraphBuilder::BuildGraphOfInvokeFieldDispatcher.
-      }
-      result = DartEntry::InvokeCallable(callable_function, orig_arguments,
-                                         orig_arguments_desc);
-      ThrowIfError(result);
-      arguments.SetReturn(result);
-      return;
-    }
-
-    const String& getter_name =
-        String::Handle(zone, Field::GetterName(target_name));
-    ArgumentsDescriptor args_desc(orig_arguments_desc);
-    while (!cls.IsNull()) {
-      function = cls.LookupDynamicFunction(target_name);
-      if (!function.IsNull()) {
-        ASSERT(!function.AreValidArguments(args_desc, NULL));
-        break;  // mismatch, invoke noSuchMethod
-      }
-      function = cls.LookupDynamicFunction(getter_name);
-      if (!function.IsNull()) {
-        const Array& getter_arguments = Array::Handle(Array::New(1));
-        getter_arguments.SetAt(0, receiver);
-        const Object& getter_result = Object::Handle(
-            zone, DartEntry::InvokeFunction(function, getter_arguments));
-        ThrowIfError(getter_result);
-        ASSERT(getter_result.IsNull() || getter_result.IsInstance());
-
-        orig_arguments.SetAt(args_desc.FirstArgIndex(), getter_result);
-        auto& call_result = Object::Handle(
-            zone,
-            DartEntry::ResolveCallable(orig_arguments, orig_arguments_desc));
-        ThrowIfError(call_result);
-        const Function& callable_function =
-            Function::Handle(zone, Function::RawCast(call_result.raw()));
-        if (is_dynamic_call && !callable_function.IsNull()) {
-          // TODO(dartbug.com/40813): Move checks that are currently compiled
-          // in the closure body to here as they are also moved to
-          // FlowGraphBuilder::BuildGraphOfInvokeFieldDispatcher.
-        }
-        call_result = DartEntry::InvokeCallable(
-            callable_function, orig_arguments, orig_arguments_desc);
-        ThrowIfError(call_result);
-        arguments.SetReturn(call_result);
-        return;
-      }
-      cls = cls.SuperClass();
-    }
-  }
-
-  NO_SUCH_METHOD();
-
-#undef NO_SUCH_METHOD
-#undef CLOSURIZE
 }
 
 // Invoke appropriate noSuchMethod function.
@@ -2322,22 +2380,32 @@
   arguments.SetReturn(result);
 }
 
-// Invoke appropriate noSuchMethod function.
+// Invoke appropriate noSuchMethod function (or in the case of no lazy
+// dispatchers, walk the receiver to find the correct method to call).
 // Arg0: receiver
-// Arg1: arguments descriptor array.
-// Arg2: arguments array.
-// Arg3: function name.
+// Arg1: function name.
+// Arg2: arguments descriptor array.
+// Arg3: arguments array.
 DEFINE_RUNTIME_ENTRY(InvokeNoSuchMethod, 4) {
   ASSERT(FLAG_enable_interpreter);
   const Instance& receiver = Instance::CheckedHandle(zone, arguments.ArgAt(0));
-  const Array& orig_arguments_desc =
-      Array::CheckedHandle(zone, arguments.ArgAt(1));
-  const Array& orig_arguments = Array::CheckedHandle(zone, arguments.ArgAt(2));
   const String& original_function_name =
-      String::CheckedHandle(zone, arguments.ArgAt(3));
+      String::CheckedHandle(zone, arguments.ArgAt(1));
+  const Array& orig_arguments_desc =
+      Array::CheckedHandle(zone, arguments.ArgAt(2));
+  const Array& orig_arguments = Array::CheckedHandle(zone, arguments.ArgAt(3));
 
-  const Object& result = Object::Handle(DartEntry::InvokeNoSuchMethod(
-      receiver, original_function_name, orig_arguments, orig_arguments_desc));
+  auto& result = Object::Handle(zone);
+  if (!FLAG_lazy_dispatchers) {
+    // Failing to find the method could be due to the lack of lazy invoke field
+    // dispatchers, so attempt a deeper search before calling noSuchMethod.
+    result = InvokeCallThroughGetterOrNoSuchMethod(
+        zone, receiver, original_function_name, orig_arguments,
+        orig_arguments_desc);
+  } else {
+    result = DartEntry::InvokeNoSuchMethod(receiver, original_function_name,
+                                           orig_arguments, orig_arguments_desc);
+  }
   ThrowIfError(result);
   arguments.SetReturn(result);
 }
@@ -3240,6 +3308,12 @@
   Exceptions::ThrowLateInitializationError(String::Handle(field.name()));
 }
 
+DEFINE_RUNTIME_ENTRY(NotLoaded, 0) {
+  // We could just use a trap instruction in the stub, but we get better stack
+  // traces when there is an exit frame.
+  FATAL("Not loaded");
+}
+
 // Use expected function signatures to help MSVC compiler resolve overloading.
 typedef double (*UnaryMathCFunction)(double x);
 typedef double (*BinaryMathCFunction)(double x, double y);
diff --git a/runtime/vm/runtime_entry_list.h b/runtime/vm/runtime_entry_list.h
index 5b83f13..8945038 100644
--- a/runtime/vm/runtime_entry_list.h
+++ b/runtime/vm/runtime_entry_list.h
@@ -57,7 +57,8 @@
   V(LateInitializationError)                                                   \
   V(CompileFunction)                                                           \
   V(CompileInterpretedFunction)                                                \
-  V(SwitchableCallMiss)
+  V(SwitchableCallMiss)                                                        \
+  V(NotLoaded)
 
 // Note: Leaf runtime function have C linkage, so they cannot pass C++ struct
 // values like ObjectPtr.
diff --git a/runtime/vm/scopes.cc b/runtime/vm/scopes.cc
index ca297b7..cff9a82 100644
--- a/runtime/vm/scopes.cc
+++ b/runtime/vm/scopes.cc
@@ -212,6 +212,7 @@
   LocalVariable* await_jump_var = nullptr;
   LocalVariable* async_completer = nullptr;
   LocalVariable* controller = nullptr;
+  LocalVariable* chained_future = nullptr;
   for (intptr_t i = 0; i < num_variables(); i++) {
     LocalVariable* variable = VariableAt(i);
     if (variable->owner() == this) {
@@ -222,6 +223,8 @@
           async_completer = variable;
         } else if (variable->name().Equals(Symbols::Controller())) {
           controller = variable;
+        } else if (variable->is_chained_future()) {
+          chained_future = variable;
         }
       }
     }
@@ -243,6 +246,11 @@
     *found_captured_variables = true;
     ASSERT(controller->index().value() == Context::kControllerIndex);
   }
+  if (chained_future != nullptr) {
+    AllocateContextVariable(chained_future, &context_owner);
+    *found_captured_variables = true;
+    ASSERT(chained_future->index().value() == Context::kChainedFutureIndex);
+  }
 
   while (pos < num_parameters) {
     LocalVariable* parameter = VariableAt(pos);
@@ -273,7 +281,7 @@
       if (variable->is_captured()) {
         // Skip the two variables already pre-allocated above.
         if (variable != await_jump_var && variable != async_completer &&
-            variable != controller) {
+            variable != controller && variable != chained_future) {
           AllocateContextVariable(variable, &context_owner);
           *found_captured_variables = true;
         }
diff --git a/runtime/vm/scopes.h b/runtime/vm/scopes.h
index fd012c6..f31a3a0 100644
--- a/runtime/vm/scopes.h
+++ b/runtime/vm/scopes.h
@@ -93,6 +93,7 @@
         is_forced_stack_(false),
         is_explicit_covariant_parameter_(false),
         is_late_(false),
+        is_chained_future_(false),
         late_init_offset_(0),
         type_check_mode_(kDoTypeCheck),
         index_() {
@@ -131,6 +132,9 @@
   bool is_late() const { return is_late_; }
   void set_is_late() { is_late_ = true; }
 
+  bool is_chained_future() const { return is_chained_future_; }
+  void set_is_chained_future() { is_chained_future_ = true; }
+
   intptr_t late_init_offset() const { return late_init_offset_; }
   void set_late_init_offset(intptr_t late_init_offset) {
     late_init_offset_ = late_init_offset;
@@ -220,6 +224,7 @@
   bool is_forced_stack_;
   bool is_explicit_covariant_parameter_;
   bool is_late_;
+  bool is_chained_future_;
   intptr_t late_init_offset_;
   TypeCheckMode type_check_mode_;
   VariableIndex index_;
diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc
index c16ed19..a2a6128 100644
--- a/runtime/vm/service.cc
+++ b/runtime/vm/service.cc
@@ -1117,6 +1117,9 @@
     }
     // Ignore events when no one is listening to the event stream.
     return;
+  } else if (event->stream_info() != NULL &&
+             FLAG_warn_on_pause_with_no_debugger && event->IsPause()) {
+    ReportPauseOnConsole(event);
   }
   if (!ServiceIsolate::IsRunning()) {
     return;
@@ -2834,9 +2837,12 @@
     return true;
   }
 
+  const uint8_t* kernel_buffer = Service::dart_library_kernel();
+  const intptr_t kernel_buffer_len = Service::dart_library_kernel_length();
+
   Dart_KernelCompilationResult compilation_result =
       KernelIsolate::CompileExpressionToKernel(
-          js->LookupParam("expression"),
+          kernel_buffer, kernel_buffer_len, js->LookupParam("expression"),
           Array::Handle(Array::MakeFixedLength(params)),
           Array::Handle(Array::MakeFixedLength(type_params)),
           js->LookupParam("libraryUri"), js->LookupParam("klass"), is_static);
@@ -4059,11 +4065,7 @@
   return true;
 }
 
-static const MethodParameter* get_process_memory_usage_params[] = {
-    NULL,
-};
-
-static bool GetProcessMemoryUsage(Thread* thread, JSONStream* js) {
+static intptr_t GetProcessMemoryUsageHelper(JSONStream* js) {
   JSONObject response(js);
   response.AddProperty("type", "ProcessMemoryUsage");
 
@@ -4073,41 +4075,55 @@
   rss.AddProperty64("size", Service::CurrentRSS());
   JSONArray rss_children(&rss, "children");
 
+  JSONObject vm(&rss_children);
+  intptr_t vm_size = 0;
   {
-    JSONObject profiler(&rss_children);
-    profiler.AddProperty("name", "Profiler");
-    profiler.AddProperty("description", "Samples from the Dart VM's profiler");
-    profiler.AddProperty64("size", Profiler::Size());
-    JSONArray(&profiler, "children");
-  }
+    JSONArray vm_children(&vm, "children");
+
+    {
+      JSONObject profiler(&vm_children);
+      profiler.AddProperty("name", "Profiler");
+      profiler.AddProperty("description",
+                           "Samples from the Dart VM's profiler");
+      intptr_t size = Profiler::Size();
+      vm_size += size;
+      profiler.AddProperty64("size", size);
+      JSONArray(&profiler, "children");
+    }
 
   {
-    JSONObject timeline(&rss_children);
+    JSONObject timeline(&vm_children);
     timeline.AddProperty("name", "Timeline");
     timeline.AddProperty(
         "description",
         "Timeline events from dart:developer and Dart_TimelineEvent");
-    timeline.AddProperty64("size", Timeline::recorder()->Size());
+    intptr_t size = Timeline::recorder()->Size();
+    vm_size += size;
+    timeline.AddProperty64("size", size);
     JSONArray(&timeline, "children");
   }
 
   {
-    JSONObject zone(&rss_children);
+    JSONObject zone(&vm_children);
     zone.AddProperty("name", "Zone");
     zone.AddProperty("description", "Arena allocation in the Dart VM");
-    zone.AddProperty64("size", Zone::Size());
+    intptr_t size = Zone::Size();
+    vm_size += size;
+    zone.AddProperty64("size", size);
     JSONArray(&zone, "children");
   }
 
   {
-    JSONObject semi(&rss_children);
+    JSONObject semi(&vm_children);
     semi.AddProperty("name", "SemiSpace Cache");
     semi.AddProperty("description", "Cached heap regions");
-    semi.AddProperty64("size", SemiSpace::CachedSize());
+    intptr_t size = SemiSpace::CachedSize();
+    vm_size += size;
+    semi.AddProperty64("size", size);
     JSONArray(&semi, "children");
   }
 
-  IsolateGroup::ForEach([&rss_children](IsolateGroup* isolate_group) {
+  IsolateGroup::ForEach([&vm_children, &vm_size](IsolateGroup* isolate_group) {
     // Note: new_space()->CapacityInWords() includes memory that hasn't been
     // allocated from the OS yet.
     int64_t capacity = (isolate_group->heap()->new_space()->UsedInWords() +
@@ -4116,10 +4132,11 @@
     int64_t used = isolate_group->heap()->TotalUsedInWords() * kWordSize;
     int64_t free = capacity - used;
 
-    JSONObject group(&rss_children);
+    JSONObject group(&vm_children);
     group.AddPropertyF("name", "IsolateGroup %s",
                        isolate_group->source()->name);
     group.AddProperty("description", "Dart heap capacity");
+    vm_size += capacity;
     group.AddProperty64("size", capacity);
     JSONArray group_children(&group, "children");
 
@@ -4139,7 +4156,21 @@
       JSONArray(&jsfree, "children");
     }
   });
+  }  // vm_children
 
+  vm.AddProperty("name", "Dart VM");
+  vm.AddProperty("description", "");
+  vm.AddProperty64("size", vm_size);
+
+  return vm_size;
+}
+
+static const MethodParameter* get_process_memory_usage_params[] = {
+    NULL,
+};
+
+static bool GetProcessMemoryUsage(Thread* thread, JSONStream* js) {
+  GetProcessMemoryUsageHelper(js);
   return true;
 }
 
@@ -4561,6 +4592,11 @@
       }
     });
   }
+  {
+    JSONStream discard_js;
+    intptr_t vm_memory = GetProcessMemoryUsageHelper(&discard_js);
+    jsobj.AddProperty("_currentMemory", vm_memory);
+  }
 }
 
 static bool GetVM(Thread* thread, JSONStream* js) {
diff --git a/runtime/vm/snapshot.h b/runtime/vm/snapshot.h
index e78bd6a..db0775c 100644
--- a/runtime/vm/snapshot.h
+++ b/runtime/vm/snapshot.h
@@ -168,6 +168,14 @@
   DISALLOW_COPY_AND_ASSIGN(Snapshot);
 };
 
+inline static bool IsSnapshotCompatible(Snapshot::Kind vm_kind,
+                                        Snapshot::Kind isolate_kind) {
+  if (vm_kind == isolate_kind) return true;
+  if (vm_kind == Snapshot::kFull && isolate_kind == Snapshot::kFullJIT)
+    return true;
+  return Snapshot::IsFull(isolate_kind);
+}
+
 class BaseReader {
  public:
   BaseReader(const uint8_t* buffer, intptr_t size) : stream_(buffer, size) {}
diff --git a/runtime/vm/stack_trace.cc b/runtime/vm/stack_trace.cc
index a9df9e1..c2b7828 100644
--- a/runtime/vm/stack_trace.cc
+++ b/runtime/vm/stack_trace.cc
@@ -104,6 +104,7 @@
   explicit CallerClosureFinder(Zone* zone)
       : receiver_context_(Context::Handle(zone)),
         receiver_function_(Function::Handle(zone)),
+        parent_function_(Function::Handle(zone)),
         context_entry_(Object::Handle(zone)),
         is_sync(Object::Handle(zone)),
         future_(Object::Handle(zone)),
@@ -130,7 +131,8 @@
         var_data_field(Field::Handle(zone)),
         state_field(Field::Handle(zone)),
         on_data_field(Field::Handle(zone)),
-        state_data_field(Field::Handle(zone)) {
+        state_data_field(Field::Handle(zone)),
+        future_timeout_method_(Function::Handle(zone)) {
     const auto& async_lib = Library::Handle(zone, Library::AsyncLibrary());
     // Look up classes:
     // - async:
@@ -195,6 +197,11 @@
     state_data_field =
         stream_iterator_class.LookupFieldAllowPrivate(Symbols::_stateData());
     ASSERT(!state_data_field.IsNull());
+
+    // Functions:
+    future_timeout_method_ =
+        future_impl_class.LookupFunction(Symbols::timeout());
+    ASSERT(!future_timeout_method_.IsNull());
   }
 
   ClosurePtr GetCallerInFutureImpl(const Object& future_) {
@@ -285,6 +292,13 @@
       return FindCallerInAsyncClosure(receiver_context_);
     } else if (receiver_function_.IsAsyncGenClosure()) {
       return FindCallerInAsyncGenClosure(receiver_context_);
+    } else if (receiver_function_.IsLocalFunction()) {
+      parent_function_ = receiver_function_.parent_function();
+      if (parent_function_.recognized_kind() ==
+          MethodRecognizer::kFutureTimeout) {
+        context_entry_ = receiver_context_.At(Context::kChainedFutureIndex);
+        return GetCallerInFutureImpl(context_entry_);
+      }
     }
 
     return Closure::null();
@@ -318,6 +332,7 @@
  private:
   Context& receiver_context_;
   Function& receiver_function_;
+  Function& parent_function_;
 
   Object& context_entry_;
   Object& is_sync;
@@ -348,6 +363,8 @@
   Field& state_field;
   Field& on_data_field;
   Field& state_data_field;
+
+  Function& future_timeout_method_;
 };
 
 void StackTraceUtils::CollectFramesLazy(
diff --git a/runtime/vm/stub_code.cc b/runtime/vm/stub_code.cc
index 58bba60..1c9ff6c6 100644
--- a/runtime/vm/stub_code.cc
+++ b/runtime/vm/stub_code.cc
@@ -160,7 +160,8 @@
   Thread* thread = Thread::Current();
   auto object_store = thread->isolate()->object_store();
   Zone* zone = thread->zone();
-  const Error& error = Error::Handle(zone, cls.EnsureIsFinalized(thread));
+  const Error& error =
+      Error::Handle(zone, cls.EnsureIsAllocateFinalized(thread));
   ASSERT(error.IsNull());
   if (cls.id() == kArrayCid) {
     return object_store->allocate_array_stub();
@@ -220,7 +221,7 @@
       }
     };
     auto bg_compiler_fun = [&]() {
-      ForceGrowthSafepointOperationScope safepoint_scope(thread);
+      ASSERT(Thread::Current()->IsAtSafepoint());
       stub = cls.allocation_stub();
       // Check if stub was already generated.
       if (!stub.IsNull()) {
diff --git a/runtime/vm/stub_code_list.h b/runtime/vm/stub_code_list.h
index 8343572..f759ea8 100644
--- a/runtime/vm/stub_code_list.h
+++ b/runtime/vm/stub_code_list.h
@@ -76,6 +76,7 @@
   V(CallClosureNoSuchMethod)                                                   \
   V(FrameAwaitingMaterialization)                                              \
   V(AsynchronousGapMarker)                                                     \
+  V(NotLoaded)                                                                 \
   V(DispatchTableNullError)                                                    \
   V(NullErrorSharedWithFPURegs)                                                \
   V(NullErrorSharedWithoutFPURegs)                                             \
diff --git a/runtime/vm/symbols.h b/runtime/vm/symbols.h
index 7e38f9e..529f4fa 100644
--- a/runtime/vm/symbols.h
+++ b/runtime/vm/symbols.h
@@ -269,6 +269,7 @@
   V(Struct, "Struct")                                                          \
   V(StructFromPointer, "#fromPointer")                                         \
   V(SubtypeTestCache, "SubtypeTestCache")                                      \
+  V(LoadingUnit, "LoadingUnit")                                                \
   V(SwitchExpr, ":switch_expr")                                                \
   V(Symbol, "Symbol")                                                          \
   V(SymbolCtor, "Symbol.")                                                     \
@@ -362,6 +363,7 @@
   V(_GrowableList, "_GrowableList")                                            \
   V(_GrowableListFactory, "_GrowableList.")                                    \
   V(_GrowableListFilledFactory, "_GrowableList.filled")                        \
+  V(_GrowableListGenerateFactory, "_GrowableList.generate")                    \
   V(_GrowableListWithData, "_GrowableList._withData")                          \
   V(_ImmutableList, "_ImmutableList")                                          \
   V(_Int16ArrayFactory, "Int16List.")                                          \
@@ -390,6 +392,7 @@
   V(_List, "_List")                                                            \
   V(_ListFactory, "_List.")                                                    \
   V(_ListFilledFactory, "_List.filled")                                        \
+  V(_ListGenerateFactory, "_List.generate")                                    \
   V(_MethodMirror, "_MethodMirror")                                            \
   V(_Mint, "_Mint")                                                            \
   V(_MirrorReference, "_MirrorReference")                                      \
@@ -490,6 +493,7 @@
   V(start_index_param, ":start_index_param")                                   \
   V(string_param, ":string_param")                                             \
   V(string_param_length, ":string_param_length")                               \
+  V(timeout, "timeout")                                                        \
   V(toString, "toString")                                                      \
   V(vm_prefer_inline, "vm:prefer-inline")                                      \
   V(vm_entry_point, "vm:entry-point")                                          \
diff --git a/runtime/vm/tagged_pointer.h b/runtime/vm/tagged_pointer.h
index 9b92514..b81e29d 100644
--- a/runtime/vm/tagged_pointer.h
+++ b/runtime/vm/tagged_pointer.h
@@ -263,6 +263,7 @@
 DEFINE_TAGGED_POINTER(ICData, CallSiteData)
 DEFINE_TAGGED_POINTER(MegamorphicCache, CallSiteData)
 DEFINE_TAGGED_POINTER(SubtypeTestCache, Object)
+DEFINE_TAGGED_POINTER(LoadingUnit, Object)
 DEFINE_TAGGED_POINTER(Error, Object)
 DEFINE_TAGGED_POINTER(ApiError, Error)
 DEFINE_TAGGED_POINTER(LanguageError, Error)
diff --git a/runtime/vm/type_testing_stubs.cc b/runtime/vm/type_testing_stubs.cc
index b07969d..fe40775 100644
--- a/runtime/vm/type_testing_stubs.cc
+++ b/runtime/vm/type_testing_stubs.cc
@@ -226,8 +226,8 @@
   //   a) We allocate an instructions object, which might cause us to
   //      temporarily flip page protections from (RX -> RW -> RX).
   //
-  thread->isolate_group()->RunWithStoppedMutators(
-      install_code_fun, install_code_fun, /*use_force_growth=*/true);
+  thread->isolate_group()->RunWithStoppedMutators(install_code_fun,
+                                                  /*use_force_growth=*/true);
 
   Code::NotifyCodeObservers(name, code, /*optimized=*/false);
 
@@ -270,6 +270,14 @@
     __ Ret();
     __ Bind(&continue_checking);
 
+  } else if (type.IsObjectType()) {
+    ASSERT(type.IsNonNullable() && Isolate::Current()->null_safety());
+    compiler::Label continue_checking;
+    __ CompareObject(TypeTestABI::kInstanceReg, Object::null_object());
+    __ BranchIf(EQUAL, &continue_checking);
+    __ Ret();
+    __ Bind(&continue_checking);
+
   } else {
     // TODO(kustermann): Make more fast cases, e.g. Type::Number()
     // is implemented by Smi.
@@ -477,7 +485,6 @@
     // ("Right Legacy", "Right Nullable" rules).
     if (Isolate::Current()->null_safety() && !type_arg.IsNullable() &&
         !type_arg.IsLegacy()) {
-      compiler::Label skip_nullable_check;
       // Nullable type is not a subtype of non-nullable type.
       // TODO(dartbug.com/40736): Allocate a register for instance type argument
       // and avoid reloading it.
@@ -489,10 +496,6 @@
       __ CompareTypeNullabilityWith(TTSInternalRegs::kScratchReg,
                                     compiler::target::Nullability::kNullable);
       __ BranchIf(EQUAL, check_failed);
-
-      if (type_arg.IsTypeParameter()) {
-        __ Bind(&skip_nullable_check);
-      }
     }
   }
 
diff --git a/runtime/vm/type_testing_stubs_test.cc b/runtime/vm/type_testing_stubs_test.cc
index 1094bb4..f6afdad 100644
--- a/runtime/vm/type_testing_stubs_test.cc
+++ b/runtime/vm/type_testing_stubs_test.cc
@@ -410,6 +410,17 @@
              ExpectLazilyFailedViaSTC, ExpectFailedViaSTC);
   RunTTSTest(obj_b2, type_dynamic_t, tav_object, tav_null,
              ExpectLazilyHandledViaSTC, ExpectHandledViaSTC);
+
+  // obj as Object (with null safety)
+  Isolate* isolate = Isolate::Current();
+  if (isolate->null_safety()) {
+    auto& type_non_nullable_object =
+        Type::Handle(isolate->object_store()->non_nullable_object_type());
+    RunTTSTest(obj_a, type_non_nullable_object, tav_null, tav_null,
+               ExpectLazilyHandledViaTTS, ExpectHandledViaTTS);
+    RunTTSTest(Object::null_object(), type_non_nullable_object, tav_null,
+               tav_null, ExpectLazilyFailedViaTTS, ExpectFailedViaTTS);
+  }
 }
 
 ISOLATE_UNIT_TEST_CASE(TTS_GenericSubtypeRangeCheck) {
diff --git a/runtime/vm/unit_test.cc b/runtime/vm/unit_test.cc
index bcc7d99..b6cb15e 100644
--- a/runtime/vm/unit_test.cc
+++ b/runtime/vm/unit_test.cc
@@ -115,6 +115,7 @@
   char* err;
   Dart_IsolateFlags api_flags;
   Isolate::FlagsInitialize(&api_flags);
+  api_flags.null_safety = (FLAG_sound_null_safety == kNullSafetyOptionStrong);
   Dart_Isolate isolate = NULL;
   if (len == 0) {
     isolate = Dart_CreateIsolateGroup(
@@ -630,6 +631,7 @@
   } else {
     Dart_KernelCompilationResult compilation_result =
         KernelIsolate::CompileExpressionToKernel(
+            /* platform_kernel= */ nullptr, /* platform_kernel_size= */ 0,
             expr.ToCString(), param_names, Array::empty_array(),
             String::Handle(lib.url()).ToCString(), /* klass=*/nullptr,
             /* is_static= */ true);
diff --git a/samples-dev/swarm/swarm_ui_lib/base/Size.dart b/samples-dev/swarm/swarm_ui_lib/base/Size.dart
index 920b4a3..08fc365 100644
--- a/samples-dev/swarm/swarm_ui_lib/base/Size.dart
+++ b/samples-dev/swarm/swarm_ui_lib/base/Size.dart
@@ -13,7 +13,7 @@
 
   Size(num this.width, num this.height) {}
 
-  bool operator ==(Size other) {
+  bool operator ==(covariant Size other) {
     return other != null && width == other.width && height == other.height;
   }
 
diff --git a/samples-dev/swarm/swarm_ui_lib/touch/Geometry.dart b/samples-dev/swarm/swarm_ui_lib/touch/Geometry.dart
index 6f033c5..2686432 100644
--- a/samples-dev/swarm/swarm_ui_lib/touch/Geometry.dart
+++ b/samples-dev/swarm/swarm_ui_lib/touch/Geometry.dart
@@ -36,7 +36,7 @@
     return Math.sqrt(dx * dx + dy * dy);
   }
 
-  bool operator ==(Coordinate other) {
+  bool operator ==(covariant Coordinate other) {
     return other != null && x == other.x && y == other.y;
   }
 
@@ -73,7 +73,7 @@
     return end - start;
   }
 
-  bool operator ==(Interval other) {
+  bool operator ==(covariant Interval other) {
     return other != null && other.start == start && other.end == end;
   }
 
diff --git a/sdk/BUILD.gn b/sdk/BUILD.gn
index bd50f42..a032fcd 100644
--- a/sdk/BUILD.gn
+++ b/sdk/BUILD.gn
@@ -47,6 +47,7 @@
 # ........analysis_server.dart.snapshot
 # ........dart2js.dart.snapshot
 # ........dartanalyzer.dart.snapshot
+# ........dds.dart.snapshot
 # ........dartdev.dart.snapshot
 # ........dartdoc.dart.snapshot
 # ........dartfmt.dart.snapshot
@@ -134,6 +135,10 @@
     "../utils/dartfmt",
   ],
   [
+    "dds",
+    "../utils/dds:generate_dds_snapshot",
+  ],
+  [
     "pub",
     "../utils/pub",
   ],
@@ -183,6 +188,10 @@
     "../utils/dartfmt",
   ],
   [
+    "dds",
+    "../utils/dds:generate_dds_snapshot",
+  ],
+  [
     "kernel_worker",
     "../utils/bazel:kernel_worker",
   ],
@@ -631,27 +640,32 @@
   outputs = [ "$root_out_dir/dart-sdk/lib/_internal/{{source_file_part}}" ]
 }
 
-# Copies DDC's SDK outline .dill to lib/_internal
-copy("copy_dev_compiler_outline") {
+# Copies DDC's SDK weak outline .dill to lib/_internal
+# TODO(nshahan) Fix the outline to be consistent and merge with below as a
+# breaking change.
+copy("copy_dev_compiler_weak_outline") {
   visibility = [ ":copy_dev_compiler_sdk" ]
   deps = [
     ":copy_libraries",
     "../utils/dartdevc:dartdevc_platform",
   ]
   sources = [ "$root_out_dir/ddc_outline.dill" ]
-
-  # TODO(nshahan) Fix the name here to be consistent and merge with below.
   outputs = [ "$root_out_dir/dart-sdk/lib/_internal/ddc_sdk.dill" ]
 }
 
-# Copies DDC's SDK outline .dill with sound null safety to lib/_internal
-copy("copy_dev_compiler_outline_sound") {
-  visibility = [ "../utils/dartdevc:dartdevc_test" ]
+# Copies DDC's SDK full and outline .dill files to lib/_internal.
+copy("copy_dev_compiler_dills") {
+  visibility = [ ":copy_dev_compiler_sdk" ]
   deps = [
     ":copy_libraries",
+    "../utils/dartdevc:dartdevc_platform",
     "../utils/dartdevc:dartdevc_platform_sound",
   ]
-  sources = [ "$root_out_dir/ddc_outline_sound.dill" ]
+  sources = [
+    "$root_out_dir/ddc_outline_sound.dill",
+    "$root_out_dir/ddc_platform.dill",
+    "$root_out_dir/ddc_platform_sound.dill",
+  ]
   outputs = [ "$root_out_dir/dart-sdk/lib/_internal/{{source_file_part}}" ]
 }
 
@@ -731,9 +745,10 @@
 group("copy_dev_compiler_sdk") {
   visibility = [ ":create_full_sdk" ]
   public_deps = [
+    ":copy_dev_compiler_dills",
     ":copy_dev_compiler_js",
-    ":copy_dev_compiler_outline",
     ":copy_dev_compiler_tools",
+    ":copy_dev_compiler_weak_outline",
   ]
 }
 
diff --git a/sdk/lib/_http/http_headers.dart b/sdk/lib/_http/http_headers.dart
index a2edfbd..73ed901 100644
--- a/sdk/lib/_http/http_headers.dart
+++ b/sdk/lib/_http/http_headers.dart
@@ -646,8 +646,7 @@
   }
 
   String _originalHeaderName(String name) {
-    // TODO: Update syntax to_originalHeaderNames?[name].
-    return _originalHeaderNames?.[name] ?? name;
+    return _originalHeaderNames?[name] ?? name;
   }
 }
 
diff --git a/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart b/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart
index 2e605a2..66c6bb1 100644
--- a/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart
+++ b/sdk/lib/_internal/js_dev_runtime/patch/internal_patch.dart
@@ -11,7 +11,8 @@
 import 'dart:_runtime' as dart;
 
 @patch
-bool typeAcceptsNull<T>() => !dart.strictNullSafety || null is T;
+bool typeAcceptsNull<T>() =>
+    !dart.compileTimeFlag('soundNullSafety') || null is T;
 
 @patch
 class Symbol implements core.Symbol {
diff --git a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart
index ba418a4..6b33186 100644
--- a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart
+++ b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart
@@ -25,23 +25,21 @@
 }
 
 final _nullFailedSet = JS('!', 'new Set()');
+
+String _nullFailedMessage(variableName) =>
+    'A null value was passed into a non-nullable parameter: $variableName.';
+
 // Run-time null safety assertion per:
 // https://github.com/dart-lang/language/blob/master/accepted/future-releases/nnbd/feature-specification.md#automatic-debug-assertion-insertion
 nullFailed(String? fileUri, int? line, int? column, String? variable) {
-  if (strictNullSafety) {
-    throw AssertionErrorImpl(
-        'A null value was passed into a non-nullable parameter $variable',
-        fileUri,
-        line,
-        column,
-        '$variable != null');
-  } else {
-    var key = '$fileUri:$line:$column';
-    if (!JS('!', '#.has(#)', _nullFailedSet, key)) {
-      JS('', '#.add(#)', _nullFailedSet, key);
-      _nullWarn(
-          'A null value was passed into a non-nullable parameter $variable');
-    }
+  if (_nonNullAsserts) {
+    throw AssertionErrorImpl(_nullFailedMessage(variable), fileUri, line,
+        column, '$variable != null');
+  }
+  var key = '$fileUri:$line:$column';
+  if (!JS('!', '#.has(#)', _nullFailedSet, key)) {
+    JS('', '#.add(#)', _nullFailedSet, key);
+    _nullWarn(_nullFailedMessage(variable));
   }
 }
 
diff --git a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart
index fd9a7d4..489795f 100644
--- a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart
+++ b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/operations.dart
@@ -185,7 +185,7 @@
     if (missingRequired.isNotEmpty) {
       var error = "Dynamic call with missing required named arguments: "
           "${missingRequired.join(', ')}.";
-      if (!strictNullSafety) {
+      if (!compileTimeFlag('soundNullSafety')) {
         _nullWarn(error);
       } else {
         return error;
@@ -430,7 +430,7 @@
 cast(obj, type) {
   // We hoist the common case where null is checked against another type here
   // for better performance.
-  if (obj == null && !strictNullSafety) {
+  if (obj == null && !compileTimeFlag('soundNullSafety')) {
     // Check the null comparison cache to avoid emitting repeated warnings.
     _nullWarnOnType(type);
     return obj;
@@ -450,11 +450,13 @@
 bool dtest(obj) {
   // Only throw an AssertionError in weak mode for compatibility. Strong mode
   // should throw a TypeError.
-  if (obj is! bool) booleanConversionFailed(strictNullSafety ? obj : test(obj));
+  if (obj is! bool)
+    booleanConversionFailed(
+        compileTimeFlag('soundNullSafety') ? obj : test(obj));
   return obj;
 }
 
-void booleanConversionFailed(obj) {
+Never booleanConversionFailed(obj) {
   var actual = typeName(getReifiedType(obj));
   throw TypeErrorImpl("type '$actual' is not a 'bool' in boolean expression");
 }
@@ -462,7 +464,7 @@
 asInt(obj) {
   // Note: null (and undefined) will fail this test.
   if (JS('!', 'Math.floor(#) != #', obj, obj)) {
-    if (obj == null && !strictNullSafety) {
+    if (obj == null && !compileTimeFlag('soundNullSafety')) {
       _nullWarnOnType(JS('', '#', int));
       return null;
     } else {
@@ -474,7 +476,9 @@
 
 asNullableInt(obj) => obj == null ? null : asInt(obj);
 
-/// Checks that `x` is not null or undefined.
+/// Checks for null or undefined and returns [x].
+///
+/// Throws [NoSuchMethodError] when it is null or undefined.
 //
 // TODO(jmesserly): inline this, either by generating it as a function into
 // the module, or via some other pattern such as:
@@ -487,15 +491,16 @@
   return x;
 }
 
-/// Checks that `x` is not null or undefined.
+/// Checks for null or undefined and returns [x].
 ///
-/// Unlike `_notNull`, this throws a `CastError` (under strict checking)
-/// or emits a runtime warning (otherwise).  This is only used by the
-/// compiler when casting from nullable to non-nullable variants of the
-/// same type.
+/// Throws a [TypeError] when [x] is null or undefined (under sound null safety
+/// mode) or emits a runtime warning (otherwise).
+///
+/// This is only used by the compiler when casting from nullable to non-nullable
+/// variants of the same type.
 nullCast(x, type) {
   if (x == null) {
-    if (!strictNullSafety) {
+    if (!compileTimeFlag('soundNullSafety')) {
       _nullWarnOnType(type);
     } else {
       castError(x, type);
@@ -504,6 +509,16 @@
   return x;
 }
 
+/// Checks for null or undefined and returns [x].
+///
+/// Throws a [TypeError] when [x] is null or undefined.
+///
+/// This is only used by the compiler for the runtime null check operator `!`.
+nullCheck(x) {
+  if (x == null) throw TypeErrorImpl("Unexpected null value.");
+  return x;
+}
+
 /// The global constant map table.
 final constantMaps = JS<Object>('!', 'new Map()');
 
diff --git a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/types.dart b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/types.dart
index a4bcaf8..2a6c61e 100644
--- a/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/types.dart
+++ b/sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/types.dart
@@ -5,33 +5,18 @@
 /// This library defines the representation of runtime types.
 part of dart._runtime;
 
+/// Returns the state of [flag] that is determined at compile time.
+///
+/// The constant value itself is inlined by the compiler in place of the call
+/// to this method.
+@notNull
+external bool compileTimeFlag(String flag);
+
 _throwNullSafetyWarningError() => throw UnsupportedError(
     'Null safety errors cannot be shown as warnings when running with sound '
     'null safety.');
 
 @notNull
-bool _setNullSafety = false;
-
-@notNull
-bool strictNullSafety = false;
-
-/// Sets the mode of the runtime subtype checks.
-///
-/// Changing the mode after the application has started running is not
-/// supported.
-void nullSafety(bool soundNullSafety) {
-  if (_setNullSafety) {
-    throw UnsupportedError('The Null Safety mode can only be set once.');
-  }
-
-  if (soundNullSafety && _weakNullSafetyWarnings)
-    _throwNullSafetyWarningError();
-
-  strictNullSafety = soundNullSafety;
-  _setNullSafety = true;
-}
-
-@notNull
 bool _weakNullSafetyWarnings = false;
 
 /// Sets the runtime mode to show warnings when running with weak null safety.
@@ -40,11 +25,25 @@
 /// is enabled. Showing warnings while running with sound null safety is not
 /// supported (they will be errors).
 void weakNullSafetyWarnings(bool showWarnings) {
-  if (showWarnings && strictNullSafety) _throwNullSafetyWarningError();
+  if (showWarnings && compileTimeFlag('soundNullSafety')) {
+    _throwNullSafetyWarningError();
+  }
 
   _weakNullSafetyWarnings = showWarnings;
 }
 
+@notNull
+bool _nonNullAsserts = false;
+
+/// Sets the runtime mode to insert non-null assertions on non-nullable method
+/// parameters.
+///
+/// When [weakNullSafetyWarnings] is also `true` the assertions will fail
+/// instead of printing a warning for the non-null parameters.
+void nonNullAsserts(bool enable) {
+  _nonNullAsserts = enable;
+}
+
 final metadata = JS('', 'Symbol("metadata")');
 
 /// Types in dart are represented internally at runtime as follows.
@@ -898,7 +897,7 @@
       var bound = typeBounds[i];
       if (_equalType(bound, dynamic) ||
           JS<bool>('!', '# === #', bound, nullable(unwrapType(Object))) ||
-          (!strictNullSafety && _equalType(bound, Object))) {
+          (!compileTimeFlag('soundNullSafety') && _equalType(bound, Object))) {
         // Do not print the bound when it is a top type. In weak mode the bounds
         // of Object and Object* will also be elided.
         continue;
@@ -997,7 +996,8 @@
       // difference is rare.
       if (_equalType(type, dynamic)) return true;
       if (_jsInstanceOf(type, NullableType) ||
-          (!strictNullSafety && _jsInstanceOf(type, LegacyType))) {
+          (!compileTimeFlag('soundNullSafety') &&
+              _jsInstanceOf(type, LegacyType))) {
         return _equalType(JS('!', '#.type', type), Object);
       }
       return false;
@@ -1289,7 +1289,7 @@
   if (JS('!', '# !== void 0', result)) return result;
 
   var validSubtype = _isSubtype(t1, t2, true);
-  if (!validSubtype && !strictNullSafety) {
+  if (!validSubtype && !compileTimeFlag('soundNullSafety')) {
     validSubtype = _isSubtype(t1, t2, false);
     if (validSubtype) {
       // TODO(nshahan) Need more information to be helpful here.
@@ -1745,7 +1745,7 @@
     var supertypeRequiredNamed = supertype.getRequiredNamedParameters();
     var subtypeNamed = supertype.getNamedParameters();
     var subtypeRequiredNamed = supertype.getRequiredNamedParameters();
-    if (!strictNullSafety) {
+    if (!compileTimeFlag('soundNullSafety')) {
       // In weak mode, treat required named params as optional named params.
       supertypeNamed = {...supertypeNamed, ...supertypeRequiredNamed};
       subtypeNamed = {...subtypeNamed, ...subtypeRequiredNamed};
diff --git a/sdk/lib/_internal/js_runtime/lib/mirrors_patch_cfe.dart b/sdk/lib/_internal/js_runtime/lib/mirrors_patch_cfe.dart
deleted file mode 100644
index c429ecb..0000000
--- a/sdk/lib/_internal/js_runtime/lib/mirrors_patch_cfe.dart
+++ /dev/null
@@ -1,38 +0,0 @@
-// Copyright (c) 2012, 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.
-
-// Patch library for dart:mirrors.
-
-import 'dart:_js_helper' show patch;
-import 'dart:mirrors';
-
-const String _message = 'dart:mirrors is no longer supported for web apps';
-
-@patch
-MirrorSystem currentMirrorSystem() => throw new UnsupportedError(_message);
-
-@patch
-InstanceMirror reflect(dynamic reflectee) =>
-    throw new UnsupportedError(_message);
-
-@patch
-ClassMirror reflectClass(Type key) => throw new UnsupportedError(_message);
-
-@patch
-TypeMirror reflectType(Type key, [List<Type>? typeArguments]) =>
-    throw new UnsupportedError(_message);
-
-@patch
-abstract class MirrorSystem {
-  @patch
-  LibraryMirror findLibrary(Symbol libraryName) =>
-      throw new UnsupportedError(_message);
-
-  @patch
-  static String getName(Symbol symbol) => throw new UnsupportedError(_message);
-
-  @patch
-  static Symbol getSymbol(String name, [LibraryMirror? library]) =>
-      throw new UnsupportedError(_message);
-}
diff --git a/sdk/lib/_internal/js_runtime/lib/rti.dart b/sdk/lib/_internal/js_runtime/lib/rti.dart
index aceef48..2f59b9d 100644
--- a/sdk/lib/_internal/js_runtime/lib/rti.dart
+++ b/sdk/lib/_internal/js_runtime/lib/rti.dart
@@ -2913,12 +2913,14 @@
       String sName = _Utils.asString(_Utils.arrayAt(sNamed, sIndex));
       sIndex += 3;
       if (_Utils.stringLessThan(tName, sName)) return false;
-      bool sIsRequired = _Utils.asBool(_Utils.arrayAt(sNamed, sIndex - 2));
+      bool sIsRequired = !JS_GET_FLAG('LEGACY') &&
+          _Utils.asBool(_Utils.arrayAt(sNamed, sIndex - 2));
       if (_Utils.stringLessThan(sName, tName)) {
         if (sIsRequired) return false;
         continue;
       }
-      bool tIsRequired = _Utils.asBool(_Utils.arrayAt(tNamed, tIndex + 1));
+      bool tIsRequired = !JS_GET_FLAG('LEGACY') &&
+          _Utils.asBool(_Utils.arrayAt(tNamed, tIndex + 1));
       if (sIsRequired && !tIsRequired) return false;
       Rti sType = _Utils.asRti(_Utils.arrayAt(sNamed, sIndex - 1));
       Rti tType = _Utils.asRti(_Utils.arrayAt(tNamed, tIndex + 2));
@@ -2926,9 +2928,11 @@
       break;
     }
   }
-  while (sIndex < sNamedLength) {
-    if (_Utils.asBool(_Utils.arrayAt(sNamed, sIndex + 1))) return false;
-    sIndex += 3;
+  if (!JS_GET_FLAG('LEGACY')) {
+    while (sIndex < sNamedLength) {
+      if (_Utils.asBool(_Utils.arrayAt(sNamed, sIndex + 1))) return false;
+      sIndex += 3;
+    }
   }
   return true;
 }
diff --git a/sdk/lib/_internal/js_runtime/pubspec.yaml b/sdk/lib/_internal/js_runtime/pubspec.yaml
index 75ee57a..96abf65 100644
--- a/sdk/lib/_internal/js_runtime/pubspec.yaml
+++ b/sdk/lib/_internal/js_runtime/pubspec.yaml
@@ -3,4 +3,4 @@
 name: js_runtime
 publish_to: none
 environment:
-  sdk: '>=2.9.0-1 <3.0.0'
+  sdk: '>=2.10.0-0.0 <3.0.0'
diff --git a/sdk/lib/_internal/sdk_library_metadata/pubspec.yaml b/sdk/lib/_internal/sdk_library_metadata/pubspec.yaml
index 7179805..8f46e53 100644
--- a/sdk/lib/_internal/sdk_library_metadata/pubspec.yaml
+++ b/sdk/lib/_internal/sdk_library_metadata/pubspec.yaml
@@ -3,4 +3,4 @@
 name: sdk_library_metadata
 publish_to: none
 environment:
-  sdk: '>=2.9.0-1 <3.0.0'
+  sdk: '>=2.10.0-0.0 <3.0.0'
diff --git a/sdk/lib/_internal/vm/bin/builtin.dart b/sdk/lib/_internal/vm/bin/builtin.dart
index 5abcbfb..7a3bafb 100644
--- a/sdk/lib/_internal/vm/bin/builtin.dart
+++ b/sdk/lib/_internal/vm/bin/builtin.dart
@@ -486,7 +486,8 @@
 // Embedder Entrypoint:
 // The embedder calls this method to initial the package resolution state.
 @pragma("vm:entry-point")
-void _Init(String packagesConfig, String workingDirectory, String rootScript) {
+void _Init(
+    String? packagesConfig, String workingDirectory, String? rootScript) {
   // Register callbacks and hooks with the rest of core libraries.
   _setupHooks();
 
diff --git a/sdk/lib/_internal/vm/bin/vmservice_server.dart b/sdk/lib/_internal/vm/bin/vmservice_server.dart
index 9857cd6..68e18a3 100644
--- a/sdk/lib/_internal/vm/bin/vmservice_server.dart
+++ b/sdk/lib/_internal/vm/bin/vmservice_server.dart
@@ -354,14 +354,41 @@
 
     final String path = result;
     if (path == WEBSOCKET_PATH) {
+      final subprotocols = request.headers['sec-websocket-protocol'];
       if (acceptNewWebSocketConnections) {
         WebSocketTransformer.upgrade(request,
+                protocolSelector:
+                    subprotocols == null ? null : (_) => 'implicit-redirect',
                 compression: CompressionOptions.compressionOff)
             .then((WebSocket webSocket) {
           WebSocketClient(webSocket, _service);
         });
       } else {
         // Forward the websocket connection request to DDS.
+        // The Javascript WebSocket implementation doesn't like websocket
+        // connection requests being redirected. Instead of redirecting, we'll
+        // just forward the connection manually if 'implicit-redirect' is
+        // provided as a protocol.
+        if (subprotocols != null) {
+          if (subprotocols.contains('implicit-redirect')) {
+            WebSocketTransformer.upgrade(request,
+                    protocolSelector: (_) => 'implicit-redirect',
+                    compression: CompressionOptions.compressionOff)
+                .then((WebSocket webSocket) async {
+              final ddsWs = await WebSocket.connect(
+                  _service.ddsUri!.replace(scheme: 'ws').toString());
+              ddsWs.addStream(webSocket);
+              webSocket.addStream(ddsWs);
+              webSocket.done.then((_) {
+                ddsWs.close();
+              });
+              ddsWs.done.then((_) {
+                webSocket.close();
+              });
+            });
+            return;
+          }
+        }
         request.response.redirect(_service.ddsUri!);
       }
       return;
diff --git a/sdk/lib/_internal/vm/lib/array.dart b/sdk/lib/_internal/vm/lib/array.dart
index 9ada6e9..d615f7b 100644
--- a/sdk/lib/_internal/vm/lib/array.dart
+++ b/sdk/lib/_internal/vm/lib/array.dart
@@ -23,6 +23,17 @@
     return result;
   }
 
+  // Specialization of List.generate constructor for growable == false.
+  // Used by pkg/vm/lib/transformations/list_factory_specializer.dart.
+  @pragma("vm:prefer-inline")
+  factory _List.generate(int length, E generator(int index)) {
+    final result = _List<E>(length);
+    for (int i = 0; i < result.length; ++i) {
+      result[i] = generator(i);
+    }
+    return result;
+  }
+
   E operator [](int index) native "List_getIndexed";
 
   void operator []=(int index, E value) {
diff --git a/sdk/lib/_internal/vm/lib/core_patch.dart b/sdk/lib/_internal/vm/lib/core_patch.dart
index 2133763..b4bbd57 100644
--- a/sdk/lib/_internal/vm/lib/core_patch.dart
+++ b/sdk/lib/_internal/vm/lib/core_patch.dart
@@ -32,7 +32,7 @@
         writeIntoOneByteString,
         writeIntoTwoByteString;
 
-import "dart:async" show Completer, Future, Timer;
+import "dart:async" show Completer, DeferredLoadException, Future, Timer;
 
 import "dart:collection"
     show
diff --git a/sdk/lib/_internal/vm/lib/developer.dart b/sdk/lib/_internal/vm/lib/developer.dart
index d9c87a8..82eac19 100644
--- a/sdk/lib/_internal/vm/lib/developer.dart
+++ b/sdk/lib/_internal/vm/lib/developer.dart
@@ -21,7 +21,7 @@
 bool debugger({bool when: true, String? message}) native "Developer_debugger";
 
 @patch
-Object inspect(Object object) native "Developer_inspect";
+Object? inspect(Object? object) native "Developer_inspect";
 
 @patch
 void log(String message,
diff --git a/sdk/lib/_internal/vm/lib/growable_array.dart b/sdk/lib/_internal/vm/lib/growable_array.dart
index 1c14701..0e63557 100644
--- a/sdk/lib/_internal/vm/lib/growable_array.dart
+++ b/sdk/lib/_internal/vm/lib/growable_array.dart
@@ -119,6 +119,17 @@
     return result;
   }
 
+  // Specialization of List.generate constructor for growable == true.
+  // Used by pkg/vm/lib/transformations/list_factory_specializer.dart.
+  @pragma("vm:prefer-inline")
+  factory _GrowableList.generate(int length, T generator(int index)) {
+    final result = _GrowableList<T>(length);
+    for (int i = 0; i < result.length; ++i) {
+      result[i] = generator(i);
+    }
+    return result;
+  }
+
   @pragma("vm:exact-result-type",
       <dynamic>[_GrowableList, "result-type-uses-passed-type-arguments"])
   factory _GrowableList._withData(_List data) native "GrowableList_allocate";
diff --git a/sdk/lib/_internal/vm/lib/isolate_patch.dart b/sdk/lib/_internal/vm/lib/isolate_patch.dart
index da2ed68..91a567d 100644
--- a/sdk/lib/_internal/vm/lib/isolate_patch.dart
+++ b/sdk/lib/_internal/vm/lib/isolate_patch.dart
@@ -229,7 +229,7 @@
  * isolate is in the message loop.
  */
 @pragma("vm:entry-point", "call")
-void _startMainIsolate(Function entryPoint, List<String> args) {
+void _startMainIsolate(Function entryPoint, List<String>? args) {
   _startIsolate(
       null, // no parent port
       entryPoint,
diff --git a/sdk/lib/_internal/vm/lib/lib_prefix.dart b/sdk/lib/_internal/vm/lib/lib_prefix.dart
index d8e52fd..4259640 100644
--- a/sdk/lib/_internal/vm/lib/lib_prefix.dart
+++ b/sdk/lib/_internal/vm/lib/lib_prefix.dart
@@ -13,6 +13,10 @@
 
   bool _isLoaded() native "LibraryPrefix_isLoaded";
   void _setLoaded() native "LibraryPrefix_setLoaded";
+  Object _loadingUnit() native "LibraryPrefix_loadingUnit";
+  static void _issueLoad(Object unit) native "LibraryPrefix_issueLoad";
+
+  static final _loads = new Map<Object, Completer<void>>();
 }
 
 class _DeferredNotLoadedError extends Error implements NoSuchMethodError {
@@ -26,9 +30,39 @@
 }
 
 @pragma("vm:entry-point")
+void _completeLoads(Object unit, String? errorMessage, bool transientError) {
+  Completer<void> load = _LibraryPrefix._loads[unit]!;
+  if (errorMessage == null) {
+    load.complete(null);
+  } else {
+    if (transientError) {
+      _LibraryPrefix._loads.remove(unit);
+    }
+    load.completeError(new DeferredLoadException(errorMessage));
+  }
+}
+
+@pragma("vm:entry-point")
 @pragma("vm:never-inline") // Don't duplicate prefix checking code.
-Future<void> _loadLibrary(_LibraryPrefix prefix) {
-  return new Future<void>(() {
+Future<void> _loadLibrary(_LibraryPrefix prefix) async {
+  if (!prefix._isLoaded()) {
+    Object unit = prefix._loadingUnit();
+    // Don't issue a load request for the root unit. A deferred prefix can
+    // point to a library in the root unit if there is also an immediate import
+    // of that library.
+    if (unit != 1) {
+      Completer<void>? load = _LibraryPrefix._loads[unit];
+      if (load == null) {
+        _LibraryPrefix._loads[unit] = load = new Completer<void>();
+        _LibraryPrefix._issueLoad(unit);
+      }
+      await load.future;
+    }
+  }
+  // Ensure the prefix's future does not complete until the next Turn even
+  // when loading is a no-op or synchronous. Helps applications avoid writing
+  // code that only works when loading isn't really deferred.
+  await new Future<void>(() {
     prefix._setLoaded();
   });
 }
diff --git a/sdk/lib/async/async.dart b/sdk/lib/async/async.dart
index 5e72a00..223af14 100644
--- a/sdk/lib/async/async.dart
+++ b/sdk/lib/async/async.dart
@@ -77,16 +77,16 @@
  *   wanted to know about handling errors and exceptions when working with
  *   Futures (but were afraid to ask).
  *
- * * [The Event Loop and Dart](https://www.dartlang.org/articles/event-loop/):
+ * * [The Event Loop and Dart](https://dart.dev/articles/event-loop/):
  *   Learn how Dart handles the event queue and microtask queue, so you can
  *   write better asynchronous code with fewer surprises.
  *
  * * [test package: Asynchronous Tests][test-readme]: How to test asynchronous
  *   code.
  *
- * [asynchronous-programming]: https://www.dartlang.org/docs/dart-up-and-running/ch03.html#dartasync---asynchronous-programming
- * [futures-tutorial]: https://www.dartlang.org/docs/tutorials/futures/
- * [futures-error-handling]: https://www.dartlang.org/articles/futures-and-error-handling/
+ * [asynchronous-programming]: https://dart.dev/guides/libraries/library-tour#dartasync---asynchronous-programming
+ * [futures-tutorial]: https://dart.dev/codelabs/async-await
+ * [futures-error-handling]: https://dart.dev/guides/libraries/futures-error-handling
  * [test-readme]: https://pub.dev/packages/test
  *
  * {@category Core}
diff --git a/sdk/lib/async/future_impl.dart b/sdk/lib/async/future_impl.dart
index 3f33737..4e24a48 100644
--- a/sdk/lib/async/future_impl.dart
+++ b/sdk/lib/async/future_impl.dart
@@ -768,13 +768,16 @@
     }
   }
 
+  @pragma("vm:entry-point")
   Future<T> timeout(Duration timeLimit, {FutureOr<T> onTimeout()?}) {
     if (_isComplete) return new _Future.immediate(this);
-    _Future<T> result = new _Future<T>();
+    // This is a VM recognised method, and the _future variable is deliberately
+    // allocated in a specific slot in the closure context for stack unwinding.
+    _Future<T> _future = new _Future<T>();
     Timer timer;
     if (onTimeout == null) {
       timer = new Timer(timeLimit, () {
-        result._completeError(
+        _future._completeError(
             new TimeoutException("Future not completed", timeLimit),
             StackTrace.empty);
       });
@@ -785,24 +788,24 @@
 
       timer = new Timer(timeLimit, () {
         try {
-          result._complete(zone.run(onTimeoutHandler));
+          _future._complete(zone.run(onTimeoutHandler));
         } catch (e, s) {
-          result._completeError(e, s);
+          _future._completeError(e, s);
         }
       });
     }
     this.then((T v) {
       if (timer.isActive) {
         timer.cancel();
-        result._completeWithValue(v);
+        _future._completeWithValue(v);
       }
     }, onError: (Object e, StackTrace s) {
       if (timer.isActive) {
         timer.cancel();
-        result._completeError(e, s);
+        _future._completeError(e, s);
       }
     });
-    return result;
+    return _future;
   }
 }
 
diff --git a/sdk/lib/async/schedule_microtask.dart b/sdk/lib/async/schedule_microtask.dart
index 940989c..7e2e933 100644
--- a/sdk/lib/async/schedule_microtask.dart
+++ b/sdk/lib/async/schedule_microtask.dart
@@ -128,7 +128,7 @@
  *
  * ## Other resources
  *
- * * [The Event Loop and Dart](https://www.dartlang.org/articles/event-loop/):
+ * * [The Event Loop and Dart](https://dart.dev/articles/event-loop/):
  * Learn how Dart handles the event queue and microtask queue, so you can write
  * better asynchronous code with fewer surprises.
  */
diff --git a/sdk/lib/collection/list.dart b/sdk/lib/collection/list.dart
index fdf2f8a..045bbd5 100644
--- a/sdk/lib/collection/list.dart
+++ b/sdk/lib/collection/list.dart
@@ -9,17 +9,27 @@
 /// `ListBase` can be used as a base class for implementing the `List`
 /// interface.
 ///
-/// All operations are defined in terms of `length`, `operator[]`,
-/// `operator[]=` and `length=`, which need to be implemented.
+/// This class implements all read operations using only the `length` and
+/// `operator[]` and members. It implements write operations using those and
+/// `add`, `length=` and `operator[]=`
+/// Classes using this base classs  should implement those five operations.
 ///
-/// *NOTICE*: Forwarding just these four operations to a normal growable [List]
-/// (as created by `[]`) will give very bad performance for `add` and
-/// `addAll` operations of `ListBase`. These operations are implemented by
-/// increasing the length of the list by one for each `add` operation, and
-/// repeatedly increasing the length of a growable list is not efficient.
-/// To avoid this, either override 'add' and 'addAll' to also forward directly
-/// to the growable list, or, preferably, use `DelegatingList` from
-/// "package:collection/collection.dart" instead.
+/// **NOTICE**: For backwards compatability reasons,
+/// there is a default implementation of `add`
+/// which only works for lists with a nullable element type.
+/// For list with a non-nullable element type,
+/// the `add` method must be implemented.
+///
+/// **NOTICE**: Forwarding just the four `length` and `[]` read/write operations
+/// to a normal growable [List] (as created by a `[]` literal)
+/// will give very bad performance for `add` and `addAll` operations
+/// of `ListBase`.
+/// These operations are implemented by
+/// increasing the length of the list by one for each `add` operation,
+/// and repeatedly increasing the length of a growable list is not efficient.
+/// To avoid this, override 'add' and 'addAll' to also forward directly
+/// to the growable list, or, if possible, use `DelegatingList` from
+/// "package:collection/collection.dart" instead of a `ListMixin`.
 abstract class ListBase<E> extends Object with ListMixin<E> {
   /// Converts a [List] to a [String].
   ///
@@ -38,18 +48,27 @@
 /// `ListMixin` can be used as a mixin to make a class implement
 /// the `List` interface.
 ///
-/// This implements all read operations using only the `length` and
-/// `operator[]` members. It implements write operations using those and
-/// `length=` and `operator[]=`
+/// This mixin implements all read operations using only the `length` and
+/// `operator[]` and members. It implements write operations using those and
+/// `add`, `length=` and `operator[]=`.
+/// Classes using this mixin should implement those five operations.
 ///
-/// *NOTICE*: Forwarding just these four operations to a normal growable [List]
-/// (as created by `[]`) will give very bad performance for `add` and
-/// `addAll` operations of `ListBase`. These operations are implemented by
-/// increasing the length of the list by one for each `add` operation, and
-/// repeatedly increasing the length of a growable list is not efficient.
-/// To avoid this, either override 'add' and 'addAll' to also forward directly
+/// **NOTICE**: For backwards compatability reasons,
+/// there is a default implementation of `add`
+/// which only works for lists with a nullable element type.
+/// For lists with a non-nullable element type,
+/// the `add` method must be implemented.
+///
+/// **NOTICE**: Forwarding just the four `length` and `[]` read/write operations
+/// to a normal growable [List] (as created by a `[]` literal)
+/// will give very bad performance for `add` and `addAll` operations
+/// of `ListMixin`.
+/// These operations are implemented by
+/// increasing the length of the list by one for each `add` operation,
+/// and repeatedly increasing the length of a growable list is not efficient.
+/// To avoid this, override 'add' and 'addAll' to also forward directly
 /// to the growable list, or, if possible, use `DelegatingList` from
-/// "package:collection/collection.dart" instead.
+/// "package:collection/collection.dart" instead of a `ListMixin`.
 abstract class ListMixin<E> implements List<E> {
   // Iterable interface.
   // TODO(lrn): When we get composable mixins, reuse IterableMixin instead
@@ -255,6 +274,7 @@
 
   // List interface.
   void add(E element) {
+    // This implementation only works for lists which allow `null` as element.
     this[this.length++] = element;
   }
 
@@ -504,14 +524,13 @@
 
   void insert(int index, E element) {
     ArgumentError.checkNotNull(index, "index");
+    var length = this.length;
     RangeError.checkValueInInterval(index, 0, length, "index");
-    if (index == this.length) {
-      add(element);
-      return;
+    add(element);
+    if (index != length) {
+      setRange(index + 1, length + 1, this, index);
+      this[index] = element;
     }
-    this.length++;
-    setRange(index + 1, this.length, this, index);
-    this[index] = element;
   }
 
   E removeAt(int index) {
diff --git a/sdk/lib/core/core.dart b/sdk/lib/core/core.dart
index dc037a3..8997c0a 100644
--- a/sdk/lib/core/core.dart
+++ b/sdk/lib/core/core.dart
@@ -137,17 +137,16 @@
  *
  * ## Other documentation
  *
- * For more information about how to use the built-in types, refer to [Built-in
- * Types](http://www.dartlang.org/docs/dart-up-and-running/contents/ch02.html#built-in-types)
- * in Chapter 2 of
- * [Dart: Up and Running](http://www.dartlang.org/docs/dart-up-and-running/).
+ * For more information about how to use the built-in types, refer to
+ * [Built-in Types](https://dart.dev/guides/language/language-tour#built-in-types)
+ * in
+ * [A tour of the Dart language](https://dart.dev/guides/language/language-tour).
  *
- * Also, see [dart:core - Numbers, Collections, Strings, and
- * More](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#dartcore---numbers-collections-strings-and-more)
- * for more coverage of classes in this package.
+ * Also, see
+ * [dart:core - numbers, collections, strings, and more](https://dart.dev/guides/libraries/library-tour#dartcore---numbers-collections-strings-and-more)
+ * for more coverage of types in this library.
  *
- * The
- * [Dart Language Specification](http://www.dartlang.org/docs/spec/)
+ * The [Dart Language Specification](https://dart.dev/guides/language/spec)
  * provides technical details.
  *
  * {@category Core}
diff --git a/sdk/lib/core/function.dart b/sdk/lib/core/function.dart
index b21f6759..e560eb4 100644
--- a/sdk/lib/core/function.dart
+++ b/sdk/lib/core/function.dart
@@ -7,8 +7,8 @@
 /**
  * The base class for all function types.
  *
- * A function value, or an instance of a class with a "call" method, is a
- * subtype of a function type, and as such, a subtype of [Function].
+ * The run-time type of a function object is subtype of a function type,
+ * and as such, a subtype of [Function].
  */
 abstract class Function {
   /**
diff --git a/sdk/lib/core/iterator.dart b/sdk/lib/core/iterator.dart
index f116c1b..e9a6284 100644
--- a/sdk/lib/core/iterator.dart
+++ b/sdk/lib/core/iterator.dart
@@ -30,8 +30,8 @@
  *     }
  *
  * **See also:**
- * [Iteration](http://www.dartlang.org/docs/dart-up-and-running/contents/ch03.html#iteration)
- * in the [library tour](http://www.dartlang.org/docs/dart-up-and-running/contents/ch03.html)
+ * [Iteration](https://dart.dev/guides/libraries/library-tour#iteration)
+ * in the [library tour](https://dart.dev/guides/libraries/library-tour)
  */
 abstract class Iterator<E> {
   /**
diff --git a/sdk/lib/core/object.dart b/sdk/lib/core/object.dart
index 31602df..0f7d97b 100644
--- a/sdk/lib/core/object.dart
+++ b/sdk/lib/core/object.dart
@@ -14,9 +14,9 @@
  * to return a string describing an instance of that class.
  * You might also need to define [hashCode] and [operator ==], as described in the
  * [Implementing map
- * keys](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#implementing-map-keys)
+ * keys](https://dart.dev/guides/libraries/library-tour#implementing-map-keys)
  * section of the [library
- * tour](http://www.dartlang.org/docs/dart-up-and-running/contents/ch03.html).
+ * tour](https://dart.dev/guides/libraries/library-tour).
  */
 @pragma("vm:entry-point")
 class Object {
diff --git a/sdk/lib/core/string.dart b/sdk/lib/core/string.dart
index 4a353b2..7bef81c 100644
--- a/sdk/lib/core/string.dart
+++ b/sdk/lib/core/string.dart
@@ -93,9 +93,7 @@
  *
  * Also see:
  *
- * * [Dart Cookbook](https://www.dartlang.org/docs/cookbook/#strings)
- *   for String examples and recipes.
- * * [Dart Up and Running](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#strings-and-regular-expressions)
+ * * [Strings and regular expressions](https://dart.dev/guides/libraries/library-tour#strings-and-regular-expressions)
  */
 @pragma('vm:entry-point')
 abstract class String implements Comparable<String>, Pattern {
diff --git a/sdk/lib/core/uri.dart b/sdk/lib/core/uri.dart
index 234241c..998cb83 100644
--- a/sdk/lib/core/uri.dart
+++ b/sdk/lib/core/uri.dart
@@ -32,8 +32,8 @@
  * * [URIs][uris] in the [library tour][libtour]
  * * [RFC-3986](http://tools.ietf.org/html/rfc3986)
  *
- * [uris]: https://www.dartlang.org/docs/dart-up-and-running/ch03.html#uris
- * [libtour]: https://www.dartlang.org/docs/dart-up-and-running/contents/ch03.html
+ * [uris]: https://dart.dev/guides/libraries/library-tour#uris
+ * [libtour]: https://dart.dev/guides/libraries/library-tour
  */
 abstract class Uri {
   /**
@@ -3256,7 +3256,7 @@
       bool base64 = false}) {
     StringBuffer buffer = StringBuffer();
     List<int> indices = [_noScheme];
-    String? charsetName = parameters?.["charset"];
+    String? charsetName = parameters?["charset"];
     String? encodingName;
     if (encoding == null) {
       if (charsetName != null) {
diff --git a/sdk/lib/html/dart2js/html_dart2js.dart b/sdk/lib/html/dart2js/html_dart2js.dart
index a3bcc02..4842c30 100644
--- a/sdk/lib/html/dart2js/html_dart2js.dart
+++ b/sdk/lib/html/dart2js/html_dart2js.dart
@@ -486,9 +486,9 @@
   static AccessibleNodeList _create_2() =>
       JS('AccessibleNodeList', 'new AccessibleNodeList()');
 
-  int get length native;
+  int? get length native;
 
-  set length(int value) native;
+  set length(int? value) native;
 
   void __setter__(int index, AccessibleNode node) native;
 
@@ -550,17 +550,17 @@
    */
   AnchorElement.created() : super.created();
 
-  String get download native;
+  String? get download native;
 
-  set download(String value) native;
+  set download(String? value) native;
 
   String get hreflang native;
 
   set hreflang(String value) native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  set referrerPolicy(String value) native;
+  set referrerPolicy(String? value) native;
 
   String get rel native;
 
@@ -576,47 +576,47 @@
 
   // From HTMLHyperlinkElementUtils
 
-  String get hash native;
+  String? get hash native;
 
-  set hash(String value) native;
+  set hash(String? value) native;
 
-  String get host native;
+  String? get host native;
 
-  set host(String value) native;
+  set host(String? value) native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  set hostname(String value) native;
+  set hostname(String? value) native;
 
-  String get href native;
+  String? get href native;
 
-  set href(String value) native;
+  set href(String? value) native;
 
-  String get origin native;
+  String? get origin native;
 
-  String get password native;
+  String? get password native;
 
-  set password(String value) native;
+  set password(String? value) native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  set pathname(String value) native;
+  set pathname(String? value) native;
 
-  String get port native;
+  String? get port native;
 
-  set port(String value) native;
+  set port(String? value) native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  set protocol(String value) native;
+  set protocol(String? value) native;
 
-  String get search native;
+  String? get search native;
 
-  set search(String value) native;
+  set search(String? value) native;
 
-  String get username native;
+  String? get username native;
 
-  set username(String value) native;
+  set username(String? value) native;
 
   String toString() => JS('String', 'String(#)', this);
 }
@@ -667,15 +667,15 @@
   Future<Animation> get finished =>
       promiseToFuture<Animation>(JS("", "#.finished", this));
 
-  String get id native;
+  String? get id native;
 
-  set id(String value) native;
+  set id(String? value) native;
 
-  String get playState native;
+  String? get playState native;
 
-  num get playbackRate native;
+  num? get playbackRate native;
 
-  set playbackRate(num value) native;
+  set playbackRate(num? value) native;
 
   Future<Animation> get ready =>
       promiseToFuture<Animation>(JS("", "#.ready", this));
@@ -711,7 +711,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  AnimationEffectTimingReadOnly get timing native;
+  AnimationEffectTimingReadOnly? get timing native;
 
   Map getComputedTiming() {
     return convertNativeToDart_Dictionary(_getComputedTiming_1())!;
@@ -733,15 +733,15 @@
 
   // Shadowing definition.
 
-  num get delay native;
+  num? get delay native;
 
-  set delay(num value) native;
+  set delay(num? value) native;
 
   // Shadowing definition.
 
-  String get direction native;
+  String? get direction native;
 
-  set direction(String value) native;
+  set direction(String? value) native;
 
   // Shadowing definition.
 
@@ -752,33 +752,33 @@
 
   // Shadowing definition.
 
-  String get easing native;
+  String? get easing native;
 
-  set easing(String value) native;
+  set easing(String? value) native;
 
   // Shadowing definition.
 
-  num get endDelay native;
+  num? get endDelay native;
 
-  set endDelay(num value) native;
+  set endDelay(num? value) native;
 
   // Shadowing definition.
 
-  String get fill native;
+  String? get fill native;
 
-  set fill(String value) native;
+  set fill(String? value) native;
 
   // Shadowing definition.
 
-  num get iterationStart native;
+  num? get iterationStart native;
 
-  set iterationStart(num value) native;
+  set iterationStart(num? value) native;
 
   // Shadowing definition.
 
-  num get iterations native;
+  num? get iterations native;
 
-  set iterations(num value) native;
+  set iterations(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -791,21 +791,21 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get delay native;
+  num? get delay native;
 
-  String get direction native;
+  String? get direction native;
 
   Object? get duration native;
 
-  String get easing native;
+  String? get easing native;
 
-  num get endDelay native;
+  num? get endDelay native;
 
-  String get fill native;
+  String? get fill native;
 
-  num get iterationStart native;
+  num? get iterationStart native;
 
-  num get iterations native;
+  num? get iterations native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -830,9 +830,9 @@
   static AnimationEvent _create_2(type) =>
       JS('AnimationEvent', 'new AnimationEvent(#)', type);
 
-  String get animationName native;
+  String? get animationName native;
 
-  num get elapsedTime native;
+  num? get elapsedTime native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -997,7 +997,7 @@
 
   static const int UPDATEREADY = 4;
 
-  int get status native;
+  int? get status native;
 
   void abort() native;
 
@@ -1055,13 +1055,13 @@
   static ApplicationCacheErrorEvent _create_2(type) => JS(
       'ApplicationCacheErrorEvent', 'new ApplicationCacheErrorEvent(#)', type);
 
-  String get message native;
+  String? get message native;
 
-  String get reason native;
+  String? get reason native;
 
-  int get status native;
+  int? get status native;
 
-  String get url native;
+  String? get url native;
 }
 // Copyright (c) 2015, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1104,13 +1104,13 @@
 
   set coords(String value) native;
 
-  String get download native;
+  String? get download native;
 
-  set download(String value) native;
+  set download(String? value) native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  set referrerPolicy(String value) native;
+  set referrerPolicy(String? value) native;
 
   String get rel native;
 
@@ -1126,47 +1126,47 @@
 
   // From HTMLHyperlinkElementUtils
 
-  String get hash native;
+  String? get hash native;
 
-  set hash(String value) native;
+  set hash(String? value) native;
 
-  String get host native;
+  String? get host native;
 
-  set host(String value) native;
+  set host(String? value) native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  set hostname(String value) native;
+  set hostname(String? value) native;
 
-  String get href native;
+  String? get href native;
 
-  set href(String value) native;
+  set href(String? value) native;
 
-  String get origin native;
+  String? get origin native;
 
-  String get password native;
+  String? get password native;
 
-  set password(String value) native;
+  set password(String? value) native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  set pathname(String value) native;
+  set pathname(String? value) native;
 
-  String get port native;
+  String? get port native;
 
-  set port(String value) native;
+  set port(String? value) native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  set protocol(String value) native;
+  set protocol(String? value) native;
 
-  String get search native;
+  String? get search native;
 
-  set search(String value) native;
+  set search(String? value) native;
 
-  String get username native;
+  String? get username native;
 
-  set username(String value) native;
+  set username(String? value) native;
 
   String toString() => JS('String', 'String(#)', this);
 }
@@ -1204,9 +1204,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  ByteBuffer get authenticatorData native;
+  ByteBuffer? get authenticatorData native;
 
-  ByteBuffer get signature native;
+  ByteBuffer? get signature native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1219,7 +1219,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  ByteBuffer get attestationObject native;
+  ByteBuffer? get attestationObject native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1233,7 +1233,7 @@
   }
 
   @JSName('clientDataJSON')
-  ByteBuffer get clientDataJson native;
+  ByteBuffer? get clientDataJson native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1279,7 +1279,7 @@
       type,
       init);
 
-  String get state native;
+  String? get state native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1299,7 +1299,7 @@
   static BackgroundFetchEvent _create_1(type, init) =>
       JS('BackgroundFetchEvent', 'new BackgroundFetchEvent(#,#)', type, init);
 
-  String get id native;
+  String? get id native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1322,7 +1322,7 @@
       type,
       init);
 
-  List<BackgroundFetchSettledFetch> get fetches native;
+  List<BackgroundFetchSettledFetch>? get fetches native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1335,7 +1335,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  _Request get request native;
+  _Request? get request native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1376,19 +1376,19 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get downloadTotal native;
+  int? get downloadTotal native;
 
-  int get downloaded native;
+  int? get downloaded native;
 
-  String get id native;
+  String? get id native;
 
-  String get title native;
+  String? get title native;
 
-  int get totalDownloadSize native;
+  int? get totalDownloadSize native;
 
-  int get uploadTotal native;
+  int? get uploadTotal native;
 
-  int get uploaded native;
+  int? get uploaded native;
 
   Future<bool> abort() => promiseToFuture<bool>(JS("", "#.abort()", this));
 }
@@ -1432,7 +1432,7 @@
   static BackgroundFetchedEvent _create_1(type, init) => JS(
       'BackgroundFetchedEvent', 'new BackgroundFetchedEvent(#,#)', type, init);
 
-  List<BackgroundFetchSettledFetch> get fetches native;
+  List<BackgroundFetchSettledFetch>? get fetches native;
 
   Future updateUI(String title) =>
       promiseToFuture(JS("", "#.updateUI(#)", this, title));
@@ -1450,7 +1450,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get visible native;
+  bool? get visible native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1514,13 +1514,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get charging native;
+  bool? get charging native;
 
-  num get chargingTime native;
+  num? get chargingTime native;
 
-  num get dischargingTime native;
+  num? get dischargingTime native;
 
-  num get level native;
+  num? get level native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1548,7 +1548,7 @@
   static BeforeInstallPromptEvent _create_2(type) =>
       JS('BeforeInstallPromptEvent', 'new BeforeInstallPromptEvent(#)', type);
 
-  List<String> get platforms native;
+  List<String>? get platforms native;
 
   Future<Map<String, dynamic>?> get userChoice =>
       promiseToFutureAsMap(JS("", "#.userChoice", this));
@@ -1568,9 +1568,9 @@
 
   // Shadowing definition.
 
-  String get returnValue native;
+  String? get returnValue native;
 
-  set returnValue(String value) native;
+  set returnValue(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1635,9 +1635,9 @@
   static BlobEvent _create_1(type, eventInitDict) =>
       JS('BlobEvent', 'new BlobEvent(#,#)', type, eventInitDict);
 
-  Blob get data native;
+  Blob? get data native;
 
-  num get timecode native;
+  num? get timecode native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1650,9 +1650,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  _BluetoothRemoteGATTCharacteristic get characteristic native;
+  _BluetoothRemoteGATTCharacteristic? get characteristic native;
 
-  String get uuid native;
+  String? get uuid native;
 
   ByteData? get value native;
 
@@ -1672,7 +1672,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get bodyUsed native;
+  bool? get bodyUsed native;
 
   Future arrayBuffer() => promiseToFuture(JS("", "#.arrayBuffer()", this));
 
@@ -1877,7 +1877,7 @@
   static BroadcastChannel _create_1(name) =>
       JS('BroadcastChannel', 'new BroadcastChannel(#)', name);
 
-  String get name native;
+  String? get name native;
 
   void close() native;
 
@@ -1896,9 +1896,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get budgetAt native;
+  num? get budgetAt native;
 
-  int get time native;
+  int? get time native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1933,9 +1933,9 @@
 
   FormElement? get form native;
 
-  String get formAction native;
+  String? get formAction native;
 
-  set formAction(String value) native;
+  set formAction(String? value) native;
 
   String get formEnctype native;
 
@@ -1956,7 +1956,7 @@
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
   String get name native;
 
@@ -2047,13 +2047,13 @@
       type,
       eventInitDict);
 
-  List get methodData native;
+  List? get methodData native;
 
-  List get modifiers native;
+  List? get modifiers native;
 
-  String get paymentRequestOrigin native;
+  String? get paymentRequestOrigin native;
 
-  String get topLevelOrigin native;
+  String? get topLevelOrigin native;
 
   void respondWith(Future canMakePaymentResponse) native;
 }
@@ -2068,7 +2068,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  CanvasElement get canvas native;
+  CanvasElement? get canvas native;
 
   void requestFrame() native;
 }
@@ -2367,13 +2367,13 @@
 
   CanvasElement get canvas native;
 
-  Matrix get currentTransform native;
+  Matrix? get currentTransform native;
 
-  set currentTransform(Matrix value) native;
+  set currentTransform(Matrix? value) native;
 
-  String get direction native;
+  String? get direction native;
 
-  set direction(String value) native;
+  set direction(String? value) native;
 
   @Creates('String|CanvasGradient|CanvasPattern')
   @Returns('String|CanvasGradient|CanvasPattern')
@@ -2381,9 +2381,9 @@
 
   set fillStyle(Object? value) native;
 
-  String get filter native;
+  String? get filter native;
 
-  set filter(String value) native;
+  set filter(String? value) native;
 
   String get font native;
 
@@ -2408,13 +2408,13 @@
    *   from WHATWG.
    */
 
-  bool get imageSmoothingEnabled native;
+  bool? get imageSmoothingEnabled native;
 
-  set imageSmoothingEnabled(bool value) native;
+  set imageSmoothingEnabled(bool? value) native;
 
-  String get imageSmoothingQuality native;
+  String? get imageSmoothingQuality native;
 
-  set imageSmoothingQuality(String value) native;
+  set imageSmoothingQuality(String? value) native;
 
   String get lineCap native;
 
@@ -2976,11 +2976,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get data native;
+  String? get data native;
 
-  set data(String value) native;
+  set data(String? value) native;
 
-  int get length native;
+  int? get length native;
 
   void appendData(String data) native;
 
@@ -3031,13 +3031,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get frameType native;
+  String? get frameType native;
 
-  String get id native;
+  String? get id native;
 
-  String get type native;
+  String? get type native;
 
-  String get url native;
+  String? get url native;
 
   void postMessage(Object message, [List<Object>? transfer]) native;
 }
@@ -3116,11 +3116,11 @@
   static CloseEvent _create_2(type) =>
       JS('CloseEvent', 'new CloseEvent(#)', type);
 
-  int get code native;
+  int? get code native;
 
-  String get reason native;
+  String? get reason native;
 
-  bool get wasClean native;
+  bool? get wasClean native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3180,7 +3180,7 @@
   static CompositionEvent _create_2(type) =>
       JS('CompositionEvent', 'new CompositionEvent(#)', type);
 
-  String get data native;
+  String? get data native;
 
   @JSName('initCompositionEvent')
   void _initCompositionEvent(String? type, bool? bubbles, bool? cancelable,
@@ -3210,9 +3210,9 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => Element.isTagSupported('content');
 
-  String get select native;
+  String? get select native;
 
-  set select(String value) native;
+  set select(String? value) native;
 
   @Returns('NodeList')
   @Creates('NodeList')
@@ -3257,7 +3257,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get accuracy native;
+  num? get accuracy native;
 
   num? get altitude native;
 
@@ -3265,9 +3265,9 @@
 
   num? get heading native;
 
-  num get latitude native;
+  num? get latitude native;
 
-  num get longitude native;
+  num? get longitude native;
 
   num? get speed native;
 }
@@ -3282,9 +3282,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get id native;
+  String? get id native;
 
-  String get type native;
+  String? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3298,9 +3298,9 @@
   }
 
   @JSName('iconURL')
-  String get iconUrl native;
+  String? get iconUrl native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3359,7 +3359,7 @@
   static bool get supported =>
       JS('bool', '!!(window.crypto && window.crypto.getRandomValues)');
 
-  _SubtleCrypto get subtle native;
+  _SubtleCrypto? get subtle native;
 
   @JSName('getRandomValues')
   @Creates('TypedData')
@@ -3378,13 +3378,13 @@
   }
 
   @Creates('Null')
-  Object get algorithm native;
+  Object? get algorithm native;
 
-  bool get extractable native;
+  bool? get extractable native;
 
-  String get type native;
+  String? get type native;
 
-  Object get usages native;
+  Object? get usages native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3397,7 +3397,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  static _Worklet get paintWorklet native;
+  static _Worklet? get paintWorklet native;
 
   static CssUnitValue Hz(num value) native;
 
@@ -3483,9 +3483,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get encoding native;
+  String? get encoding native;
 
-  set encoding(String value) native;
+  set encoding(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3498,7 +3498,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get conditionText native;
+  String? get conditionText native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3511,7 +3511,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  CssStyleDeclaration get style native;
+  CssStyleDeclaration? get style native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3526,7 +3526,7 @@
 
   @Returns('_CssRuleList')
   @Creates('_CssRuleList')
-  List<CssRule> get cssRules native;
+  List<CssRule>? get cssRules native;
 
   void deleteRule(int index) native;
 
@@ -3560,11 +3560,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get href native;
+  String? get href native;
 
-  MediaList get media native;
+  MediaList? get media native;
 
-  CssStyleSheet get styleSheet native;
+  CssStyleSheet? get styleSheet native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3577,11 +3577,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get keyText native;
+  String? get keyText native;
 
-  set keyText(String value) native;
+  set keyText(String? value) native;
 
-  CssStyleDeclaration get style native;
+  CssStyleDeclaration? get style native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3596,11 +3596,11 @@
 
   @Returns('_CssRuleList')
   @Creates('_CssRuleList')
-  List<CssRule> get cssRules native;
+  List<CssRule>? get cssRules native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
   CssKeyframeRule __getter__(int index) native;
 
@@ -3627,9 +3627,9 @@
   static CssKeywordValue _create_1(keyword) =>
       JS('CssKeywordValue', 'new CSSKeywordValue(#)', keyword);
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3654,9 +3654,9 @@
   static CssMatrixComponent _create_2(matrix) =>
       JS('CssMatrixComponent', 'new CSSMatrixComponent(#)', matrix);
 
-  DomMatrix get matrix native;
+  DomMatrix? get matrix native;
 
-  set matrix(DomMatrix value) native;
+  set matrix(DomMatrix? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3669,7 +3669,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  MediaList get media native;
+  MediaList? get media native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3683,9 +3683,9 @@
   }
 
   @JSName('namespaceURI')
-  String get namespaceUri native;
+  String? get namespaceUri native;
 
-  String get prefix native;
+  String? get prefix native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3721,11 +3721,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get selectorText native;
+  String? get selectorText native;
 
-  set selectorText(String value) native;
+  set selectorText(String? value) native;
 
-  CssStyleDeclaration get style native;
+  CssStyleDeclaration? get style native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3744,9 +3744,9 @@
   static CssPerspective _create_1(length) =>
       JS('CssPerspective', 'new CSSPerspective(#)', length);
 
-  CssNumericValue get length native;
+  CssNumericValue? get length native;
 
-  set length(CssNumericValue value) native;
+  set length(CssNumericValue? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3765,13 +3765,13 @@
   static CssPositionValue _create_1(x, y) =>
       JS('CssPositionValue', 'new CSSPositionValue(#,#)', x, y);
 
-  CssNumericValue get x native;
+  CssNumericValue? get x native;
 
-  set x(CssNumericValue value) native;
+  set x(CssNumericValue? value) native;
 
-  CssNumericValue get y native;
+  CssNumericValue? get y native;
 
-  set y(CssNumericValue value) native;
+  set y(CssNumericValue? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3784,7 +3784,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get state native;
+  String? get state native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3818,21 +3818,21 @@
   static CssRotation _create_2(angleValue_OR_x, y, z, angle) => JS(
       'CssRotation', 'new CSSRotation(#,#,#,#)', angleValue_OR_x, y, z, angle);
 
-  CssNumericValue get angle native;
+  CssNumericValue? get angle native;
 
-  set angle(CssNumericValue value) native;
+  set angle(CssNumericValue? value) native;
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 
-  num get z native;
+  num? get z native;
 
-  set z(num value) native;
+  set z(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3867,15 +3867,15 @@
 
   static const int VIEWPORT_RULE = 15;
 
-  String get cssText native;
+  String? get cssText native;
 
-  set cssText(String value) native;
+  set cssText(String? value) native;
 
   CssRule? get parentRule native;
 
   CssStyleSheet? get parentStyleSheet native;
 
-  int get type native;
+  int? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3901,17 +3901,17 @@
   static CssScale _create_2(x, y, z) =>
       JS('CssScale', 'new CSSScale(#,#,#)', x, y, z);
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 
-  num get z native;
+  num? get z native;
 
-  set z(num value) native;
+  set z(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3929,13 +3929,13 @@
   }
   static CssSkew _create_1(ax, ay) => JS('CssSkew', 'new CSSSkew(#,#)', ax, ay);
 
-  CssNumericValue get ax native;
+  CssNumericValue? get ax native;
 
-  set ax(CssNumericValue value) native;
+  set ax(CssNumericValue? value) native;
 
-  CssNumericValue get ay native;
+  CssNumericValue? get ay native;
 
-  set ay(CssNumericValue value) native;
+  set ay(CssNumericValue? value) native;
 }
 
 // Copyright (c) 2014, the Dart project authors.  Please see the AUTHORS file
@@ -4048,13 +4048,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get cssFloat native;
+  String? get cssFloat native;
 
   set cssFloat(String? value) native;
 
-  String get cssText native;
+  String? get cssText native;
 
-  set cssText(String value) native;
+  set cssText(String? value) native;
 
   int get length native;
 
@@ -8699,7 +8699,7 @@
 
   @Returns('_CssRuleList')
   @Creates('_CssRuleList')
-  List<CssRule> get rules native;
+  List<CssRule>? get rules native;
 
   int addRule(String? selector, String? style, [int? index]) native;
 
@@ -8744,9 +8744,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get is2D native;
+  bool? get is2D native;
 
-  set is2D(bool value) native;
+  set is2D(bool? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -8774,9 +8774,9 @@
   static CssTransformValue _create_2(transformComponents) =>
       JS('CssTransformValue', 'new CSSTransformValue(#)', transformComponents);
 
-  bool get is2D native;
+  bool? get is2D native;
 
-  int get length native;
+  int? get length native;
 
   CssTransformComponent componentAtIndex(int index) native;
 
@@ -8810,17 +8810,17 @@
   static CssTranslation _create_2(x, y, z) =>
       JS('CssTranslation', 'new CSSTranslation(#,#,#)', x, y, z);
 
-  CssNumericValue get x native;
+  CssNumericValue? get x native;
 
-  set x(CssNumericValue value) native;
+  set x(CssNumericValue? value) native;
 
-  CssNumericValue get y native;
+  CssNumericValue? get y native;
 
-  set y(CssNumericValue value) native;
+  set y(CssNumericValue? value) native;
 
-  CssNumericValue get z native;
+  CssNumericValue? get z native;
 
-  set z(CssNumericValue value) native;
+  set z(CssNumericValue? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -8839,15 +8839,15 @@
   static CssUnitValue _create_1(value, unit) =>
       JS('CssUnitValue', 'new CSSUnitValue(#,#)', value, unit);
 
-  String get type native;
+  String? get type native;
 
-  String get unit native;
+  String? get unit native;
 
-  set unit(String value) native;
+  set unit(String? value) native;
 
-  num get value native;
+  num? get value native;
 
-  set value(num value) native;
+  set value(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -8860,7 +8860,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get length native;
+  int? get length native;
 
   Object? fragmentAtIndex(int index) native;
 }
@@ -8875,9 +8875,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  CssUnparsedValue get fallback native;
+  CssUnparsedValue? get fallback native;
 
-  String get variable native;
+  String? get variable native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -8890,7 +8890,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  CssStyleDeclaration get style native;
+  CssStyleDeclaration? get style native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -8909,7 +8909,7 @@
   static CssurlImageValue _create_1(url) =>
       JS('CssurlImageValue', 'new CSSURLImageValue(#)', url);
 
-  String get url native;
+  String? get url native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9053,9 +9053,9 @@
    */
   DataElement.created() : super.created();
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9086,7 +9086,7 @@
 
   @Returns('HtmlCollection')
   @Creates('HtmlCollection')
-  List<Node> get options native;
+  List<Node>? get options native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9104,21 +9104,21 @@
   }
   static DataTransfer _create_1() => JS('DataTransfer', 'new DataTransfer()');
 
-  String get dropEffect native;
+  String? get dropEffect native;
 
-  set dropEffect(String value) native;
+  set dropEffect(String? value) native;
 
-  String get effectAllowed native;
+  String? get effectAllowed native;
 
-  set effectAllowed(String value) native;
+  set effectAllowed(String? value) native;
 
   @Returns('FileList')
   @Creates('FileList')
-  List<File> get files native;
+  List<File>? get files native;
 
-  DataTransferItemList get items native;
+  DataTransferItemList? get items native;
 
-  List<String> get types native;
+  List<String>? get types native;
 
   void clearData([String? format]) native;
 
@@ -9137,9 +9137,9 @@
   Entry getAsEntry() {
     Entry entry = _webkitGetAsEntry() as Entry;
 
-    if (entry.isFile)
+    if (entry.isFile!)
       applyExtension('FileEntry', entry);
-    else if (entry.isDirectory)
+    else if (entry.isDirectory!)
       applyExtension('DirectoryEntry', entry);
     else
       applyExtension('Entry', entry);
@@ -9152,9 +9152,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get kind native;
+  String? get kind native;
 
-  String get type native;
+  String? get type native;
 
   File? getAsFile() native;
 
@@ -9174,7 +9174,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get length native;
+  int? get length native;
 
   DataTransferItem? add(data_OR_file, [String? type]) native;
 
@@ -9341,11 +9341,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get lineNumber native;
+  int? get lineNumber native;
 
-  String get message native;
+  String? get message native;
 
-  String get sourceFile native;
+  String? get sourceFile native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9372,9 +9372,9 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => Element.isTagSupported('details');
 
-  bool get open native;
+  bool? get open native;
 
-  set open(bool value) native;
+  set open(bool? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9393,11 +9393,11 @@
   static DetectedBarcode _create_1() =>
       JS('DetectedBarcode', 'new DetectedBarcode()');
 
-  Rectangle get boundingBox native;
+  Rectangle? get boundingBox native;
 
-  List get cornerPoints native;
+  List? get cornerPoints native;
 
-  String get rawValue native;
+  String? get rawValue native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9415,9 +9415,9 @@
   }
   static DetectedFace _create_1() => JS('DetectedFace', 'new DetectedFace()');
 
-  Rectangle get boundingBox native;
+  Rectangle? get boundingBox native;
 
-  List get landmarks native;
+  List? get landmarks native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9435,11 +9435,11 @@
   }
   static DetectedText _create_1() => JS('DetectedText', 'new DetectedText()');
 
-  Rectangle get boundingBox native;
+  Rectangle? get boundingBox native;
 
-  List get cornerPoints native;
+  List? get cornerPoints native;
 
-  String get rawValue native;
+  String? get rawValue native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -9485,7 +9485,7 @@
 
   DeviceAcceleration? get accelerationIncludingGravity native;
 
-  num get interval native;
+  num? get interval native;
 
   DeviceRotationRate? get rotationRate native;
 }
@@ -9515,7 +9515,7 @@
   static DeviceOrientationEvent _create_2(type) =>
       JS('DeviceOrientationEvent', 'new DeviceOrientationEvent(#)', type);
 
-  bool get absolute native;
+  bool? get absolute native;
 
   num? get alpha native;
 
@@ -9558,13 +9558,13 @@
    */
   DialogElement.created() : super.created();
 
-  bool get open native;
+  bool? get open native;
 
-  set open(bool value) native;
+  set open(bool? value) native;
 
-  String get returnValue native;
+  String? get returnValue native;
 
-  set returnValue(String value) native;
+  set returnValue(String? value) native;
 
   void close([String? returnValue]) native;
 
@@ -9754,9 +9754,9 @@
       values.forEach((value) {
         applyExtension('Entry', value);
         Entry entry = value as Entry;
-        if (entry.isFile)
+        if (entry.isFile!)
           applyExtension('FileEntry', entry);
-        else if (entry.isDirectory) applyExtension('DirectoryEntry', entry);
+        else if (entry.isDirectory!) applyExtension('DirectoryEntry', entry);
       });
       completer.complete(new List<Entry>.from(values));
     }, (error) {
@@ -9871,7 +9871,7 @@
   }
   static Document _create_1() => JS('Document', 'new Document()');
 
-  String get addressSpace native;
+  String? get addressSpace native;
 
   @JSName('body')
   HtmlElement? get _body native;
@@ -9879,11 +9879,11 @@
   @JSName('body')
   set _body(HtmlElement? value) native;
 
-  String get contentType native;
+  String? get contentType native;
 
-  String get cookie native;
+  String? get cookie native;
 
-  set cookie(String value) native;
+  set cookie(String? value) native;
 
   ScriptElement? get currentScript native;
 
@@ -9897,31 +9897,31 @@
 
   Element? get documentElement native;
 
-  String get domain native;
+  String? get domain native;
 
-  bool get fullscreenEnabled native;
+  bool? get fullscreenEnabled native;
 
   @JSName('head')
   HeadElement? get _head native;
 
-  bool get hidden native;
+  bool? get hidden native;
 
-  DomImplementation get implementation native;
+  DomImplementation? get implementation native;
 
   @JSName('lastModified')
-  String get _lastModified native;
+  String? get _lastModified native;
 
-  String get origin native;
+  String? get origin native;
 
   @JSName('preferredStylesheetSet')
   String? get _preferredStylesheetSet native;
 
-  String get readyState native;
+  String? get readyState native;
 
   @JSName('referrer')
   String get _referrer native;
 
-  SvgSvgElement get rootElement native;
+  SvgSvgElement? get rootElement native;
 
   Element? get rootScroller native;
 
@@ -9935,9 +9935,9 @@
   @JSName('selectedStylesheetSet')
   set _selectedStylesheetSet(String? value) native;
 
-  String get suborigin native;
+  String? get suborigin native;
 
-  DocumentTimeline get timeline native;
+  DocumentTimeline? get timeline native;
 
   @JSName('title')
   String get _title native;
@@ -9946,27 +9946,27 @@
   set _title(String value) native;
 
   @JSName('visibilityState')
-  String get _visibilityState native;
+  String? get _visibilityState native;
 
   @JSName('webkitFullscreenElement')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  Element get _webkitFullscreenElement native;
+  Element? get _webkitFullscreenElement native;
 
   @JSName('webkitFullscreenEnabled')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  bool get _webkitFullscreenEnabled native;
+  bool? get _webkitFullscreenEnabled native;
 
   @JSName('webkitHidden')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  bool get _webkitHidden native;
+  bool? get _webkitHidden native;
 
   @JSName('webkitVisibilityState')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  String get _webkitVisibilityState native;
+  String? get _webkitVisibilityState native;
 
   Node adoptNode(Node node) native;
 
@@ -10103,7 +10103,7 @@
   @JSName('styleSheets')
   @Returns('_StyleSheetList')
   @Creates('_StyleSheetList')
-  List<StyleSheet> get _styleSheets native;
+  List<StyleSheet>? get _styleSheets native;
 
   @JSName('elementFromPoint')
   Element? _elementFromPoint(int x, int y) native;
@@ -10112,7 +10112,7 @@
 
   // From FontFaceSource
 
-  FontFaceSet get fonts native;
+  FontFaceSet? get fonts native;
 
   // From ParentNode
 
@@ -10122,7 +10122,7 @@
   @JSName('children')
   @Returns('HtmlCollection')
   @Creates('HtmlCollection')
-  List<Node> get _children native;
+  List<Node>? get _children native;
 
   @JSName('firstElementChild')
   Element? get _firstElementChild native;
@@ -10498,7 +10498,10 @@
   ElementList<T> querySelectorAll<T extends Element>(String selectors) =>
       new _FrozenElementList<T>._wrap(_querySelectorAll(selectors));
 
-  String get innerHtml {
+  // innerHtml is marked as nullable, even though it is guaranteed to return a
+  // non-nullable, because ShadowRoot.innerHtml overrides it and can be
+  // incompatible.
+  String? get innerHtml {
     final e = new DivElement();
     e.append(this.clone(true));
     return e.innerHtml;
@@ -10591,7 +10594,7 @@
 
   @Returns('_StyleSheetList')
   @Creates('_StyleSheetList')
-  List<StyleSheet> get styleSheets native;
+  List<StyleSheet>? get styleSheets native;
 
   Element? elementFromPoint(int x, int y) native;
 
@@ -10643,9 +10646,9 @@
       JS('DomError', 'new DOMError(#,#)', name, message);
   static DomError _create_2(name) => JS('DomError', 'new DOMError(#)', name);
 
-  String get message native;
+  String? get message native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -10703,7 +10706,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get message native;
+  String? get message native;
 
   String toString() => JS('String', 'String(#)', this);
 }
@@ -10764,135 +10767,135 @@
 
   // Shadowing definition.
 
-  num get a native;
+  num? get a native;
 
-  set a(num value) native;
+  set a(num? value) native;
 
   // Shadowing definition.
 
-  num get b native;
+  num? get b native;
 
-  set b(num value) native;
+  set b(num? value) native;
 
   // Shadowing definition.
 
-  num get c native;
+  num? get c native;
 
-  set c(num value) native;
+  set c(num? value) native;
 
   // Shadowing definition.
 
-  num get d native;
+  num? get d native;
 
-  set d(num value) native;
+  set d(num? value) native;
 
   // Shadowing definition.
 
-  num get e native;
+  num? get e native;
 
-  set e(num value) native;
+  set e(num? value) native;
 
   // Shadowing definition.
 
-  num get f native;
+  num? get f native;
 
-  set f(num value) native;
+  set f(num? value) native;
 
   // Shadowing definition.
 
-  num get m11 native;
+  num? get m11 native;
 
-  set m11(num value) native;
+  set m11(num? value) native;
 
   // Shadowing definition.
 
-  num get m12 native;
+  num? get m12 native;
 
-  set m12(num value) native;
+  set m12(num? value) native;
 
   // Shadowing definition.
 
-  num get m13 native;
+  num? get m13 native;
 
-  set m13(num value) native;
+  set m13(num? value) native;
 
   // Shadowing definition.
 
-  num get m14 native;
+  num? get m14 native;
 
-  set m14(num value) native;
+  set m14(num? value) native;
 
   // Shadowing definition.
 
-  num get m21 native;
+  num? get m21 native;
 
-  set m21(num value) native;
+  set m21(num? value) native;
 
   // Shadowing definition.
 
-  num get m22 native;
+  num? get m22 native;
 
-  set m22(num value) native;
+  set m22(num? value) native;
 
   // Shadowing definition.
 
-  num get m23 native;
+  num? get m23 native;
 
-  set m23(num value) native;
+  set m23(num? value) native;
 
   // Shadowing definition.
 
-  num get m24 native;
+  num? get m24 native;
 
-  set m24(num value) native;
+  set m24(num? value) native;
 
   // Shadowing definition.
 
-  num get m31 native;
+  num? get m31 native;
 
-  set m31(num value) native;
+  set m31(num? value) native;
 
   // Shadowing definition.
 
-  num get m32 native;
+  num? get m32 native;
 
-  set m32(num value) native;
+  set m32(num? value) native;
 
   // Shadowing definition.
 
-  num get m33 native;
+  num? get m33 native;
 
-  set m33(num value) native;
+  set m33(num? value) native;
 
   // Shadowing definition.
 
-  num get m34 native;
+  num? get m34 native;
 
-  set m34(num value) native;
+  set m34(num? value) native;
 
   // Shadowing definition.
 
-  num get m41 native;
+  num? get m41 native;
 
-  set m41(num value) native;
+  set m41(num? value) native;
 
   // Shadowing definition.
 
-  num get m42 native;
+  num? get m42 native;
 
-  set m42(num value) native;
+  set m42(num? value) native;
 
   // Shadowing definition.
 
-  num get m43 native;
+  num? get m43 native;
 
-  set m43(num value) native;
+  set m43(num? value) native;
 
   // Shadowing definition.
 
-  num get m44 native;
+  num? get m44 native;
 
-  set m44(num value) native;
+  set m44(num? value) native;
 
   static DomMatrix fromFloat32Array(Float32List array32) native;
 
@@ -10986,53 +10989,53 @@
   static DomMatrixReadOnly _create_2() =>
       JS('DomMatrixReadOnly', 'new DOMMatrixReadOnly()');
 
-  num get a native;
+  num? get a native;
 
-  num get b native;
+  num? get b native;
 
-  num get c native;
+  num? get c native;
 
-  num get d native;
+  num? get d native;
 
-  num get e native;
+  num? get e native;
 
-  num get f native;
+  num? get f native;
 
-  bool get is2D native;
+  bool? get is2D native;
 
-  bool get isIdentity native;
+  bool? get isIdentity native;
 
-  num get m11 native;
+  num? get m11 native;
 
-  num get m12 native;
+  num? get m12 native;
 
-  num get m13 native;
+  num? get m13 native;
 
-  num get m14 native;
+  num? get m14 native;
 
-  num get m21 native;
+  num? get m21 native;
 
-  num get m22 native;
+  num? get m22 native;
 
-  num get m23 native;
+  num? get m23 native;
 
-  num get m24 native;
+  num? get m24 native;
 
-  num get m31 native;
+  num? get m31 native;
 
-  num get m32 native;
+  num? get m32 native;
 
-  num get m33 native;
+  num? get m33 native;
 
-  num get m34 native;
+  num? get m34 native;
 
-  num get m41 native;
+  num? get m41 native;
 
-  num get m42 native;
+  num? get m42 native;
 
-  num get m43 native;
+  num? get m43 native;
 
-  num get m44 native;
+  num? get m44 native;
 
   DomMatrix flipX() native;
 
@@ -11168,27 +11171,27 @@
 
   // Shadowing definition.
 
-  num get w native;
+  num? get w native;
 
-  set w(num value) native;
+  set w(num? value) native;
 
   // Shadowing definition.
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
   // Shadowing definition.
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 
   // Shadowing definition.
 
-  num get z native;
+  num? get z native;
 
-  set z(num value) native;
+  set z(num? value) native;
 
   static DomPoint fromPoint([Map? other]) {
     if (other != null) {
@@ -11240,13 +11243,13 @@
   static DomPointReadOnly _create_5() =>
       JS('DomPointReadOnly', 'new DOMPointReadOnly()');
 
-  num get w native;
+  num? get w native;
 
-  num get x native;
+  num? get x native;
 
-  num get y native;
+  num? get y native;
 
-  num get z native;
+  num? get z native;
 
   static DomPointReadOnly fromPoint([Map? other]) {
     if (other != null) {
@@ -11318,13 +11321,13 @@
   static DomQuad _create_4(p1) => JS('DomQuad', 'new DOMQuad(#)', p1);
   static DomQuad _create_5() => JS('DomQuad', 'new DOMQuad()');
 
-  DomPoint get p1 native;
+  DomPoint? get p1 native;
 
-  DomPoint get p2 native;
+  DomPoint? get p2 native;
 
-  DomPoint get p3 native;
+  DomPoint? get p3 native;
 
-  DomPoint get p4 native;
+  DomPoint? get p4 native;
 
   static DomQuad fromQuad([Map? other]) {
     if (other != null) {
@@ -11539,21 +11542,57 @@
   static DomRectReadOnly _create_5() =>
       JS('DomRectReadOnly', 'new DOMRectReadOnly()');
 
-  num get bottom native;
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
 
-  num get height native;
+  @JSName('bottom')
+  num? get _bottom native;
 
-  num get left native;
+  num get bottom => _bottom!;
 
-  num get right native;
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
 
-  num get top native;
+  @JSName('height')
+  num? get _height native;
 
-  num get width native;
+  num get height => _height!;
 
-  num get x native;
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
 
-  num get y native;
+  @JSName('left')
+  num? get _left native;
+
+  num get left => _left!;
+
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
+
+  @JSName('right')
+  num? get _right native;
+
+  num get right => _right!;
+
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
+
+  @JSName('top')
+  num? get _top native;
+
+  num get top => _top!;
+
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
+
+  @JSName('width')
+  num? get _width native;
+
+  num get width => _width!;
+
+  num? get x native;
+
+  num? get y native;
 
   static DomRectReadOnly fromRect([Map? other]) {
     if (other != null) {
@@ -11659,9 +11698,9 @@
 
   int get length native;
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 
   void add(String tokens) native;
 
@@ -11722,6 +11761,10 @@
   Iterator<Element> get iterator => toList().iterator;
 
   void addAll(Iterable<Element> iterable) {
+    _addAll(_element, iterable);
+  }
+
+  static void _addAll(Element _element, Iterable<Element> iterable) {
     if (iterable is _ChildNodeListLazy) {
       iterable = new List.from(iterable);
     }
@@ -11775,6 +11818,10 @@
   }
 
   bool remove(Object? object) {
+    return _remove(_element, object);
+  }
+
+  static bool _remove(Element _element, Object? object) {
     if (object is Element) {
       Element element = object;
       if (identical(element.parentNode, _element)) {
@@ -11823,7 +11870,10 @@
     return result;
   }
 
-  Element get first {
+  Element get first => _first(_element);
+
+  @pragma('dart2js:noInline')
+  static Element _first(Element _element) {
     Element? result = _element._firstElementChild;
     if (result == null) throw new StateError("No elements");
     return result;
@@ -12965,6 +13015,16 @@
    */
   List<Element> get children => new _ChildrenElementList._wrap(this);
 
+  List<Node> get _children =>
+      // Element.children always returns the same list-like object which is a
+      // live view on the underlying DOM tree. So we can GVN it and remove it if
+      // unused.
+      JS(
+          'returns:HtmlCollection;creates:HtmlCollection;'
+              'depends:none;effects:none;gvn:true',
+          '#.children',
+          this);
+
   set children(List<Element> value) {
     // Copy list first since we don't want liveness during iteration.
     var copy = value.toList();
@@ -13105,7 +13165,7 @@
    * Gets the position of this element relative to the client area of the page.
    */
   Rectangle get client =>
-      new Rectangle(clientLeft, clientTop, clientWidth, clientHeight);
+      new Rectangle(clientLeft!, clientTop!, clientWidth, clientHeight);
 
   /**
    * Gets the offset of this element relative to its offsetParent.
@@ -13648,13 +13708,13 @@
     }
 
     if (_parseDocument == null) {
-      _parseDocument = document.implementation.createHtmlDocument('');
+      _parseDocument = document.implementation!.createHtmlDocument('');
       _parseRange = _parseDocument!.createRange();
 
       // Workaround for Safari bug. Was also previously Chrome bug 229142
       // - URIs are not resolved in new doc.
       BaseElement base = _parseDocument!.createElement('base') as BaseElement;
-      base.href = document.baseUri;
+      base.href = document.baseUri!;
       _parseDocument!.head!.append(base);
     }
 
@@ -13776,7 +13836,7 @@
     }
   }
 
-  String get innerHtml => _innerHtml;
+  String? get innerHtml => _innerHtml;
 
   @JSName('innerText')
   String get innerText native;
@@ -14449,9 +14509,9 @@
 
   set contentEditable(String value) native;
 
-  String get dir native;
+  String? get dir native;
 
-  set dir(String value) native;
+  set dir(String? value) native;
 
   /**
    * Indicates whether the element can be dragged and dropped.
@@ -14485,33 +14545,33 @@
 
   set hidden(bool value) native;
 
-  bool get inert native;
+  bool? get inert native;
 
-  set inert(bool value) native;
+  set inert(bool? value) native;
 
-  String get inputMode native;
+  String? get inputMode native;
 
-  set inputMode(String value) native;
+  set inputMode(String? value) native;
 
-  bool get isContentEditable native;
+  bool? get isContentEditable native;
 
-  String get lang native;
+  String? get lang native;
 
-  set lang(String value) native;
+  set lang(String? value) native;
 
-  bool get spellcheck native;
+  bool? get spellcheck native;
 
-  set spellcheck(bool value) native;
+  set spellcheck(bool? value) native;
 
   CssStyleDeclaration get style native;
 
-  int get tabIndex native;
+  int? get tabIndex native;
 
-  set tabIndex(int value) native;
+  set tabIndex(int? value) native;
 
-  String get title native;
+  String? get title native;
 
-  set title(String value) native;
+  set title(String? value) native;
 
   /**
    * Specifies whether this element's text content changes when the page is
@@ -14524,9 +14584,9 @@
    *   from WHATWG.
    */
 
-  bool get translate native;
+  bool? get translate native;
 
-  set translate(bool value) native;
+  set translate(bool? value) native;
 
   void blur() native;
 
@@ -14539,7 +14599,7 @@
   SlotElement? get assignedSlot native;
 
   @JSName('attributes')
-  _NamedNodeMap get _attributes native;
+  _NamedNodeMap? get _attributes native;
 
   String get className native;
 
@@ -14547,9 +14607,9 @@
 
   int get clientHeight native;
 
-  int get clientLeft native;
+  int? get clientLeft native;
 
-  int get clientTop native;
+  int? get clientTop native;
 
   int get clientWidth native;
 
@@ -14562,22 +14622,22 @@
   set id(String value) native;
 
   @JSName('innerHTML')
-  String get _innerHtml native;
+  String? get _innerHtml native;
 
   @JSName('innerHTML')
   set _innerHtml(String? value) native;
 
   @JSName('localName')
-  String get _localName native;
+  String? get _localName native;
 
   @JSName('namespaceURI')
   String? get _namespaceUri native;
 
   @JSName('outerHTML')
-  String get outerHtml native;
+  String? get outerHtml native;
 
   @JSName('scrollHeight')
-  int get _scrollHeight native;
+  int? get _scrollHeight native;
 
   @JSName('scrollLeft')
   num get _scrollLeft native;
@@ -14592,13 +14652,13 @@
   set _scrollTop(num value) native;
 
   @JSName('scrollWidth')
-  int get _scrollWidth native;
+  int? get _scrollWidth native;
 
-  String get slot native;
+  String? get slot native;
 
-  set slot(String value) native;
+  set slot(String? value) native;
 
-  StylePropertyMap get styleMap native;
+  StylePropertyMap? get styleMap native;
 
   String get tagName native;
 
@@ -14824,11 +14884,6 @@
   @JSName('childElementCount')
   int get _childElementCount native;
 
-  @JSName('children')
-  @Returns('HtmlCollection')
-  @Creates('HtmlCollection')
-  List<Node> get _children native;
-
   @JSName('firstElementChild')
   Element? get _firstElementChild native;
 
@@ -15226,9 +15281,9 @@
 
   set height(String value) native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
   String get src native;
 
@@ -15264,15 +15319,15 @@
     throw new UnsupportedError("Not supported");
   }
 
-  FileSystem get filesystem native;
+  FileSystem? get filesystem native;
 
-  String get fullPath native;
+  String? get fullPath native;
 
-  bool get isDirectory native;
+  bool? get isDirectory native;
 
-  bool get isFile native;
+  bool? get isFile native;
 
-  String get name native;
+  String? get name native;
 
   @JSName('copyTo')
   void _copyTo(DirectoryEntry parent,
@@ -15396,16 +15451,16 @@
   static ErrorEvent _create_2(type) =>
       JS('ErrorEvent', 'new ErrorEvent(#)', type);
 
-  int get colno native;
+  int? get colno native;
 
   @Creates('Null')
   Object? get error native;
 
-  String get filename native;
+  String? get filename native;
 
-  int get lineno native;
+  int? get lineno native;
 
-  String get message native;
+  String? get message native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -15510,11 +15565,11 @@
    */
   static const int CAPTURING_PHASE = 1;
 
-  bool get bubbles native;
+  bool? get bubbles native;
 
-  bool get cancelable native;
+  bool? get cancelable native;
 
-  bool get composed native;
+  bool? get composed native;
 
   EventTarget? get currentTarget =>
       _convertNativeToDart_EventTarget(this._get_currentTarget);
@@ -15527,7 +15582,7 @@
 
   int get eventPhase native;
 
-  bool get isTrusted native;
+  bool? get isTrusted native;
 
   EventTarget? get target => _convertNativeToDart_EventTarget(this._get_target);
   @JSName('target')
@@ -15535,7 +15590,7 @@
   @Returns('EventTarget|=Object')
   dynamic get _get_target native;
 
-  num get timeStamp native;
+  num? get timeStamp native;
 
   String get type native;
 
@@ -15615,11 +15670,11 @@
 
   static const int OPEN = 1;
 
-  int get readyState native;
+  int? get readyState native;
 
-  String get url native;
+  String? get url native;
 
-  bool get withCredentials native;
+  bool? get withCredentials native;
 
   void close() native;
 
@@ -15806,11 +15861,11 @@
   @annotation_Returns_SerializedScriptValue
   Object? get data native;
 
-  String get lastEventId native;
+  String? get lastEventId native;
 
-  String get origin native;
+  String? get origin native;
 
-  List<MessagePort> get ports native;
+  List<MessagePort>? get ports native;
 
   @Creates('Client|ServiceWorker|MessagePort')
   @Returns('Client|ServiceWorker|MessagePort|Null')
@@ -15877,14 +15932,14 @@
 
   String? get protocol native;
 
-  String get provider native;
+  String? get provider native;
 
   // From CredentialUserData
 
   @JSName('iconURL')
-  String get iconUrl native;
+  String? get iconUrl native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -15906,12 +15961,12 @@
 
   String? get clientId native;
 
-  bool get isReload native;
+  bool? get isReload native;
 
   Future get preloadResponse =>
       promiseToFuture(JS("", "#.preloadResponse", this));
 
-  _Request get request native;
+  _Request? get request native;
 
   void respondWith(Future r) native;
 }
@@ -15945,7 +16000,7 @@
 
   @Returns('HtmlCollection')
   @Creates('HtmlCollection')
-  List<Node> get elements native;
+  List<Node>? get elements native;
 
   FormElement? get form native;
 
@@ -15990,7 +16045,7 @@
   static File _create_2(fileBits, fileName) =>
       JS('File', 'new File(#,#)', fileBits, fileName);
 
-  int get lastModified native;
+  int? get lastModified native;
 
   DateTime get lastModifiedDate =>
       convertNativeToDart_DateTime(this._get_lastModifiedDate);
@@ -16003,7 +16058,7 @@
   @JSName('webkitRelativePath')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  String get relativePath native;
+  String? get relativePath native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16245,9 +16300,9 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => JS('bool', '!!(window.webkitRequestFileSystem)');
 
-  String get name native;
+  String? get name native;
 
-  DirectoryEntry get root native;
+  DirectoryEntry? get root native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16329,11 +16384,11 @@
 
   DomException? get error native;
 
-  int get length native;
+  int? get length native;
 
-  int get position native;
+  int? get position native;
 
-  int get readyState native;
+  int? get readyState native;
 
   void abort() native;
 
@@ -16420,42 +16475,42 @@
   static FontFace _create_2(family, source) =>
       JS('FontFace', 'new FontFace(#,#)', family, source);
 
-  String get display native;
+  String? get display native;
 
-  set display(String value) native;
+  set display(String? value) native;
 
-  String get family native;
+  String? get family native;
 
-  set family(String value) native;
+  set family(String? value) native;
 
-  String get featureSettings native;
+  String? get featureSettings native;
 
-  set featureSettings(String value) native;
+  set featureSettings(String? value) native;
 
   Future<FontFace> get loaded =>
       promiseToFuture<FontFace>(JS("", "#.loaded", this));
 
-  String get status native;
+  String? get status native;
 
-  String get stretch native;
+  String? get stretch native;
 
-  set stretch(String value) native;
+  set stretch(String? value) native;
 
-  String get style native;
+  String? get style native;
 
-  set style(String value) native;
+  set style(String? value) native;
 
-  String get unicodeRange native;
+  String? get unicodeRange native;
 
-  set unicodeRange(String value) native;
+  set unicodeRange(String? value) native;
 
-  String get variant native;
+  String? get variant native;
 
-  set variant(String value) native;
+  set variant(String? value) native;
 
-  String get weight native;
+  String? get weight native;
 
-  set weight(String value) native;
+  set weight(String? value) native;
 
   Future<FontFace> load() =>
       promiseToFuture<FontFace>(JS("", "#.load()", this));
@@ -16480,7 +16535,7 @@
   static const EventStreamProvider<FontFaceSetLoadEvent> loadingErrorEvent =
       const EventStreamProvider<FontFaceSetLoadEvent>('loadingerror');
 
-  String get status native;
+  String? get status native;
 
   FontFaceSet add(FontFace arg) native;
 
@@ -16528,7 +16583,7 @@
   static FontFaceSetLoadEvent _create_2(type) =>
       JS('FontFaceSetLoadEvent', 'new FontFaceSetLoadEvent(#)', type);
 
-  List<FontFace> get fontfaces native;
+  List<FontFace>? get fontfaces native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16541,7 +16596,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  FontFaceSet get fonts native;
+  FontFaceSet? get fonts native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16561,9 +16616,9 @@
   static ForeignFetchEvent _create_1(type, eventInitDict) => JS(
       'ForeignFetchEvent', 'new ForeignFetchEvent(#,#)', type, eventInitDict);
 
-  String get origin native;
+  String? get origin native;
 
-  _Request get request native;
+  _Request? get request native;
 
   void respondWith(Future r) native;
 }
@@ -16632,43 +16687,43 @@
    */
   FormElement.created() : super.created();
 
-  String get acceptCharset native;
+  String? get acceptCharset native;
 
-  set acceptCharset(String value) native;
+  set acceptCharset(String? value) native;
 
-  String get action native;
+  String? get action native;
 
-  set action(String value) native;
+  set action(String? value) native;
 
-  String get autocomplete native;
+  String? get autocomplete native;
 
-  set autocomplete(String value) native;
+  set autocomplete(String? value) native;
 
-  String get encoding native;
+  String? get encoding native;
 
-  set encoding(String value) native;
+  set encoding(String? value) native;
 
-  String get enctype native;
+  String? get enctype native;
 
-  set enctype(String value) native;
+  set enctype(String? value) native;
 
-  int get length native;
+  int? get length native;
 
-  String get method native;
+  String? get method native;
 
-  set method(String value) native;
+  set method(String? value) native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  bool get noValidate native;
+  bool? get noValidate native;
 
-  set noValidate(bool value) native;
+  set noValidate(bool? value) native;
 
-  String get target native;
+  String? get target native;
 
-  set target(String value) native;
+  set target(String? value) native;
 
   Object? __getter__(String name) native;
 
@@ -16716,27 +16771,27 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List<num> get axes native;
+  List<num>? get axes native;
 
   @Creates('JSExtendableArray|GamepadButton')
   @Returns('JSExtendableArray')
-  List<GamepadButton> get buttons native;
+  List<GamepadButton>? get buttons native;
 
-  bool get connected native;
+  bool? get connected native;
 
-  int get displayId native;
+  int? get displayId native;
 
-  String get hand native;
+  String? get hand native;
 
-  String get id native;
+  String? get id native;
 
-  int get index native;
+  int? get index native;
 
-  String get mapping native;
+  String? get mapping native;
 
   GamepadPose? get pose native;
 
-  int get timestamp native;
+  int? get timestamp native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16749,11 +16804,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get pressed native;
+  bool? get pressed native;
 
-  bool get touched native;
+  bool? get touched native;
 
-  num get value native;
+  num? get value native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16778,7 +16833,7 @@
   static GamepadEvent _create_2(type) =>
       JS('GamepadEvent', 'new GamepadEvent(#)', type);
 
-  Gamepad get gamepad native;
+  Gamepad? get gamepad native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -16795,9 +16850,9 @@
 
   Float32List? get angularVelocity native;
 
-  bool get hasOrientation native;
+  bool? get hasOrientation native;
 
-  bool get hasPosition native;
+  bool? get hasPosition native;
 
   Float32List? get linearAcceleration native;
 
@@ -16965,9 +17020,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Coordinates get coords native;
+  Coordinates? get coords native;
 
-  int get timestamp native;
+  int? get timestamp native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -17377,10 +17432,10 @@
   static bool get supported => Device.isEventTypeSupported('HashChangeEvent');
 
   @JSName('newURL')
-  String get newUrl native;
+  String? get newUrl native;
 
   @JSName('oldURL')
-  String get oldUrl native;
+  String? get oldUrl native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -17501,9 +17556,9 @@
 
   int get length native;
 
-  String get scrollRestoration native;
+  String? get scrollRestoration native;
 
-  set scrollRestoration(String value) native;
+  set scrollRestoration(String? value) native;
 
   dynamic get state =>
       convertNativeToDart_SerializedScriptValue(this._get_state);
@@ -17642,7 +17697,7 @@
 
   HeadElement? get head => _head;
 
-  String get lastModified => _lastModified;
+  String? get lastModified => _lastModified;
 
   String? get preferredStylesheetSet => _preferredStylesheetSet;
 
@@ -17653,7 +17708,7 @@
     _selectedStylesheetSet = value;
   }
 
-  List<StyleSheet> get styleSheets => _styleSheets;
+  List<StyleSheet>? get styleSheets => _styleSheets;
 
   String get title => _title;
 
@@ -17821,47 +17876,47 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get hash native;
+  String? get hash native;
 
-  set hash(String value) native;
+  set hash(String? value) native;
 
-  String get host native;
+  String? get host native;
 
-  set host(String value) native;
+  set host(String? value) native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  set hostname(String value) native;
+  set hostname(String? value) native;
 
-  String get href native;
+  String? get href native;
 
-  set href(String value) native;
+  set href(String? value) native;
 
-  String get origin native;
+  String? get origin native;
 
-  String get password native;
+  String? get password native;
 
-  set password(String value) native;
+  set password(String? value) native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  set pathname(String value) native;
+  set pathname(String? value) native;
 
-  String get port native;
+  String? get port native;
 
-  set port(String value) native;
+  set port(String? value) native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  set protocol(String value) native;
+  set protocol(String? value) native;
 
-  String get search native;
+  String? get search native;
 
-  set search(String value) native;
+  set search(String? value) native;
 
-  String get username native;
+  String? get username native;
 
-  set username(String value) native;
+  set username(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -17953,7 +18008,7 @@
       {bool? withCredentials, void onProgress(ProgressEvent e)?}) {
     return request(url,
             withCredentials: withCredentials, onProgress: onProgress)
-        .then((HttpRequest xhr) => xhr.responseText);
+        .then((HttpRequest xhr) => xhr.responseText!);
   }
 
   /**
@@ -18101,15 +18156,16 @@
     }
 
     xhr.onLoad.listen((e) {
-      var accepted = xhr.status >= 200 && xhr.status < 300;
-      var fileUri = xhr.status == 0; // file:// URIs have status of 0.
-      var notModified = xhr.status == 304;
+      var status = xhr.status!;
+      var accepted = status >= 200 && status < 300;
+      var fileUri = status == 0; // file:// URIs have status of 0.
+      var notModified = status == 304;
       // Redirect status is specified up to 307, but others have been used in
       // practice. Notably Google Drive uses 308 Resume Incomplete for
       // resumable uploads, and it's also been used as a redirect. The
       // redirect case will be handled by the browser before it gets to us,
       // so if we see it we should pass it through to the user.
-      var unknownRedirect = xhr.status > 307 && xhr.status < 400;
+      var unknownRedirect = status > 307 && status < 400;
 
       if (accepted || fileUri || notModified || unknownRedirect) {
         completer.complete(xhr);
@@ -18176,7 +18232,7 @@
       {String? method, String? sendData}) {
     if (supportsCrossOrigin) {
       return request(url, method: method, sendData: sendData).then((xhr) {
-        return xhr.responseText;
+        return xhr.responseText!;
       });
     }
     var completer = new Completer<String>();
@@ -18383,7 +18439,7 @@
    * The response in String form or empty String on failure.
    */
 
-  String get responseText native;
+  String? get responseText native;
 
   /**
    * [String] telling the server the desired response format.
@@ -18402,7 +18458,7 @@
   set responseType(String value) native;
 
   @JSName('responseURL')
-  String get responseUrl native;
+  String? get responseUrl native;
 
   @JSName('responseXML')
 
@@ -18421,14 +18477,14 @@
    * See also: [HTTP Status Codes](http://en.wikipedia.org/wiki/List_of_HTTP_status_codes)
    */
 
-  int get status native;
+  int? get status native;
 
   /**
    * The request response string (such as \"OK\").
    * See also: [HTTP Status Codes](http://en.wikipedia.org/wiki/List_of_HTTP_status_codes)
    */
 
-  String get statusText native;
+  String? get statusText native;
 
   /**
    * Length of time in milliseconds before a request is automatically
@@ -18446,9 +18502,9 @@
    *   from W3C.
    */
 
-  int get timeout native;
+  int? get timeout native;
 
-  set timeout(int value) native;
+  set timeout(int? value) native;
 
   /**
    * [EventTarget] that can hold listeners to track the progress of the request.
@@ -18464,9 +18520,9 @@
    * This value is ignored for same-site requests.
    */
 
-  bool get withCredentials native;
+  bool? get withCredentials native;
 
-  set withCredentials(bool value) native;
+  set withCredentials(bool? value) native;
 
   /**
    * Stop the current request.
@@ -18691,17 +18747,17 @@
    */
   IFrameElement.created() : super.created();
 
-  String get allow native;
+  String? get allow native;
 
-  set allow(String value) native;
+  set allow(String? value) native;
 
-  bool get allowFullscreen native;
+  bool? get allowFullscreen native;
 
-  set allowFullscreen(bool value) native;
+  set allowFullscreen(bool? value) native;
 
-  bool get allowPaymentRequest native;
+  bool? get allowPaymentRequest native;
 
-  set allowPaymentRequest(bool value) native;
+  set allowPaymentRequest(bool? value) native;
 
   WindowBase? get contentWindow =>
       _convertNativeToDart_Window(this._get_contentWindow);
@@ -18710,35 +18766,35 @@
   @Returns('Window|=Object')
   dynamic get _get_contentWindow native;
 
-  String get csp native;
+  String? get csp native;
 
-  set csp(String value) native;
+  set csp(String? value) native;
 
-  String get height native;
+  String? get height native;
 
-  set height(String value) native;
+  set height(String? value) native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  set referrerPolicy(String value) native;
+  set referrerPolicy(String? value) native;
 
-  DomTokenList get sandbox native;
+  DomTokenList? get sandbox native;
 
-  String get src native;
+  String? get src native;
 
-  set src(String value) native;
+  set src(String? value) native;
 
-  String get srcdoc native;
+  String? get srcdoc native;
 
-  set srcdoc(String value) native;
+  set srcdoc(String? value) native;
 
-  String get width native;
+  String? get width native;
 
-  set width(String value) native;
+  set width(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -18751,7 +18807,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get didTimeout native;
+  bool? get didTimeout native;
 
   double timeRemaining() native;
 }
@@ -18773,9 +18829,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get height native;
+  int? get height native;
 
-  int get width native;
+  int? get width native;
 
   void close() native;
 }
@@ -18790,7 +18846,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  CanvasElement get canvas native;
+  CanvasElement? get canvas native;
 
   void transferFromImageBitmap(ImageBitmap? bitmap) native;
 }
@@ -18811,7 +18867,7 @@
   static ImageCapture _create_1(track) =>
       JS('ImageCapture', 'new ImageCapture(#)', track);
 
-  MediaStreamTrack get track native;
+  MediaStreamTrack? get track native;
 
   Future<PhotoCapabilities> getPhotoCapabilities() =>
       promiseToFuture<PhotoCapabilities>(
@@ -18904,57 +18960,57 @@
    */
   ImageElement.created() : super.created();
 
-  String get alt native;
+  String? get alt native;
 
-  set alt(String value) native;
+  set alt(String? value) native;
 
-  String get async native;
+  String? get async native;
 
-  set async(String value) native;
+  set async(String? value) native;
 
-  bool get complete native;
+  bool? get complete native;
 
   String? get crossOrigin native;
 
   set crossOrigin(String? value) native;
 
-  String get currentSrc native;
+  String? get currentSrc native;
 
-  int get height native;
+  int? get height native;
 
-  set height(int value) native;
+  set height(int? value) native;
 
-  bool get isMap native;
+  bool? get isMap native;
 
-  set isMap(bool value) native;
+  set isMap(bool? value) native;
 
   int get naturalHeight native;
 
   int get naturalWidth native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  set referrerPolicy(String value) native;
+  set referrerPolicy(String? value) native;
 
-  String get sizes native;
+  String? get sizes native;
 
-  set sizes(String value) native;
+  set sizes(String? value) native;
 
-  String get src native;
+  String? get src native;
 
-  set src(String value) native;
+  set src(String? value) native;
 
-  String get srcset native;
+  String? get srcset native;
 
-  set srcset(String value) native;
+  set srcset(String? value) native;
 
-  String get useMap native;
+  String? get useMap native;
 
-  set useMap(String value) native;
+  set useMap(String? value) native;
 
-  int get width native;
+  int? get width native;
 
-  set width(int value) native;
+  set width(int? value) native;
 
   Future decode() => promiseToFuture(JS("", "#.decode()", this));
 }
@@ -18983,7 +19039,7 @@
   static InputDeviceCapabilities _create_2() =>
       JS('InputDeviceCapabilities', 'new InputDeviceCapabilities()');
 
-  bool get firesTouchEvents native;
+  bool? get firesTouchEvents native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -19035,17 +19091,17 @@
    */
   InputElement.created() : super.created();
 
-  String get accept native;
+  String? get accept native;
 
-  set accept(String value) native;
+  set accept(String? value) native;
 
-  String get alt native;
+  String? get alt native;
 
-  set alt(String value) native;
+  set alt(String? value) native;
 
-  String get autocapitalize native;
+  String? get autocapitalize native;
 
-  set autocapitalize(String value) native;
+  set autocapitalize(String? value) native;
 
   String get autocomplete native;
 
@@ -19055,29 +19111,29 @@
 
   set autofocus(bool value) native;
 
-  String get capture native;
+  String? get capture native;
 
-  set capture(String value) native;
+  set capture(String? value) native;
 
-  bool get checked native;
+  bool? get checked native;
 
-  set checked(bool value) native;
+  set checked(bool? value) native;
 
-  bool get defaultChecked native;
+  bool? get defaultChecked native;
 
-  set defaultChecked(bool value) native;
+  set defaultChecked(bool? value) native;
 
-  String get defaultValue native;
+  String? get defaultValue native;
 
-  set defaultValue(String value) native;
+  set defaultValue(String? value) native;
 
-  String get dirName native;
+  String? get dirName native;
 
-  set dirName(String value) native;
+  set dirName(String? value) native;
 
-  bool get disabled native;
+  bool? get disabled native;
 
-  set disabled(bool value) native;
+  set disabled(bool? value) native;
 
   @Returns('FileList|Null')
   @Creates('FileList')
@@ -19107,47 +19163,47 @@
 
   set formTarget(String value) native;
 
-  int get height native;
+  int? get height native;
 
-  set height(int value) native;
+  set height(int? value) native;
 
-  bool get incremental native;
+  bool? get incremental native;
 
-  set incremental(bool value) native;
+  set incremental(bool? value) native;
 
-  bool get indeterminate native;
+  bool? get indeterminate native;
 
-  set indeterminate(bool value) native;
+  set indeterminate(bool? value) native;
 
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
   HtmlElement? get list native;
 
-  String get max native;
+  String? get max native;
 
-  set max(String value) native;
+  set max(String? value) native;
 
-  int get maxLength native;
+  int? get maxLength native;
 
-  set maxLength(int value) native;
+  set maxLength(int? value) native;
 
-  String get min native;
+  String? get min native;
 
-  set min(String value) native;
+  set min(String? value) native;
 
-  int get minLength native;
+  int? get minLength native;
 
-  set minLength(int value) native;
+  set minLength(int? value) native;
 
-  bool get multiple native;
+  bool? get multiple native;
 
-  set multiple(bool value) native;
+  set multiple(bool? value) native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
   String get pattern native;
 
@@ -19157,9 +19213,9 @@
 
   set placeholder(String value) native;
 
-  bool get readOnly native;
+  bool? get readOnly native;
 
-  set readOnly(bool value) native;
+  set readOnly(bool? value) native;
 
   bool get required native;
 
@@ -19177,27 +19233,27 @@
 
   set selectionStart(int? value) native;
 
-  int get size native;
+  int? get size native;
 
-  set size(int value) native;
+  set size(int? value) native;
 
-  String get src native;
+  String? get src native;
 
-  set src(String value) native;
+  set src(String? value) native;
 
-  String get step native;
+  String? get step native;
 
-  set step(String value) native;
+  set step(String? value) native;
 
-  String get type native;
+  String? get type native;
 
-  set type(String value) native;
+  set type(String? value) native;
 
   String get validationMessage native;
 
   ValidityState get validity native;
 
-  String get value native;
+  String? get value native;
 
   set value(String? value) native;
 
@@ -19215,26 +19271,26 @@
     JS("void", "#.valueAsDate = #", this, value);
   }
 
-  num get valueAsNumber native;
+  num? get valueAsNumber native;
 
-  set valueAsNumber(num value) native;
+  set valueAsNumber(num? value) native;
 
   @JSName('webkitEntries')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  List<Entry> get entries native;
+  List<Entry>? get entries native;
 
   @JSName('webkitdirectory')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  bool get directory native;
+  bool? get directory native;
 
   @JSName('webkitdirectory')
-  set directory(bool value) native;
+  set directory(bool? value) native;
 
-  int get width native;
+  int? get width native;
 
-  set width(int value) native;
+  set width(int? value) native;
 
   bool get willValidate native;
 
@@ -19267,22 +19323,22 @@
   bool get autofocus;
   set autofocus(bool value);
 
-  bool get disabled;
-  set disabled(bool value);
+  bool? get disabled;
+  set disabled(bool? value);
 
-  bool get incremental;
-  set incremental(bool value);
+  bool? get incremental;
+  set incremental(bool? value);
 
-  bool get indeterminate;
-  set indeterminate(bool value);
+  bool? get indeterminate;
+  set indeterminate(bool? value);
 
-  String get name;
-  set name(String value);
+  String? get name;
+  set name(String? value);
 
-  String get value;
+  String? get value;
   set value(String? value);
 
-  List<Node> get labels;
+  List<Node>? get labels;
 
   String get validationMessage;
 
@@ -19309,8 +19365,8 @@
   String get autocomplete;
   set autocomplete(String value);
 
-  int get maxLength;
-  set maxLength(int value);
+  int? get maxLength;
+  set maxLength(int? value);
 
   String get pattern;
   set pattern(String value);
@@ -19318,14 +19374,14 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
 
-  int get size;
-  set size(int value);
+  int? get size;
+  set size(int? value);
 
   void select();
 
@@ -19354,8 +19410,8 @@
 abstract class SearchInputElement implements TextInputElementBase {
   factory SearchInputElement() => new InputElement(type: 'search');
 
-  String get dirName;
-  set dirName(String value);
+  String? get dirName;
+  set dirName(String? value);
 
   Element? get list;
 
@@ -19371,8 +19427,8 @@
 abstract class TextInputElement implements TextInputElementBase {
   factory TextInputElement() => new InputElement(type: 'text');
 
-  String get dirName;
-  set dirName(String value);
+  String? get dirName;
+  set dirName(String? value);
 
   Element? get list;
 }
@@ -19440,11 +19496,11 @@
 
   Element? get list;
 
-  int get maxLength;
-  set maxLength(int value);
+  int? get maxLength;
+  set maxLength(int? value);
 
-  bool get multiple;
-  set multiple(bool value);
+  bool? get multiple;
+  set multiple(bool? value);
 
   String get pattern;
   set pattern(String value);
@@ -19452,14 +19508,14 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
 
-  int get size;
-  set size(int value);
+  int? get size;
+  set size(int? value);
 
   /// Returns true if this input type is supported on the current platform.
   static bool get supported {
@@ -19480,17 +19536,17 @@
 abstract class RangeInputElementBase implements InputElementBase {
   Element? get list;
 
-  String get max;
-  set max(String value);
+  String? get max;
+  set max(String? value);
 
-  String get min;
-  set min(String value);
+  String? get min;
+  set min(String? value);
 
-  String get step;
-  set step(String value);
+  String? get step;
+  set step(String? value);
 
-  num get valueAsNumber;
-  set valueAsNumber(num value);
+  num? get valueAsNumber;
+  set valueAsNumber(num? value);
 
   void stepDown([int? n]);
 
@@ -19509,8 +19565,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19533,8 +19589,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19557,8 +19613,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19581,8 +19637,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19604,8 +19660,8 @@
   factory LocalDateTimeInputElement() =>
       new InputElement(type: 'datetime-local');
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19628,8 +19684,8 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool? get readOnly;
+  set readOnly(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19666,8 +19722,8 @@
 abstract class CheckboxInputElement implements InputElementBase {
   factory CheckboxInputElement() => new InputElement(type: 'checkbox');
 
-  bool get checked;
-  set checked(bool value);
+  bool? get checked;
+  set checked(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19687,8 +19743,8 @@
 abstract class RadioButtonInputElement implements InputElementBase {
   factory RadioButtonInputElement() => new InputElement(type: 'radio');
 
-  bool get checked;
-  set checked(bool value);
+  bool? get checked;
+  set checked(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19700,11 +19756,11 @@
 abstract class FileUploadInputElement implements InputElementBase {
   factory FileUploadInputElement() => new InputElement(type: 'file');
 
-  String get accept;
-  set accept(String value);
+  String? get accept;
+  set accept(String? value);
 
-  bool get multiple;
-  set multiple(bool value);
+  bool? get multiple;
+  set multiple(bool? value);
 
   bool get required;
   set required(bool value);
@@ -19741,8 +19797,8 @@
 abstract class ImageButtonInputElement implements InputElementBase {
   factory ImageButtonInputElement() => new InputElement(type: 'image');
 
-  String get alt;
-  set alt(String value);
+  String? get alt;
+  set alt(String? value);
 
   String get formAction;
   set formAction(String value);
@@ -19759,14 +19815,14 @@
   String get formTarget;
   set formTarget(String value);
 
-  int get height;
-  set height(int value);
+  int? get height;
+  set height(int? value);
 
-  String get src;
-  set src(String value);
+  String? get src;
+  set src(String? value);
 
-  int get width;
-  set width(int value);
+  int? get width;
+  set width(int? value);
 }
 
 /**
@@ -19845,9 +19901,9 @@
 
   Element? get root native;
 
-  String get rootMargin native;
+  String? get rootMargin native;
 
-  List<num> get thresholds native;
+  List<num>? get thresholds native;
 
   void disconnect() native;
 
@@ -19876,19 +19932,19 @@
     throw new UnsupportedError("Not supported");
   }
 
-  DomRectReadOnly get boundingClientRect native;
+  DomRectReadOnly? get boundingClientRect native;
 
-  num get intersectionRatio native;
+  num? get intersectionRatio native;
 
-  DomRectReadOnly get intersectionRect native;
+  DomRectReadOnly? get intersectionRect native;
 
-  bool get isIntersecting native;
+  bool? get isIntersecting native;
 
   DomRectReadOnly? get rootBounds native;
 
-  Element get target native;
+  Element? get target native;
 
-  num get time native;
+  num? get time native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -19901,11 +19957,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get lineNumber native;
+  int? get lineNumber native;
 
-  String get message native;
+  String? get message native;
 
-  String get sourceFile native;
+  String? get sourceFile native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -19993,7 +20049,7 @@
 
   int get charCode native;
 
-  int get which => _which;
+  int? get which => _which;
 
   factory KeyboardEvent._(String type, [Map? eventInitDict]) {
     if (eventInitDict != null) {
@@ -20020,13 +20076,13 @@
   @JSName('charCode')
   int get _charCode native;
 
-  String get code native;
+  String? get code native;
 
   bool get ctrlKey native;
 
-  bool get isComposing native;
+  bool? get isComposing native;
 
-  String get key native;
+  String? get key native;
 
   @JSName('keyCode')
   int get _keyCode native;
@@ -20035,7 +20091,7 @@
 
   bool get metaKey native;
 
-  bool get repeat native;
+  bool? get repeat native;
 
   bool get shiftKey native;
 
@@ -20224,17 +20280,17 @@
    */
   LinkElement.created() : super.created();
 
-  String get as native;
+  String? get as native;
 
-  set as(String value) native;
+  set as(String? value) native;
 
   String? get crossOrigin native;
 
   set crossOrigin(String? value) native;
 
-  bool get disabled native;
+  bool? get disabled native;
 
-  set disabled(bool value) native;
+  set disabled(bool? value) native;
 
   String get href native;
 
@@ -20246,31 +20302,31 @@
 
   Document? get import native;
 
-  String get integrity native;
+  String? get integrity native;
 
-  set integrity(String value) native;
+  set integrity(String? value) native;
 
   String get media native;
 
   set media(String value) native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  set referrerPolicy(String value) native;
+  set referrerPolicy(String? value) native;
 
   String get rel native;
 
   set rel(String value) native;
 
-  DomTokenList get relList native;
+  DomTokenList? get relList native;
 
-  String get scope native;
+  String? get scope native;
 
-  set scope(String value) native;
+  set scope(String? value) native;
 
   StyleSheet? get sheet native;
 
-  DomTokenList get sizes native;
+  DomTokenList? get sizes native;
 
   String get type native;
 
@@ -20294,7 +20350,7 @@
 
   @Returns('DomStringList')
   @Creates('DomStringList')
-  List<String> get ancestorOrigins native;
+  List<String>? get ancestorOrigins native;
 
   String get hash native;
 
@@ -20304,17 +20360,17 @@
 
   set host(String value) native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  set hostname(String value) native;
+  set hostname(String? value) native;
 
   String get href native;
 
   set href(String value) native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  set pathname(String value) native;
+  set pathname(String? value) native;
 
   String get port native;
 
@@ -20324,13 +20380,13 @@
 
   set protocol(String value) native;
 
-  String get search native;
+  String? get search native;
 
-  set search(String value) native;
+  set search(String? value) native;
 
-  TrustedUrl get trustedHref native;
+  TrustedUrl? get trustedHref native;
 
-  set trustedHref(TrustedUrl value) native;
+  set trustedHref(TrustedUrl? value) native;
 
   void assign([String? url]) native;
 
@@ -20440,11 +20496,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get powerEfficient native;
+  bool? get powerEfficient native;
 
-  bool get smooth native;
+  bool? get smooth native;
 
-  bool get supported native;
+  bool? get supported native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20457,13 +20513,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get deviceId native;
+  String? get deviceId native;
 
-  String get groupId native;
+  String? get groupId native;
 
-  String get kind native;
+  String? get kind native;
 
-  String get label native;
+  String? get label native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20531,7 +20587,7 @@
 
   static const int NETWORK_NO_SOURCE = 3;
 
-  AudioTrackList get audioTracks native;
+  AudioTrackList? get audioTracks native;
 
   bool get autoplay native;
 
@@ -20543,7 +20599,7 @@
 
   set controls(bool value) native;
 
-  DomTokenList get controlsList native;
+  DomTokenList? get controlsList native;
 
   String? get crossOrigin native;
 
@@ -20555,9 +20611,9 @@
 
   set currentTime(num value) native;
 
-  bool get defaultMuted native;
+  bool? get defaultMuted native;
 
-  set defaultMuted(bool value) native;
+  set defaultMuted(bool? value) native;
 
   num get defaultPlaybackRate native;
 
@@ -20577,13 +20633,13 @@
 
   set loop(bool value) native;
 
-  MediaKeys get mediaKeys native;
+  MediaKeys? get mediaKeys native;
 
   bool get muted native;
 
   set muted(bool value) native;
 
-  int get networkState native;
+  int? get networkState native;
 
   bool get paused native;
 
@@ -20599,25 +20655,25 @@
 
   int get readyState native;
 
-  RemotePlayback get remote native;
+  RemotePlayback? get remote native;
 
   TimeRanges get seekable native;
 
   bool get seeking native;
 
-  String get sinkId native;
+  String? get sinkId native;
 
   String get src native;
 
   set src(String value) native;
 
-  MediaStream get srcObject native;
+  MediaStream? get srcObject native;
 
-  set srcObject(MediaStream value) native;
+  set srcObject(MediaStream? value) native;
 
-  TextTrackList get textTracks native;
+  TextTrackList? get textTracks native;
 
-  VideoTrackList get videoTracks native;
+  VideoTrackList? get videoTracks native;
 
   num get volume native;
 
@@ -20626,12 +20682,12 @@
   @JSName('webkitAudioDecodedByteCount')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  int get audioDecodedByteCount native;
+  int? get audioDecodedByteCount native;
 
   @JSName('webkitVideoDecodedByteCount')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  int get videoDecodedByteCount native;
+  int? get videoDecodedByteCount native;
 
   TextTrack addTextTrack(String kind, [String? label, String? language]) native;
 
@@ -20680,7 +20736,7 @@
 
   ByteBuffer? get initData native;
 
-  String get initDataType native;
+  String? get initDataType native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20704,7 +20760,7 @@
 
   int get code native;
 
-  String get message native;
+  String? get message native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20727,9 +20783,9 @@
       type,
       eventInitDict);
 
-  ByteBuffer get message native;
+  ByteBuffer? get message native;
 
-  String get messageType native;
+  String? get messageType native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20747,11 +20803,11 @@
 
   Future<void> get closed => promiseToFuture<void>(JS("", "#.closed", this));
 
-  num get expiration native;
+  num? get expiration native;
 
-  MediaKeyStatusMap get keyStatuses native;
+  MediaKeyStatusMap? get keyStatuses native;
 
-  String get sessionId native;
+  String? get sessionId native;
 
   Future close() => promiseToFuture(JS("", "#.close()", this));
 
@@ -20780,7 +20836,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get size native;
+  int? get size native;
 
   Object? get(/*BufferSource*/ keyId) native;
 
@@ -20797,7 +20853,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get keySystem native;
+  String? get keySystem native;
 
   Future createMediaKeys() =>
       promiseToFuture(JS("", "#.createMediaKeys()", this));
@@ -20848,7 +20904,7 @@
   static MediaKeysPolicy _create_1(init) =>
       JS('MediaKeysPolicy', 'new MediaKeysPolicy(#)', init);
 
-  String get minHdcpVersion native;
+  String? get minHdcpVersion native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20862,7 +20918,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get length native;
+  int? get length native;
 
   String? get mediaText native;
 
@@ -20897,21 +20953,21 @@
   static MediaMetadata _create_2() =>
       JS('MediaMetadata', 'new MediaMetadata()');
 
-  String get album native;
+  String? get album native;
 
-  set album(String value) native;
+  set album(String? value) native;
 
-  String get artist native;
+  String? get artist native;
 
-  set artist(String value) native;
+  set artist(String? value) native;
 
-  List get artwork native;
+  List? get artwork native;
 
-  set artwork(List value) native;
+  set artwork(List? value) native;
 
-  String get title native;
+  String? get title native;
 
-  set title(String value) native;
+  set title(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20964,9 +21020,9 @@
   static MediaQueryListEvent _create_2(type) =>
       JS('MediaQueryListEvent', 'new MediaQueryListEvent(#)', type);
 
-  bool get matches native;
+  bool? get matches native;
 
-  String get media native;
+  String? get media native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -20997,15 +21053,15 @@
   static MediaRecorder _create_2(stream) =>
       JS('MediaRecorder', 'new MediaRecorder(#)', stream);
 
-  int get audioBitsPerSecond native;
+  int? get audioBitsPerSecond native;
 
-  String get mimeType native;
+  String? get mimeType native;
 
-  String get state native;
+  String? get state native;
 
-  MediaStream get stream native;
+  MediaStream? get stream native;
 
-  int get videoBitsPerSecond native;
+  int? get videoBitsPerSecond native;
 
   static bool isTypeSupported(String type) native;
 
@@ -21038,9 +21094,9 @@
 
   set metadata(MediaMetadata? value) native;
 
-  String get playbackState native;
+  String? get playbackState native;
 
-  set playbackState(String value) native;
+  set playbackState(String? value) native;
 
   void setActionHandler(String action, MediaSessionActionHandler? handler)
       native;
@@ -21063,11 +21119,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get max native;
+  num? get max native;
 
-  num get min native;
+  num? get min native;
 
-  num get step native;
+  num? get step native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21090,15 +21146,15 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => JS('bool', '!!(window.MediaSource)');
 
-  SourceBufferList get activeSourceBuffers native;
+  SourceBufferList? get activeSourceBuffers native;
 
-  num get duration native;
+  num? get duration native;
 
-  set duration(num value) native;
+  set duration(num? value) native;
 
-  String get readyState native;
+  String? get readyState native;
 
-  SourceBufferList get sourceBuffers native;
+  SourceBufferList? get sourceBuffers native;
 
   SourceBuffer addSourceBuffer(String type) native;
 
@@ -21160,9 +21216,9 @@
   static MediaStream _create_3(stream_OR_tracks) =>
       JS('MediaStream', 'new MediaStream(#)', stream_OR_tracks);
 
-  bool get active native;
+  bool? get active native;
 
-  String get id native;
+  String? get id native;
 
   void addTrack(MediaStreamTrack track) native;
 
@@ -21272,23 +21328,23 @@
   static const EventStreamProvider<Event> unmuteEvent =
       const EventStreamProvider<Event>('unmute');
 
-  String get contentHint native;
+  String? get contentHint native;
 
-  set contentHint(String value) native;
+  set contentHint(String? value) native;
 
-  bool get enabled native;
+  bool? get enabled native;
 
-  set enabled(bool value) native;
+  set enabled(bool? value) native;
 
-  String get id native;
+  String? get id native;
 
-  String get kind native;
+  String? get kind native;
 
-  String get label native;
+  String? get label native;
 
-  bool get muted native;
+  bool? get muted native;
 
-  String get readyState native;
+  String? get readyState native;
 
   Future applyConstraints([Map? constraints]) {
     var constraints_dict = null;
@@ -21359,7 +21415,7 @@
   static bool get supported =>
       Device.isEventTypeSupported('MediaStreamTrackEvent');
 
-  MediaStreamTrack get track native;
+  MediaStreamTrack? get track native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21372,11 +21428,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get jsHeapSizeLimit native;
+  int? get jsHeapSizeLimit native;
 
-  int get totalJSHeapSize native;
+  int? get totalJSHeapSize native;
 
-  int get usedJSHeapSize native;
+  int? get usedJSHeapSize native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21517,7 +21573,7 @@
   @Returns('EventTarget|=Object')
   dynamic get _get_source native;
 
-  String get suborigin native;
+  String? get suborigin native;
 
   void _initMessageEvent(
       String? typeArg,
@@ -21624,9 +21680,9 @@
 
   set content(String value) native;
 
-  String get httpEquiv native;
+  String? get httpEquiv native;
 
-  set httpEquiv(String value) native;
+  set httpEquiv(String? value) native;
 
   String get name native;
 
@@ -21649,7 +21705,7 @@
   @Creates('Null')
   dynamic get _get_modificationTime native;
 
-  int get size native;
+  int? get size native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21691,7 +21747,7 @@
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
   num get low native;
 
@@ -21724,11 +21780,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  MidiInputMap get inputs native;
+  MidiInputMap? get inputs native;
 
-  MidiOutputMap get outputs native;
+  MidiOutputMap? get outputs native;
 
-  bool get sysexEnabled native;
+  bool? get sysexEnabled native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21756,7 +21812,7 @@
   static MidiConnectionEvent _create_2(type) =>
       JS('MidiConnectionEvent', 'new MIDIConnectionEvent(#)', type);
 
-  MidiPort get port native;
+  MidiPort? get port native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21873,7 +21929,7 @@
   static MidiMessageEvent _create_2(type) =>
       JS('MidiMessageEvent', 'new MIDIMessageEvent(#)', type);
 
-  Uint8List get data native;
+  Uint8List? get data native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -21967,19 +22023,19 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get connection native;
+  String? get connection native;
 
-  String get id native;
+  String? get id native;
 
-  String get manufacturer native;
+  String? get manufacturer native;
 
-  String get name native;
+  String? get name native;
 
-  String get state native;
+  String? get state native;
 
-  String get type native;
+  String? get type native;
 
-  String get version native;
+  String? get version native;
 
   Future close() => promiseToFuture(JS("", "#.close()", this));
 
@@ -21996,13 +22052,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get description native;
+  String? get description native;
 
-  Plugin get enabledPlugin native;
+  Plugin? get enabledPlugin native;
 
-  String get suffixes native;
+  String? get suffixes native;
 
-  String get type native;
+  String? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22159,7 +22215,7 @@
 
   int get button native;
 
-  int get buttons native;
+  int? get buttons native;
 
   @JSName('clientX')
   num get _clientX native;
@@ -22177,27 +22233,27 @@
    * relatedTarget to get the same information in the standard way.
    */
   @deprecated
-  Node get fromElement native;
+  Node? get fromElement native;
 
   @JSName('layerX')
-  int get _layerX native;
+  int? get _layerX native;
 
   @JSName('layerY')
-  int get _layerY native;
+  int? get _layerY native;
 
   bool get metaKey native;
 
   @JSName('movementX')
-  int get _movementX native;
+  int? get _movementX native;
 
   @JSName('movementY')
-  int get _movementY native;
+  int? get _movementY native;
 
   @JSName('pageX')
-  num get _pageX native;
+  num? get _pageX native;
 
   @JSName('pageY')
-  num get _pageY native;
+  num? get _pageY native;
 
   String? get region native;
 
@@ -22224,7 +22280,7 @@
    * relatedTarget to get the same information in the standard way.
    */
   @deprecated
-  Node get toElement native;
+  Node? get toElement native;
 
   bool getModifierState(String keyArg) native;
 
@@ -22286,7 +22342,7 @@
 
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.FIREFOX)
-  Point get movement => new Point(_movementX, _movementY);
+  Point get movement => new Point(_movementX!, _movementY!);
 
   /**
    * The coordinates of the mouse pointer in target node coordinates.
@@ -22313,9 +22369,9 @@
 
   Point get screen => new Point(_screenX, _screenY);
 
-  Point get layer => new Point(_layerX, _layerY);
+  Point get layer => new Point(_layerX!, _layerY!);
 
-  Point get page => new Point(_pageX, _pageY);
+  Point get page => new Point(_pageX!, _pageY!);
 
   DataTransfer get dataTransfer =>
       JS('DataTransfer', "#['dataTransfer']", this);
@@ -22346,13 +22402,13 @@
 
   static const int REMOVAL = 3;
 
-  int get attrChange native;
+  int? get attrChange native;
 
-  String get attrName native;
+  String? get attrName native;
 
-  String get newValue native;
+  String? get newValue native;
 
-  String get prevValue native;
+  String? get prevValue native;
 
   Node? get relatedNode native;
 
@@ -22487,7 +22543,7 @@
 
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get addedNodes native;
+  List<Node>? get addedNodes native;
 
   String? get attributeName native;
 
@@ -22501,11 +22557,11 @@
 
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get removedNodes native;
+  List<Node>? get removedNodes native;
 
-  Node get target native;
+  Node? get target native;
 
-  String get type native;
+  String? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22626,13 +22682,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  _BudgetService get budget native;
+  _BudgetService? get budget native;
 
-  _Clipboard get clipboard native;
+  _Clipboard? get clipboard native;
 
   NetworkInformation? get connection native;
 
-  CredentialsContainer get credentials native;
+  CredentialsContainer? get credentials native;
 
   num? get deviceMemory native;
 
@@ -22641,28 +22697,28 @@
   @Unstable()
   Geolocation get geolocation native;
 
-  int get maxTouchPoints native;
+  int? get maxTouchPoints native;
 
-  MediaCapabilities get mediaCapabilities native;
+  MediaCapabilities? get mediaCapabilities native;
 
-  MediaDevices get mediaDevices native;
+  MediaDevices? get mediaDevices native;
 
-  MediaSession get mediaSession native;
+  MediaSession? get mediaSession native;
 
-  MimeTypeArray get mimeTypes native;
+  MimeTypeArray? get mimeTypes native;
 
-  _NFC get nfc native;
+  _NFC? get nfc native;
 
-  Permissions get permissions native;
+  Permissions? get permissions native;
 
-  Presentation get presentation native;
+  Presentation? get presentation native;
 
   @Unstable()
-  String get productSub native;
+  String? get productSub native;
 
-  ServiceWorkerContainer get serviceWorker native;
+  ServiceWorkerContainer? get serviceWorker native;
 
-  StorageManager get storage native;
+  StorageManager? get storage native;
 
   @Unstable()
   String get vendor native;
@@ -22670,17 +22726,17 @@
   @Unstable()
   String get vendorSub native;
 
-  VR get vr native;
+  VR? get vr native;
 
   @JSName('webkitPersistentStorage')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  DeprecatedStorageQuota get persistentStorage native;
+  DeprecatedStorageQuota? get persistentStorage native;
 
   @JSName('webkitTemporaryStorage')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  DeprecatedStorageQuota get temporaryStorage native;
+  DeprecatedStorageQuota? get temporaryStorage native;
 
   void cancelKeyboardLock() native;
 
@@ -22742,12 +22798,12 @@
 
   // From NavigatorAutomationInformation
 
-  bool get webdriver native;
+  bool? get webdriver native;
 
   // From NavigatorCookies
 
   @Unstable()
-  bool get cookieEnabled native;
+  bool? get cookieEnabled native;
 
   // From NavigatorID
 
@@ -22757,9 +22813,9 @@
 
   String get appVersion native;
 
-  bool get dartEnabled native;
+  bool? get dartEnabled native;
 
-  String get platform native;
+  String? get platform native;
 
   @Unstable()
   String get product native;
@@ -22768,12 +22824,12 @@
 
   // From NavigatorLanguage
 
-  List<String> get languages native;
+  List<String>? get languages native;
 
   // From NavigatorOnLine
 
   @Unstable()
-  bool get onLine native;
+  bool? get onLine native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22786,7 +22842,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get webdriver native;
+  bool? get webdriver native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22799,7 +22855,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get hardwareConcurrency native;
+  int? get hardwareConcurrency native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22812,7 +22868,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get cookieEnabled native;
+  bool? get cookieEnabled native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22830,9 +22886,9 @@
 
   String get appVersion native;
 
-  bool get dartEnabled native;
+  bool? get dartEnabled native;
 
-  String get platform native;
+  String? get platform native;
 
   String get product native;
 
@@ -22848,9 +22904,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get language native;
+  String? get language native;
 
-  List<String> get languages native;
+  List<String>? get languages native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22862,7 +22918,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get onLine native;
+  bool? get onLine native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22875,11 +22931,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get constraintName native;
+  String? get constraintName native;
 
-  String get message native;
+  String? get message native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -22911,13 +22967,13 @@
 
   num? get downlink native;
 
-  num get downlinkMax native;
+  num? get downlinkMax native;
 
-  String get effectiveType native;
+  String? get effectiveType native;
 
-  int get rtt native;
+  int? get rtt native;
 
-  String get type native;
+  String? get type native;
 
   Stream<Event> get onChange => changeEvent.forTarget(this);
 }
@@ -23220,7 +23276,7 @@
   static const int TEXT_NODE = 3;
 
   @JSName('baseURI')
-  String get baseUri native;
+  String? get baseUri native;
 
   /**
    * The first child of this node.
@@ -23233,7 +23289,7 @@
 
   Node? get firstChild native;
 
-  bool get isConnected native;
+  bool? get isConnected native;
 
   /**
    * The last child of this node.
@@ -23271,7 +23327,7 @@
    *   [nodeType].
    */
 
-  String get nodeName native;
+  String? get nodeName native;
 
   /**
    * The type of node.
@@ -23506,9 +23562,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get pointerBeforeReferenceNode native;
+  bool? get pointerBeforeReferenceNode native;
 
-  Node get referenceNode native;
+  Node? get referenceNode native;
 
   Node get root native;
 
@@ -23697,41 +23753,41 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => JS('bool', '!!(window.Notification)');
 
-  List get actions native;
+  List? get actions native;
 
-  String get badge native;
+  String? get badge native;
 
-  String get body native;
+  String? get body native;
 
   @annotation_Creates_SerializedScriptValue
   @annotation_Returns_SerializedScriptValue
   Object? get data native;
 
-  String get dir native;
+  String? get dir native;
 
-  String get icon native;
+  String? get icon native;
 
-  String get image native;
+  String? get image native;
 
-  String get lang native;
+  String? get lang native;
 
-  static int get maxActions native;
+  static int? get maxActions native;
 
-  static String get permission native;
+  static String? get permission native;
 
-  bool get renotify native;
+  bool? get renotify native;
 
-  bool get requireInteraction native;
+  bool? get requireInteraction native;
 
-  bool get silent native;
+  bool? get silent native;
 
-  String get tag native;
+  String? get tag native;
 
-  int get timestamp native;
+  int? get timestamp native;
 
-  String get title native;
+  String? get title native;
 
-  List<int> get vibrate native;
+  List<int>? get vibrate native;
 
   void close() native;
 
@@ -23778,9 +23834,9 @@
   static NotificationEvent _create_1(type, eventInitDict) => JS(
       'NotificationEvent', 'new NotificationEvent(#,#)', type, eventInitDict);
 
-  String get action native;
+  String? get action native;
 
-  Notification get notification native;
+  Notification? get notification native;
 
   String? get reply native;
 }
@@ -23814,9 +23870,9 @@
    */
   OListElement.created() : super.created();
 
-  bool get reversed native;
+  bool? get reversed native;
 
-  set reversed(bool value) native;
+  set reversed(bool? value) native;
 
   int get start native;
 
@@ -23918,13 +23974,13 @@
   static OffscreenCanvas _create_1(width, height) =>
       JS('OffscreenCanvas', 'new OffscreenCanvas(#,#)', width, height);
 
-  int get height native;
+  int? get height native;
 
-  set height(int value) native;
+  set height(int? value) native;
 
-  int get width native;
+  int? get width native;
 
-  set width(int value) native;
+  set width(int? value) native;
 
   Future<Blob> convertToBlob([Map? options]) {
     var options_dict = null;
@@ -23962,87 +24018,87 @@
     throw new UnsupportedError("Not supported");
   }
 
-  OffscreenCanvas get canvas native;
+  OffscreenCanvas? get canvas native;
 
-  String get direction native;
+  String? get direction native;
 
-  set direction(String value) native;
+  set direction(String? value) native;
 
   Object? get fillStyle native;
 
   set fillStyle(Object? value) native;
 
-  String get filter native;
+  String? get filter native;
 
-  set filter(String value) native;
+  set filter(String? value) native;
 
-  String get font native;
+  String? get font native;
 
-  set font(String value) native;
+  set font(String? value) native;
 
-  num get globalAlpha native;
+  num? get globalAlpha native;
 
-  set globalAlpha(num value) native;
+  set globalAlpha(num? value) native;
 
-  String get globalCompositeOperation native;
+  String? get globalCompositeOperation native;
 
-  set globalCompositeOperation(String value) native;
+  set globalCompositeOperation(String? value) native;
 
-  bool get imageSmoothingEnabled native;
+  bool? get imageSmoothingEnabled native;
 
-  set imageSmoothingEnabled(bool value) native;
+  set imageSmoothingEnabled(bool? value) native;
 
-  String get imageSmoothingQuality native;
+  String? get imageSmoothingQuality native;
 
-  set imageSmoothingQuality(String value) native;
+  set imageSmoothingQuality(String? value) native;
 
-  String get lineCap native;
+  String? get lineCap native;
 
-  set lineCap(String value) native;
+  set lineCap(String? value) native;
 
-  num get lineDashOffset native;
+  num? get lineDashOffset native;
 
-  set lineDashOffset(num value) native;
+  set lineDashOffset(num? value) native;
 
-  String get lineJoin native;
+  String? get lineJoin native;
 
-  set lineJoin(String value) native;
+  set lineJoin(String? value) native;
 
-  num get lineWidth native;
+  num? get lineWidth native;
 
-  set lineWidth(num value) native;
+  set lineWidth(num? value) native;
 
-  num get miterLimit native;
+  num? get miterLimit native;
 
-  set miterLimit(num value) native;
+  set miterLimit(num? value) native;
 
-  num get shadowBlur native;
+  num? get shadowBlur native;
 
-  set shadowBlur(num value) native;
+  set shadowBlur(num? value) native;
 
-  String get shadowColor native;
+  String? get shadowColor native;
 
-  set shadowColor(String value) native;
+  set shadowColor(String? value) native;
 
-  num get shadowOffsetX native;
+  num? get shadowOffsetX native;
 
-  set shadowOffsetX(num value) native;
+  set shadowOffsetX(num? value) native;
 
-  num get shadowOffsetY native;
+  num? get shadowOffsetY native;
 
-  set shadowOffsetY(num value) native;
+  set shadowOffsetY(num? value) native;
 
   Object? get strokeStyle native;
 
   set strokeStyle(Object? value) native;
 
-  String get textAlign native;
+  String? get textAlign native;
 
-  set textAlign(String value) native;
+  set textAlign(String? value) native;
 
-  String get textBaseline native;
+  String? get textBaseline native;
 
-  set textBaseline(String value) native;
+  set textBaseline(String? value) native;
 
   void beginPath() native;
 
@@ -24307,9 +24363,9 @@
 
   int get index native;
 
-  String get label native;
+  String? get label native;
 
-  set label(String value) native;
+  set label(String? value) native;
 
   bool get selected native;
 
@@ -24359,34 +24415,34 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => Element.isTagSupported('output');
 
-  String get defaultValue native;
+  String? get defaultValue native;
 
-  set defaultValue(String value) native;
+  set defaultValue(String? value) native;
 
   FormElement? get form native;
 
-  DomTokenList get htmlFor native;
+  DomTokenList? get htmlFor native;
 
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  String get type native;
+  String? get type native;
 
-  String get validationMessage native;
+  String? get validationMessage native;
 
-  ValidityState get validity native;
+  ValidityState? get validity native;
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 
-  bool get willValidate native;
+  bool? get willValidate native;
 
   bool checkValidity() native;
 
@@ -24418,7 +24474,7 @@
 
   String? get message native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24446,7 +24502,7 @@
   static PageTransitionEvent _create_2(type) =>
       JS('PageTransitionEvent', 'new PageTransitionEvent(#)', type);
 
-  bool get persisted native;
+  bool? get persisted native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24459,69 +24515,69 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Matrix get currentTransform native;
+  Matrix? get currentTransform native;
 
-  set currentTransform(Matrix value) native;
+  set currentTransform(Matrix? value) native;
 
   Object? get fillStyle native;
 
   set fillStyle(Object? value) native;
 
-  String get filter native;
+  String? get filter native;
 
-  set filter(String value) native;
+  set filter(String? value) native;
 
-  num get globalAlpha native;
+  num? get globalAlpha native;
 
-  set globalAlpha(num value) native;
+  set globalAlpha(num? value) native;
 
-  String get globalCompositeOperation native;
+  String? get globalCompositeOperation native;
 
-  set globalCompositeOperation(String value) native;
+  set globalCompositeOperation(String? value) native;
 
-  bool get imageSmoothingEnabled native;
+  bool? get imageSmoothingEnabled native;
 
-  set imageSmoothingEnabled(bool value) native;
+  set imageSmoothingEnabled(bool? value) native;
 
-  String get imageSmoothingQuality native;
+  String? get imageSmoothingQuality native;
 
-  set imageSmoothingQuality(String value) native;
+  set imageSmoothingQuality(String? value) native;
 
-  String get lineCap native;
+  String? get lineCap native;
 
-  set lineCap(String value) native;
+  set lineCap(String? value) native;
 
-  num get lineDashOffset native;
+  num? get lineDashOffset native;
 
-  set lineDashOffset(num value) native;
+  set lineDashOffset(num? value) native;
 
-  String get lineJoin native;
+  String? get lineJoin native;
 
-  set lineJoin(String value) native;
+  set lineJoin(String? value) native;
 
-  num get lineWidth native;
+  num? get lineWidth native;
 
-  set lineWidth(num value) native;
+  set lineWidth(num? value) native;
 
-  num get miterLimit native;
+  num? get miterLimit native;
 
-  set miterLimit(num value) native;
+  set miterLimit(num? value) native;
 
-  num get shadowBlur native;
+  num? get shadowBlur native;
 
-  set shadowBlur(num value) native;
+  set shadowBlur(num? value) native;
 
-  String get shadowColor native;
+  String? get shadowColor native;
 
-  set shadowColor(String value) native;
+  set shadowColor(String? value) native;
 
-  num get shadowOffsetX native;
+  num? get shadowOffsetX native;
 
-  set shadowOffsetX(num value) native;
+  set shadowOffsetX(num? value) native;
 
-  num get shadowOffsetY native;
+  num? get shadowOffsetY native;
 
-  set shadowOffsetY(num value) native;
+  set shadowOffsetY(num? value) native;
 
   Object? get strokeStyle native;
 
@@ -24616,9 +24672,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get height native;
+  num? get height native;
 
-  num get width native;
+  num? get width native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24631,7 +24687,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get devicePixelRatio native;
+  num? get devicePixelRatio native;
 
   void registerPaint(String name, Object paintCtor) native;
 }
@@ -24702,7 +24758,7 @@
 
   int get _childElementCount native;
 
-  List<Node> get _children native;
+  List<Node>? get _children native;
 
   Element? get _firstElementChild native;
 
@@ -24742,22 +24798,22 @@
 
   set additionalData(Object? value) native;
 
-  String get idName native;
+  String? get idName native;
 
-  set idName(String value) native;
+  set idName(String? value) native;
 
-  String get password native;
+  String? get password native;
 
-  String get passwordName native;
+  String? get passwordName native;
 
-  set passwordName(String value) native;
+  set passwordName(String? value) native;
 
   // From CredentialUserData
 
   @JSName('iconURL')
-  String get iconUrl native;
+  String? get iconUrl native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24824,27 +24880,27 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List<String> get addressLine native;
+  List<String>? get addressLine native;
 
-  String get city native;
+  String? get city native;
 
-  String get country native;
+  String? get country native;
 
-  String get dependentLocality native;
+  String? get dependentLocality native;
 
-  String get languageCode native;
+  String? get languageCode native;
 
-  String get organization native;
+  String? get organization native;
 
-  String get phone native;
+  String? get phone native;
 
-  String get postalCode native;
+  String? get postalCode native;
 
-  String get recipient native;
+  String? get recipient native;
 
-  String get region native;
+  String? get region native;
 
-  String get sortingCode native;
+  String? get sortingCode native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24888,11 +24944,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  PaymentInstruments get instruments native;
+  PaymentInstruments? get instruments native;
 
-  String get userHint native;
+  String? get userHint native;
 
-  set userHint(String value) native;
+  set userHint(String? value) native;
 }
 // Copyright (c) 2015, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -24928,7 +24984,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get id native;
+  String? get id native;
 
   PaymentAddress? get shippingAddress native;
 
@@ -24966,19 +25022,19 @@
       type,
       eventInitDict);
 
-  String get instrumentKey native;
+  String? get instrumentKey native;
 
-  List get methodData native;
+  List? get methodData native;
 
-  List get modifiers native;
+  List? get modifiers native;
 
-  String get paymentRequestId native;
+  String? get paymentRequestId native;
 
-  String get paymentRequestOrigin native;
+  String? get paymentRequestOrigin native;
 
-  String get topLevelOrigin native;
+  String? get topLevelOrigin native;
 
-  Object get total native;
+  Object? get total native;
 
   Future<WindowClient> openWindow(String url) =>
       promiseToFuture<WindowClient>(JS("", "#.openWindow(#)", this, url));
@@ -25024,9 +25080,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Object get details native;
+  Object? get details native;
 
-  String get methodName native;
+  String? get methodName native;
 
   String? get payerEmail native;
 
@@ -25034,7 +25090,7 @@
 
   String? get payerPhone native;
 
-  String get requestId native;
+  String? get requestId native;
 
   PaymentAddress? get shippingAddress native;
 
@@ -25064,7 +25120,7 @@
 
   PerformanceNavigation get navigation native;
 
-  num get timeOrigin native;
+  num? get timeOrigin native;
 
   PerformanceTiming get timing native;
 
@@ -25119,7 +25175,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List<TaskAttributionTiming> get attribution native;
+  List<TaskAttributionTiming>? get attribution native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25163,9 +25219,9 @@
 
   static const int TYPE_RESERVED = 255;
 
-  int get redirectCount native;
+  int? get redirectCount native;
 
-  int get type native;
+  int? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25178,25 +25234,25 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get domComplete native;
+  num? get domComplete native;
 
-  num get domContentLoadedEventEnd native;
+  num? get domContentLoadedEventEnd native;
 
-  num get domContentLoadedEventStart native;
+  num? get domContentLoadedEventStart native;
 
-  num get domInteractive native;
+  num? get domInteractive native;
 
-  num get loadEventEnd native;
+  num? get loadEventEnd native;
 
-  num get loadEventStart native;
+  num? get loadEventStart native;
 
-  int get redirectCount native;
+  int? get redirectCount native;
 
-  String get type native;
+  String? get type native;
 
-  num get unloadEventEnd native;
+  num? get unloadEventEnd native;
 
-  num get unloadEventStart native;
+  num? get unloadEventStart native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25279,37 +25335,37 @@
 
   num get connectStart native;
 
-  int get decodedBodySize native;
+  int? get decodedBodySize native;
 
-  num get domainLookupEnd native;
+  num? get domainLookupEnd native;
 
-  num get domainLookupStart native;
+  num? get domainLookupStart native;
 
-  int get encodedBodySize native;
+  int? get encodedBodySize native;
 
-  num get fetchStart native;
+  num? get fetchStart native;
 
-  String get initiatorType native;
+  String? get initiatorType native;
 
-  String get nextHopProtocol native;
+  String? get nextHopProtocol native;
 
-  num get redirectEnd native;
+  num? get redirectEnd native;
 
-  num get redirectStart native;
+  num? get redirectStart native;
 
-  num get requestStart native;
+  num? get requestStart native;
 
-  num get responseEnd native;
+  num? get responseEnd native;
 
-  num get responseStart native;
+  num? get responseStart native;
 
-  num get secureConnectionStart native;
+  num? get secureConnectionStart native;
 
-  List<PerformanceServerTiming> get serverTiming native;
+  List<PerformanceServerTiming>? get serverTiming native;
 
-  int get transferSize native;
+  int? get transferSize native;
 
-  num get workerStart native;
+  num? get workerStart native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25322,11 +25378,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get description native;
+  String? get description native;
 
-  num get duration native;
+  num? get duration native;
 
-  String get name native;
+  String? get name native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25396,7 +25452,7 @@
   static const EventStreamProvider<Event> changeEvent =
       const EventStreamProvider<Event>('change');
 
-  String get state native;
+  String? get state native;
 
   Stream<Event> get onChange => changeEvent.forTarget(this);
 }
@@ -25444,13 +25500,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List get fillLightMode native;
+  List? get fillLightMode native;
 
-  MediaSettingsRange get imageHeight native;
+  MediaSettingsRange? get imageHeight native;
 
-  MediaSettingsRange get imageWidth native;
+  MediaSettingsRange? get imageWidth native;
 
-  String get redEyeReduction native;
+  String? get redEyeReduction native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25480,13 +25536,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get description native;
+  String? get description native;
 
-  String get filename native;
+  String? get filename native;
 
-  int get length native;
+  int? get length native;
 
-  String get name native;
+  String? get name native;
 
   MimeType? item(int index) native;
 
@@ -25581,25 +25637,25 @@
   static PointerEvent _create_2(type) =>
       JS('PointerEvent', 'new PointerEvent(#)', type);
 
-  num get height native;
+  num? get height native;
 
-  bool get isPrimary native;
+  bool? get isPrimary native;
 
-  int get pointerId native;
+  int? get pointerId native;
 
-  String get pointerType native;
+  String? get pointerType native;
 
-  num get pressure native;
+  num? get pressure native;
 
-  num get tangentialPressure native;
+  num? get tangentialPressure native;
 
-  int get tiltX native;
+  int? get tiltX native;
 
-  int get tiltY native;
+  int? get tiltY native;
 
-  int get twist native;
+  int? get twist native;
 
-  num get width native;
+  num? get width native;
 
   List<PointerEvent> getCoalescedEvents() native;
 
@@ -25674,9 +25730,9 @@
 
   static const int TIMEOUT = 3;
 
-  int get code native;
+  int? get code native;
 
-  String get message native;
+  String? get message native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25740,7 +25796,7 @@
   static const EventStreamProvider<Event> changeEvent =
       const EventStreamProvider<Event>('change');
 
-  bool get value native;
+  bool? get value native;
 
   Stream<Event> get onChange => changeEvent.forTarget(this);
 }
@@ -25758,15 +25814,15 @@
   static const EventStreamProvider<MessageEvent> messageEvent =
       const EventStreamProvider<MessageEvent>('message');
 
-  String get binaryType native;
+  String? get binaryType native;
 
-  set binaryType(String value) native;
+  set binaryType(String? value) native;
 
-  String get id native;
+  String? get id native;
 
-  String get state native;
+  String? get state native;
 
-  String get url native;
+  String? get url native;
 
   void close() native;
 
@@ -25796,7 +25852,7 @@
       JS('PresentationConnectionAvailableEvent',
           'new PresentationConnectionAvailableEvent(#,#)', type, eventInitDict);
 
-  PresentationConnection get connection native;
+  PresentationConnection? get connection native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25819,9 +25875,9 @@
       type,
       eventInitDict);
 
-  String get message native;
+  String? get message native;
 
-  String get reason native;
+  String? get reason native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25834,7 +25890,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List<PresentationConnection> get connections native;
+  List<PresentationConnection>? get connections native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25902,7 +25958,7 @@
 
   StyleSheet? get sheet native;
 
-  String get target native;
+  String? get target native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -25934,7 +25990,7 @@
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
   num get max native;
 
@@ -25971,9 +26027,9 @@
 
   bool get lengthComputable native;
 
-  int get loaded native;
+  int? get loaded native;
 
-  int get total native;
+  int? get total native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26011,9 +26067,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  ByteBuffer get rawId native;
+  ByteBuffer? get rawId native;
 
-  AuthenticatorResponse get response native;
+  AuthenticatorResponse? get response native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26050,7 +26106,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  static List<String> get supportedContentEncodings native;
+  static List<String>? get supportedContentEncodings native;
 
   Future<PushSubscription> getSubscription() =>
       promiseToFuture<PushSubscription>(JS("", "#.getSubscription()", this));
@@ -26102,11 +26158,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get endpoint native;
+  String? get endpoint native;
 
-  int get expirationTime native;
+  int? get expirationTime native;
 
-  PushSubscriptionOptions get options native;
+  PushSubscriptionOptions? get options native;
 
   ByteBuffer? getKey(String name) native;
 
@@ -26126,7 +26182,7 @@
 
   ByteBuffer? get applicationServerKey native;
 
-  bool get userVisibleOnly native;
+  bool? get userVisibleOnly native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26298,11 +26354,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get id native;
+  String? get id native;
 
-  String get platform native;
+  String? get platform native;
 
-  String get url native;
+  String? get url native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26340,7 +26396,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get state native;
+  String? get state native;
 
   Future cancelWatchAvailability([int? id]) =>
       promiseToFuture(JS("", "#.cancelWatchAvailability(#)", this, id));
@@ -26447,9 +26503,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  DomRectReadOnly get contentRect native;
+  DomRectReadOnly? get contentRect native;
 
-  Element get target native;
+  Element? get target native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26462,7 +26518,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get expires native;
+  int? get expires native;
 
   List<Map> getFingerprints() native;
 }
@@ -26513,33 +26569,33 @@
   static const EventStreamProvider<Event> openEvent =
       const EventStreamProvider<Event>('open');
 
-  String get binaryType native;
+  String? get binaryType native;
 
-  set binaryType(String value) native;
+  set binaryType(String? value) native;
 
-  int get bufferedAmount native;
+  int? get bufferedAmount native;
 
-  int get bufferedAmountLowThreshold native;
+  int? get bufferedAmountLowThreshold native;
 
-  set bufferedAmountLowThreshold(int value) native;
+  set bufferedAmountLowThreshold(int? value) native;
 
-  int get id native;
+  int? get id native;
 
-  String get label native;
+  String? get label native;
 
-  int get maxRetransmitTime native;
+  int? get maxRetransmitTime native;
 
-  int get maxRetransmits native;
+  int? get maxRetransmits native;
 
-  bool get negotiated native;
+  bool? get negotiated native;
 
-  bool get ordered native;
+  bool? get ordered native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  String get readyState native;
+  String? get readyState native;
 
-  bool get reliable native;
+  bool? get reliable native;
 
   void close() native;
 
@@ -26590,7 +26646,7 @@
       type,
       eventInitDict);
 
-  RtcDataChannel get channel native;
+  RtcDataChannel? get channel native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26613,15 +26669,15 @@
       const EventStreamProvider<RtcDtmfToneChangeEvent>('tonechange');
 
   @JSName('canInsertDTMF')
-  bool get canInsertDtmf native;
+  bool? get canInsertDtmf native;
 
-  int get duration native;
+  int? get duration native;
 
-  int get interToneGap native;
+  int? get interToneGap native;
 
-  String get toneBuffer native;
+  String? get toneBuffer native;
 
-  MediaStreamTrack get track native;
+  MediaStreamTrack? get track native;
 
   @JSName('insertDTMF')
   void insertDtmf(String tones, [int? duration, int? interToneGap]) native;
@@ -26651,7 +26707,7 @@
       type,
       eventInitDict);
 
-  String get tone native;
+  String? get tone native;
 }
 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26670,17 +26726,17 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get candidate native;
+  String? get candidate native;
 
-  set candidate(String value) native;
+  set candidate(String? value) native;
 
-  int get sdpMLineIndex native;
+  int? get sdpMLineIndex native;
 
-  set sdpMLineIndex(int value) native;
+  set sdpMLineIndex(int? value) native;
 
-  String get sdpMid native;
+  String? get sdpMid native;
 
-  set sdpMid(String value) native;
+  set sdpMid(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -26693,13 +26749,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get id native;
+  String? get id native;
 
   DateTime get timestamp => convertNativeToDart_DateTime(this._get_timestamp);
   @JSName('timestamp')
   dynamic get _get_timestamp native;
 
-  String get type native;
+  String? get type native;
 
   List<String> names() native;
 
@@ -26847,15 +26903,15 @@
   static const EventStreamProvider<RtcTrackEvent> trackEvent =
       const EventStreamProvider<RtcTrackEvent>('track');
 
-  String get iceConnectionState native;
+  String? get iceConnectionState native;
 
-  String get iceGatheringState native;
+  String? get iceGatheringState native;
 
   RtcSessionDescription? get localDescription native;
 
   RtcSessionDescription? get remoteDescription native;
 
-  String get signalingState native;
+  String? get signalingState native;
 
   Future addIceCandidate(Object candidate,
           [VoidCallback? successCallback,
@@ -27021,9 +27077,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get source native;
+  int? get source native;
 
-  num get timestamp native;
+  num? get timestamp native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27036,7 +27092,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  MediaStreamTrack get track native;
+  MediaStreamTrack? get track native;
 
   List<RtcRtpContributingSource> getContributingSources() native;
 }
@@ -27179,11 +27235,11 @@
   static RtcTrackEvent _create_1(type, eventInitDict) =>
       JS('RtcTrackEvent', 'new RTCTrackEvent(#,#)', type, eventInitDict);
 
-  RtcRtpReceiver get receiver native;
+  RtcRtpReceiver? get receiver native;
 
-  List<MediaStream> get streams native;
+  List<MediaStream>? get streams native;
 
-  MediaStreamTrack get track native;
+  MediaStreamTrack? get track native;
 }
 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27192,37 +27248,37 @@
 @Native("Screen")
 class Screen extends Interceptor {
   Rectangle get available =>
-      new Rectangle(_availLeft, _availTop, _availWidth, _availHeight);
+      new Rectangle(_availLeft!, _availTop!, _availWidth!, _availHeight!);
   // To suppress missing implicit constructor warnings.
   factory Screen._() {
     throw new UnsupportedError("Not supported");
   }
 
   @JSName('availHeight')
-  int get _availHeight native;
+  int? get _availHeight native;
 
   @JSName('availLeft')
-  int get _availLeft native;
+  int? get _availLeft native;
 
   @JSName('availTop')
-  int get _availTop native;
+  int? get _availTop native;
 
   @JSName('availWidth')
-  int get _availWidth native;
+  int? get _availWidth native;
 
-  int get colorDepth native;
+  int? get colorDepth native;
 
-  int get height native;
+  int? get height native;
 
-  bool get keepAwake native;
+  bool? get keepAwake native;
 
-  set keepAwake(bool value) native;
+  set keepAwake(bool? value) native;
 
-  ScreenOrientation get orientation native;
+  ScreenOrientation? get orientation native;
 
-  int get pixelDepth native;
+  int? get pixelDepth native;
 
-  int get width native;
+  int? get width native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27238,9 +27294,9 @@
   static const EventStreamProvider<Event> changeEvent =
       const EventStreamProvider<Event>('change');
 
-  int get angle native;
+  int? get angle native;
 
-  String get type native;
+  String? get type native;
 
   Future lock(String orientation) =>
       promiseToFuture(JS("", "#.lock(#)", this, orientation));
@@ -27272,9 +27328,9 @@
    */
   ScriptElement.created() : super.created();
 
-  bool get async native;
+  bool? get async native;
 
-  set async(bool value) native;
+  set async(bool? value) native;
 
   String get charset native;
 
@@ -27284,17 +27340,17 @@
 
   set crossOrigin(String? value) native;
 
-  bool get defer native;
+  bool? get defer native;
 
-  set defer(bool value) native;
+  set defer(bool? value) native;
 
-  String get integrity native;
+  String? get integrity native;
 
-  set integrity(String value) native;
+  set integrity(String? value) native;
 
-  bool get noModule native;
+  bool? get noModule native;
 
-  set noModule(bool value) native;
+  set noModule(bool? value) native;
 
   String get src native;
 
@@ -27326,29 +27382,29 @@
       JS('ScrollState', 'new ScrollState(#)', scrollStateInit);
   static ScrollState _create_2() => JS('ScrollState', 'new ScrollState()');
 
-  num get deltaGranularity native;
+  num? get deltaGranularity native;
 
-  num get deltaX native;
+  num? get deltaX native;
 
-  num get deltaY native;
+  num? get deltaY native;
 
-  bool get fromUserInput native;
+  bool? get fromUserInput native;
 
-  bool get inInertialPhase native;
+  bool? get inInertialPhase native;
 
-  bool get isBeginning native;
+  bool? get isBeginning native;
 
-  bool get isDirectManipulation native;
+  bool? get isDirectManipulation native;
 
-  bool get isEnding native;
+  bool? get isEnding native;
 
-  int get positionX native;
+  int? get positionX native;
 
-  int get positionY native;
+  int? get positionY native;
 
-  num get velocityX native;
+  num? get velocityX native;
 
-  num get velocityY native;
+  num? get velocityY native;
 
   void consumeDelta(num x, num y) native;
 
@@ -27384,7 +27440,7 @@
   static ScrollTimeline _create_2() =>
       JS('ScrollTimeline', 'new ScrollTimeline()');
 
-  String get orientation native;
+  String? get orientation native;
 
   Element? get scrollSource native;
 
@@ -27419,30 +27475,30 @@
       type);
 
   @JSName('blockedURI')
-  String get blockedUri native;
+  String? get blockedUri native;
 
-  int get columnNumber native;
+  int? get columnNumber native;
 
-  String get disposition native;
+  String? get disposition native;
 
   @JSName('documentURI')
-  String get documentUri native;
+  String? get documentUri native;
 
-  String get effectiveDirective native;
+  String? get effectiveDirective native;
 
-  int get lineNumber native;
+  int? get lineNumber native;
 
-  String get originalPolicy native;
+  String? get originalPolicy native;
 
-  String get referrer native;
+  String? get referrer native;
 
-  String get sample native;
+  String? get sample native;
 
-  String get sourceFile native;
+  String? get sourceFile native;
 
-  int get statusCode native;
+  int? get statusCode native;
 
-  String get violatedDirective native;
+  String? get violatedDirective native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27480,31 +27536,31 @@
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
-  int get length native;
+  int? get length native;
 
-  set length(int value) native;
+  set length(int? value) native;
 
-  bool get multiple native;
+  bool? get multiple native;
 
-  set multiple(bool value) native;
+  set multiple(bool? value) native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  bool get required native;
+  bool? get required native;
 
-  set required(bool value) native;
+  set required(bool? value) native;
 
-  int get selectedIndex native;
+  int? get selectedIndex native;
 
-  set selectedIndex(int value) native;
+  set selectedIndex(int? value) native;
 
-  int get size native;
+  int? get size native;
 
-  set size(int value) native;
+  set size(int? value) native;
 
   String get type native;
 
@@ -27512,9 +27568,9 @@
 
   ValidityState get validity native;
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 
   bool get willValidate native;
 
@@ -27541,11 +27597,11 @@
 
   List<OptionElement> get selectedOptions {
     // IE does not change the selected flag for single-selection items.
-    if (this.multiple) {
+    if (this.multiple!) {
       var options = this.options.where((o) => o.selected).toList();
       return new UnmodifiableListView(options);
     } else {
-      return [this.options[this.selectedIndex]];
+      return [this.options[this.selectedIndex!]];
     }
   }
 }
@@ -27562,25 +27618,25 @@
 
   Node? get anchorNode native;
 
-  int get anchorOffset native;
+  int? get anchorOffset native;
 
   Node? get baseNode native;
 
-  int get baseOffset native;
+  int? get baseOffset native;
 
   Node? get extentNode native;
 
-  int get extentOffset native;
+  int? get extentOffset native;
 
   Node? get focusNode native;
 
-  int get focusOffset native;
+  int? get focusOffset native;
 
-  bool get isCollapsed native;
+  bool? get isCollapsed native;
 
-  int get rangeCount native;
+  int? get rangeCount native;
 
-  String get type native;
+  String? get type native;
 
   void addRange(Range range) native;
 
@@ -27627,11 +27683,11 @@
   static const EventStreamProvider<Event> errorEvent =
       const EventStreamProvider<Event>('error');
 
-  bool get activated native;
+  bool? get activated native;
 
-  bool get hasReading native;
+  bool? get hasReading native;
 
-  num get timestamp native;
+  num? get timestamp native;
 
   void start() native;
 
@@ -27657,7 +27713,7 @@
   static SensorErrorEvent _create_1(type, eventInitDict) =>
       JS('SensorErrorEvent', 'new SensorErrorEvent(#,#)', type, eventInitDict);
 
-  DomException get error native;
+  DomException? get error native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27674,9 +27730,9 @@
       const EventStreamProvider<Event>('error');
 
   @JSName('scriptURL')
-  String get scriptUrl native;
+  String? get scriptUrl native;
 
-  String get state native;
+  String? get state native;
 
   void postMessage(/*any*/ message, [List<Object>? transfer]) {
     if (transfer != null) {
@@ -27759,9 +27815,9 @@
   static const EventStreamProvider<MessageEvent> messageEvent =
       const EventStreamProvider<MessageEvent>('message');
 
-  Clients get clients native;
+  Clients? get clients native;
 
-  ServiceWorkerRegistration get registration native;
+  ServiceWorkerRegistration? get registration native;
 
   Future skipWaiting() => promiseToFuture(JS("", "#.skipWaiting()", this));
 
@@ -27794,19 +27850,19 @@
 
   ServiceWorker? get active native;
 
-  BackgroundFetchManager get backgroundFetch native;
+  BackgroundFetchManager? get backgroundFetch native;
 
   ServiceWorker? get installing native;
 
-  NavigationPreloadManager get navigationPreload native;
+  NavigationPreloadManager? get navigationPreload native;
 
-  PaymentManager get paymentManager native;
+  PaymentManager? get paymentManager native;
 
-  PushManager get pushManager native;
+  PushManager? get pushManager native;
 
-  String get scope native;
+  String? get scope native;
 
-  SyncManager get sync native;
+  SyncManager? get sync native;
 
   ServiceWorker? get waiting native;
 
@@ -27874,17 +27930,17 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get delegatesFocus native;
+  bool? get delegatesFocus native;
 
-  Element get host native;
+  Element? get host native;
 
   @JSName('innerHTML')
-  String get innerHtml native;
+  String? get innerHtml native;
 
   @JSName('innerHTML')
   set innerHtml(String? value) native;
 
-  String get mode native;
+  String? get mode native;
 
   ShadowRoot? get olderShadowRoot native;
 
@@ -27898,7 +27954,7 @@
 
   @Returns('_StyleSheetList')
   @Creates('_StyleSheetList')
-  List<StyleSheet> get styleSheets native;
+  List<StyleSheet>? get styleSheets native;
 
   Element? elementFromPoint(int x, int y) native;
 
@@ -27957,7 +28013,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get byteLength native;
+  int? get byteLength native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -27984,7 +28040,7 @@
   static SharedWorker _create_2(scriptURL) =>
       JS('SharedWorker', 'new SharedWorker(#)', scriptURL);
 
-  MessagePort get port native;
+  MessagePort? get port native;
 
   Stream<Event> get onError => errorEvent.forTarget(this);
 }
@@ -28012,7 +28068,7 @@
 
   static const int TEMPORARY = 0;
 
-  String get name native;
+  String? get name native;
 
   void close() native;
 
@@ -28065,9 +28121,9 @@
    */
   SlotElement.created() : super.created();
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
   List<Node> assignedNodes([Map? options]) {
     if (options != null) {
@@ -28099,33 +28155,33 @@
   static const EventStreamProvider<Event> errorEvent =
       const EventStreamProvider<Event>('error');
 
-  num get appendWindowEnd native;
+  num? get appendWindowEnd native;
 
-  set appendWindowEnd(num value) native;
+  set appendWindowEnd(num? value) native;
 
-  num get appendWindowStart native;
+  num? get appendWindowStart native;
 
-  set appendWindowStart(num value) native;
+  set appendWindowStart(num? value) native;
 
-  AudioTrackList get audioTracks native;
+  AudioTrackList? get audioTracks native;
 
-  TimeRanges get buffered native;
+  TimeRanges? get buffered native;
 
-  String get mode native;
+  String? get mode native;
 
-  set mode(String value) native;
+  set mode(String? value) native;
 
-  num get timestampOffset native;
+  num? get timestampOffset native;
 
-  set timestampOffset(num value) native;
+  set timestampOffset(num? value) native;
 
-  TrackDefaultList get trackDefaults native;
+  TrackDefaultList? get trackDefaults native;
 
-  set trackDefaults(TrackDefaultList value) native;
+  set trackDefaults(TrackDefaultList? value) native;
 
-  bool get updating native;
+  bool? get updating native;
 
-  VideoTrackList get videoTracks native;
+  VideoTrackList? get videoTracks native;
 
   void abort() native;
 
@@ -28227,17 +28283,17 @@
 
   set media(String value) native;
 
-  String get sizes native;
+  String? get sizes native;
 
-  set sizes(String value) native;
+  set sizes(String? value) native;
 
   String get src native;
 
   set src(String value) native;
 
-  String get srcset native;
+  String? get srcset native;
 
-  set srcset(String value) native;
+  set srcset(String? value) native;
 
   String get type native;
 
@@ -28283,13 +28339,13 @@
   static SpeechGrammar _create_1() =>
       JS('SpeechGrammar', 'new SpeechGrammar()');
 
-  String get src native;
+  String? get src native;
 
-  set src(String value) native;
+  set src(String? value) native;
 
-  num get weight native;
+  num? get weight native;
 
-  set weight(num value) native;
+  set weight(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -28480,25 +28536,25 @@
 
   set audioTrack(MediaStreamTrack? value) native;
 
-  bool get continuous native;
+  bool? get continuous native;
 
-  set continuous(bool value) native;
+  set continuous(bool? value) native;
 
-  SpeechGrammarList get grammars native;
+  SpeechGrammarList? get grammars native;
 
-  set grammars(SpeechGrammarList value) native;
+  set grammars(SpeechGrammarList? value) native;
 
-  bool get interimResults native;
+  bool? get interimResults native;
 
-  set interimResults(bool value) native;
+  set interimResults(bool? value) native;
 
-  String get lang native;
+  String? get lang native;
 
-  set lang(String value) native;
+  set lang(String? value) native;
 
-  int get maxAlternatives native;
+  int? get maxAlternatives native;
 
-  set maxAlternatives(int value) native;
+  set maxAlternatives(int? value) native;
 
   void abort() native;
 
@@ -28556,9 +28612,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get confidence native;
+  num? get confidence native;
 
-  String get transcript native;
+  String? get transcript native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -28587,9 +28643,9 @@
   static SpeechRecognitionError _create_2(type) =>
       JS('SpeechRecognitionError', 'new SpeechRecognitionError(#)', type);
 
-  String get error native;
+  String? get error native;
 
-  String get message native;
+  String? get message native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -28622,7 +28678,7 @@
 
   Document? get interpretation native;
 
-  int get resultIndex native;
+  int? get resultIndex native;
 
   @Returns('_SpeechRecognitionResultList|Null')
   @Creates('_SpeechRecognitionResultList')
@@ -28640,9 +28696,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get isFinal native;
+  bool? get isFinal native;
 
-  int get length native;
+  int? get length native;
 
   SpeechRecognitionAlternative item(int index) native;
 }
@@ -28663,11 +28719,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get paused native;
+  bool? get paused native;
 
-  bool get pending native;
+  bool? get pending native;
 
-  bool get speaking native;
+  bool? get speaking native;
 
   void cancel() native;
 
@@ -28691,13 +28747,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get charIndex native;
+  int? get charIndex native;
 
-  num get elapsedTime native;
+  num? get elapsedTime native;
 
-  String get name native;
+  String? get name native;
 
-  SpeechSynthesisUtterance get utterance native;
+  SpeechSynthesisUtterance? get utterance native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -28784,29 +28840,29 @@
   static SpeechSynthesisUtterance _create_2() =>
       JS('SpeechSynthesisUtterance', 'new SpeechSynthesisUtterance()');
 
-  String get lang native;
+  String? get lang native;
 
-  set lang(String value) native;
+  set lang(String? value) native;
 
-  num get pitch native;
+  num? get pitch native;
 
-  set pitch(num value) native;
+  set pitch(num? value) native;
 
-  num get rate native;
+  num? get rate native;
 
-  set rate(num value) native;
+  set rate(num? value) native;
 
-  String get text native;
+  String? get text native;
 
-  set text(String value) native;
+  set text(String? value) native;
 
   SpeechSynthesisVoice? get voice native;
 
   set voice(SpeechSynthesisVoice? value) native;
 
-  num get volume native;
+  num? get volume native;
 
-  set volume(num value) native;
+  set volume(num? value) native;
 
   /// Stream of `boundary` events handled by this [SpeechSynthesisUtterance].
   Stream<SpeechSynthesisEvent> get onBoundary => boundaryEvent.forTarget(this);
@@ -28841,16 +28897,16 @@
   }
 
   @JSName('default')
-  bool get defaultValue native;
+  bool? get defaultValue native;
 
-  String get lang native;
+  String? get lang native;
 
-  bool get localService native;
+  bool? get localService native;
 
-  String get name native;
+  String? get name native;
 
   @JSName('voiceURI')
-  String get voiceUri native;
+  String? get voiceUri native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -28863,15 +28919,15 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get collapsed native;
+  bool? get collapsed native;
 
-  Node get endContainer native;
+  Node? get endContainer native;
 
-  int get endOffset native;
+  int? get endOffset native;
 
-  Node get startContainer native;
+  Node? get startContainer native;
 
-  int get startOffset native;
+  int? get startOffset native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -29034,7 +29090,7 @@
 
   Storage? get storageArea native;
 
-  String get url native;
+  String? get url native;
 
   @JSName('initStorageEvent')
   void _initStorageEvent(
@@ -29129,7 +29185,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get type native;
+  String? get type native;
 
   bool matchMedium(String? mediaquery) native;
 }
@@ -29180,13 +29236,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get disabled native;
+  bool? get disabled native;
 
-  set disabled(bool value) native;
+  set disabled(bool? value) native;
 
   String? get href native;
 
-  MediaList get media native;
+  MediaList? get media native;
 
   Node? get ownerNode native;
 
@@ -29194,7 +29250,7 @@
 
   String? get title native;
 
-  String get type native;
+  String? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -29214,9 +29270,9 @@
   static SyncEvent _create_1(type, init) =>
       JS('SyncEvent', 'new SyncEvent(#,#)', type, init);
 
-  bool get lastChance native;
+  bool? get lastChance native;
 
-  String get tag native;
+  String? get tag native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -29559,16 +29615,16 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get containerId native;
+  String? get containerId native;
 
-  String get containerName native;
+  String? get containerName native;
 
-  String get containerSrc native;
+  String? get containerSrc native;
 
-  String get containerType native;
+  String? get containerType native;
 
   @JSName('scriptURL')
-  String get scriptUrl native;
+  String? get scriptUrl native;
 }
 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -29596,7 +29652,7 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => Element.isTagSupported('template');
 
-  DocumentFragment get content native;
+  DocumentFragment? get content native;
 
   /**
    * An override to place the contents into content rather than as child nodes.
@@ -29608,11 +29664,11 @@
   void setInnerHtml(String? html,
       {NodeValidator? validator, NodeTreeSanitizer? treeSanitizer}) {
     text = null;
-    content.nodes.clear();
+    content!.nodes.clear();
     var fragment = createFragment(html,
         validator: validator, treeSanitizer: treeSanitizer);
 
-    content.append(fragment);
+    content!.append(fragment);
   }
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
@@ -29666,9 +29722,9 @@
    */
   TextAreaElement.created() : super.created();
 
-  String get autocapitalize native;
+  String? get autocapitalize native;
 
-  set autocapitalize(String value) native;
+  set autocapitalize(String? value) native;
 
   bool get autofocus native;
 
@@ -29678,13 +29734,13 @@
 
   set cols(int value) native;
 
-  String get defaultValue native;
+  String? get defaultValue native;
 
-  set defaultValue(String value) native;
+  set defaultValue(String? value) native;
 
-  String get dirName native;
+  String? get dirName native;
 
-  set dirName(String value) native;
+  set dirName(String? value) native;
 
   bool get disabled native;
 
@@ -29695,7 +29751,7 @@
   @Unstable()
   @Returns('NodeList')
   @Creates('NodeList')
-  List<Node> get labels native;
+  List<Node>? get labels native;
 
   int get maxLength native;
 
@@ -29725,31 +29781,31 @@
 
   set rows(int value) native;
 
-  String get selectionDirection native;
+  String? get selectionDirection native;
 
-  set selectionDirection(String value) native;
+  set selectionDirection(String? value) native;
 
-  int get selectionEnd native;
+  int? get selectionEnd native;
 
-  set selectionEnd(int value) native;
+  set selectionEnd(int? value) native;
 
-  int get selectionStart native;
+  int? get selectionStart native;
 
-  set selectionStart(int value) native;
+  set selectionStart(int? value) native;
 
-  int get textLength native;
+  int? get textLength native;
 
-  String get type native;
+  String? get type native;
 
-  String get validationMessage native;
+  String? get validationMessage native;
 
-  ValidityState get validity native;
+  ValidityState? get validity native;
 
-  String get value native;
+  String? get value native;
 
   set value(String? value) native;
 
-  bool get willValidate native;
+  bool? get willValidate native;
 
   String get wrap native;
 
@@ -29813,7 +29869,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get data native;
+  String? get data native;
 
   @JSName('initTextEvent')
   void _initTextEvent(String? type, bool? bubbles, bool? cancelable,
@@ -29830,29 +29886,29 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get actualBoundingBoxAscent native;
+  num? get actualBoundingBoxAscent native;
 
-  num get actualBoundingBoxDescent native;
+  num? get actualBoundingBoxDescent native;
 
-  num get actualBoundingBoxLeft native;
+  num? get actualBoundingBoxLeft native;
 
-  num get actualBoundingBoxRight native;
+  num? get actualBoundingBoxRight native;
 
-  num get alphabeticBaseline native;
+  num? get alphabeticBaseline native;
 
-  num get emHeightAscent native;
+  num? get emHeightAscent native;
 
-  num get emHeightDescent native;
+  num? get emHeightDescent native;
 
-  num get fontBoundingBoxAscent native;
+  num? get fontBoundingBoxAscent native;
 
-  num get fontBoundingBoxDescent native;
+  num? get fontBoundingBoxDescent native;
 
-  num get hangingBaseline native;
+  num? get hangingBaseline native;
 
-  num get ideographicBaseline native;
+  num? get ideographicBaseline native;
 
-  num get width native;
+  num? get width native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -29886,9 +29942,9 @@
 
   String get language native;
 
-  String get mode native;
+  String? get mode native;
 
-  set mode(String value) native;
+  set mode(String? value) native;
 
   void addCue(TextTrackCue cue) native;
 
@@ -29926,21 +29982,21 @@
   static const EventStreamProvider<Event> exitEvent =
       const EventStreamProvider<Event>('exit');
 
-  num get endTime native;
+  num? get endTime native;
 
-  set endTime(num value) native;
+  set endTime(num? value) native;
 
-  String get id native;
+  String? get id native;
 
-  set id(String value) native;
+  set id(String? value) native;
 
-  bool get pauseOnExit native;
+  bool? get pauseOnExit native;
 
-  set pauseOnExit(bool value) native;
+  set pauseOnExit(bool? value) native;
 
-  num get startTime native;
+  num? get startTime native;
 
-  set startTime(num value) native;
+  set startTime(num? value) native;
 
   TextTrack? get track native;
 
@@ -30108,9 +30164,9 @@
    */
   TimeElement.created() : super.created();
 
-  String get dateTime native;
+  String? get dateTime native;
 
-  set dateTime(String value) native;
+  set dateTime(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30178,36 +30234,36 @@
   static Touch _create_1(initDict) => JS('Touch', 'new Touch(#)', initDict);
 
   @JSName('clientX')
-  num get _clientX native;
+  num? get _clientX native;
 
   @JSName('clientY')
-  num get _clientY native;
+  num? get _clientY native;
 
-  num get force native;
+  num? get force native;
 
-  int get identifier native;
+  int? get identifier native;
 
   @JSName('pageX')
-  num get _pageX native;
+  num? get _pageX native;
 
   @JSName('pageY')
-  num get _pageY native;
+  num? get _pageY native;
 
   @JSName('radiusX')
-  num get _radiusX native;
+  num? get _radiusX native;
 
   @JSName('radiusY')
-  num get _radiusY native;
+  num? get _radiusY native;
 
   String? get region native;
 
-  num get rotationAngle native;
+  num? get rotationAngle native;
 
   @JSName('screenX')
-  num get _screenX native;
+  num? get _screenX native;
 
   @JSName('screenY')
-  num get _screenY native;
+  num? get _screenY native;
 
   EventTarget? get target => _convertNativeToDart_EventTarget(this._get_target);
   @JSName('target')
@@ -30265,19 +30321,19 @@
   static TouchEvent _create_2(type) =>
       JS('TouchEvent', 'new TouchEvent(#)', type);
 
-  bool get altKey native;
+  bool? get altKey native;
 
-  TouchList get changedTouches native;
+  TouchList? get changedTouches native;
 
-  bool get ctrlKey native;
+  bool? get ctrlKey native;
 
-  bool get metaKey native;
+  bool? get metaKey native;
 
-  bool get shiftKey native;
+  bool? get shiftKey native;
 
-  TouchList get targetTouches native;
+  TouchList? get targetTouches native;
 
-  TouchList get touches native;
+  TouchList? get touches native;
 
   /**
    * Checks if touch events supported on the current platform.
@@ -30387,15 +30443,15 @@
       label,
       kinds);
 
-  String get byteStreamTrackID native;
+  String? get byteStreamTrackID native;
 
-  Object get kinds native;
+  Object? get kinds native;
 
-  String get label native;
+  String? get label native;
 
-  String get language native;
+  String? get language native;
 
-  String get type native;
+  String? get type native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30419,7 +30475,7 @@
   static TrackDefaultList _create_2() =>
       JS('TrackDefaultList', 'new TrackDefaultList()');
 
-  int get length native;
+  int? get length native;
 
   TrackDefault item(int index) native;
 }
@@ -30457,30 +30513,30 @@
   static const int NONE = 0;
 
   @JSName('default')
-  bool get defaultValue native;
+  bool? get defaultValue native;
 
   @JSName('default')
-  set defaultValue(bool value) native;
+  set defaultValue(bool? value) native;
 
-  String get kind native;
+  String? get kind native;
 
-  set kind(String value) native;
+  set kind(String? value) native;
 
-  String get label native;
+  String? get label native;
 
-  set label(String value) native;
+  set label(String? value) native;
 
-  int get readyState native;
+  int? get readyState native;
 
-  String get src native;
+  String? get src native;
 
-  set src(String value) native;
+  set src(String? value) native;
 
-  String get srclang native;
+  String? get srclang native;
 
-  set srclang(String value) native;
+  set srclang(String? value) native;
 
-  TextTrack get track native;
+  TextTrack? get track native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30532,11 +30588,11 @@
   static TransitionEvent _create_2(type) =>
       JS('TransitionEvent', 'new TransitionEvent(#)', type);
 
-  num get elapsedTime native;
+  num? get elapsedTime native;
 
-  String get propertyName native;
+  String? get propertyName native;
 
-  String get pseudoElement native;
+  String? get pseudoElement native;
 }
 // Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30658,7 +30714,7 @@
       JS('UIEvent', 'new UIEvent(#,#)', type, eventInitDict);
   static UIEvent _create_2(type) => JS('UIEvent', 'new UIEvent(#)', type);
 
-  int get detail native;
+  int? get detail native;
 
   InputDeviceCapabilities? get sourceCapabilities native;
 
@@ -30670,7 +30726,7 @@
 
   @JSName('which')
   @Unstable()
-  int get _which native;
+  int? get _which native;
 
   @JSName('initUIEvent')
   void _initUIEvent(String type, bool bubbles, bool cancelable, Window? view,
@@ -30769,49 +30825,49 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get hash native;
+  String? get hash native;
 
-  set hash(String value) native;
+  set hash(String? value) native;
 
-  String get host native;
+  String? get host native;
 
-  set host(String value) native;
+  set host(String? value) native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  set hostname(String value) native;
+  set hostname(String? value) native;
 
-  String get href native;
+  String? get href native;
 
-  set href(String value) native;
+  set href(String? value) native;
 
-  String get origin native;
+  String? get origin native;
 
-  String get password native;
+  String? get password native;
 
-  set password(String value) native;
+  set password(String? value) native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  set pathname(String value) native;
+  set pathname(String? value) native;
 
-  String get port native;
+  String? get port native;
 
-  set port(String value) native;
+  set port(String? value) native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  set protocol(String value) native;
+  set protocol(String? value) native;
 
-  String get search native;
+  String? get search native;
 
-  set search(String value) native;
+  set search(String? value) native;
 
-  UrlSearchParams get searchParams native;
+  UrlSearchParams? get searchParams native;
 
-  String get username native;
+  String? get username native;
 
-  set username(String value) native;
+  set username(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30859,23 +30915,23 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get hash native;
+  String? get hash native;
 
-  String get host native;
+  String? get host native;
 
-  String get hostname native;
+  String? get hostname native;
 
-  String get href native;
+  String? get href native;
 
-  String get origin native;
+  String? get origin native;
 
-  String get pathname native;
+  String? get pathname native;
 
-  String get port native;
+  String? get port native;
 
-  String get protocol native;
+  String? get protocol native;
 
-  String get search native;
+  String? get search native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30914,9 +30970,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get deviceName native;
+  String? get deviceName native;
 
-  bool get isExternal native;
+  bool? get isExternal native;
 
   Future requestSession([Map? options]) {
     var options_dict = null;
@@ -30952,7 +31008,7 @@
   static VRDeviceEvent _create_1(type, eventInitDict) =>
       JS('VRDeviceEvent', 'new VRDeviceEvent(#,#)', type, eventInitDict);
 
-  VRDevice get device native;
+  VRDevice? get device native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -30965,23 +31021,23 @@
     throw new UnsupportedError("Not supported");
   }
 
-  VRDisplayCapabilities get capabilities native;
+  VRDisplayCapabilities? get capabilities native;
 
-  num get depthFar native;
+  num? get depthFar native;
 
-  set depthFar(num value) native;
+  set depthFar(num? value) native;
 
-  num get depthNear native;
+  num? get depthNear native;
 
-  set depthNear(num value) native;
+  set depthNear(num? value) native;
 
-  int get displayId native;
+  int? get displayId native;
 
-  String get displayName native;
+  String? get displayName native;
 
-  bool get isPresenting native;
+  bool? get isPresenting native;
 
-  VRStageParameters get stageParameters native;
+  VRStageParameters? get stageParameters native;
 
   void cancelAnimationFrame(int handle) native;
 
@@ -31011,13 +31067,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get canPresent native;
+  bool? get canPresent native;
 
-  bool get hasExternalDisplay native;
+  bool? get hasExternalDisplay native;
 
-  bool get hasPosition native;
+  bool? get hasPosition native;
 
-  int get maxLayers native;
+  int? get maxLayers native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31042,9 +31098,9 @@
   static VRDisplayEvent _create_2(type) =>
       JS('VRDisplayEvent', 'new VRDisplayEvent(#)', type);
 
-  VRDisplay get display native;
+  VRDisplay? get display native;
 
-  String get reason native;
+  String? get reason native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31057,11 +31113,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Float32List get offset native;
+  Float32List? get offset native;
 
-  int get renderHeight native;
+  int? get renderHeight native;
 
-  int get renderWidth native;
+  int? get renderWidth native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31079,15 +31135,15 @@
   }
   static VRFrameData _create_1() => JS('VRFrameData', 'new VRFrameData()');
 
-  Float32List get leftProjectionMatrix native;
+  Float32List? get leftProjectionMatrix native;
 
-  Float32List get leftViewMatrix native;
+  Float32List? get leftViewMatrix native;
 
-  VRPose get pose native;
+  VRPose? get pose native;
 
-  Float32List get rightProjectionMatrix native;
+  Float32List? get rightProjectionMatrix native;
 
-  Float32List get rightViewMatrix native;
+  Float32List? get rightViewMatrix native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31102,7 +31158,7 @@
 
   VRStageBounds? get bounds native;
 
-  num get emulatedHeight native;
+  num? get emulatedHeight native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31144,17 +31200,17 @@
   static const EventStreamProvider<Event> focusEvent =
       const EventStreamProvider<Event>('focus');
 
-  num get depthFar native;
+  num? get depthFar native;
 
-  set depthFar(num value) native;
+  set depthFar(num? value) native;
 
-  num get depthNear native;
+  num? get depthNear native;
 
-  set depthNear(num value) native;
+  set depthNear(num? value) native;
 
-  VRDevice get device native;
+  VRDevice? get device native;
 
-  bool get exclusive native;
+  bool? get exclusive native;
 
   Future end() => promiseToFuture(JS("", "#.end()", this));
 
@@ -31189,7 +31245,7 @@
   static VRSessionEvent _create_1(type, eventInitDict) =>
       JS('VRSessionEvent', 'new VRSessionEvent(#,#)', type, eventInitDict);
 
-  VRSession get session native;
+  VRSession? get session native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31202,7 +31258,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  List<VRStageBoundsPoint> get geometry native;
+  List<VRStageBoundsPoint>? get geometry native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31215,9 +31271,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get x native;
+  num? get x native;
 
-  num get z native;
+  num? get z native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31230,11 +31286,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Float32List get sittingToStandingTransform native;
+  Float32List? get sittingToStandingTransform native;
 
-  num get sizeX native;
+  num? get sizeX native;
 
-  num get sizeZ native;
+  num? get sizeZ native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31247,27 +31303,27 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get badInput native;
+  bool? get badInput native;
 
-  bool get customError native;
+  bool? get customError native;
 
-  bool get patternMismatch native;
+  bool? get patternMismatch native;
 
-  bool get rangeOverflow native;
+  bool? get rangeOverflow native;
 
-  bool get rangeUnderflow native;
+  bool? get rangeUnderflow native;
 
-  bool get stepMismatch native;
+  bool? get stepMismatch native;
 
-  bool get tooLong native;
+  bool? get tooLong native;
 
-  bool get tooShort native;
+  bool? get tooShort native;
 
-  bool get typeMismatch native;
+  bool? get typeMismatch native;
 
-  bool get valid native;
+  bool? get valid native;
 
-  bool get valueMissing native;
+  bool? get valueMissing native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31307,12 +31363,12 @@
   @JSName('webkitDecodedFrameCount')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  int get decodedFrameCount native;
+  int? get decodedFrameCount native;
 
   @JSName('webkitDroppedFrameCount')
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.SAFARI)
-  int get droppedFrameCount native;
+  int? get droppedFrameCount native;
 
   int get width native;
 
@@ -31341,13 +31397,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get corruptedVideoFrames native;
+  int? get corruptedVideoFrames native;
 
-  num get creationTime native;
+  num? get creationTime native;
 
-  int get droppedVideoFrames native;
+  int? get droppedVideoFrames native;
 
-  int get totalVideoFrames native;
+  int? get totalVideoFrames native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31360,17 +31416,17 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get id native;
+  String? get id native;
 
-  String get kind native;
+  String? get kind native;
 
-  String get label native;
+  String? get label native;
 
-  String get language native;
+  String? get language native;
 
-  bool get selected native;
+  bool? get selected native;
 
-  set selected(bool value) native;
+  set selected(bool? value) native;
 
   SourceBuffer? get sourceBuffer native;
 }
@@ -31388,9 +31444,9 @@
   static const EventStreamProvider<Event> changeEvent =
       const EventStreamProvider<Event>('change');
 
-  int get length native;
+  int? get length native;
 
-  int get selectedIndex native;
+  int? get selectedIndex native;
 
   VideoTrack __getter__(int index) native;
 
@@ -31415,19 +31471,19 @@
   static const EventStreamProvider<Event> scrollEvent =
       const EventStreamProvider<Event>('scroll');
 
-  num get height native;
+  num? get height native;
 
-  num get offsetLeft native;
+  num? get offsetLeft native;
 
-  num get offsetTop native;
+  num? get offsetTop native;
 
-  num get pageLeft native;
+  num? get pageLeft native;
 
-  num get pageTop native;
+  num? get pageTop native;
 
-  num get scale native;
+  num? get scale native;
 
-  num get width native;
+  num? get width native;
 
   Stream<Event> get onResize => resizeEvent.forTarget(this);
 
@@ -31457,9 +31513,9 @@
   static VttCue _create_1(startTime, endTime, text) =>
       JS('VttCue', 'new VTTCue(#,#,#)', startTime, endTime, text);
 
-  String get align native;
+  String? get align native;
 
-  set align(String value) native;
+  set align(String? value) native;
 
   @Creates('Null')
   @Returns('num|String')
@@ -31477,21 +31533,21 @@
 
   set region(VttRegion? value) native;
 
-  num get size native;
+  num? get size native;
 
-  set size(num value) native;
+  set size(num? value) native;
 
-  bool get snapToLines native;
+  bool? get snapToLines native;
 
-  set snapToLines(bool value) native;
+  set snapToLines(bool? value) native;
 
-  String get text native;
+  String? get text native;
 
-  set text(String value) native;
+  set text(String? value) native;
 
-  String get vertical native;
+  String? get vertical native;
 
-  set vertical(String value) native;
+  set vertical(String? value) native;
 
   @JSName('getCueAsHTML')
   DocumentFragment getCueAsHtml() native;
@@ -31512,37 +31568,37 @@
   }
   static VttRegion _create_1() => JS('VttRegion', 'new VTTRegion()');
 
-  String get id native;
+  String? get id native;
 
-  set id(String value) native;
+  set id(String? value) native;
 
-  int get lines native;
+  int? get lines native;
 
-  set lines(int value) native;
+  set lines(int? value) native;
 
-  num get regionAnchorX native;
+  num? get regionAnchorX native;
 
-  set regionAnchorX(num value) native;
+  set regionAnchorX(num? value) native;
 
-  num get regionAnchorY native;
+  num? get regionAnchorY native;
 
-  set regionAnchorY(num value) native;
+  set regionAnchorY(num? value) native;
 
-  String get scroll native;
+  String? get scroll native;
 
-  set scroll(String value) native;
+  set scroll(String? value) native;
 
-  num get viewportAnchorX native;
+  num? get viewportAnchorX native;
 
-  set viewportAnchorX(num value) native;
+  set viewportAnchorX(num? value) native;
 
-  num get viewportAnchorY native;
+  num? get viewportAnchorY native;
 
-  set viewportAnchorY(num value) native;
+  set viewportAnchorY(num? value) native;
 
-  num get width native;
+  num? get width native;
 
-  set width(num value) native;
+  set width(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -31652,19 +31708,19 @@
 
   static const int OPEN = 1;
 
-  String get binaryType native;
+  String? get binaryType native;
 
-  set binaryType(String value) native;
+  set binaryType(String? value) native;
 
-  int get bufferedAmount native;
+  int? get bufferedAmount native;
 
-  String get extensions native;
+  String? get extensions native;
 
-  String get protocol native;
+  String? get protocol native;
 
   int get readyState native;
 
-  String get url native;
+  String? get url native;
 
   void close([int? code, String? reason]) native;
 
@@ -31802,12 +31858,12 @@
   static const int DOM_DELTA_PIXEL = 0x00;
 
   @JSName('deltaX')
-  num get _deltaX native;
+  num? get _deltaX native;
 
   @JSName('deltaY')
-  num get _deltaY native;
+  num? get _deltaY native;
 
-  num get deltaZ native;
+  num? get deltaZ native;
 
   /**
    * The amount that is expected to scroll vertically, in units determined by
@@ -31818,10 +31874,9 @@
    * * [WheelEvent.deltaY](http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#events-WheelEvent-deltaY) from the W3C.
    */
   num get deltaY {
-    if (JS('bool', '#.deltaY !== undefined', this)) {
-      // W3C WheelEvent
-      return this._deltaY;
-    }
+    // deltaY may be missing or undefined.
+    num? value = JS('', '#.deltaY', this);
+    if (value != null) return value;
     throw new UnsupportedError('deltaY is not supported');
   }
 
@@ -31834,10 +31889,9 @@
    * * [WheelEvent.deltaX](http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#events-WheelEvent-deltaX) from the W3C.
    */
   num get deltaX {
-    if (JS('bool', '#.deltaX !== undefined', this)) {
-      // W3C WheelEvent
-      return this._deltaX;
-    }
+    // deltaX may be missing or undefined.
+    num? value = JS('', '#.deltaX', this);
+    if (value != null) return value;
     throw new UnsupportedError('deltaX is not supported');
   }
 
@@ -32306,7 +32360,7 @@
    */
   static const int TEMPORARY = 0;
 
-  _Worklet get animationWorklet native;
+  _Worklet? get animationWorklet native;
 
   /**
    * The application cache for this window.
@@ -32321,15 +32375,15 @@
    *   from WHATWG.
    */
 
-  ApplicationCache get applicationCache native;
+  ApplicationCache? get applicationCache native;
 
-  _Worklet get audioWorklet native;
+  _Worklet? get audioWorklet native;
 
-  CacheStorage get caches native;
+  CacheStorage? get caches native;
 
-  bool get closed native;
+  bool? get closed native;
 
-  CookieStore get cookieStore native;
+  CookieStore? get cookieStore native;
 
   /**
    * Entrypoint for the browser's cryptographic functions.
@@ -32339,21 +32393,21 @@
    * * [Web cryptography API](http://www.w3.org/TR/WebCryptoAPI/) from W3C.
    */
 
-  Crypto get crypto native;
+  Crypto? get crypto native;
 
-  CustomElementRegistry get customElements native;
+  CustomElementRegistry? get customElements native;
 
   /// *Deprecated*.
 
-  String get defaultStatus native;
+  String? get defaultStatus native;
 
-  set defaultStatus(String value) native;
+  set defaultStatus(String? value) native;
 
   /// *Deprecated*.
 
-  String get defaultstatus native;
+  String? get defaultstatus native;
 
-  set defaultstatus(String value) native;
+  set defaultstatus(String? value) native;
 
   /**
    * The ratio between physical pixels and logical CSS pixels.
@@ -32368,7 +32422,7 @@
 
   num get devicePixelRatio native;
 
-  External get external native;
+  External? get external native;
 
   /**
    * The current session history for this window's newest document.
@@ -32390,7 +32444,7 @@
    *   from MDN.
    */
 
-  int get innerHeight native;
+  int? get innerHeight native;
 
   /**
    * The width of the viewport including scrollbars.
@@ -32401,9 +32455,9 @@
    *   from MDN.
    */
 
-  int get innerWidth native;
+  int? get innerWidth native;
 
-  bool get isSecureContext native;
+  bool? get isSecureContext native;
 
   /**
    * Storage for this window that persists across sessions.
@@ -32430,7 +32484,7 @@
    *   from WHATWG.
    */
 
-  BarProp get locationbar native;
+  BarProp? get locationbar native;
 
   /**
    * This window's menu bar, which displays menu commands.
@@ -32442,7 +32496,7 @@
    *   from WHATWG.
    */
 
-  BarProp get menubar native;
+  BarProp? get menubar native;
 
   /**
    * The name of this window.
@@ -32453,9 +32507,9 @@
    *   from MDN.
    */
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
   /**
    * The user agent accessing this window.
@@ -32478,7 +32532,7 @@
    *   from WebPlatform.org.
    */
 
-  bool get offscreenBuffering native;
+  bool? get offscreenBuffering native;
 
   WindowBase? get opener => _convertNativeToDart_Window(this._get_opener);
   @JSName('opener')
@@ -32488,9 +32542,9 @@
 
   set opener(WindowBase? value) native;
 
-  int get orientation native;
+  int? get orientation native;
 
-  String get origin native;
+  String? get origin native;
 
   /**
    * The height of this window including all user interface elements.
@@ -32581,7 +32635,7 @@
    *   from W3C.
    */
 
-  Screen get screen native;
+  Screen? get screen native;
 
   /**
    * The distance from the left side of the screen to the left side of this
@@ -32593,7 +32647,7 @@
    *   from W3C.
    */
 
-  int get screenLeft native;
+  int? get screenLeft native;
 
   /**
    * The distance from the top of the screen to the top of this window.
@@ -32604,7 +32658,7 @@
    *   from W3C.
    */
 
-  int get screenTop native;
+  int? get screenTop native;
 
   /**
    * The distance from the left side of the screen to the mouse pointer.
@@ -32615,7 +32669,7 @@
    *   from W3C.
    */
 
-  int get screenX native;
+  int? get screenX native;
 
   /**
    * The distance from the top of the screen to the mouse pointer.
@@ -32626,7 +32680,7 @@
    *   from W3C.
    */
 
-  int get screenY native;
+  int? get screenY native;
 
   /**
    * This window's scroll bars.
@@ -32638,7 +32692,7 @@
    *   from WHATWG.
    */
 
-  BarProp get scrollbars native;
+  BarProp? get scrollbars native;
 
   /**
    * The current window.
@@ -32688,13 +32742,13 @@
    *   from W3C.
    */
 
-  SpeechSynthesis get speechSynthesis native;
+  SpeechSynthesis? get speechSynthesis native;
 
   /// *Deprecated*.
 
-  String get status native;
+  String? get status native;
 
-  set status(String value) native;
+  set status(String? value) native;
 
   /**
    * This window's status bar.
@@ -32706,7 +32760,7 @@
    *   from WHATWG.
    */
 
-  BarProp get statusbar native;
+  BarProp? get statusbar native;
 
   /**
    * Access to CSS media queries.
@@ -32718,7 +32772,7 @@
    *   from Safari Developer Library.
    */
 
-  StyleMedia get styleMedia native;
+  StyleMedia? get styleMedia native;
 
   /**
    * This window's tool bar.
@@ -32730,7 +32784,7 @@
    *   from WHATWG.
    */
 
-  BarProp get toolbar native;
+  BarProp? get toolbar native;
 
   WindowBase? get top => _convertNativeToDart_Window(this._get_top);
   @JSName('top')
@@ -33639,8 +33693,9 @@
 
   String get returnValue => _returnValue;
 
-  set returnValue(String value) {
-    _returnValue = value;
+  set returnValue(String? value) {
+    // Typed as nullable only to be compatible with the overriden method.
+    _returnValue = value!;
     // FF and IE use the value as the return value, Chrome will return this from
     // the event callback function.
     if (JS<bool>('bool', '("returnValue" in #)', wrapped)) {
@@ -33712,9 +33767,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get focused native;
+  bool? get focused native;
 
-  String get visibilityState native;
+  String? get visibilityState native;
 
   Future<WindowClient> focus() =>
       promiseToFuture<WindowClient>(JS("", "#.focus()", this));
@@ -33855,23 +33910,23 @@
   static const EventStreamProvider<Event> errorEvent =
       const EventStreamProvider<Event>('error');
 
-  String get addressSpace native;
+  String? get addressSpace native;
 
-  CacheStorage get caches native;
+  CacheStorage? get caches native;
 
-  Crypto get crypto native;
+  Crypto? get crypto native;
 
-  IdbFactory get indexedDB native;
+  IdbFactory? get indexedDB native;
 
-  bool get isSecureContext native;
+  bool? get isSecureContext native;
 
   _WorkerLocation get location native;
 
   _WorkerNavigator get navigator native;
 
-  String get origin native;
+  String? get origin native;
 
-  WorkerPerformance get performance native;
+  WorkerPerformance? get performance native;
 
   WorkerGlobalScope get self native;
 
@@ -33930,9 +33985,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  MemoryInfo get memory native;
+  MemoryInfo? get memory native;
 
-  num get timeOrigin native;
+  num? get timeOrigin native;
 
   void clearMarks(String? markName) native;
 
@@ -33980,7 +34035,7 @@
       JS('WorkletAnimation', 'new WorkletAnimation(#,#,#,#)', animatorName,
           effects, timelines, options);
 
-  String get playState native;
+  String? get playState native;
 
   void cancel() native;
 
@@ -34089,19 +34144,19 @@
 
   static const int UNORDERED_NODE_SNAPSHOT_TYPE = 6;
 
-  bool get booleanValue native;
+  bool? get booleanValue native;
 
-  bool get invalidIteratorState native;
+  bool? get invalidIteratorState native;
 
-  num get numberValue native;
+  num? get numberValue native;
 
-  int get resultType native;
+  int? get resultType native;
 
-  Node get singleNodeValue native;
+  Node? get singleNodeValue native;
 
-  int get snapshotLength native;
+  int? get snapshotLength native;
 
-  String get stringValue native;
+  String? get stringValue native;
 
   Node? iterateNext() native;
 
@@ -34192,16 +34247,16 @@
   }
 
   @JSName('localName')
-  String get _localName native;
+  String? get _localName native;
 
-  String get name native;
+  String? get name native;
 
   @JSName('namespaceURI')
   String? get _namespaceUri native;
 
-  String get value native;
+  String? get value native;
 
-  set value(String value) native;
+  set value(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -34579,27 +34634,39 @@
 
   // Shadowing definition.
 
-  num get height native;
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
+
+  @JSName('height')
+  num? get _height native;
+
+  num get height => _height!;
 
   set height(num value) native;
 
   // Shadowing definition.
 
-  num get width native;
+  // The following getter is incompatible with some browsers but
+  // must be made non-nullable to match the overridden method.
+
+  @JSName('width')
+  num? get _width native;
+
+  num get width => _width!;
 
   set width(num value) native;
 
   // Shadowing definition.
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
   // Shadowing definition.
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 }
 
 /**
@@ -35065,9 +35132,9 @@
 
   ReportBody? get body native;
 
-  String get type native;
+  String? get type native;
 
-  String get url native;
+  String? get url native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -35091,23 +35158,23 @@
       JS('_Request', 'new Request(#,#)', input, requestInitDict);
   static _Request _create_2(input) => JS('_Request', 'new Request(#)', input);
 
-  String get cache native;
+  String? get cache native;
 
-  String get credentials native;
+  String? get credentials native;
 
-  Headers get headers native;
+  Headers? get headers native;
 
-  String get integrity native;
+  String? get integrity native;
 
-  String get mode native;
+  String? get mode native;
 
-  String get redirect native;
+  String? get redirect native;
 
-  String get referrer native;
+  String? get referrer native;
 
-  String get referrerPolicy native;
+  String? get referrerPolicy native;
 
-  String get url native;
+  String? get url native;
 
   _Request clone() native;
 }
@@ -35671,12 +35738,12 @@
 
   Iterable<String> get keys {
     // TODO: generate a lazy collection instead.
-    var attributes = _element._attributes;
+    var attributes = _element._attributes!;
     var keys = <String>[];
     for (int i = 0, len = attributes.length; i < len; i++) {
       _Attr attr = attributes[i] as _Attr;
       if (_matches(attr)) {
-        keys.add(attr.name);
+        keys.add(attr.name!);
       }
     }
     return keys;
@@ -35684,12 +35751,12 @@
 
   Iterable<String> get values {
     // TODO: generate a lazy collection instead.
-    var attributes = _element._attributes;
+    var attributes = _element._attributes!;
     var values = <String>[];
     for (int i = 0, len = attributes.length; i < len; i++) {
       _Attr attr = attributes[i] as _Attr;
       if (_matches(attr)) {
-        values.add(attr.value);
+        values.add(attr.value!);
       }
     }
     return values;
@@ -36012,8 +36079,11 @@
    *     print(window.closed); // 'false'
    *     window.close();
    *     print(window.closed); // 'true'
+   *
+   * MDN does not have compatibility info on this attribute, and therefore is
+   * marked nullable.
    */
-  bool get closed;
+  bool? get closed;
 
   /**
    * A reference to the window that opened this one.
@@ -40521,12 +40591,12 @@
   static EventStreamProvider<KeyEvent> keyPressEvent =
       new _KeyboardEventHandler('keypress');
 
-  String get code => _parent.code;
+  String get code => _parent.code!;
   /** True if the ctrl key is pressed during this event. */
   bool get ctrlKey => _parent.ctrlKey;
-  int get detail => _parent.detail;
-  bool get isComposing => _parent.isComposing;
-  String get key => _parent.key;
+  int get detail => _parent.detail!;
+  bool get isComposing => _parent.isComposing!;
+  String get key => _parent.key!;
   /**
    * Accessor to the part of the keyboard that the key was pressed from (one of
    * KeyLocation.STANDARD, KeyLocation.RIGHT, KeyLocation.LEFT,
@@ -40608,11 +40678,11 @@
 
   _WrappedEvent(this.wrapped);
 
-  bool get bubbles => wrapped.bubbles;
+  bool get bubbles => wrapped.bubbles!;
 
-  bool get cancelable => wrapped.cancelable;
+  bool get cancelable => wrapped.cancelable!;
 
-  bool get composed => wrapped.composed;
+  bool get composed => wrapped.composed!;
 
   EventTarget? get currentTarget => wrapped.currentTarget;
 
@@ -40620,7 +40690,7 @@
 
   int get eventPhase => wrapped.eventPhase;
 
-  bool get isTrusted => wrapped.isTrusted;
+  bool get isTrusted => wrapped.isTrusted!;
 
   EventTarget? get target => wrapped.target;
 
@@ -41045,7 +41115,7 @@
 
     if (element is TemplateElement) {
       TemplateElement template = element;
-      sanitizeTree(template.content);
+      sanitizeTree(template.content!);
     }
   }
 
diff --git a/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart b/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart
index 4cb159b..f8fb0a7 100644
--- a/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart
+++ b/sdk/lib/indexed_db/dart2js/indexed_db_dart2js.dart
@@ -244,7 +244,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get direction native;
+  String? get direction native;
 
   @_annotation_Creates_IDBKey
   @_annotation_Returns_IDBKey
@@ -400,15 +400,15 @@
   static const EventStreamProvider<VersionChangeEvent> versionChangeEvent =
       const EventStreamProvider<VersionChangeEvent>('versionchange');
 
-  String get name native;
+  String? get name native;
 
   @Returns('DomStringList')
   @Creates('DomStringList')
-  List<String> get objectStoreNames native;
+  List<String>? get objectStoreNames native;
 
   @Creates('int|String|Null')
   @Returns('int|String|Null')
-  int get version native;
+  int? get version native;
 
   void close() native;
 
@@ -656,15 +656,15 @@
   @annotation_Creates_SerializedScriptValue
   Object? get keyPath native;
 
-  bool get multiEntry native;
+  bool? get multiEntry native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  ObjectStore get objectStore native;
+  ObjectStore? get objectStore native;
 
-  bool get unique native;
+  bool? get unique native;
 
   @JSName('count')
   Request _count(Object? key) native;
@@ -727,12 +727,12 @@
   @annotation_Creates_SerializedScriptValue
   Object? get lower native;
 
-  bool get lowerOpen native;
+  bool? get lowerOpen native;
 
   @annotation_Creates_SerializedScriptValue
   Object? get upper native;
 
-  bool get upperOpen native;
+  bool? get upperOpen native;
 
   @JSName('bound')
   static KeyRange bound_(Object lower, Object upper,
@@ -879,20 +879,20 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get autoIncrement native;
+  bool? get autoIncrement native;
 
   @Returns('DomStringList')
   @Creates('DomStringList')
-  List<String> get indexNames native;
+  List<String>? get indexNames native;
 
   @annotation_Creates_SerializedScriptValue
   Object? get keyPath native;
 
-  String get name native;
+  String? get name native;
 
-  set name(String value) native;
+  set name(String? value) native;
 
-  Transaction get transaction native;
+  Transaction? get transaction native;
 
   @Returns('Request')
   @Creates('Request')
@@ -1028,7 +1028,7 @@
 
   Object? get key native;
 
-  String get type native;
+  String? get type native;
 
   Object? get value native;
 }
@@ -1072,11 +1072,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Database get database native;
+  Database? get database native;
 
   Object? get records native;
 
-  Transaction get transaction native;
+  Transaction? get transaction native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1145,9 +1145,9 @@
   static const EventStreamProvider<Event> successEvent =
       const EventStreamProvider<Event>('success');
 
-  DomException get error native;
+  DomException? get error native;
 
-  String get readyState native;
+  String? get readyState native;
 
   dynamic get result => _convertNativeToDart_IDBAny(this._get_result);
   @JSName('result')
@@ -1157,7 +1157,7 @@
   @Creates('Null')
   Object? get source native;
 
-  Transaction get transaction native;
+  Transaction? get transaction native;
 
   /// Stream of `error` events handled by this [Request].
   Stream<Event> get onError => errorEvent.forTarget(this);
@@ -1232,15 +1232,15 @@
   static const EventStreamProvider<Event> errorEvent =
       const EventStreamProvider<Event>('error');
 
-  Database get db native;
+  Database? get db native;
 
-  DomException get error native;
+  DomException? get error native;
 
-  String get mode native;
+  String? get mode native;
 
   @Returns('DomStringList')
   @Creates('DomStringList')
-  List<String> get objectStoreNames native;
+  List<String>? get objectStoreNames native;
 
   void abort() native;
 
@@ -1282,9 +1282,9 @@
   static VersionChangeEvent _create_2(type) =>
       JS('VersionChangeEvent', 'new IDBVersionChangeEvent(#)', type);
 
-  String get dataLoss native;
+  String? get dataLoss native;
 
-  String get dataLossMessage native;
+  String? get dataLossMessage native;
 
   @Creates('int|String|Null')
   @Returns('int|String|Null')
@@ -1292,7 +1292,7 @@
 
   @Creates('int|String|Null')
   @Returns('int|String|Null')
-  int get oldVersion native;
+  int? get oldVersion native;
 
   @JSName('target')
   OpenDBRequest get target native;
diff --git a/sdk/lib/io/directory.dart b/sdk/lib/io/directory.dart
index 90e2159..ee8ef1d 100644
--- a/sdk/lib/io/directory.dart
+++ b/sdk/lib/io/directory.dart
@@ -99,15 +99,10 @@
  *
  * ## Other resources
  *
- * * [Dart by Example](https://www.dartlang.org/dart-by-example/#files-directories-and-symlinks)
- *   provides additional task-oriented code samples that show how to use
- *   various API from the Directory class and the related [File] class.
+ * * The [Files and directories](https://dart.dev/guides/libraries/library-tour#files-and-directories)
+ *   section of the library tour.
  *
- * * [I/O for Command-Line
- *   Apps](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#dartio---io-for-command-line-apps)
- *   a section from _A Tour of the Dart Libraries_ covers files and directories.
- *
- * * [Write Command-Line Apps](https://www.dartlang.org/docs/tutorials/cmdline/),
+ * * [Write Command-Line Apps](https://dart.dev/tutorials/server/cmdline),
  *   a tutorial about writing command-line apps, includes information about
  *   files and directories.
  */
diff --git a/sdk/lib/io/file.dart b/sdk/lib/io/file.dart
index 234220a..9c1f2f5 100644
--- a/sdk/lib/io/file.dart
+++ b/sdk/lib/io/file.dart
@@ -225,15 +225,10 @@
  *
  * ## Other resources
  *
- * * [Dart by Example](https://www.dartlang.org/dart-by-example/#files-directories-and-symlinks)
- *   provides additional task-oriented code samples that show how to use
- *   various API from the Directory class and the related [File] class.
+ * * The [Files and directories](https://dart.dev/guides/libraries/library-tour#files-and-directories)
+ *   section of the library tour.
  *
- * * [I/O for Command-Line
- *   Apps](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#dartio---io-for-command-line-apps)
- *   a section from _A Tour of the Dart Libraries_ covers files and directories.
- *
- * * [Write Command-Line Apps](https://www.dartlang.org/docs/tutorials/cmdline/),
+ * * [Write Command-Line Apps](https://dart.dev/tutorials/server/cmdline),
  *   a tutorial about writing command-line apps, includes information about
  *   files and directories.
  */
diff --git a/sdk/lib/io/file_system_entity.dart b/sdk/lib/io/file_system_entity.dart
index 0741583..b8cf2ff 100644
--- a/sdk/lib/io/file_system_entity.dart
+++ b/sdk/lib/io/file_system_entity.dart
@@ -232,17 +232,10 @@
  *
  * ## Other resources
  *
- * * [Dart by
- *   Example](https://www.dartlang.org/dart-by-example/#files-directories-and-symlinks)
- *   provides additional task-oriented code samples that show how to use various
- *   API from the [Directory] class and the [File] class, both subclasses of
- *   FileSystemEntity.
+ * * The [Files and directories](https://dart.dev/guides/libraries/library-tour#files-and-directories)
+ *   section of the library tour.
  *
- * * [I/O for Command-Line
- *   Apps](https://www.dartlang.org/docs/dart-up-and-running/ch03.html#dartio---io-for-command-line-apps),
- *   a section from _A Tour of the Dart Libraries_ covers files and directories.
- *
- * * [Write Command-Line Apps](https://www.dartlang.org/docs/tutorials/cmdline/),
+ * * [Write Command-Line Apps](https://dart.dev/tutorials/server/cmdline),
  *   a tutorial about writing command-line apps, includes information about
  *   files and directories.
  */
diff --git a/sdk/lib/io/io.dart b/sdk/lib/io/io.dart
index 27cd6a3..7dcabd8 100644
--- a/sdk/lib/io/io.dart
+++ b/sdk/lib/io/io.dart
@@ -21,7 +21,7 @@
  *     import 'dart:io';
  *
  * For an introduction to I/O in Dart, see the [dart:io library
- * tour](https://www.dartlang.org/dart-vm/io-library-tour).
+ * tour](https://dart.dev/guides/libraries/library-tour#dartio).
  *
  * ## File, Directory, and Link
  *
diff --git a/sdk/lib/io/platform.dart b/sdk/lib/io/platform.dart
index 412e258..c484461 100644
--- a/sdk/lib/io/platform.dart
+++ b/sdk/lib/io/platform.dart
@@ -58,12 +58,6 @@
  *         print('is not a Mac');
  *       }
  *     }
- *
- * ## Other resources
- *
- * [Dart by Example](https://www.dartlang.org/dart-by-example/#dart-io-and-command-line-apps)
- * provides additional task-oriented code samples that show how to use
- * various API from the [dart:io] library.
  */
 class Platform {
   static final _numberOfProcessors = _Platform.numberOfProcessors;
diff --git a/sdk/lib/io/process.dart b/sdk/lib/io/process.dart
index e0d0b15..d976baf 100644
--- a/sdk/lib/io/process.dart
+++ b/sdk/lib/io/process.dart
@@ -261,12 +261,6 @@
  *         });
  *       });
  *     }
- *
- * ## Other resources
- *
- * [Dart by Example](https://www.dartlang.org/dart-by-example/#dart-io-and-command-line-apps)
- * provides additional task-oriented code samples that show how to use
- * various API from the [dart:io] library.
  */
 abstract class Process {
   /**
diff --git a/sdk/lib/libraries.json b/sdk/lib/libraries.json
index 0289238..15b4cd3 100644
--- a/sdk/lib/libraries.json
+++ b/sdk/lib/libraries.json
@@ -221,11 +221,6 @@
         "uri": "math/math.dart",
         "patches": "_internal/js_runtime/lib/math_patch.dart"
       },
-      "mirrors": {
-        "uri": "mirrors/mirrors.dart",
-        "patches": "_internal/js_runtime/lib/mirrors_patch_cfe.dart",
-        "supported": false
-      },
       "typed_data": {
         "uri": "typed_data/typed_data.dart",
         "patches": "_internal/js_runtime/lib/typed_data_patch.dart"
@@ -334,11 +329,6 @@
         "uri": "math/math.dart",
         "patches": "_internal/js_runtime/lib/math_patch.dart"
       },
-      "mirrors": {
-        "uri": "mirrors/mirrors.dart",
-        "patches": "_internal/js_runtime/lib/mirrors_patch_cfe.dart",
-        "supported": false
-      },
       "typed_data": {
         "uri": "typed_data/typed_data.dart",
         "patches": "_internal/js_runtime/lib/typed_data_patch.dart"
@@ -448,11 +438,6 @@
         "patches": "_internal/js_dev_runtime/patch/isolate_patch.dart",
         "supported": false
       },
-      "mirrors": {
-        "uri": "mirrors/mirrors.dart",
-        "patches": "_internal/js_runtime/lib/mirrors_patch_cfe.dart",
-        "supported": false
-      },
       "math": {
         "uri": "math/math.dart",
         "patches": "_internal/js_dev_runtime/patch/math_patch.dart"
diff --git a/sdk/lib/libraries.yaml b/sdk/lib/libraries.yaml
index a80284d..50e350e 100644
--- a/sdk/lib/libraries.yaml
+++ b/sdk/lib/libraries.yaml
@@ -218,11 +218,6 @@
       uri: "math/math.dart"
       patches: "_internal/js_runtime/lib/math_patch.dart"
 
-    mirrors:
-      uri: "mirrors/mirrors.dart"
-      patches: "_internal/js_runtime/lib/mirrors_patch_cfe.dart"
-      supported: false
-
     typed_data:
       uri: "typed_data/typed_data.dart"
       patches: "_internal/js_runtime/lib/typed_data_patch.dart"
@@ -329,11 +324,6 @@
       uri: "math/math.dart"
       patches: "_internal/js_runtime/lib/math_patch.dart"
 
-    mirrors:
-      uri: "mirrors/mirrors.dart"
-      patches: "_internal/js_runtime/lib/mirrors_patch_cfe.dart"
-      supported: false
-
     typed_data:
       uri: "typed_data/typed_data.dart"
       patches: "_internal/js_runtime/lib/typed_data_patch.dart"
@@ -441,11 +431,6 @@
         patches: "_internal/js_dev_runtime/patch/isolate_patch.dart"
         supported: false
 
-      mirrors:
-        uri: "mirrors/mirrors.dart"
-        patches: "_internal/js_runtime/lib/mirrors_patch_cfe.dart"
-        supported: false
-
       math:
         uri: "math/math.dart"
         patches: "_internal/js_dev_runtime/patch/math_patch.dart"
diff --git a/sdk/lib/svg/dart2js/svg_dart2js.dart b/sdk/lib/svg/dart2js/svg_dart2js.dart
index ebb9015..f016890 100644
--- a/sdk/lib/svg/dart2js/svg_dart2js.dart
+++ b/sdk/lib/svg/dart2js/svg_dart2js.dart
@@ -58,7 +58,7 @@
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -82,19 +82,19 @@
 
   static const int SVG_ANGLETYPE_UNSPECIFIED = 1;
 
-  int get unitType native;
+  int? get unitType native;
 
-  num get value native;
+  num? get value native;
 
-  set value(num value) native;
+  set value(num? value) native;
 
-  String get valueAsString native;
+  String? get valueAsString native;
 
-  set valueAsString(String value) native;
+  set valueAsString(String? value) native;
 
-  num get valueInSpecifiedUnits native;
+  num? get valueInSpecifiedUnits native;
 
-  set valueInSpecifiedUnits(num value) native;
+  set valueInSpecifiedUnits(num? value) native;
 
   void convertToSpecifiedUnits(int unitType) native;
 
@@ -202,9 +202,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Angle get animVal native;
+  Angle? get animVal native;
 
-  Angle get baseVal native;
+  Angle? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -218,11 +218,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get animVal native;
+  bool? get animVal native;
 
-  bool get baseVal native;
+  bool? get baseVal native;
 
-  set baseVal(bool value) native;
+  set baseVal(bool? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -236,11 +236,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get animVal native;
+  int? get animVal native;
 
-  int get baseVal native;
+  int? get baseVal native;
 
-  set baseVal(int value) native;
+  set baseVal(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -254,11 +254,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get animVal native;
+  int? get animVal native;
 
-  int get baseVal native;
+  int? get baseVal native;
 
-  set baseVal(int value) native;
+  set baseVal(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -272,9 +272,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Length get animVal native;
+  Length? get animVal native;
 
-  Length get baseVal native;
+  Length? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -288,9 +288,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  LengthList get animVal native;
+  LengthList? get animVal native;
 
-  LengthList get baseVal native;
+  LengthList? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -304,11 +304,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get animVal native;
+  num? get animVal native;
 
-  num get baseVal native;
+  num? get baseVal native;
 
-  set baseVal(num value) native;
+  set baseVal(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -322,9 +322,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  NumberList get animVal native;
+  NumberList? get animVal native;
 
-  NumberList get baseVal native;
+  NumberList? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -338,9 +338,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  PreserveAspectRatio get animVal native;
+  PreserveAspectRatio? get animVal native;
 
-  PreserveAspectRatio get baseVal native;
+  PreserveAspectRatio? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -354,9 +354,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Rect get animVal native;
+  Rect? get animVal native;
 
-  Rect get baseVal native;
+  Rect? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -370,11 +370,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  String get animVal native;
+  String? get animVal native;
 
-  String get baseVal native;
+  String? get baseVal native;
 
-  set baseVal(String value) native;
+  set baseVal(String? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -388,9 +388,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  TransformList get animVal native;
+  TransformList? get animVal native;
 
-  TransformList get baseVal native;
+  TransformList? get baseVal native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -414,7 +414,7 @@
    */
   AnimationElement.created() : super.created();
 
-  SvgElement get targetElement native;
+  SvgElement? get targetElement native;
 
   void beginElement() native;
 
@@ -432,9 +432,9 @@
 
   // From SVGTests
 
-  StringList get requiredExtensions native;
+  StringList? get requiredExtensions native;
 
-  StringList get systemLanguage native;
+  StringList? get systemLanguage native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -458,11 +458,11 @@
    */
   CircleElement.created() : super.created();
 
-  AnimatedLength get cx native;
+  AnimatedLength? get cx native;
 
-  AnimatedLength get cy native;
+  AnimatedLength? get cy native;
 
-  AnimatedLength get r native;
+  AnimatedLength? get r native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -486,7 +486,7 @@
    */
   ClipPathElement.created() : super.created();
 
-  AnimatedEnumeration get clipPathUnits native;
+  AnimatedEnumeration? get clipPathUnits native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -569,13 +569,13 @@
    */
   EllipseElement.created() : super.created();
 
-  AnimatedLength get cx native;
+  AnimatedLength? get cx native;
 
-  AnimatedLength get cy native;
+  AnimatedLength? get cy native;
 
-  AnimatedLength get rx native;
+  AnimatedLength? get rx native;
 
-  AnimatedLength get ry native;
+  AnimatedLength? get ry native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -621,23 +621,23 @@
 
   static const int SVG_FEBLEND_MODE_UNKNOWN = 0;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedString get in2 native;
+  AnimatedString? get in2 native;
 
-  AnimatedEnumeration get mode native;
+  AnimatedEnumeration? get mode native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -689,15 +689,15 @@
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -731,19 +731,19 @@
       SvgElement.isTagSupported('feComponentTransfer') &&
       (new SvgElement.tag('feComponentTransfer') is FEComponentTransferElement);
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -778,31 +778,31 @@
 
   static const int SVG_FECOMPOSITE_OPERATOR_XOR = 5;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedString get in2 native;
+  AnimatedString? get in2 native;
 
-  AnimatedNumber get k1 native;
+  AnimatedNumber? get k1 native;
 
-  AnimatedNumber get k2 native;
+  AnimatedNumber? get k2 native;
 
-  AnimatedNumber get k3 native;
+  AnimatedNumber? get k3 native;
 
-  AnimatedNumber get k4 native;
+  AnimatedNumber? get k4 native;
 
-  AnimatedEnumeration get operator native;
+  AnimatedEnumeration? get operator native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -844,41 +844,41 @@
 
   static const int SVG_EDGEMODE_WRAP = 2;
 
-  AnimatedNumber get bias native;
+  AnimatedNumber? get bias native;
 
-  AnimatedNumber get divisor native;
+  AnimatedNumber? get divisor native;
 
-  AnimatedEnumeration get edgeMode native;
+  AnimatedEnumeration? get edgeMode native;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedNumberList get kernelMatrix native;
+  AnimatedNumberList? get kernelMatrix native;
 
-  AnimatedNumber get kernelUnitLengthX native;
+  AnimatedNumber? get kernelUnitLengthX native;
 
-  AnimatedNumber get kernelUnitLengthY native;
+  AnimatedNumber? get kernelUnitLengthY native;
 
-  AnimatedInteger get orderX native;
+  AnimatedInteger? get orderX native;
 
-  AnimatedInteger get orderY native;
+  AnimatedInteger? get orderY native;
 
-  AnimatedBoolean get preserveAlpha native;
+  AnimatedBoolean? get preserveAlpha native;
 
-  AnimatedInteger get targetX native;
+  AnimatedInteger? get targetX native;
 
-  AnimatedInteger get targetY native;
+  AnimatedInteger? get targetY native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -912,27 +912,27 @@
       SvgElement.isTagSupported('feDiffuseLighting') &&
       (new SvgElement.tag('feDiffuseLighting') is FEDiffuseLightingElement);
 
-  AnimatedNumber get diffuseConstant native;
+  AnimatedNumber? get diffuseConstant native;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedNumber get kernelUnitLengthX native;
+  AnimatedNumber? get kernelUnitLengthX native;
 
-  AnimatedNumber get kernelUnitLengthY native;
+  AnimatedNumber? get kernelUnitLengthY native;
 
-  AnimatedNumber get surfaceScale native;
+  AnimatedNumber? get surfaceScale native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -976,27 +976,27 @@
 
   static const int SVG_CHANNEL_UNKNOWN = 0;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedString get in2 native;
+  AnimatedString? get in2 native;
 
-  AnimatedNumber get scale native;
+  AnimatedNumber? get scale native;
 
-  AnimatedEnumeration get xChannelSelector native;
+  AnimatedEnumeration? get xChannelSelector native;
 
-  AnimatedEnumeration get yChannelSelector native;
+  AnimatedEnumeration? get yChannelSelector native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1029,9 +1029,9 @@
       SvgElement.isTagSupported('feDistantLight') &&
       (new SvgElement.tag('feDistantLight') is FEDistantLightElement);
 
-  AnimatedNumber get azimuth native;
+  AnimatedNumber? get azimuth native;
 
-  AnimatedNumber get elevation native;
+  AnimatedNumber? get elevation native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1067,15 +1067,15 @@
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1233,25 +1233,25 @@
       SvgElement.isTagSupported('feGaussianBlur') &&
       (new SvgElement.tag('feGaussianBlur') is FEGaussianBlurElement);
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedNumber get stdDeviationX native;
+  AnimatedNumber? get stdDeviationX native;
 
-  AnimatedNumber get stdDeviationY native;
+  AnimatedNumber? get stdDeviationY native;
 
   void setStdDeviation(num stdDeviationX, num stdDeviationY) native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1285,23 +1285,23 @@
       SvgElement.isTagSupported('feImage') &&
       (new SvgElement.tag('feImage') is FEImageElement);
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1337,15 +1337,15 @@
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1378,7 +1378,7 @@
       SvgElement.isTagSupported('feMergeNode') &&
       (new SvgElement.tag('feMergeNode') is FEMergeNodeElement);
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1409,25 +1409,25 @@
 
   static const int SVG_MORPHOLOGY_OPERATOR_UNKNOWN = 0;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedEnumeration get operator native;
+  AnimatedEnumeration? get operator native;
 
-  AnimatedNumber get radiusX native;
+  AnimatedNumber? get radiusX native;
 
-  AnimatedNumber get radiusY native;
+  AnimatedNumber? get radiusY native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1461,23 +1461,23 @@
       SvgElement.isTagSupported('feOffset') &&
       (new SvgElement.tag('feOffset') is FEOffsetElement);
 
-  AnimatedNumber get dx native;
+  AnimatedNumber? get dx native;
 
-  AnimatedNumber get dy native;
+  AnimatedNumber? get dy native;
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1510,11 +1510,11 @@
       SvgElement.isTagSupported('fePointLight') &&
       (new SvgElement.tag('fePointLight') is FEPointLightElement);
 
-  AnimatedNumber get x native;
+  AnimatedNumber? get x native;
 
-  AnimatedNumber get y native;
+  AnimatedNumber? get y native;
 
-  AnimatedNumber get z native;
+  AnimatedNumber? get z native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1548,29 +1548,29 @@
       SvgElement.isTagSupported('feSpecularLighting') &&
       (new SvgElement.tag('feSpecularLighting') is FESpecularLightingElement);
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
-  AnimatedNumber get kernelUnitLengthX native;
+  AnimatedNumber? get kernelUnitLengthX native;
 
-  AnimatedNumber get kernelUnitLengthY native;
+  AnimatedNumber? get kernelUnitLengthY native;
 
-  AnimatedNumber get specularConstant native;
+  AnimatedNumber? get specularConstant native;
 
-  AnimatedNumber get specularExponent native;
+  AnimatedNumber? get specularExponent native;
 
-  AnimatedNumber get surfaceScale native;
+  AnimatedNumber? get surfaceScale native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1603,21 +1603,21 @@
       SvgElement.isTagSupported('feSpotLight') &&
       (new SvgElement.tag('feSpotLight') is FESpotLightElement);
 
-  AnimatedNumber get limitingConeAngle native;
+  AnimatedNumber? get limitingConeAngle native;
 
-  AnimatedNumber get pointsAtX native;
+  AnimatedNumber? get pointsAtX native;
 
-  AnimatedNumber get pointsAtY native;
+  AnimatedNumber? get pointsAtY native;
 
-  AnimatedNumber get pointsAtZ native;
+  AnimatedNumber? get pointsAtZ native;
 
-  AnimatedNumber get specularExponent native;
+  AnimatedNumber? get specularExponent native;
 
-  AnimatedNumber get x native;
+  AnimatedNumber? get x native;
 
-  AnimatedNumber get y native;
+  AnimatedNumber? get y native;
 
-  AnimatedNumber get z native;
+  AnimatedNumber? get z native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1651,19 +1651,19 @@
       SvgElement.isTagSupported('feTile') &&
       (new SvgElement.tag('feTile') is FETileElement);
 
-  AnimatedString get in1 native;
+  AnimatedString? get in1 native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1709,29 +1709,29 @@
 
   static const int SVG_TURBULENCE_TYPE_UNKNOWN = 0;
 
-  AnimatedNumber get baseFrequencyX native;
+  AnimatedNumber? get baseFrequencyX native;
 
-  AnimatedNumber get baseFrequencyY native;
+  AnimatedNumber? get baseFrequencyY native;
 
-  AnimatedInteger get numOctaves native;
+  AnimatedInteger? get numOctaves native;
 
-  AnimatedNumber get seed native;
+  AnimatedNumber? get seed native;
 
-  AnimatedEnumeration get stitchTiles native;
+  AnimatedEnumeration? get stitchTiles native;
 
-  AnimatedEnumeration get type native;
+  AnimatedEnumeration? get type native;
 
   // From SVGFilterPrimitiveStandardAttributes
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1764,21 +1764,21 @@
       SvgElement.isTagSupported('filter') &&
       (new SvgElement.tag('filter') is FilterElement);
 
-  AnimatedEnumeration get filterUnits native;
+  AnimatedEnumeration? get filterUnits native;
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedEnumeration get primitiveUnits native;
+  AnimatedEnumeration? get primitiveUnits native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1791,15 +1791,15 @@
     throw new UnsupportedError("Not supported");
   }
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedString get result native;
+  AnimatedString? get result native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1812,9 +1812,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1846,13 +1846,13 @@
       SvgElement.isTagSupported('foreignObject') &&
       (new SvgElement.tag('foreignObject') is ForeignObjectElement);
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1892,7 +1892,7 @@
    */
   GeometryElement.created() : super.created();
 
-  AnimatedNumber get pathLength native;
+  AnimatedNumber? get pathLength native;
 
   Point getPointAtLength(num distance) native;
 
@@ -1919,11 +1919,11 @@
    */
   GraphicsElement.created() : super.created();
 
-  SvgElement get farthestViewportElement native;
+  SvgElement? get farthestViewportElement native;
 
-  SvgElement get nearestViewportElement native;
+  SvgElement? get nearestViewportElement native;
 
-  AnimatedTransformList get transform native;
+  AnimatedTransformList? get transform native;
 
   Rect getBBox() native;
 
@@ -1935,9 +1935,9 @@
 
   // From SVGTests
 
-  StringList get requiredExtensions native;
+  StringList? get requiredExtensions native;
 
-  StringList get systemLanguage native;
+  StringList? get systemLanguage native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1960,25 +1960,25 @@
    */
   ImageElement.created() : super.created();
 
-  String get async native;
+  String? get async native;
 
-  set async(String value) native;
+  set async(String? value) native;
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   Future decode() => promiseToFuture(JS("", "#.decode()", this));
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2014,19 +2014,19 @@
 
   static const int SVG_LENGTHTYPE_UNKNOWN = 0;
 
-  int get unitType native;
+  int? get unitType native;
 
-  num get value native;
+  num? get value native;
 
-  set value(num value) native;
+  set value(num? value) native;
 
-  String get valueAsString native;
+  String? get valueAsString native;
 
-  set valueAsString(String value) native;
+  set valueAsString(String? value) native;
 
-  num get valueInSpecifiedUnits native;
+  num? get valueInSpecifiedUnits native;
 
-  set valueInSpecifiedUnits(num value) native;
+  set valueInSpecifiedUnits(num? value) native;
 
   void convertToSpecifiedUnits(int unitType) native;
 
@@ -2048,7 +2048,7 @@
 
   int get length => JS("int", "#.length", this);
 
-  int get numberOfItems native;
+  int? get numberOfItems native;
 
   Length operator [](int index) {
     if (JS("bool", "# >>> 0 !== # || # >= #", index, index, index, length))
@@ -2130,13 +2130,13 @@
    */
   LineElement.created() : super.created();
 
-  AnimatedLength get x1 native;
+  AnimatedLength? get x1 native;
 
-  AnimatedLength get x2 native;
+  AnimatedLength? get x2 native;
 
-  AnimatedLength get y1 native;
+  AnimatedLength? get y1 native;
 
-  AnimatedLength get y2 native;
+  AnimatedLength? get y2 native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2160,13 +2160,13 @@
    */
   LinearGradientElement.created() : super.created();
 
-  AnimatedLength get x1 native;
+  AnimatedLength? get x1 native;
 
-  AnimatedLength get x2 native;
+  AnimatedLength? get x2 native;
 
-  AnimatedLength get y1 native;
+  AnimatedLength? get y1 native;
 
-  AnimatedLength get y2 native;
+  AnimatedLength? get y2 native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2208,9 +2208,9 @@
 
   AnimatedLength get markerWidth native;
 
-  AnimatedAngle get orientAngle native;
+  AnimatedAngle? get orientAngle native;
 
-  AnimatedEnumeration get orientType native;
+  AnimatedEnumeration? get orientType native;
 
   AnimatedLength get refX native;
 
@@ -2222,9 +2222,9 @@
 
   // From SVGFitToViewBox
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2247,23 +2247,23 @@
    */
   MaskElement.created() : super.created();
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedEnumeration get maskContentUnits native;
+  AnimatedEnumeration? get maskContentUnits native;
 
-  AnimatedEnumeration get maskUnits native;
+  AnimatedEnumeration? get maskUnits native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   // From SVGTests
 
-  StringList get requiredExtensions native;
+  StringList? get requiredExtensions native;
 
-  StringList get systemLanguage native;
+  StringList? get systemLanguage native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2277,29 +2277,29 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get a native;
+  num? get a native;
 
-  set a(num value) native;
+  set a(num? value) native;
 
-  num get b native;
+  num? get b native;
 
-  set b(num value) native;
+  set b(num? value) native;
 
-  num get c native;
+  num? get c native;
 
-  set c(num value) native;
+  set c(num? value) native;
 
-  num get d native;
+  num? get d native;
 
-  set d(num value) native;
+  set d(num? value) native;
 
-  num get e native;
+  num? get e native;
 
-  set e(num value) native;
+  set e(num? value) native;
 
-  num get f native;
+  num? get f native;
 
-  set f(num value) native;
+  set f(num? value) native;
 
   Matrix flipX() native;
 
@@ -2353,9 +2353,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get value native;
+  num? get value native;
 
-  set value(num value) native;
+  set value(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2373,7 +2373,7 @@
 
   int get length => JS("int", "#.length", this);
 
-  int get numberOfItems native;
+  int? get numberOfItems native;
 
   Number operator [](int index) {
     if (JS("bool", "# >>> 0 !== # || # >= #", index, index, index, length))
@@ -2478,35 +2478,35 @@
    */
   PatternElement.created() : super.created();
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedEnumeration get patternContentUnits native;
+  AnimatedEnumeration? get patternContentUnits native;
 
-  AnimatedTransformList get patternTransform native;
+  AnimatedTransformList? get patternTransform native;
 
-  AnimatedEnumeration get patternUnits native;
+  AnimatedEnumeration? get patternUnits native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   // From SVGFitToViewBox
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 
   // From SVGTests
 
-  StringList get requiredExtensions native;
+  StringList? get requiredExtensions native;
 
-  StringList get systemLanguage native;
+  StringList? get systemLanguage native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2520,13 +2520,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 
   Point matrixTransform(Matrix matrix) native;
 }
@@ -2542,9 +2542,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get length native;
+  int? get length native;
 
-  int get numberOfItems native;
+  int? get numberOfItems native;
 
   void __setter__(int index, Point newItem) native;
 
@@ -2584,7 +2584,7 @@
    */
   PolygonElement.created() : super.created();
 
-  PointList get animatedPoints native;
+  PointList? get animatedPoints native;
 
   PointList get points native;
 }
@@ -2610,7 +2610,7 @@
    */
   PolylineElement.created() : super.created();
 
-  PointList get animatedPoints native;
+  PointList? get animatedPoints native;
 
   PointList get points native;
 }
@@ -2654,13 +2654,13 @@
 
   static const int SVG_PRESERVEASPECTRATIO_XMINYMIN = 2;
 
-  int get align native;
+  int? get align native;
 
-  set align(int value) native;
+  set align(int? value) native;
 
-  int get meetOrSlice native;
+  int? get meetOrSlice native;
 
-  set meetOrSlice(int value) native;
+  set meetOrSlice(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2684,17 +2684,17 @@
    */
   RadialGradientElement.created() : super.created();
 
-  AnimatedLength get cx native;
+  AnimatedLength? get cx native;
 
-  AnimatedLength get cy native;
+  AnimatedLength? get cy native;
 
-  AnimatedLength get fr native;
+  AnimatedLength? get fr native;
 
-  AnimatedLength get fx native;
+  AnimatedLength? get fx native;
 
-  AnimatedLength get fy native;
+  AnimatedLength? get fy native;
 
-  AnimatedLength get r native;
+  AnimatedLength? get r native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2708,21 +2708,21 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get height native;
+  num? get height native;
 
-  set height(num value) native;
+  set height(num? value) native;
 
-  num get width native;
+  num? get width native;
 
-  set width(num value) native;
+  set width(num? value) native;
 
-  num get x native;
+  num? get x native;
 
-  set x(num value) native;
+  set x(num? value) native;
 
-  num get y native;
+  num? get y native;
 
-  set y(num value) native;
+  set y(num? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2745,17 +2745,17 @@
    */
   RectElement.created() : super.created();
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedLength get rx native;
+  AnimatedLength? get rx native;
 
-  AnimatedLength get ry native;
+  AnimatedLength? get ry native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2779,13 +2779,13 @@
    */
   ScriptElement.created() : super.created();
 
-  String get type native;
+  String? get type native;
 
-  set type(String value) native;
+  set type(String? value) native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -2856,7 +2856,7 @@
 
   int get length => JS("int", "#.length", this);
 
-  int get numberOfItems native;
+  int? get numberOfItems native;
 
   String operator [](int index) {
     if (JS("bool", "# >>> 0 !== # || # >= #", index, index, index, length))
@@ -2937,23 +2937,23 @@
    */
   StyleElement.created() : super.created();
 
-  bool get disabled native;
+  bool? get disabled native;
 
-  set disabled(bool value) native;
+  set disabled(bool? value) native;
 
-  String get media native;
+  String? get media native;
 
-  set media(String value) native;
+  set media(String? value) native;
 
   StyleSheet? get sheet native;
 
   // Use implementation from Element.
-  // String get title native;
-  // void set title(String value) native;
+  // String? get title native;
+  // void set title(String? value) native;
 
-  String get type native;
+  String? get type native;
 
-  set type(String value) native;
+  set type(String? value) native;
 }
 // Copyright (c) 2011, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3023,14 +3023,14 @@
     children.addAll(value);
   }
 
-  String get outerHtml {
+  String? get outerHtml {
     final container = new DivElement();
     final SvgElement cloned = this.clone(true) as SvgElement;
     container.children.add(cloned);
     return container.innerHtml;
   }
 
-  String get innerHtml {
+  String? get innerHtml {
     final container = new DivElement();
     final SvgElement cloned = this.clone(true) as SvgElement;
     container.children.addAll(cloned.children);
@@ -3293,8 +3293,8 @@
   // void set style(CssStyleDeclaration value) native;
 
   // Use implementation from Element.
-  // int get tabIndex native;
-  // void set tabIndex(int value) native;
+  // int? get tabIndex native;
+  // void set tabIndex(int? value) native;
 
   SvgElement? get viewportElement native;
 
@@ -3458,19 +3458,19 @@
    */
   SvgSvgElement.created() : super.created();
 
-  num get currentScale native;
+  num? get currentScale native;
 
-  set currentScale(num value) native;
+  set currentScale(num? value) native;
 
-  Point get currentTranslate native;
+  Point? get currentTranslate native;
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   bool animationsPaused() native;
 
@@ -3533,15 +3533,15 @@
 
   // From SVGFitToViewBox
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 
   // From SVGZoomAndPan
 
-  int get zoomAndPan native;
+  int? get zoomAndPan native;
 
-  set zoomAndPan(int value) native;
+  set zoomAndPan(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3589,9 +3589,9 @@
 
   // From SVGFitToViewBox
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3625,9 +3625,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  StringList get requiredExtensions native;
+  StringList? get requiredExtensions native;
 
-  StringList get systemLanguage native;
+  StringList? get systemLanguage native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3653,9 +3653,9 @@
 
   static const int LENGTHADJUST_UNKNOWN = 0;
 
-  AnimatedEnumeration get lengthAdjust native;
+  AnimatedEnumeration? get lengthAdjust native;
 
-  AnimatedLength get textLength native;
+  AnimatedLength? get textLength native;
 
   int getCharNumAtPosition(Point point) native;
 
@@ -3726,15 +3726,15 @@
 
   static const int TEXTPATH_SPACINGTYPE_UNKNOWN = 0;
 
-  AnimatedEnumeration get method native;
+  AnimatedEnumeration? get method native;
 
-  AnimatedEnumeration get spacing native;
+  AnimatedEnumeration? get spacing native;
 
-  AnimatedLength get startOffset native;
+  AnimatedLength? get startOffset native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3754,15 +3754,15 @@
    */
   TextPositioningElement.created() : super.created();
 
-  AnimatedLengthList get dx native;
+  AnimatedLengthList? get dx native;
 
-  AnimatedLengthList get dy native;
+  AnimatedLengthList? get dy native;
 
-  AnimatedNumberList get rotate native;
+  AnimatedNumberList? get rotate native;
 
-  AnimatedLengthList get x native;
+  AnimatedLengthList? get x native;
 
-  AnimatedLengthList get y native;
+  AnimatedLengthList? get y native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3811,11 +3811,11 @@
 
   static const int SVG_TRANSFORM_UNKNOWN = 0;
 
-  num get angle native;
+  num? get angle native;
 
-  Matrix get matrix native;
+  Matrix? get matrix native;
 
-  int get type native;
+  int? get type native;
 
   void setMatrix(Matrix matrix) native;
 
@@ -3845,7 +3845,7 @@
 
   int get length => JS("int", "#.length", this);
 
-  int get numberOfItems native;
+  int? get numberOfItems native;
 
   Transform operator [](int index) {
     if (JS("bool", "# >>> 0 !== # || # >= #", index, index, index, length))
@@ -3940,7 +3940,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3963,17 +3963,17 @@
    */
   UseElement.created() : super.created();
 
-  AnimatedLength get height native;
+  AnimatedLength? get height native;
 
-  AnimatedLength get width native;
+  AnimatedLength? get width native;
 
-  AnimatedLength get x native;
+  AnimatedLength? get x native;
 
-  AnimatedLength get y native;
+  AnimatedLength? get y native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -3998,15 +3998,15 @@
 
   // From SVGFitToViewBox
 
-  AnimatedPreserveAspectRatio get preserveAspectRatio native;
+  AnimatedPreserveAspectRatio? get preserveAspectRatio native;
 
-  AnimatedRect get viewBox native;
+  AnimatedRect? get viewBox native;
 
   // From SVGZoomAndPan
 
-  int get zoomAndPan native;
+  int? get zoomAndPan native;
 
-  set zoomAndPan(int value) native;
+  set zoomAndPan(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -4025,9 +4025,9 @@
 
   static const int SVG_ZOOMANDPAN_UNKNOWN = 0;
 
-  int get zoomAndPan native;
+  int? get zoomAndPan native;
 
-  set zoomAndPan(int value) native;
+  set zoomAndPan(int? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -4055,15 +4055,15 @@
 
   static const int SVG_SPREADMETHOD_UNKNOWN = 0;
 
-  AnimatedTransformList get gradientTransform native;
+  AnimatedTransformList? get gradientTransform native;
 
-  AnimatedEnumeration get gradientUnits native;
+  AnimatedEnumeration? get gradientUnits native;
 
-  AnimatedEnumeration get spreadMethod native;
+  AnimatedEnumeration? get spreadMethod native;
 
   // From SVGURIReference
 
-  AnimatedString get href native;
+  AnimatedString? get href native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
diff --git a/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart b/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart
index 146e158..da12ab3 100644
--- a/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart
+++ b/sdk/lib/web_audio/dart2js/web_audio_dart2js.dart
@@ -50,23 +50,23 @@
   static AnalyserNode _create_2(context) =>
       JS('AnalyserNode', 'new AnalyserNode(#)', context);
 
-  int get fftSize native;
+  int? get fftSize native;
 
-  set fftSize(int value) native;
+  set fftSize(int? value) native;
 
-  int get frequencyBinCount native;
+  int? get frequencyBinCount native;
 
-  num get maxDecibels native;
+  num? get maxDecibels native;
 
-  set maxDecibels(num value) native;
+  set maxDecibels(num? value) native;
 
-  num get minDecibels native;
+  num? get minDecibels native;
 
-  set minDecibels(num value) native;
+  set minDecibels(num? value) native;
 
-  num get smoothingTimeConstant native;
+  num? get smoothingTimeConstant native;
 
-  set smoothingTimeConstant(num value) native;
+  set smoothingTimeConstant(num? value) native;
 
   void getByteFrequencyData(Uint8List array) native;
 
@@ -94,13 +94,13 @@
   static AudioBuffer _create_1(options) =>
       JS('AudioBuffer', 'new AudioBuffer(#)', options);
 
-  num get duration native;
+  num? get duration native;
 
-  int get length native;
+  int? get length native;
 
-  int get numberOfChannels native;
+  int? get numberOfChannels native;
 
-  num get sampleRate native;
+  num? get sampleRate native;
 
   void copyFromChannel(Float32List destination, int channelNumber,
       [int? startInChannel]) native;
@@ -142,21 +142,21 @@
 
   set buffer(AudioBuffer? value) native;
 
-  AudioParam get detune native;
+  AudioParam? get detune native;
 
-  bool get loop native;
+  bool? get loop native;
 
-  set loop(bool value) native;
+  set loop(bool? value) native;
 
-  num get loopEnd native;
+  num? get loopEnd native;
 
-  set loopEnd(num value) native;
+  set loopEnd(num? value) native;
 
-  num get loopStart native;
+  num? get loopStart native;
 
-  set loopStart(num value) native;
+  set loopStart(num? value) native;
 
-  AudioParam get playbackRate native;
+  AudioParam? get playbackRate native;
 
   void start([num? when, num? grainOffset, num? grainDuration]) native;
 }
@@ -177,7 +177,7 @@
   static bool get supported =>
       JS('bool', '!!(window.AudioContext || window.webkitAudioContext)');
 
-  num get baseLatency native;
+  num? get baseLatency native;
 
   Future close() => promiseToFuture(JS("", "#.close()", this));
 
@@ -261,7 +261,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get maxChannelCount native;
+  int? get maxChannelCount native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -274,23 +274,23 @@
     throw new UnsupportedError("Not supported");
   }
 
-  AudioParam get forwardX native;
+  AudioParam? get forwardX native;
 
-  AudioParam get forwardY native;
+  AudioParam? get forwardY native;
 
-  AudioParam get forwardZ native;
+  AudioParam? get forwardZ native;
 
-  AudioParam get positionX native;
+  AudioParam? get positionX native;
 
-  AudioParam get positionY native;
+  AudioParam? get positionY native;
 
-  AudioParam get positionZ native;
+  AudioParam? get positionZ native;
 
-  AudioParam get upX native;
+  AudioParam? get upX native;
 
-  AudioParam get upY native;
+  AudioParam? get upY native;
 
-  AudioParam get upZ native;
+  AudioParam? get upZ native;
 
   void setOrientation(num x, num y, num z, num xUp, num yUp, num zUp) native;
 
@@ -307,23 +307,23 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get channelCount native;
+  int? get channelCount native;
 
-  set channelCount(int value) native;
+  set channelCount(int? value) native;
 
-  String get channelCountMode native;
+  String? get channelCountMode native;
 
-  set channelCountMode(String value) native;
+  set channelCountMode(String? value) native;
 
-  String get channelInterpretation native;
+  String? get channelInterpretation native;
 
-  set channelInterpretation(String value) native;
+  set channelInterpretation(String? value) native;
 
-  BaseAudioContext get context native;
+  BaseAudioContext? get context native;
 
-  int get numberOfInputs native;
+  int? get numberOfInputs native;
 
-  int get numberOfOutputs native;
+  int? get numberOfOutputs native;
 
   @JSName('connect')
   AudioNode _connect(destination, [int? output, int? input]) native;
@@ -349,15 +349,15 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get defaultValue native;
+  num? get defaultValue native;
 
-  num get maxValue native;
+  num? get maxValue native;
 
-  num get minValue native;
+  num? get minValue native;
 
-  num get value native;
+  num? get value native;
 
-  set value(num value) native;
+  set value(num? value) native;
 
   AudioParam cancelAndHoldAtTime(num startTime) native;
 
@@ -463,11 +463,11 @@
       type,
       eventInitDict);
 
-  AudioBuffer get inputBuffer native;
+  AudioBuffer? get inputBuffer native;
 
-  AudioBuffer get outputBuffer native;
+  AudioBuffer? get outputBuffer native;
 
-  num get playbackTime native;
+  num? get playbackTime native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -501,17 +501,17 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get enabled native;
+  bool? get enabled native;
 
-  set enabled(bool value) native;
+  set enabled(bool? value) native;
 
-  String get id native;
+  String? get id native;
 
-  String get kind native;
+  String? get kind native;
 
-  String get label native;
+  String? get label native;
 
-  String get language native;
+  String? get language native;
 
   SourceBuffer? get sourceBuffer native;
 }
@@ -529,7 +529,7 @@
   static const EventStreamProvider<Event> changeEvent =
       const EventStreamProvider<Event>('change');
 
-  int get length native;
+  int? get length native;
 
   AudioTrack __getter__(int index) native;
 
@@ -548,9 +548,9 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get currentTime native;
+  num? get currentTime native;
 
-  num get sampleRate native;
+  num? get sampleRate native;
 
   void registerProcessor(String name, Object processorConstructor) native;
 }
@@ -582,7 +582,7 @@
   static AudioWorkletNode _create_2(context, name) =>
       JS('AudioWorkletNode', 'new AudioWorkletNode(#,#)', context, name);
 
-  AudioParamMap get parameters native;
+  AudioParamMap? get parameters native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -606,15 +606,15 @@
     throw new UnsupportedError("Not supported");
   }
 
-  num get currentTime native;
+  num? get currentTime native;
 
-  AudioDestinationNode get destination native;
+  AudioDestinationNode? get destination native;
 
-  AudioListener get listener native;
+  AudioListener? get listener native;
 
-  num get sampleRate native;
+  num? get sampleRate native;
 
-  String get state native;
+  String? get state native;
 
   AnalyserNode createAnalyser() native;
 
@@ -710,17 +710,17 @@
   static BiquadFilterNode _create_2(context) =>
       JS('BiquadFilterNode', 'new BiquadFilterNode(#)', context);
 
-  AudioParam get Q native;
+  AudioParam? get Q native;
 
-  AudioParam get detune native;
+  AudioParam? get detune native;
 
-  AudioParam get frequency native;
+  AudioParam? get frequency native;
 
-  AudioParam get gain native;
+  AudioParam? get gain native;
 
-  String get type native;
+  String? get type native;
 
-  set type(String value) native;
+  set type(String? value) native;
 
   void getFrequencyResponse(Float32List frequencyHz, Float32List magResponse,
       Float32List phaseResponse) native;
@@ -794,7 +794,7 @@
   static ConstantSourceNode _create_2(context) =>
       JS('ConstantSourceNode', 'new ConstantSourceNode(#)', context);
 
-  AudioParam get offset native;
+  AudioParam? get offset native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -823,9 +823,9 @@
 
   set buffer(AudioBuffer? value) native;
 
-  bool get normalize native;
+  bool? get normalize native;
 
-  set normalize(bool value) native;
+  set normalize(bool? value) native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -850,7 +850,7 @@
   static DelayNode _create_2(context) =>
       JS('DelayNode', 'new DelayNode(#)', context);
 
-  AudioParam get delayTime native;
+  AudioParam? get delayTime native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -878,17 +878,17 @@
   static DynamicsCompressorNode _create_2(context) =>
       JS('DynamicsCompressorNode', 'new DynamicsCompressorNode(#)', context);
 
-  AudioParam get attack native;
+  AudioParam? get attack native;
 
-  AudioParam get knee native;
+  AudioParam? get knee native;
 
-  AudioParam get ratio native;
+  AudioParam? get ratio native;
 
-  num get reduction native;
+  num? get reduction native;
 
-  AudioParam get release native;
+  AudioParam? get release native;
 
-  AudioParam get threshold native;
+  AudioParam? get threshold native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -913,7 +913,7 @@
   static GainNode _create_2(context) =>
       JS('GainNode', 'new GainNode(#)', context);
 
-  AudioParam get gain native;
+  AudioParam? get gain native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -957,7 +957,7 @@
       context,
       options);
 
-  MediaElement get mediaElement native;
+  MediaElement? get mediaElement native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -988,7 +988,7 @@
       'new MediaStreamAudioDestinationNode(#)',
       context);
 
-  MediaStream get stream native;
+  MediaStream? get stream native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1011,7 +1011,7 @@
       context,
       options);
 
-  MediaStream get mediaStream native;
+  MediaStream? get mediaStream native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1034,7 +1034,7 @@
       type,
       eventInitDict);
 
-  AudioBuffer get renderedBuffer native;
+  AudioBuffer? get renderedBuffer native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1073,7 +1073,7 @@
       'new OfflineAudioContext(#)',
       numberOfChannels_OR_options);
 
-  int get length native;
+  int? get length native;
 
   Future<AudioBuffer> startRendering() =>
       promiseToFuture<AudioBuffer>(JS("", "#.startRendering()", this));
@@ -1105,13 +1105,13 @@
   static OscillatorNode _create_2(context) =>
       JS('OscillatorNode', 'new OscillatorNode(#)', context);
 
-  AudioParam get detune native;
+  AudioParam? get detune native;
 
-  AudioParam get frequency native;
+  AudioParam? get frequency native;
 
-  String get type native;
+  String? get type native;
 
-  set type(String value) native;
+  set type(String? value) native;
 
   void setPeriodicWave(PeriodicWave periodicWave) native;
 }
@@ -1138,49 +1138,49 @@
   static PannerNode _create_2(context) =>
       JS('PannerNode', 'new PannerNode(#)', context);
 
-  num get coneInnerAngle native;
+  num? get coneInnerAngle native;
 
-  set coneInnerAngle(num value) native;
+  set coneInnerAngle(num? value) native;
 
-  num get coneOuterAngle native;
+  num? get coneOuterAngle native;
 
-  set coneOuterAngle(num value) native;
+  set coneOuterAngle(num? value) native;
 
-  num get coneOuterGain native;
+  num? get coneOuterGain native;
 
-  set coneOuterGain(num value) native;
+  set coneOuterGain(num? value) native;
 
-  String get distanceModel native;
+  String? get distanceModel native;
 
-  set distanceModel(String value) native;
+  set distanceModel(String? value) native;
 
-  num get maxDistance native;
+  num? get maxDistance native;
 
-  set maxDistance(num value) native;
+  set maxDistance(num? value) native;
 
-  AudioParam get orientationX native;
+  AudioParam? get orientationX native;
 
-  AudioParam get orientationY native;
+  AudioParam? get orientationY native;
 
-  AudioParam get orientationZ native;
+  AudioParam? get orientationZ native;
 
-  String get panningModel native;
+  String? get panningModel native;
 
-  set panningModel(String value) native;
+  set panningModel(String? value) native;
 
-  AudioParam get positionX native;
+  AudioParam? get positionX native;
 
-  AudioParam get positionY native;
+  AudioParam? get positionY native;
 
-  AudioParam get positionZ native;
+  AudioParam? get positionZ native;
 
-  num get refDistance native;
+  num? get refDistance native;
 
-  set refDistance(num value) native;
+  set refDistance(num? value) native;
 
-  num get rolloffFactor native;
+  num? get rolloffFactor native;
 
-  set rolloffFactor(num value) native;
+  set rolloffFactor(num? value) native;
 
   void setOrientation(num x, num y, num z) native;
 
@@ -1229,7 +1229,7 @@
   static const EventStreamProvider<AudioProcessingEvent> audioProcessEvent =
       const EventStreamProvider<AudioProcessingEvent>('audioprocess');
 
-  int get bufferSize native;
+  int? get bufferSize native;
 
   void setEventListener(EventListener eventListener) native;
 
@@ -1267,7 +1267,7 @@
   static StereoPannerNode _create_2(context) =>
       JS('StereoPannerNode', 'new StereoPannerNode(#)', context);
 
-  AudioParam get pan native;
+  AudioParam? get pan native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -1296,7 +1296,7 @@
 
   set curve(Float32List? value) native;
 
-  String get oversample native;
+  String? get oversample native;
 
-  set oversample(String value) native;
+  set oversample(String? value) native;
 }
diff --git a/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart b/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
index 53671df..072cfae 100644
--- a/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
+++ b/sdk/lib/web_gl/dart2js/web_gl_dart2js.dart
@@ -89,7 +89,7 @@
   CanvasElement get canvas native;
 
   @JSName('canvas')
-  OffscreenCanvas get offscreenCanvas native;
+  OffscreenCanvas? get offscreenCanvas native;
 }
 
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
@@ -727,9 +727,9 @@
 
   // From WebGLRenderingContextBase
 
-  int get drawingBufferHeight native;
+  int? get drawingBufferHeight native;
 
-  int get drawingBufferWidth native;
+  int? get drawingBufferWidth native;
 
   void activeTexture(int texture) native;
 
@@ -1363,7 +1363,7 @@
     throw new UnsupportedError("Not supported");
   }
 
-  Canvas get canvas native;
+  Canvas? get canvas native;
 
   // From WebGL2RenderingContextBase
 
@@ -2304,9 +2304,9 @@
 
   // From WebGLRenderingContextBase
 
-  int get drawingBufferHeight native;
+  int? get drawingBufferHeight native;
 
-  int get drawingBufferWidth native;
+  int? get drawingBufferWidth native;
 
   void activeTexture(int texture) native;
 
@@ -2890,13 +2890,13 @@
     throw new UnsupportedError("Not supported");
   }
 
-  bool get lastUploadedVideoFrameWasSkipped native;
+  bool? get lastUploadedVideoFrameWasSkipped native;
 
-  int get lastUploadedVideoHeight native;
+  int? get lastUploadedVideoHeight native;
 
-  num get lastUploadedVideoTimestamp native;
+  num? get lastUploadedVideoTimestamp native;
 
-  int get lastUploadedVideoWidth native;
+  int? get lastUploadedVideoWidth native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
diff --git a/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart b/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart
index f97b55e..4d7f936 100644
--- a/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart
+++ b/sdk/lib/web_sql/dart2js/web_sql_dart2js.dart
@@ -79,7 +79,7 @@
   /// Checks if this type is supported on the current platform.
   static bool get supported => JS('bool', '!!(window.openDatabase)');
 
-  String get version native;
+  String? get version native;
 
   @JSName('changeVersion')
   /**
@@ -185,9 +185,9 @@
 
   static const int VERSION_ERR = 2;
 
-  int get code native;
+  int? get code native;
 
-  String get message native;
+  String? get message native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
@@ -200,11 +200,11 @@
     throw new UnsupportedError("Not supported");
   }
 
-  int get insertId native;
+  int? get insertId native;
 
-  SqlResultSetRowList get rows native;
+  SqlResultSetRowList? get rows native;
 
-  int get rowsAffected native;
+  int? get rowsAffected native;
 }
 // Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
 // for details. All rights reserved. Use of this source code is governed by a
diff --git a/sdk_args.gni b/sdk_args.gni
index 06dc3e8..2776011 100644
--- a/sdk_args.gni
+++ b/sdk_args.gni
@@ -34,6 +34,7 @@
                          [
                            "$_dart_root/tools/VERSION",
                            "$_dart_root/tools/utils.py",
+                           "$default_git_folder/logs/HEAD",
                          ])
 } else {
   sdk_hash = "0000000000"
diff --git a/tests/co19/co19-co19.status b/tests/co19/co19-co19.status
index 2176473..7d0157f 100644
--- a/tests/co19/co19-co19.status
+++ b/tests/co19/co19-co19.status
@@ -24,27 +24,7 @@
 Language/Reference/Operator_Precedence/precedence_12_Shift_t04: Skip # Triple shift is not implemented yet
 Language/Reference/Operator_Precedence/precedence_t05: Skip # Triple shift is not implemented yet
 Language/Statements/Assert/*: Skip # Not migrated to NNBD
-Language/Statements/Blocks/*: Skip # Not migrated to NNBD
-Language/Statements/Break/*: Skip # Not migrated to NNBD
-Language/Statements/Continue/*: Skip # Not migrated to NNBD
-Language/Statements/Do/*: Skip # Not migrated to NNBD
-Language/Statements/Expression_Statements/*: Skip # Not migrated to NNBD
-Language/Statements/For/*: Skip # Not migrated to NNBD
-Language/Statements/For/Asynchronous_For_in/*: Skip # Not migrated to NNBD
-Language/Statements/For/For_Loop/*: Skip # Not migrated to NNBD
-Language/Statements/For/For_in/*: Skip # Not migrated to NNBD
-Language/Statements/If/*: Skip # Not migrated to NNBD
-Language/Statements/Labels/*: Skip # Not migrated to NNBD
-Language/Statements/Local_Function_Declaration/*: Skip # Not migrated to NNBD
-Language/Statements/Local_Variable_Declaration/*: Skip # Not migrated to NNBD
-Language/Statements/Rethrow/*: Skip # Not migrated to NNBD
-Language/Statements/Return/*: Skip # Not migrated to NNBD
-Language/Statements/Switch/*: Skip # Not migrated to NNBD
-Language/Statements/Try/*: Skip # Not migrated to NNBD
-Language/Statements/While/*: Skip # Not migrated to NNBD
-Language/Statements/Yield_and_Yield_Each/*: Skip # Not migrated to NNBD
-Language/Statements/Yield_and_Yield_Each/Yield/*: Skip # Not migrated to NNBD
-Language/Statements/Yield_and_Yield_Each/Yield_Each/*: Skip # Not migrated to NNBD
+Language/Statements/Expression_Statements/syntax_t06: Skip # Type aliases are not fully implemented
 Language/Types/Dynamic_Type_System/*: Skip # Not migrated to NNBD
 Language/Types/Function_Types/*: Skip # Not migrated to NNBD
 Language/Types/Interface_Types/*: Skip # Not migrated to NNBD
diff --git a/tests/corelib/dynamic_nosuchmethod_test.dart b/tests/corelib/dynamic_nosuchmethod_test.dart
index 2577b48..14fce84 100644
--- a/tests/corelib/dynamic_nosuchmethod_test.dart
+++ b/tests/corelib/dynamic_nosuchmethod_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 // Test that noSuchMethod calls behave as expected for dynamic object invocations.
diff --git a/tests/corelib/list_concurrent_modify_test.dart b/tests/corelib/list_concurrent_modify_test.dart
index df62919..9e8d338 100644
--- a/tests/corelib/list_concurrent_modify_test.dart
+++ b/tests/corelib/list_concurrent_modify_test.dart
@@ -34,8 +34,8 @@
   // Operations that change the length cause ConcurrentModificationError.
   void testModification(action()) {
     testIterator(int when) {
-      list.length = 4;
-      list.setAll(0, [0, 1, 2, 3]);
+      list.clear();
+      list.addAll([0, 1, 2, 3]);
       Expect.throws(() {
         for (var element in list) {
           if (element == when) action();
@@ -44,8 +44,8 @@
     }
 
     testForEach(int when) {
-      list.length = 4;
-      list.setAll(0, [0, 1, 2, 3]);
+      list.clear();
+      list.addAll([0, 1, 2, 3]);
       Expect.throws(() {
         list.forEach((var element) {
           if (element == when) action();
@@ -84,7 +84,10 @@
 }
 
 class MyList<E> extends ListBase<E> {
-  List<E> _source;
+  // TODO(42496): Use a nullable list because insert() is implemented in terms
+  // of length=. Change this back to `E` and remove the `as E` below when that
+  // issue is fixed.
+  List<E?> _source;
   MyList(this._source);
   int get length => _source.length;
   void set length(int length) {
@@ -95,7 +98,7 @@
     _source.add(element);
   }
 
-  E operator [](int index) => _source[index];
+  E operator [](int index) => _source[index] as E;
   void operator []=(int index, E value) {
     _source[index] = value;
   }
diff --git a/tests/corelib/list_removeat_test.dart b/tests/corelib/list_removeat_test.dart
index a1657c2..1cffceb 100644
--- a/tests/corelib/list_removeat_test.dart
+++ b/tests/corelib/list_removeat_test.dart
@@ -26,8 +26,8 @@
   Expect.throwsRangeError(() => l1.removeAt(-1), "negative");
   Expect.throwsRangeError(() => l1.removeAt(5), "too large");
   Expect.throws(() => l1.removeAt(null),
-      // With --null-safety a TypeError is thrown
-      // With --no-null-safety an ArgumentError is thrown
+      // With sound null safety a TypeError is thrown.
+      // Without sound null safety an ArgumentError is thrown.
       (e) => e is TypeError || e is ArgumentError, "is null");
 
   Expect.equals(2, l1.removeAt(2), "l1-remove2");
diff --git a/tests/corelib/list_test.dart b/tests/corelib/list_test.dart
index a6b746a..c38d6d1 100644
--- a/tests/corelib/list_test.dart
+++ b/tests/corelib/list_test.dart
@@ -546,7 +546,10 @@
 }
 
 class MyList<E> extends ListBase<E> {
-  List<E> _source;
+  // TODO(42496): Use a nullable list because insert() is implemented in terms
+  // of length=. Change this back to `E` and remove the `as E` below when that
+  // issue is fixed.
+  List<E?> _source;
   MyList(this._source);
   int get length => _source.length;
   void set length(int length) {
@@ -557,7 +560,7 @@
     _source.add(element);
   }
 
-  E operator [](int index) => _source[index];
+  E operator [](int index) => _source[index] as E;
   void operator []=(int index, E value) {
     _source[index] = value;
   }
diff --git a/tests/corelib/null_nosuchmethod_test.dart b/tests/corelib/null_nosuchmethod_test.dart
index 37ff417..4edf9cf 100644
--- a/tests/corelib/null_nosuchmethod_test.dart
+++ b/tests/corelib/null_nosuchmethod_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 // Test that Null's noSuchMethod can be closurized and called directly.
diff --git a/tests/corelib_2/dynamic_nosuchmethod_test.dart b/tests/corelib_2/dynamic_nosuchmethod_test.dart
index 2577b48..14fce84 100644
--- a/tests/corelib_2/dynamic_nosuchmethod_test.dart
+++ b/tests/corelib_2/dynamic_nosuchmethod_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 // Test that noSuchMethod calls behave as expected for dynamic object invocations.
diff --git a/tests/corelib_2/null_nosuchmethod_test.dart b/tests/corelib_2/null_nosuchmethod_test.dart
index 37ff417..4edf9cf 100644
--- a/tests/corelib_2/null_nosuchmethod_test.dart
+++ b/tests/corelib_2/null_nosuchmethod_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 // Test that Null's noSuchMethod can be closurized and called directly.
diff --git a/tests/dart2js/42531_test.dart b/tests/dart2js/42531_test.dart
new file mode 100644
index 0000000..7bc9b58
--- /dev/null
+++ b/tests/dart2js/42531_test.dart
@@ -0,0 +1,46 @@
+// 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 'package:expect/expect.dart';
+
+// Regression test for badly named generator body.
+
+Future<void> goo(Future Function() f) async {
+  Expect.equals(102, (await f()).keys.single);
+  Expect.equals(104, (await f()).keys.single);
+}
+
+Future<T> identity<T>(T x) async => x;
+
+extension Gloop<T> on Map<T, List<T>> {
+  // An async method using a 'complex' generator type `Map<T, List<T>>`.  This
+  // requires a separated entry and body, which requires a name, and the name
+  // must be legal JavaScript.
+  Future<Map<T, List<T>>> foo(int x) async {
+    var result = await identity({(x += this.length) as T: <T>[]});
+    return result;
+  }
+
+  Future<int> bar(int x) async {
+    // An async closure using a 'complex' generator type `Map<T, Set<T>>`.  This
+    // requires a separated entry and body, which requires a name, and the name
+    // must be legal JavaScript.
+    await goo(() async => {(x += this.length) as T: <T>{}});
+    return x;
+  }
+}
+
+main() async {
+  // Test method.
+  Map<int, List<int>> o1 = {1: [], 2: []};
+  var o2 = await o1.foo(100);
+  var o3 = await o2.foo(100);
+  Expect.equals('{102: []}', '$o2');
+  Expect.equals('{101: []}', '$o3');
+
+  // Test closure.
+  Map<int, List<int>> o = {1: [], 2: []};
+  int x = await o.bar(100);
+  Expect.equals(104, x);
+}
diff --git a/tests/dart2js/conditional_rewrite_test.dart b/tests/dart2js/conditional_rewrite_test.dart
index 57b0a42..12a1620 100644
--- a/tests/dart2js/conditional_rewrite_test.dart
+++ b/tests/dart2js/conditional_rewrite_test.dart
@@ -48,10 +48,10 @@
 }
 
 bool get isConditionCheckDisabled {
-  bool b = null;
+  bool? b = null;
   for (int i = 0; i < 3; i++) {
     try {
-      b = !b;
+      b = !(b as dynamic);
     } catch (e) {
       return false;
     }
diff --git a/tests/dart2js/conditional_send_test.dart b/tests/dart2js/conditional_send_test.dart
index d1a27c1..dd6d6b7 100644
--- a/tests/dart2js/conditional_send_test.dart
+++ b/tests/dart2js/conditional_send_test.dart
@@ -10,12 +10,12 @@
 confuse(x) => x;
 
 class A {
-  int x;
+  int? x;
   m() => "a";
 }
 
 main(args) {
   var a = confuse(true) ? null : new A();
   a?.x = 3;
-  Expect.throws(() => a.m());
+  Expect.throws(() => a!.m());
 }
diff --git a/tests/dart2js/consistent_add_error_test.dart b/tests/dart2js/consistent_add_error_test.dart
index fd5840f..4559ce4 100644
--- a/tests/dart2js/consistent_add_error_test.dart
+++ b/tests/dart2js/consistent_add_error_test.dart
@@ -11,10 +11,10 @@
 confuse(x) => x;
 
 void check2(String name, name1, f1, name2, f2) {
-  Error trap(part, f) {
+  Error? trap(part, f) {
     try {
       f();
-    } catch (e) {
+    } on Error catch (e) {
       return e;
     }
     Expect.fail('should throw: $name.$part');
@@ -50,7 +50,7 @@
   }
 
   static f4() {
-    return (confuse(1) as int) + null;
+    return (confuse(1) as int) + (null as dynamic);
   }
 
   static f5() {
@@ -60,11 +60,11 @@
 
   static f6() {
     var a = confuse(true) ? 1 : 2; // Small int with unknown value.
-    return a + null;
+    return a + (null as dynamic);
   }
 
   static f7() {
-    return 1 + null;
+    return 1 + (null as dynamic);
   }
 
   static test() {
@@ -78,7 +78,7 @@
   }
 
   static f2() {
-    return confuse('a') + null;
+    return confuse('a') + (null as dynamic);
   }
 
   static f3() {
@@ -86,7 +86,7 @@
   }
 
   static f4() {
-    return (confuse('a') as String) + null;
+    return (confuse('a') as String) + (null as dynamic);
   }
 
   static f5() {
@@ -96,11 +96,11 @@
 
   static f6() {
     var a = confuse(true) ? 'a' : 'bc';
-    return a + null;
+    return a + (null as dynamic);
   }
 
   static f7() {
-    return 'a' + null;
+    return 'a' + (null as dynamic);
   }
 
   static test() {
diff --git a/tests/dart2js/consistent_codeUnitAt_error_test.dart b/tests/dart2js/consistent_codeUnitAt_error_test.dart
index 536279b..b90a68a 100644
--- a/tests/dart2js/consistent_codeUnitAt_error_test.dart
+++ b/tests/dart2js/consistent_codeUnitAt_error_test.dart
@@ -12,10 +12,10 @@
 confuse(x) => x;
 
 void check2(String name, name1, f1, name2, f2) {
-  Error trap(part, f) {
+  Error? trap(part, f) {
     try {
       f();
-    } catch (e) {
+    } on Error catch (e) {
       return e;
     }
     Expect.fail('should throw: $name.$part');
diff --git a/tests/dart2js/consistent_null_add_error_test.dart b/tests/dart2js/consistent_null_add_error_test.dart
index 64ad07d..c1a57f0 100644
--- a/tests/dart2js/consistent_null_add_error_test.dart
+++ b/tests/dart2js/consistent_null_add_error_test.dart
@@ -13,10 +13,10 @@
 confuse(x) => x;
 
 void check2(String name, name1, f1, name2, f2) {
-  Error trap(part, f) {
+  Error? trap(part, f) {
     try {
       f();
-    } catch (e) {
+    } on Error catch (e) {
       return e;
     }
     Expect.fail('should throw: $name.$part');
diff --git a/tests/dart2js/consistent_subtract_error_test.dart b/tests/dart2js/consistent_subtract_error_test.dart
index a847937..a34f50f 100644
--- a/tests/dart2js/consistent_subtract_error_test.dart
+++ b/tests/dart2js/consistent_subtract_error_test.dart
@@ -13,10 +13,10 @@
 confuse(x) => x;
 
 void check2(String name, name1, f1, name2, f2) {
-  Error trap(part, f) {
+  Error? trap(part, f) {
     try {
       f();
-    } catch (e) {
+    } on Error catch (e) {
       return e;
     }
     Expect.fail('should throw: $name.$part');
@@ -52,7 +52,7 @@
   }
 
   static f4() {
-    return (confuse(1) as int) - null;
+    return (confuse(1) as int) - (null as dynamic);
   }
 
   static f5() {
@@ -62,11 +62,11 @@
 
   static f6() {
     var a = confuse(true) ? 1 : 2; // Small int with unknown value.
-    return a - null;
+    return a - (null as dynamic);
   }
 
   static f7() {
-    return 1 - null;
+    return 1 - (null as dynamic);
   }
 
   static test() {
diff --git a/tests/dart2js/constant_folding_test.dart b/tests/dart2js/constant_folding_test.dart
index b9b050b..97e2a4f 100644
--- a/tests/dart2js/constant_folding_test.dart
+++ b/tests/dart2js/constant_folding_test.dart
@@ -928,7 +928,7 @@
 ///   constant evaluation results in `0` or `0.0` and the other results in
 ///   `-0.0`. Therefore, we additionally check that both values have the same
 ///   sign in this case.
-void jsEquals(expected, actual, [String reason = null]) {
+void jsEquals(expected, actual, [String reason = ""]) {
   if (expected is num && actual is num) {
     if (expected.isNaN && actual.isNaN) return;
   }
@@ -941,7 +941,7 @@
         actual.isNegative,
         (reason == null ? "" : "$reason ") +
             "${expected.toString()} and "
-            "${actual.toString()} have different signs.");
+                "${actual.toString()} have different signs.");
   }
 }
 
diff --git a/tests/dart2js/dart2js_2.status b/tests/dart2js/dart2js.status
similarity index 100%
rename from tests/dart2js/dart2js_2.status
rename to tests/dart2js/dart2js.status
diff --git a/tests/dart2js/deferred/uninstantiated_type_variable_lib.dart b/tests/dart2js/deferred/uninstantiated_type_variable_lib.dart
index 2af788d..08933c9 100644
--- a/tests/dart2js/deferred/uninstantiated_type_variable_lib.dart
+++ b/tests/dart2js/deferred/uninstantiated_type_variable_lib.dart
@@ -8,7 +8,7 @@
 class A {}
 
 class Box<T> {
-  int value;
+  int? value;
 }
 
 class B<T> extends A {
diff --git a/tests/dart2js/effectively_constant_fields_test.dart b/tests/dart2js/effectively_constant_fields_test.dart
index 6c9c18b..b6f9e35 100644
--- a/tests/dart2js/effectively_constant_fields_test.dart
+++ b/tests/dart2js/effectively_constant_fields_test.dart
@@ -51,8 +51,8 @@
 }
 
 @pragma('dart2js:noInline')
-method6(Class1 c) {
-  return c.field1;
+method6(Class1? c) {
+  return c!.field1;
 }
 
 @pragma('dart2js:noInline')
diff --git a/tests/dart2js/fields_test.dart b/tests/dart2js/fields_test.dart
index 95c2ca3..fb4bafb 100644
--- a/tests/dart2js/fields_test.dart
+++ b/tests/dart2js/fields_test.dart
@@ -6,7 +6,7 @@
 
 class A {
   A() {}
-  int x;
+  int? x;
 
   foo() {
     x = 42;
@@ -24,7 +24,7 @@
   Expect.equals(0, a.x);
   a.x = 4;
   Expect.equals(4, a.x);
-  a.x += 1;
+  a.x = a.x! + 1;
   Expect.equals(5, a.x);
 
   B b = new B();
diff --git a/tests/dart2js/for_in_test.dart b/tests/dart2js/for_in_test.dart
index 8f0eb15..eca74b8 100644
--- a/tests/dart2js/for_in_test.dart
+++ b/tests/dart2js/for_in_test.dart
@@ -42,7 +42,10 @@
         index = -1;
 
   bool moveNext() => ++index < values.length;
-  T get current => (0 <= index && index < values.length) ? values[index] : null;
+  T get current {
+    assert(0 <= index && index < values.length);
+    return values[index];
+  }
 }
 
 void main() {
diff --git a/tests/dart2js/for_test.dart b/tests/dart2js/for_test.dart
index fc910be..2a4e668 100644
--- a/tests/dart2js/for_test.dart
+++ b/tests/dart2js/for_test.dart
@@ -46,7 +46,7 @@
   var i;
   var sum = 0;
   for (i = 0; i < 5; i++) {
-    sum += i;
+    sum += i as int;
   }
   Expect.equals(5, i);
   Expect.equals(10, sum);
diff --git a/tests/dart2js/generic_class_is_test.dart b/tests/dart2js/generic_class_is_test.dart
index 6026b8d..cc2efe4 100644
--- a/tests/dart2js/generic_class_is_test.dart
+++ b/tests/dart2js/generic_class_is_test.dart
@@ -20,6 +20,6 @@
 class C2 implements C {}
 
 main() {
-  Expect.isTrue(new B<List<A<C>>>().method(new List<A1>()));
-  Expect.isFalse(new B<List<A<C2>>>().method(new List<A1>()));
+  Expect.isTrue(B<List<A<C>>>().method(List<A1>.empty()));
+  Expect.isFalse(B<List<A<C2>>>().method(List<A1>.empty()));
 }
diff --git a/tests/dart2js/generic_instantiation1_test.dart b/tests/dart2js/generic_instantiation1_test.dart
index fcfb79f..c22d9c4 100644
--- a/tests/dart2js/generic_instantiation1_test.dart
+++ b/tests/dart2js/generic_instantiation1_test.dart
@@ -2,9 +2,7 @@
 // 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.
 
-// dart2jsOptions=--strong
-
-int f<T>(T a) => null;
+int f<T>(T a) => 0;
 
 typedef int F<R>(R a);
 
@@ -15,5 +13,5 @@
 }
 
 main() {
-  new B<int>().c(0);
+  B<int>().c(0);
 }
diff --git a/tests/dart2js/generic_instantiation2_test.dart b/tests/dart2js/generic_instantiation2_test.dart
index 047d221..c22d9c4 100644
--- a/tests/dart2js/generic_instantiation2_test.dart
+++ b/tests/dart2js/generic_instantiation2_test.dart
@@ -2,9 +2,7 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks
-
-int f<T>(T a) => null;
+int f<T>(T a) => 0;
 
 typedef int F<R>(R a);
 
@@ -15,5 +13,5 @@
 }
 
 main() {
-  new B<int>().c(0);
+  B<int>().c(0);
 }
diff --git a/tests/dart2js/generic_type_error_message_test.dart b/tests/dart2js/generic_type_error_message_test.dart
index e9ff104..a7b8c8d 100644
--- a/tests/dart2js/generic_type_error_message_test.dart
+++ b/tests/dart2js/generic_type_error_message_test.dart
@@ -2,8 +2,6 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Foo<T extends num> {}
@@ -21,14 +19,14 @@
   test(c as Baz<num>, Baz, expectTypeArguments: true);
 }
 
-void test(dynamic object, Type type, {bool expectTypeArguments}) {
+void test(dynamic object, Type type, {required bool expectTypeArguments}) {
   bool caught = false;
   try {
     print(type);
     object as List<String>;
   } catch (e) {
     String expected = '$type';
-    if (!expectTypeArguments) {
+    if (!expectTypeArguments!) {
       expected = expected.substring(0, expected.indexOf('<'));
     }
     expected = '$expected';
diff --git a/tests/dart2js/getters_setters_test.dart b/tests/dart2js/getters_setters_test.dart
index 139f366..d7b5d2d 100644
--- a/tests/dart2js/getters_setters_test.dart
+++ b/tests/dart2js/getters_setters_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 class GettersSettersTest {
-  static int foo;
+  static int? foo;
 
   static get bar {
     return foo;
@@ -67,8 +67,8 @@
 
 class A {
   A();
-  int x_;
-  static int foo;
+  int? x_;
+  static int? foo;
 
   static get bar {
     return foo;
@@ -79,7 +79,7 @@
   }
 
   int get x {
-    return x_;
+    return x_!;
   }
 
   void set x(int value) {
@@ -91,7 +91,7 @@
   }
 
   int operator [](int index) {
-    return x_ + index;
+    return x_! + index;
   }
 
   void operator []=(int index, int value) {
@@ -99,7 +99,7 @@
   }
 
   int getX_() {
-    return x_;
+    return x_!;
   }
 }
 
@@ -108,14 +108,14 @@
 }
 
 class C extends A {
-  int y_;
+  int? y_;
 
   C() {
     this.x_ = 0;
   }
 
   int get x {
-    return y_;
+    return y_!;
   }
 
   void set x(int value) {
diff --git a/tests/dart2js/inferrer_is_int_test.dart b/tests/dart2js/inferrer_is_int_test.dart
index c1cb1af..f544578 100644
--- a/tests/dart2js/inferrer_is_int_test.dart
+++ b/tests/dart2js/inferrer_is_int_test.dart
@@ -6,7 +6,7 @@
 // literal might become an int at runtime.
 
 import "package:expect/expect.dart";
-import '../language_2/compiler_annotations.dart';
+import '../language/compiler_annotations.dart';
 
 @DontInline()
 callWithStringAndDouble(value) {
diff --git a/tests/dart2js/injected_cast_test.dart b/tests/dart2js/injected_cast_test.dart
index 3ab671c..4413de3 100644
--- a/tests/dart2js/injected_cast_test.dart
+++ b/tests/dart2js/injected_cast_test.dart
@@ -12,15 +12,20 @@
 }
 
 @pragma('dart2js:noInline')
-test1(dynamic c, num n) {
+test1(dynamic c, dynamic n) {
   if (c is Class) {
     c.method(field = 41, n, field = 42);
   }
 }
 
 @pragma('dart2js:noInline')
-test2(dynamic c, num n) {
+test2(dynamic c, dynamic n) {
   if (c is! Class) return;
+  c.method(field = 66, n, field = 67);
+}
+
+@pragma('dart2js:noInline')
+test3(dynamic c, dynamic n) {
   c.method(field = 86, n, field = 87);
 }
 
@@ -36,6 +41,14 @@
 
   try {
     test2(new Class(), 0.5);
+    field = 213;
+    field = 213;
+  } catch (e) {}
+  // See above comment.
+  Expect.equals(66, field);
+
+  try {
+    test3(new Class(), 0.5);
     field = 321;
     field = 321;
   } catch (e) {}
diff --git a/tests/dart2js/instantiation_stub_2_test.dart b/tests/dart2js/instantiation_stub_2_test.dart
index 1376011..99d7a6c 100644
--- a/tests/dart2js/instantiation_stub_2_test.dart
+++ b/tests/dart2js/instantiation_stub_2_test.dart
@@ -2,26 +2,25 @@
 // 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 'package:expect/expect.dart';
 
-List<T> foo<T>([T a1, T a2, T a3, T a4, T a5, T a6, T a7]) =>
-    <T>[a1, a2, a3, a4, a5, a6, a7];
+List<T?> foo<T>([T? a1, T? a2, T? a3, T? a4, T? a5, T? a6, T? a7]) =>
+    [a1, a2, a3, a4, a5, a6, a7];
 
 class CC {
-  List<T> bar<T, U, V>([T a1, T a2, T a3, T a4, T a5, T a6]) =>
-      <T>[a1, a2, a3, a4, a5, a6];
+  List<T?> bar<T, U, V>([T? a1, T? a2, T? a3, T? a4, T? a5, T? a6]) =>
+      [a1, a2, a3, a4, a5, a6];
 }
 
 main() {
   // We expect a call$1$5 entry for foo, accessed nowhere else in the program
   // except via the call$5 entry on the instantiation.
-  List<int> Function(int, int, int, int, int) f = foo;
+  List<int?> Function(int?, int?, int?, int?, int?) f = foo;
   Expect.equals(4, f(1, 2, 3, 4, 5)[3]);
 
   // We expect a bar$3$4 entry for bar, accessed nowhere else in the program
   // except via the call$4 entry on the instantiation.
-  var o = new CC();
-  List<String> Function(String, String, String, String) g = o.bar;
+  var o = CC();
+  List<String?> Function(String?, String?, String?, String?) g = o.bar;
   Expect.equals('abcdnullnull', g('a', 'b', 'c', 'd').join(''));
 }
diff --git a/tests/dart2js/internal/deferred/load_in_correct_order_lib4.dart b/tests/dart2js/internal/deferred/load_in_correct_order_lib4.dart
index 4d52cac..eed0c5b 100644
--- a/tests/dart2js/internal/deferred/load_in_correct_order_lib4.dart
+++ b/tests/dart2js/internal/deferred/load_in_correct_order_lib4.dart
@@ -1,6 +1,6 @@
 class C4 {
   final value = 499;
   const C4();
-
+}
 
 const c4 = const C4();
diff --git a/tests/dart2js/internal/lax_runtime_type_closure_to_string7_test.dart b/tests/dart2js/internal/lax_runtime_type_closure_to_string7_test.dart
index 652ac67..9bb98e3 100644
--- a/tests/dart2js/internal/lax_runtime_type_closure_to_string7_test.dart
+++ b/tests/dart2js/internal/lax_runtime_type_closure_to_string7_test.dart
@@ -13,7 +13,7 @@
 
 @pragma('dart2js:noInline')
 test<Q>() {
-  Q local1(Q) {}
+  Q? local1(Q) {}
   local2(int i) => i;
 
   var toString = '${local1.runtimeType}';
diff --git a/tests/dart2js/internal/rti/bind_test.dart b/tests/dart2js/internal/rti/bind_test.dart
index 4e38ba6..907d271 100644
--- a/tests/dart2js/internal/rti/bind_test.dart
+++ b/tests/dart2js/internal/rti/bind_test.dart
@@ -5,13 +5,13 @@
 import 'dart:_rti' as rti;
 import "package:expect/expect.dart";
 
-void checkRtiIdentical(Object rti1, Object rti2) {
+void checkRtiIdentical(rti.Rti rti1, rti.Rti rti2) {
   var format = rti.testingRtiToString;
   Expect.isTrue(
       identical(rti1, rti2), 'identical(${format(rti1)}, ${format(rti2)}');
 }
 
-void checkToString(String expected, Object rti1) {
+void checkToString(String expected, rti.Rti rti1) {
   String result = rti.testingRtiToString(rti1);
   if (expected == result) return;
   Expect.equals(expected, result.replaceAll('minified:', ''));
diff --git a/tests/dart2js/internal/rti/bound_environment_test.dart b/tests/dart2js/internal/rti/bound_environment_test.dart
index 67f8ec3..6032e0b 100644
--- a/tests/dart2js/internal/rti/bound_environment_test.dart
+++ b/tests/dart2js/internal/rti/bound_environment_test.dart
@@ -5,13 +5,13 @@
 import 'dart:_rti' as rti;
 import "package:expect/expect.dart";
 
-void checkRtiIdentical(Object rti1, Object rti2) {
+void checkRtiIdentical(rti.Rti rti1, rti.Rti rti2) {
   var format = rti.testingRtiToString;
   Expect.isTrue(
       identical(rti1, rti2), 'identical(${format(rti1)}, ${format(rti2)}');
 }
 
-void checkToString(String expected, Object rti1) {
+void checkToString(String expected, rti.Rti rti1) {
   String result = rti.testingRtiToString(rti1);
   if (expected == result) return;
   Expect.equals(expected, result.replaceAll('minified:', ''));
diff --git a/tests/dart2js/internal/rti/class_environment_test.dart b/tests/dart2js/internal/rti/class_environment_test.dart
index 4cf7d9e..296333a3 100644
--- a/tests/dart2js/internal/rti/class_environment_test.dart
+++ b/tests/dart2js/internal/rti/class_environment_test.dart
@@ -5,13 +5,13 @@
 import 'dart:_rti' as rti;
 import "package:expect/expect.dart";
 
-void checkRtiIdentical(Object rti1, Object rti2) {
+void checkRtiIdentical(rti.Rti rti1, rti.Rti rti2) {
   var format = rti.testingRtiToString;
   Expect.isTrue(
       identical(rti1, rti2), 'identical(${format(rti1)}, ${format(rti2)}');
 }
 
-void checkToString(String expected, Object rti1) {
+void checkToString(String expected, rti.Rti rti1) {
   String result = rti.testingRtiToString(rti1);
   if (expected == result) return;
   Expect.equals(expected, result.replaceAll('minified:', ''));
diff --git a/tests/dart2js/internal/rti/required_named_parameters_test.dart b/tests/dart2js/internal/rti/required_named_parameters_test.dart
index 309a381..c07f7a4 100644
--- a/tests/dart2js/internal/rti/required_named_parameters_test.dart
+++ b/tests/dart2js/internal/rti/required_named_parameters_test.dart
@@ -51,11 +51,11 @@
 
   // Subtype may not redeclare optional parameters as required
   rti2 = rti.testingUniverseEval(universe, "@(A,{a!A,b!A,c!A})");
-  Expect.isFalse(rti.testingIsSubtype(universe, rti2, rti1));
+  Expect.equals(isWeakMode, rti.testingIsSubtype(universe, rti2, rti1));
 
   // Subtype may not declare new required named parameters
   rti2 = rti.testingUniverseEval(universe, "@(A,{a!A,b:A,c!A,d!A})");
-  Expect.isFalse(rti.testingIsSubtype(universe, rti2, rti1));
+  Expect.equals(isWeakMode, rti.testingIsSubtype(universe, rti2, rti1));
 
   // Rti.toString() appears as expected
   Expect.equals('(B, {required B a, B b, required B c}) => dynamic',
diff --git a/tests/dart2js/internal/rti/simple_2_test.dart b/tests/dart2js/internal/rti/simple_2_test.dart
index e195451..fd3da62 100644
--- a/tests/dart2js/internal/rti/simple_2_test.dart
+++ b/tests/dart2js/internal/rti/simple_2_test.dart
@@ -5,7 +5,7 @@
 import 'dart:_rti' as rti;
 import "package:expect/expect.dart";
 
-void checkToString(String expected, Object rti1) {
+void checkToString(String expected, rti.Rti rti1) {
   String result = rti.testingRtiToString(rti1);
   if (expected == result) return;
   Expect.equals(expected, result.replaceAll('minified:', ''));
diff --git a/tests/dart2js/is_check_instanceof_test.dart b/tests/dart2js/is_check_instanceof_test.dart
index 7e9c8a4..e219294 100644
--- a/tests/dart2js/is_check_instanceof_test.dart
+++ b/tests/dart2js/is_check_instanceof_test.dart
@@ -33,7 +33,7 @@
 }
 
 void main() {
-  var things = new List(3);
+  var things = []..length = 3;
   things.setRange(0, 3, [new INSTANTIATED(), 1, new Object()]);
 
   var checkX = new Check<INSTANTIATED>();
diff --git a/tests/dart2js/js_array_index_error_test.dart b/tests/dart2js/js_array_index_error_test.dart
index 8af893a..9998762 100644
--- a/tests/dart2js/js_array_index_error_test.dart
+++ b/tests/dart2js/js_array_index_error_test.dart
@@ -11,10 +11,10 @@
 @pragma('dart2js:assumeDynamic')
 confuse(x) => x;
 
-Error getError(action(), name, part) {
+Error? getError(action(), name, part) {
   try {
     action();
-  } catch (e) {
+  } on Error catch (e) {
     return e;
   }
   Expect.fail('must throw: $name: $part');
diff --git a/tests/dart2js/js_array_removeLast_error_test.dart b/tests/dart2js/js_array_removeLast_error_test.dart
index 5241f55..de5496b 100644
--- a/tests/dart2js/js_array_removeLast_error_test.dart
+++ b/tests/dart2js/js_array_removeLast_error_test.dart
@@ -11,11 +11,11 @@
 @pragma('dart2js:assumeDynamic')
 confuse(x) => x;
 
-Error getError(action()) {
+Error? getError(action()) {
   try {
     action();
     Expect.fail('must throw');
-  } catch (e) {
+  } on Error catch (e) {
     return e;
   }
 }
diff --git a/tests/dart2js/jsinterop_test.dart b/tests/dart2js/jsinterop_test.dart
index 07798e5..f44b2b4 100644
--- a/tests/dart2js/jsinterop_test.dart
+++ b/tests/dart2js/jsinterop_test.dart
@@ -50,7 +50,7 @@
 
 class Class {
   Class.generative();
-  factory Class.fact() => null;
+  factory Class.fact() => null as dynamic;
 
   // NON_NATIVE_EXTERNAL               //# 08: compile-time error
   external Class.externalGenerative(); //# 08: continued
@@ -58,7 +58,7 @@
   // NON_NATIVE_EXTERNAL                 //# 09: compile-time error
   external factory Class.externalFact(); //# 09: continued
 
-  @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 10: compile-time error
+  @JS('a') // GENERIC  //# 10: compile-time error
   Class.jsInteropGenerative(); //# 10: continued
 
   @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 11: compile-time error
diff --git a/tests/dart2js/lax_runtime_type_closure_equals1_test.dart b/tests/dart2js/lax_runtime_type_closure_equals1_test.dart
index 8f9836f..3837a0c 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals1_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals1_test.dart
@@ -2,7 +2,7 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
diff --git a/tests/dart2js/lax_runtime_type_closure_equals2_test.dart b/tests/dart2js/lax_runtime_type_closure_equals2_test.dart
index 56afe25..6b62ae4 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals2_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals2_test.dart
@@ -2,7 +2,7 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
@@ -11,13 +11,13 @@
 }
 
 main() {
-  T local1a<T>() => null;
+  T local1a<T>() => throw 'unreachable';
 
-  T local1b<T>() => null;
+  T local1b<T>() => throw 'unreachable';
 
   T local2<T>(T t, String s) => t;
 
   Expect.isTrue(local1a.runtimeType == local1b.runtimeType);
   Expect.isFalse(local1a.runtimeType == local2.runtimeType);
-  new Class();
+  Class();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals3_test.dart b/tests/dart2js/lax_runtime_type_closure_equals3_test.dart
index 673211e..6f3d755 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals3_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals3_test.dart
@@ -2,19 +2,19 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
-String method() => null;
+String method() => throw 'unreachable';
 
 class Class1<T> {
   Class1();
 
   method() {
-    T local1a() => null;
+    T local1a() => throw 'unreachable';
 
-    T local1b() => null;
+    T local1b() => throw 'unreachable';
 
     T local2(T t, String s) => t;
 
@@ -29,6 +29,6 @@
 }
 
 main() {
-  new Class1<int>().method();
-  new Class2<int>();
+  Class1<int>().method();
+  Class2<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals4_test.dart b/tests/dart2js/lax_runtime_type_closure_equals4_test.dart
index 73b72b3..24004b5 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals4_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals4_test.dart
@@ -2,16 +2,16 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
 class Class1<T> {
   Class1();
 
-  method1a() => null;
+  method1a() => throw 'unreachable';
 
-  method1b() => null;
+  method1b() => throw 'unreachable';
 
   method2(t, s) => t;
 }
@@ -21,9 +21,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals5_test.dart b/tests/dart2js/lax_runtime_type_closure_equals5_test.dart
index ecad991..cb6ab52 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals5_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals5_test.dart
@@ -2,16 +2,16 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
 class Class1<T> {
   Class1();
 
-  T method1a() => null;
+  T method1a() => throw 'unreachable';
 
-  T method1b() => null;
+  T method1b() => throw 'unreachable';
 
   T method2(T t, String s) => t;
 }
@@ -21,9 +21,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals6_test.dart b/tests/dart2js/lax_runtime_type_closure_equals6_test.dart
index 23641eb..a0e7a3f 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals6_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals6_test.dart
@@ -2,13 +2,13 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
-method1a() => null;
+method1a() => throw 'unreachable';
 
-method1b() => null;
+method1b() => throw 'unreachable';
 
 method2(t, s) => t;
 
@@ -19,5 +19,5 @@
 main() {
   Expect.isTrue(method1a.runtimeType == method1b.runtimeType);
   Expect.isFalse(method1a.runtimeType == method2.runtimeType);
-  new Class<int>();
+  Class<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals7_test.dart b/tests/dart2js/lax_runtime_type_closure_equals7_test.dart
index 129dcca..1542dd1 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals7_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals7_test.dart
@@ -2,13 +2,13 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
-T method1a<T>() => null;
+T method1a<T>() => throw 'unreachable';
 
-T method1b<T>() => null;
+T method1b<T>() => throw 'unreachable';
 
 T method2<T>(T t, String s) => t;
 
@@ -19,5 +19,5 @@
 main() {
   Expect.isTrue(method1a.runtimeType == method1b.runtimeType);
   Expect.isFalse(method1a.runtimeType == method2.runtimeType);
-  new Class<int>();
+  Class<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_equals8_test.dart b/tests/dart2js/lax_runtime_type_closure_equals8_test.dart
index 7a1142d..c8dc561 100644
--- a/tests/dart2js/lax_runtime_type_closure_equals8_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_equals8_test.dart
@@ -2,16 +2,16 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
 class Class1<S> {
   Class1();
 
-  T method1a<T>() => null;
+  T method1a<T>() => throw 'unreachable';
 
-  T method1b<T>() => null;
+  T method1b<T>() => throw 'unreachable';
 
   T method2<T>(T t, String s) => t;
 }
@@ -21,9 +21,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_to_string3_test.dart b/tests/dart2js/lax_runtime_type_closure_to_string3_test.dart
index 1d244c0..5f0edff 100644
--- a/tests/dart2js/lax_runtime_type_closure_to_string3_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_to_string3_test.dart
@@ -2,14 +2,14 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string --experiment-new-rti
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string --experiment-new-rti
 
 import 'package:expect/expect.dart';
 
 class Class1<T> {
   Class1();
 
-  T method() => null;
+  T method() => throw 'unreachable';
 }
 
 class Class2<T> {
@@ -17,7 +17,7 @@
 }
 
 main() {
-  Class1<int> cls1 = new Class1<int>();
+  Class1<int> cls1 = Class1<int>();
   Expect.equals("() => erased", cls1.method.runtimeType.toString());
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/lax_runtime_type_closure_to_string4_test.dart b/tests/dart2js/lax_runtime_type_closure_to_string4_test.dart
index c95cf29..95db29e 100644
--- a/tests/dart2js/lax_runtime_type_closure_to_string4_test.dart
+++ b/tests/dart2js/lax_runtime_type_closure_to_string4_test.dart
@@ -2,14 +2,14 @@
 // 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.
 
-// dart2jsOptions=--strong --omit-implicit-checks --lax-runtime-type-to-string
+// dart2jsOptions=--omit-implicit-checks --lax-runtime-type-to-string
 
 import 'package:expect/expect.dart';
 
 class Class1 {
   Class1();
 
-  T method<T>() => null;
+  T method<T>() => throw 'unreachable';
 }
 
 class Class2<T> {
@@ -17,7 +17,7 @@
 }
 
 main() {
-  Class1 cls1 = new Class1();
+  Class1 cls1 = Class1();
   Expect.equals("<T1>() => T1", cls1.method.runtimeType.toString());
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/list_factory_test.dart b/tests/dart2js/list_factory_test.dart
index b58c925..3df2eb5 100644
--- a/tests/dart2js/list_factory_test.dart
+++ b/tests/dart2js/list_factory_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 main() {
-  var a = new List(4);
+  var a = List.filled(4, 0);
   Expect.equals(4, a.length);
   a[0] = 42;
   a[1] = 43;
@@ -15,7 +15,7 @@
     Expect.equals(42 + i, a[i]);
   }
 
-  a = new List();
+  a = List.empty(growable: true);
   a.add(42);
   a.add(43);
   a.add(44);
diff --git a/tests/dart2js/local_function_signatures_strong_test.dart b/tests/dart2js/local_function_signatures_strong_test.dart
index f1df515..89b2c23 100644
--- a/tests/dart2js/local_function_signatures_strong_test.dart
+++ b/tests/dart2js/local_function_signatures_strong_test.dart
@@ -2,93 +2,91 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1 {
   method1() {
-    num local<T>(num n) => null;
+    num local<T>(num n) => null as dynamic;
     return local;
   }
 
   method2() {
-    num local<T>(int n) => null;
+    num local<T>(int n) => null as dynamic;
     return local;
   }
 
   method3() {
-    int local<T>(num n) => null;
+    int local<T>(num n) => null as dynamic;
     return local;
   }
 }
 
 class Class2 {
   method4<T>() {
-    num local(T n) => null;
+    num local(T n) => null as dynamic;
     return local;
   }
 }
 
 class Class3 {
   method5<T>() {
-    T local(num n) => null;
+    T local(num n) => null as dynamic;
     return local;
   }
 }
 
 class Class4 {
   method6<T>() {
-    num local(num n, T t) => null;
+    num local(num n, T t) => null as dynamic;
     return local;
   }
 }
 
 method7<T>() {
-  num local(T n) => null;
+  num local(T n) => null as dynamic;
   return local;
 }
 
 method8<T>() {
-  T local(num n) => null;
+  T local(num n) => null as dynamic;
   return local;
 }
 
 method9<T>() {
-  num local(num n, T t) => null;
+  num local(num n, T t) => null as dynamic;
   return local;
 }
 
 method10() {
-  num local<T>(T n) => null;
+  num local<T>(T n) => null as dynamic;
   return local;
 }
 
 method11() {
-  T local<T>(num n) => null;
+  T local<T>(num n) => null as dynamic;
   return local;
 }
 
 method12() {
-  num local<T>(num n, T t) => null;
+  num local<T>(num n, T t) => null as dynamic;
   return local;
 }
 
 num Function(num) //# 01: ok
     method13() {
-  num local<T>(num n) => null;
+  num local<T>(num n) => null as dynamic;
   return local;
 }
 
 num Function(num) //# 01: continued
     method14() {
-  num local<T>(T n) => null;
+  num local<T>(T n) => null as dynamic;
   return local;
 }
 
 num Function(num) //# 01: continued
     method15() {
-  T local<T>(num n) => null;
+  T local<T>(num n) => null as dynamic;
   return local;
 }
 
diff --git a/tests/dart2js/local_function_signatures_test.dart b/tests/dart2js/local_function_signatures_test.dart
index 11bfb83..303be77 100644
--- a/tests/dart2js/local_function_signatures_test.dart
+++ b/tests/dart2js/local_function_signatures_test.dart
@@ -2,44 +2,42 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1 {
   method1() {
-    num local(num n) => null;
+    num local(num n) => null as dynamic;
     return local;
   }
 
   method2() {
-    num local(int n) => null;
+    num local(int n) => null as dynamic;
     return local;
   }
 
   method3() {
-    Object local(num n) => null;
+    Object local(num n) => null as dynamic;
     return local;
   }
 }
 
 class Class2<T> {
   method4() {
-    num local(T n) => null;
+    num local(T n) => null as dynamic;
     return local;
   }
 }
 
 class Class3<T> {
   method5() {
-    T local(num n) => null;
+    T local(num n) => null as dynamic;
     return local;
   }
 }
 
 class Class4<T> {
   method6() {
-    num local(num n, T t) => null;
+    num local(num n, T t) => null as dynamic;
     return local;
   }
 }
diff --git a/tests/dart2js/member_namespace_test.dart b/tests/dart2js/member_namespace_test.dart
index ff65d20..43d265f 100644
--- a/tests/dart2js/member_namespace_test.dart
+++ b/tests/dart2js/member_namespace_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 class A {
-  static int a;
+  static int? a;
   A();
   static foo() {
     // Make sure 'A' is not resolved to the constructor.
diff --git a/tests/dart2js/method_signatures_strong_test.dart b/tests/dart2js/method_signatures_strong_test.dart
index 3e3f256..b3be862 100644
--- a/tests/dart2js/method_signatures_strong_test.dart
+++ b/tests/dart2js/method_signatures_strong_test.dart
@@ -2,35 +2,33 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1 {
-  num method1<T>(num n) => null;
+  num method1<T>(num n) => throw 'unreachable';
 
-  num method2<T>(int n) => null;
+  num method2<T>(int n) => throw 'unreachable';
 
-  int method3<T>(num n) => null;
+  int method3<T>(num n) => throw 'unreachable';
 }
 
 class Class2 {
-  num method4<T>(T n) => null;
+  num method4<T>(T n) => throw 'unreachable';
 }
 
 class Class3 {
-  T method5<T>(num n) => null;
+  T method5<T>(num n) => throw 'unreachable';
 }
 
 class Class4 {
-  num method6<T>(num n, T t) => null;
+  num method6<T>(num n, T t) => throw 'unreachable';
 }
 
-num method7<T>(T n) => null;
+num method7<T>(T n) => throw 'unreachable';
 
-T method8<T>(num n) => null;
+T method8<T>(num n) => throw 'unreachable';
 
-num method9<T>(num n, T t) => null;
+num method9<T>(num n, T t) => throw 'unreachable';
 
 @pragma('dart2js:noInline')
 test(o) => o is num Function(num);
diff --git a/tests/dart2js/method_signatures_test.dart b/tests/dart2js/method_signatures_test.dart
index 79d0c7f..5c35561 100644
--- a/tests/dart2js/method_signatures_test.dart
+++ b/tests/dart2js/method_signatures_test.dart
@@ -2,35 +2,33 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1 {
-  num method1(num n) => null;
+  num method1(num n) => throw 'unreachable';
 
-  num method2(int n) => null;
+  num method2(int n) => throw 'unreachable';
 
-  Object method3(num n) => null;
+  Object method3(num n) => throw 'unreachable';
 }
 
 class Class2<T> {
-  num method4(T n) => null;
+  num method4(T n) => throw 'unreachable';
 }
 
 class Class3<T> {
-  T method5(num n) => null;
+  T method5(num n) => throw 'unreachable';
 }
 
 class Class4<T> {
-  num method6(num n, T t) => null;
+  num method6(num n, T t) => throw 'unreachable';
 }
 
-num method7(num n) => null;
+num method7(num n) => throw 'unreachable';
 
-num method8(int n) => null;
+num method8(int n) => throw 'unreachable';
 
-Object method9(num n) => null;
+Object method9(num n) => throw 'unreachable';
 
 @pragma('dart2js:noInline')
 test(o) => o is num Function(num);
diff --git a/tests/dart2js/minus_zero2_test.dart b/tests/dart2js/minus_zero2_test.dart
index 02cf9f0..a48b860 100644
--- a/tests/dart2js/minus_zero2_test.dart
+++ b/tests/dart2js/minus_zero2_test.dart
@@ -10,10 +10,10 @@
   // Dart2js must use "-0.0" as if it was 0. In particular, it must do its
   // range-analysis correctly.
   var list = [1, 2, 3];
-  if (new DateTime.now().millisecondsSinceEpoch == 42) list[1] = 4;
+  if (DateTime.now().millisecondsSinceEpoch == 42) list[1] = 4;
   int sum = 0;
   for (num i = -0.0; i < list.length; i++) {
-    sum += list[i];
+    sum += list[i as int];
   }
   Expect.equals(6, sum);
 }
diff --git a/tests/dart2js/minus_zero_test.dart b/tests/dart2js/minus_zero_test.dart
index bc3c0b6..705c62d 100644
--- a/tests/dart2js/minus_zero_test.dart
+++ b/tests/dart2js/minus_zero_test.dart
@@ -13,7 +13,7 @@
   // Dart2js must not infer that the type-intersection of int and -0.0 is empty.
   // It must get an interceptor for the addition (`i += 3`), or use the native
   // JS + operation.
-  int i = minusZero();
+  int i = minusZero() as int;
   i += 3;
   Expect.equals(3, i);
 }
diff --git a/tests/dart2js/mixin_type_variable_test.dart b/tests/dart2js/mixin_type_variable_test.dart
index 750e58d..5d7c69e 100644
--- a/tests/dart2js/mixin_type_variable_test.dart
+++ b/tests/dart2js/mixin_type_variable_test.dart
@@ -3,7 +3,7 @@
 // BSD-style license that can be found in the LICENSE file.
 
 abstract class Bar<C> {
-  final List<C> _one = new List<C>();
+  final List<C> _one = [];
 
   final bool _two = Foo is C;
 }
@@ -29,7 +29,7 @@
 }
 
 main() {
-  new Foo();
-  new C('e');
-  new F('e');
+  Foo();
+  C('e');
+  F('e');
 }
diff --git a/tests/dart2js/native/compute_this_script_test.dart b/tests/dart2js/native/compute_this_script_test.dart
index ee5c855..5b76bf5 100644
--- a/tests/dart2js/native/compute_this_script_test.dart
+++ b/tests/dart2js/native/compute_this_script_test.dart
@@ -10,7 +10,7 @@
   // This is somewhat brittle and relies on an implementation detail
   // of our test runner, but I can think of no other way to test this.
   // -- ahe
-  if (!thisScript.endsWith('/compute_this_script_test.js')) {
+  if (!thisScript!.endsWith('/compute_this_script_test.js')) {
     throw 'Unexpected script: "$thisScript"';
   }
 }
diff --git a/tests/dart2js/native/error_safeToString_test.dart b/tests/dart2js/native/error_safeToString_test.dart
index 115c908..022b53a 100644
--- a/tests/dart2js/native/error_safeToString_test.dart
+++ b/tests/dart2js/native/error_safeToString_test.dart
@@ -80,9 +80,11 @@
 expectTypeName(expectedName, s) {
   var m = new RegExp(r"Instance of '(.*)'").firstMatch(s);
   Expect.isNotNull(m);
-  var name = m.group(1);
+  var name = m!.group(1);
   Expect.isTrue(
-      expectedName == name || name.length <= 3 || name.startsWith('minified:'),
+      expectedName == name ||
+          name!.length <= 3 ||
+          name!.startsWith('minified:'),
       "Is '$expectedName' or minified: '$name'");
 }
 
diff --git a/tests/dart2js/native/field_type_test.dart b/tests/dart2js/native/field_type_test.dart
index e488855..8135cd5 100644
--- a/tests/dart2js/native/field_type_test.dart
+++ b/tests/dart2js/native/field_type_test.dart
@@ -12,11 +12,11 @@
 class Node {
   Node get parentNode native;
 
-  ModelSource _modelSource; // If null, inherited from parent.
+  ModelSource? _modelSource; // If null, inherited from parent.
 
-  ModelSource get modelSource {
+  ModelSource? get modelSource {
     for (Node node = this; node != null; node = node.parentNode) {
-      ModelSource source = node._modelSource;
+      ModelSource? source = node._modelSource;
       if (source != null) return source;
     }
     return null;
@@ -24,11 +24,11 @@
 
   // Copy of above code renamed with suffix '2'.
 
-  ModelSource _modelSource2; // If null, inherited from parent.
+  ModelSource? _modelSource2; // If null, inherited from parent.
 
-  ModelSource get modelSource2 {
+  ModelSource? get modelSource2 {
     for (Node node = this; node != null; node = node.parentNode) {
-      ModelSource source = node._modelSource2;
+      ModelSource? source = node._modelSource2;
       if (source != null) return source;
     }
     return null;
diff --git a/tests/dart2js/native/native_checked_fields_frog_test.dart b/tests/dart2js/native/native_checked_fields_frog_test.dart
index f9fdece..76d8902 100644
--- a/tests/dart2js/native/native_checked_fields_frog_test.dart
+++ b/tests/dart2js/native/native_checked_fields_frog_test.dart
@@ -4,16 +4,18 @@
 
 import 'native_testing.dart';
 
-// Test that type checks occur on assignment to fields of native methods.
+// Test that type checks occur on assignment to properties of native classes.
 
 @Native("A")
 class A {
-  int foo;
+  void set foo(int unused) native;
+  int get foo native;
 }
 
 @Native("B")
 class B {
-  String foo;
+  void set foo(String unused) native;
+  String get foo native;
 }
 
 A makeA() native;
@@ -79,7 +81,7 @@
   var a = stuff[0];
   // Detect whether we are using --omit-implicit-checks.
   try {
-    String s = a;
+    String s = a as dynamic;
     return false;
   } catch (e) {
     // Ignore.
diff --git a/tests/dart2js/native/native_class_fields_2_test.dart b/tests/dart2js/native/native_class_fields_2_test.dart
index 3b3d265..6529946 100644
--- a/tests/dart2js/native/native_class_fields_2_test.dart
+++ b/tests/dart2js/native/native_class_fields_2_test.dart
@@ -8,10 +8,14 @@
 // that are known from the DOM (like x, y, z).
 @Native("A")
 class A {
-  int x;
-  int y;
-  int z;
-  int gettersCalled;
+  void set x(int unused) native;
+  int get x native;
+  void set y(int unused) native;
+  int get y native;
+  void set z(int unused) native;
+  int get z native;
+  void set gettersCalled(int unused) native;
+  int get gettersCalled native;
 }
 
 void setup() {
diff --git a/tests/dart2js/native/native_class_fields_3_test.dart b/tests/dart2js/native/native_class_fields_3_test.dart
index 4812292..dd2824d 100644
--- a/tests/dart2js/native/native_class_fields_3_test.dart
+++ b/tests/dart2js/native/native_class_fields_3_test.dart
@@ -14,14 +14,22 @@
 // getters too if they have a property that has the same name.
 @Native("A")
 class A {
-  int bar;
-  int g;
-  int s;
-  int end;
-  int gend;
-  int send;
-  int gettersCalled;
-  int settersCalled;
+  void set bar(int unused) native;
+  int get bar native;
+  void set g(int unused) native;
+  int get g native;
+  void set s(int unused) native;
+  int get s native;
+  void set end(int unused) native;
+  int get end native;
+  void set gend(int unused) native;
+  int get gend native;
+  void set send(int unused) native;
+  int get send native;
+  void set gettersCalled(int unused) native;
+  int get gettersCalled native;
+  void set settersCalled(int unused) native;
+  int get settersCalled native;
 }
 
 void setup() {
diff --git a/tests/dart2js/native/native_class_fields_test.dart b/tests/dart2js/native/native_class_fields_test.dart
index e37adbe..64122ac 100644
--- a/tests/dart2js/native/native_class_fields_test.dart
+++ b/tests/dart2js/native/native_class_fields_test.dart
@@ -7,8 +7,10 @@
 // Verify that native fields on classes are not renamed by the minifier.
 @Native("A")
 class A {
-  int myLongPropertyName;
-  int getValue;
+  void set myLongPropertyName(int unused) native;
+  int get myLongPropertyName native;
+  void set getValue(int unused) native;
+  int get getValue native;
 
   int method(int z) => myLongPropertyName;
 }
diff --git a/tests/dart2js/native/native_exceptions1_frog_test.dart b/tests/dart2js/native/native_exceptions1_frog_test.dart
index fbef012..b9957e8 100644
--- a/tests/dart2js/native/native_exceptions1_frog_test.dart
+++ b/tests/dart2js/native/native_exceptions1_frog_test.dart
@@ -87,8 +87,8 @@
     var x = a.op(51);
   } catch (e) {
     threw = true;
-    Expect.equals(100, e.code);
     Expect.isTrue(e is E);
+    Expect.equals(100, (e as E).code);
   }
   Expect.isTrue(threw);
 
diff --git a/tests/dart2js/native/native_field_name_test.dart b/tests/dart2js/native/native_field_name_test.dart
index 66e25ac..89f401f 100644
--- a/tests/dart2js/native/native_field_name_test.dart
+++ b/tests/dart2js/native/native_field_name_test.dart
@@ -8,8 +8,10 @@
 
 @Native("A")
 class A {
-  int myLongPropertyName;
-  int getValue;
+  void set myLongPropertyName(int unused) native;
+  int get myLongPropertyName native;
+  void set getValue(int unused) native;
+  int get getValue native;
 
   int method(int z) => myLongPropertyName;
 }
diff --git a/tests/dart2js/native/native_field_rename_1_frog_test.dart b/tests/dart2js/native/native_field_rename_1_frog_test.dart
index 5fd6602..27b4710 100644
--- a/tests/dart2js/native/native_field_rename_1_frog_test.dart
+++ b/tests/dart2js/native/native_field_rename_1_frog_test.dart
@@ -10,7 +10,9 @@
 
 @Native("A")
 class A {
-  int key; //  jsname is 'key'
+  //  jsname is 'key'
+  void set key(int unused) native;
+  int get key native;
   int getKey() => key;
 }
 
diff --git a/tests/dart2js/native/native_field_rename_2_frog_test.dart b/tests/dart2js/native/native_field_rename_2_frog_test.dart
index 2c44d54..93fce23 100644
--- a/tests/dart2js/native/native_field_rename_2_frog_test.dart
+++ b/tests/dart2js/native/native_field_rename_2_frog_test.dart
@@ -9,19 +9,21 @@
 import 'native_testing.dart';
 
 abstract class I {
-  int key;
+  int? key;
 }
 
 @Native("A")
 class A implements I {
-  int key; //  jsname is 'key'
-  int getKey() => key;
+  //  jsname is 'key'
+  void set key(int? unused) native;
+  int? get key native;
+  int? getKey() => key;
 }
 
 class B implements I {
-  int key; //  jsname is not 'key'
+  int? key; //  jsname is not 'key'
   B([this.key = 222]);
-  int getKey() => key;
+  int? getKey() => key;
 }
 
 @Native("X")
@@ -72,8 +74,8 @@
 
 testPartial() {
   var things = [makeA(), new B(), makeX()];
-  I a = things[0];
-  I b = things[1];
+  I a = things[0] as I;
+  I b = things[1] as I;
 
   // All subtypes of I have a field 'key'. The compiler might be tempted to
   // generate a direct property access, but that will fail since one of the
diff --git a/tests/dart2js/native/native_null_closure_frog_test.dart b/tests/dart2js/native/native_null_closure_frog_test.dart
index 1768cac..f5fd85e 100644
--- a/tests/dart2js/native/native_null_closure_frog_test.dart
+++ b/tests/dart2js/native/native_null_closure_frog_test.dart
@@ -10,8 +10,8 @@
 
 @Native("A")
 class A {
-  setClosure(MyFunctionType f) native;
-  check(MyFunctionType f) native;
+  setClosure(MyFunctionType? f) native;
+  check(MyFunctionType? f) native;
   invoke() native;
 }
 
diff --git a/tests/dart2js/native/native_test.dart b/tests/dart2js/native/native_test.dart
index 0eb52d6..21c2bab 100644
--- a/tests/dart2js/native/native_test.dart
+++ b/tests/dart2js/native/native_test.dart
@@ -32,7 +32,7 @@
 
 class Class {
   Class.generative();
-  factory Class.fact() => null;
+  factory Class.fact() => null as dynamic;
 
   // NON_NATIVE_EXTERNAL               //# 08: compile-time error
   external Class.externalGenerative(); //# 08: continued
@@ -92,7 +92,7 @@
 class NativeClass {
   NativeClass.generative();
 
-  factory NativeClass.fact() => null;
+  factory NativeClass.fact() => null as dynamic;
 
   // NON_NATIVE_EXTERNAL                     //# 31: compile-time error
   external NativeClass.externalGenerative(); //# 31: continued
diff --git a/tests/dart2js/native/oddly_named_fields_test.dart b/tests/dart2js/native/oddly_named_fields_test.dart
index 54d9bd4..7a93c95 100644
--- a/tests/dart2js/native/oddly_named_fields_test.dart
+++ b/tests/dart2js/native/oddly_named_fields_test.dart
@@ -64,710 +64,710 @@
 @Native("NativeClassWithOddNames")
 class NativeClassWithOddNames {
   @JSName('break')
-  bool breakValue;
+  bool? breakValue;
   @JSName('case')
-  bool caseValue;
+  bool? caseValue;
   @JSName('catch')
-  bool catchValue;
+  bool? catchValue;
   @JSName('class')
-  bool classValue;
+  bool? classValue;
   @JSName('const')
-  bool constValue;
+  bool? constValue;
   @JSName('continue')
-  bool continueValue;
+  bool? continueValue;
   @JSName('debugger')
-  bool debuggerValue;
+  bool? debuggerValue;
   @JSName('default')
-  bool defaultValue;
+  bool? defaultValue;
   @JSName('delete')
-  bool deleteValue;
+  bool? deleteValue;
   @JSName('do')
-  bool doValue;
+  bool? doValue;
   @JSName('else')
-  bool elseValue;
+  bool? elseValue;
   @JSName('enum')
-  bool enumValue;
+  bool? enumValue;
   @JSName('export')
-  bool exportValue;
+  bool? exportValue;
   @JSName('extends')
-  bool extendsValue;
+  bool? extendsValue;
   @JSName('false')
-  bool falseValue;
+  bool? falseValue;
   @JSName('finally')
-  bool finallyValue;
+  bool? finallyValue;
   @JSName('for')
-  bool forValue;
+  bool? forValue;
   @JSName('function')
-  bool functionValue;
+  bool? functionValue;
   @JSName('if')
-  bool ifValue;
+  bool? ifValue;
   @JSName('implements')
-  bool implementsValue;
+  bool? implementsValue;
   @JSName('import')
-  bool importValue;
+  bool? importValue;
   @JSName('in')
-  bool inValue;
+  bool? inValue;
   @JSName('instanceof')
-  bool instanceofValue;
+  bool? instanceofValue;
   @JSName('interface')
-  bool interfaceValue;
+  bool? interfaceValue;
   @JSName('let')
-  bool letValue;
+  bool? letValue;
   @JSName('new')
-  bool newValue;
+  bool? newValue;
   @JSName('null')
-  bool nullValue;
+  bool? nullValue;
   @JSName('package')
-  bool packageValue;
+  bool? packageValue;
   @JSName('private')
-  bool privateValue;
+  bool? privateValue;
   @JSName('protected')
-  bool protectedValue;
+  bool? protectedValue;
   @JSName('public')
-  bool publicValue;
+  bool? publicValue;
   @JSName('return')
-  bool returnValue;
+  bool? returnValue;
   @JSName('static')
-  bool staticValue;
+  bool? staticValue;
   @JSName('super')
-  bool superValue;
+  bool? superValue;
   @JSName('switch')
-  bool switchValue;
+  bool? switchValue;
   @JSName('this')
-  bool thisValue;
+  bool? thisValue;
   @JSName('throw')
-  bool throwValue;
+  bool? throwValue;
   @JSName('true')
-  bool trueValue;
+  bool? trueValue;
   @JSName('try')
-  bool tryValue;
+  bool? tryValue;
   @JSName('typeof')
-  bool typeofValue;
+  bool? typeofValue;
   @JSName('var')
-  bool varValue;
+  bool? varValue;
   @JSName('void')
-  bool voidValue;
+  bool? voidValue;
   @JSName('while')
-  bool whileValue;
+  bool? whileValue;
   @JSName('with')
-  bool withValue;
+  bool? withValue;
   @JSName('yield')
-  bool yieldValue;
+  bool? yieldValue;
 
   void testMyFields() {
     if (breakValue != null) throw 'incorrect initialization of "breakValue"';
     breakValue = true;
-    if (!breakValue) throw 'incorrect value in "breakValue"';
+    if (!breakValue!) throw 'incorrect value in "breakValue"';
     breakValue = false;
-    if (breakValue) throw 'incorrect value in "breakValue"';
+    if (breakValue!) throw 'incorrect value in "breakValue"';
 
     if (caseValue != null) throw 'incorrect initialization of "caseValue"';
     caseValue = true;
-    if (!caseValue) throw 'incorrect value in "caseValue"';
+    if (!caseValue!) throw 'incorrect value in "caseValue"';
     caseValue = false;
-    if (caseValue) throw 'incorrect value in "caseValue"';
+    if (caseValue!) throw 'incorrect value in "caseValue"';
 
     if (catchValue != null) throw 'incorrect initialization of "catchValue"';
     catchValue = true;
-    if (!catchValue) throw 'incorrect value in "catchValue"';
+    if (!catchValue!) throw 'incorrect value in "catchValue"';
     catchValue = false;
-    if (catchValue) throw 'incorrect value in "catchValue"';
+    if (catchValue!) throw 'incorrect value in "catchValue"';
 
     if (classValue != null) throw 'incorrect initialization of "classValue"';
     classValue = true;
-    if (!classValue) throw 'incorrect value in "classValue"';
+    if (!classValue!) throw 'incorrect value in "classValue"';
     classValue = false;
-    if (classValue) throw 'incorrect value in "classValue"';
+    if (classValue!) throw 'incorrect value in "classValue"';
 
     if (constValue != null) throw 'incorrect initialization of "constValue"';
     constValue = true;
-    if (!constValue) throw 'incorrect value in "constValue"';
+    if (!constValue!) throw 'incorrect value in "constValue"';
     constValue = false;
-    if (constValue) throw 'incorrect value in "constValue"';
+    if (constValue!) throw 'incorrect value in "constValue"';
 
     if (continueValue != null)
       throw 'incorrect initialization of "continueValue"';
     continueValue = true;
-    if (!continueValue) throw 'incorrect value in "continueValue"';
+    if (!continueValue!) throw 'incorrect value in "continueValue"';
     continueValue = false;
-    if (continueValue) throw 'incorrect value in "continueValue"';
+    if (continueValue!) throw 'incorrect value in "continueValue"';
 
     if (debuggerValue != null)
       throw 'incorrect initialization of "debuggerValue"';
     debuggerValue = true;
-    if (!debuggerValue) throw 'incorrect value in "debuggerValue"';
+    if (!debuggerValue!) throw 'incorrect value in "debuggerValue"';
     debuggerValue = false;
-    if (debuggerValue) throw 'incorrect value in "debuggerValue"';
+    if (debuggerValue!) throw 'incorrect value in "debuggerValue"';
 
     if (defaultValue != null)
       throw 'incorrect initialization of "defaultValue"';
     defaultValue = true;
-    if (!defaultValue) throw 'incorrect value in "defaultValue"';
+    if (!defaultValue!) throw 'incorrect value in "defaultValue"';
     defaultValue = false;
-    if (defaultValue) throw 'incorrect value in "defaultValue"';
+    if (defaultValue!) throw 'incorrect value in "defaultValue"';
 
     if (deleteValue != null) throw 'incorrect initialization of "deleteValue"';
     deleteValue = true;
-    if (!deleteValue) throw 'incorrect value in "deleteValue"';
+    if (!deleteValue!) throw 'incorrect value in "deleteValue"';
     deleteValue = false;
-    if (deleteValue) throw 'incorrect value in "deleteValue"';
+    if (deleteValue!) throw 'incorrect value in "deleteValue"';
 
     if (doValue != null) throw 'incorrect initialization of "doValue"';
     doValue = true;
-    if (!doValue) throw 'incorrect value in "doValue"';
+    if (!doValue!) throw 'incorrect value in "doValue"';
     doValue = false;
-    if (doValue) throw 'incorrect value in "doValue"';
+    if (doValue!) throw 'incorrect value in "doValue"';
 
     if (elseValue != null) throw 'incorrect initialization of "elseValue"';
     elseValue = true;
-    if (!elseValue) throw 'incorrect value in "elseValue"';
+    if (!elseValue!) throw 'incorrect value in "elseValue"';
     elseValue = false;
-    if (elseValue) throw 'incorrect value in "elseValue"';
+    if (elseValue!) throw 'incorrect value in "elseValue"';
 
     if (enumValue != null) throw 'incorrect initialization of "enumValue"';
     enumValue = true;
-    if (!enumValue) throw 'incorrect value in "enumValue"';
+    if (!enumValue!) throw 'incorrect value in "enumValue"';
     enumValue = false;
-    if (enumValue) throw 'incorrect value in "enumValue"';
+    if (enumValue!) throw 'incorrect value in "enumValue"';
 
     if (exportValue != null) throw 'incorrect initialization of "exportValue"';
     exportValue = true;
-    if (!exportValue) throw 'incorrect value in "exportValue"';
+    if (!exportValue!) throw 'incorrect value in "exportValue"';
     exportValue = false;
-    if (exportValue) throw 'incorrect value in "exportValue"';
+    if (exportValue!) throw 'incorrect value in "exportValue"';
 
     if (extendsValue != null)
       throw 'incorrect initialization of "extendsValue"';
     extendsValue = true;
-    if (!extendsValue) throw 'incorrect value in "extendsValue"';
+    if (!extendsValue!) throw 'incorrect value in "extendsValue"';
     extendsValue = false;
-    if (extendsValue) throw 'incorrect value in "extendsValue"';
+    if (extendsValue!) throw 'incorrect value in "extendsValue"';
 
     if (falseValue != null) throw 'incorrect initialization of "falseValue"';
     falseValue = true;
-    if (!falseValue) throw 'incorrect value in "falseValue"';
+    if (!falseValue!) throw 'incorrect value in "falseValue"';
     falseValue = false;
-    if (falseValue) throw 'incorrect value in "falseValue"';
+    if (falseValue!) throw 'incorrect value in "falseValue"';
 
     if (finallyValue != null)
       throw 'incorrect initialization of "finallyValue"';
     finallyValue = true;
-    if (!finallyValue) throw 'incorrect value in "finallyValue"';
+    if (!finallyValue!) throw 'incorrect value in "finallyValue"';
     finallyValue = false;
-    if (finallyValue) throw 'incorrect value in "finallyValue"';
+    if (finallyValue!) throw 'incorrect value in "finallyValue"';
 
     if (forValue != null) throw 'incorrect initialization of "forValue"';
     forValue = true;
-    if (!forValue) throw 'incorrect value in "forValue"';
+    if (!forValue!) throw 'incorrect value in "forValue"';
     forValue = false;
-    if (forValue) throw 'incorrect value in "forValue"';
+    if (forValue!) throw 'incorrect value in "forValue"';
 
     if (functionValue != null)
       throw 'incorrect initialization of "functionValue"';
     functionValue = true;
-    if (!functionValue) throw 'incorrect value in "functionValue"';
+    if (!functionValue!) throw 'incorrect value in "functionValue"';
     functionValue = false;
-    if (functionValue) throw 'incorrect value in "functionValue"';
+    if (functionValue!) throw 'incorrect value in "functionValue"';
 
     if (ifValue != null) throw 'incorrect initialization of "ifValue"';
     ifValue = true;
-    if (!ifValue) throw 'incorrect value in "ifValue"';
+    if (!ifValue!) throw 'incorrect value in "ifValue"';
     ifValue = false;
-    if (ifValue) throw 'incorrect value in "ifValue"';
+    if (ifValue!) throw 'incorrect value in "ifValue"';
 
     if (implementsValue != null)
       throw 'incorrect initialization of "implementsValue"';
     implementsValue = true;
-    if (!implementsValue) throw 'incorrect value in "implementsValue"';
+    if (!implementsValue!) throw 'incorrect value in "implementsValue"';
     implementsValue = false;
-    if (implementsValue) throw 'incorrect value in "implementsValue"';
+    if (implementsValue!) throw 'incorrect value in "implementsValue"';
 
     if (importValue != null) throw 'incorrect initialization of "importValue"';
     importValue = true;
-    if (!importValue) throw 'incorrect value in "importValue"';
+    if (!importValue!) throw 'incorrect value in "importValue"';
     importValue = false;
-    if (importValue) throw 'incorrect value in "importValue"';
+    if (importValue!) throw 'incorrect value in "importValue"';
 
     if (inValue != null) throw 'incorrect initialization of "inValue"';
     inValue = true;
-    if (!inValue) throw 'incorrect value in "inValue"';
+    if (!inValue!) throw 'incorrect value in "inValue"';
     inValue = false;
-    if (inValue) throw 'incorrect value in "inValue"';
+    if (inValue!) throw 'incorrect value in "inValue"';
 
     if (instanceofValue != null)
       throw 'incorrect initialization of "instanceofValue"';
     instanceofValue = true;
-    if (!instanceofValue) throw 'incorrect value in "instanceofValue"';
+    if (!instanceofValue!) throw 'incorrect value in "instanceofValue"';
     instanceofValue = false;
-    if (instanceofValue) throw 'incorrect value in "instanceofValue"';
+    if (instanceofValue!) throw 'incorrect value in "instanceofValue"';
 
     if (interfaceValue != null)
       throw 'incorrect initialization of "interfaceValue"';
     interfaceValue = true;
-    if (!interfaceValue) throw 'incorrect value in "interfaceValue"';
+    if (!interfaceValue!) throw 'incorrect value in "interfaceValue"';
     interfaceValue = false;
-    if (interfaceValue) throw 'incorrect value in "interfaceValue"';
+    if (interfaceValue!) throw 'incorrect value in "interfaceValue"';
 
     if (letValue != null) throw 'incorrect initialization of "letValue"';
     letValue = true;
-    if (!letValue) throw 'incorrect value in "letValue"';
+    if (!letValue!) throw 'incorrect value in "letValue"';
     letValue = false;
-    if (letValue) throw 'incorrect value in "letValue"';
+    if (letValue!) throw 'incorrect value in "letValue"';
 
     if (newValue != null) throw 'incorrect initialization of "newValue"';
     newValue = true;
-    if (!newValue) throw 'incorrect value in "newValue"';
+    if (!newValue!) throw 'incorrect value in "newValue"';
     newValue = false;
-    if (newValue) throw 'incorrect value in "newValue"';
+    if (newValue!) throw 'incorrect value in "newValue"';
 
     if (nullValue != null) throw 'incorrect initialization of "nullValue"';
     nullValue = true;
-    if (!nullValue) throw 'incorrect value in "nullValue"';
+    if (!nullValue!) throw 'incorrect value in "nullValue"';
     nullValue = false;
-    if (nullValue) throw 'incorrect value in "nullValue"';
+    if (nullValue!) throw 'incorrect value in "nullValue"';
 
     if (packageValue != null)
       throw 'incorrect initialization of "packageValue"';
     packageValue = true;
-    if (!packageValue) throw 'incorrect value in "packageValue"';
+    if (!packageValue!) throw 'incorrect value in "packageValue"';
     packageValue = false;
-    if (packageValue) throw 'incorrect value in "packageValue"';
+    if (packageValue!) throw 'incorrect value in "packageValue"';
 
     if (privateValue != null)
       throw 'incorrect initialization of "privateValue"';
     privateValue = true;
-    if (!privateValue) throw 'incorrect value in "privateValue"';
+    if (!privateValue!) throw 'incorrect value in "privateValue"';
     privateValue = false;
-    if (privateValue) throw 'incorrect value in "privateValue"';
+    if (privateValue!) throw 'incorrect value in "privateValue"';
 
     if (protectedValue != null)
       throw 'incorrect initialization of "protectedValue"';
     protectedValue = true;
-    if (!protectedValue) throw 'incorrect value in "protectedValue"';
+    if (!protectedValue!) throw 'incorrect value in "protectedValue"';
     protectedValue = false;
-    if (protectedValue) throw 'incorrect value in "protectedValue"';
+    if (protectedValue!) throw 'incorrect value in "protectedValue"';
 
     if (publicValue != null) throw 'incorrect initialization of "publicValue"';
     publicValue = true;
-    if (!publicValue) throw 'incorrect value in "publicValue"';
+    if (!publicValue!) throw 'incorrect value in "publicValue"';
     publicValue = false;
-    if (publicValue) throw 'incorrect value in "publicValue"';
+    if (publicValue!) throw 'incorrect value in "publicValue"';
 
     if (returnValue != null) throw 'incorrect initialization of "returnValue"';
     returnValue = true;
-    if (!returnValue) throw 'incorrect value in "returnValue"';
+    if (!returnValue!) throw 'incorrect value in "returnValue"';
     returnValue = false;
-    if (returnValue) throw 'incorrect value in "returnValue"';
+    if (returnValue!) throw 'incorrect value in "returnValue"';
 
     if (staticValue != null) throw 'incorrect initialization of "staticValue"';
     staticValue = true;
-    if (!staticValue) throw 'incorrect value in "staticValue"';
+    if (!staticValue!) throw 'incorrect value in "staticValue"';
     staticValue = false;
-    if (staticValue) throw 'incorrect value in "staticValue"';
+    if (staticValue!) throw 'incorrect value in "staticValue"';
 
     if (superValue != null) throw 'incorrect initialization of "superValue"';
     superValue = true;
-    if (!superValue) throw 'incorrect value in "superValue"';
+    if (!superValue!) throw 'incorrect value in "superValue"';
     superValue = false;
-    if (superValue) throw 'incorrect value in "superValue"';
+    if (superValue!) throw 'incorrect value in "superValue"';
 
     if (switchValue != null) throw 'incorrect initialization of "switchValue"';
     switchValue = true;
-    if (!switchValue) throw 'incorrect value in "switchValue"';
+    if (!switchValue!) throw 'incorrect value in "switchValue"';
     switchValue = false;
-    if (switchValue) throw 'incorrect value in "switchValue"';
+    if (switchValue!) throw 'incorrect value in "switchValue"';
 
     if (thisValue != null) throw 'incorrect initialization of "thisValue"';
     thisValue = true;
-    if (!thisValue) throw 'incorrect value in "thisValue"';
+    if (!thisValue!) throw 'incorrect value in "thisValue"';
     thisValue = false;
-    if (thisValue) throw 'incorrect value in "thisValue"';
+    if (thisValue!) throw 'incorrect value in "thisValue"';
 
     if (throwValue != null) throw 'incorrect initialization of "throwValue"';
     throwValue = true;
-    if (!throwValue) throw 'incorrect value in "throwValue"';
+    if (!throwValue!) throw 'incorrect value in "throwValue"';
     throwValue = false;
-    if (throwValue) throw 'incorrect value in "throwValue"';
+    if (throwValue!) throw 'incorrect value in "throwValue"';
 
     if (trueValue != null) throw 'incorrect initialization of "trueValue"';
     trueValue = true;
-    if (!trueValue) throw 'incorrect value in "trueValue"';
+    if (!trueValue!) throw 'incorrect value in "trueValue"';
     trueValue = false;
-    if (trueValue) throw 'incorrect value in "trueValue"';
+    if (trueValue!) throw 'incorrect value in "trueValue"';
 
     if (tryValue != null) throw 'incorrect initialization of "tryValue"';
     tryValue = true;
-    if (!tryValue) throw 'incorrect value in "tryValue"';
+    if (!tryValue!) throw 'incorrect value in "tryValue"';
     tryValue = false;
-    if (tryValue) throw 'incorrect value in "tryValue"';
+    if (tryValue!) throw 'incorrect value in "tryValue"';
 
     if (typeofValue != null) throw 'incorrect initialization of "typeofValue"';
     typeofValue = true;
-    if (!typeofValue) throw 'incorrect value in "typeofValue"';
+    if (!typeofValue!) throw 'incorrect value in "typeofValue"';
     typeofValue = false;
-    if (typeofValue) throw 'incorrect value in "typeofValue"';
+    if (typeofValue!) throw 'incorrect value in "typeofValue"';
 
     if (varValue != null) throw 'incorrect initialization of "varValue"';
     varValue = true;
-    if (!varValue) throw 'incorrect value in "varValue"';
+    if (!varValue!) throw 'incorrect value in "varValue"';
     varValue = false;
-    if (varValue) throw 'incorrect value in "varValue"';
+    if (varValue!) throw 'incorrect value in "varValue"';
 
     if (voidValue != null) throw 'incorrect initialization of "voidValue"';
     voidValue = true;
-    if (!voidValue) throw 'incorrect value in "voidValue"';
+    if (!voidValue!) throw 'incorrect value in "voidValue"';
     voidValue = false;
-    if (voidValue) throw 'incorrect value in "voidValue"';
+    if (voidValue!) throw 'incorrect value in "voidValue"';
 
     if (whileValue != null) throw 'incorrect initialization of "whileValue"';
     whileValue = true;
-    if (!whileValue) throw 'incorrect value in "whileValue"';
+    if (!whileValue!) throw 'incorrect value in "whileValue"';
     whileValue = false;
-    if (whileValue) throw 'incorrect value in "whileValue"';
+    if (whileValue!) throw 'incorrect value in "whileValue"';
 
     if (withValue != null) throw 'incorrect initialization of "withValue"';
     withValue = true;
-    if (!withValue) throw 'incorrect value in "withValue"';
+    if (!withValue!) throw 'incorrect value in "withValue"';
     withValue = false;
-    if (withValue) throw 'incorrect value in "withValue"';
+    if (withValue!) throw 'incorrect value in "withValue"';
 
     if (yieldValue != null) throw 'incorrect initialization of "yieldValue"';
     yieldValue = true;
-    if (!yieldValue) throw 'incorrect value in "yieldValue"';
+    if (!yieldValue!) throw 'incorrect value in "yieldValue"';
     yieldValue = false;
-    if (yieldValue) throw 'incorrect value in "yieldValue"';
+    if (yieldValue!) throw 'incorrect value in "yieldValue"';
   }
 }
 
 class ClassWithOddNames {
-  bool breakValue;
-  bool caseValue;
-  bool catchValue;
-  bool classValue;
-  bool constValue;
-  bool continueValue;
-  bool debuggerValue;
-  bool defaultValue;
-  bool deleteValue;
-  bool doValue;
-  bool elseValue;
-  bool enumValue;
-  bool exportValue;
-  bool extendsValue;
-  bool falseValue;
-  bool finallyValue;
-  bool forValue;
-  bool functionValue;
-  bool ifValue;
-  bool implementsValue;
-  bool importValue;
-  bool inValue;
-  bool instanceofValue;
-  bool interfaceValue;
-  bool letValue;
-  bool newValue;
-  bool nullValue;
-  bool packageValue;
-  bool privateValue;
-  bool protectedValue;
-  bool publicValue;
-  bool returnValue;
-  bool staticValue;
-  bool superValue;
-  bool switchValue;
-  bool thisValue;
-  bool throwValue;
-  bool trueValue;
-  bool tryValue;
-  bool typeofValue;
-  bool varValue;
-  bool voidValue;
-  bool whileValue;
-  bool withValue;
-  bool yieldValue;
+  bool? breakValue;
+  bool? caseValue;
+  bool? catchValue;
+  bool? classValue;
+  bool? constValue;
+  bool? continueValue;
+  bool? debuggerValue;
+  bool? defaultValue;
+  bool? deleteValue;
+  bool? doValue;
+  bool? elseValue;
+  bool? enumValue;
+  bool? exportValue;
+  bool? extendsValue;
+  bool? falseValue;
+  bool? finallyValue;
+  bool? forValue;
+  bool? functionValue;
+  bool? ifValue;
+  bool? implementsValue;
+  bool? importValue;
+  bool? inValue;
+  bool? instanceofValue;
+  bool? interfaceValue;
+  bool? letValue;
+  bool? newValue;
+  bool? nullValue;
+  bool? packageValue;
+  bool? privateValue;
+  bool? protectedValue;
+  bool? publicValue;
+  bool? returnValue;
+  bool? staticValue;
+  bool? superValue;
+  bool? switchValue;
+  bool? thisValue;
+  bool? throwValue;
+  bool? trueValue;
+  bool? tryValue;
+  bool? typeofValue;
+  bool? varValue;
+  bool? voidValue;
+  bool? whileValue;
+  bool? withValue;
+  bool? yieldValue;
 
   void testMyFields() {
     if (breakValue != null) throw 'incorrect initialization of "breakValue"';
     breakValue = true;
-    if (!breakValue) throw 'incorrect value in "breakValue"';
+    if (!breakValue!) throw 'incorrect value in "breakValue"';
     breakValue = false;
-    if (breakValue) throw 'incorrect value in "breakValue"';
+    if (breakValue!) throw 'incorrect value in "breakValue"';
 
     if (caseValue != null) throw 'incorrect initialization of "caseValue"';
     caseValue = true;
-    if (!caseValue) throw 'incorrect value in "caseValue"';
+    if (!caseValue!) throw 'incorrect value in "caseValue"';
     caseValue = false;
-    if (caseValue) throw 'incorrect value in "caseValue"';
+    if (caseValue!) throw 'incorrect value in "caseValue"';
 
     if (catchValue != null) throw 'incorrect initialization of "catchValue"';
     catchValue = true;
-    if (!catchValue) throw 'incorrect value in "catchValue"';
+    if (!catchValue!) throw 'incorrect value in "catchValue"';
     catchValue = false;
-    if (catchValue) throw 'incorrect value in "catchValue"';
+    if (catchValue!) throw 'incorrect value in "catchValue"';
 
     if (classValue != null) throw 'incorrect initialization of "classValue"';
     classValue = true;
-    if (!classValue) throw 'incorrect value in "classValue"';
+    if (!classValue!) throw 'incorrect value in "classValue"';
     classValue = false;
-    if (classValue) throw 'incorrect value in "classValue"';
+    if (classValue!) throw 'incorrect value in "classValue"';
 
     if (constValue != null) throw 'incorrect initialization of "constValue"';
     constValue = true;
-    if (!constValue) throw 'incorrect value in "constValue"';
+    if (!constValue!) throw 'incorrect value in "constValue"';
     constValue = false;
-    if (constValue) throw 'incorrect value in "constValue"';
+    if (constValue!) throw 'incorrect value in "constValue"';
 
     if (continueValue != null)
       throw 'incorrect initialization of "continueValue"';
     continueValue = true;
-    if (!continueValue) throw 'incorrect value in "continueValue"';
+    if (!continueValue!) throw 'incorrect value in "continueValue"';
     continueValue = false;
-    if (continueValue) throw 'incorrect value in "continueValue"';
+    if (continueValue!) throw 'incorrect value in "continueValue"';
 
     if (debuggerValue != null)
       throw 'incorrect initialization of "debuggerValue"';
     debuggerValue = true;
-    if (!debuggerValue) throw 'incorrect value in "debuggerValue"';
+    if (!debuggerValue!) throw 'incorrect value in "debuggerValue"';
     debuggerValue = false;
-    if (debuggerValue) throw 'incorrect value in "debuggerValue"';
+    if (debuggerValue!) throw 'incorrect value in "debuggerValue"';
 
     if (defaultValue != null)
       throw 'incorrect initialization of "defaultValue"';
     defaultValue = true;
-    if (!defaultValue) throw 'incorrect value in "defaultValue"';
+    if (!defaultValue!) throw 'incorrect value in "defaultValue"';
     defaultValue = false;
-    if (defaultValue) throw 'incorrect value in "defaultValue"';
+    if (defaultValue!) throw 'incorrect value in "defaultValue"';
 
     if (deleteValue != null) throw 'incorrect initialization of "deleteValue"';
     deleteValue = true;
-    if (!deleteValue) throw 'incorrect value in "deleteValue"';
+    if (!deleteValue!) throw 'incorrect value in "deleteValue"';
     deleteValue = false;
-    if (deleteValue) throw 'incorrect value in "deleteValue"';
+    if (deleteValue!) throw 'incorrect value in "deleteValue"';
 
     if (doValue != null) throw 'incorrect initialization of "doValue"';
     doValue = true;
-    if (!doValue) throw 'incorrect value in "doValue"';
+    if (!doValue!) throw 'incorrect value in "doValue"';
     doValue = false;
-    if (doValue) throw 'incorrect value in "doValue"';
+    if (doValue!) throw 'incorrect value in "doValue"';
 
     if (elseValue != null) throw 'incorrect initialization of "elseValue"';
     elseValue = true;
-    if (!elseValue) throw 'incorrect value in "elseValue"';
+    if (!elseValue!) throw 'incorrect value in "elseValue"';
     elseValue = false;
-    if (elseValue) throw 'incorrect value in "elseValue"';
+    if (elseValue!) throw 'incorrect value in "elseValue"';
 
     if (enumValue != null) throw 'incorrect initialization of "enumValue"';
     enumValue = true;
-    if (!enumValue) throw 'incorrect value in "enumValue"';
+    if (!enumValue!) throw 'incorrect value in "enumValue"';
     enumValue = false;
-    if (enumValue) throw 'incorrect value in "enumValue"';
+    if (enumValue!) throw 'incorrect value in "enumValue"';
 
     if (exportValue != null) throw 'incorrect initialization of "exportValue"';
     exportValue = true;
-    if (!exportValue) throw 'incorrect value in "exportValue"';
+    if (!exportValue!) throw 'incorrect value in "exportValue"';
     exportValue = false;
-    if (exportValue) throw 'incorrect value in "exportValue"';
+    if (exportValue!) throw 'incorrect value in "exportValue"';
 
     if (extendsValue != null)
       throw 'incorrect initialization of "extendsValue"';
     extendsValue = true;
-    if (!extendsValue) throw 'incorrect value in "extendsValue"';
+    if (!extendsValue!) throw 'incorrect value in "extendsValue"';
     extendsValue = false;
-    if (extendsValue) throw 'incorrect value in "extendsValue"';
+    if (extendsValue!) throw 'incorrect value in "extendsValue"';
 
     if (falseValue != null) throw 'incorrect initialization of "falseValue"';
     falseValue = true;
-    if (!falseValue) throw 'incorrect value in "falseValue"';
+    if (!falseValue!) throw 'incorrect value in "falseValue"';
     falseValue = false;
-    if (falseValue) throw 'incorrect value in "falseValue"';
+    if (falseValue!) throw 'incorrect value in "falseValue"';
 
     if (finallyValue != null)
       throw 'incorrect initialization of "finallyValue"';
     finallyValue = true;
-    if (!finallyValue) throw 'incorrect value in "finallyValue"';
+    if (!finallyValue!) throw 'incorrect value in "finallyValue"';
     finallyValue = false;
-    if (finallyValue) throw 'incorrect value in "finallyValue"';
+    if (finallyValue!) throw 'incorrect value in "finallyValue"';
 
     if (forValue != null) throw 'incorrect initialization of "forValue"';
     forValue = true;
-    if (!forValue) throw 'incorrect value in "forValue"';
+    if (!forValue!) throw 'incorrect value in "forValue"';
     forValue = false;
-    if (forValue) throw 'incorrect value in "forValue"';
+    if (forValue!) throw 'incorrect value in "forValue"';
 
     if (functionValue != null)
       throw 'incorrect initialization of "functionValue"';
     functionValue = true;
-    if (!functionValue) throw 'incorrect value in "functionValue"';
+    if (!functionValue!) throw 'incorrect value in "functionValue"';
     functionValue = false;
-    if (functionValue) throw 'incorrect value in "functionValue"';
+    if (functionValue!) throw 'incorrect value in "functionValue"';
 
     if (ifValue != null) throw 'incorrect initialization of "ifValue"';
     ifValue = true;
-    if (!ifValue) throw 'incorrect value in "ifValue"';
+    if (!ifValue!) throw 'incorrect value in "ifValue"';
     ifValue = false;
-    if (ifValue) throw 'incorrect value in "ifValue"';
+    if (ifValue!) throw 'incorrect value in "ifValue"';
 
     if (implementsValue != null)
       throw 'incorrect initialization of "implementsValue"';
     implementsValue = true;
-    if (!implementsValue) throw 'incorrect value in "implementsValue"';
+    if (!implementsValue!) throw 'incorrect value in "implementsValue"';
     implementsValue = false;
-    if (implementsValue) throw 'incorrect value in "implementsValue"';
+    if (implementsValue!) throw 'incorrect value in "implementsValue"';
 
     if (importValue != null) throw 'incorrect initialization of "importValue"';
     importValue = true;
-    if (!importValue) throw 'incorrect value in "importValue"';
+    if (!importValue!) throw 'incorrect value in "importValue"';
     importValue = false;
-    if (importValue) throw 'incorrect value in "importValue"';
+    if (importValue!) throw 'incorrect value in "importValue"';
 
     if (inValue != null) throw 'incorrect initialization of "inValue"';
     inValue = true;
-    if (!inValue) throw 'incorrect value in "inValue"';
+    if (!inValue!) throw 'incorrect value in "inValue"';
     inValue = false;
-    if (inValue) throw 'incorrect value in "inValue"';
+    if (inValue!) throw 'incorrect value in "inValue"';
 
     if (instanceofValue != null)
       throw 'incorrect initialization of "instanceofValue"';
     instanceofValue = true;
-    if (!instanceofValue) throw 'incorrect value in "instanceofValue"';
+    if (!instanceofValue!) throw 'incorrect value in "instanceofValue"';
     instanceofValue = false;
-    if (instanceofValue) throw 'incorrect value in "instanceofValue"';
+    if (instanceofValue!) throw 'incorrect value in "instanceofValue"';
 
     if (interfaceValue != null)
       throw 'incorrect initialization of "interfaceValue"';
     interfaceValue = true;
-    if (!interfaceValue) throw 'incorrect value in "interfaceValue"';
+    if (!interfaceValue!) throw 'incorrect value in "interfaceValue"';
     interfaceValue = false;
-    if (interfaceValue) throw 'incorrect value in "interfaceValue"';
+    if (interfaceValue!) throw 'incorrect value in "interfaceValue"';
 
     if (letValue != null) throw 'incorrect initialization of "letValue"';
     letValue = true;
-    if (!letValue) throw 'incorrect value in "letValue"';
+    if (!letValue!) throw 'incorrect value in "letValue"';
     letValue = false;
-    if (letValue) throw 'incorrect value in "letValue"';
+    if (letValue!) throw 'incorrect value in "letValue"';
 
     if (newValue != null) throw 'incorrect initialization of "newValue"';
     newValue = true;
-    if (!newValue) throw 'incorrect value in "newValue"';
+    if (!newValue!) throw 'incorrect value in "newValue"';
     newValue = false;
-    if (newValue) throw 'incorrect value in "newValue"';
+    if (newValue!) throw 'incorrect value in "newValue"';
 
     if (nullValue != null) throw 'incorrect initialization of "nullValue"';
     nullValue = true;
-    if (!nullValue) throw 'incorrect value in "nullValue"';
+    if (!nullValue!) throw 'incorrect value in "nullValue"';
     nullValue = false;
-    if (nullValue) throw 'incorrect value in "nullValue"';
+    if (nullValue!) throw 'incorrect value in "nullValue"';
 
     if (packageValue != null)
       throw 'incorrect initialization of "packageValue"';
     packageValue = true;
-    if (!packageValue) throw 'incorrect value in "packageValue"';
+    if (!packageValue!) throw 'incorrect value in "packageValue"';
     packageValue = false;
-    if (packageValue) throw 'incorrect value in "packageValue"';
+    if (packageValue!) throw 'incorrect value in "packageValue"';
 
     if (privateValue != null)
       throw 'incorrect initialization of "privateValue"';
     privateValue = true;
-    if (!privateValue) throw 'incorrect value in "privateValue"';
+    if (!privateValue!) throw 'incorrect value in "privateValue"';
     privateValue = false;
-    if (privateValue) throw 'incorrect value in "privateValue"';
+    if (privateValue!) throw 'incorrect value in "privateValue"';
 
     if (protectedValue != null)
       throw 'incorrect initialization of "protectedValue"';
     protectedValue = true;
-    if (!protectedValue) throw 'incorrect value in "protectedValue"';
+    if (!protectedValue!) throw 'incorrect value in "protectedValue"';
     protectedValue = false;
-    if (protectedValue) throw 'incorrect value in "protectedValue"';
+    if (protectedValue!) throw 'incorrect value in "protectedValue"';
 
     if (publicValue != null) throw 'incorrect initialization of "publicValue"';
     publicValue = true;
-    if (!publicValue) throw 'incorrect value in "publicValue"';
+    if (!publicValue!) throw 'incorrect value in "publicValue"';
     publicValue = false;
-    if (publicValue) throw 'incorrect value in "publicValue"';
+    if (publicValue!) throw 'incorrect value in "publicValue"';
 
     if (returnValue != null) throw 'incorrect initialization of "returnValue"';
     returnValue = true;
-    if (!returnValue) throw 'incorrect value in "returnValue"';
+    if (!returnValue!) throw 'incorrect value in "returnValue"';
     returnValue = false;
-    if (returnValue) throw 'incorrect value in "returnValue"';
+    if (returnValue!) throw 'incorrect value in "returnValue"';
 
     if (staticValue != null) throw 'incorrect initialization of "staticValue"';
     staticValue = true;
-    if (!staticValue) throw 'incorrect value in "staticValue"';
+    if (!staticValue!) throw 'incorrect value in "staticValue"';
     staticValue = false;
-    if (staticValue) throw 'incorrect value in "staticValue"';
+    if (staticValue!) throw 'incorrect value in "staticValue"';
 
     if (superValue != null) throw 'incorrect initialization of "superValue"';
     superValue = true;
-    if (!superValue) throw 'incorrect value in "superValue"';
+    if (!superValue!) throw 'incorrect value in "superValue"';
     superValue = false;
-    if (superValue) throw 'incorrect value in "superValue"';
+    if (superValue!) throw 'incorrect value in "superValue"';
 
     if (switchValue != null) throw 'incorrect initialization of "switchValue"';
     switchValue = true;
-    if (!switchValue) throw 'incorrect value in "switchValue"';
+    if (!switchValue!) throw 'incorrect value in "switchValue"';
     switchValue = false;
-    if (switchValue) throw 'incorrect value in "switchValue"';
+    if (switchValue!) throw 'incorrect value in "switchValue"';
 
     if (thisValue != null) throw 'incorrect initialization of "thisValue"';
     thisValue = true;
-    if (!thisValue) throw 'incorrect value in "thisValue"';
+    if (!thisValue!) throw 'incorrect value in "thisValue"';
     thisValue = false;
-    if (thisValue) throw 'incorrect value in "thisValue"';
+    if (thisValue!) throw 'incorrect value in "thisValue"';
 
     if (throwValue != null) throw 'incorrect initialization of "throwValue"';
     throwValue = true;
-    if (!throwValue) throw 'incorrect value in "throwValue"';
+    if (!throwValue!) throw 'incorrect value in "throwValue"';
     throwValue = false;
-    if (throwValue) throw 'incorrect value in "throwValue"';
+    if (throwValue!) throw 'incorrect value in "throwValue"';
 
     if (trueValue != null) throw 'incorrect initialization of "trueValue"';
     trueValue = true;
-    if (!trueValue) throw 'incorrect value in "trueValue"';
+    if (!trueValue!) throw 'incorrect value in "trueValue"';
     trueValue = false;
-    if (trueValue) throw 'incorrect value in "trueValue"';
+    if (trueValue!) throw 'incorrect value in "trueValue"';
 
     if (tryValue != null) throw 'incorrect initialization of "tryValue"';
     tryValue = true;
-    if (!tryValue) throw 'incorrect value in "tryValue"';
+    if (!tryValue!) throw 'incorrect value in "tryValue"';
     tryValue = false;
-    if (tryValue) throw 'incorrect value in "tryValue"';
+    if (tryValue!) throw 'incorrect value in "tryValue"';
 
     if (typeofValue != null) throw 'incorrect initialization of "typeofValue"';
     typeofValue = true;
-    if (!typeofValue) throw 'incorrect value in "typeofValue"';
+    if (!typeofValue!) throw 'incorrect value in "typeofValue"';
     typeofValue = false;
-    if (typeofValue) throw 'incorrect value in "typeofValue"';
+    if (typeofValue!) throw 'incorrect value in "typeofValue"';
 
     if (varValue != null) throw 'incorrect initialization of "varValue"';
     varValue = true;
-    if (!varValue) throw 'incorrect value in "varValue"';
+    if (!varValue!) throw 'incorrect value in "varValue"';
     varValue = false;
-    if (varValue) throw 'incorrect value in "varValue"';
+    if (varValue!) throw 'incorrect value in "varValue"';
 
     if (voidValue != null) throw 'incorrect initialization of "voidValue"';
     voidValue = true;
-    if (!voidValue) throw 'incorrect value in "voidValue"';
+    if (!voidValue!) throw 'incorrect value in "voidValue"';
     voidValue = false;
-    if (voidValue) throw 'incorrect value in "voidValue"';
+    if (voidValue!) throw 'incorrect value in "voidValue"';
 
     if (whileValue != null) throw 'incorrect initialization of "whileValue"';
     whileValue = true;
-    if (!whileValue) throw 'incorrect value in "whileValue"';
+    if (!whileValue!) throw 'incorrect value in "whileValue"';
     whileValue = false;
-    if (whileValue) throw 'incorrect value in "whileValue"';
+    if (whileValue!) throw 'incorrect value in "whileValue"';
 
     if (withValue != null) throw 'incorrect initialization of "withValue"';
     withValue = true;
-    if (!withValue) throw 'incorrect value in "withValue"';
+    if (!withValue!) throw 'incorrect value in "withValue"';
     withValue = false;
-    if (withValue) throw 'incorrect value in "withValue"';
+    if (withValue!) throw 'incorrect value in "withValue"';
 
     if (yieldValue != null) throw 'incorrect initialization of "yieldValue"';
     yieldValue = true;
-    if (!yieldValue) throw 'incorrect value in "yieldValue"';
+    if (!yieldValue!) throw 'incorrect value in "yieldValue"';
     yieldValue = false;
-    if (yieldValue) throw 'incorrect value in "yieldValue"';
+    if (yieldValue!) throw 'incorrect value in "yieldValue"';
   }
 }
 
@@ -777,301 +777,301 @@
   if (object.breakValue == null)
     throw 'incorrect initialization of "breakValue"';
   object.breakValue = true;
-  if (!object.breakValue) throw 'incorrect value in "breakValue"';
+  if (!object.breakValue!) throw 'incorrect value in "breakValue"';
   object.breakValue = false;
-  if (object.breakValue) throw 'incorrect value in "breakValue"';
+  if (object.breakValue!) throw 'incorrect value in "breakValue"';
 
   if (object.caseValue == null) throw 'incorrect initialization of "caseValue"';
   object.caseValue = true;
-  if (!object.caseValue) throw 'incorrect value in "caseValue"';
+  if (!object.caseValue!) throw 'incorrect value in "caseValue"';
   object.caseValue = false;
-  if (object.caseValue) throw 'incorrect value in "caseValue"';
+  if (object.caseValue!) throw 'incorrect value in "caseValue"';
 
   if (object.catchValue == null)
     throw 'incorrect initialization of "catchValue"';
   object.catchValue = true;
-  if (!object.catchValue) throw 'incorrect value in "catchValue"';
+  if (!object.catchValue!) throw 'incorrect value in "catchValue"';
   object.catchValue = false;
-  if (object.catchValue) throw 'incorrect value in "catchValue"';
+  if (object.catchValue!) throw 'incorrect value in "catchValue"';
 
   if (object.classValue == null)
     throw 'incorrect initialization of "classValue"';
   object.classValue = true;
-  if (!object.classValue) throw 'incorrect value in "classValue"';
+  if (!object.classValue!) throw 'incorrect value in "classValue"';
   object.classValue = false;
-  if (object.classValue) throw 'incorrect value in "classValue"';
+  if (object.classValue!) throw 'incorrect value in "classValue"';
 
   if (object.constValue == null)
     throw 'incorrect initialization of "constValue"';
   object.constValue = true;
-  if (!object.constValue) throw 'incorrect value in "constValue"';
+  if (!object.constValue!) throw 'incorrect value in "constValue"';
   object.constValue = false;
-  if (object.constValue) throw 'incorrect value in "constValue"';
+  if (object.constValue!) throw 'incorrect value in "constValue"';
 
   if (object.continueValue == null)
     throw 'incorrect initialization of "continueValue"';
   object.continueValue = true;
-  if (!object.continueValue) throw 'incorrect value in "continueValue"';
+  if (!object.continueValue!) throw 'incorrect value in "continueValue"';
   object.continueValue = false;
-  if (object.continueValue) throw 'incorrect value in "continueValue"';
+  if (object.continueValue!) throw 'incorrect value in "continueValue"';
 
   if (object.debuggerValue == null)
     throw 'incorrect initialization of "debuggerValue"';
   object.debuggerValue = true;
-  if (!object.debuggerValue) throw 'incorrect value in "debuggerValue"';
+  if (!object.debuggerValue!) throw 'incorrect value in "debuggerValue"';
   object.debuggerValue = false;
-  if (object.debuggerValue) throw 'incorrect value in "debuggerValue"';
+  if (object.debuggerValue!) throw 'incorrect value in "debuggerValue"';
 
   if (object.defaultValue == null)
     throw 'incorrect initialization of "defaultValue"';
   object.defaultValue = true;
-  if (!object.defaultValue) throw 'incorrect value in "defaultValue"';
+  if (!object.defaultValue!) throw 'incorrect value in "defaultValue"';
   object.defaultValue = false;
-  if (object.defaultValue) throw 'incorrect value in "defaultValue"';
+  if (object.defaultValue!) throw 'incorrect value in "defaultValue"';
 
   if (object.deleteValue == null)
     throw 'incorrect initialization of "deleteValue"';
   object.deleteValue = true;
-  if (!object.deleteValue) throw 'incorrect value in "deleteValue"';
+  if (!object.deleteValue!) throw 'incorrect value in "deleteValue"';
   object.deleteValue = false;
-  if (object.deleteValue) throw 'incorrect value in "deleteValue"';
+  if (object.deleteValue!) throw 'incorrect value in "deleteValue"';
 
   if (object.doValue == null) throw 'incorrect initialization of "doValue"';
   object.doValue = true;
-  if (!object.doValue) throw 'incorrect value in "doValue"';
+  if (!object.doValue!) throw 'incorrect value in "doValue"';
   object.doValue = false;
-  if (object.doValue) throw 'incorrect value in "doValue"';
+  if (object.doValue!) throw 'incorrect value in "doValue"';
 
   if (object.elseValue == null) throw 'incorrect initialization of "elseValue"';
   object.elseValue = true;
-  if (!object.elseValue) throw 'incorrect value in "elseValue"';
+  if (!object.elseValue!) throw 'incorrect value in "elseValue"';
   object.elseValue = false;
-  if (object.elseValue) throw 'incorrect value in "elseValue"';
+  if (object.elseValue!) throw 'incorrect value in "elseValue"';
 
   if (object.enumValue == null) throw 'incorrect initialization of "enumValue"';
   object.enumValue = true;
-  if (!object.enumValue) throw 'incorrect value in "enumValue"';
+  if (!object.enumValue!) throw 'incorrect value in "enumValue"';
   object.enumValue = false;
-  if (object.enumValue) throw 'incorrect value in "enumValue"';
+  if (object.enumValue!) throw 'incorrect value in "enumValue"';
 
   if (object.exportValue == null)
     throw 'incorrect initialization of "exportValue"';
   object.exportValue = true;
-  if (!object.exportValue) throw 'incorrect value in "exportValue"';
+  if (!object.exportValue!) throw 'incorrect value in "exportValue"';
   object.exportValue = false;
-  if (object.exportValue) throw 'incorrect value in "exportValue"';
+  if (object.exportValue!) throw 'incorrect value in "exportValue"';
 
   if (object.extendsValue == null)
     throw 'incorrect initialization of "extendsValue"';
   object.extendsValue = true;
-  if (!object.extendsValue) throw 'incorrect value in "extendsValue"';
+  if (!object.extendsValue!) throw 'incorrect value in "extendsValue"';
   object.extendsValue = false;
-  if (object.extendsValue) throw 'incorrect value in "extendsValue"';
+  if (object.extendsValue!) throw 'incorrect value in "extendsValue"';
 
   if (object.falseValue == null)
     throw 'incorrect initialization of "falseValue"';
   object.falseValue = true;
-  if (!object.falseValue) throw 'incorrect value in "falseValue"';
+  if (!object.falseValue!) throw 'incorrect value in "falseValue"';
   object.falseValue = false;
-  if (object.falseValue) throw 'incorrect value in "falseValue"';
+  if (object.falseValue!) throw 'incorrect value in "falseValue"';
 
   if (object.finallyValue == null)
     throw 'incorrect initialization of "finallyValue"';
   object.finallyValue = true;
-  if (!object.finallyValue) throw 'incorrect value in "finallyValue"';
+  if (!object.finallyValue!) throw 'incorrect value in "finallyValue"';
   object.finallyValue = false;
-  if (object.finallyValue) throw 'incorrect value in "finallyValue"';
+  if (object.finallyValue!) throw 'incorrect value in "finallyValue"';
 
   if (object.forValue == null) throw 'incorrect initialization of "forValue"';
   object.forValue = true;
-  if (!object.forValue) throw 'incorrect value in "forValue"';
+  if (!object.forValue!) throw 'incorrect value in "forValue"';
   object.forValue = false;
-  if (object.forValue) throw 'incorrect value in "forValue"';
+  if (object.forValue!) throw 'incorrect value in "forValue"';
 
   if (object.functionValue == null)
     throw 'incorrect initialization of "functionValue"';
   object.functionValue = true;
-  if (!object.functionValue) throw 'incorrect value in "functionValue"';
+  if (!object.functionValue!) throw 'incorrect value in "functionValue"';
   object.functionValue = false;
-  if (object.functionValue) throw 'incorrect value in "functionValue"';
+  if (object.functionValue!) throw 'incorrect value in "functionValue"';
 
   if (object.ifValue == null) throw 'incorrect initialization of "ifValue"';
   object.ifValue = true;
-  if (!object.ifValue) throw 'incorrect value in "ifValue"';
+  if (!object.ifValue!) throw 'incorrect value in "ifValue"';
   object.ifValue = false;
-  if (object.ifValue) throw 'incorrect value in "ifValue"';
+  if (object.ifValue!) throw 'incorrect value in "ifValue"';
 
   if (object.implementsValue == null)
     throw 'incorrect initialization of "implementsValue"';
   object.implementsValue = true;
-  if (!object.implementsValue) throw 'incorrect value in "implementsValue"';
+  if (!object.implementsValue!) throw 'incorrect value in "implementsValue"';
   object.implementsValue = false;
-  if (object.implementsValue) throw 'incorrect value in "implementsValue"';
+  if (object.implementsValue!) throw 'incorrect value in "implementsValue"';
 
   if (object.importValue == null)
     throw 'incorrect initialization of "importValue"';
   object.importValue = true;
-  if (!object.importValue) throw 'incorrect value in "importValue"';
+  if (!object.importValue!) throw 'incorrect value in "importValue"';
   object.importValue = false;
-  if (object.importValue) throw 'incorrect value in "importValue"';
+  if (object.importValue!) throw 'incorrect value in "importValue"';
 
   if (object.inValue == null) throw 'incorrect initialization of "inValue"';
   object.inValue = true;
-  if (!object.inValue) throw 'incorrect value in "inValue"';
+  if (!object.inValue!) throw 'incorrect value in "inValue"';
   object.inValue = false;
-  if (object.inValue) throw 'incorrect value in "inValue"';
+  if (object.inValue!) throw 'incorrect value in "inValue"';
 
   if (object.instanceofValue == null)
     throw 'incorrect initialization of "instanceofValue"';
   object.instanceofValue = true;
-  if (!object.instanceofValue) throw 'incorrect value in "instanceofValue"';
+  if (!object.instanceofValue!) throw 'incorrect value in "instanceofValue"';
   object.instanceofValue = false;
-  if (object.instanceofValue) throw 'incorrect value in "instanceofValue"';
+  if (object.instanceofValue!) throw 'incorrect value in "instanceofValue"';
 
   if (object.interfaceValue == null)
     throw 'incorrect initialization of "interfaceValue"';
   object.interfaceValue = true;
-  if (!object.interfaceValue) throw 'incorrect value in "interfaceValue"';
+  if (!object.interfaceValue!) throw 'incorrect value in "interfaceValue"';
   object.interfaceValue = false;
-  if (object.interfaceValue) throw 'incorrect value in "interfaceValue"';
+  if (object.interfaceValue!) throw 'incorrect value in "interfaceValue"';
 
   if (object.letValue == null) throw 'incorrect initialization of "letValue"';
   object.letValue = true;
-  if (!object.letValue) throw 'incorrect value in "letValue"';
+  if (!object.letValue!) throw 'incorrect value in "letValue"';
   object.letValue = false;
-  if (object.letValue) throw 'incorrect value in "letValue"';
+  if (object.letValue!) throw 'incorrect value in "letValue"';
 
   if (object.newValue == null) throw 'incorrect initialization of "newValue"';
   object.newValue = true;
-  if (!object.newValue) throw 'incorrect value in "newValue"';
+  if (!object.newValue!) throw 'incorrect value in "newValue"';
   object.newValue = false;
-  if (object.newValue) throw 'incorrect value in "newValue"';
+  if (object.newValue!) throw 'incorrect value in "newValue"';
 
   if (object.nullValue == null) throw 'incorrect initialization of "nullValue"';
   object.nullValue = true;
-  if (!object.nullValue) throw 'incorrect value in "nullValue"';
+  if (!object.nullValue!) throw 'incorrect value in "nullValue"';
   object.nullValue = false;
-  if (object.nullValue) throw 'incorrect value in "nullValue"';
+  if (object.nullValue!) throw 'incorrect value in "nullValue"';
 
   if (object.packageValue == null)
     throw 'incorrect initialization of "packageValue"';
   object.packageValue = true;
-  if (!object.packageValue) throw 'incorrect value in "packageValue"';
+  if (!object.packageValue!) throw 'incorrect value in "packageValue"';
   object.packageValue = false;
-  if (object.packageValue) throw 'incorrect value in "packageValue"';
+  if (object.packageValue!) throw 'incorrect value in "packageValue"';
 
   if (object.privateValue == null)
     throw 'incorrect initialization of "privateValue"';
   object.privateValue = true;
-  if (!object.privateValue) throw 'incorrect value in "privateValue"';
+  if (!object.privateValue!) throw 'incorrect value in "privateValue"';
   object.privateValue = false;
-  if (object.privateValue) throw 'incorrect value in "privateValue"';
+  if (object.privateValue!) throw 'incorrect value in "privateValue"';
 
   if (object.protectedValue == null)
     throw 'incorrect initialization of "protectedValue"';
   object.protectedValue = true;
-  if (!object.protectedValue) throw 'incorrect value in "protectedValue"';
+  if (!object.protectedValue!) throw 'incorrect value in "protectedValue"';
   object.protectedValue = false;
-  if (object.protectedValue) throw 'incorrect value in "protectedValue"';
+  if (object.protectedValue!) throw 'incorrect value in "protectedValue"';
 
   if (object.publicValue == null)
     throw 'incorrect initialization of "publicValue"';
   object.publicValue = true;
-  if (!object.publicValue) throw 'incorrect value in "publicValue"';
+  if (!object.publicValue!) throw 'incorrect value in "publicValue"';
   object.publicValue = false;
-  if (object.publicValue) throw 'incorrect value in "publicValue"';
+  if (object.publicValue!) throw 'incorrect value in "publicValue"';
 
   if (object.returnValue == null)
     throw 'incorrect initialization of "returnValue"';
   object.returnValue = true;
-  if (!object.returnValue) throw 'incorrect value in "returnValue"';
+  if (!object.returnValue!) throw 'incorrect value in "returnValue"';
   object.returnValue = false;
-  if (object.returnValue) throw 'incorrect value in "returnValue"';
+  if (object.returnValue!) throw 'incorrect value in "returnValue"';
 
   if (object.staticValue == null)
     throw 'incorrect initialization of "staticValue"';
   object.staticValue = true;
-  if (!object.staticValue) throw 'incorrect value in "staticValue"';
+  if (!object.staticValue!) throw 'incorrect value in "staticValue"';
   object.staticValue = false;
-  if (object.staticValue) throw 'incorrect value in "staticValue"';
+  if (object.staticValue!) throw 'incorrect value in "staticValue"';
 
   if (object.superValue == null)
     throw 'incorrect initialization of "superValue"';
   object.superValue = true;
-  if (!object.superValue) throw 'incorrect value in "superValue"';
+  if (!object.superValue!) throw 'incorrect value in "superValue"';
   object.superValue = false;
-  if (object.superValue) throw 'incorrect value in "superValue"';
+  if (object.superValue!) throw 'incorrect value in "superValue"';
 
   if (object.switchValue == null)
     throw 'incorrect initialization of "switchValue"';
   object.switchValue = true;
-  if (!object.switchValue) throw 'incorrect value in "switchValue"';
+  if (!object.switchValue!) throw 'incorrect value in "switchValue"';
   object.switchValue = false;
-  if (object.switchValue) throw 'incorrect value in "switchValue"';
+  if (object.switchValue!) throw 'incorrect value in "switchValue"';
 
   if (object.thisValue == null) throw 'incorrect initialization of "thisValue"';
   object.thisValue = true;
-  if (!object.thisValue) throw 'incorrect value in "thisValue"';
+  if (!object.thisValue!) throw 'incorrect value in "thisValue"';
   object.thisValue = false;
-  if (object.thisValue) throw 'incorrect value in "thisValue"';
+  if (object.thisValue!) throw 'incorrect value in "thisValue"';
 
   if (object.throwValue == null)
     throw 'incorrect initialization of "throwValue"';
   object.throwValue = true;
-  if (!object.throwValue) throw 'incorrect value in "throwValue"';
+  if (!object.throwValue!) throw 'incorrect value in "throwValue"';
   object.throwValue = false;
-  if (object.throwValue) throw 'incorrect value in "throwValue"';
+  if (object.throwValue!) throw 'incorrect value in "throwValue"';
 
   if (object.trueValue == null) throw 'incorrect initialization of "trueValue"';
   object.trueValue = true;
-  if (!object.trueValue) throw 'incorrect value in "trueValue"';
+  if (!object.trueValue!) throw 'incorrect value in "trueValue"';
   object.trueValue = false;
-  if (object.trueValue) throw 'incorrect value in "trueValue"';
+  if (object.trueValue!) throw 'incorrect value in "trueValue"';
 
   if (object.tryValue == null) throw 'incorrect initialization of "tryValue"';
   object.tryValue = true;
-  if (!object.tryValue) throw 'incorrect value in "tryValue"';
+  if (!object.tryValue!) throw 'incorrect value in "tryValue"';
   object.tryValue = false;
-  if (object.tryValue) throw 'incorrect value in "tryValue"';
+  if (object.tryValue!) throw 'incorrect value in "tryValue"';
 
   if (object.typeofValue == null)
     throw 'incorrect initialization of "typeofValue"';
   object.typeofValue = true;
-  if (!object.typeofValue) throw 'incorrect value in "typeofValue"';
+  if (!object.typeofValue!) throw 'incorrect value in "typeofValue"';
   object.typeofValue = false;
-  if (object.typeofValue) throw 'incorrect value in "typeofValue"';
+  if (object.typeofValue!) throw 'incorrect value in "typeofValue"';
 
   if (object.varValue == null) throw 'incorrect initialization of "varValue"';
   object.varValue = true;
-  if (!object.varValue) throw 'incorrect value in "varValue"';
+  if (!object.varValue!) throw 'incorrect value in "varValue"';
   object.varValue = false;
-  if (object.varValue) throw 'incorrect value in "varValue"';
+  if (object.varValue!) throw 'incorrect value in "varValue"';
 
   if (object.voidValue == null) throw 'incorrect initialization of "voidValue"';
   object.voidValue = true;
-  if (!object.voidValue) throw 'incorrect value in "voidValue"';
+  if (!object.voidValue!) throw 'incorrect value in "voidValue"';
   object.voidValue = false;
-  if (object.voidValue) throw 'incorrect value in "voidValue"';
+  if (object.voidValue!) throw 'incorrect value in "voidValue"';
 
   if (object.whileValue == null)
     throw 'incorrect initialization of "whileValue"';
   object.whileValue = true;
-  if (!object.whileValue) throw 'incorrect value in "whileValue"';
+  if (!object.whileValue!) throw 'incorrect value in "whileValue"';
   object.whileValue = false;
-  if (object.whileValue) throw 'incorrect value in "whileValue"';
+  if (object.whileValue!) throw 'incorrect value in "whileValue"';
 
   if (object.withValue == null) throw 'incorrect initialization of "withValue"';
   object.withValue = true;
-  if (!object.withValue) throw 'incorrect value in "withValue"';
+  if (!object.withValue!) throw 'incorrect value in "withValue"';
   object.withValue = false;
-  if (object.withValue) throw 'incorrect value in "withValue"';
+  if (object.withValue!) throw 'incorrect value in "withValue"';
 
   if (object.yieldValue == null)
     throw 'incorrect initialization of "yieldValue"';
   object.yieldValue = true;
-  if (!object.yieldValue) throw 'incorrect value in "yieldValue"';
+  if (!object.yieldValue!) throw 'incorrect value in "yieldValue"';
   object.yieldValue = false;
-  if (object.yieldValue) throw 'incorrect value in "yieldValue"';
+  if (object.yieldValue!) throw 'incorrect value in "yieldValue"';
 }
 
 /// Called multiple times with arguments that are hard to track in type
@@ -1082,301 +1082,301 @@
   if (object.breakValue == null)
     throw 'incorrect initialization of "breakValue"';
   object.breakValue = true;
-  if (!object.breakValue) throw 'incorrect value in "breakValue"';
+  if (!object.breakValue!) throw 'incorrect value in "breakValue"';
   object.breakValue = false;
-  if (object.breakValue) throw 'incorrect value in "breakValue"';
+  if (object.breakValue!) throw 'incorrect value in "breakValue"';
 
   if (object.caseValue == null) throw 'incorrect initialization of "caseValue"';
   object.caseValue = true;
-  if (!object.caseValue) throw 'incorrect value in "caseValue"';
+  if (!object.caseValue!) throw 'incorrect value in "caseValue"';
   object.caseValue = false;
-  if (object.caseValue) throw 'incorrect value in "caseValue"';
+  if (object.caseValue!) throw 'incorrect value in "caseValue"';
 
   if (object.catchValue == null)
     throw 'incorrect initialization of "catchValue"';
   object.catchValue = true;
-  if (!object.catchValue) throw 'incorrect value in "catchValue"';
+  if (!object.catchValue!) throw 'incorrect value in "catchValue"';
   object.catchValue = false;
-  if (object.catchValue) throw 'incorrect value in "catchValue"';
+  if (object.catchValue!) throw 'incorrect value in "catchValue"';
 
   if (object.classValue == null)
     throw 'incorrect initialization of "classValue"';
   object.classValue = true;
-  if (!object.classValue) throw 'incorrect value in "classValue"';
+  if (!object.classValue!) throw 'incorrect value in "classValue"';
   object.classValue = false;
-  if (object.classValue) throw 'incorrect value in "classValue"';
+  if (object.classValue!) throw 'incorrect value in "classValue"';
 
   if (object.constValue == null)
     throw 'incorrect initialization of "constValue"';
   object.constValue = true;
-  if (!object.constValue) throw 'incorrect value in "constValue"';
+  if (!object.constValue!) throw 'incorrect value in "constValue"';
   object.constValue = false;
-  if (object.constValue) throw 'incorrect value in "constValue"';
+  if (object.constValue!) throw 'incorrect value in "constValue"';
 
   if (object.continueValue == null)
     throw 'incorrect initialization of "continueValue"';
   object.continueValue = true;
-  if (!object.continueValue) throw 'incorrect value in "continueValue"';
+  if (!object.continueValue!) throw 'incorrect value in "continueValue"';
   object.continueValue = false;
-  if (object.continueValue) throw 'incorrect value in "continueValue"';
+  if (object.continueValue!) throw 'incorrect value in "continueValue"';
 
   if (object.debuggerValue == null)
     throw 'incorrect initialization of "debuggerValue"';
   object.debuggerValue = true;
-  if (!object.debuggerValue) throw 'incorrect value in "debuggerValue"';
+  if (!object.debuggerValue!) throw 'incorrect value in "debuggerValue"';
   object.debuggerValue = false;
-  if (object.debuggerValue) throw 'incorrect value in "debuggerValue"';
+  if (object.debuggerValue!) throw 'incorrect value in "debuggerValue"';
 
   if (object.defaultValue == null)
     throw 'incorrect initialization of "defaultValue"';
   object.defaultValue = true;
-  if (!object.defaultValue) throw 'incorrect value in "defaultValue"';
+  if (!object.defaultValue!) throw 'incorrect value in "defaultValue"';
   object.defaultValue = false;
-  if (object.defaultValue) throw 'incorrect value in "defaultValue"';
+  if (object.defaultValue!) throw 'incorrect value in "defaultValue"';
 
   if (object.deleteValue == null)
     throw 'incorrect initialization of "deleteValue"';
   object.deleteValue = true;
-  if (!object.deleteValue) throw 'incorrect value in "deleteValue"';
+  if (!object.deleteValue!) throw 'incorrect value in "deleteValue"';
   object.deleteValue = false;
-  if (object.deleteValue) throw 'incorrect value in "deleteValue"';
+  if (object.deleteValue!) throw 'incorrect value in "deleteValue"';
 
   if (object.doValue == null) throw 'incorrect initialization of "doValue"';
   object.doValue = true;
-  if (!object.doValue) throw 'incorrect value in "doValue"';
+  if (!object.doValue!) throw 'incorrect value in "doValue"';
   object.doValue = false;
-  if (object.doValue) throw 'incorrect value in "doValue"';
+  if (object.doValue!) throw 'incorrect value in "doValue"';
 
   if (object.elseValue == null) throw 'incorrect initialization of "elseValue"';
   object.elseValue = true;
-  if (!object.elseValue) throw 'incorrect value in "elseValue"';
+  if (!object.elseValue!) throw 'incorrect value in "elseValue"';
   object.elseValue = false;
-  if (object.elseValue) throw 'incorrect value in "elseValue"';
+  if (object.elseValue!) throw 'incorrect value in "elseValue"';
 
   if (object.enumValue == null) throw 'incorrect initialization of "enumValue"';
   object.enumValue = true;
-  if (!object.enumValue) throw 'incorrect value in "enumValue"';
+  if (!object.enumValue!) throw 'incorrect value in "enumValue"';
   object.enumValue = false;
-  if (object.enumValue) throw 'incorrect value in "enumValue"';
+  if (object.enumValue!) throw 'incorrect value in "enumValue"';
 
   if (object.exportValue == null)
     throw 'incorrect initialization of "exportValue"';
   object.exportValue = true;
-  if (!object.exportValue) throw 'incorrect value in "exportValue"';
+  if (!object.exportValue!) throw 'incorrect value in "exportValue"';
   object.exportValue = false;
-  if (object.exportValue) throw 'incorrect value in "exportValue"';
+  if (object.exportValue!) throw 'incorrect value in "exportValue"';
 
   if (object.extendsValue == null)
     throw 'incorrect initialization of "extendsValue"';
   object.extendsValue = true;
-  if (!object.extendsValue) throw 'incorrect value in "extendsValue"';
+  if (!object.extendsValue!) throw 'incorrect value in "extendsValue"';
   object.extendsValue = false;
-  if (object.extendsValue) throw 'incorrect value in "extendsValue"';
+  if (object.extendsValue!) throw 'incorrect value in "extendsValue"';
 
   if (object.falseValue == null)
     throw 'incorrect initialization of "falseValue"';
   object.falseValue = true;
-  if (!object.falseValue) throw 'incorrect value in "falseValue"';
+  if (!object.falseValue!) throw 'incorrect value in "falseValue"';
   object.falseValue = false;
-  if (object.falseValue) throw 'incorrect value in "falseValue"';
+  if (object.falseValue!) throw 'incorrect value in "falseValue"';
 
   if (object.finallyValue == null)
     throw 'incorrect initialization of "finallyValue"';
   object.finallyValue = true;
-  if (!object.finallyValue) throw 'incorrect value in "finallyValue"';
+  if (!object.finallyValue!) throw 'incorrect value in "finallyValue"';
   object.finallyValue = false;
-  if (object.finallyValue) throw 'incorrect value in "finallyValue"';
+  if (object.finallyValue!) throw 'incorrect value in "finallyValue"';
 
   if (object.forValue == null) throw 'incorrect initialization of "forValue"';
   object.forValue = true;
-  if (!object.forValue) throw 'incorrect value in "forValue"';
+  if (!object.forValue!) throw 'incorrect value in "forValue"';
   object.forValue = false;
-  if (object.forValue) throw 'incorrect value in "forValue"';
+  if (object.forValue!) throw 'incorrect value in "forValue"';
 
   if (object.functionValue == null)
     throw 'incorrect initialization of "functionValue"';
   object.functionValue = true;
-  if (!object.functionValue) throw 'incorrect value in "functionValue"';
+  if (!object.functionValue!) throw 'incorrect value in "functionValue"';
   object.functionValue = false;
-  if (object.functionValue) throw 'incorrect value in "functionValue"';
+  if (object.functionValue!) throw 'incorrect value in "functionValue"';
 
   if (object.ifValue == null) throw 'incorrect initialization of "ifValue"';
   object.ifValue = true;
-  if (!object.ifValue) throw 'incorrect value in "ifValue"';
+  if (!object.ifValue!) throw 'incorrect value in "ifValue"';
   object.ifValue = false;
-  if (object.ifValue) throw 'incorrect value in "ifValue"';
+  if (object.ifValue!) throw 'incorrect value in "ifValue"';
 
   if (object.implementsValue == null)
     throw 'incorrect initialization of "implementsValue"';
   object.implementsValue = true;
-  if (!object.implementsValue) throw 'incorrect value in "implementsValue"';
+  if (!object.implementsValue!) throw 'incorrect value in "implementsValue"';
   object.implementsValue = false;
-  if (object.implementsValue) throw 'incorrect value in "implementsValue"';
+  if (object.implementsValue!) throw 'incorrect value in "implementsValue"';
 
   if (object.importValue == null)
     throw 'incorrect initialization of "importValue"';
   object.importValue = true;
-  if (!object.importValue) throw 'incorrect value in "importValue"';
+  if (!object.importValue!) throw 'incorrect value in "importValue"';
   object.importValue = false;
-  if (object.importValue) throw 'incorrect value in "importValue"';
+  if (object.importValue!) throw 'incorrect value in "importValue"';
 
   if (object.inValue == null) throw 'incorrect initialization of "inValue"';
   object.inValue = true;
-  if (!object.inValue) throw 'incorrect value in "inValue"';
+  if (!object.inValue!) throw 'incorrect value in "inValue"';
   object.inValue = false;
-  if (object.inValue) throw 'incorrect value in "inValue"';
+  if (object.inValue!) throw 'incorrect value in "inValue"';
 
   if (object.instanceofValue == null)
     throw 'incorrect initialization of "instanceofValue"';
   object.instanceofValue = true;
-  if (!object.instanceofValue) throw 'incorrect value in "instanceofValue"';
+  if (!object.instanceofValue!) throw 'incorrect value in "instanceofValue"';
   object.instanceofValue = false;
-  if (object.instanceofValue) throw 'incorrect value in "instanceofValue"';
+  if (object.instanceofValue!) throw 'incorrect value in "instanceofValue"';
 
   if (object.interfaceValue == null)
     throw 'incorrect initialization of "interfaceValue"';
   object.interfaceValue = true;
-  if (!object.interfaceValue) throw 'incorrect value in "interfaceValue"';
+  if (!object.interfaceValue!) throw 'incorrect value in "interfaceValue"';
   object.interfaceValue = false;
-  if (object.interfaceValue) throw 'incorrect value in "interfaceValue"';
+  if (object.interfaceValue!) throw 'incorrect value in "interfaceValue"';
 
   if (object.letValue == null) throw 'incorrect initialization of "letValue"';
   object.letValue = true;
-  if (!object.letValue) throw 'incorrect value in "letValue"';
+  if (!object.letValue!) throw 'incorrect value in "letValue"';
   object.letValue = false;
-  if (object.letValue) throw 'incorrect value in "letValue"';
+  if (object.letValue!) throw 'incorrect value in "letValue"';
 
   if (object.newValue == null) throw 'incorrect initialization of "newValue"';
   object.newValue = true;
-  if (!object.newValue) throw 'incorrect value in "newValue"';
+  if (!object.newValue!) throw 'incorrect value in "newValue"';
   object.newValue = false;
-  if (object.newValue) throw 'incorrect value in "newValue"';
+  if (object.newValue!) throw 'incorrect value in "newValue"';
 
   if (object.nullValue == null) throw 'incorrect initialization of "nullValue"';
   object.nullValue = true;
-  if (!object.nullValue) throw 'incorrect value in "nullValue"';
+  if (!object.nullValue!) throw 'incorrect value in "nullValue"';
   object.nullValue = false;
-  if (object.nullValue) throw 'incorrect value in "nullValue"';
+  if (object.nullValue!) throw 'incorrect value in "nullValue"';
 
   if (object.packageValue == null)
     throw 'incorrect initialization of "packageValue"';
   object.packageValue = true;
-  if (!object.packageValue) throw 'incorrect value in "packageValue"';
+  if (!object.packageValue!) throw 'incorrect value in "packageValue"';
   object.packageValue = false;
-  if (object.packageValue) throw 'incorrect value in "packageValue"';
+  if (object.packageValue!) throw 'incorrect value in "packageValue"';
 
   if (object.privateValue == null)
     throw 'incorrect initialization of "privateValue"';
   object.privateValue = true;
-  if (!object.privateValue) throw 'incorrect value in "privateValue"';
+  if (!object.privateValue!) throw 'incorrect value in "privateValue"';
   object.privateValue = false;
-  if (object.privateValue) throw 'incorrect value in "privateValue"';
+  if (object.privateValue!) throw 'incorrect value in "privateValue"';
 
   if (object.protectedValue == null)
     throw 'incorrect initialization of "protectedValue"';
   object.protectedValue = true;
-  if (!object.protectedValue) throw 'incorrect value in "protectedValue"';
+  if (!object.protectedValue!) throw 'incorrect value in "protectedValue"';
   object.protectedValue = false;
-  if (object.protectedValue) throw 'incorrect value in "protectedValue"';
+  if (object.protectedValue!) throw 'incorrect value in "protectedValue"';
 
   if (object.publicValue == null)
     throw 'incorrect initialization of "publicValue"';
   object.publicValue = true;
-  if (!object.publicValue) throw 'incorrect value in "publicValue"';
+  if (!object.publicValue!) throw 'incorrect value in "publicValue"';
   object.publicValue = false;
-  if (object.publicValue) throw 'incorrect value in "publicValue"';
+  if (object.publicValue!) throw 'incorrect value in "publicValue"';
 
   if (object.returnValue == null)
     throw 'incorrect initialization of "returnValue"';
   object.returnValue = true;
-  if (!object.returnValue) throw 'incorrect value in "returnValue"';
+  if (!object.returnValue!) throw 'incorrect value in "returnValue"';
   object.returnValue = false;
-  if (object.returnValue) throw 'incorrect value in "returnValue"';
+  if (object.returnValue!) throw 'incorrect value in "returnValue"';
 
   if (object.staticValue == null)
     throw 'incorrect initialization of "staticValue"';
   object.staticValue = true;
-  if (!object.staticValue) throw 'incorrect value in "staticValue"';
+  if (!object.staticValue!) throw 'incorrect value in "staticValue"';
   object.staticValue = false;
-  if (object.staticValue) throw 'incorrect value in "staticValue"';
+  if (object.staticValue!) throw 'incorrect value in "staticValue"';
 
   if (object.superValue == null)
     throw 'incorrect initialization of "superValue"';
   object.superValue = true;
-  if (!object.superValue) throw 'incorrect value in "superValue"';
+  if (!object.superValue!) throw 'incorrect value in "superValue"';
   object.superValue = false;
-  if (object.superValue) throw 'incorrect value in "superValue"';
+  if (object.superValue!) throw 'incorrect value in "superValue"';
 
   if (object.switchValue == null)
     throw 'incorrect initialization of "switchValue"';
   object.switchValue = true;
-  if (!object.switchValue) throw 'incorrect value in "switchValue"';
+  if (!object.switchValue!) throw 'incorrect value in "switchValue"';
   object.switchValue = false;
-  if (object.switchValue) throw 'incorrect value in "switchValue"';
+  if (object.switchValue!) throw 'incorrect value in "switchValue"';
 
   if (object.thisValue == null) throw 'incorrect initialization of "thisValue"';
   object.thisValue = true;
-  if (!object.thisValue) throw 'incorrect value in "thisValue"';
+  if (!object.thisValue!) throw 'incorrect value in "thisValue"';
   object.thisValue = false;
-  if (object.thisValue) throw 'incorrect value in "thisValue"';
+  if (object.thisValue!) throw 'incorrect value in "thisValue"';
 
   if (object.throwValue == null)
     throw 'incorrect initialization of "throwValue"';
   object.throwValue = true;
-  if (!object.throwValue) throw 'incorrect value in "throwValue"';
+  if (!object.throwValue!) throw 'incorrect value in "throwValue"';
   object.throwValue = false;
-  if (object.throwValue) throw 'incorrect value in "throwValue"';
+  if (object.throwValue!) throw 'incorrect value in "throwValue"';
 
   if (object.trueValue == null) throw 'incorrect initialization of "trueValue"';
   object.trueValue = true;
-  if (!object.trueValue) throw 'incorrect value in "trueValue"';
+  if (!object.trueValue!) throw 'incorrect value in "trueValue"';
   object.trueValue = false;
-  if (object.trueValue) throw 'incorrect value in "trueValue"';
+  if (object.trueValue!) throw 'incorrect value in "trueValue"';
 
   if (object.tryValue == null) throw 'incorrect initialization of "tryValue"';
   object.tryValue = true;
-  if (!object.tryValue) throw 'incorrect value in "tryValue"';
+  if (!object.tryValue!) throw 'incorrect value in "tryValue"';
   object.tryValue = false;
-  if (object.tryValue) throw 'incorrect value in "tryValue"';
+  if (object.tryValue!) throw 'incorrect value in "tryValue"';
 
   if (object.typeofValue == null)
     throw 'incorrect initialization of "typeofValue"';
   object.typeofValue = true;
-  if (!object.typeofValue) throw 'incorrect value in "typeofValue"';
+  if (!object.typeofValue!) throw 'incorrect value in "typeofValue"';
   object.typeofValue = false;
-  if (object.typeofValue) throw 'incorrect value in "typeofValue"';
+  if (object.typeofValue!) throw 'incorrect value in "typeofValue"';
 
   if (object.varValue == null) throw 'incorrect initialization of "varValue"';
   object.varValue = true;
-  if (!object.varValue) throw 'incorrect value in "varValue"';
+  if (!object.varValue!) throw 'incorrect value in "varValue"';
   object.varValue = false;
-  if (object.varValue) throw 'incorrect value in "varValue"';
+  if (object.varValue!) throw 'incorrect value in "varValue"';
 
   if (object.voidValue == null) throw 'incorrect initialization of "voidValue"';
   object.voidValue = true;
-  if (!object.voidValue) throw 'incorrect value in "voidValue"';
+  if (!object.voidValue!) throw 'incorrect value in "voidValue"';
   object.voidValue = false;
-  if (object.voidValue) throw 'incorrect value in "voidValue"';
+  if (object.voidValue!) throw 'incorrect value in "voidValue"';
 
   if (object.whileValue == null)
     throw 'incorrect initialization of "whileValue"';
   object.whileValue = true;
-  if (!object.whileValue) throw 'incorrect value in "whileValue"';
+  if (!object.whileValue!) throw 'incorrect value in "whileValue"';
   object.whileValue = false;
-  if (object.whileValue) throw 'incorrect value in "whileValue"';
+  if (object.whileValue!) throw 'incorrect value in "whileValue"';
 
   if (object.withValue == null) throw 'incorrect initialization of "withValue"';
   object.withValue = true;
-  if (!object.withValue) throw 'incorrect value in "withValue"';
+  if (!object.withValue!) throw 'incorrect value in "withValue"';
   object.withValue = false;
-  if (object.withValue) throw 'incorrect value in "withValue"';
+  if (object.withValue!) throw 'incorrect value in "withValue"';
 
   if (object.yieldValue == null)
     throw 'incorrect initialization of "yieldValue"';
   object.yieldValue = true;
-  if (!object.yieldValue) throw 'incorrect value in "yieldValue"';
+  if (!object.yieldValue!) throw 'incorrect value in "yieldValue"';
   object.yieldValue = false;
-  if (object.yieldValue) throw 'incorrect value in "yieldValue"';
+  if (object.yieldValue!) throw 'incorrect value in "yieldValue"';
 }
 
 NativeClassWithOddNames makeNativeClassWithOddNames() native;
diff --git a/tests/dart2js/native/subclassing_super_call_test.dart b/tests/dart2js/native/subclassing_super_call_test.dart
index 61e3fc1..b157933 100644
--- a/tests/dart2js/native/subclassing_super_call_test.dart
+++ b/tests/dart2js/native/subclassing_super_call_test.dart
@@ -15,13 +15,14 @@
 @Native("N2")
 class N2 extends N1 {
   N2.init();
-  String text;
+  void set text(String unused) native;
+  String get text native;
   foo() native;
 }
 
 class AA extends N2 {
   AA.init() : super.init();
-  String afield;
+  String? afield;
   afun() => 'afun:$afield';
 }
 
diff --git a/tests/dart2js/native/subclassing_type_test.dart b/tests/dart2js/native/subclassing_type_test.dart
index b99872e..ce52e5b 100644
--- a/tests/dart2js/native/subclassing_type_test.dart
+++ b/tests/dart2js/native/subclassing_type_test.dart
@@ -39,10 +39,10 @@
 })()""");
 }
 
-A gA;
-B gB;
-C gC;
-M gM;
+A? gA;
+B? gB;
+C? gC;
+M? gM;
 
 isA(x) => x is A;
 asA(x) => x as A;
diff --git a/tests/dart2js/native/type_error_decode_test.dart b/tests/dart2js/native/type_error_decode_test.dart
index ba97210..67f0174 100644
--- a/tests/dart2js/native/type_error_decode_test.dart
+++ b/tests/dart2js/native/type_error_decode_test.dart
@@ -35,11 +35,11 @@
 
 main() {
   dynamic x = null;
-  dynamic z = new Object();
-  dynamic v = new List(1)[0];
+  dynamic z = Object();
+  dynamic v = ([]..length = 1)[0];
   dynamic s = "Cannot call method 'foo' of null";
   dynamic nul = null;
-  dynamic f = new Foo();
+  dynamic f = Foo();
 
   expectThrows(() => x.fisk(), isNullError);
   expectThrows(() => v.fisk(), isNullError);
diff --git a/tests/dart2js/non_jsinterop_test.dart b/tests/dart2js/non_jsinterop_test.dart
index e66c5d5..67f239b 100644
--- a/tests/dart2js/non_jsinterop_test.dart
+++ b/tests/dart2js/non_jsinterop_test.dart
@@ -52,7 +52,7 @@
 
 class Class {
   Class.generative();
-  factory Class.fact() => null;
+  factory Class.fact() => null as dynamic;
 
   // NON_NATIVE_EXTERNAL               //# 08: compile-time error
   external Class.externalGenerative(); //# 08: continued
@@ -60,7 +60,7 @@
   // NON_NATIVE_EXTERNAL                 //# 09: compile-time error
   external factory Class.externalFact(); //# 09: continued
 
-  @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 10: compile-time error
+  @JS('a') // GENERIC  //# 10: compile-time error
   Class.jsInteropGenerative(); //# 10: continued
 
   @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 11: compile-time error
diff --git a/tests/dart2js/panda_test.dart b/tests/dart2js/panda_test.dart
index 2afaee6..a7c324f 100644
--- a/tests/dart2js/panda_test.dart
+++ b/tests/dart2js/panda_test.dart
@@ -8,7 +8,7 @@
 import 'panda_lib.dart' as p;
 
 void main() {
-  p.Panda x = new p.Panda();
+  p.Panda? x = new p.Panda();
   Expect.isTrue(x is p.Panda);
   x = null;
   Expect.isFalse(x is p.Panda);
diff --git a/tests/dart2js/regress_40349_test.dart b/tests/dart2js/regress_40349_test.dart
index 796688d..83b8797 100644
--- a/tests/dart2js/regress_40349_test.dart
+++ b/tests/dart2js/regress_40349_test.dart
@@ -21,7 +21,7 @@
 
 class A<E> {
   int _foo = 0;
-  List<E> list = [null];
+  List<E?> list = [null];
 
   @pragma('dart2js:tryInline')
   void internalMethod(E value) {
diff --git a/tests/dart2js/regress_null_aware_test.dart b/tests/dart2js/regress_null_aware_test.dart
index 4ef8dc3..cc278b7 100644
--- a/tests/dart2js/regress_null_aware_test.dart
+++ b/tests/dart2js/regress_null_aware_test.dart
@@ -5,17 +5,11 @@
 // Regression test for failure on CFE null-aware encoding.
 
 class Class {
-  Map<String, Set<String>> map;
+  Map<String, Set<String>>? map;
 
-  List<String> method(String node, Set<String> set) =>
-      set.add(node)
-          ? [
-              node,
-              ...?map[node]
-                  ?.expand((node) => method(node, set))
-                  ?.toList()
-            ]
-          : [];
+  List<String> method(String node, Set<String> set) => set.add(node)
+      ? [node, ...?map![node]?.expand((node) => method(node, set))?.toList()]
+      : [];
 }
 
 main(args) {
diff --git a/tests/dart2js/return_setter_test.dart b/tests/dart2js/return_setter_test.dart
index a938b71..5cdb499 100644
--- a/tests/dart2js/return_setter_test.dart
+++ b/tests/dart2js/return_setter_test.dart
@@ -5,13 +5,13 @@
 import "package:expect/expect.dart";
 
 class A {
-  int foo;
+  int? foo;
 
-  static int invocations;
+  static int? invocations;
 
   static bar() {
     Expect.equals(0, invocations);
-    invocations++;
+    invocations = invocations! + 1;
     return 2;
   }
 }
diff --git a/tests/dart2js/runtime_type_closure_equals1_test.dart b/tests/dart2js/runtime_type_closure_equals1_test.dart
index 5defc5e..fb65f2a 100644
--- a/tests/dart2js/runtime_type_closure_equals1_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals1_test.dart
@@ -2,8 +2,6 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class<T> {
@@ -19,5 +17,5 @@
 
   Expect.isTrue(local1a.runtimeType == local1b.runtimeType);
   Expect.isFalse(local1a.runtimeType == local2.runtimeType);
-  new Class();
+  Class();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals2_test.dart b/tests/dart2js/runtime_type_closure_equals2_test.dart
index 86fe4b2..110520e 100644
--- a/tests/dart2js/runtime_type_closure_equals2_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals2_test.dart
@@ -2,8 +2,6 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class<T> {
@@ -11,13 +9,13 @@
 }
 
 main() {
-  T local1a<T>() => null;
+  T local1a<T>() => throw 'unreachable';
 
-  T local1b<T>() => null;
+  T local1b<T>() => throw 'unreachable';
 
   T local2<T>(T t, String s) => t;
 
   Expect.isTrue(local1a.runtimeType == local1b.runtimeType);
   Expect.isFalse(local1a.runtimeType == local2.runtimeType);
-  new Class();
+  Class();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals3_test.dart b/tests/dart2js/runtime_type_closure_equals3_test.dart
index ffcd03f..111ffda 100644
--- a/tests/dart2js/runtime_type_closure_equals3_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals3_test.dart
@@ -2,19 +2,17 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
-String method() => null;
+String method() => throw 'unreachable';
 
 class Class1<T> {
   Class1();
 
   method() {
-    T local1a() => null;
+    T local1a() => throw 'unreachable';
 
-    T local1b() => null;
+    T local1b() => throw 'unreachable';
 
     T local2(T t, String s) => t;
 
@@ -29,6 +27,6 @@
 }
 
 main() {
-  new Class1<int>().method();
-  new Class2<int>();
+  Class1<int>().method();
+  Class2<int>();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals4_test.dart b/tests/dart2js/runtime_type_closure_equals4_test.dart
index 967b5f6..f23c0c1 100644
--- a/tests/dart2js/runtime_type_closure_equals4_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals4_test.dart
@@ -2,8 +2,6 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1<T> {
@@ -21,9 +19,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals5_test.dart b/tests/dart2js/runtime_type_closure_equals5_test.dart
index 1b19f8d..c4d16a5 100644
--- a/tests/dart2js/runtime_type_closure_equals5_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals5_test.dart
@@ -2,16 +2,14 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1<T> {
   Class1();
 
-  T method1a() => null;
+  T method1a() => throw 'unreachable';
 
-  T method1b() => null;
+  T method1b() => throw 'unreachable';
 
   T method2(T t, String s) => t;
 }
@@ -21,9 +19,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals6_test.dart b/tests/dart2js/runtime_type_closure_equals6_test.dart
index 5090f04..84ed603 100644
--- a/tests/dart2js/runtime_type_closure_equals6_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals6_test.dart
@@ -2,8 +2,6 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 method1a() => null;
@@ -19,5 +17,5 @@
 main() {
   Expect.isTrue(method1a.runtimeType == method1b.runtimeType);
   Expect.isFalse(method1a.runtimeType == method2.runtimeType);
-  new Class<int>();
+  Class<int>();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals7_test.dart b/tests/dart2js/runtime_type_closure_equals7_test.dart
index 73348c9..04d4246 100644
--- a/tests/dart2js/runtime_type_closure_equals7_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals7_test.dart
@@ -2,13 +2,11 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
-T method1a<T>() => null;
+T method1a<T>() => throw 'unreachable';
 
-T method1b<T>() => null;
+T method1b<T>() => throw 'unreachable';
 
 T method2<T>(T t, String s) => t;
 
@@ -19,5 +17,5 @@
 main() {
   Expect.isTrue(method1a.runtimeType == method1b.runtimeType);
   Expect.isFalse(method1a.runtimeType == method2.runtimeType);
-  new Class<int>();
+  Class<int>();
 }
diff --git a/tests/dart2js/runtime_type_closure_equals8_test.dart b/tests/dart2js/runtime_type_closure_equals8_test.dart
index 5f03539..6416dba 100644
--- a/tests/dart2js/runtime_type_closure_equals8_test.dart
+++ b/tests/dart2js/runtime_type_closure_equals8_test.dart
@@ -2,16 +2,14 @@
 // 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.
 
-// dart2jsOptions=--strong
-
 import 'package:expect/expect.dart';
 
 class Class1<S> {
   Class1();
 
-  T method1a<T>() => null;
+  T method1a<T>() => throw 'unreachable';
 
-  T method1b<T>() => null;
+  T method1b<T>() => throw 'unreachable';
 
   T method2<T>(T t, String s) => t;
 }
@@ -21,9 +19,9 @@
 }
 
 main() {
-  var c = new Class1<int>();
+  var c = Class1<int>();
 
   Expect.isTrue(c.method1a.runtimeType == c.method1b.runtimeType);
   Expect.isFalse(c.method1a.runtimeType == c.method2.runtimeType);
-  new Class2<int>();
+  Class2<int>();
 }
diff --git a/tests/dart2js/static_field2_test.dart b/tests/dart2js/static_field2_test.dart
index d2f5cc7..c96589b 100644
--- a/tests/dart2js/static_field2_test.dart
+++ b/tests/dart2js/static_field2_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 class A {
-  static int b;
+  static int? b;
 }
 
 main() {
diff --git a/tests/dart2js/static_field_test.dart b/tests/dart2js/static_field_test.dart
index 63c96af..f0f8d9b 100644
--- a/tests/dart2js/static_field_test.dart
+++ b/tests/dart2js/static_field_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 class A {
-  static int b;
+  static int? b;
 
   setA(val) {
     b = val;
@@ -21,7 +21,7 @@
 }
 
 main() {
-  A a = new A();
+  A a = A();
   a.setA(42);
   Expect.equals(42, a.bar());
   Expect.equals(42, a.bar2());
diff --git a/tests/dart2js/static_var_no_initializer_test.dart b/tests/dart2js/static_var_no_initializer_test.dart
index e6cb720..8605621 100644
--- a/tests/dart2js/static_var_no_initializer_test.dart
+++ b/tests/dart2js/static_var_no_initializer_test.dart
@@ -4,8 +4,8 @@
 
 import "package:expect/expect.dart";
 
-int one;
-int x;
+int? one;
+int? x;
 
 void testOne() {
   Expect.equals(1, one);
@@ -16,7 +16,7 @@
 }
 
 void increaseX() {
-  x = x + 1;
+  x = x! + 1;
 }
 
 void main() {
@@ -26,7 +26,7 @@
   testOne();
   Expect.equals(5, x);
   testX(5);
-  x = x + 1;
+  x = x! + 1;
   Expect.equals(6, x);
   testX(6);
   increaseX();
diff --git a/tests/dart2js/string_interpolation_opt1_test.dart b/tests/dart2js/string_interpolation_opt1_test.dart
index 60e92d4..7332951 100644
--- a/tests/dart2js/string_interpolation_opt1_test.dart
+++ b/tests/dart2js/string_interpolation_opt1_test.dart
@@ -7,7 +7,7 @@
 
 // Test that String interpolation works in some optimized cases.
 
-bool get inscrutableFalse => new Random().nextDouble() > 2;
+bool get inscrutableFalse => Random().nextDouble() > 2;
 
 returnsNullOrString(x) {
   if (inscrutableFalse) return 'hi';
@@ -27,7 +27,7 @@
 }
 
 void testString() {
-  var a = new List(100); // 'null' values in here are JavaScript undefined.
+  var a = []..length = 100; // 'null' values in here are JavaScript undefined.
   spoil(a);
   var s = returnsNullOrString('hi');
   var x = a[2];
@@ -39,7 +39,7 @@
 }
 
 void testInt() {
-  var a = new List(100); // 'null' values in here are JavaScript undefined.
+  var a = []..length = 100; // 'null' values in here are JavaScript undefined.
   spoil(a);
   var s = returnsNullOrInt(123);
   var x = a[2];
diff --git a/tests/dart2js/super_constructor1_test.dart b/tests/dart2js/super_constructor1_test.dart
index a0aaf86..f177c57 100644
--- a/tests/dart2js/super_constructor1_test.dart
+++ b/tests/dart2js/super_constructor1_test.dart
@@ -4,7 +4,7 @@
 
 import "package:expect/expect.dart";
 
-String message;
+String? message;
 
 class A {
   int x;
@@ -33,7 +33,7 @@
 
 main() {
   message = '';
-  var c = new C(7);
+  var c = C(7);
   Expect.equals(27, c.x);
   Expect.equals(21, c.y);
   Expect.equals(7, c.z);
diff --git a/tests/dart2js/tear_off_types_test.dart b/tests/dart2js/tear_off_types_test.dart
index d7f6c41..daee27d 100644
--- a/tests/dart2js/tear_off_types_test.dart
+++ b/tests/dart2js/tear_off_types_test.dart
@@ -27,9 +27,9 @@
   Expect.isFalse(_test1(method1c));
 }
 
-B1 method1a() => null;
-A1<int> method1b() => null;
-A1<String> method1c() => null;
+B1 method1a() => throw 'unreachable';
+A1<int> method1b() => throw 'unreachable';
+A1<String> method1c() => throw 'unreachable';
 
 @pragma('dart2js:noInline')
 bool _test1(f) => f is A1<int> Function();
@@ -81,9 +81,9 @@
   Expect.isFalse(_test4(method4c));
 }
 
-B4 method4a() => null;
-A4<int> method4b() => null;
-A4<String> method4c() => null;
+B4 method4a() => throw 'unreachable';
+A4<int> method4b() => throw 'unreachable';
+A4<String> method4c() => throw 'unreachable';
 
 @pragma('dart4js:noInline')
 _test4(f) => f is B4 Function();
@@ -117,9 +117,9 @@
   Expect.isFalse(_test6(method6c));
 }
 
-void Function(B6) method6a() => null;
-void Function(A6<int>) method6b() => null;
-void Function(A6<String>) method6c() => null;
+void Function(B6) method6a() => throw 'unreachable';
+void Function(A6<int>) method6b() => throw 'unreachable';
+void Function(A6<String>) method6c() => throw 'unreachable';
 
 @pragma('dart6js:noInline')
 _test6(f) => f is void Function(B6) Function();
diff --git a/tests/dart2js/this_test.dart b/tests/dart2js/this_test.dart
index e0804e7..f797d88 100644
--- a/tests/dart2js/this_test.dart
+++ b/tests/dart2js/this_test.dart
@@ -5,7 +5,7 @@
 import "package:expect/expect.dart";
 
 class A {
-  int x;
+  int? x;
   getX() => this.x;
   setX(val) {
     this.x = val;
@@ -13,7 +13,7 @@
 }
 
 main() {
-  A a = new A();
+  A a = A();
   a.setX(42);
   Expect.equals(42, a.getX());
 }
diff --git a/tests/dart2js/type_argument_optimization_test.dart b/tests/dart2js/type_argument_optimization_test.dart
index 21b41c5..facb994 100644
--- a/tests/dart2js/type_argument_optimization_test.dart
+++ b/tests/dart2js/type_argument_optimization_test.dart
@@ -14,21 +14,21 @@
 class Widget {}
 
 abstract class ProxyWidget extends Widget {
-  final Widget child;
+  final Widget? child;
 
   ProxyWidget({this.child});
 }
 
 abstract class InheritedWidget extends ProxyWidget {
-  InheritedWidget({Widget child}) : super(child: child);
+  InheritedWidget({Widget? child}) : super(child: child);
 }
 
 class InheritedProvider<T> extends InheritedWidget {
-  final T _value;
-  final UpdateShouldNotify<T> _updateShouldNotify;
+  final T? _value;
+  final UpdateShouldNotify<T>? _updateShouldNotify;
 
   InheritedProvider(
-      {T value, UpdateShouldNotify<T> updateShouldNotify, Widget child})
+      {T? value, UpdateShouldNotify<T>? updateShouldNotify, Widget? child})
       : _value = value,
         _updateShouldNotify = updateShouldNotify,
         super(child: child);
@@ -73,15 +73,15 @@
 
 class ValueListenableProvider<T>
     extends ValueDelegateWidget<ValueListenable<T>> {
-  final Widget child;
+  final Widget? child;
 
-  final UpdateShouldNotify<T> updateShouldNotify;
+  final UpdateShouldNotify<T>? updateShouldNotify;
 
   ValueListenableProvider(ValueStateDelegate<ValueListenable<T>> delegate,
       this.updateShouldNotify, this.child)
       : super(delegate);
 
-  Widget build() {
+  ValueListenableBuilder<T> build() {
     return ValueListenableBuilder<T>(
       valueListenable: delegate.value,
       builder: (_, value, child) {
@@ -97,25 +97,25 @@
 }
 
 class ValueListenableBuilder<T> extends Widget {
-  final ValueListenable<T> valueListenable;
-  final ValueWidgetBuilder<T> builder;
-  final Widget child;
+  final ValueListenable<T>? valueListenable;
+  final ValueWidgetBuilder<T>? builder;
+  final Widget? child;
 
   ValueListenableBuilder({this.valueListenable, this.builder, this.child});
 }
 
 void main() {
-  print(create(42).valueListenable.value);
-  print(create('foo').valueListenable.value);
+  print(create(42).valueListenable!.value);
+  print(create('foo').valueListenable!.value);
 }
 
 ValueListenableBuilder<T> create<T>(T value) {
-  ValueListenableImpl<T> valueListenable = new ValueListenableImpl<T>(value);
+  ValueListenableImpl<T> valueListenable = ValueListenableImpl<T>(value);
   ValueStateDelegateImpl<ValueListenable<T>> valueStateDelegate =
-      new ValueStateDelegateImpl<ValueListenable<T>>(valueListenable);
+      ValueStateDelegateImpl<ValueListenable<T>>(valueListenable);
   ValueListenableProvider<T> valueListenableProvider =
-      new ValueListenableProvider<T>(valueStateDelegate, null, null);
-  Widget widget = valueListenableProvider.build();
+      ValueListenableProvider<T>(valueStateDelegate, null, null);
+  ValueListenableBuilder<T> widget = valueListenableProvider.build();
   print(value);
   return widget;
 }
diff --git a/tests/dart2js_2/42531_test.dart b/tests/dart2js_2/42531_test.dart
new file mode 100644
index 0000000..7bc9b58
--- /dev/null
+++ b/tests/dart2js_2/42531_test.dart
@@ -0,0 +1,46 @@
+// 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 'package:expect/expect.dart';
+
+// Regression test for badly named generator body.
+
+Future<void> goo(Future Function() f) async {
+  Expect.equals(102, (await f()).keys.single);
+  Expect.equals(104, (await f()).keys.single);
+}
+
+Future<T> identity<T>(T x) async => x;
+
+extension Gloop<T> on Map<T, List<T>> {
+  // An async method using a 'complex' generator type `Map<T, List<T>>`.  This
+  // requires a separated entry and body, which requires a name, and the name
+  // must be legal JavaScript.
+  Future<Map<T, List<T>>> foo(int x) async {
+    var result = await identity({(x += this.length) as T: <T>[]});
+    return result;
+  }
+
+  Future<int> bar(int x) async {
+    // An async closure using a 'complex' generator type `Map<T, Set<T>>`.  This
+    // requires a separated entry and body, which requires a name, and the name
+    // must be legal JavaScript.
+    await goo(() async => {(x += this.length) as T: <T>{}});
+    return x;
+  }
+}
+
+main() async {
+  // Test method.
+  Map<int, List<int>> o1 = {1: [], 2: []};
+  var o2 = await o1.foo(100);
+  var o3 = await o2.foo(100);
+  Expect.equals('{102: []}', '$o2');
+  Expect.equals('{101: []}', '$o3');
+
+  // Test closure.
+  Map<int, List<int>> o = {1: [], 2: []};
+  int x = await o.bar(100);
+  Expect.equals(104, x);
+}
diff --git a/tests/dart2js_2/internal/rti/required_named_parameters_test.dart b/tests/dart2js_2/internal/rti/required_named_parameters_test.dart
index 309a381..c07f7a4 100644
--- a/tests/dart2js_2/internal/rti/required_named_parameters_test.dart
+++ b/tests/dart2js_2/internal/rti/required_named_parameters_test.dart
@@ -51,11 +51,11 @@
 
   // Subtype may not redeclare optional parameters as required
   rti2 = rti.testingUniverseEval(universe, "@(A,{a!A,b!A,c!A})");
-  Expect.isFalse(rti.testingIsSubtype(universe, rti2, rti1));
+  Expect.equals(isWeakMode, rti.testingIsSubtype(universe, rti2, rti1));
 
   // Subtype may not declare new required named parameters
   rti2 = rti.testingUniverseEval(universe, "@(A,{a!A,b:A,c!A,d!A})");
-  Expect.isFalse(rti.testingIsSubtype(universe, rti2, rti1));
+  Expect.equals(isWeakMode, rti.testingIsSubtype(universe, rti2, rti1));
 
   // Rti.toString() appears as expected
   Expect.equals('(B, {required B a, B b, required B c}) => dynamic',
diff --git a/tests/dart2js_2/jsinterop_test.dart b/tests/dart2js_2/jsinterop_test.dart
index b9fb820..23521a0 100644
--- a/tests/dart2js_2/jsinterop_test.dart
+++ b/tests/dart2js_2/jsinterop_test.dart
@@ -60,7 +60,7 @@
   // NON_NATIVE_EXTERNAL                 //# 09: compile-time error
   external factory Class.externalFact(); //# 09: continued
 
-  @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 10: compile-time error
+  @JS('a') // GENERIC  //# 10: compile-time error
   Class.jsInteropGenerative(); //# 10: continued
 
   @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 11: compile-time error
diff --git a/tests/dart2js_2/non_jsinterop_test.dart b/tests/dart2js_2/non_jsinterop_test.dart
index abf7672..bbaae2c 100644
--- a/tests/dart2js_2/non_jsinterop_test.dart
+++ b/tests/dart2js_2/non_jsinterop_test.dart
@@ -62,7 +62,7 @@
   // NON_NATIVE_EXTERNAL                 //# 09: compile-time error
   external factory Class.externalFact(); //# 09: continued
 
-  @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 10: compile-time error
+  @JS('a') // GENERIC  //# 10: compile-time error
   Class.jsInteropGenerative(); //# 10: continued
 
   @JS('a') // JS_INTEROP_MEMBER_IN_NON_JS_INTEROP_CLASS  //# 11: compile-time error
diff --git a/tests/dartdevc/const_test.dart b/tests/dartdevc/const_test.dart
index b2dbf27..b39656d95 100644
--- a/tests/dartdevc/const_test.dart
+++ b/tests/dartdevc/const_test.dart
@@ -7,7 +7,7 @@
 import 'dart:_runtime' as dart;
 
 void main() {
-  var data = JS('', '[1, 2, 3, 4]');
+  dynamic data = JS('', '[1, 2, 3, 4]');
   Expect.isFalse(data is List<int>);
 
   var list = dart.constList(data, dart.unwrapType(int));
diff --git a/tests/dartdevc/hot_restart_timer_test.dart b/tests/dartdevc/hot_restart_timer_test.dart
index 9685f51..4bacc82 100644
--- a/tests/dartdevc/hot_restart_timer_test.dart
+++ b/tests/dartdevc/hot_restart_timer_test.dart
@@ -11,7 +11,7 @@
   await periodicTest();
 }
 
-void timeoutTest() async {
+Future<void> timeoutTest() async {
   bool beforeRestart = true;
   bool calledBeforeRestart = false;
   bool calledAfterRestart = false;
@@ -31,7 +31,7 @@
   Expect.isFalse(calledAfterRestart);
 }
 
-void periodicTest() async {
+Future<void> periodicTest() async {
   bool beforeRestart = true;
   bool calledBeforeRestart = false;
   bool calledAfterRestart = false;
diff --git a/tests/dartdevc/variance_subtype_test.dart b/tests/dartdevc/variance_subtype_test.dart
index 108ec64..7200987 100644
--- a/tests/dartdevc/variance_subtype_test.dart
+++ b/tests/dartdevc/variance_subtype_test.dart
@@ -43,17 +43,17 @@
   // Invariant<Middle> <: Invariant<Middle>
   checkSubtype(typeRep<Invariant<Middle>>(), typeRep<Invariant<Middle>>());
 
-  // Invariant<dynamic> <:> Invariant<Object>
+  // Invariant<dynamic> <:> Invariant<Object?>
   checkMutualSubtype(
-      typeRep<Invariant<dynamic>>(), typeRep<Invariant<Object>>());
+      typeRep<Invariant<dynamic>>(), typeRep<Invariant<Object?>>());
 
   // Invariant<FutureOr<dynamic>> <:> Invariant<dynamic>
   checkMutualSubtype(
       typeRep<Invariant<FutureOr<dynamic>>>(), typeRep<Invariant<dynamic>>());
 
-  // Invariant<FutureOr<Null>> <:> Invariant<Future<Null>>
+  // Invariant<FutureOr<Null>> <:> Invariant<Future<Null>?>
   checkMutualSubtype(
-      typeRep<Invariant<FutureOr<Null>>>(), typeRep<Invariant<Future<Null>>>());
+      typeRep<Invariant<FutureOr<Null>>>(), typeRep<Invariant<Future<Null>?>>());
 
   // LegacyCovariant<Lower> <: LegacyCovariant<Middle>
   checkProperSubtype(
diff --git a/tests/dartdevc/variance_test.dart b/tests/dartdevc/variance_test.dart
index 69c7679..f3bcf75 100644
--- a/tests/dartdevc/variance_test.dart
+++ b/tests/dartdevc/variance_test.dart
@@ -7,7 +7,7 @@
 // Tests the emission of explicit variance modifiers.
 
 import 'dart:_runtime'
-    show wrapType, unwrapType, getGenericArgVariances, Variance, typeRep;
+    show getGenericArgVariances, Variance, typeRep;
 
 import 'package:expect/expect.dart';
 
@@ -25,27 +25,27 @@
 
 class G<inout T> = Object with F<T>;
 
-List getVariances(Object t) {
-  // TODO(nshahan) Update to handle legacy wrapper when we unfork dart:_runtime.
-  var type = unwrapType(wrapType(t));
+List? getVariances(Object type) {
+  // TODO(nshahan) Revisit when we decide if getGenericArgVariances will handle
+  // legacy and nullable wrappers.
   return getGenericArgVariances(type);
 }
 
 main() {
-  Expect.listEquals([Variance.contravariant], getVariances(typeRep<A>()));
+  Expect.listEquals([Variance.contravariant], getVariances(typeRep<A>())!);
 
-  Expect.listEquals([Variance.covariant], getVariances(typeRep<B>()));
+  Expect.listEquals([Variance.covariant], getVariances(typeRep<B>())!);
 
-  Expect.listEquals([Variance.invariant], getVariances(typeRep<C>()));
+  Expect.listEquals([Variance.invariant], getVariances(typeRep<C>())!);
 
   // Implicit variance is not emitted into the generated code.
   Expect.isNull(getVariances(typeRep<D>()));
 
   Expect.listEquals(
       [Variance.invariant, Variance.covariant, Variance.contravariant],
-      getVariances(typeRep<E>()));
+      getVariances(typeRep<E>())!);
 
-  Expect.listEquals([Variance.contravariant], getVariances(typeRep<F>()));
+  Expect.listEquals([Variance.contravariant], getVariances(typeRep<F>())!);
 
-  Expect.listEquals([Variance.invariant], getVariances(typeRep<G>()));
+  Expect.listEquals([Variance.invariant], getVariances(typeRep<G>())!);
 }
diff --git a/tests/dartdevc_2/variance_test.dart b/tests/dartdevc_2/variance_test.dart
index ac2e683..6d84f2f 100644
--- a/tests/dartdevc_2/variance_test.dart
+++ b/tests/dartdevc_2/variance_test.dart
@@ -9,7 +9,7 @@
 // Tests the emission of explicit variance modifiers.
 
 import 'dart:_runtime'
-    show wrapType, unwrapType, getGenericArgVariances, Variance, typeRep;
+    show getGenericArgVariances, Variance, legacyTypeRep;
 
 import 'package:expect/expect.dart';
 
@@ -27,27 +27,27 @@
 
 class G<inout T> = Object with F<T>;
 
-List getVariances(Object t) {
-  // TODO(nshahan) Update to handle legacy wrapper when we unfork dart:_runtime.
-  var type = unwrapType(wrapType(t));
-  return getGenericArgVariances(type);
+List getVariances(dynamic type) {
+  // TODO(nshahan) Revisit when we decide if getGenericArgVariances will handle
+  // legacy and nullable wrappers.
+  return getGenericArgVariances(type.type);
 }
 
 main() {
-  Expect.listEquals([Variance.contravariant], getVariances(typeRep<A>()));
+  Expect.listEquals([Variance.contravariant], getVariances(legacyTypeRep<A>()));
 
-  Expect.listEquals([Variance.covariant], getVariances(typeRep<B>()));
+  Expect.listEquals([Variance.covariant], getVariances(legacyTypeRep<B>()));
 
-  Expect.listEquals([Variance.invariant], getVariances(typeRep<C>()));
+  Expect.listEquals([Variance.invariant], getVariances(legacyTypeRep<C>()));
 
   // Implicit variance is not emitted into the generated code.
-  Expect.isNull(getVariances(typeRep<D>()));
+  Expect.isNull(getVariances(legacyTypeRep<D>()));
 
   Expect.listEquals(
       [Variance.invariant, Variance.covariant, Variance.contravariant],
-      getVariances(typeRep<E>()));
+      getVariances(legacyTypeRep<E>()));
 
-  Expect.listEquals([Variance.contravariant], getVariances(typeRep<F>()));
+  Expect.listEquals([Variance.contravariant], getVariances(legacyTypeRep<F>()));
 
-  Expect.listEquals([Variance.invariant], getVariances(typeRep<G>()));
+  Expect.listEquals([Variance.invariant], getVariances(legacyTypeRep<G>()));
 }
diff --git a/tests/ffi/coordinate_nnbd_workaround.dart b/tests/ffi/coordinate_nnbd_workaround.dart
new file mode 100644
index 0000000..515badd
--- /dev/null
+++ b/tests/ffi/coordinate_nnbd_workaround.dart
@@ -0,0 +1,29 @@
+// 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.
+
+library FfiTest;
+
+import 'dart:ffi';
+import "package:ffi/ffi.dart";
+
+/// Sample struct for dart:ffi library.
+class Coordinate extends Struct {
+  @Double()
+  external double get x;
+  external set x(double v);
+
+  @Double()
+  external double get y;
+  external set y(double v);
+
+  external Pointer<Coordinate> get next;
+  external set next(Pointer<Coordinate> v);
+
+  factory Coordinate.allocate(double x, double y, Pointer<Coordinate> next) {
+    return allocate<Coordinate>().ref
+      ..x = x
+      ..y = y
+      ..next = next;
+  }
+}
diff --git a/tests/ffi/structs_nnbd_workaround_test.dart b/tests/ffi/structs_nnbd_workaround_test.dart
new file mode 100644
index 0000000..6501faf
--- /dev/null
+++ b/tests/ffi/structs_nnbd_workaround_test.dart
@@ -0,0 +1,100 @@
+// 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 test program for testing dart:ffi struct pointers.
+//
+// VMOptions=--deterministic --optimization-counter-threshold=50
+
+import 'dart:ffi';
+
+import "package:expect/expect.dart";
+import "package:ffi/ffi.dart";
+
+import 'coordinate_nnbd_workaround.dart';
+
+void main() {
+  for (int i = 0; i < 100; i++) {
+    testStructAllocate();
+    testStructFromAddress();
+    testStructWithNulls();
+    testTypeTest();
+    testUtf8();
+  }
+}
+
+/// allocates each coordinate separately in c memory
+void testStructAllocate() {
+  Pointer<Coordinate> c1 = Coordinate.allocate(10.0, 10.0, nullptr).addressOf;
+  Pointer<Coordinate> c2 = Coordinate.allocate(20.0, 20.0, c1).addressOf;
+  Pointer<Coordinate> c3 = Coordinate.allocate(30.0, 30.0, c2).addressOf;
+  c1.ref.next = c3;
+
+  Coordinate currentCoordinate = c1.ref;
+  Expect.equals(10.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(30.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(20.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(10.0, currentCoordinate.x);
+
+  free(c1);
+  free(c2);
+  free(c3);
+}
+
+/// allocates coordinates consecutively in c memory
+void testStructFromAddress() {
+  Pointer<Coordinate> c1 = allocate(count: 3);
+  Pointer<Coordinate> c2 = c1.elementAt(1);
+  Pointer<Coordinate> c3 = c1.elementAt(2);
+  c1.ref
+    ..x = 10.0
+    ..y = 10.0
+    ..next = c3;
+  c2.ref
+    ..x = 20.0
+    ..y = 20.0
+    ..next = c1;
+  c3.ref
+    ..x = 30.0
+    ..y = 30.0
+    ..next = c2;
+
+  Coordinate currentCoordinate = c1.ref;
+  Expect.equals(10.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(30.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(20.0, currentCoordinate.x);
+  currentCoordinate = currentCoordinate.next.ref;
+  Expect.equals(10.0, currentCoordinate.x);
+
+  free(c1);
+}
+
+void testStructWithNulls() {
+  Pointer<Coordinate> coordinate =
+      Coordinate.allocate(10.0, 10.0, nullptr).addressOf;
+  Expect.equals(coordinate.ref.next, nullptr);
+  coordinate.ref.next = coordinate;
+  Expect.notEquals(coordinate.ref.next, nullptr);
+  coordinate.ref.next = nullptr;
+  Expect.equals(coordinate.ref.next, nullptr);
+  free(coordinate);
+}
+
+void testTypeTest() {
+  Coordinate c = Coordinate.allocate(10, 10, nullptr);
+  Expect.isTrue(c is Struct);
+  Expect.isTrue(c.addressOf is Pointer<Coordinate>);
+  free(c.addressOf);
+}
+
+void testUtf8() {
+  final String test = 'Hasta Mañana';
+  final Pointer<Utf8> medium = Utf8.toUtf8(test);
+  Expect.equals(test, Utf8.fromUtf8(medium));
+  free(medium);
+}
diff --git a/tests/language/async/or_generator_return_type_stacktrace_test.dart b/tests/language/async/or_generator_return_type_stacktrace_test.dart
index 35f1f2d..1e331db 100644
--- a/tests/language/async/or_generator_return_type_stacktrace_test.dart
+++ b/tests/language/async/or_generator_return_type_stacktrace_test.dart
@@ -11,12 +11,12 @@
 // [cfe] Functions marked 'async' must have a return type assignable to 'Future'.
 int badReturnTypeAsyncStar() async* {}
 // [error line 12, column 1, length 3]
-// [analyzer] STATIC_TYPE_WARNING.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE
+// [analyzer] COMPILE_TIME_ERROR.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE
 //  ^
 // [cfe] Functions marked 'async*' must have a return type assignable to 'Stream'.
 int badReturnTypeSyncStar() sync* {}
 // [error line 17, column 1, length 3]
-// [analyzer] STATIC_TYPE_WARNING.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE
+// [analyzer] COMPILE_TIME_ERROR.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE
 //  ^
 // [cfe] Functions marked 'sync*' must have a return type assignable to 'Iterable'.
 
diff --git a/tests/language/async_star/void_async_star_test.dart b/tests/language/async_star/void_async_star_test.dart
new file mode 100644
index 0000000..8e3c77d
--- /dev/null
+++ b/tests/language/async_star/void_async_star_test.dart
@@ -0,0 +1,38 @@
+// 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.
+
+// It is an error for an `async*` function to have return type `void`.
+
+import 'dart:async';
+
+/*space*/ void f1() async* {
+  //      ^^^^
+  // [analyzer] unspecified
+  // [cfe] unspecified
+}
+
+class C {
+  static void f2() async* {
+    //   ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  /*space*/ void f3() async* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+}
+
+void main() {
+  /*space*/ void f4() async* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  // No function literal: It is probably not possible to infer the
+  // return type `void` for a function literal marked `async*`.
+}
diff --git a/tests/language/call/closurization_test.dart b/tests/language/call/closurization_test.dart
index 683c229..102413b 100644
--- a/tests/language/call/closurization_test.dart
+++ b/tests/language/call/closurization_test.dart
@@ -3,6 +3,9 @@
 // BSD-style license that can be found in the LICENSE file.
 // VMOptions=--optimization_counter_threshold=10 --no-background_compilation
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 main() {
diff --git a/tests/language/class/variable_shadow_class_test.dart b/tests/language/class/variable_shadow_class_test.dart
index 5e24390..3fc29e4 100644
--- a/tests/language/class/variable_shadow_class_test.dart
+++ b/tests/language/class/variable_shadow_class_test.dart
@@ -15,9 +15,8 @@
     var Test;
     // Now this refers to the variable.
     var i = new Test.named(10);
-    //          ^^^^^^^^^^
-    // [analyzer] STATIC_WARNING.CREATION_WITH_NON_TYPE
     //          ^^^^
+    // [analyzer] COMPILE_TIME_ERROR.PREFIX_SHADOWED_BY_LOCAL_DECLARATION
     // [cfe] Method not found: 'Test.named'.
     Expect.equals(10, i.field);
   }
diff --git a/tests/language/const/const_locals_constant_locals_test.dart b/tests/language/const/const_locals_constant_locals_test.dart
index 9f937df..472687b 100644
--- a/tests/language/const/const_locals_constant_locals_test.dart
+++ b/tests/language/const/const_locals_constant_locals_test.dart
@@ -10,8 +10,7 @@
   const c1;
   //    ^^
   // [analyzer] COMPILE_TIME_ERROR.CONST_NOT_INITIALIZED
-  //      ^
-  // [cfe] The const variable ';' must be initialized.
+  // [cfe] The const variable 'c1' must be initialized.
   const c2 = 0;
   const c3 = field;
   //         ^^^^^
diff --git a/tests/language/deferred/deferred_and_immediate_import_lib.dart b/tests/language/deferred/deferred_and_immediate_import_lib.dart
new file mode 100644
index 0000000..61eeb08
--- /dev/null
+++ b/tests/language/deferred/deferred_and_immediate_import_lib.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  print("Foo!");
+}
diff --git a/tests/language/deferred/deferred_and_immediate_import_test.dart b/tests/language/deferred/deferred_and_immediate_import_test.dart
new file mode 100644
index 0000000..d54ca7e
--- /dev/null
+++ b/tests/language/deferred/deferred_and_immediate_import_test.dart
@@ -0,0 +1,19 @@
+// 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 "package:expect/expect.dart";
+
+import "deferred_and_immediate_import_lib.dart" as immediatePrefix;
+import "deferred_and_immediate_import_lib.dart" deferred as deferredPrefix;
+
+main() async {
+  immediatePrefix.foo();
+
+  Expect.throws(() {
+    deferredPrefix.foo();
+  });
+
+  await deferredPrefix.loadLibrary();
+  deferredPrefix.foo();
+}
diff --git a/tests/language/deferred/unreachable_loading_unit_deferred.dart b/tests/language/deferred/unreachable_loading_unit_deferred.dart
new file mode 100644
index 0000000..ca5f8bdc
--- /dev/null
+++ b/tests/language/deferred/unreachable_loading_unit_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  print("Foo");
+}
diff --git a/tests/language/deferred/unreachable_loading_unit_immediate.dart b/tests/language/deferred/unreachable_loading_unit_immediate.dart
new file mode 100644
index 0000000..a320045
--- /dev/null
+++ b/tests/language/deferred/unreachable_loading_unit_immediate.dart
@@ -0,0 +1,10 @@
+// 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 "unreachable_loading_unit_deferred.dart" deferred as lib;
+
+unreachable() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/tests/language/deferred/unreachable_loading_unit_test.dart b/tests/language/deferred/unreachable_loading_unit_test.dart
new file mode 100644
index 0000000..8a66342
--- /dev/null
+++ b/tests/language/deferred/unreachable_loading_unit_test.dart
@@ -0,0 +1,9 @@
+// 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 "unreachable_loading_unit_immediate.dart";
+
+main() {
+  print("Okay");
+}
diff --git a/tests/language/external_abstract_fields/abstract_fields_error_test.dart b/tests/language/external_abstract_fields/abstract_fields_error_test.dart
index 317b8ca..ca9fb38 100644
--- a/tests/language/external_abstract_fields/abstract_fields_error_test.dart
+++ b/tests/language/external_abstract_fields/abstract_fields_error_test.dart
@@ -7,11 +7,13 @@
 
 // Check that abstract declarations are abstract.
 class Abstract1 {
+//    ^
+// [cfe] The non-abstract class 'Abstract1' is missing implementations for these members:
+
   // The class is not abstract and does not have an implementation of `x`.
   abstract int x;
   //           ^
   // [analyzer] unspecified
-  // [cfe] unspecified
 }
 
 // Check that class has expected interface.
@@ -26,9 +28,10 @@
 
     // Cannot assign to final field.
     a.x = 42;
+    //^
+    // [cfe] The setter 'x' isn't defined for the class 'Abstract2'.
     //  ^
     // [analyzer] unspecified
-    // [cfe] unspecified
 
     String y = a.y;
     a.y = "ab";
@@ -37,7 +40,7 @@
     a.y = Object();
     //    ^^^^^^^^
     // [analyzer] unspecified
-    // [cfe] unspecified
+    // [cfe] A value of type 'Object' can't be assigned to a variable of type 'String'.
   }
 
   void test() {
@@ -45,9 +48,10 @@
 
     // Cannot assign to final field.
     this.x = 42;
+    //   ^
+    // [cfe] The setter 'x' isn't defined for the class 'Abstract2'.
     //     ^
     // [analyzer] unspecified
-    // [cfe] unspecified
 
     String y = this.y;
     this.y = "ab";
@@ -56,13 +60,13 @@
     this.y = Object();
     //       ^^^^^^^^
     // [analyzer] unspecified
-    // [cfe] unspecified
+    // [cfe] A value of type 'Object' can't be assigned to a variable of type 'String'.
   }
 }
 
-class Concrete2 implements Abstract2 {
-  final int x;
-  String y;
+class Concrete2 extends Abstract2 {
+  final int x = 0;
+  String y = '';
 }
 
 void main() {
diff --git a/tests/language/external_abstract_fields/abstract_fields_test.dart b/tests/language/external_abstract_fields/abstract_fields_test.dart
index 8deca66..c946ed7 100644
--- a/tests/language/external_abstract_fields/abstract_fields_test.dart
+++ b/tests/language/external_abstract_fields/abstract_fields_test.dart
@@ -66,7 +66,7 @@
   }
   int get y {
     lastName = #y;
-    return 0;
+    return _y;
   }
   set y(int value) {
     lastName = #y;
diff --git a/tests/language/external_abstract_fields/external_fields_test.dart b/tests/language/external_abstract_fields/external_fields_test.dart
index 58e792f..281fc97 100644
--- a/tests/language/external_abstract_fields/external_fields_test.dart
+++ b/tests/language/external_abstract_fields/external_fields_test.dart
@@ -3,7 +3,9 @@
 // BSD-style license that can be found in the LICENSE file.
 
 // Checks that external variable declarations are allowed.
-// Can only be statically checked, there is no implementation at run-time.
+// No implementation at run-time, so it throws.
+
+import 'package:expect/expect.dart';
 
 // External variables cannot be abstract, const, late or have an initializer.
 
@@ -32,30 +34,32 @@
   external int instance6;
 }
 
-void main() {
-  top1;
-  top1 = 0;
-  top2;
-  top3;
-  top3 = 0;
-  top4;
+void shouldThrow(Function() f) => Expect.throwsNoSuchMethodError(f);
 
-  C.static1;
-  C.static1 = 0;
-  C.static2;
-  C.static3;
-  C.static3 = 0;
-  C.static4;
+void main() {
+  shouldThrow(() => top1);
+  shouldThrow(() => top1 = 0);
+  shouldThrow(() => top2);
+  shouldThrow(() => top3);
+  shouldThrow(() => top3 = 0);
+  shouldThrow(() => top4);
+
+  shouldThrow(() => C.static1);
+  shouldThrow(() => C.static1 = 0);
+  shouldThrow(() => C.static2);
+  shouldThrow(() => C.static3);
+  shouldThrow(() => C.static3 = 0);
+  shouldThrow(() => C.static4);
 
   C c = C();
-  c.instance1;
-  c.instance1 = 0;
-  c.instance2;
-  c.instance3;
-  c.instance3 = 0;
-  c.instance4;
-  c.instance5;
-  c.instance5 = 0;
-  c.instance6;
-  c.instance6 = 0;
+  shouldThrow(() => c.instance1);
+  shouldThrow(() => c.instance1 = 0);
+  shouldThrow(() => c.instance2);
+  shouldThrow(() => c.instance3);
+  shouldThrow(() => c.instance3 = 0);
+  shouldThrow(() => c.instance4);
+  shouldThrow(() => c.instance5);
+  shouldThrow(() => c.instance5 = 0);
+  shouldThrow(() => c.instance6);
+  shouldThrow(() => c.instance6 = 0);
 }
diff --git a/tests/language/factory/return_type_checked_test.dart b/tests/language/factory/return_type_checked_test.dart
index c882f4f..0cff112 100644
--- a/tests/language/factory/return_type_checked_test.dart
+++ b/tests/language/factory/return_type_checked_test.dart
@@ -8,7 +8,7 @@
   factory A() => 42;
   //             ^^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] A value of type 'int' can't be assigned to a variable of type 'A'.
+  // [cfe] A value of type 'int' can't be returned from a function with return type 'A'.
 }
 
 main() {
diff --git a/tests/language/generic/function_bounds_test.dart b/tests/language/generic/function_bounds_test.dart
index 4ab11d3..d670e54 100644
--- a/tests/language/generic/function_bounds_test.dart
+++ b/tests/language/generic/function_bounds_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import 'dart:math';
 import 'package:expect/expect.dart';
 
diff --git a/tests/language/generic/instantiate_tearoff_test.dart b/tests/language/generic/instantiate_tearoff_test.dart
index 6a551f6..dc1afd4 100644
--- a/tests/language/generic/instantiate_tearoff_test.dart
+++ b/tests/language/generic/instantiate_tearoff_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 T f<T>(T x) => x;
diff --git a/tests/language/implicit_downcast_during/function_literal_arrow_test.dart b/tests/language/implicit_downcast_during/function_literal_arrow_test.dart
index 3f5950e..409ae5b 100644
--- a/tests/language/implicit_downcast_during/function_literal_arrow_test.dart
+++ b/tests/language/implicit_downcast_during/function_literal_arrow_test.dart
@@ -11,5 +11,5 @@
   B Function(A) f = (A a) => a;
   //                         ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE_FROM_CLOSURE
-  // [cfe] A value of type 'A' can't be assigned to a variable of type 'B'.
+  // [cfe] A value of type 'A' can't be returned from a function with return type 'B'.
 }
diff --git a/tests/language/implicit_downcast_during/function_literal_return_test.dart b/tests/language/implicit_downcast_during/function_literal_return_test.dart
index f7862a1..1c7a056 100644
--- a/tests/language/implicit_downcast_during/function_literal_return_test.dart
+++ b/tests/language/implicit_downcast_during/function_literal_return_test.dart
@@ -12,6 +12,6 @@
     return a;
     //     ^
     // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE_FROM_CLOSURE
-    // [cfe] A value of type 'A' can't be assigned to a variable of type 'B'.
+    // [cfe] A value of type 'A' can't be returned from a function with return type 'B'.
   };
 }
diff --git a/tests/language/implicit_downcast_during/return_async_test.dart b/tests/language/implicit_downcast_during/return_async_test.dart
index a976d1e..34d041e 100644
--- a/tests/language/implicit_downcast_during/return_async_test.dart
+++ b/tests/language/implicit_downcast_during/return_async_test.dart
@@ -13,14 +13,14 @@
   //     ^^^^^^^^^^^^^^^^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
   //       ^
-  // [cfe] A value of type 'FutureOr<A>' can't be assigned to a variable of type 'B'.
+  // [cfe] A value of type 'FutureOr<A>' can't be returned from an async function with return type 'Future<B>'.
 }
 
 Future<B> f2(A a) async => a as FutureOr<A>;
 //                         ^^^^^^^^^^^^^^^^
 // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
 //                           ^
-// [cfe] A value of type 'FutureOr<A>' can't be assigned to a variable of type 'B'.
+// [cfe] A value of type 'FutureOr<A>' can't be returned from an async function with return type 'Future<B>'.
 
 main() async {
   Object b;
diff --git a/tests/language/implicit_downcast_during/return_test.dart b/tests/language/implicit_downcast_during/return_test.dart
index 3bbffe8..e858dc4 100644
--- a/tests/language/implicit_downcast_during/return_test.dart
+++ b/tests/language/implicit_downcast_during/return_test.dart
@@ -10,13 +10,13 @@
   return a;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] A value of type 'A' can't be assigned to a variable of type 'B'.
+  // [cfe] A value of type 'A' can't be returned from a function with return type 'B'.
 }
 
 B f2(A a) => a;
 //           ^
 // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-// [cfe] A value of type 'A' can't be assigned to a variable of type 'B'.
+// [cfe] A value of type 'A' can't be returned from a function with return type 'B'.
 
 void main() {
   Object b;
diff --git a/tests/language/import/name_clash_lib1.dart b/tests/language/import/name_clash_lib1.dart
new file mode 100644
index 0000000..8fbfaf3
--- /dev/null
+++ b/tests/language/import/name_clash_lib1.dart
@@ -0,0 +1,5 @@
+// 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.
+
+library clashing.nonempty.name;
diff --git a/tests/language/import/name_clash_lib2.dart b/tests/language/import/name_clash_lib2.dart
new file mode 100644
index 0000000..8fbfaf3
--- /dev/null
+++ b/tests/language/import/name_clash_lib2.dart
@@ -0,0 +1,5 @@
+// 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.
+
+library clashing.nonempty.name;
diff --git a/tests/language/import/name_clash_test.dart b/tests/language/import/name_clash_test.dart
new file mode 100644
index 0000000..72d06a5
--- /dev/null
+++ b/tests/language/import/name_clash_test.dart
@@ -0,0 +1,13 @@
+// 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.
+
+// Check that a library name clash is not an error.
+
+import "name_clash_lib1.dart";
+import "name_clash_lib2.dart";
+
+export "name_clash_lib1.dart";
+export "name_clash_lib2.dart";
+
+main() {}
diff --git a/tests/language/invalid_returns/async_invalid_return_00_test.dart b/tests/language/invalid_returns/async_invalid_return_00_test.dart
index 6df2790..b5e14e1 100644
--- a/tests/language/invalid_returns/async_invalid_return_00_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_00_test.dart
@@ -12,14 +12,14 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 Object? test2() async {
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 // Inferred return type of function literal is `Future<Null>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_01_test.dart b/tests/language/invalid_returns/async_invalid_return_01_test.dart
index e2b0e9b..a502d3f0 100644
--- a/tests/language/invalid_returns/async_invalid_return_01_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_01_test.dart
@@ -12,14 +12,14 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 Future<int> Function() test2 = () async {
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_02_test.dart b/tests/language/invalid_returns/async_invalid_return_02_test.dart
index 1b36160..ad814cf 100644
--- a/tests/language/invalid_returns/async_invalid_return_02_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_02_test.dart
@@ -12,14 +12,14 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 FutureOr<int> Function() test2 = () async {
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_03_test.dart b/tests/language/invalid_returns/async_invalid_return_03_test.dart
index 7845404..4b42e26 100644
--- a/tests/language/invalid_returns/async_invalid_return_03_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_03_test.dart
@@ -12,7 +12,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 // Inferred return type of function literal is `Future<Null>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_04_test.dart b/tests/language/invalid_returns/async_invalid_return_04_test.dart
index 4c0b193..648a1af 100644
--- a/tests/language/invalid_returns/async_invalid_return_04_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_04_test.dart
@@ -12,7 +12,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void async function.
 }
 
 // Inferred return type of function literal is `Future<Null>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_05_test.dart b/tests/language/invalid_returns/async_invalid_return_05_test.dart
index d11a4b5..5ef7b9a 100644
--- a/tests/language/invalid_returns/async_invalid_return_05_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_05_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_08_test.dart b/tests/language/invalid_returns/async_invalid_return_08_test.dart
index 09950ac..e8f283d 100644
--- a/tests/language/invalid_returns/async_invalid_return_08_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_08_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<Object>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_11_test.dart b/tests/language/invalid_returns/async_invalid_return_11_test.dart
index b85f731..f0fc113 100644
--- a/tests/language/invalid_returns/async_invalid_return_11_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_11_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>?' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<int?>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Future<int>?' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_14_test.dart b/tests/language/invalid_returns/async_invalid_return_14_test.dart
index 3eaa715..77458a8 100644
--- a/tests/language/invalid_returns/async_invalid_return_14_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_14_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_17_test.dart b/tests/language/invalid_returns/async_invalid_return_17_test.dart
index f347a21..0cac976 100644
--- a/tests/language/invalid_returns/async_invalid_return_17_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_17_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<Object>' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<Object>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Future<Object>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_20_test.dart b/tests/language/invalid_returns/async_invalid_return_20_test.dart
index 5b54f78..ef44111 100644
--- a/tests/language/invalid_returns/async_invalid_return_20_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_20_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<Object>' can't be returned from an async function with return type 'void'.
 }
 
-// Inferred return type of function literal is `Future<Object>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 void Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'FutureOr<Object>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_23_test.dart b/tests/language/invalid_returns/async_invalid_return_23_test.dart
index f496a74..37b6fdb 100644
--- a/tests/language/invalid_returns/async_invalid_return_23_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_23_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'Object'.
 }
 
 Object? test2() async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'Object?'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_24_test.dart b/tests/language/invalid_returns/async_invalid_return_24_test.dart
index 1ccbca7..1a57405 100644
--- a/tests/language/invalid_returns/async_invalid_return_24_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_24_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>?' can't be returned from an async function with return type 'Object'.
 }
 
 Object? test2() async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>?' can't be returned from an async function with return type 'Object?'.
 }
 
 // Inferred return type of function literal is `Future<void?>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_25_test.dart b/tests/language/invalid_returns/async_invalid_return_25_test.dart
index 5991e70..c080c43 100644
--- a/tests/language/invalid_returns/async_invalid_return_25_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_25_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Object'.
 }
 
 Object? test2() async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Object?'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_26_test.dart b/tests/language/invalid_returns/async_invalid_return_26_test.dart
index d99d60c..729e3dc 100644
--- a/tests/language/invalid_returns/async_invalid_return_26_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_26_test.dart
@@ -18,7 +18,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'Future<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_27_test.dart b/tests/language/invalid_returns/async_invalid_return_27_test.dart
index 6b2faba..4650891 100644
--- a/tests/language/invalid_returns/async_invalid_return_27_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_27_test.dart
@@ -17,7 +17,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_28_test.dart b/tests/language/invalid_returns/async_invalid_return_28_test.dart
index 416b127..dd02198 100644
--- a/tests/language/invalid_returns/async_invalid_return_28_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_28_test.dart
@@ -17,7 +17,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Future<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_29_test.dart b/tests/language/invalid_returns/async_invalid_return_29_test.dart
index dd8a9e2..b2c96c0 100644
--- a/tests/language/invalid_returns/async_invalid_return_29_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_29_test.dart
@@ -18,7 +18,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'FutureOr<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_30_test.dart b/tests/language/invalid_returns/async_invalid_return_30_test.dart
index 605f4c9..b8e09b5 100644
--- a/tests/language/invalid_returns/async_invalid_return_30_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_30_test.dart
@@ -17,7 +17,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'FutureOr<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_31_test.dart b/tests/language/invalid_returns/async_invalid_return_31_test.dart
index 9d5ac6c..f35985b 100644
--- a/tests/language/invalid_returns/async_invalid_return_31_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_31_test.dart
@@ -17,7 +17,7 @@
   return v;
   //     ^
   // [analyzer] STATIC_TYPE_WARNING.RETURN_OF_INVALID_TYPE
-  // [cfe] This expression has type 'void' and can't be used.
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'FutureOr<int>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_32_test.dart b/tests/language/invalid_returns/async_invalid_return_32_test.dart
index eaac876..0c2f96d 100644
--- a/tests/language/invalid_returns/async_invalid_return_32_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_32_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'Future<Object?>'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_33_test.dart b/tests/language/invalid_returns/async_invalid_return_33_test.dart
index 971b4aa..30c61e6 100644
--- a/tests/language/invalid_returns/async_invalid_return_33_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_33_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<Object?>'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_34_test.dart b/tests/language/invalid_returns/async_invalid_return_34_test.dart
index 5815421..d538239 100644
--- a/tests/language/invalid_returns/async_invalid_return_34_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_34_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Future<Object?>'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_35_test.dart b/tests/language/invalid_returns/async_invalid_return_35_test.dart
index b9ddf70..8776631 100644
--- a/tests/language/invalid_returns/async_invalid_return_35_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_35_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from an async function with return type 'FutureOr<Object?>'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_36_test.dart b/tests/language/invalid_returns/async_invalid_return_36_test.dart
index 7586e9a..d79404d 100644
--- a/tests/language/invalid_returns/async_invalid_return_36_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_36_test.dart
@@ -15,21 +15,21 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'FutureOr<Object>'.
 }
 
 FutureOr<Object?> test2() async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'FutureOr<Object?>'.
 }
 
 FutureOr<Object> Function() test3 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<Object>'.
 };
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_37_test.dart b/tests/language/invalid_returns/async_invalid_return_37_test.dart
index 6b0496d..da078a4 100644
--- a/tests/language/invalid_returns/async_invalid_return_37_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_37_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'FutureOr<Object?>'.
 }
 
 // Inferred return type of function literal is `Future<void>`, no error.
diff --git a/tests/language/invalid_returns/async_invalid_return_38_test.dart b/tests/language/invalid_returns/async_invalid_return_38_test.dart
index 3f18592..09a761b 100644
--- a/tests/language/invalid_returns/async_invalid_return_38_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_38_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<String>'.
 }
 
 Future<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_39_test.dart b/tests/language/invalid_returns/async_invalid_return_39_test.dart
index 80deb7f..03879e4 100644
--- a/tests/language/invalid_returns/async_invalid_return_39_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_39_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<String>'.
 }
 
 Future<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_40_test.dart b/tests/language/invalid_returns/async_invalid_return_40_test.dart
index 71589c8..9fc9eb0 100644
--- a/tests/language/invalid_returns/async_invalid_return_40_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_40_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<num>' can't be returned from an async function with return type 'Future<int>'.
 }
 
 Future<int> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<num>' can't be returned from an async function with return type 'Future<int>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_41_test.dart b/tests/language/invalid_returns/async_invalid_return_41_test.dart
index d68b8ef..819d0df 100644
--- a/tests/language/invalid_returns/async_invalid_return_41_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_41_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<Future<String>>' can't be returned from an async function with return type 'Future<String>'.
 }
 
 Future<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<Future<String>>' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_42_test.dart b/tests/language/invalid_returns/async_invalid_return_42_test.dart
index 0988253..1c5e414 100644
--- a/tests/language/invalid_returns/async_invalid_return_42_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_42_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'FutureOr<String>'.
 }
 
 FutureOr<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_43_test.dart b/tests/language/invalid_returns/async_invalid_return_43_test.dart
index dbb5b1d..0ae4774 100644
--- a/tests/language/invalid_returns/async_invalid_return_43_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_43_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'FutureOr<String>'.
 }
 
 FutureOr<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_44_test.dart b/tests/language/invalid_returns/async_invalid_return_44_test.dart
index c9adfeb..56a1092 100644
--- a/tests/language/invalid_returns/async_invalid_return_44_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_44_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'FutureOr<String>'.
 }
 
 FutureOr<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_45_test.dart b/tests/language/invalid_returns/async_invalid_return_45_test.dart
index bf75dc2..5811b57 100644
--- a/tests/language/invalid_returns/async_invalid_return_45_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_45_test.dart
@@ -15,14 +15,14 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<Future<String>>' can't be returned from an async function with return type 'FutureOr<String>'.
 }
 
 FutureOr<String> Function() test2 = () async {
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<Future<String>>' can't be returned from an async function with return type 'Future<String>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_47_test.dart b/tests/language/invalid_returns/async_invalid_return_47_test.dart
index e39b36c..0ee1f2b 100644
--- a/tests/language/invalid_returns/async_invalid_return_47_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_47_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<Null>'.
 }
 
 // Inferred return type of function literal is `Future<Null>`.
@@ -23,7 +23,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<Null>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_48_test.dart b/tests/language/invalid_returns/async_invalid_return_48_test.dart
index d60f948..b97e745 100644
--- a/tests/language/invalid_returns/async_invalid_return_48_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_48_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Future<Null>'.
 }
 
 // Inferred return type of function literal is `Future<Null>`.
@@ -23,7 +23,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Future<Null>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_50_test.dart b/tests/language/invalid_returns/async_invalid_return_50_test.dart
index 236f512..0169b9e 100644
--- a/tests/language/invalid_returns/async_invalid_return_50_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_50_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'FutureOr<Null>'.
 }
 
 // Inferred return type of function literal is `Future<Null>`.
@@ -23,7 +23,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<void>' can't be returned from an async function with return type 'Future<Null>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_51_test.dart b/tests/language/invalid_returns/async_invalid_return_51_test.dart
index 3448c14..d8c0cf9 100644
--- a/tests/language/invalid_returns/async_invalid_return_51_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_51_test.dart
@@ -15,7 +15,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'FutureOr<Null>'.
 }
 
 // Inferred return type of function literal is `Future<Null>`.
@@ -23,7 +23,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<void>' can't be returned from an async function with return type 'Future<Null>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_52_test.dart b/tests/language/invalid_returns/async_invalid_return_52_test.dart
index 8f086b2..4c951e9 100644
--- a/tests/language/invalid_returns/async_invalid_return_52_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_52_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 Future<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_53_test.dart b/tests/language/invalid_returns/async_invalid_return_53_test.dart
index d51ae11..5647bdb 100644
--- a/tests/language/invalid_returns/async_invalid_return_53_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_53_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'Future<void>'.
 }
 
-// Inferred return type of function literal is `Future<Object>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 Future<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_54_test.dart b/tests/language/invalid_returns/async_invalid_return_54_test.dart
index 4dd661a..a85a38a 100644
--- a/tests/language/invalid_returns/async_invalid_return_54_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_54_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'Future<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 Future<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_55_test.dart b/tests/language/invalid_returns/async_invalid_return_55_test.dart
index 72f9440..ea710ad 100644
--- a/tests/language/invalid_returns/async_invalid_return_55_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_55_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 Future<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_56_test.dart b/tests/language/invalid_returns/async_invalid_return_56_test.dart
index 9443436..ee25201 100644
--- a/tests/language/invalid_returns/async_invalid_return_56_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_56_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'FutureOr<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 FutureOr<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'int' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_57_test.dart b/tests/language/invalid_returns/async_invalid_return_57_test.dart
index 633be93..5c243f7 100644
--- a/tests/language/invalid_returns/async_invalid_return_57_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_57_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'FutureOr<void>'.
 }
 
-// Inferred return type of function literal is `Future<Object>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 FutureOr<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Object' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_58_test.dart b/tests/language/invalid_returns/async_invalid_return_58_test.dart
index 4d508eb..f0e387e7b 100644
--- a/tests/language/invalid_returns/async_invalid_return_58_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_58_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'FutureOr<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 FutureOr<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/async_invalid_return_59_test.dart b/tests/language/invalid_returns/async_invalid_return_59_test.dart
index 95399b9..4e52a29 100644
--- a/tests/language/invalid_returns/async_invalid_return_59_test.dart
+++ b/tests/language/invalid_returns/async_invalid_return_59_test.dart
@@ -15,12 +15,15 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'FutureOr<void>'.
 }
 
-// Inferred return type of function literal is `Future<int>`, no error.
+// Inferred return type of function literal is `Future<void>`.
 FutureOr<void> Function() test2 = () async {
   return v;
+  //     ^
+  // [analyzer] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from an async function with return type 'Future<void>'.
 };
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_00_test.dart b/tests/language/invalid_returns/sync_invalid_return_00_test.dart
index 1c368e0..2519193 100644
--- a/tests/language/invalid_returns/sync_invalid_return_00_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_00_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_01_test.dart b/tests/language/invalid_returns/sync_invalid_return_01_test.dart
index a290916..2e04fe8 100644
--- a/tests/language/invalid_returns/sync_invalid_return_01_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_01_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_02_test.dart b/tests/language/invalid_returns/sync_invalid_return_02_test.dart
index 05db4f2..3009f48 100644
--- a/tests/language/invalid_returns/sync_invalid_return_02_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_02_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_03_test.dart b/tests/language/invalid_returns/sync_invalid_return_03_test.dart
index 4116191..d031ecfa 100644
--- a/tests/language/invalid_returns/sync_invalid_return_03_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_03_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_04_test.dart b/tests/language/invalid_returns/sync_invalid_return_04_test.dart
index 1a80d62..6e26a3a 100644
--- a/tests/language/invalid_returns/sync_invalid_return_04_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_04_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_05_test.dart b/tests/language/invalid_returns/sync_invalid_return_05_test.dart
index 27daec4..1c3d43c 100644
--- a/tests/language/invalid_returns/sync_invalid_return_05_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_05_test.dart
@@ -11,7 +11,7 @@
   return;
 //^
 // [analyzer] unspecified
-// [cfe] unspecified
+// [cfe] A value must be explicitly returned from a non-void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_06_test.dart b/tests/language/invalid_returns/sync_invalid_return_06_test.dart
index e7530f1..b5b41c3 100644
--- a/tests/language/invalid_returns/sync_invalid_return_06_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_06_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_07_test.dart b/tests/language/invalid_returns/sync_invalid_return_07_test.dart
index 691cf5d..6a03677 100644
--- a/tests/language/invalid_returns/sync_invalid_return_07_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_07_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_08_test.dart b/tests/language/invalid_returns/sync_invalid_return_08_test.dart
index 94067eb..762714b 100644
--- a/tests/language/invalid_returns/sync_invalid_return_08_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_08_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_09_test.dart b/tests/language/invalid_returns/sync_invalid_return_09_test.dart
index b4bca3e..b7a8981 100644
--- a/tests/language/invalid_returns/sync_invalid_return_09_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_09_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_10_test.dart b/tests/language/invalid_returns/sync_invalid_return_10_test.dart
index 26508b3..f57003b 100644
--- a/tests/language/invalid_returns/sync_invalid_return_10_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_10_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_11_test.dart b/tests/language/invalid_returns/sync_invalid_return_11_test.dart
index cfdef54..2d9cf3e 100644
--- a/tests/language/invalid_returns/sync_invalid_return_11_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_11_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] Can't return a value from a void function.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_12_test.dart b/tests/language/invalid_returns/sync_invalid_return_12_test.dart
index 23b45a4..e6ace80 100644
--- a/tests/language/invalid_returns/sync_invalid_return_12_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_12_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'int'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_13_test.dart b/tests/language/invalid_returns/sync_invalid_return_13_test.dart
index cadaa24..5abb52b 100644
--- a/tests/language/invalid_returns/sync_invalid_return_13_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_13_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'Object?'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_14_test.dart b/tests/language/invalid_returns/sync_invalid_return_14_test.dart
index 0082e8e..8cd50e2 100644
--- a/tests/language/invalid_returns/sync_invalid_return_14_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_14_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'Future<int>?'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_15_test.dart b/tests/language/invalid_returns/sync_invalid_return_15_test.dart
index 0bbb367..b586861 100644
--- a/tests/language/invalid_returns/sync_invalid_return_15_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_15_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'FutureOr<int?>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_16_test.dart b/tests/language/invalid_returns/sync_invalid_return_16_test.dart
index d2a2cd9..897f5a9 100644
--- a/tests/language/invalid_returns/sync_invalid_return_16_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_16_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'Future<Object>?'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_17_test.dart b/tests/language/invalid_returns/sync_invalid_return_17_test.dart
index 4834cd6..493faf0 100644
--- a/tests/language/invalid_returns/sync_invalid_return_17_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_17_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'FutureOr<Object?>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_18_test.dart b/tests/language/invalid_returns/sync_invalid_return_18_test.dart
index 24abec0..de1f9a2 100644
--- a/tests/language/invalid_returns/sync_invalid_return_18_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_18_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from a function with return type 'String'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_19_test.dart b/tests/language/invalid_returns/sync_invalid_return_19_test.dart
index 7e0d3df..613cadc 100644
--- a/tests/language/invalid_returns/sync_invalid_return_19_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_19_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from a function with return type 'String'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_20_test.dart b/tests/language/invalid_returns/sync_invalid_return_20_test.dart
index a057f8f..928168c 100644
--- a/tests/language/invalid_returns/sync_invalid_return_20_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_20_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int?>' can't be returned from a function with return type 'String'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_21_test.dart b/tests/language/invalid_returns/sync_invalid_return_21_test.dart
index 140508e..fc1c898 100644
--- a/tests/language/invalid_returns/sync_invalid_return_21_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_21_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from a function with return type 'Future<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_22_test.dart b/tests/language/invalid_returns/sync_invalid_return_22_test.dart
index b1e2dc7..47a2401 100644
--- a/tests/language/invalid_returns/sync_invalid_return_22_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_22_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from a function with return type 'Future<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_23_test.dart b/tests/language/invalid_returns/sync_invalid_return_23_test.dart
index 2b9a833..a9d4ab7 100644
--- a/tests/language/invalid_returns/sync_invalid_return_23_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_23_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int>' can't be returned from a function with return type 'Future<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_24_test.dart b/tests/language/invalid_returns/sync_invalid_return_24_test.dart
index 5606fd4..cbc5b15 100644
--- a/tests/language/invalid_returns/sync_invalid_return_24_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_24_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'int' can't be returned from a function with return type 'FutureOr<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_25_test.dart b/tests/language/invalid_returns/sync_invalid_return_25_test.dart
index 90014c9..ac9c262 100644
--- a/tests/language/invalid_returns/sync_invalid_return_25_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_25_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'Future<int>' can't be returned from a function with return type 'FutureOr<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_26_test.dart b/tests/language/invalid_returns/sync_invalid_return_26_test.dart
index 1ea644f..ec1ff2e 100644
--- a/tests/language/invalid_returns/sync_invalid_return_26_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_26_test.dart
@@ -13,7 +13,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'FutureOr<int?>' can't be returned from a function with return type 'FutureOr<String>'.
 }
 
 void main() {
diff --git a/tests/language/invalid_returns/sync_invalid_return_27_test.dart b/tests/language/invalid_returns/sync_invalid_return_27_test.dart
index 0361ee2..d3d6999 100644
--- a/tests/language/invalid_returns/sync_invalid_return_27_test.dart
+++ b/tests/language/invalid_returns/sync_invalid_return_27_test.dart
@@ -14,7 +14,7 @@
   return v;
   //     ^
   // [analyzer] unspecified
-  // [cfe] unspecified
+  // [cfe] A value of type 'void' can't be returned from a function with return type 'Null'.
 }
 
 void main() {
diff --git a/tests/language/language.status b/tests/language/language.status
index 266988d..3764b4c 100644
--- a/tests/language/language.status
+++ b/tests/language/language.status
@@ -35,6 +35,9 @@
 stack_trace/demangle_ctors_test: SkipByDesign # Names are not scrubbed.
 type/checks_in_factory_method_test: SkipByDesign # Requires checked mode.
 
+[ $compiler != dart2analyzer && $compiler != fasta ]
+identifier/built_in_type_annotation_test/*: SkipByDesign # Analyzer/CFE only tests.
+
 [ $compiler != dart2js && $compiler != dartdevc && !$checked ]
 function_type/*: Skip # Needs checked mode.
 
diff --git a/tests/language/lazy/static8_test.dart b/tests/language/lazy/static8_test.dart
index 953129c..de313a8 100644
--- a/tests/language/lazy/static8_test.dart
+++ b/tests/language/lazy/static8_test.dart
@@ -8,7 +8,7 @@
 
 var trace;
 
-final foo = bar;
+var foo = bar;
 
 var recursionDepth = 0;
 
@@ -40,7 +40,7 @@
 }
 
 class X {
-  static final foo = X.bar;
+  static var foo = X.bar;
 
   static get bar {
     if (recursionDepth > 3) throw "recursed";
diff --git a/tests/language/nnbd/constant_null_safety_mode_test.dart b/tests/language/nnbd/constant_null_safety_mode_test.dart
index 1383449..131a2ff 100644
--- a/tests/language/nnbd/constant_null_safety_mode_test.dart
+++ b/tests/language/nnbd/constant_null_safety_mode_test.dart
@@ -7,4 +7,18 @@
 main() {
   const trueInWeakMode = <Null>[] is List<int>;
   Expect.equals(isWeakMode, trueInWeakMode);
+
+  // The following tests use the Uri.pathSegments() to access a constant list
+  // that is defined in the SDK and verify the type associated with it does not
+  // allow null when running with sound null safety.
+  var emptyUri = Uri(pathSegments: []);
+  dynamic stringList = emptyUri.pathSegments.toList();
+  if (isStrongMode) {
+    Expect.throwsTypeError(() {
+      stringList.add(null);
+    });
+  } else {
+    stringList.add(null);
+    Expect.listEquals([null], stringList);
+  }
 }
diff --git a/tests/language/nnbd/flow_analysis/issue41981_error_test.dart b/tests/language/nnbd/flow_analysis/issue41981_error_test.dart
new file mode 100644
index 0000000..1ff4339
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/issue41981_error_test.dart
@@ -0,0 +1,23 @@
+// 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.
+
+// This test verifies that a block of code that results from promotion to the
+// `Never` type cannot affect the "definitely unassigned" state of a late
+// variable, because promotion to `Never` causes the code to be considered
+// unreachable.
+
+// SharedOptions=--enable-experiment=non-nullable
+
+main() {
+  late int i;
+  Null n = null;
+  if (n != null) {
+    // n has type `Never`, so this code is unreachable.
+    i = 42;
+  }
+  i; // Variable is definitely unassigned
+//^
+// [analyzer] COMPILE_TIME_ERROR.DEFINITELY_UNASSIGNED_LATE_LOCAL_VARIABLE
+// [cfe] Non-nullable late variable 'i' without initializer is definitely unassigned.
+}
diff --git a/tests/language/nnbd/flow_analysis/late_var_assigned_in_try_test.dart b/tests/language/nnbd/flow_analysis/late_var_assigned_in_try_test.dart
new file mode 100644
index 0000000..f0fca1a
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/late_var_assigned_in_try_test.dart
@@ -0,0 +1,34 @@
+// 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.
+
+// This test verifies that when a late variable is assigned in a try block and
+// read in a catch or finally block, that there is no compile-time error,
+// because the assignment might happen prior to the exception occurring.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void tryCatch() {
+  late int x;
+  try {
+    x = 10;
+    throw 'foo';
+  } catch (_) {
+    Expect.equals(x, 10);
+  }
+}
+
+void tryFinally() {
+  late int x;
+  try {
+    x = 10;
+  } finally {
+    Expect.equals(x, 10);
+  }
+}
+
+main() {
+  tryCatch();
+  tryFinally();
+}
diff --git a/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_local_function_ok_test.dart b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_local_function_ok_test.dart
new file mode 100644
index 0000000..aaf6a87
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_local_function_ok_test.dart
@@ -0,0 +1,60 @@
+// 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.
+
+// This test verifies that when a late variable might be read prior to its first
+// assignment, but the semantics of local functions allow for the possibility
+// that the assignment might occur before the read, that there is no
+// compile-time error.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+// First scenario: the variable is written inside the function, and the read
+// happens after the function is created.
+void writeInFunction() {
+  late int x;
+  void f() {
+    x = 10;
+  }
+
+  f();
+  Expect.equals(x, 10);
+}
+
+void writeInClosure() {
+  late int x;
+  var f = () {
+    x = 10;
+  };
+  f();
+  Expect.equals(x, 10);
+}
+
+// Second scenario: the variable is written outside the function, and the read
+// happens inside the function.
+void readInFunction() {
+  late int x;
+  void f() {
+    Expect.equals(x, 10);
+  }
+
+  x = 10;
+  f();
+}
+
+void readInClosure() {
+  late int x;
+  var f = () {
+    Expect.equals(x, 10);
+  };
+  x = 10;
+  f();
+}
+
+main() {
+  writeInFunction();
+  writeInClosure();
+  readInFunction();
+  readInClosure();
+}
diff --git a/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_loop_test.dart b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_loop_test.dart
new file mode 100644
index 0000000..09eef1c
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_loop_test.dart
@@ -0,0 +1,70 @@
+// 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.
+
+// This test verifies that when a late variable is read prior to its first
+// assignment, but the read and the assignment occur within the body of a loop,
+// that there is no compile-time error, because the assignment may happen in an
+// earlier iteration than the read.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void forLoop() {
+  late int x;
+  for (int i = 0; i < 2; i++) {
+    if (i == 1) {
+      Expect.equals(x, 10);
+    }
+    if (i == 0) {
+      x = 10;
+    }
+  }
+}
+
+void forEach() {
+  late int x;
+  for (bool b in [false, true]) {
+    if (b) {
+      Expect.equals(x, 10);
+    }
+    if (!b) {
+      x = 10;
+    }
+  }
+}
+
+void whileLoop() {
+  late int x;
+  int i = 0;
+  while (i < 2) {
+    if (i == 1) {
+      Expect.equals(x, 10);
+    }
+    if (i == 0) {
+      x = 10;
+    }
+    i++;
+  }
+}
+
+void doLoop() {
+  late int x;
+  int i = 0;
+  do {
+    if (i == 1) {
+      Expect.equals(x, 10);
+    }
+    if (i == 0) {
+      x = 10;
+    }
+    i++;
+  } while (i < 2);
+}
+
+main() {
+  forLoop();
+  forEach();
+  whileLoop();
+  doLoop();
+}
diff --git a/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_error_test.dart b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_error_test.dart
new file mode 100644
index 0000000..59b5a20
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_error_test.dart
@@ -0,0 +1,31 @@
+// 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.
+
+// This test verifies that when a late variable is read prior to its first
+// assignment, and the read occurs within the body of an unlabelled case block,
+// and the assignment occurs elsewhere in the switch, that there is a
+// compile-time error, because the variable is unassigned on all possible
+// control flow paths to the read.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void switchBad(int value) {
+  late int x;
+  switch (value) {
+    case 0:
+      Expect.equals(x, 10);
+      //            ^
+      // [analyzer] COMPILE_TIME_ERROR.DEFINITELY_UNASSIGNED_LATE_LOCAL_VARIABLE
+      // [cfe] Non-nullable late variable 'x' without initializer is definitely unassigned.
+      break;
+    case 1:
+      x = 10;
+      break;
+  }
+}
+
+main() {
+  switchBad(1);
+}
diff --git a/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_test.dart b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_test.dart
new file mode 100644
index 0000000..edb6b6e
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/late_var_used_before_assignment_in_switch_test.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.
+
+// This test verifies that when a late variable is read prior to its first
+// assignment, but the read occurs within the body of a labelled case block, and
+// the assignment occurs somewhere in the switch, that there is no compile-time
+// error, because the assignment may happen prior to a branch to the label.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void switchOk(int one) {
+  late int x;
+  switch (one) {
+    L:
+    case 0:
+      Expect.equals(x, 10);
+      break;
+    case 1:
+      x = 10;
+      continue L;
+  }
+}
+
+main() {
+  switchOk(1);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_error_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_error_test.dart
new file mode 100644
index 0000000..fe6c7db
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_error_test.dart
@@ -0,0 +1,30 @@
+// 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.
+
+// This test verifies that if a read is performed on a getter whose type is
+// `Never?`, the resulting code block is considered reachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+
+Never? get neverQuestionGetter => null;
+
+void explicitNeverQuestionType(Object x, bool b) {
+  if (x is! int) {
+    if (b) {
+      neverQuestionGetter;
+    } else {
+      return;
+    }
+  }
+  // Since the read of `neverQuestionGetter` was reachable, `x` is not promoted
+  // to `int`.
+  x.isEven;
+//  ^^^^^^
+// [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+// [cfe] unspecified
+}
+
+main() {
+  explicitNeverQuestionType(0, true);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_test.dart
new file mode 100644
index 0000000..af54180
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_getter_get_test.dart
@@ -0,0 +1,46 @@
+// 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.
+
+// This test verifies that if a read is performed on a getter whose type is
+// `Never`, the resulting code block is considered unreachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+Never get neverGetter => throw 'x';
+
+void explicitNeverType(Object x, bool b) {
+  if (x is! int) {
+    if (b) {
+      neverGetter; // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since the read of `neverGetter` was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+class TypeVarExtendsNever<T extends Never> {
+  T get tGetter => throw 'x';
+
+  void test(Object x, bool b) {
+    if (x is! int) {
+      if (b) {
+        tGetter; // Unreachable
+      } else {
+        return;
+      }
+    }
+    // Since the read of `tGetter` was unreachable, `x` is now promoted to
+    // `int`.
+    Expect.isTrue(x.isEven);
+  }
+}
+
+main() {
+  explicitNeverType(0, false);
+  TypeVarExtendsNever<Never>().test(0, false);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_invocation_error_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_invocation_error_test.dart
new file mode 100644
index 0000000..e5b9c32
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_invocation_error_test.dart
@@ -0,0 +1,30 @@
+// 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.
+
+// This test verifies that if a method is invoked whose return type is `Never?`,
+// the resulting code block is considered reachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+
+Never? neverQuestionFunction() => null;
+
+void explicitNeverQuestionType(Object x, bool b) {
+  if (x is! int) {
+    if (b) {
+      neverQuestionFunction();
+    } else {
+      return;
+    }
+  }
+  // Since completion of `neverQuestionFunction` was reachable, `x` is not
+  // promoted to `int`.
+  x.isEven;
+//  ^^^^^^
+// [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+// [cfe] unspecified
+}
+
+main() {
+  explicitNeverQuestionType(0, true);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_invocation_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_invocation_test.dart
new file mode 100644
index 0000000..d059c4d
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_invocation_test.dart
@@ -0,0 +1,46 @@
+// 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.
+
+// This test verifies that if a method is invoked whose return type is `Never`,
+// the resulting code block is considered unreachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+Never neverFunction() => throw 'x';
+
+void explicitNeverType(Object x, bool b) {
+  if (x is! int) {
+    if (b) {
+      neverFunction(); // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since completion of `neverFunction` was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+class TypeVarExtendsNever<T extends Never> {
+  T tMethod() => throw 'x';
+
+  void test(Object x, bool b) {
+    if (x is! int) {
+      if (b) {
+        tMethod(); // Unreachable
+      } else {
+        return;
+      }
+    }
+    // Since completion of `tMethod` was unreachable, `x` is now promoted to
+    // `int`.
+    Expect.isTrue(x.isEven);
+  }
+}
+
+main() {
+  explicitNeverType(0, false);
+  TypeVarExtendsNever<Never>().test(0, false);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_promotion_error_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_promotion_error_test.dart
new file mode 100644
index 0000000..b76136c
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_promotion_error_test.dart
@@ -0,0 +1,27 @@
+// 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.
+
+// This test verifies that when a variable's type is promoted to `Never?`, the
+// resulting code block is considered reachable by flow analysis.  This is in
+// contrast to promotion to `Never`, which is considered unreachable.
+
+// SharedOptions=--enable-experiment=non-nullable
+void promoteViaIsCheck(Object x, Object? y) {
+  if (x is! int) {
+    if (y is Never?) {
+      // Reachable
+    } else {
+      return;
+    }
+  }
+  // Since the `y is Never?` branch was reachable, `x` is not promoted to `int`.
+  x.isEven;
+//  ^^^^^^
+// [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+// [cfe] unspecified
+}
+
+main() {
+  promoteViaIsCheck(0, null);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_promotion_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_promotion_test.dart
new file mode 100644
index 0000000..3bcc228
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_promotion_test.dart
@@ -0,0 +1,70 @@
+// 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.
+
+// This test verifies that when a variable's type is promoted to `Never` (either
+// via an explicit `is` check or a comparison to `null`), the resulting code
+// block is considered unreachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void promoteViaIsCheck(Object x, Object? y) {
+  if (x is! int) {
+    if (y is Never) {
+      // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since the `y is Never` branch was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+void promoteViaIsCheck_typeVarExtendsNever<T extends Never>(
+    Object x, Object? y) {
+  if (x is! int) {
+    if (y is T) {
+      // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since the `y is Never` branch was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+void promoteViaIsCheck_typeVarPromotedToNever<T>(Object x, T y) {
+  if (x is! int) {
+    if (y is Never) {
+      // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since the `y is Never` branch was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+void promoteViaNullCheck(Object x, Null y) {
+  if (x is! int) {
+    if (y != null) {
+      // Unreachable
+    } else {
+      return;
+    }
+  }
+  // Since the `y != null` branch was unreachable, `x` is now promoted to
+  // `int`.
+  Expect.isTrue(x.isEven);
+}
+
+main() {
+  promoteViaIsCheck(0, 'foo');
+  promoteViaIsCheck_typeVarExtendsNever<Never>(0, 'foo');
+  promoteViaIsCheck_typeVarPromotedToNever<Object?>(0, 'foo');
+  promoteViaNullCheck(0, null);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_error_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_error_test.dart
new file mode 100644
index 0000000..2f7e690
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_error_test.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.
+
+// This test verifies that if a read is performed on a variable whose type is
+// `Never?`, the resulting code block is considered reachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+
+void explicitNeverQuestionType(Object x, bool b) {
+  Never? y = null;
+  if (x is! int) {
+    if (b) {
+      y;
+    } else {
+      return;
+    }
+  }
+  // Since the read of `y` was reachable, `x` is not promoted to `int`.
+  x.isEven;
+//  ^^^^^^
+// [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+// [cfe] unspecified
+}
+
+main() {
+  explicitNeverQuestionType(0, true);
+}
diff --git a/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_test.dart b/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_test.dart
new file mode 100644
index 0000000..3330292
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/unreachable_via_variable_get_test.dart
@@ -0,0 +1,53 @@
+// 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.
+
+// This test verifies that if a read is performed on a variable whose type is
+// `Never`, the resulting code block is considered unreachable by flow analysis.
+
+// SharedOptions=--enable-experiment=non-nullable
+import 'package:expect/expect.dart';
+
+void explicitNeverType(Never Function() f, Object x, bool b1, bool b2) {
+  late Never y;
+  // Loop so that flow analysis no longer can tell that y is definitely
+  // unassigned
+  while (true) {
+    if (x is! int) {
+      if (b1) {
+        y; // Unreachable
+      } else {
+        return;
+      }
+    }
+    // Since the read of `y` was unreachable, `x` is now promoted to `int`.
+    Expect.isTrue(x.isEven);
+    if (b2) return;
+    y = f();
+  }
+}
+
+void typeVarExtendsNever<T extends Never>(
+    T Function() f, Object x, bool b1, bool b2) {
+  late T y;
+  // Loop so that flow analysis no longer can tell that y is definitely
+  // unassigned
+  while (true) {
+    if (x is! int) {
+      if (b1) {
+        y; // Unreachable
+      } else {
+        return;
+      }
+    }
+    // Since the read of `y` was unreachable, `x` is now promoted to `int`.
+    Expect.isTrue(x.isEven);
+    if (b2) return;
+    y = f();
+  }
+}
+
+main() {
+  explicitNeverType(() => throw 'x', 0, false, true);
+  typeVarExtendsNever<Never>(() => throw 'x', 0, false, true);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_closure_error_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_closure_error_test.dart
new file mode 100644
index 0000000..bd76d00
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_closure_error_test.dart
@@ -0,0 +1,44 @@
+// 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.
+
+// Verifies that variables assigned in closures and local functions are
+// de-promoted at the top of the closure, since the closure may be invoked
+// multiple times.
+
+void functionExpression(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    var f = () {
+      // The assignment to x does de-promote because it happens after the top of
+      // the closure, so flow analysis cannot check that the assigned value is
+      // an int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    };
+  }
+}
+
+void localFunction(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    f() {
+      // The assignment to x does de-promote because it happens after the top of
+      // the closure, so flow analysis cannot check that the assigned value is
+      // an int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    }
+  }
+}
+
+main() {
+  functionExpression(0);
+  localFunction(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_error_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_error_test.dart
new file mode 100644
index 0000000..646649d
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_error_test.dart
@@ -0,0 +1,141 @@
+// 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.
+
+// Verifies that variables assigned in loops are de-promoted at the top of the
+// loop body, since the loop body be executed multiple times.
+
+void forLoopAssignInCondition(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    for (; 0 == 0 ? (x = 0) == 0 : true;) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    }
+  }
+}
+
+void forLoopAssignInUpdater(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    for (;; x = 0) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    }
+  }
+}
+
+void forLoopAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    for (;;) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    }
+  }
+}
+
+void forEachAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    for (var y in [0]) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    }
+  }
+}
+
+void whileAssignInCondition(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    while (0 == 0 ? (x = 0) == 0 : true) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    }
+  }
+}
+
+void whileAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    while (true) {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    }
+  }
+}
+
+void doAssignInCondition(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    do {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    } while ((x = 0) == 0);
+  }
+}
+
+void doAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    do {
+      // The assignment to x does de-promote because it happens after the top of
+      // the loop, so flow analysis cannot check that the assigned value is an
+      // int at the time de-promotion occurs.
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+      x = 0;
+    } while (true);
+  }
+}
+
+main() {
+  forLoopAssignInCondition(0);
+  forLoopAssignInUpdater(0);
+  forLoopAssignInBody(0);
+  forEachAssignInBody(0);
+  whileAssignInCondition(0);
+  whileAssignInBody(0);
+  doAssignInCondition(0);
+  doAssignInBody(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_test.dart
new file mode 100644
index 0000000..a385715
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_loop_test.dart
@@ -0,0 +1,76 @@
+// 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.
+
+// Verifies that variables assigned in initialization parts of loops are not
+// de-promoted, since loop initialization only executes once.
+
+void forLoopWithoutDecl(Object x) {
+  if (x is int) {
+    for (x = 0;;) {
+      // The assignment to x does not de-promote x because it happens before the
+      // top of the loop, and it assigns an int (which is compatible with the
+      // promoted type).
+      x.isEven;
+      break;
+    }
+  }
+}
+
+void forLoopWithoutDeclAssignInRHS(Object x) {
+  if (x is int) {
+    int y;
+    for (y = (x = 0);;) {
+      // The assignment to x does not de-promote x because it happens before the
+      // top of the loop, and it assigns an int (which is compatible with the
+      // promoted type).
+      x.isEven;
+      break;
+    }
+  }
+}
+
+void forLoopWithDeclAssignInRHS(Object x) {
+  if (x is int) {
+    for (int y = (x = 0);;) {
+      // The assignment to x does not de-promote x because it happens before the
+      // top of the loop, and it assigns an int (which is compatible with the
+      // promoted type).
+      x.isEven;
+      break;
+    }
+  }
+}
+
+void forEachWithoutDecl(Object x) {
+  if (x is int) {
+    int y;
+    for (y in [x = 0]) {
+      // The assignment to x does not de-promote x because it happens before the
+      // top of the loop, and it assigns an int (which is compatible with the
+      // promoted type).
+      x.isEven;
+      break;
+    }
+  }
+}
+
+void forEachWithDecl(Object x) {
+  if (x is int) {
+    for (int y in [x = 0]) {
+      // The assignment to x does not de-promote x because it happens before the
+      // top of the loop, and it assigns an int (which is compatible with the
+      // promoted type).
+      x.isEven;
+      break;
+    }
+  }
+}
+
+main() {
+  forLoopWithoutDecl(0);
+  forLoopWithoutDeclAssignInRHS(0);
+  forLoopWithDeclAssignInRHS(0);
+  forEachWithoutDecl(0);
+  forEachWithDecl(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_error_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_error_test.dart
new file mode 100644
index 0000000..9d96b15
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_error_test.dart
@@ -0,0 +1,54 @@
+// 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.
+
+// Verifies that variables assigned in switch statement bodies are de-promoted
+// at the top of labelled case blocks, since the assignment may occur before a
+// branch to the labelled case block.
+
+void switchWithLabelAssignInCase(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    switch (x) {
+      case 1:
+        continue L;
+      L:
+      case 0:
+        // The assignment to x does de-promote because it happens after the
+        // label, so flow analysis cannot check that the assigned value is an
+        // int at the time de-promotion occurs.
+        print(x.isEven);
+        //      ^^^^^^
+        // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+        // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+        x = 0;
+        break;
+    }
+  }
+}
+
+void switchWithLabelAssignInDefault(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    switch (x) {
+      case 1:
+        continue L;
+      L:
+      default:
+        // The assignment to x does de-promote because it happens after the
+        // label, so flow analysis cannot check that the assigned value is an
+        // int at the time de-promotion occurs.
+        print(x.isEven);
+        //      ^^^^^^
+        // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+        // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+        x = 0;
+        break;
+    }
+  }
+}
+
+main() {
+  switchWithLabelAssignInCase(0);
+  switchWithLabelAssignInDefault(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_test.dart
new file mode 100644
index 0000000..c8cfc47ef
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_switch_test.dart
@@ -0,0 +1,99 @@
+// 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.
+
+// Verifies that variables assigned in switch statements are not de-promoted if
+// the assignment cannot possibly happen prior to the read.
+
+void switchDefaultWithoutLabel(Object x) {
+  if (x is int) {
+    switch (x = 0) {
+      case 1:
+        break;
+      default:
+        // The assignment to x does not de-promote x because there is no label,
+        // and it assigns an int (which is compatible with the promoted type).
+        x.isEven;
+        break;
+    }
+  }
+}
+
+void switchCaseWithoutLabel(Object x) {
+  if (x is int) {
+    switch (x = 0) {
+      case 1:
+        break;
+      case 0:
+        // The assignment to x does not de-promote x because there is no label,
+        // and it assigns an int (which is compatible with the promoted type).
+        x.isEven;
+        break;
+    }
+  }
+}
+
+void switchDefaultWithoutLabelAssignInDefault(Object x) {
+  if (x is int) {
+    switch (x) {
+      default:
+        // The assignment to x does not de-promote x because there is no label.
+        x.isEven;
+        x = 0;
+        break;
+    }
+  }
+}
+
+void switchCaseWithoutLabelAssignInCase(Object x) {
+  if (x is int) {
+    switch (x) {
+      case 0:
+        // The assignment to x does not de-promote x because there is no label.
+        x.isEven;
+        x = 0;
+        break;
+    }
+  }
+}
+
+void switchDefaultWithLabel(Object x) {
+  if (x is int) {
+    switch (x = 0) {
+      case 1:
+        continue L;
+      L:
+      default:
+        // The assignment to x does not de-promote x because it happens before
+        // the label, and it assigns an int (which is compatible with the
+        // promoted type).
+        x.isEven;
+        break;
+    }
+  }
+}
+
+void switchCaseWithLabel(Object x) {
+  if (x is int) {
+    switch (x = 0) {
+      case 1:
+        continue L;
+      L:
+      case 0:
+        // The assignment to x does not de-promote x because it happens before
+        // the label, and it assigns an int (which is compatible with the
+        // promoted type).
+        x.isEven;
+        break;
+    }
+  }
+}
+
+main() {
+  switchDefaultWithoutLabel(0);
+  switchCaseWithoutLabel(0);
+  switchDefaultWithoutLabelAssignInDefault(0);
+  switchCaseWithoutLabelAssignInCase(0);
+  switchDefaultWithLabel(0);
+  switchCaseWithLabel(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_error_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_error_test.dart
new file mode 100644
index 0000000..8f89bdf
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_error_test.dart
@@ -0,0 +1,48 @@
+// 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.
+
+// Verifies that variables assigned in try blocks are de-promoted in catch and
+// finally blocks, since the catch or finally block may execute after the
+// assignment.
+
+void tryCatchAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    try {
+      x = 0;
+    } catch (e) {
+      // The assignment to x does de-promote because flow analysis does a
+      // conservative estimate of the flow model resulting from a caught
+      // exception (using the same logic it uses for loops, which doesn't
+      // account for RHS types)
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    }
+  }
+}
+
+void tryFinallyAssignInBody(Object x) {
+  if (x is int) {
+    print(x.isEven); // Verify that promotion occurred
+    try {
+      x = 0;
+    } finally {
+      // The assignment to x does de-promote because flow analysis does a
+      // conservative estimate of the flow model resulting from a caught
+      // exception (using the same logic it uses for loops, which doesn't
+      // account for RHS types)
+      print(x.isEven);
+      //      ^^^^^^
+      // [analyzer] STATIC_TYPE_WARNING.UNDEFINED_GETTER
+      // [cfe] The getter 'isEven' isn't defined for the class 'Object'.
+    }
+  }
+}
+
+main() {
+  tryCatchAssignInBody(0);
+  tryFinallyAssignInBody(0);
+}
diff --git a/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_test.dart b/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_test.dart
new file mode 100644
index 0000000..5ddcaf3
--- /dev/null
+++ b/tests/language/nnbd/flow_analysis/write_promoted_value_in_try_test.dart
@@ -0,0 +1,33 @@
+// 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.
+
+// Verifies that variables assigned in catch and finally are not de-promoted,
+// since the catch or finally block only executes once.
+
+void tryCatchAssignInCatch(Object x) {
+  if (x is int) {
+    try {} catch (e) {
+      // The assignment to x does not de-promote because the assignment is
+      // outside the scope of the try block
+      x.isEven;
+      x = '';
+    }
+  }
+}
+
+void tryFinallyAssignInBody(Object x) {
+  if (x is int) {
+    try {} finally {
+      // The assignment to x does not de-promote because the assignment is
+      // outside the scope of the try block
+      x.isEven;
+      x = 0;
+    }
+  }
+}
+
+main() {
+  tryCatchAssignInCatch(0);
+  tryFinallyAssignInBody(0);
+}
diff --git a/tests/language/nnbd/null_assertions/parameter_checks_test.dart b/tests/language/nnbd/null_assertions/parameter_checks_test.dart
index c6f9cc6..d841cd44 100644
--- a/tests/language/nnbd/null_assertions/parameter_checks_test.dart
+++ b/tests/language/nnbd/null_assertions/parameter_checks_test.dart
@@ -5,7 +5,8 @@
 // Test for null assertions for parameters in NNBD weak mode.
 
 // Requirements=nnbd-weak
-// VMOptions=--enable-asserts --null-assertions
+// VMOptions=--enable-asserts
+// SharedOptions=--null-assertions
 
 // Opt out of Null Safety:
 // @dart = 2.6
diff --git a/tests/language/nnbd/static_errors/super_equals_allows_null_test.dart b/tests/language/nnbd/static_errors/super_equals_allows_null_test.dart
new file mode 100644
index 0000000..507a146
--- /dev/null
+++ b/tests/language/nnbd/static_errors/super_equals_allows_null_test.dart
@@ -0,0 +1,97 @@
+// 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 "package:expect/expect.dart";
+
+// SharedOptions=--enable-experiment=non-nullable
+
+// Test that `super == x` is allowed when `x` has a nullable type, even if the
+// targeted definition of `operator==` has a parameter with a non-nullable type,
+// as per this spec text (from
+// accepted/future-releases/nnbd/feature-specification.md):
+//
+//     Similarly, consider an expression `e` of the form `super == e2` that
+//     occurs in a class whose superclass is `C`, where the static type of `e2`
+//     is `T2`. Let `S` be the formal parameter type of the concrete declaration
+//     of `operator ==` found by method lookup in `C` (_if that search succeeds,
+//     otherwise it is a compile-time error_).  It is a compile-time error
+//     unless `T2` is assignable to `S?`.
+//
+// Also test that `super == null` evaluates to `false` without calling
+// `super.operator==`, as per this spec text (from section "Equality"):
+//
+//     Evaluation of an equality expression ee of the form super == e proceeds
+//     as follows:
+//     - The expression e is evaluated to an object o.
+//     - If either this or o is the null object (16.4), then ee evaluates to
+//       evaluates to true if both this and o are the null object and to false
+//       otherwise.  Otherwise,
+//     - evaluation of ee is equivalent to the method invocation super.==(o).
+
+MapEntry<dynamic, dynamic>? _call = null;
+
+class BaseObject {
+  bool operator ==(Object other) {
+    Expect.isNull(_call);
+    _call = MapEntry(this, other);
+    return false;
+  }
+}
+
+class DerivedObject extends BaseObject {
+  void test() {
+    Object? nullAsObjectQuestion = null;
+    Object? nonNullAsObjectQuestion = 0;
+    dynamic nullAsDynamic = null;
+    dynamic nonNullAsDynamic = 1;
+    Expect.isFalse(super == nullAsObjectQuestion);
+    Expect.isNull(_call);
+    Expect.isFalse(super == nonNullAsObjectQuestion);
+    Expect.identical(_call!.key, this);
+    Expect.identical(_call!.value, nonNullAsObjectQuestion);
+    _call = null;
+    Expect.isFalse(super == nullAsDynamic);
+    Expect.isNull(_call);
+    Expect.isFalse(super == nonNullAsDynamic);
+    Expect.identical(_call!.key, this);
+    Expect.identical(_call!.value, nonNullAsDynamic);
+    _call = null;
+  }
+}
+
+class BaseNum {
+  bool operator ==(covariant num other) {
+    Expect.isNull(_call);
+    _call = MapEntry(this, other);
+    return false;
+  }
+}
+
+class DerivedNum extends BaseNum {
+  void test() {
+    num? nullAsNumQuestion = null;
+    num? nonNullAsNumQuestion = 0;
+    dynamic nullAsDynamic = null;
+    dynamic nonNullAsDynamic = 1;
+    dynamic nonNumAsDynamic = 'foo';
+    Expect.isFalse(super == nullAsNumQuestion);
+    Expect.isNull(_call);
+    Expect.isFalse(super == nonNullAsNumQuestion);
+    Expect.identical(_call!.key, this);
+    Expect.identical(_call!.value, nonNullAsNumQuestion);
+    _call = null;
+    Expect.isFalse(super == nullAsDynamic);
+    Expect.isNull(_call);
+    Expect.isFalse(super == nonNullAsDynamic);
+    Expect.identical(_call!.key, this);
+    Expect.identical(_call!.value, nonNullAsDynamic);
+    _call = null;
+    Expect.throwsTypeError(() => super == nonNumAsDynamic);
+    Expect.isNull(_call);
+  }
+}
+
+main() {
+  DerivedObject().test();
+  DerivedNum().test();
+}
diff --git a/tests/language/nnbd/static_errors/super_equals_disallows_non_matching_type_error_test.dart b/tests/language/nnbd/static_errors/super_equals_disallows_non_matching_type_error_test.dart
new file mode 100644
index 0000000..d0e52ea
--- /dev/null
+++ b/tests/language/nnbd/static_errors/super_equals_disallows_non_matching_type_error_test.dart
@@ -0,0 +1,37 @@
+// 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 "package:expect/expect.dart";
+
+// SharedOptions=--enable-experiment=non-nullable
+
+// Test that `super == x` is properly type checked against the target
+// `operator==` method.  That is, the special allowance in the following spec
+// text (from accepted/future-releases/nnbd/feature-specification.md) allows `x`
+// to be nullable, but still requires that the type otherwise matches:
+//
+//     Similarly, consider an expression `e` of the form `super == e2` that
+//     occurs in a class whose superclass is `C`, where the static type of `e2`
+//     is `T2`. Let `S` be the formal parameter type of the concrete declaration
+//     of `operator ==` found by method lookup in `C` (_if that search succeeds,
+//     otherwise it is a compile-time error_).  It is a compile-time error
+//     unless `T2` is assignable to `S?`.
+
+class Base {
+  bool operator ==(covariant num other) => false;
+}
+
+class Derived extends Base {
+  void test() {
+    String string = 'foo';
+    String? stringQuestion = 'foo';
+    super == string;
+    //       ^^^^^^
+    // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+    // [cfe] The argument type 'String' can't be assigned to the parameter type 'num?'.
+    super == stringQuestion;
+    //       ^^^^^^^^^^^^^^
+    // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+    // [cfe] The argument type 'String?' can't be assigned to the parameter type 'num?'.
+  }
+}
diff --git a/tests/language/operator/invalid_operators_test.dart b/tests/language/operator/invalid_operators_test.dart
index 4e90b5b..1a3b359 100644
--- a/tests/language/operator/invalid_operators_test.dart
+++ b/tests/language/operator/invalid_operators_test.dart
@@ -9,6 +9,7 @@
   // [cfe] Operator '==' should have exactly one parameter.
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
+  // [cfe] The method 'Operators1.==' has fewer positional arguments than those of overridden method 'Object.=='.
   operator <() => true;
   //       ^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
@@ -86,6 +87,7 @@
   // [cfe] Operator '==' should have exactly one parameter.
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
+  // [cfe] The method 'Operators2.==' has more required arguments than those of overridden method 'Object.=='.
   operator <(a, b) => true;
   //       ^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
@@ -249,6 +251,7 @@
   operator ==({a}) => true;
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_OVERRIDE
+  // [cfe] The method 'Operators4.==' has fewer positional arguments than those of overridden method 'Object.=='.
   //           ^
   // [analyzer] COMPILE_TIME_ERROR.OPTIONAL_PARAMETER_IN_OPERATOR
   // [cfe] An operator can't have optional parameters.
@@ -569,6 +572,9 @@
   operator ==<T>(a) => true;
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_OVERRIDE
+  // [cfe] Declared type variables of 'Operators7.==' doesn't match those on overridden method 'Object.=='.
+  //       ^
+  // [cfe] The return type of the method 'Operators7.==' is 'dynamic', which does not match the return type, 'bool', of the overridden method, 'Object.=='.
   //         ^^^
   // [analyzer] SYNTACTIC_ERROR.TYPE_PARAMETERS_ON_OPERATOR
   //          ^
@@ -665,4 +671,11 @@
   // [cfe] Types parameters aren't allowed when defining an operator.
 }
 
+class Operators8 {
+  /*space*/ int operator []=(a, b) => 1;
+  //        ^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_OPERATOR
+  // [cfe] unspecified
+}
+
 main() {}
diff --git a/tests/language/operator/number_operator_context_test.dart b/tests/language/operator/number_operator_context_test.dart
new file mode 100644
index 0000000..898f139
--- /dev/null
+++ b/tests/language/operator/number_operator_context_test.dart
@@ -0,0 +1,177 @@
+// Copyright (c) 2021, 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.
+
+// Test the new context type rules for number operators,
+// as modified by Null Safety
+import "static_type_helper.dart";
+
+// The context rules for `e` of the form:
+// For e1 + e2, e1 - e2, e1 * e2, e1 % e2 or e1.remainder(e2),,
+// if the static type of e1 is a non-`Never` subtype of `int`,
+// and the context type of the entire expression is `int`,
+// then the context type of e2 is `int`.
+// If the static type of e1 is a non-`Never` subtype of `num`
+// that is not a subtype of `double`,
+// and the context type of the entire expression is `double`,
+// then the context type of e2 is `double`.
+
+// If the context type of `e1.clamp(e2, e3)`, *C*,
+// and the  the static type of `e1`, *T*,
+// are both is a non-`Never` subtypes of `num`,
+// then the context types of `e2` and `e3` are both *C*.
+// Otherwise the context types of `e2` and `e3` are `num`.
+
+void main() {
+  testIntContext<int, Object>(1, 1);
+  testDoubleContext<int, double, num, Object>(1, 1.1, 1.1, 1.1);
+  testNumContext<num, Object>(1, 1);
+}
+
+void testIntContext<I extends int, O extends Object>(I i, O o) {
+  context<int>(1 + (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(1 - (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(1 * (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(1 % (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(1.remainder(contextType(1)..expectStaticType<Exactly<int>>()));
+
+  context<int>(i + (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(i - (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(i * (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(i % (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(i.remainder(contextType(1)..expectStaticType<Exactly<int>>()));
+
+  context<num>(1 + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(1 - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(1 * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(1 % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(1.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  O oi = 1 as O;
+  if (oi is! int) throw "promote oi to O&int";
+  context<int>(oi + (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(oi - (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(oi * (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(oi % (contextType(1)..expectStaticType<Exactly<int>>()));
+  context<int>(oi.remainder(contextType(1)..expectStaticType<Exactly<int>>()));
+
+  int ii = 0;
+  ii += contextType(1)..expectStaticType<Exactly<int>>();
+  ii -= contextType(1)..expectStaticType<Exactly<int>>();
+  ii *= contextType(1)..expectStaticType<Exactly<int>>();
+  ii %= contextType(1)..expectStaticType<Exactly<int>>();
+  if (ii != 0) throw "use ii";
+
+  context<int>(1.clamp(contextType(1)..expectStaticType<Exactly<int>>(),
+      contextType(1)..expectStaticType<Exactly<int>>()));
+
+  context<int>(i.clamp(contextType(1)..expectStaticType<Exactly<int>>(),
+      contextType(1)..expectStaticType<Exactly<int>>()));
+
+  context<int>(oi.clamp(contextType(1)..expectStaticType<Exactly<int>>(),
+      contextType(1)..expectStaticType<Exactly<int>>()));
+}
+
+void testDoubleContext<I extends int, D extends double, N extends num,
+    O extends Object>(I i, D d, N n, O o) {
+  context<double>(1 + (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(1 - (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(1 * (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(1 % (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(
+      1.remainder(contextType(1.0)..expectStaticType<Exactly<double>>()));
+
+  context<double>(n + (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(n - (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(n * (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(n % (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(
+      n.remainder(contextType(1.0)..expectStaticType<Exactly<double>>()));
+
+  context<double>(i + (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(i - (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(i * (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(i % (contextType(1.0)..expectStaticType<Exactly<double>>()));
+  context<double>(
+      i.remainder(contextType(1.0)..expectStaticType<Exactly<double>>()));
+
+  context<double>(d + (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(d - (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(d * (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(d % (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(
+      d.remainder(contextType(1.0)..expectStaticType<Exactly<num>>()));
+
+  var od = (1.0 as O);
+  if (od is! double) throw "promote od to O&double";
+  context<double>(od + (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(od - (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(od * (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(od % (contextType(1.0)..expectStaticType<Exactly<num>>()));
+  context<double>(
+      od.remainder(contextType(1.0)..expectStaticType<Exactly<num>>()));
+
+  // The context type also causes double literals.
+  context<double>(1 + (1..expectStaticType<Exactly<double>>()));
+  context<double>(1 - (1..expectStaticType<Exactly<double>>()));
+  context<double>(1 * (1..expectStaticType<Exactly<double>>()));
+  context<double>(1 % (1..expectStaticType<Exactly<double>>()));
+  context<double>(1.remainder(1..expectStaticType<Exactly<double>>()));
+
+  double dd = 0.0;
+  dd += contextType(1)..expectStaticType<Exactly<num>>();
+  dd -= contextType(1)..expectStaticType<Exactly<num>>();
+  dd *= contextType(1)..expectStaticType<Exactly<num>>();
+  dd %= contextType(2)..expectStaticType<Exactly<num>>();
+
+  context<double>(1.1.clamp(
+      contextType(1.0)..expectStaticType<Exactly<double>>(),
+      contextType(1.0)..expectStaticType<Exactly<double>>()));
+
+  context<double>(d.clamp(contextType(1.0)..expectStaticType<Exactly<double>>(),
+      contextType(1.0)..expectStaticType<Exactly<double>>()));
+
+  context<double>(od.clamp(
+      contextType(1.0)..expectStaticType<Exactly<double>>(),
+      contextType(1.0)..expectStaticType<Exactly<double>>()));
+}
+
+void testNumContext<N extends num, O extends Object>(N n, O o) {
+  var i1 = 1;
+  var d1 = 1.0;
+  num n1 = 1;
+  if (o is! num) throw "promote o to O&num";
+
+  context<num>(i1 + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(i1 - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(i1 * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(i1 % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(i1.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  context<num>(d1 + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(d1 - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(d1 * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(d1 % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(d1.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  context<num>(n1 + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n1 - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n1 * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n1 % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n1.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  context<num>(n + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(n.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  context<num>(o + (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(o - (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(o * (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(o % (contextType(1)..expectStaticType<Exactly<num>>()));
+  context<num>(o.remainder(contextType(1)..expectStaticType<Exactly<num>>()));
+
+  context<num>(o.clamp(contextType(1)..expectStaticType<Exactly<num>>(),
+      contextType(1)..expectStaticType<Exactly<num>>()));
+}
diff --git a/tests/language/operator/number_operator_error_test.dart b/tests/language/operator/number_operator_error_test.dart
new file mode 100644
index 0000000..7c57fc0
--- /dev/null
+++ b/tests/language/operator/number_operator_error_test.dart
@@ -0,0 +1,246 @@
+// Copyright (c) 2021, 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.
+
+// Test the new context type rules for number operators,
+import "static_type_helper.dart";
+
+// as modified by Null Safety
+void main() {
+  testTypes<int, double, num, Object>(1, 1.0, 1, 1);
+}
+
+void
+    testTypes<I extends int, D extends double, N extends num, O extends Object>(
+        I ti, D td, N tn, O to) {
+  int i = 1;
+  double d = 1.0;
+  num n = cast(1);
+  O oi = cast(1);
+  if (oi is! int) throw "promote oi to O&int";
+  checkIntersectionType<O, int>(oi, oi, oi);
+  O od = cast(1.0);
+  if (od is! double) throw "promote od to O&double";
+  checkIntersectionType<O, double>(od, od, od);
+  O on = cast(1);
+  if (on is! num) throw "promote on to I&num";
+  checkIntersectionType<O, num>(on, on, on);
+  dynamic dyn = cast(1);
+  late never = throw "unreachable";
+
+  /* indent */ i + "string";
+  //               ^^^^^^^^
+  // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+  // [cfe] A value of type 'String' can't be assigned to a variable of type 'num'.
+
+  i += d;
+  //   ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  //^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'int'.
+
+  i += n;
+  //   ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  //^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'int'.
+
+  i += never;
+  //   ^^^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  //^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'int'.
+
+  i += dyn; // type of `i + dyn` is `num`, not assignable to `int`.
+  //   ^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  //^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'int'.
+
+  ti += i; // Type of expression is `int`, not `I`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'int' can't be assigned to a variable of type 'I'.
+
+  ti += d; // Type of expression is `num`, not `I`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'I'.
+
+  ti += n; // Type of expression is `num`, not `I`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'I'.
+
+  ti += never; // Type of expression is `num`, not `I`.
+  //    ^^^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'I'.
+
+  ti += dyn; // type of `i + dyn` is `num`, not assignable to `int`.
+  //    ^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'I'.
+
+  td += i; // Type of expression is `double`, not `D`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  td += d; // Type of expression is `double`, not `D`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  td += n; // Type of expression is `double`, not `D`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  td += dyn; // Type of expression is `double`, not `D`.
+  //    ^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  td += never; // Type of expression is `double`, not `D`.
+  //    ^^^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  tn += i; // Type of expression is `num`, not `N`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  tn += d; // Type of expression is `num`, not `N`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  tn += n; // Type of expression is `num`, not `N`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  tn += dyn; // Type of expression is `num`, not `N`.
+  //    ^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  tn += never; // Type of expression is `num`, not `N`.
+  //    ^^^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  O oi1 = to; // New variable to avoid demoting `oi`.
+  if (oi1 is int) {
+    // Promote oi1 to O&int
+    oi1 + d; // Valid
+    oi1 += d;
+    //     ^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'double' can't be assigned to a variable of type 'O'.
+  }
+
+  O oi2 = to;
+  if (oi2 is int) {
+    // Promote oi2 to O&int.
+    oi2 + n; // Valid
+    oi2 += n;
+    //     ^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'num' can't be assigned to a variable of type 'O'.
+  }
+
+  O oi3 = to;
+  if (oi3 is int) {
+    // Promote oi3 to O&int.
+    oi3 + dyn; // Valid
+    oi3 += dyn;
+    //     ^^^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'num' can't be assigned to a variable of type 'O'.
+  }
+
+  O oi4 = to;
+  if (oi4 is int) {
+    // Promote oi4 to O&int.
+    oi4 + never; // Valid.
+    oi4 += never;
+    //     ^^^^^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'num' can't be assigned to a variable of type 'O'.
+  }
+
+  context<D>(i + td); // Type of expression is `double`, not `D`.
+  //         ^^^^^^
+  // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+  //           ^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  context<D>(n + td); // Type of expression is `double`, not `D`.
+  //         ^^^^^^
+  // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+  //           ^
+  // [cfe] A value of type 'double' can't be assigned to a variable of type 'D'.
+
+  context<D>(1.0 + td); // Type of expression is `double`, not `D`.
+  //         ^^^^^^^^
+  // [analyzer] STATIC_WARNING.ARGUMENT_TYPE_NOT_ASSIGNABLE
+  //             ^
+  // [cfe] The argument type 'double' can't be assigned to the parameter type 'D'.
+
+  tn += n; // Type of expression is `num`, not `N`.
+  //    ^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  tn += dyn;
+  //    ^^^
+  // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+  // ^^
+  // [cfe] A value of type 'num' can't be assigned to a variable of type 'N'.
+
+  O on1 = to;
+  if (on1 is num) {
+    // Promote on1 to O&num.
+    on1 += n; // Type of expression is `num`, not `N` or `O`.
+    //     ^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'num' can't be assigned to a variable of type 'O'.
+  }
+
+  O on2 = to;
+  if (on2 is num) {
+    // Promote on2 to O&num.
+    on2 += dyn; // Type of expression is `num`, not `N` or `O`.
+    //     ^^^
+    // [analyzer] STATIC_TYPE_WARNING.INVALID_ASSIGNMENT
+    //  ^^
+    // [cfe] A value of type 'num' can't be assigned to a variable of type 'O'.
+  }
+}
+
+// The value as the context type, without risking any assignment promotion.
+T cast<T>(Object value) => value as T;
diff --git a/tests/language/operator/number_operator_typing_test.dart b/tests/language/operator/number_operator_typing_test.dart
new file mode 100644
index 0000000..62e452a
--- /dev/null
+++ b/tests/language/operator/number_operator_typing_test.dart
@@ -0,0 +1,927 @@
+// Copyright (c) 2026, 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.
+
+// Test the rules for static types of number operators,
+// as modified by Null Safety
+import "static_type_helper.dart";
+
+// ignore_for_file: receiver_of_type_never
+
+// The typing rules for `e` of the form:
+// * `e1 op e2` (op in `+`, `-`, `*` or `%`), or
+// * `e1.remainder(e2)`,
+//
+// where *T* is the static type of `e1`, *S* is the static type of `e2`
+// and *T* is a non-`Never` subtype of `num` and *S* is assignable to `num`.
+//
+// * If *T* <: `double` then the static type of `e` is `double`.
+// * Otherwise, if *S* <: `double` and not *S* <: `Never`,
+//   then the static type of `e` is `double`.
+// * Otherwise, if *T* <: `int`, *S* <: `int` and not *S* <: `Never`,
+//   then the static type of `e` is `int`.
+// * Otherwise the static type of *e* is `num`.
+//
+// For `e1.clamp(e2, e3)` where
+// *T1* is the static type of `e1`, *T1* a non-`Never` subtype of `num`,
+// *T2* is the static type of `e2`, and
+// *T3* is the static type of `e3`:
+//
+// * If all of *T1*, *T2* and *T3* are non-`Never` subtypes of `int`,
+//   then the static type of `e` is `int`.
+// * If all of *T1*, *T2* and *T3* are non-`Never` subtypes of `double`,
+//   then the static type of `e` is `double`.
+// * Otherwise the static type of `e` is num`.
+
+main() {
+  testPlainVariables(1, 1.0, 1);
+  testPromotedVariables(1, 1.0, 1);
+  testTypeVariables<int, double, int>(1, 1.0, 1);
+  testPromotedTypeVariables<Object>(1, 1.0, 1);
+  const TestConst<int, double, num>(1, 1.0, 1);
+}
+
+final num n1 = 1;
+final num n2 = 2;
+final int i1 = 1;
+final int i2 = 2;
+final dynamic dyn1 = 1;
+final dynamic dyn2 = 2;
+late final Never never = throw "unreachable"; // Only used for static tests.
+
+// Check the static type of operations on plain variables.
+void testPlainVariables(int i, double d, num n) {
+  (i + i).expectStaticType<Exactly<int>>();
+  (i - i).expectStaticType<Exactly<int>>();
+  (i * i).expectStaticType<Exactly<int>>();
+  (i % i).expectStaticType<Exactly<int>>();
+  i.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + d).expectStaticType<Exactly<double>>();
+  (i - d).expectStaticType<Exactly<double>>();
+  (i * d).expectStaticType<Exactly<double>>();
+  (i % d).expectStaticType<Exactly<double>>();
+  i.remainder(d).expectStaticType<Exactly<double>>();
+
+  (i + n).expectStaticType<Exactly<num>>();
+  (i - n).expectStaticType<Exactly<num>>();
+  (i * n).expectStaticType<Exactly<num>>();
+  (i % n).expectStaticType<Exactly<num>>();
+  i.remainder(n).expectStaticType<Exactly<num>>();
+
+  (i + dyn1).expectStaticType<Exactly<num>>();
+  (i - dyn1).expectStaticType<Exactly<num>>();
+  (i * dyn1).expectStaticType<Exactly<num>>();
+  (i % dyn1).expectStaticType<Exactly<num>>();
+  i.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    // Only for the static checks
+    // since we have sub-expressions of type Never.
+    (i + never).expectStaticType<Exactly<num>>();
+    (i - never).expectStaticType<Exactly<num>>();
+    (i * never).expectStaticType<Exactly<num>>();
+    (i % never).expectStaticType<Exactly<num>>();
+    i.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (d + i).expectStaticType<Exactly<double>>();
+  (d - i).expectStaticType<Exactly<double>>();
+  (d * i).expectStaticType<Exactly<double>>();
+  (d % i).expectStaticType<Exactly<double>>();
+  d.remainder(i).expectStaticType<Exactly<double>>();
+
+  (d + d).expectStaticType<Exactly<double>>();
+  (d - d).expectStaticType<Exactly<double>>();
+  (d * d).expectStaticType<Exactly<double>>();
+  (d % d).expectStaticType<Exactly<double>>();
+  d.remainder(d).expectStaticType<Exactly<double>>();
+
+  (d + n).expectStaticType<Exactly<double>>();
+  (d - n).expectStaticType<Exactly<double>>();
+  (d * n).expectStaticType<Exactly<double>>();
+  (d % n).expectStaticType<Exactly<double>>();
+  d.remainder(n).expectStaticType<Exactly<double>>();
+
+  (d + dyn1).expectStaticType<Exactly<double>>();
+  (d - dyn1).expectStaticType<Exactly<double>>();
+  (d * dyn1).expectStaticType<Exactly<double>>();
+  (d % dyn1).expectStaticType<Exactly<double>>();
+  d.remainder(dyn1).expectStaticType<Exactly<double>>();
+
+  if (false) {
+    (d + never).expectStaticType<Exactly<double>>();
+    (d - never).expectStaticType<Exactly<double>>();
+    (d * never).expectStaticType<Exactly<double>>();
+    (d % never).expectStaticType<Exactly<double>>();
+    d.remainder(never).expectStaticType<Exactly<double>>();
+  }
+
+  (n + i).expectStaticType<Exactly<num>>();
+  (n - i).expectStaticType<Exactly<num>>();
+  (n * i).expectStaticType<Exactly<num>>();
+  (n % i).expectStaticType<Exactly<num>>();
+  n.remainder(i).expectStaticType<Exactly<num>>();
+
+  (n + d).expectStaticType<Exactly<double>>();
+  (n - d).expectStaticType<Exactly<double>>();
+  (n * d).expectStaticType<Exactly<double>>();
+  (n % d).expectStaticType<Exactly<double>>();
+  n.remainder(d).expectStaticType<Exactly<double>>();
+
+  (n + n).expectStaticType<Exactly<num>>();
+  (n - n).expectStaticType<Exactly<num>>();
+  (n * n).expectStaticType<Exactly<num>>();
+  (n % n).expectStaticType<Exactly<num>>();
+  n.remainder(n).expectStaticType<Exactly<num>>();
+
+  (n + dyn1).expectStaticType<Exactly<num>>();
+  (n - dyn1).expectStaticType<Exactly<num>>();
+  (n * dyn1).expectStaticType<Exactly<num>>();
+  (n % dyn1).expectStaticType<Exactly<num>>();
+  n.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (n + never).expectStaticType<Exactly<num>>();
+    (n - never).expectStaticType<Exactly<num>>();
+    (n * never).expectStaticType<Exactly<num>>();
+    (n % never).expectStaticType<Exactly<num>>();
+    n.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (dyn1 + d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 - d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 * d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 % d).expectStaticType<Exactly<dynamic>>();
+  dyn1.remainder(d).expectStaticType<Exactly<dynamic>>();
+
+  if (false) {
+    (never + d).expectStaticType<Exactly<Never>>();
+    (never - d).expectStaticType<Exactly<Never>>();
+    (never * d).expectStaticType<Exactly<Never>>();
+    (never % d).expectStaticType<Exactly<Never>>();
+    never.remainder(d).expectStaticType<Exactly<Never>>();
+  }
+
+  i.clamp(i, i).expectStaticType<Exactly<int>>();
+  d.clamp(d, d).expectStaticType<Exactly<double>>();
+
+  i.clamp(i, d).expectStaticType<Exactly<num>>();
+  i.clamp(d, i).expectStaticType<Exactly<num>>();
+  d.clamp(i, i).expectStaticType<Exactly<num>>();
+  i.clamp(d, d).expectStaticType<Exactly<num>>();
+  d.clamp(i, d).expectStaticType<Exactly<num>>();
+  d.clamp(d, i).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, n).expectStaticType<Exactly<num>>();
+  i.clamp(n, i).expectStaticType<Exactly<num>>();
+  n.clamp(i, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, n).expectStaticType<Exactly<num>>();
+  d.clamp(n, d).expectStaticType<Exactly<num>>();
+  n.clamp(d, d).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, dyn1).expectStaticType<Exactly<num>>();
+  i.clamp(dyn1, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, dyn1).expectStaticType<Exactly<num>>();
+  d.clamp(dyn1, d).expectStaticType<Exactly<num>>();
+  n.clamp(n, dyn1).expectStaticType<Exactly<num>>();
+  n.clamp(dyn1, n).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    i.clamp(i, never).expectStaticType<Exactly<num>>();
+    d.clamp(d, never).expectStaticType<Exactly<num>>();
+    n.clamp(n, never).expectStaticType<Exactly<num>>();
+    never.clamp(i, i).expectStaticType<Exactly<Never>>();
+  }
+
+  (i += i1).expectStaticType<Exactly<int>>();
+  (i -= i1).expectStaticType<Exactly<int>>();
+  (i *= i1).expectStaticType<Exactly<int>>();
+  (i %= i2).expectStaticType<Exactly<int>>();
+  (i++).expectStaticType<Exactly<int>>();
+  (i--).expectStaticType<Exactly<int>>();
+  (++i).expectStaticType<Exactly<int>>();
+  (--i).expectStaticType<Exactly<int>>();
+
+  (d += i1).expectStaticType<Exactly<double>>();
+  (d -= i1).expectStaticType<Exactly<double>>();
+  (d *= i1).expectStaticType<Exactly<double>>();
+  (d %= i2).expectStaticType<Exactly<double>>();
+  (d += 1.0).expectStaticType<Exactly<double>>();
+  (d -= 1.0).expectStaticType<Exactly<double>>();
+  (d *= 1.0).expectStaticType<Exactly<double>>();
+  (d %= 1.0).expectStaticType<Exactly<double>>();
+  (d += n1).expectStaticType<Exactly<double>>();
+  (d -= n1).expectStaticType<Exactly<double>>();
+  (d *= n1).expectStaticType<Exactly<double>>();
+  (d %= n2).expectStaticType<Exactly<double>>();
+  (d += dyn1).expectStaticType<Exactly<double>>();
+  (d -= dyn1).expectStaticType<Exactly<double>>();
+  (d *= dyn1).expectStaticType<Exactly<double>>();
+  (d %= dyn2).expectStaticType<Exactly<double>>();
+  (d++).expectStaticType<Exactly<double>>();
+  (d--).expectStaticType<Exactly<double>>();
+  (++d).expectStaticType<Exactly<double>>();
+  (--d).expectStaticType<Exactly<double>>();
+
+  (n += i1).expectStaticType<Exactly<num>>();
+  (n -= i1).expectStaticType<Exactly<num>>();
+  (n *= i1).expectStaticType<Exactly<num>>();
+  (n %= i2).expectStaticType<Exactly<num>>();
+  (n += 1.0).expectStaticType<Exactly<double>>();
+  (n -= 1.0).expectStaticType<Exactly<double>>();
+  (n *= 1.0).expectStaticType<Exactly<double>>();
+  (n %= 1.0).expectStaticType<Exactly<double>>();
+  (n += n1).expectStaticType<Exactly<num>>();
+  (n -= n1).expectStaticType<Exactly<num>>();
+  (n *= n1).expectStaticType<Exactly<num>>();
+  (n %= n2).expectStaticType<Exactly<num>>();
+  (n += dyn1).expectStaticType<Exactly<num>>();
+  (n -= dyn1).expectStaticType<Exactly<num>>();
+  (n *= dyn1).expectStaticType<Exactly<num>>();
+  (n %= dyn2).expectStaticType<Exactly<num>>();
+  (n++).expectStaticType<Exactly<num>>();
+  (n--).expectStaticType<Exactly<num>>();
+  (++n).expectStaticType<Exactly<num>>();
+  (--n).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (d += never).expectStaticType<Exactly<double>>();
+    (n += never).expectStaticType<Exactly<num>>();
+  }
+}
+
+// Check the static type of operations on promoted variables.
+void testPromotedVariables(Object i, Object d, Object n) {
+  if (i is! int) throw "promote i to int";
+  if (d is! double) throw "promote d to double";
+  if (n is! num) throw "promote n to num";
+  i.expectStaticType<Exactly<int>>();
+  d.expectStaticType<Exactly<double>>();
+  n.expectStaticType<Exactly<num>>();
+
+  (i + i).expectStaticType<Exactly<int>>();
+  (i - i).expectStaticType<Exactly<int>>();
+  (i * i).expectStaticType<Exactly<int>>();
+  (i % i).expectStaticType<Exactly<int>>();
+  i.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + d).expectStaticType<Exactly<double>>();
+  (i - d).expectStaticType<Exactly<double>>();
+  (i * d).expectStaticType<Exactly<double>>();
+  (i % d).expectStaticType<Exactly<double>>();
+  i.remainder(d).expectStaticType<Exactly<double>>();
+
+  (i + n).expectStaticType<Exactly<num>>();
+  (i - n).expectStaticType<Exactly<num>>();
+  (i * n).expectStaticType<Exactly<num>>();
+  (i % n).expectStaticType<Exactly<num>>();
+  i.remainder(n).expectStaticType<Exactly<num>>();
+
+  (i + dyn1).expectStaticType<Exactly<num>>();
+  (i - dyn1).expectStaticType<Exactly<num>>();
+  (i * dyn1).expectStaticType<Exactly<num>>();
+  (i % dyn1).expectStaticType<Exactly<num>>();
+  i.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (i + never).expectStaticType<Exactly<num>>();
+    (i - never).expectStaticType<Exactly<num>>();
+    (i * never).expectStaticType<Exactly<num>>();
+    (i % never).expectStaticType<Exactly<num>>();
+    i.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (d + i).expectStaticType<Exactly<double>>();
+  (d - i).expectStaticType<Exactly<double>>();
+  (d * i).expectStaticType<Exactly<double>>();
+  (d % i).expectStaticType<Exactly<double>>();
+  d.remainder(i).expectStaticType<Exactly<double>>();
+
+  (d + d).expectStaticType<Exactly<double>>();
+  (d - d).expectStaticType<Exactly<double>>();
+  (d * d).expectStaticType<Exactly<double>>();
+  (d % d).expectStaticType<Exactly<double>>();
+  d.remainder(d).expectStaticType<Exactly<double>>();
+
+  (d + n).expectStaticType<Exactly<double>>();
+  (d - n).expectStaticType<Exactly<double>>();
+  (d * n).expectStaticType<Exactly<double>>();
+  (d % n).expectStaticType<Exactly<double>>();
+  d.remainder(n).expectStaticType<Exactly<double>>();
+
+  (d + dyn1).expectStaticType<Exactly<double>>();
+  (d - dyn1).expectStaticType<Exactly<double>>();
+  (d * dyn1).expectStaticType<Exactly<double>>();
+  (d % dyn1).expectStaticType<Exactly<double>>();
+  d.remainder(dyn1).expectStaticType<Exactly<double>>();
+
+  if (false) {
+    (d + never).expectStaticType<Exactly<double>>();
+    (d - never).expectStaticType<Exactly<double>>();
+    (d * never).expectStaticType<Exactly<double>>();
+    (d % never).expectStaticType<Exactly<double>>();
+    d.remainder(never).expectStaticType<Exactly<double>>();
+  }
+
+  (n + i).expectStaticType<Exactly<num>>();
+  (n - i).expectStaticType<Exactly<num>>();
+  (n * i).expectStaticType<Exactly<num>>();
+  (n % i).expectStaticType<Exactly<num>>();
+  n.remainder(i).expectStaticType<Exactly<num>>();
+
+  (n + d).expectStaticType<Exactly<double>>();
+  (n - d).expectStaticType<Exactly<double>>();
+  (n * d).expectStaticType<Exactly<double>>();
+  (n % d).expectStaticType<Exactly<double>>();
+  n.remainder(d).expectStaticType<Exactly<double>>();
+
+  (n + n).expectStaticType<Exactly<num>>();
+  (n - n).expectStaticType<Exactly<num>>();
+  (n * n).expectStaticType<Exactly<num>>();
+  (n % n).expectStaticType<Exactly<num>>();
+  n.remainder(n).expectStaticType<Exactly<num>>();
+
+  (n + dyn1).expectStaticType<Exactly<num>>();
+  (n - dyn1).expectStaticType<Exactly<num>>();
+  (n * dyn1).expectStaticType<Exactly<num>>();
+  (n % dyn1).expectStaticType<Exactly<num>>();
+  n.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (n + never).expectStaticType<Exactly<num>>();
+    (n - never).expectStaticType<Exactly<num>>();
+    (n * never).expectStaticType<Exactly<num>>();
+    (n % never).expectStaticType<Exactly<num>>();
+    n.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (dyn1 + d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 - d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 * d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 % d).expectStaticType<Exactly<dynamic>>();
+  dyn1.remainder(d).expectStaticType<Exactly<dynamic>>();
+
+  if (false) {
+    (never + d).expectStaticType<Exactly<Never>>();
+    (never - d).expectStaticType<Exactly<Never>>();
+    (never * d).expectStaticType<Exactly<Never>>();
+    (never % d).expectStaticType<Exactly<Never>>();
+    never.remainder(d).expectStaticType<Exactly<Never>>();
+  }
+
+  i.clamp(i, i).expectStaticType<Exactly<int>>();
+  d.clamp(d, d).expectStaticType<Exactly<double>>();
+
+  i.clamp(i, d).expectStaticType<Exactly<num>>();
+  i.clamp(d, i).expectStaticType<Exactly<num>>();
+  d.clamp(i, i).expectStaticType<Exactly<num>>();
+  i.clamp(d, d).expectStaticType<Exactly<num>>();
+  d.clamp(i, d).expectStaticType<Exactly<num>>();
+  d.clamp(d, i).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, n).expectStaticType<Exactly<num>>();
+  i.clamp(n, i).expectStaticType<Exactly<num>>();
+  n.clamp(i, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, n).expectStaticType<Exactly<num>>();
+  d.clamp(n, d).expectStaticType<Exactly<num>>();
+  n.clamp(d, d).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, dyn1).expectStaticType<Exactly<num>>();
+  i.clamp(dyn1, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, dyn1).expectStaticType<Exactly<num>>();
+  d.clamp(dyn1, d).expectStaticType<Exactly<num>>();
+  n.clamp(n, dyn1).expectStaticType<Exactly<num>>();
+  n.clamp(dyn1, n).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    i.clamp(i, never).expectStaticType<Exactly<num>>();
+    d.clamp(d, never).expectStaticType<Exactly<num>>();
+    n.clamp(n, never).expectStaticType<Exactly<num>>();
+    never.clamp(i, i).expectStaticType<Exactly<Never>>();
+  }
+
+  (i += i1).expectStaticType<Exactly<int>>();
+  (i -= i1).expectStaticType<Exactly<int>>();
+  (i *= i1).expectStaticType<Exactly<int>>();
+  (i %= i2).expectStaticType<Exactly<int>>();
+  (i++).expectStaticType<Exactly<int>>();
+  (i--).expectStaticType<Exactly<int>>();
+  (++i).expectStaticType<Exactly<int>>();
+  (--i).expectStaticType<Exactly<int>>();
+
+  (d += i1).expectStaticType<Exactly<double>>();
+  (d -= i1).expectStaticType<Exactly<double>>();
+  (d *= i1).expectStaticType<Exactly<double>>();
+  (d %= i2).expectStaticType<Exactly<double>>();
+  (d += 1.0).expectStaticType<Exactly<double>>();
+  (d -= 1.0).expectStaticType<Exactly<double>>();
+  (d *= 1.0).expectStaticType<Exactly<double>>();
+  (d %= 1.0).expectStaticType<Exactly<double>>();
+  (d += n1).expectStaticType<Exactly<double>>();
+  (d -= n1).expectStaticType<Exactly<double>>();
+  (d *= n1).expectStaticType<Exactly<double>>();
+  (d %= n2).expectStaticType<Exactly<double>>();
+  (d += dyn1).expectStaticType<Exactly<double>>();
+  (d -= dyn1).expectStaticType<Exactly<double>>();
+  (d *= dyn1).expectStaticType<Exactly<double>>();
+  (d %= dyn2).expectStaticType<Exactly<double>>();
+  (d++).expectStaticType<Exactly<double>>();
+  (d--).expectStaticType<Exactly<double>>();
+  (++d).expectStaticType<Exactly<double>>();
+  (--d).expectStaticType<Exactly<double>>();
+
+  (n += i1).expectStaticType<Exactly<num>>();
+  (n -= i1).expectStaticType<Exactly<num>>();
+  (n *= i1).expectStaticType<Exactly<num>>();
+  (n %= i2).expectStaticType<Exactly<num>>();
+  (n += 1.0).expectStaticType<Exactly<double>>();
+  (n -= 1.0).expectStaticType<Exactly<double>>();
+  (n *= 1.0).expectStaticType<Exactly<double>>();
+  (n %= 1.0).expectStaticType<Exactly<double>>();
+  (n += n1).expectStaticType<Exactly<num>>();
+  (n -= n1).expectStaticType<Exactly<num>>();
+  (n *= n1).expectStaticType<Exactly<num>>();
+  (n %= n2).expectStaticType<Exactly<num>>();
+  (n += dyn1).expectStaticType<Exactly<num>>();
+  (n -= dyn1).expectStaticType<Exactly<num>>();
+  (n *= dyn1).expectStaticType<Exactly<num>>();
+  (n %= dyn2).expectStaticType<Exactly<num>>();
+  (n++).expectStaticType<Exactly<num>>();
+  (n--).expectStaticType<Exactly<num>>();
+  (++n).expectStaticType<Exactly<num>>();
+  (--n).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (d += never).expectStaticType<Exactly<double>>();
+    (n += never).expectStaticType<Exactly<num>>();
+  }
+}
+
+// Check the static type of operations on promoted variables.
+void testTypeVariables<I extends int, D extends double, N extends num>(
+    I i, D d, N n) {
+  int ii = i; // Actual int type.
+
+  (ii + i).expectStaticType<Exactly<int>>();
+  (ii - i).expectStaticType<Exactly<int>>();
+  (ii * i).expectStaticType<Exactly<int>>();
+  (ii % i).expectStaticType<Exactly<int>>();
+  ii.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + ii).expectStaticType<Exactly<int>>();
+  (i - ii).expectStaticType<Exactly<int>>();
+  (i * ii).expectStaticType<Exactly<int>>();
+  (i % ii).expectStaticType<Exactly<int>>();
+  i.remainder(ii).expectStaticType<Exactly<int>>();
+
+  (i + i).expectStaticType<Exactly<int>>();
+  (i - i).expectStaticType<Exactly<int>>();
+  (i * i).expectStaticType<Exactly<int>>();
+  (i % i).expectStaticType<Exactly<int>>();
+  i.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + d).expectStaticType<Exactly<double>>();
+  (i - d).expectStaticType<Exactly<double>>();
+  (i * d).expectStaticType<Exactly<double>>();
+  (i % d).expectStaticType<Exactly<double>>();
+  i.remainder(d).expectStaticType<Exactly<double>>();
+
+  (i + n).expectStaticType<Exactly<num>>();
+  (i - n).expectStaticType<Exactly<num>>();
+  (i * n).expectStaticType<Exactly<num>>();
+  (i % n).expectStaticType<Exactly<num>>();
+  i.remainder(n).expectStaticType<Exactly<num>>();
+
+  (i + dyn1).expectStaticType<Exactly<num>>();
+  (i - dyn1).expectStaticType<Exactly<num>>();
+  (i * dyn1).expectStaticType<Exactly<num>>();
+  (i % dyn1).expectStaticType<Exactly<num>>();
+  i.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (i + never).expectStaticType<Exactly<num>>();
+    (i - never).expectStaticType<Exactly<num>>();
+    (i * never).expectStaticType<Exactly<num>>();
+    (i % never).expectStaticType<Exactly<num>>();
+    i.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (d + i).expectStaticType<Exactly<double>>();
+  (d - i).expectStaticType<Exactly<double>>();
+  (d * i).expectStaticType<Exactly<double>>();
+  (d % i).expectStaticType<Exactly<double>>();
+  d.remainder(i).expectStaticType<Exactly<double>>();
+
+  double dd = d; // Actual double type.
+
+  (dd + d).expectStaticType<Exactly<double>>();
+  (dd - d).expectStaticType<Exactly<double>>();
+  (dd * d).expectStaticType<Exactly<double>>();
+  (dd % d).expectStaticType<Exactly<double>>();
+  dd.remainder(d).expectStaticType<Exactly<double>>();
+
+  (d + dd).expectStaticType<Exactly<double>>();
+  (d - dd).expectStaticType<Exactly<double>>();
+  (d * dd).expectStaticType<Exactly<double>>();
+  (d % dd).expectStaticType<Exactly<double>>();
+  d.remainder(dd).expectStaticType<Exactly<double>>();
+
+  (d + d).expectStaticType<Exactly<double>>();
+  (d - d).expectStaticType<Exactly<double>>();
+  (d * d).expectStaticType<Exactly<double>>();
+  (d % d).expectStaticType<Exactly<double>>();
+  d.remainder(d).expectStaticType<Exactly<double>>();
+
+  (d + n).expectStaticType<Exactly<double>>();
+  (d - n).expectStaticType<Exactly<double>>();
+  (d * n).expectStaticType<Exactly<double>>();
+  (d % n).expectStaticType<Exactly<double>>();
+  d.remainder(n).expectStaticType<Exactly<double>>();
+
+  (d + dyn1).expectStaticType<Exactly<double>>();
+  (d - dyn1).expectStaticType<Exactly<double>>();
+  (d * dyn1).expectStaticType<Exactly<double>>();
+  (d % dyn1).expectStaticType<Exactly<double>>();
+  d.remainder(dyn1).expectStaticType<Exactly<double>>();
+
+  if (false) {
+    (d + never).expectStaticType<Exactly<double>>();
+    (d - never).expectStaticType<Exactly<double>>();
+    (d * never).expectStaticType<Exactly<double>>();
+    (d % never).expectStaticType<Exactly<double>>();
+    d.remainder(never).expectStaticType<Exactly<double>>();
+  }
+
+  (n + i).expectStaticType<Exactly<num>>();
+  (n - i).expectStaticType<Exactly<num>>();
+  (n * i).expectStaticType<Exactly<num>>();
+  (n % i).expectStaticType<Exactly<num>>();
+  n.remainder(i).expectStaticType<Exactly<num>>();
+
+  (n + d).expectStaticType<Exactly<double>>();
+  (n - d).expectStaticType<Exactly<double>>();
+  (n * d).expectStaticType<Exactly<double>>();
+  (n % d).expectStaticType<Exactly<double>>();
+  n.remainder(d).expectStaticType<Exactly<double>>();
+
+  num nn = n; // Actual num type.
+
+  (nn + n).expectStaticType<Exactly<num>>();
+  (nn - n).expectStaticType<Exactly<num>>();
+  (nn * n).expectStaticType<Exactly<num>>();
+  (nn % n).expectStaticType<Exactly<num>>();
+  nn.remainder(n).expectStaticType<Exactly<num>>();
+
+  (n + nn).expectStaticType<Exactly<num>>();
+  (n - nn).expectStaticType<Exactly<num>>();
+  (n * nn).expectStaticType<Exactly<num>>();
+  (n % nn).expectStaticType<Exactly<num>>();
+  n.remainder(nn).expectStaticType<Exactly<num>>();
+
+  (n + n).expectStaticType<Exactly<num>>();
+  (n - n).expectStaticType<Exactly<num>>();
+  (n * n).expectStaticType<Exactly<num>>();
+  (n % n).expectStaticType<Exactly<num>>();
+  n.remainder(n).expectStaticType<Exactly<num>>();
+
+  (n + dyn1).expectStaticType<Exactly<num>>();
+  (n - dyn1).expectStaticType<Exactly<num>>();
+  (n * dyn1).expectStaticType<Exactly<num>>();
+  (n % dyn1).expectStaticType<Exactly<num>>();
+  n.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (n + never).expectStaticType<Exactly<num>>();
+    (n - never).expectStaticType<Exactly<num>>();
+    (n * never).expectStaticType<Exactly<num>>();
+    (n % never).expectStaticType<Exactly<num>>();
+    n.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (dyn1 + d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 - d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 * d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 % d).expectStaticType<Exactly<dynamic>>();
+  dyn1.remainder(d).expectStaticType<Exactly<dynamic>>();
+
+  if (false) {
+    (never + d).expectStaticType<Exactly<Never>>();
+    (never - d).expectStaticType<Exactly<Never>>();
+    (never * d).expectStaticType<Exactly<Never>>();
+    (never % d).expectStaticType<Exactly<Never>>();
+    never.remainder(d).expectStaticType<Exactly<Never>>();
+  }
+
+  i.clamp(i, i).expectStaticType<Exactly<int>>();
+  i.clamp(i, ii).expectStaticType<Exactly<int>>();
+  i.clamp(ii, i).expectStaticType<Exactly<int>>();
+  ii.clamp(i, i).expectStaticType<Exactly<int>>();
+
+  d.clamp(d, d).expectStaticType<Exactly<double>>();
+  d.clamp(d, dd).expectStaticType<Exactly<double>>();
+  d.clamp(dd, d).expectStaticType<Exactly<double>>();
+  dd.clamp(d, d).expectStaticType<Exactly<double>>();
+
+  n.clamp(n, n).expectStaticType<Exactly<num>>();
+  n.clamp(n, nn).expectStaticType<Exactly<num>>();
+  n.clamp(nn, n).expectStaticType<Exactly<num>>();
+  nn.clamp(n, n).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, d).expectStaticType<Exactly<num>>();
+  i.clamp(d, i).expectStaticType<Exactly<num>>();
+  d.clamp(i, i).expectStaticType<Exactly<num>>();
+  i.clamp(d, d).expectStaticType<Exactly<num>>();
+  d.clamp(i, d).expectStaticType<Exactly<num>>();
+  d.clamp(d, i).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, n).expectStaticType<Exactly<num>>();
+  i.clamp(n, i).expectStaticType<Exactly<num>>();
+  n.clamp(i, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, n).expectStaticType<Exactly<num>>();
+  d.clamp(n, d).expectStaticType<Exactly<num>>();
+  n.clamp(d, d).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, dyn1).expectStaticType<Exactly<num>>();
+  i.clamp(dyn1, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, dyn1).expectStaticType<Exactly<num>>();
+  d.clamp(dyn1, d).expectStaticType<Exactly<num>>();
+  n.clamp(i, dyn1).expectStaticType<Exactly<num>>();
+  n.clamp(dyn1, d).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    i.clamp(i, never).expectStaticType<Exactly<num>>();
+    d.clamp(d, never).expectStaticType<Exactly<num>>();
+    n.clamp(n, never).expectStaticType<Exactly<num>>();
+    never.clamp(i, i).expectStaticType<Exactly<Never>>();
+  }
+
+  Object on = 1;
+  if (on is! N) throw "promote on to O&N";
+  var onn = on;
+  if (onn is! num) throw "promote onn O&N&num";
+
+  // With three different type variable types,
+  // still pick num.
+  n.clamp(on, onn).expectStaticType<Exactly<num>>();
+  on.clamp(n, onn).expectStaticType<Exactly<num>>();
+  onn.clamp(on, n).expectStaticType<Exactly<num>>();
+}
+
+// Check the static type of operations on promoted type variables.
+void testPromotedTypeVariables<T>(T i, T d, T n) {
+  if (i is! int) throw "promote i to T & int";
+  if (d is! double) throw "promote d to T & double";
+  if (n is! num) throw "promote n to T & num";
+  // We cannot pass intersection types to type parameters,
+  // so we need to check them in-place.
+  // We check that the value is assignable to both types,
+  // and are not dynamic (assignable to `Object`).
+  checkIntersectionType<int, T>(i, i, i);
+  checkIntersectionType<double, T>(d, d, d);
+  checkIntersectionType<num, T>(n, n, n);
+
+  int ii = i; // Actual integer type.
+
+  (ii + i).expectStaticType<Exactly<int>>();
+  (ii - i).expectStaticType<Exactly<int>>();
+  (ii * i).expectStaticType<Exactly<int>>();
+  (ii % i).expectStaticType<Exactly<int>>();
+  ii.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + i).expectStaticType<Exactly<int>>();
+  (i - i).expectStaticType<Exactly<int>>();
+  (i * i).expectStaticType<Exactly<int>>();
+  (i % i).expectStaticType<Exactly<int>>();
+  i.remainder(i).expectStaticType<Exactly<int>>();
+
+  (i + ii).expectStaticType<Exactly<int>>();
+  (i - ii).expectStaticType<Exactly<int>>();
+  (i * ii).expectStaticType<Exactly<int>>();
+  (i % ii).expectStaticType<Exactly<int>>();
+  i.remainder(ii).expectStaticType<Exactly<int>>();
+
+  (i + d).expectStaticType<Exactly<double>>();
+  (i - d).expectStaticType<Exactly<double>>();
+  (i * d).expectStaticType<Exactly<double>>();
+  (i % d).expectStaticType<Exactly<double>>();
+  i.remainder(d).expectStaticType<Exactly<double>>();
+
+  (i + n).expectStaticType<Exactly<num>>();
+  (i - n).expectStaticType<Exactly<num>>();
+  (i * n).expectStaticType<Exactly<num>>();
+  (i % n).expectStaticType<Exactly<num>>();
+  i.remainder(n).expectStaticType<Exactly<num>>();
+
+  (i + dyn1).expectStaticType<Exactly<num>>();
+  (i - dyn1).expectStaticType<Exactly<num>>();
+  (i * dyn1).expectStaticType<Exactly<num>>();
+  (i % dyn1).expectStaticType<Exactly<num>>();
+  i.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (i + never).expectStaticType<Exactly<num>>();
+    (i - never).expectStaticType<Exactly<num>>();
+    (i * never).expectStaticType<Exactly<num>>();
+    (i % never).expectStaticType<Exactly<num>>();
+    i.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (d + i).expectStaticType<Exactly<double>>();
+  (d - i).expectStaticType<Exactly<double>>();
+  (d * i).expectStaticType<Exactly<double>>();
+  (d % i).expectStaticType<Exactly<double>>();
+  d.remainder(i).expectStaticType<Exactly<double>>();
+
+  double dd = d; // Actual double type.
+
+  (dd + d).expectStaticType<Exactly<double>>();
+  (dd - d).expectStaticType<Exactly<double>>();
+  (dd * d).expectStaticType<Exactly<double>>();
+  (dd % d).expectStaticType<Exactly<double>>();
+  dd.remainder(d).expectStaticType<Exactly<double>>();
+
+  // Result type T&double;
+  (d + dd).expectStaticType<Exactly<double>>();
+  (d - dd).expectStaticType<Exactly<double>>();
+  (d * dd).expectStaticType<Exactly<double>>();
+  (d % dd).expectStaticType<Exactly<double>>();
+  d.remainder(dd).expectStaticType<Exactly<double>>();
+
+  (d + d).expectStaticType<Exactly<double>>();
+  (d - d).expectStaticType<Exactly<double>>();
+  (d * d).expectStaticType<Exactly<double>>();
+  (d % d).expectStaticType<Exactly<double>>();
+  d.remainder(d).expectStaticType<Exactly<double>>();
+
+  (d + n).expectStaticType<Exactly<double>>();
+  (d - n).expectStaticType<Exactly<double>>();
+  (d * n).expectStaticType<Exactly<double>>();
+  (d % n).expectStaticType<Exactly<double>>();
+  d.remainder(n).expectStaticType<Exactly<double>>();
+
+  (d + dyn1).expectStaticType<Exactly<double>>();
+  (d - dyn1).expectStaticType<Exactly<double>>();
+  (d * dyn1).expectStaticType<Exactly<double>>();
+  (d % dyn1).expectStaticType<Exactly<double>>();
+  d.remainder(dyn1).expectStaticType<Exactly<double>>();
+
+  if (false) {
+    d + never.expectStaticType<Exactly<double>>();
+    d - never.expectStaticType<Exactly<double>>();
+    d * never.expectStaticType<Exactly<double>>();
+    d % never.expectStaticType<Exactly<double>>();
+    d.remainder(never).expectStaticType<Exactly<double>>();
+  }
+
+  (n + i).expectStaticType<Exactly<num>>();
+  (n - i).expectStaticType<Exactly<num>>();
+  (n * i).expectStaticType<Exactly<num>>();
+  (n % i).expectStaticType<Exactly<num>>();
+  n.remainder(i).expectStaticType<Exactly<num>>();
+
+  (n + d).expectStaticType<Exactly<double>>();
+  (n - d).expectStaticType<Exactly<double>>();
+  (n * d).expectStaticType<Exactly<double>>();
+  (n % d).expectStaticType<Exactly<double>>();
+  n.remainder(d).expectStaticType<Exactly<double>>();
+
+  num nn = n; // Actual num-typed value.
+
+  (nn + n).expectStaticType<Exactly<num>>();
+  (nn - n).expectStaticType<Exactly<num>>();
+  (nn * n).expectStaticType<Exactly<num>>();
+  (nn % n).expectStaticType<Exactly<num>>();
+  nn.remainder(n).expectStaticType<Exactly<num>>();
+
+  (nn + dyn1).expectStaticType<Exactly<num>>();
+  (nn - dyn1).expectStaticType<Exactly<num>>();
+  (nn * dyn1).expectStaticType<Exactly<num>>();
+  (nn % dyn1).expectStaticType<Exactly<num>>();
+  nn.remainder(dyn1).expectStaticType<Exactly<num>>();
+
+  (n + nn).expectStaticType<Exactly<num>>();
+  (n - nn).expectStaticType<Exactly<num>>();
+  (n * nn).expectStaticType<Exactly<num>>();
+  (n % nn).expectStaticType<Exactly<num>>();
+  n.remainder(nn).expectStaticType<Exactly<num>>();
+
+  (n + n).expectStaticType<Exactly<num>>();
+  (n - n).expectStaticType<Exactly<num>>();
+  (n * n).expectStaticType<Exactly<num>>();
+  (n % n).expectStaticType<Exactly<num>>();
+  n.remainder(n).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    (n + never).expectStaticType<Exactly<num>>();
+    (n - never).expectStaticType<Exactly<num>>();
+    (n * never).expectStaticType<Exactly<num>>();
+    (n % never).expectStaticType<Exactly<num>>();
+    n.remainder(never).expectStaticType<Exactly<num>>();
+  }
+
+  (dyn1 + d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 - d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 * d).expectStaticType<Exactly<dynamic>>();
+  (dyn1 % d).expectStaticType<Exactly<dynamic>>();
+  dyn1.remainder(d).expectStaticType<Exactly<dynamic>>();
+
+  if (false) {
+    (never + d).expectStaticType<Exactly<Never>>();
+    (never - d).expectStaticType<Exactly<Never>>();
+    (never * d).expectStaticType<Exactly<Never>>();
+    (never % d).expectStaticType<Exactly<Never>>();
+    never.remainder(d).expectStaticType<Exactly<Never>>();
+  }
+
+  i.clamp(i, i).expectStaticType<Exactly<int>>();
+  i.clamp(i, ii).expectStaticType<Exactly<int>>();
+  i.clamp(ii, i).expectStaticType<Exactly<int>>();
+  ii.clamp(i, i).expectStaticType<Exactly<int>>();
+
+  d.clamp(d, d).expectStaticType<Exactly<double>>();
+  d.clamp(d, dd).expectStaticType<Exactly<double>>();
+  d.clamp(dd, d).expectStaticType<Exactly<double>>();
+  dd.clamp(d, d).expectStaticType<Exactly<double>>();
+
+  n.clamp(n, n).expectStaticType<Exactly<num>>();
+  n.clamp(n, nn).expectStaticType<Exactly<num>>();
+  n.clamp(nn, n).expectStaticType<Exactly<num>>();
+  nn.clamp(n, n).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, d).expectStaticType<Exactly<num>>();
+  i.clamp(d, i).expectStaticType<Exactly<num>>();
+  d.clamp(i, i).expectStaticType<Exactly<num>>();
+  i.clamp(d, d).expectStaticType<Exactly<num>>();
+  d.clamp(i, d).expectStaticType<Exactly<num>>();
+  d.clamp(d, i).expectStaticType<Exactly<num>>();
+
+  i.clamp(i, dyn1).expectStaticType<Exactly<num>>();
+  i.clamp(dyn1, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, dyn1).expectStaticType<Exactly<num>>();
+  d.clamp(dyn1, d).expectStaticType<Exactly<num>>();
+  n.clamp(n, dyn1).expectStaticType<Exactly<num>>();
+  n.clamp(dyn1, n).expectStaticType<Exactly<num>>();
+
+  // The type T&num is a supertype of T&int/T&double, so it is the result type.
+  i.clamp(i, n).expectStaticType<Exactly<num>>();
+  i.clamp(n, i).expectStaticType<Exactly<num>>();
+  n.clamp(i, i).expectStaticType<Exactly<num>>();
+  d.clamp(d, n).expectStaticType<Exactly<num>>();
+  d.clamp(n, d).expectStaticType<Exactly<num>>();
+  n.clamp(d, d).expectStaticType<Exactly<num>>();
+  i.clamp(d, n).expectStaticType<Exactly<num>>();
+  d.clamp(i, n).expectStaticType<Exactly<num>>();
+  n.clamp(i, d).expectStaticType<Exactly<num>>();
+
+  if (false) {
+    i.clamp(i, never).expectStaticType<Exactly<num>>();
+    d.clamp(d, never).expectStaticType<Exactly<num>>();
+    n.clamp(n, never).expectStaticType<Exactly<num>>();
+    never.clamp(i, i).expectStaticType<Exactly<Never>>();
+  }
+}
+
+/// Perform constant operations and check that they are still valid.
+class TestConst<I extends int, D extends double, N extends num> {
+  static const dynamic dyn = 1;
+  final int int1;
+  final int int2;
+  final int int3;
+  final int int4;
+  final double dbl1;
+  final double dbl2;
+  final double dbl3;
+  final double dbl4;
+  final double dbl5;
+  final double dbl6;
+  final double dbl7;
+  final double dbl8;
+  final double dbl9;
+  final double dbl10;
+  final num num1;
+  final num num2;
+  final num num3;
+  final num num4;
+  final num num5;
+  const TestConst(I i, D d, N n)
+      : int1 = 1 + i,
+        int2 = i + 1,
+        int3 = i + 1,
+        int4 = i + i,
+        dbl1 = 1.0 + i,
+        dbl2 = 1.0 + d,
+        dbl3 = 1.0 + n,
+        dbl4 = 1.0 + dyn,
+        dbl5 = 1 + 1, // Checking context type of "double = int + _".
+        dbl6 = n + 1, // Checking context type of "double = num + _".
+        dbl7 = d + i,
+        dbl8 = d + d,
+        dbl9 = d + n,
+        dbl10 = d + dyn,
+        num1 = i + n,
+        num2 = n + d,
+        num3 = n + n,
+        num4 = n + i,
+        num5 = n + dyn;
+}
diff --git a/tests/language/operator/static_type_helper.dart b/tests/language/operator/static_type_helper.dart
new file mode 100644
index 0000000..50cdace
--- /dev/null
+++ b/tests/language/operator/static_type_helper.dart
@@ -0,0 +1,70 @@
+// 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.
+
+// Ensures a context type of [T] for the operand.
+void context<T>(T x) {}
+
+/// Captures the context type of the call and returns the same type.
+///
+/// Can be used to check the context type as:
+/// ```dart
+/// int x = contextType(1 /* valid value */)..expectStaticType<Exactly<int>>;
+/// ```
+T contextType<T>(Object result) => result as T;
+
+extension StaticType<T> on T {
+  /// Check the static type.
+  ///
+  /// Use as follows (assuming `e` has static type `num`):
+  /// ```dart
+  ///   e.expectStaticType<Exactly<num>>()  // No context type.
+  ///   e.expectStaticType<SubtypeOf<Object>>()  // No context type.
+  ///   e.expectStaticType<SupertypeOf<int>>()  // No context type.
+  /// ```
+  /// or
+  /// ```dart
+  ///   e..expectStaticType<Exactly<num>>()  // Preserve context type.
+  ///   e..expectStaticType<SubtypeOf<Object>>()  // Preserve context type.
+  ///   e..expectStaticType<SupertypeOf<int>>()  // Preserve context type.
+  /// ```
+  /// This will be a *compile-time error* if the static type is not
+  /// as required by the constraints type (the one passed to [Exactly],
+  /// [SubtypeOf] or [SupertypeOf].)
+  T expectStaticType<R extends Exactly<T>>() {
+    return this;
+  }
+}
+
+/// Use with [StaticType.expectStaticType] to expect precisely the type [T].
+///
+/// Example use:
+/// ```dart
+/// "abc".expectStaticType<Exactly<String>>();
+/// ```
+typedef Exactly<T> = T Function(T);
+
+/// Use with [StaticType.expectStaticType] to expect a subtype of [T].
+///
+/// Example use:
+/// ```dart
+/// num x = 1;
+/// x.expectStaticType<SubtypeOf<Object>>();
+/// ```
+typedef SubtypeOf<T> = Never Function(T);
+
+/// Use with [StaticType.expectStaticType] to expect a supertype of [T].
+///
+/// Example use:
+/// ```dart
+/// num x = 1;
+/// x.expectStaticType<SupertypeOf<int>>();
+/// ```
+typedef SupertypeOf<T> = T Function(Object?);
+
+/// Checks that an expression is assignable to [T1], [T2] and [Object].
+///
+/// This ensures that the type of the expression is a non-`dynamic`
+/// type assignable to both [T1] and [T2], and if those are unrelated,
+/// it must be an intersection type.
+void checkIntersectionType<T1, T2>(T1 v1, T2 v2, Object v3) {}
diff --git a/tests/language/prefix/shadow_test.dart b/tests/language/prefix/shadow_test.dart
index 4a5bdc2..1680b1e 100644
--- a/tests/language/prefix/shadow_test.dart
+++ b/tests/language/prefix/shadow_test.dart
@@ -11,6 +11,8 @@
 class P<T> {
   test() {
     new T.Library10(10);
+    //  ^
+    // [analyzer] COMPILE_TIME_ERROR.PREFIX_SHADOWED_BY_LOCAL_DECLARATION
     //    ^
     // [cfe] Method not found: 'T.Library10'.
   }
diff --git a/tests/language/setter/declaration_test.dart b/tests/language/setter/declaration_test.dart
index cc5e6a7..7a597eb 100644
--- a/tests/language/setter/declaration_test.dart
+++ b/tests/language/setter/declaration_test.dart
@@ -2,7 +2,9 @@
 // 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.
 
-/// Test that a setter has a single argument.
+// Test that a setter has a single argument.
+
+import 'dart:async';
 
 set tooFew() {}
 //  ^^^^^^
@@ -16,7 +18,153 @@
 //         ^
 // [cfe] A setter should have exactly one formal parameter.
 
+/*space*/ int? set wrongReturnType1(_) => 1;
+//        ^^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+/*space*/ FutureOr<void> set wrongReturnType2(_) {}
+//        ^^^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+/*space*/ Never set wrongReturnType3(_) => throw 1;
+//        ^^^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+int get nonSubtypes1 => 1;
+//      ^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+// [cfe] unspecified
+set nonSubtypes1(String _) {}
+
+int? get nonSubtypes2 => 1;
+//       ^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+// [cfe] unspecified
+set nonSubtypes2(int _) {}
+
+FutureOr<int> get nonSubtypes3 => 1;
+//                ^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+// [cfe] unspecified
+set nonSubtypes3(int _) {}
+
+dynamic get nonSubtypes4 => 1;
+//          ^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+// [cfe] unspecified
+set nonSubtypes4(int _) {}
+
+class C {
+  static int? set staticWrongReturnType1(_) => 1;
+  //     ^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static FutureOr<void> set staticWrongReturnType2(_) {}
+  //     ^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static Never set staticWrongReturnType3(_) => throw 1;
+  //     ^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ int? set wrongReturnType1(_) => 1;
+  //        ^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ FutureOr<void> set wrongReturnType2(_) {}
+  //        ^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ Never set wrongReturnType3(_) => throw 1;
+  //        ^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static int get staticNonSubtypes1 => 1;
+  //             ^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  static set staticNonSubtypes1(String _) {}
+
+  static int? get staticNonSubtypes2 => 1;
+  //              ^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  static set staticNonSubtypes2(int _) {}
+
+  static FutureOr<int> get staticNonSubtypes3 => 1;
+  //                       ^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  static set staticNonSubtypes3(int _) {}
+
+  static dynamic get staticNonSubtypes4 => 1;
+  //                 ^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  static set staticNonSubtypes4(int _) {}
+
+  int get nonSubtypes1 => 1;
+  //      ^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  set nonSubtypes1(String _) {}
+
+  int? get nonSubtypes2 => 1;
+  //       ^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  set nonSubtypes2(int _) {}
+
+  FutureOr<int> get nonSubtypes3 => 1;
+  //                ^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  set nonSubtypes3(int _) {}
+
+  dynamic get nonSubtypes4 => 1;
+  //          ^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_SUBTYPE_SETTER_TYPES
+  // [cfe] unspecified
+  set nonSubtypes4(int _) {}
+}
+
 main() {
   tooFew = 1;
-  tooMany = 2;
+  tooMany = 1;
+  wrongReturnType1 = 1;
+  wrongReturnType2 = 1;
+  wrongReturnType3 = 1;
+  C.staticWrongReturnType1 = 1;
+  C.staticWrongReturnType2 = 1;
+  C.staticWrongReturnType3 = 1;
+  C().wrongReturnType1 = 1;
+  C().wrongReturnType2 = 1;
+  C().wrongReturnType3 = 1;
+  var x1 = C.staticNonSubtypes1;
+  C.staticNonSubtypes1 = '' as dynamic;
+  var x2 = C.staticNonSubtypes2;
+  C.staticNonSubtypes2 = 1 as dynamic;
+  var x3 = C.staticNonSubtypes3;
+  C.staticNonSubtypes3 = 1 as dynamic;
+  var y1 = nonSubtypes1;
+  nonSubtypes1 = '' as dynamic;
+  var y2 = nonSubtypes2;
+  nonSubtypes2 = 1 as dynamic;
+  var y3 = nonSubtypes3;
+  nonSubtypes3 = 1 as dynamic;
+  var z1 = C().nonSubtypes1;
+  C().nonSubtypes1 = '' as dynamic;
+  var z2 = C().nonSubtypes2;
+  C().nonSubtypes2 = 1 as dynamic;
+  var z3 = C().nonSubtypes3;
+  C().nonSubtypes3 = 1 as dynamic;
 }
diff --git a/tests/language/spread_collections/null_spread_test.dart b/tests/language/spread_collections/null_spread_test.dart
new file mode 100644
index 0000000..062cb9f
--- /dev/null
+++ b/tests/language/spread_collections/null_spread_test.dart
@@ -0,0 +1,87 @@
+// 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.
+
+// Test that the inferred element type, key type, and value type of a spread
+// element of the form `...?e` where `e` has type `Null` or a potentially
+// nullable subtype thereof is `Never`; and the element, key, and value types
+// are also `Never` for `...e` where the type of `e` is a subtype of `Never`.
+
+import 'package:expect/expect.dart';
+
+Function f = uncalled; // Do not optimize away `uncalled`.
+Never myNever = throw 1;
+
+void uncalled<X extends Null>(X x) {
+  // Test empty collection, involving only type `Never`.
+  var l1 = [...?x];
+  List<Never> l1b = l1;
+  var l2 = [...myNever];
+  List<Never> l2b = l2;
+  var l3 = [...?myNever]; // Warning, but possible.
+  List<Never> l3b = l3;
+  var s1 = {...?x, if (false) throw 1};
+  Set<Never> s1b = s1;
+  var s2 = {...myNever, if (false) throw 1};
+  Set<Never> s2b = s2;
+  var s3 = {...?myNever, if (false) throw 1}; // Warning.
+  Set<Never> s3b = s3;
+  var m1 = {...?x, if (false) throw 1: throw 1};
+  Map<Never, Never> m1b = m1;
+  var m2 = {...myNever, if (false) throw 1: throw 1};
+  Map<Never, Never> m2b = m2;
+  var m3 = {...?myNever, if (false) throw 1: throw 1}; // Warning.
+  Map<Never, Never> m3b = m3;
+
+  // Test non-empty collection of `Never` and `int`.
+  var li1 = [...?x, 1];
+  List<int> li1b = li1;
+  var li2 = [...myNever, 1];
+  List<int> li2b = li2;
+  var li3 = [...?myNever, 1]; // Warning.
+  List<int> li3b = li3;
+  var si1 = {1, ...?x};
+  Set<int> si1b = si1;
+  var si2 = {1, ...myNever};
+  Set<int> si2b = si2;
+  var si3 = {1, ...?myNever}; // Warning.
+  Set<int> si3b = si3;
+  var mi1 = {1: 1, ...?x};
+  Map<int, int> mi1b = mi1;
+  var mi2 = {1: 1, ...myNever};
+  Map<int, int> mi2b = mi2;
+  var mi3 = {1: 1, ...?myNever}; // Warning.
+  Map<int, int> mi3b = mi3;
+}
+
+void main() {
+  Null myNull = null;
+
+  // Test empty collection, involving only type `Never`.
+  var l1 = [...?null];
+  List<Never> l1b = l1;
+  var l2 = [...?myNull];
+  List<Never> l2b = l2;
+  var s1 = {...?null, if (false) throw 1};
+  Set<Never> s1b = s1;
+  var s2 = {if (false) throw 1, ...?myNull};
+  Set<Never> s2b = s2;
+  var m1 = {...?null, if (false) throw 1: throw 1};
+  Map<Never, Never> m1b = m1;
+  var m2 = {if (false) throw 1: throw 1, ...?myNull};
+  Map<Never, Never> m2b = m2;
+
+  // Test non-empty collection of `Never` and `int`.
+  var li1 = [...?null, 1];
+  List<int> li1b = li1;
+  var li2 = [1, ...?myNull];
+  List<int> li2b = li2;
+  var si1 = {1, ...?null};
+  Set<int> si1b = si1;
+  var si2 = {...?myNull, 1};
+  Set<int> si2b = si2;
+  var mi1 = {1: 1, ...?null};
+  Map<int, int> mi1b = mi1;
+  var mi2 = {...?myNull, 1: 1};
+  Map<int, int> mi2b = mi2;
+}
diff --git a/tests/language/sync_star/void_sync_star_test.dart b/tests/language/sync_star/void_sync_star_test.dart
new file mode 100644
index 0000000..4c387f3
--- /dev/null
+++ b/tests/language/sync_star/void_sync_star_test.dart
@@ -0,0 +1,36 @@
+// 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.
+
+// It is an error for a `sync*` function to have return type `void`.
+
+/*space*/ void f1() sync* {
+  //      ^^^^
+  // [analyzer] unspecified
+  // [cfe] unspecified
+}
+
+class C {
+  static void f2() sync* {
+    //   ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  /*space*/ void f3() sync* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+}
+
+void main() {
+  /*space*/ void f4() sync* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  // No function literal: It is probably not possible to infer the
+  // return type `void` for a function literal marked `sync*`.
+}
diff --git a/tests/language/type/implicit_error_test.dart b/tests/language/type/implicit_error_test.dart
index 1c42842..5adad76 100644
--- a/tests/language/type/implicit_error_test.dart
+++ b/tests/language/type/implicit_error_test.dart
@@ -29,7 +29,6 @@
 
   Expect.throws<TypeError>(() {
     int x = wrap(noToString); // Implicit cast should throw
-    return x;
   }, (e) {
     e.toString(); // Should not throw.
     return true;
diff --git a/tests/language/unsorted/checked_method_error_order_test.dart b/tests/language/unsorted/checked_method_error_order_test.dart
index b8ebfe6..8689027 100644
--- a/tests/language/unsorted/checked_method_error_order_test.dart
+++ b/tests/language/unsorted/checked_method_error_order_test.dart
@@ -35,9 +35,9 @@
     Expect.throws(() => new Bar().optional(i: x, a: y), (e) {
       if (e is TypeError) {
         var m = e.toString();
-        return m.contains("is not a subtype of type 'int'") ||
+        return m.contains("is not a subtype of type 'int?'") ||
             m.contains(
-                "Expected a value of type 'int', but got one of type 'String'");
+                "Expected a value of type 'int?', but got one of type 'String'");
       }
       return false;
     });
diff --git a/tests/language/unsorted/flatten_test.dart b/tests/language/unsorted/flatten_test.dart
index 2ff13e9..0d27daf 100644
--- a/tests/language/unsorted/flatten_test.dart
+++ b/tests/language/unsorted/flatten_test.dart
@@ -33,7 +33,7 @@
   Divergent<Divergent<int>> x = await new Divergent<int>(); //# 09: runtime error
   Future<Divergent<Divergent<int>>> f() async => new Divergent<int>(); //# 10: ok
   Future<Divergent<Divergent<int>>> f() async { return new Divergent<int>(); } //# 11: ok
-  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())(); //# 12: runtime error
+  Future<Divergent<Divergent<int>>> x = (() async => new Divergent<int>())(); //# 12: compile-time error
 }
 
 main() {
diff --git a/tests/language/vm/bool_check_stack_traces_test.dart b/tests/language/vm/bool_check_stack_traces_test.dart
index 71ef230..bdc9ce5 100644
--- a/tests/language/vm/bool_check_stack_traces_test.dart
+++ b/tests/language/vm/bool_check_stack_traces_test.dart
@@ -81,8 +81,15 @@
     print(stacktrace);
     print('-----------------------------');
 
-    Expect.isTrue(e is TypeError);
-    Expect.equals("type 'Null' is not a subtype of type 'bool'", e.toString());
+    if (isStrongMode) {
+      Expect.isTrue(e is TypeError);
+      Expect.equals(
+          "type 'Null' is not a subtype of type 'bool'", e.toString());
+    } else {
+      Expect.isTrue(e is AssertionError);
+      Expect.equals('Failed assertion: boolean expression must not be null',
+          e.toString());
+    }
 
     final String st = stacktrace.toString();
     for (int lineNum in lineNumbers) {
diff --git a/tests/language_2/async/or_generator_return_type_stacktrace_test.dart b/tests/language_2/async/or_generator_return_type_stacktrace_test.dart
index 39fdb56..1de0f9c 100644
--- a/tests/language_2/async/or_generator_return_type_stacktrace_test.dart
+++ b/tests/language_2/async/or_generator_return_type_stacktrace_test.dart
@@ -11,12 +11,12 @@
 // [cfe] Functions marked 'async' must have a return type assignable to 'Future'.
 int badReturnTypeAsyncStar() async* {}
 // [error line 12, column 1, length 3]
-// [analyzer] STATIC_TYPE_WARNING.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE
+// [analyzer] COMPILE_TIME_ERROR.ILLEGAL_ASYNC_GENERATOR_RETURN_TYPE
 //  ^
 // [cfe] Functions marked 'async*' must have a return type assignable to 'Stream'.
 int badReturnTypeSyncStar() sync* {}
 // [error line 17, column 1, length 3]
-// [analyzer] STATIC_TYPE_WARNING.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE
+// [analyzer] COMPILE_TIME_ERROR.ILLEGAL_SYNC_GENERATOR_RETURN_TYPE
 //  ^
 // [cfe] Functions marked 'sync*' must have a return type assignable to 'Iterable'.
 
diff --git a/tests/language_2/async_star/void_async_star_test.dart b/tests/language_2/async_star/void_async_star_test.dart
new file mode 100644
index 0000000..8e3c77d
--- /dev/null
+++ b/tests/language_2/async_star/void_async_star_test.dart
@@ -0,0 +1,38 @@
+// 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.
+
+// It is an error for an `async*` function to have return type `void`.
+
+import 'dart:async';
+
+/*space*/ void f1() async* {
+  //      ^^^^
+  // [analyzer] unspecified
+  // [cfe] unspecified
+}
+
+class C {
+  static void f2() async* {
+    //   ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  /*space*/ void f3() async* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+}
+
+void main() {
+  /*space*/ void f4() async* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  // No function literal: It is probably not possible to infer the
+  // return type `void` for a function literal marked `async*`.
+}
diff --git a/tests/language_2/call/closurization_test.dart b/tests/language_2/call/closurization_test.dart
index 683c229..102413b 100644
--- a/tests/language_2/call/closurization_test.dart
+++ b/tests/language_2/call/closurization_test.dart
@@ -3,6 +3,9 @@
 // BSD-style license that can be found in the LICENSE file.
 // VMOptions=--optimization_counter_threshold=10 --no-background_compilation
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 main() {
diff --git a/tests/language_2/class/variable_shadow_class_test.dart b/tests/language_2/class/variable_shadow_class_test.dart
index 5e24390..3fc29e4 100644
--- a/tests/language_2/class/variable_shadow_class_test.dart
+++ b/tests/language_2/class/variable_shadow_class_test.dart
@@ -15,9 +15,8 @@
     var Test;
     // Now this refers to the variable.
     var i = new Test.named(10);
-    //          ^^^^^^^^^^
-    // [analyzer] STATIC_WARNING.CREATION_WITH_NON_TYPE
     //          ^^^^
+    // [analyzer] COMPILE_TIME_ERROR.PREFIX_SHADOWED_BY_LOCAL_DECLARATION
     // [cfe] Method not found: 'Test.named'.
     Expect.equals(10, i.field);
   }
diff --git a/tests/language_2/const/const_locals_constant_locals_test.dart b/tests/language_2/const/const_locals_constant_locals_test.dart
index 9f937df..472687b 100644
--- a/tests/language_2/const/const_locals_constant_locals_test.dart
+++ b/tests/language_2/const/const_locals_constant_locals_test.dart
@@ -10,8 +10,7 @@
   const c1;
   //    ^^
   // [analyzer] COMPILE_TIME_ERROR.CONST_NOT_INITIALIZED
-  //      ^
-  // [cfe] The const variable ';' must be initialized.
+  // [cfe] The const variable 'c1' must be initialized.
   const c2 = 0;
   const c3 = field;
   //         ^^^^^
diff --git a/tests/language_2/const/syntax_test.dart b/tests/language_2/const/syntax_test.dart
index 3682988..0bb8881 100644
--- a/tests/language_2/const/syntax_test.dart
+++ b/tests/language_2/const/syntax_test.dart
@@ -9,14 +9,12 @@
   const f1;
   //    ^^
   // [analyzer] COMPILE_TIME_ERROR.CONST_NOT_INITIALIZED
-  //      ^
-  // [cfe] The const variable ';' must be initialized.
+  // [cfe] The const variable 'f1' must be initialized.
   const int f2 = 87;
   const int f3;
   //        ^^
   // [analyzer] COMPILE_TIME_ERROR.CONST_NOT_INITIALIZED
-  //          ^
-  // [cfe] The const variable ';' must be initialized.
+  // [cfe] The const variable 'f3' must be initialized.
   Expect.equals(42, f0);
   Expect.equals(87, f2);
 
diff --git a/tests/language_2/deferred/deferred_and_immediate_import_lib.dart b/tests/language_2/deferred/deferred_and_immediate_import_lib.dart
new file mode 100644
index 0000000..61eeb08
--- /dev/null
+++ b/tests/language_2/deferred/deferred_and_immediate_import_lib.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  print("Foo!");
+}
diff --git a/tests/language_2/deferred/deferred_and_immediate_import_test.dart b/tests/language_2/deferred/deferred_and_immediate_import_test.dart
new file mode 100644
index 0000000..d54ca7e
--- /dev/null
+++ b/tests/language_2/deferred/deferred_and_immediate_import_test.dart
@@ -0,0 +1,19 @@
+// 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 "package:expect/expect.dart";
+
+import "deferred_and_immediate_import_lib.dart" as immediatePrefix;
+import "deferred_and_immediate_import_lib.dart" deferred as deferredPrefix;
+
+main() async {
+  immediatePrefix.foo();
+
+  Expect.throws(() {
+    deferredPrefix.foo();
+  });
+
+  await deferredPrefix.loadLibrary();
+  deferredPrefix.foo();
+}
diff --git a/tests/language_2/deferred/unreachable_loading_unit_deferred.dart b/tests/language_2/deferred/unreachable_loading_unit_deferred.dart
new file mode 100644
index 0000000..ca5f8bdc
--- /dev/null
+++ b/tests/language_2/deferred/unreachable_loading_unit_deferred.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  print("Foo");
+}
diff --git a/tests/language_2/deferred/unreachable_loading_unit_immediate.dart b/tests/language_2/deferred/unreachable_loading_unit_immediate.dart
new file mode 100644
index 0000000..a320045
--- /dev/null
+++ b/tests/language_2/deferred/unreachable_loading_unit_immediate.dart
@@ -0,0 +1,10 @@
+// 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 "unreachable_loading_unit_deferred.dart" deferred as lib;
+
+unreachable() async {
+  await lib.loadLibrary();
+  lib.foo();
+}
diff --git a/tests/language_2/deferred/unreachable_loading_unit_test.dart b/tests/language_2/deferred/unreachable_loading_unit_test.dart
new file mode 100644
index 0000000..8a66342
--- /dev/null
+++ b/tests/language_2/deferred/unreachable_loading_unit_test.dart
@@ -0,0 +1,9 @@
+// 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 "unreachable_loading_unit_immediate.dart";
+
+main() {
+  print("Okay");
+}
diff --git a/tests/language_2/generic/function_bounds_test.dart b/tests/language_2/generic/function_bounds_test.dart
index ad7f17d..f361f64 100644
--- a/tests/language_2/generic/function_bounds_test.dart
+++ b/tests/language_2/generic/function_bounds_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import 'dart:math';
 import 'package:expect/expect.dart';
 
diff --git a/tests/language_2/generic/instantiate_tearoff_test.dart b/tests/language_2/generic/instantiate_tearoff_test.dart
index 6a551f6..dc1afd4 100644
--- a/tests/language_2/generic/instantiate_tearoff_test.dart
+++ b/tests/language_2/generic/instantiate_tearoff_test.dart
@@ -2,6 +2,9 @@
 // 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.
 
+// VMOptions=--lazy-dispatchers
+// VMOptions=--no-lazy-dispatchers
+
 import "package:expect/expect.dart";
 
 T f<T>(T x) => x;
diff --git a/tests/language_2/import/name_clash_lib1.dart b/tests/language_2/import/name_clash_lib1.dart
new file mode 100644
index 0000000..8fbfaf3
--- /dev/null
+++ b/tests/language_2/import/name_clash_lib1.dart
@@ -0,0 +1,5 @@
+// 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.
+
+library clashing.nonempty.name;
diff --git a/tests/language_2/import/name_clash_lib2.dart b/tests/language_2/import/name_clash_lib2.dart
new file mode 100644
index 0000000..8fbfaf3
--- /dev/null
+++ b/tests/language_2/import/name_clash_lib2.dart
@@ -0,0 +1,5 @@
+// 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.
+
+library clashing.nonempty.name;
diff --git a/tests/language_2/import/name_clash_test.dart b/tests/language_2/import/name_clash_test.dart
new file mode 100644
index 0000000..72d06a5
--- /dev/null
+++ b/tests/language_2/import/name_clash_test.dart
@@ -0,0 +1,13 @@
+// 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.
+
+// Check that a library name clash is not an error.
+
+import "name_clash_lib1.dart";
+import "name_clash_lib2.dart";
+
+export "name_clash_lib1.dart";
+export "name_clash_lib2.dart";
+
+main() {}
diff --git a/tests/language_2/language_2.status b/tests/language_2/language_2.status
index 72e60ac..c602c82 100644
--- a/tests/language_2/language_2.status
+++ b/tests/language_2/language_2.status
@@ -35,6 +35,9 @@
 stack_trace/demangle_ctors_test: SkipByDesign # Names are not scrubbed.
 type/checks_in_factory_method_test: SkipByDesign # Requires checked mode.
 
+[ $compiler != dart2analyzer && $compiler != fasta ]
+identifier/built_in_type_annotation_test/*: SkipByDesign # Analyzer/CFE only tests.
+
 [ $compiler != dart2js && $compiler != dartdevc && !$checked ]
 function_type/*: Skip # Needs checked mode.
 
diff --git a/tests/language_2/operator/invalid_operators_test.dart b/tests/language_2/operator/invalid_operators_test.dart
index d0ec7e4..a02ad70 100644
--- a/tests/language_2/operator/invalid_operators_test.dart
+++ b/tests/language_2/operator/invalid_operators_test.dart
@@ -9,6 +9,7 @@
   // [cfe] Operator '==' should have exactly one parameter.
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
+  // [cfe] The method 'Operators1.==' has fewer positional arguments than those of overridden method 'Object.=='.
   operator <() => true;
   //       ^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
@@ -86,6 +87,7 @@
   // [cfe] Operator '==' should have exactly one parameter.
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
+  // [cfe] The method 'Operators2.==' has more required arguments than those of overridden method 'Object.=='.
   operator <(a, b) => true;
   //       ^
   // [analyzer] COMPILE_TIME_ERROR.WRONG_NUMBER_OF_PARAMETERS_FOR_OPERATOR
@@ -248,6 +250,7 @@
   operator ==({a}) => true;
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_OVERRIDE
+  // [cfe] The method 'Operators4.==' has fewer positional arguments than those of overridden method 'Object.=='.
   //           ^
   // [analyzer] COMPILE_TIME_ERROR.OPTIONAL_PARAMETER_IN_OPERATOR
   // [cfe] An operator can't have optional parameters.
@@ -568,6 +571,9 @@
   operator ==<T>(a) => true;
   //       ^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_OVERRIDE
+  // [cfe] Declared type variables of 'Operators7.==' doesn't match those on overridden method 'Object.=='.
+  //       ^
+  // [cfe] The return type of the method 'Operators7.==' is 'dynamic', which does not match the return type, 'bool', of the overridden method, 'Object.=='.
   //         ^^^
   // [analyzer] SYNTACTIC_ERROR.TYPE_PARAMETERS_ON_OPERATOR
   //          ^
@@ -664,4 +670,11 @@
   // [cfe] Types parameters aren't allowed when defining an operator.
 }
 
+class Operators8 {
+  /*space*/ int operator []=(a, b) {}
+  //        ^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_OPERATOR
+  // [cfe] unspecified
+}
+
 main() {}
diff --git a/tests/language_2/prefix/shadow_test.dart b/tests/language_2/prefix/shadow_test.dart
index 4a5bdc2..1680b1e 100644
--- a/tests/language_2/prefix/shadow_test.dart
+++ b/tests/language_2/prefix/shadow_test.dart
@@ -11,6 +11,8 @@
 class P<T> {
   test() {
     new T.Library10(10);
+    //  ^
+    // [analyzer] COMPILE_TIME_ERROR.PREFIX_SHADOWED_BY_LOCAL_DECLARATION
     //    ^
     // [cfe] Method not found: 'T.Library10'.
   }
diff --git a/tests/language_2/setter/declaration_test.dart b/tests/language_2/setter/declaration_test.dart
index cc5e6a7..b1ef548 100644
--- a/tests/language_2/setter/declaration_test.dart
+++ b/tests/language_2/setter/declaration_test.dart
@@ -2,7 +2,9 @@
 // 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.
 
-/// Test that a setter has a single argument.
+// Test that a setter has a single argument.
+
+import 'dart:async';
 
 set tooFew() {}
 //  ^^^^^^
@@ -16,7 +18,109 @@
 //         ^
 // [cfe] A setter should have exactly one formal parameter.
 
+/*space*/ int set wrongReturnType1(_) {}
+//        ^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+/*space*/ FutureOr<void> set wrongReturnType2(_) {}
+//        ^^^^^^^^^^^^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+/*space*/ Never set wrongReturnType3(_) {}
+//        ^^^^^
+// [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+// [cfe] unspecified
+
+class C {
+  static int set staticWrongReturnType1(_) => 1;
+  //     ^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static FutureOr<void> set staticWrongReturnType2(_) {}
+  //     ^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static Never set staticWrongReturnType3(_) => throw 1;
+  //     ^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ int set wrongReturnType1(_) {}
+  //        ^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ FutureOr<void> set wrongReturnType2(_) {}
+  //        ^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  /*space*/ Never set wrongReturnType3(_) => throw 1;
+  //        ^^^^^
+  // [analyzer] STATIC_WARNING.NON_VOID_RETURN_FOR_SETTER
+  // [cfe] unspecified
+
+  static int get staticNonAssignableTypes1 => 1;
+  //             ^^^^^^^^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_ASSIGNABLE_SETTER_TYPES
+  // [cfe] unspecified
+  static set staticNonAssignableTypes1(String _) {}
+
+  static num get staticAssignableTypes1 => 1;
+  static set staticAssignableTypes1(int _) {}
+
+  static FutureOr<int> get staticAssignableTypes2 => 1;
+  static set staticAssignableTypes2(int _) {}
+
+  static dynamic get staticAssignableTypes3 => 1;
+  static set staticAssignableTypes3(int _) {}
+
+  int get nonAssignableTypes1 => 1;
+  //      ^^^^^^^^^^^^^^^^^^^
+  // [analyzer] STATIC_WARNING.GETTER_NOT_ASSIGNABLE_SETTER_TYPES
+  // [cfe] unspecified
+  set nonAssignableTypes1(String _) {}
+
+  num get assignableTypes1 => 1;
+  set assignableTypes1(int _) {}
+
+  FutureOr<int> get assignableTypes2 => 1;
+  set assignableTypes2(int _) {}
+
+  dynamic get assignableTypes3 => 1;
+  set assignableTypes3(int _) {}
+}
+
 main() {
   tooFew = 1;
-  tooMany = 2;
+  tooMany = 1;
+  wrongReturnType1 = 1;
+  wrongReturnType2 = 1;
+  wrongReturnType3 = 1;
+  C.staticWrongReturnType1 = 4;
+  C.staticWrongReturnType2 = 4;
+  C.staticWrongReturnType3 = 4;
+  C().wrongReturnType1 = 5;
+  C().wrongReturnType2 = 5;
+  C().wrongReturnType3 = 5;
+  var x1 = C.staticNonAssignableTypes1;
+  C.staticNonAssignableTypes1 = '' as dynamic;
+  var y1 = C.staticAssignableTypes1;
+  C.staticAssignableTypes1 = '' as dynamic;
+  var y2 = C.staticAssignableTypes2;
+  C.staticAssignableTypes2 = '' as dynamic;
+  var y3 = C.staticAssignableTypes3;
+  C.staticAssignableTypes3 = '' as dynamic;
+  var z1 = C().nonAssignableTypes1;
+  C().nonAssignableTypes1 = '' as dynamic;
+  var w1 = C().assignableTypes1;
+  C().assignableTypes1 = '' as dynamic;
+  var w2 = C().assignableTypes2;
+  C().assignableTypes2 = '' as dynamic;
+  var w3 = C().assignableTypes3;
+  C().assignableTypes3 = '' as dynamic;
 }
diff --git a/tests/language_2/sync_star/void_sync_star_test.dart b/tests/language_2/sync_star/void_sync_star_test.dart
new file mode 100644
index 0000000..4c387f3
--- /dev/null
+++ b/tests/language_2/sync_star/void_sync_star_test.dart
@@ -0,0 +1,36 @@
+// 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.
+
+// It is an error for a `sync*` function to have return type `void`.
+
+/*space*/ void f1() sync* {
+  //      ^^^^
+  // [analyzer] unspecified
+  // [cfe] unspecified
+}
+
+class C {
+  static void f2() sync* {
+    //   ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  /*space*/ void f3() sync* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+}
+
+void main() {
+  /*space*/ void f4() sync* {
+    //      ^^^^
+    // [analyzer] unspecified
+    // [cfe] unspecified
+  }
+
+  // No function literal: It is probably not possible to infer the
+  // return type `void` for a function literal marked `sync*`.
+}
diff --git a/tests/lib/html/cache_test.dart b/tests/lib/html/cache_test.dart
index 2e0991b..3fde2d2 100644
--- a/tests/lib/html/cache_test.dart
+++ b/tests/lib/html/cache_test.dart
@@ -17,8 +17,8 @@
     test('ApplicationCache', () {
       var expectation = ApplicationCache.supported ? returnsNormally : throws;
       expect(() {
-        ApplicationCache appCache = window.applicationCache;
-        expect(cacheStatusToString(appCache.status), "UNCACHED");
+        ApplicationCache appCache = window.applicationCache!;
+        expect(cacheStatusToString(appCache.status!), "UNCACHED");
       }, expectation);
     });
   });
diff --git a/tests/lib/html/callback_list_test.dart b/tests/lib/html/callback_list_test.dart
index d6390b1..f61dee8 100644
--- a/tests/lib/html/callback_list_test.dart
+++ b/tests/lib/html/callback_list_test.dart
@@ -27,7 +27,7 @@
 }
 
 void main() async {
-  window.navigator.persistentStorage.requestQuota(1024 * 1024, _quotaHandler);
+  window.navigator.persistentStorage!.requestQuota(1024 * 1024, _quotaHandler);
 
   await waitUntilCallbackDone(isCallbackDone);
   expect(true, isCallbackDone());
@@ -36,7 +36,7 @@
 Future _quotaHandler(int byteCount) async {
   FileSystem filesystem =
       await window.requestFileSystem(1024 * 1024, persistent: true);
-  DirectoryEntry dir = await filesystem.root;
+  DirectoryEntry dir = await filesystem.root!;
   DirectoryReader dirReader = dir.createReader();
   await dirReader.readEntries();
   List<Entry> secondEntries = await dirReader.readEntries();
diff --git a/tests/lib/html/crypto_test.dart b/tests/lib/html/crypto_test.dart
index 9cb63ab..b398f2d 100644
--- a/tests/lib/html/crypto_test.dart
+++ b/tests/lib/html/crypto_test.dart
@@ -24,7 +24,7 @@
       });
 
       test('successful call', () {
-        var crypto = window.crypto;
+        var crypto = window.crypto!;
         var data = new Uint8List(100);
         expect(data.every((e) => e == 0), isTrue);
         crypto.getRandomValues(data);
@@ -35,7 +35,7 @@
       });
 
       test('type mismatch', () {
-        var crypto = window.crypto;
+        var crypto = window.crypto!;
         var data = new Float32List(100);
         expect(() {
           crypto.getRandomValues(data);
diff --git a/tests/lib/html/css_rule_list_test.dart b/tests/lib/html/css_rule_list_test.dart
index 596e2d8..f994bc4 100644
--- a/tests/lib/html/css_rule_list_test.dart
+++ b/tests/lib/html/css_rule_list_test.dart
@@ -11,7 +11,7 @@
       predicate((x) => x is List<CssRule>, 'is a List<CssRule>');
 
   test("ClientRectList test", () {
-    var sheet = document.styleSheets[0] as CssStyleSheet;
+    var sheet = document.styleSheets![0] as CssStyleSheet;
     List<CssRule> rulesList = sheet.cssRules;
     expect(rulesList, isCssRuleList);
   });
diff --git a/tests/lib/html/cssstyledeclaration_test.dart b/tests/lib/html/cssstyledeclaration_test.dart
index aa8a5d4..d18ff33 100644
--- a/tests/lib/html/cssstyledeclaration_test.dart
+++ b/tests/lib/html/cssstyledeclaration_test.dart
@@ -23,7 +23,7 @@
 
   test('default constructor is empty', () {
     var style = new CssStyleDeclaration();
-    expect(style.cssText.isEmpty, isTrue);
+    expect(style.cssText!.isEmpty, isTrue);
     expect(style.getPropertyPriority('color').isEmpty, isTrue);
     expect(style.item(0).isEmpty, isTrue);
     expect(style.length, 0);
@@ -46,7 +46,7 @@
   test('removeProperty is wrapped', () {
     var style = createTestStyle();
     style.removeProperty("width");
-    expect(style.cssText.trim(), equals("color: blue;"));
+    expect(style.cssText!.trim(), equals("color: blue;"));
   });
 
   test('CSS property empty getters and setters', () {
diff --git a/tests/lib/html/custom/entered_left_view/entered_left_view_util.dart b/tests/lib/html/custom/entered_left_view/entered_left_view_util.dart
index d5f6e7d..d34222d 100644
--- a/tests/lib/html/custom/entered_left_view/entered_left_view_util.dart
+++ b/tests/lib/html/custom/entered_left_view/entered_left_view_util.dart
@@ -62,7 +62,7 @@
 }
 
 var docA = document;
-var docB = document.implementation.createHtmlDocument('');
+var docB = document.implementation!.createHtmlDocument('');
 var nullSanitizer = new NullTreeSanitizer();
 
 setupFunc() {
diff --git a/tests/lib/html/datalistelement_test.dart b/tests/lib/html/datalistelement_test.dart
index 2a9396d..767d97a 100644
--- a/tests/lib/html/datalistelement_test.dart
+++ b/tests/lib/html/datalistelement_test.dart
@@ -53,7 +53,7 @@
   test('options', () {
     try {
       var options =
-          (document.querySelector('#browsers') as DataListElement).options;
+          (document.querySelector('#browsers') as DataListElement).options!;
       expect(options.length, 5);
     } catch (e) {
       expect(DataListElement.supported, false);
diff --git a/tests/lib/html/document_test.dart b/tests/lib/html/document_test.dart
index 334f67e..f9e480b 100644
--- a/tests/lib/html/document_test.dart
+++ b/tests/lib/html/document_test.dart
@@ -48,7 +48,7 @@
 
     test('adoptNode', () {
       var div = new Element.html('<div><div id="foo">bar</div></div>');
-      var doc = document.implementation.createHtmlDocument('');
+      var doc = document.implementation!.createHtmlDocument('');
       expect(doc.adoptNode(div), div);
       expect(div.ownerDocument, doc);
       doc.body!.nodes.add(div);
@@ -57,7 +57,7 @@
 
     test('importNode', () {
       var div = new Element.html('<div><div id="foo">bar</div></div>');
-      var doc = document.implementation.createHtmlDocument('');
+      var doc = document.implementation!.createHtmlDocument('');
       var div2 = doc.importNode(div, true);
       expect(div2, notEquals(div));
       expect(div2.ownerDocument, doc);
@@ -70,7 +70,7 @@
       var doc1 = document;
       expect(doc1 is HtmlDocument, true);
       expect(inscrutable(doc1) is HtmlDocument, true);
-      var doc2 = document.implementation.createHtmlDocument('');
+      var doc2 = document.implementation!.createHtmlDocument('');
       expect(doc2 is HtmlDocument, true);
       expect(inscrutable(doc2) is HtmlDocument, true);
     });
@@ -78,7 +78,7 @@
     test('typeTest2', () {
       inscrutable = inscrutable(inscrutable);
       // XML document.
-      var doc3 = document.implementation.createDocument(null, 'report', null);
+      var doc3 = document.implementation!.createDocument(null, 'report', null);
       expect(doc3 is HtmlDocument, false);
       expect(inscrutable(doc3) is HtmlDocument, false);
     });
diff --git a/tests/lib/html/element_classes_svg_test.dart b/tests/lib/html/element_classes_svg_test.dart
index cc05a21..12520b7 100644
--- a/tests/lib/html/element_classes_svg_test.dart
+++ b/tests/lib/html/element_classes_svg_test.dart
@@ -89,7 +89,7 @@
 
 main() {
   Set<String> extractClasses(Element el) {
-    final match = new RegExp('class="([^"]+)"').firstMatch(el.outerHtml)!;
+    final match = new RegExp('class="([^"]+)"').firstMatch(el.outerHtml!)!;
     return new LinkedHashSet.from(match[1]!.split(' '));
   }
 
diff --git a/tests/lib/html/element_classes_test.dart b/tests/lib/html/element_classes_test.dart
index 0345692..322efb7 100644
--- a/tests/lib/html/element_classes_test.dart
+++ b/tests/lib/html/element_classes_test.dart
@@ -46,7 +46,7 @@
 
 main() {
   Set<String> extractClasses(Element el) {
-    final match = new RegExp('class="([^"]+)"').firstMatch(el.outerHtml)!;
+    final match = new RegExp('class="([^"]+)"').firstMatch(el.outerHtml!)!;
     return new LinkedHashSet.from(match[1]!.split(' '));
   }
 
diff --git a/tests/lib/html/element_constructor_1_test.dart b/tests/lib/html/element_constructor_1_test.dart
index bd265b4..b5a7cfc 100644
--- a/tests/lib/html/element_constructor_1_test.dart
+++ b/tests/lib/html/element_constructor_1_test.dart
@@ -31,7 +31,7 @@
   test('anchor2', () {
     var e = new AnchorElement(href: '#blah');
     expect(e, isAnchorElement);
-    expect(e.href.endsWith('#blah'), isTrue);
+    expect(e.href!.endsWith('#blah'), isTrue);
   });
 
   test('area', () {
diff --git a/tests/lib/html/file_sample_test.dart b/tests/lib/html/file_sample_test.dart
index 15d36f4..59f6930 100644
--- a/tests/lib/html/file_sample_test.dart
+++ b/tests/lib/html/file_sample_test.dart
@@ -59,7 +59,7 @@
   var fs = await fileSystem;
 
   _myDirectory =
-      await fs.root.createDirectory('my_directory') as DirectoryEntry;
+      await fs.root!.createDirectory('my_directory') as DirectoryEntry;
 
   FileEntry fileEntry = await _myDirectory.createFile('log.txt') as FileEntry;
 
@@ -122,7 +122,7 @@
   FileEntry fileEntry = await createFile();
   expect(fileEntry.name, 'log.txt');
 
-  List<Entry> entries = await readEntries(fs.root);
+  List<Entry> entries = await readEntries(fs.root!);
   expect(entries.length > 0, true);
   expect(entries[0].isDirectory, true);
   expect(entries[0].name, 'my_directory');
diff --git a/tests/lib/html/fileapi_directory_reader_test.dart b/tests/lib/html/fileapi_directory_reader_test.dart
index 7468759..12a7244 100644
--- a/tests/lib/html/fileapi_directory_reader_test.dart
+++ b/tests/lib/html/fileapi_directory_reader_test.dart
@@ -28,8 +28,8 @@
   Future doDirSetup(String testName) async {
     await getFileSystem();
 
-    var file = await fs.root.createFile('file_$testName') as FileEntry;
-    var dir = await fs.root.createDirectory('dir_$testName') as DirectoryEntry;
+    var file = await fs.root!.createFile('file_$testName') as FileEntry;
+    var dir = await fs.root!.createDirectory('dir_$testName') as DirectoryEntry;
     return new Future.value(new FileAndDir(file, dir));
   }
 
diff --git a/tests/lib/html/fileapi_directory_test.dart b/tests/lib/html/fileapi_directory_test.dart
index 9b4ee72..da24c78 100644
--- a/tests/lib/html/fileapi_directory_test.dart
+++ b/tests/lib/html/fileapi_directory_test.dart
@@ -28,14 +28,14 @@
 
     test('directoryDoesntExist', () async {
       try {
-        await fs.root.getDirectory('directory2');
+        await fs.root!.getDirectory('directory2');
       } on DomException catch (error) {
         expect(DomException.NOT_FOUND, error.name);
       }
     });
 
     test('directoryCreate', () async {
-      var entry = await fs.root.createDirectory('directory3');
+      var entry = await fs.root!.createDirectory('directory3');
       expect(entry.name, equals('directory3'));
     });
   }
diff --git a/tests/lib/html/fileapi_entry_test.dart b/tests/lib/html/fileapi_entry_test.dart
index fd0e303..ae700a1 100644
--- a/tests/lib/html/fileapi_entry_test.dart
+++ b/tests/lib/html/fileapi_entry_test.dart
@@ -30,8 +30,8 @@
   Future doDirSetup(String testName) async {
     await getFileSystem();
 
-    var file = await fs.root.createFile('file_$testName') as FileEntry;
-    var dir = await fs.root.createDirectory('dir_$testName') as DirectoryEntry;
+    var file = await fs.root!.createFile('file_$testName') as FileEntry;
+    var dir = await fs.root!.createDirectory('dir_$testName') as DirectoryEntry;
     return new Future.value(new FileAndDir(file, dir));
   }
 
@@ -56,7 +56,7 @@
       expect(entry.fullPath, '/dir_moveTo/movedFile');
 
       try {
-        entry = await fs.root.getFile('file4');
+        entry = await fs.root!.getFile('file4');
         fail("File file4 should not exist.");
       } on DomException catch (error) {
         expect(DomException.NOT_FOUND, error.name);
diff --git a/tests/lib/html/fileapi_file_entry_test.dart b/tests/lib/html/fileapi_file_entry_test.dart
index 1789003..d8bf7b6 100644
--- a/tests/lib/html/fileapi_file_entry_test.dart
+++ b/tests/lib/html/fileapi_file_entry_test.dart
@@ -28,8 +28,8 @@
   Future doDirSetup(String testName) async {
     await getFileSystem();
 
-    var file = await fs.root.createFile('file_$testName') as FileEntry;
-    var dir = await fs.root.createDirectory('dir_$testName') as DirectoryEntry;
+    var file = await fs.root!.createFile('file_$testName') as FileEntry;
+    var dir = await fs.root!.createDirectory('dir_$testName') as DirectoryEntry;
     return new Future.value(new FileAndDir(file, dir));
   }
 
diff --git a/tests/lib/html/fileapi_file_test.dart b/tests/lib/html/fileapi_file_test.dart
index 8eb644b..1503213 100644
--- a/tests/lib/html/fileapi_file_test.dart
+++ b/tests/lib/html/fileapi_file_test.dart
@@ -28,7 +28,7 @@
 
     test('fileDoesntExist', () async {
       try {
-        var fileObj = await fs.root.getFile('file2');
+        var fileObj = await fs.root!.getFile('file2');
         fail("file found");
       } on DomException catch (error) {
         expect(DomException.NOT_FOUND, error.name);
@@ -36,7 +36,7 @@
     });
 
     test('fileCreate', () async {
-      var fileObj = await fs.root.createFile('file4');
+      var fileObj = await fs.root!.createFile('file4');
       expect(fileObj.name, equals('file4'));
       expect(fileObj.isFile, isTrue);
 
diff --git a/tests/lib/html/fontface_loaded_test.dart b/tests/lib/html/fontface_loaded_test.dart
index ef07061..5a889f4 100644
--- a/tests/lib/html/fontface_loaded_test.dart
+++ b/tests/lib/html/fontface_loaded_test.dart
@@ -34,7 +34,7 @@
   test('document fonts - temporary', () async {
     var atLeastOneFont = false;
     var loaded = <Future<FontFace>>[];
-    document.fonts.forEach((FontFace fontFace, _, __) async {
+    document.fonts!.forEach((FontFace fontFace, _, __) async {
       atLeastOneFont = true;
       var f1 = fontFace.loaded;
       var f2 = fontFace.loaded;
@@ -44,14 +44,14 @@
     });
     expect(atLeastOneFont, isTrue);
     return Future.wait(loaded).then(expectAsync((_) async {
-      document.fonts.forEach((fontFace, _, __) {
+      document.fonts!.forEach((fontFace, _, __) {
         expect(fontFace.status, 'loaded');
       });
       expect(loaded.length, 3);
       for (var loadedEntry in loaded) {
         var fontFace = await loadedEntry;
         expect(fontFace.status, 'loaded');
-        var fontFamily = fontFace.family;
+        var fontFamily = fontFace.family!;
         if (fontFamily.startsWith('"')) {
           // FF wraps family in quotes - remove the quotes.
           fontFamily = fontFamily.substring(1, fontFamily.length - 1);
diff --git a/tests/lib/html/form_data_test.dart b/tests/lib/html/form_data_test.dart
index 03592e2..b142676 100644
--- a/tests/lib/html/form_data_test.dart
+++ b/tests/lib/html/form_data_test.dart
@@ -68,7 +68,7 @@
             '${window.location.protocol}//${window.location.host}/echo');
 
         xhr.onLoad.listen(expectAsync((e) {
-          expect(xhr.responseText.contains(blobString), isTrue);
+          expect(xhr.responseText!.contains(blobString), isTrue);
         }));
         xhr.onError.listen((e) {
           fail('$e');
diff --git a/tests/lib/html/html_mock_test.dart b/tests/lib/html/html_mock_test.dart
index 94c016d..ed3e85b 100644
--- a/tests/lib/html/html_mock_test.dart
+++ b/tests/lib/html/html_mock_test.dart
@@ -35,7 +35,7 @@
 class MockWindow extends Mock with _EventListeners implements Window {
   Stream<Event> get onBeforeUnload => new Stream.fromIterable([]);
 
-  String name = "MOCK_NAME";
+  String? name = "MOCK_NAME";
 }
 
 @proxy
diff --git a/tests/lib/html/htmlcollection_test.dart b/tests/lib/html/htmlcollection_test.dart
index e0d60e3..fe81626 100644
--- a/tests/lib/html/htmlcollection_test.dart
+++ b/tests/lib/html/htmlcollection_test.dart
@@ -6,8 +6,8 @@
 
 import 'package:expect/minitest.dart';
 
-bool isChecked(Element e) => (e as CheckboxInputElement).checked;
-bool isUnchecked(Element e) => !(e as CheckboxInputElement).checked;
+bool isChecked(Element e) => (e as CheckboxInputElement).checked!;
+bool isUnchecked(Element e) => !(e as CheckboxInputElement).checked!;
 
 // Test that List<Element> implements List<T>
 main() {
diff --git a/tests/lib/html/interactive_geolocation_test.dart b/tests/lib/html/interactive_geolocation_test.dart
index 1ad3a13..133079c 100644
--- a/tests/lib/html/interactive_geolocation_test.dart
+++ b/tests/lib/html/interactive_geolocation_test.dart
@@ -12,16 +12,18 @@
 
 Future testGetCurrentPosition() async {
   var position = await window.navigator.geolocation.getCurrentPosition();
-  Expect.isNotNull(position.coords.latitude);
-  Expect.isNotNull(position.coords.longitude);
-  Expect.isNotNull(position.coords.accuracy);
+  var coords = position.coords!;
+  Expect.isNotNull(coords.latitude);
+  Expect.isNotNull(coords.longitude);
+  Expect.isNotNull(coords.accuracy);
 }
 
 Future testWatchPosition() async {
   var position = await window.navigator.geolocation.watchPosition().first;
-  Expect.isNotNull(position.coords.latitude);
-  Expect.isNotNull(position.coords.longitude);
-  Expect.isNotNull(position.coords.accuracy);
+  var coords = position.coords!;
+  Expect.isNotNull(coords.latitude);
+  Expect.isNotNull(coords.longitude);
+  Expect.isNotNull(coords.accuracy);
 }
 
 main() {
diff --git a/tests/lib/html/interactive_media_test.dart b/tests/lib/html/interactive_media_test.dart
index 5a816aea..997d376 100644
--- a/tests/lib/html/interactive_media_test.dart
+++ b/tests/lib/html/interactive_media_test.dart
@@ -17,7 +17,7 @@
     var mediaStream = await userMediaFuture;
     expect(mediaStream, isNotNull);
     expect(mediaStream is MediaStream, true);
-    var devices = window.navigator.mediaDevices;
+    var devices = window.navigator.mediaDevices!;
     var enumDevices = await devices.enumerateDevices();
     expect(enumDevices.length > 1, true);
     for (var device in enumDevices) {
@@ -65,14 +65,14 @@
       await testUserMediaAudio(window.navigator
           .getUserMedia(audio: true)); // Deprecated way to get a media stream.
       await testUserMediaAudio(
-          window.navigator.mediaDevices.getUserMedia({'audio': true}));
+          window.navigator.mediaDevices!.getUserMedia({'audio': true}));
     });
 
     test('getUserMedia', () async {
       await testUserMediaVideo(window.navigator
           .getUserMedia(video: true)); // Deprecated way to get a media stream.
       await testUserMediaVideo(
-          window.navigator.mediaDevices.getUserMedia({'video': true}));
+          window.navigator.mediaDevices!.getUserMedia({'video': true}));
     });
 
     test('getUserMediaComplexConstructor', () async {
@@ -86,7 +86,7 @@
       await testUserMediaVideo(window.navigator.getUserMedia(
           video: videoOptions)); // Deprecated way to get a media stream.
       await testUserMediaVideo(
-          window.navigator.mediaDevices.getUserMedia({'video': videoOptions}));
+          window.navigator.mediaDevices!.getUserMedia({'video': videoOptions}));
     });
   }
 }
diff --git a/tests/lib/html/mediadevices_test.dart b/tests/lib/html/mediadevices_test.dart
index abc803a..2b4331c 100644
--- a/tests/lib/html/mediadevices_test.dart
+++ b/tests/lib/html/mediadevices_test.dart
@@ -9,7 +9,7 @@
 import 'package:expect/expect.dart';
 
 test() async {
-  var list = await window.navigator.mediaDevices.enumerateDevices();
+  var list = await window.navigator.mediaDevices!.enumerateDevices();
   Expect.isTrue(list is List<dynamic>, "Expected list to be List<dynamic>");
 }
 
diff --git a/tests/lib/html/mutationobserver_test.dart b/tests/lib/html/mutationobserver_test.dart
index 7ee71fe..a41709b 100644
--- a/tests/lib/html/mutationobserver_test.dart
+++ b/tests/lib/html/mutationobserver_test.dart
@@ -24,7 +24,8 @@
 
   callback(mutations, observer) {
     for (MutationRecord mutation in mutations) {
-      for (Node node in mutation.addedNodes) {
+      var addedNodes = mutation.addedNodes!;
+      for (Node node in addedNodes) {
         nodes.add(node);
       }
     }
diff --git a/tests/lib/html/node_validator_important_if_you_suppress_make_the_bug_critical_test.dart b/tests/lib/html/node_validator_important_if_you_suppress_make_the_bug_critical_test.dart
index 0faaf09..5a3d0f2 100644
--- a/tests/lib/html/node_validator_important_if_you_suppress_make_the_bug_critical_test.dart
+++ b/tests/lib/html/node_validator_important_if_you_suppress_make_the_bug_critical_test.dart
@@ -117,7 +117,7 @@
       var expectedContent = document.body!.createFragment('<div></div>'
           '<img/>');
 
-      validateNodeTree(template.content, expectedContent);
+      validateNodeTree(template.content!, expectedContent);
     });
 
     test("appendHtml is sanitized", () {
diff --git a/tests/lib/html/notification_test.dart b/tests/lib/html/notification_test.dart
index 283dc5b..31bc58d 100644
--- a/tests/lib/html/notification_test.dart
+++ b/tests/lib/html/notification_test.dart
@@ -34,7 +34,7 @@
         expect(allSpecified.title, "Deluxe notification");
         expect(allSpecified.dir, "rtl");
         expect(allSpecified.body, "All parameters set");
-        var icon = allSpecified.icon;
+        var icon = allSpecified.icon!;
         var tail = Uri.parse(icon).pathSegments.last;
         expect(tail, "icon.png");
         expect(allSpecified.tag, "tag");
diff --git a/tests/lib/html/storage_promise_test.dart b/tests/lib/html/storage_promise_test.dart
index 4c8e54d..0910e0c 100644
--- a/tests/lib/html/storage_promise_test.dart
+++ b/tests/lib/html/storage_promise_test.dart
@@ -18,7 +18,7 @@
   test('Basic Promise Test', () async {
     try {
       thenEstimateBefore = true;
-      window.navigator.storage.estimate().then((value) {
+      window.navigator.storage!.estimate().then((value) {
         thenEstimate = value!;
         thenEstimateDone = true;
       });
@@ -27,7 +27,7 @@
       fail("StorageManger failed: $msg");
     }
 
-    Map estimate = await window.navigator.storage.estimate() as Map;
+    Map estimate = await window.navigator.storage!.estimate() as Map;
 
     expect(thenEstimate['usage'] >= 0, true);
     expect(thenEstimate['quota'] > 1, true);
diff --git a/tests/lib/html/streams_test.dart b/tests/lib/html/streams_test.dart
index 2d5c210..5f8bd88 100644
--- a/tests/lib/html/streams_test.dart
+++ b/tests/lib/html/streams_test.dart
@@ -15,7 +15,7 @@
   }
 
   Element get element => _a;
-  Stream<Event?> get stream => _a.onFocus;
+  Stream<Event> get stream => _a.onFocus;
 
   // Causes an event on a to be fired.
   void pulse() {
@@ -193,7 +193,7 @@
   });
 
   test('reduce', () {
-    stream.reduce((a, b) => null).then((_) {});
+    stream.reduce((a, b) => a).then((_) {});
   });
 
   test('fold', () {
diff --git a/tests/lib/html/svg_test.dart b/tests/lib/html/svg_test.dart
index 1e9a282..fecb2ee 100644
--- a/tests/lib/html/svg_test.dart
+++ b/tests/lib/html/svg_test.dart
@@ -24,11 +24,11 @@
       expect(e, isNotNull);
 
       svg.RectElement r = document.querySelector('#rect1') as svg.RectElement;
-      expect(r.x.baseVal.value, 10);
-      expect(r.y.baseVal.value, 20);
-      expect(r.height.baseVal.value, 40);
-      expect(r.width.baseVal.value, 130);
-      expect(r.rx.baseVal.value, 5);
+      expect(r.x!.baseVal!.value, 10);
+      expect(r.y!.baseVal!.value, 20);
+      expect(r.height!.baseVal!.value, 40);
+      expect(r.width!.baseVal!.value, 130);
+      expect(r.rx!.baseVal!.value, 5);
     });
 
     test('trailing newline', () {
diff --git a/tests/lib/html/track_element_constructor_test.dart b/tests/lib/html/track_element_constructor_test.dart
index 9fa006b..e2643b6 100644
--- a/tests/lib/html/track_element_constructor_test.dart
+++ b/tests/lib/html/track_element_constructor_test.dart
@@ -18,11 +18,11 @@
     if (!TrackElement.supported) return;
     document.body!.append(new TrackElement()..defaultValue = true);
     var trackElement = document.querySelector('track') as TrackElement;
-    if (!trackElement.defaultValue) {
+    if (!trackElement.defaultValue!) {
       throw 'Expected default value to be true';
     }
     trackElement.defaultValue = false;
-    if (trackElement.defaultValue) {
+    if (trackElement.defaultValue!) {
       throw 'Expected default value to be false';
     }
   });
diff --git a/tests/lib/html/trusted_html_tree_sanitizer_test.dart b/tests/lib/html/trusted_html_tree_sanitizer_test.dart
index a0d92ed..80c7738 100644
--- a/tests/lib/html/trusted_html_tree_sanitizer_test.dart
+++ b/tests/lib/html/trusted_html_tree_sanitizer_test.dart
@@ -43,7 +43,7 @@
     });
 
     test("appendHtml", () {
-      var oldStuff = document.body!.innerHtml;
+      var oldStuff = document.body!.innerHtml!;
       var newStuff = '<div rumplestiltskin="value">content</div>';
       document.body!
           .appendHtml(newStuff, treeSanitizer: NodeTreeSanitizer.trusted);
diff --git a/tests/lib/html/typing_test.dart b/tests/lib/html/typing_test.dart
index 9fa3628..6a93e4e 100644
--- a/tests/lib/html/typing_test.dart
+++ b/tests/lib/html/typing_test.dart
@@ -27,11 +27,11 @@
 
   test('StyleSheetList', () {
     var document = window.document as HtmlDocument;
-    List<StyleSheet> asList = document.styleSheets;
+    List<StyleSheet> asList = document.styleSheets!;
     expect(asList, isStyleSheetList);
     // Check it's Iterable.
     int counter = 0;
-    for (StyleSheet styleSheet in document.styleSheets) {
+    for (StyleSheet styleSheet in asList) {
       counter++;
     }
 
diff --git a/tests/lib/html/websql_test.dart b/tests/lib/html/websql_test.dart
index 7d88a91..3445764 100644
--- a/tests/lib/html/websql_test.dart
+++ b/tests/lib/html/websql_test.dart
@@ -105,8 +105,8 @@
       expect(tx, isNotNull, reason: "Transaction not ready");
       try {
         SqlResultSet queryResult = await queryTable(tx, tableName);
-        expect(queryResult.rows.length, 1);
-        expect(queryResult.rows[0]['test_data'], "Some text data");
+        expect(queryResult.rows!.length, 1);
+        expect(queryResult.rows![0]['test_data'], "Some text data");
       } on DomException catch (error) {
         expect(false, true, reason: "queryTable failed - ${error.message}");
       }
diff --git a/tests/lib/html/wheelevent_test.dart b/tests/lib/html/wheelevent_test.dart
index 2614ae0..0491868 100644
--- a/tests/lib/html/wheelevent_test.dart
+++ b/tests/lib/html/wheelevent_test.dart
@@ -44,7 +44,7 @@
       expect(e.deltaX, 0);
       expect(e.deltaY, 0);
       expect(e.screen.x, 0);
-      expect(e.deltaZ.toDouble(), 1.0);
+      expect(e.deltaZ!.toDouble(), 1.0);
       done.complete();
     } catch (e) {
       done.completeError(e);
diff --git a/tests/lib/html/xhr_cross_origin_test.dart b/tests/lib/html/xhr_cross_origin_test.dart
index 7bc0a20..dc0e34d 100644
--- a/tests/lib/html/xhr_cross_origin_test.dart
+++ b/tests/lib/html/xhr_cross_origin_test.dart
@@ -17,7 +17,7 @@
 // TODO(efortuna): If we need to use this function frequently, make a
 // url_analyzer library that is part of test.dart that these tests can import.
 int get crossOriginPort {
-  var searchUrl = window.location.search;
+  var searchUrl = window.location.search!;
   var crossOriginStr = 'crossOriginPort=';
   var index = searchUrl.indexOf(crossOriginStr);
   var nextArg = searchUrl.indexOf('&', index);
diff --git a/tests/lib/isolate/scenarios/package_relative_root/.dart_tool/package_config.json b/tests/lib/isolate/scenarios/package_relative_root/.dart_tool/package_config.json
index 00b936c..6d510b8 100644
--- a/tests/lib/isolate/scenarios/package_relative_root/.dart_tool/package_config.json
+++ b/tests/lib/isolate/scenarios/package_relative_root/.dart_tool/package_config.json
@@ -4,12 +4,12 @@
     {
       "name": "foo",
       "rootUri": "../packages/foo",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "bar",
       "rootUri": "../packages/bar",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     }
   ]
 }
diff --git a/tests/lib/isolate/scenarios/package_relative_spec/.dart_tool/package_config.json b/tests/lib/isolate/scenarios/package_relative_spec/.dart_tool/package_config.json
index 581db8e..740a2dd 100644
--- a/tests/lib/isolate/scenarios/package_relative_spec/.dart_tool/package_config.json
+++ b/tests/lib/isolate/scenarios/package_relative_spec/.dart_tool/package_config.json
@@ -4,12 +4,12 @@
     {
       "name": "foo",
       "rootUri": "../foo_package",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "bar",
       "rootUri": "../bar1_package",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     }
   ]
 }
diff --git a/tests/lib/isolate/scenarios/package_relative_spec/bar1_package/package.config b/tests/lib/isolate/scenarios/package_relative_spec/bar1_package/package.config
index daf3199..e4dc783 100644
--- a/tests/lib/isolate/scenarios/package_relative_spec/bar1_package/package.config
+++ b/tests/lib/isolate/scenarios/package_relative_spec/bar1_package/package.config
@@ -4,12 +4,12 @@
     {
       "name": "foo",
       "rootUri": "../foo_package",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     },
     {
       "name": "bar",
       "rootUri": "../bar2_package",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     }
   ]
 }
diff --git a/tests/lib/isolate/scenarios/short_package/.dart_tool/package_config.json b/tests/lib/isolate/scenarios/short_package/.dart_tool/package_config.json
index f77884c..c043659 100644
--- a/tests/lib/isolate/scenarios/short_package/.dart_tool/package_config.json
+++ b/tests/lib/isolate/scenarios/short_package/.dart_tool/package_config.json
@@ -4,7 +4,7 @@
     {
       "name": "flu",
       "rootUri": "../flu_package",
-      "languageVersion": "2.9"
+      "languageVersion": "2.10"
     }
   ]
 }
diff --git a/tests/lib/js/constructor_parameters_static_test.dart b/tests/lib/js/constructor_parameters_static_test.dart
new file mode 100644
index 0000000..597ce1e
--- /dev/null
+++ b/tests/lib/js/constructor_parameters_static_test.dart
@@ -0,0 +1,47 @@
+// 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.
+
+// TODO(srujzs): Fix this test once web static error testing is supported.
+
+// Checks for static errors related to parameters for constructors and
+// factories.
+
+@JS()
+library js_constructor_parameters_static_test;
+
+import 'package:js/js.dart';
+import 'package:expect/expect.dart';
+
+@JS()
+class Foo {
+  external Foo({int? a});
+  //                 ^
+  // [web] TODO(srujzs): Add error once supported.
+  external factory Foo.fooFactory({int? a});
+  //                                ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+@JS()
+@anonymous
+class Bar {
+  external Bar({int? a});
+  //                 ^
+  // [web] TODO(srujzs): Add error once supported.
+
+  // Named parameters are okay only for factories of an anonymous class.
+  external factory Bar.barFactory({int? a});
+}
+
+@JS()
+abstract class Baz {
+  external Baz({int? a});
+  //                 ^
+  // [web] TODO(srujzs): Add error once supported.
+  external factory Baz.bazFactory({int? a});
+  //                                ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+main() {}
diff --git a/tests/lib/js/is_check_and_as_cast_test.dart b/tests/lib/js/is_check_and_as_cast_test.dart
new file mode 100644
index 0000000..ef48137
--- /dev/null
+++ b/tests/lib/js/is_check_and_as_cast_test.dart
@@ -0,0 +1,122 @@
+// 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.
+
+// Tests `is` checks and `as` casts between various JS objects. Currently, all
+// checks and casts should be allowed between JS objects.
+
+@JS()
+library is_check_and_as_cast_test;
+
+import 'package:js/js.dart';
+import 'package:expect/minitest.dart';
+
+@JS()
+external void eval(String code);
+
+@JS()
+class Foo {
+  external Foo(int a);
+  external int get a;
+}
+
+// Class with same structure as Foo but separate JS class.
+@JS()
+class Bar {
+  external Bar(int a);
+  external int get a;
+}
+
+@JS('Bar')
+class BarCopy {
+  external BarCopy(int a);
+  external int get a;
+}
+
+@JS()
+class Baz {
+  external Baz(int a, int b);
+  external int get a;
+  external int get b;
+}
+
+// JS object literals
+@JS()
+@anonymous
+class LiteralA {
+  external int get x;
+}
+
+@JS()
+@anonymous
+class LiteralB {
+  external int get y;
+}
+
+// Library is annotated with JS so we don't need the annotation here.
+external LiteralA get a;
+external LiteralB get b;
+
+void main() {
+  eval(r"""
+    function Foo(a) {
+      this.a = a;
+    }
+    function Bar(a) {
+      this.a = a;
+    }
+    function Baz(a, b) {
+      Foo.call(this, a);
+      this.b = b;
+    }
+    Baz.prototype.__proto__ = Foo.prototype;
+    var a = {
+      x: 1,
+    };
+    var b = {
+      y: 2,
+    };
+      """);
+
+  // JS class object can be checked and casted with itself.
+  var foo = Foo(42);
+  expect(foo is Foo, isTrue);
+  expect(() => (foo as Foo), returnsNormally);
+
+  // Try it with dynamic.
+  dynamic d = Foo(42);
+  expect(d is Foo, isTrue);
+  expect(() => (d as Foo), returnsNormally);
+
+  // Casts are allowed between any JS class objects.
+  expect(foo is Bar, isTrue);
+  expect(d is Bar, isTrue);
+  expect(() => (foo as Bar), returnsNormally);
+  expect(() => (d as Bar), returnsNormally);
+
+  // Type-checking and casting works regardless of the inheritance chain.
+  var baz = Baz(42, 43);
+  expect(baz is Foo, isTrue);
+  expect(() => (baz as Foo), returnsNormally);
+  expect(foo is Baz, isTrue);
+  expect(() => (foo as Baz), returnsNormally);
+
+  // BarCopy is the same JS class as Bar.
+  var barCopy = BarCopy(42);
+  expect(barCopy is Bar, isTrue);
+  expect(() => (barCopy as Bar), returnsNormally);
+
+  // JS object literal can be checked and casted with itself.
+  expect(a is LiteralA, isTrue);
+  expect(() => (a as LiteralA), returnsNormally);
+
+  // Like class objects, casts are allowed between any object literals.
+  expect(a is LiteralB, isTrue);
+  expect(() => (a as LiteralB), returnsNormally);
+
+  // Similarly, casts are allowed between any class objects and object literals.
+  expect(foo is LiteralB, isTrue);
+  expect(() => (foo as LiteralB), returnsNormally);
+  expect(a is Foo, isTrue);
+  expect(() => (a as Foo), returnsNormally);
+}
diff --git a/tests/lib/js/parameters_static_test.dart b/tests/lib/js/parameters_static_test.dart
new file mode 100644
index 0000000..0928ca5
--- /dev/null
+++ b/tests/lib/js/parameters_static_test.dart
@@ -0,0 +1,63 @@
+// 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.
+
+// TODO(srujzs): Fix this test once web static error testing is supported.
+
+// Checks for static errors related to parameters for methods.
+
+@JS()
+library js_parameters_static_test;
+
+import 'package:js/js.dart';
+import 'package:expect/expect.dart';
+
+@JS()
+class Foo {
+  external int singleNamedArg({int? a});
+  //                                ^
+  // [web] TODO(srujzs): Add error once supported.
+  external int mixedNamedArgs(int a, {int? b});
+  //                                       ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+@JS()
+class Bar {
+  external static int singleNamedArg({int? a});
+  //                                       ^
+  // [web] TODO(srujzs): Add error once supported.
+  external static int mixedNamedArgs(int a, {int? b});
+  //                                              ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+external int singleNamedArg({int? a});
+//                                ^
+// [web] TODO(srujzs): Add error once supported.
+external int mixedNamedArgs(int a, {int? b});
+//                                       ^
+// [web] TODO(srujzs): Add error once supported.
+
+@JS()
+@anonymous
+class Baz {
+  external int singleNamedArg({int? a});
+  //                                ^
+  // [web] TODO(srujzs): Add error once supported.
+  external int mixedNamedArgs(int a, {int? b});
+  //                                       ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+@JS()
+abstract class Qux {
+  external int singleNamedArg({int? a});
+  //                                ^
+  // [web] TODO(srujzs): Add error once supported.
+  external int mixedNamedArgs(int a, {int? b});
+  //                                       ^
+  // [web] TODO(srujzs): Add error once supported.
+}
+
+main() {}
diff --git a/tests/lib/mirrors/null_test.dart b/tests/lib/mirrors/null_test.dart
index 21ae2d8..0d58539 100644
--- a/tests/lib/mirrors/null_test.dart
+++ b/tests/lib/mirrors/null_test.dart
@@ -18,20 +18,35 @@
 
   InstanceMirror im1 = reflect(null);
   Expect.equals(cm, im1.type);
-  Expect.isTrue(im1.invoke(const Symbol("=="), [null]).reflectee);
+  if (isStrongMode) {
+    Expect.throwsTypeError(() => im1.invoke(const Symbol("=="), [null]),
+        'null not assignable to Object');
+  } else {
+    Expect.isTrue(im1.invoke(const Symbol("=="), [null]).reflectee);
+  }
   Expect.isFalse(im1.invoke(const Symbol("=="), [42]).reflectee);
 
   var obj = confuse(null); // Null value that isn't known at compile-time.
   InstanceMirror im2 = reflect(obj);
   Expect.equals(cm, im2.type);
-  Expect.isTrue(im2.invoke(const Symbol("=="), [null]).reflectee);
+  if (isStrongMode) {
+    Expect.throwsTypeError(() => im2.invoke(const Symbol("=="), [null]),
+        'null not assignable to Object');
+  } else {
+    Expect.isTrue(im2.invoke(const Symbol("=="), [null]).reflectee);
+  }
   Expect.isFalse(im2.invoke(const Symbol("=="), [42]).reflectee);
 
   InstanceMirror nullMirror = reflect(null);
   Expect.isTrue(nullMirror.getField(#hashCode).reflectee is int);
   Expect.equals(null.hashCode, nullMirror.getField(#hashCode).reflectee);
   Expect.equals('Null', nullMirror.getField(#runtimeType).reflectee.toString());
-  Expect.isTrue(nullMirror.invoke(#==, [null]).reflectee);
+  if (isStrongMode) {
+    Expect.throwsTypeError(
+        () => nullMirror.invoke(#==, [null]), 'null not assignable to Object');
+  } else {
+    Expect.isTrue(nullMirror.invoke(#==, [null]).reflectee);
+  }
   Expect.isFalse(nullMirror.invoke(#==, [new Object()]).reflectee);
   Expect.equals('null', nullMirror.invoke(#toString, []).reflectee);
   Expect.throwsNoSuchMethodError(
diff --git a/tests/lib/web/mirrors_support_test.dart b/tests/lib/web/mirrors_support_test.dart
index 03dc2d5..78f3648 100644
--- a/tests/lib/web/mirrors_support_test.dart
+++ b/tests/lib/web/mirrors_support_test.dart
@@ -2,16 +2,9 @@
 // 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:mirrors' provides no functionality in dart-web, but can be imported and
-// all APIs throw.
-import 'dart:mirrors';
-import 'package:expect/expect.dart';
+// 'dart:mirrors' can no longer be imported, doing so produces a static error.
+import 'dart:mirrors';   //# 01: compile-time error
 
 main() {
-  Expect.throws<UnsupportedError>(() => currentMirrorSystem());
-  Expect.throws<UnsupportedError>(() => reflect(main));
-  Expect.throws<UnsupportedError>(() => reflectClass(Object));
-  Expect.throws<UnsupportedError>(() => reflectType(Object));
-  Expect.throws<UnsupportedError>(() => MirrorSystem.getName(#core));
-  Expect.throws<UnsupportedError>(() => MirrorSystem.getSymbol("core"));
+  reflect(main);         //# 01: continued
 }
diff --git a/tests/lib_2/html/streams_test.dart b/tests/lib_2/html/streams_test.dart
index 63c4bd7..713a6e6 100644
--- a/tests/lib_2/html/streams_test.dart
+++ b/tests/lib_2/html/streams_test.dart
@@ -189,7 +189,7 @@
   });
 
   test('reduce', () {
-    stream.reduce((a, b) => null).then((_) {});
+    stream.reduce((a, b) => a).then((_) {});
   });
 
   test('fold', () {
diff --git a/tests/lib_2/web/mirrors_support_test.dart b/tests/lib_2/web/mirrors_support_test.dart
index 03dc2d5..78f3648 100644
--- a/tests/lib_2/web/mirrors_support_test.dart
+++ b/tests/lib_2/web/mirrors_support_test.dart
@@ -2,16 +2,9 @@
 // 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:mirrors' provides no functionality in dart-web, but can be imported and
-// all APIs throw.
-import 'dart:mirrors';
-import 'package:expect/expect.dart';
+// 'dart:mirrors' can no longer be imported, doing so produces a static error.
+import 'dart:mirrors';   //# 01: compile-time error
 
 main() {
-  Expect.throws<UnsupportedError>(() => currentMirrorSystem());
-  Expect.throws<UnsupportedError>(() => reflect(main));
-  Expect.throws<UnsupportedError>(() => reflectClass(Object));
-  Expect.throws<UnsupportedError>(() => reflectType(Object));
-  Expect.throws<UnsupportedError>(() => MirrorSystem.getName(#core));
-  Expect.throws<UnsupportedError>(() => MirrorSystem.getSymbol("core"));
+  reflect(main);         //# 01: continued
 }
diff --git a/tests/standalone/fragmentation_deferred_load_lib1.dart b/tests/standalone/fragmentation_deferred_load_lib1.dart
new file mode 100644
index 0000000..c561f14
--- /dev/null
+++ b/tests/standalone/fragmentation_deferred_load_lib1.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "one!";
+}
diff --git a/tests/standalone/fragmentation_deferred_load_lib2.dart b/tests/standalone/fragmentation_deferred_load_lib2.dart
new file mode 100644
index 0000000..1f01b0f
--- /dev/null
+++ b/tests/standalone/fragmentation_deferred_load_lib2.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "two!";
+}
diff --git a/tests/standalone/fragmentation_deferred_load_lib3.dart b/tests/standalone/fragmentation_deferred_load_lib3.dart
new file mode 100644
index 0000000..77d3264
--- /dev/null
+++ b/tests/standalone/fragmentation_deferred_load_lib3.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "three!";
+}
diff --git a/tests/standalone/fragmentation_deferred_load_test.dart b/tests/standalone/fragmentation_deferred_load_test.dart
new file mode 100644
index 0000000..b84a09c
--- /dev/null
+++ b/tests/standalone/fragmentation_deferred_load_test.dart
@@ -0,0 +1,40 @@
+// 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.
+
+// VMOptions=--use_compactor
+
+// Each loading unit creates more image pages in the heap, which unfortunately
+// cannot be aligned stronger than virtual memory page alignment, so the
+// compactor must detect references to these image pages separately. Before
+// these loading units were implemented, the compactor could assume a small
+// upper bound on the number of image pages.
+
+import "package:expect/expect.dart";
+import "fragmentation_deferred_load_lib1.dart" deferred as lib1;
+import "fragmentation_deferred_load_lib2.dart" deferred as lib2;
+import "fragmentation_deferred_load_lib3.dart" deferred as lib3;
+
+main() async {
+  await lib1.loadLibrary();
+  Expect.equals("one!", lib1.foo());
+  await lib2.loadLibrary();
+  Expect.equals("two!", lib2.foo());
+  await lib3.loadLibrary();
+  Expect.equals("three!", lib3.foo());
+
+  final List<List?> arrays = [];
+  // Fill up heap with alternate large-small items.
+  for (int i = 0; i < 500000; i++) {
+    arrays.add(new List<dynamic>.filled(260, null));
+    arrays.add(new List<dynamic>.filled(1, null));
+  }
+  // Clear the large items so that the heap is full of 260-word gaps.
+  for (int i = 0; i < arrays.length; i += 2) {
+    arrays[i] = null;
+  }
+  // Allocate a lot of 300-word objects that don't fit in the gaps.
+  for (int i = 0; i < 600000; i++) {
+    arrays.add(new List<dynamic>.filled(300, null));
+  }
+}
diff --git a/tests/standalone/io/file_copy_test.dart b/tests/standalone/io/file_copy_test.dart
index 2302a4a..b1c0723 100644
--- a/tests/standalone/io/file_copy_test.dart
+++ b/tests/standalone/io/file_copy_test.dart
@@ -30,6 +30,14 @@
   Expect.equals(FILE_CONTENT2, file1.readAsStringSync());
   Expect.equals(FILE_CONTENT2, file2.readAsStringSync());
 
+  // Check there is no temporary files existing.
+  var list = tmp.listSync();
+  Expect.equals(2, list.length);
+  for (var file in list) {
+    final fileName = file.path.toString();
+    Expect.isTrue(fileName.contains("file1") || fileName.contains("file2"));
+  }
+
   // Fail when coping to directory.
   var dir = new Directory('${tmp.path}/dir')..createSync();
   Expect.throws(() => file1.copySync(dir.path));
@@ -38,6 +46,28 @@
   tmp.deleteSync(recursive: true);
 }
 
+void testWithForwardSlashes() {
+  if (Platform.isWindows) {
+    final tmp = Directory.systemTemp.createTempSync('dart-file-copy');
+
+    final file1 = File('${tmp.path}/file1');
+    file1.writeAsStringSync(FILE_CONTENT1);
+    Expect.equals(FILE_CONTENT1, file1.readAsStringSync());
+
+    // Test with a path contains only forward slashes.
+    final dest = tmp.path.toString().replaceAll("\\", "/");
+    final file2 = file1.copySync('${dest}/file2');
+    Expect.equals(FILE_CONTENT1, file2.readAsStringSync());
+
+    // Test with a path mixing both forward and backward slashes.
+    final file3 = file1.copySync('${dest}\\file3');
+    Expect.equals(FILE_CONTENT1, file3.readAsStringSync());
+
+    // Clean up the directory
+    tmp.deleteSync(recursive: true);
+  }
+}
+
 void testCopy() {
   asyncStart();
   var tmp = Directory.systemTemp.createTempSync('dart-file-copy');
@@ -76,4 +106,6 @@
 main() {
   testCopySync();
   testCopy();
+  // This is Windows only test.
+  testWithForwardSlashes();
 }
diff --git a/tests/standalone/package/scenarios/both_dir_and_file/.dart_tool/package_config.json b/tests/standalone/package/scenarios/both_dir_and_file/.dart_tool/package_config.json
new file mode 100644
index 0000000..23e4838
--- /dev/null
+++ b/tests/standalone/package/scenarios/both_dir_and_file/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "copyright": [
+    "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."
+  ],
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "foo",
+      "rootUri": "../foo",
+      "languageVersion": "2.10"
+    }
+  ]
+}
diff --git a/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart b/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
index 5b5156e..898a519 100644
--- a/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
+++ b/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
@@ -6,6 +6,6 @@
 
 library empty_packages_file_discovery_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart b/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
index 010f5f3..fbde79f 100644
--- a/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
+++ b/tests/standalone/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
@@ -6,6 +6,6 @@
 
 library empty_packages_file_option_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone/package/scenarios/packages_file_in_parent/.dart_tool/package_config.json b/tests/standalone/package/scenarios/packages_file_in_parent/.dart_tool/package_config.json
new file mode 100644
index 0000000..23e4838
--- /dev/null
+++ b/tests/standalone/package/scenarios/packages_file_in_parent/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "copyright": [
+    "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."
+  ],
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "foo",
+      "rootUri": "../foo",
+      "languageVersion": "2.10"
+    }
+  ]
+}
diff --git a/tests/standalone/package/scenarios/packages_file_only/.dart_tool/package_config.json b/tests/standalone/package/scenarios/packages_file_only/.dart_tool/package_config.json
new file mode 100644
index 0000000..23e4838
--- /dev/null
+++ b/tests/standalone/package/scenarios/packages_file_only/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "copyright": [
+    "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."
+  ],
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "foo",
+      "rootUri": "../foo",
+      "languageVersion": "2.10"
+    }
+  ]
+}
diff --git a/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_lines_test.dart b/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_lines_test.dart
index 665597a..1b77992 100644
--- a/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_lines_test.dart
+++ b/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_lines_test.dart
@@ -4,6 +4,10 @@
 
 // Packages=empty_lines.packages
 
+// This test verifies handling of legacy .packages file and cannot be run in
+// null safety (strong) mode as strong mode needs new package_config.json.
+// Requirements=nnbd-weak
+
 library empty_lines_test;
 
 import 'package:foo/foo.dart' as foo;
diff --git a/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart b/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
index 97cded4..b908cbf 100644
--- a/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
+++ b/tests/standalone/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
@@ -4,12 +4,16 @@
 
 // Packages=empty_package_dir.packages
 
+// This test verifies handling of legacy .packages file and cannot be run in
+// null safety (strong) mode as strong mode needs new package_config.json.
+// Requirements=nnbd-weak
+
 // In this test, we give a packages file that associates the package 'foo' with
 // the empty string. This causes both the VM and dart2js to resolve
 // 'package:foo' imports relative to the root directory. So the import statement
 // `import 'package:foo/foo.dart'` is equivalent to `import '/foo.dart'`.
 library empty_package_dir_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone/package/scenarios/packages_file_strange_formatting/mixed_line_ends_test.dart b/tests/standalone/package/scenarios/packages_file_strange_formatting/mixed_line_ends_test.dart
index 3e9ec48..b41423a 100644
--- a/tests/standalone/package/scenarios/packages_file_strange_formatting/mixed_line_ends_test.dart
+++ b/tests/standalone/package/scenarios/packages_file_strange_formatting/mixed_line_ends_test.dart
@@ -4,6 +4,10 @@
 
 // Packages=mixed_line_ends.packages
 
+// This test verifies handling of legacy .packages file and cannot be run in
+// null safety (strong) mode as strong mode needs new package_config.json.
+// Requirements=nnbd-weak
+
 library mixed_line_ends_test;
 
 import 'package:foo/foo.dart' as foo;
diff --git a/tests/standalone/package/scenarios/packages_option_only/sub/.dart_tool/package_config.json b/tests/standalone/package/scenarios/packages_option_only/sub/.dart_tool/package_config.json
new file mode 100644
index 0000000..23e4838
--- /dev/null
+++ b/tests/standalone/package/scenarios/packages_option_only/sub/.dart_tool/package_config.json
@@ -0,0 +1,15 @@
+{
+  "copyright": [
+    "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."
+  ],
+  "configVersion": 2,
+  "packages": [
+    {
+      "name": "foo",
+      "rootUri": "../foo",
+      "languageVersion": "2.10"
+    }
+  ]
+}
diff --git a/tests/standalone/regress_41329_absolute_test.dart b/tests/standalone/regress_41329_absolute_test.dart
index cc2a402..e35e126 100644
--- a/tests/standalone/regress_41329_absolute_test.dart
+++ b/tests/standalone/regress_41329_absolute_test.dart
@@ -4,8 +4,6 @@
 
 import 'dart:io';
 
-import 'package:async_helper/async_helper.dart';
-import 'package:path/path.dart' as p;
 import 'package:expect/expect.dart';
 
 Future<void> main() async {
diff --git a/tests/standalone/regress_41329_relative_test.dart b/tests/standalone/regress_41329_relative_test.dart
index cc2a402..e35e126 100644
--- a/tests/standalone/regress_41329_relative_test.dart
+++ b/tests/standalone/regress_41329_relative_test.dart
@@ -4,8 +4,6 @@
 
 import 'dart:io';
 
-import 'package:async_helper/async_helper.dart';
-import 'package:path/path.dart' as p;
 import 'package:expect/expect.dart';
 
 Future<void> main() async {
diff --git a/tests/standalone_2/fragmentation_deferred_load_lib1.dart b/tests/standalone_2/fragmentation_deferred_load_lib1.dart
new file mode 100644
index 0000000..c561f14
--- /dev/null
+++ b/tests/standalone_2/fragmentation_deferred_load_lib1.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "one!";
+}
diff --git a/tests/standalone_2/fragmentation_deferred_load_lib2.dart b/tests/standalone_2/fragmentation_deferred_load_lib2.dart
new file mode 100644
index 0000000..1f01b0f
--- /dev/null
+++ b/tests/standalone_2/fragmentation_deferred_load_lib2.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "two!";
+}
diff --git a/tests/standalone_2/fragmentation_deferred_load_lib3.dart b/tests/standalone_2/fragmentation_deferred_load_lib3.dart
new file mode 100644
index 0000000..77d3264
--- /dev/null
+++ b/tests/standalone_2/fragmentation_deferred_load_lib3.dart
@@ -0,0 +1,7 @@
+// 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.
+
+foo() {
+  return "three!";
+}
diff --git a/tests/standalone_2/fragmentation_deferred_load_test.dart b/tests/standalone_2/fragmentation_deferred_load_test.dart
new file mode 100644
index 0000000..8e0ecc3
--- /dev/null
+++ b/tests/standalone_2/fragmentation_deferred_load_test.dart
@@ -0,0 +1,40 @@
+// 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.
+
+// VMOptions=--use_compactor
+
+// Each loading unit creates more image pages in the heap, which unfortunately
+// cannot be aligned stronger than virtual memory page alignment, so the
+// compactor must detect references to these image pages separately. Before
+// these loading units were implemented, the compactor could assume a small
+// upper bound on the number of image pages.
+
+import "package:expect/expect.dart";
+import "fragmentation_deferred_load_lib1.dart" deferred as lib1;
+import "fragmentation_deferred_load_lib2.dart" deferred as lib2;
+import "fragmentation_deferred_load_lib3.dart" deferred as lib3;
+
+main() async {
+  await lib1.loadLibrary();
+  Expect.equals("one!", lib1.foo());
+  await lib2.loadLibrary();
+  Expect.equals("two!", lib2.foo());
+  await lib3.loadLibrary();
+  Expect.equals("three!", lib3.foo());
+
+  final List<List> arrays = [];
+  // Fill up heap with alternate large-small items.
+  for (int i = 0; i < 500000; i++) {
+    arrays.add(new List(260));
+    arrays.add(new List(1));
+  }
+  // Clear the large items so that the heap is full of 260-word gaps.
+  for (int i = 0; i < arrays.length; i += 2) {
+    arrays[i] = null;
+  }
+  // Allocate a lot of 300-word objects that don't fit in the gaps.
+  for (int i = 0; i < 600000; i++) {
+    arrays.add(new List(300));
+  }
+}
diff --git a/tests/standalone_2/io/file_copy_test.dart b/tests/standalone_2/io/file_copy_test.dart
index 2302a4a..b1c0723 100644
--- a/tests/standalone_2/io/file_copy_test.dart
+++ b/tests/standalone_2/io/file_copy_test.dart
@@ -30,6 +30,14 @@
   Expect.equals(FILE_CONTENT2, file1.readAsStringSync());
   Expect.equals(FILE_CONTENT2, file2.readAsStringSync());
 
+  // Check there is no temporary files existing.
+  var list = tmp.listSync();
+  Expect.equals(2, list.length);
+  for (var file in list) {
+    final fileName = file.path.toString();
+    Expect.isTrue(fileName.contains("file1") || fileName.contains("file2"));
+  }
+
   // Fail when coping to directory.
   var dir = new Directory('${tmp.path}/dir')..createSync();
   Expect.throws(() => file1.copySync(dir.path));
@@ -38,6 +46,28 @@
   tmp.deleteSync(recursive: true);
 }
 
+void testWithForwardSlashes() {
+  if (Platform.isWindows) {
+    final tmp = Directory.systemTemp.createTempSync('dart-file-copy');
+
+    final file1 = File('${tmp.path}/file1');
+    file1.writeAsStringSync(FILE_CONTENT1);
+    Expect.equals(FILE_CONTENT1, file1.readAsStringSync());
+
+    // Test with a path contains only forward slashes.
+    final dest = tmp.path.toString().replaceAll("\\", "/");
+    final file2 = file1.copySync('${dest}/file2');
+    Expect.equals(FILE_CONTENT1, file2.readAsStringSync());
+
+    // Test with a path mixing both forward and backward slashes.
+    final file3 = file1.copySync('${dest}\\file3');
+    Expect.equals(FILE_CONTENT1, file3.readAsStringSync());
+
+    // Clean up the directory
+    tmp.deleteSync(recursive: true);
+  }
+}
+
 void testCopy() {
   asyncStart();
   var tmp = Directory.systemTemp.createTempSync('dart-file-copy');
@@ -76,4 +106,6 @@
 main() {
   testCopySync();
   testCopy();
+  // This is Windows only test.
+  testWithForwardSlashes();
 }
diff --git a/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart b/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
index 5b5156e..898a519 100644
--- a/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
+++ b/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_discovery_test.dart
@@ -6,6 +6,6 @@
 
 library empty_packages_file_discovery_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart b/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
index 010f5f3..fbde79f 100644
--- a/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
+++ b/tests/standalone_2/package/scenarios/empty_packages_file/empty_packages_file_option_test.dart
@@ -6,6 +6,6 @@
 
 library empty_packages_file_option_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone_2/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart b/tests/standalone_2/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
index 97cded4..2cf07c9 100644
--- a/tests/standalone_2/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
+++ b/tests/standalone_2/package/scenarios/packages_file_strange_formatting/empty_package_dir_test.dart
@@ -10,6 +10,6 @@
 // `import 'package:foo/foo.dart'` is equivalent to `import '/foo.dart'`.
 library empty_package_dir_test;
 
-import 'package:foo/foo.dart';
+import 'package:foo/foo.dart'; //# 01: compile-time error
 
 main() {}
diff --git a/tests/standalone_2/regress_41329_absolute_test.dart b/tests/standalone_2/regress_41329_absolute_test.dart
index cc2a402..e35e126 100644
--- a/tests/standalone_2/regress_41329_absolute_test.dart
+++ b/tests/standalone_2/regress_41329_absolute_test.dart
@@ -4,8 +4,6 @@
 
 import 'dart:io';
 
-import 'package:async_helper/async_helper.dart';
-import 'package:path/path.dart' as p;
 import 'package:expect/expect.dart';
 
 Future<void> main() async {
diff --git a/tests/standalone_2/regress_41329_relative_test.dart b/tests/standalone_2/regress_41329_relative_test.dart
index cc2a402..e35e126 100644
--- a/tests/standalone_2/regress_41329_relative_test.dart
+++ b/tests/standalone_2/regress_41329_relative_test.dart
@@ -4,8 +4,6 @@
 
 import 'dart:io';
 
-import 'package:async_helper/async_helper.dart';
-import 'package:path/path.dart' as p;
 import 'package:expect/expect.dart';
 
 Future<void> main() async {
diff --git a/tools/VERSION b/tools/VERSION
index b8eb434..b03de39 100644
--- a/tools/VERSION
+++ b/tools/VERSION
@@ -31,9 +31,9 @@
 #
 CHANNEL dev
 MAJOR 2
-MINOR 9
+MINOR 10
 PATCH 0
-PRERELEASE 21
+PRERELEASE 0
 PRERELEASE_PATCH 0
-ABI_VERSION 38
-OLDEST_SUPPORTED_ABI_VERSION 38
+ABI_VERSION 39
+OLDEST_SUPPORTED_ABI_VERSION 39
diff --git a/tools/bots/get_builder_status.dart b/tools/bots/get_builder_status.dart
index 725c9f4..e464abc 100755
--- a/tools/bots/get_builder_status.dart
+++ b/tools/bots/get_builder_status.dart
@@ -17,8 +17,15 @@
 
 const numAttempts = 20;
 const failuresPerConfiguration = 20;
-const queryUrl = 'https://firestore.googleapis.com/v1/'
-    'projects/dart-ci/databases/(default)/documents:runQuery';
+
+bool useStagingDatabase;
+
+String get queryUrl {
+  var project = useStagingDatabase ? "dart-ci-staging" : "dart-ci";
+  return 'https://firestore.googleapis.com/v1/'
+      'projects/$project/databases/(default)/documents:runQuery';
+}
+
 String builder;
 String builderBase;
 int buildNumber;
@@ -46,6 +53,11 @@
   exit(1);
 }
 
+Future<String> readGcloudAuthToken(String path) async {
+  String token = await File(path).readAsString();
+  return token.split("\n").first;
+}
+
 main(List<String> args) async {
   final parser = new ArgParser();
   parser.addFlag('help', help: 'Show the program usage.', negatable: false);
@@ -53,16 +65,23 @@
       abbr: 'a', help: 'Authorization token with cloud-platform scope');
   parser.addOption('builder', abbr: 'b', help: 'The builder name');
   parser.addOption('build_number', abbr: 'n', help: 'The build number');
+  parser.addFlag('staging',
+      abbr: 's', help: 'use staging database', defaultsTo: false);
 
   final options = parser.parse(args);
   if (options['help']) {
     usage(parser);
   }
 
+  useStagingDatabase = options['staging'];
   builder = options['builder'];
   buildNumber = int.parse(options['build_number']);
   builderBase = builder.replaceFirst(RegExp('-try\$'), '');
-  token = await File(options['auth_token']).readAsString();
+  if (options['auth_token'] == null) {
+    print('Option "--auth_token (-a)" is required\n');
+    usage(parser);
+  }
+  token = await readGcloudAuthToken(options['auth_token']);
   client = http.Client();
   for (int count = 0; count < numAttempts; ++count) {
     if (count > 0) {
@@ -104,7 +123,7 @@
           ].join(' '));
         }
       } else {
-        print('No results recieved for build $buildNumber of $builder');
+        print('No results received for build $buildNumber of $builder');
       }
     } else {
       print('HTTP status ${response.statusCode} received '
diff --git a/tools/bots/test_matrix.json b/tools/bots/test_matrix.json
index fcb7636..5ed6cd3 100644
--- a/tools/bots/test_matrix.json
+++ b/tools/bots/test_matrix.json
@@ -313,6 +313,7 @@
       "third_party/android_tools/sdk/platform-tools/adb",
       "third_party/android_tools/ndk/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64/bin/aarch64-linux-android-strip",
       "third_party/android_tools/ndk/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-strip",
+      "third_party/webdriver/",
       "third_party/pkg/",
       "third_party/pkg_tested/",
       "tests/.dart_tool/package_config.json",
@@ -700,6 +701,7 @@
       }
     },
     "dartk-(linux|mac|win)-(debug|product|release)-(ia32|x64)": {},
+    "dartk-fuchsia-(debug|product|release)-x64": {},
     "dartk-linux-debug-(ia32|x64)-canary": {
       "options": {
         "builder-tag": "canary"
@@ -711,11 +713,11 @@
           "non-nullable"
         ],
 	"gen-kernel-options": [
-          "--no-null-safety"
+          "--no-sound-null-safety"
         ],
         "enable-asserts": true,
 	"vm-options": [
-          "--no-null-safety"
+          "--no-sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -726,12 +728,12 @@
           "non-nullable"
         ],
 	"gen-kernel-options": [
-          "--no-null-safety"
+          "--no-sound-null-safety"
         ],
         "enable-asserts": true,
         "use-elf": true,
 	"vm-options": [
-          "--no-null-safety"
+          "--no-sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -743,7 +745,7 @@
         ],
         "enable-asserts": true,
 	"vm-options": [
-          "--no-null-safety"
+          "--no-sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -754,7 +756,7 @@
           "non-nullable"
         ],
         "vm-options": [
-          "--null-safety"
+          "--sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -765,10 +767,10 @@
           "non-nullable"
         ],
         "gen-kernel-options": [
-          "--null-safety"
+          "--sound-null-safety"
         ],
         "vm-options": [
-          "--null-safety"
+          "--sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -780,10 +782,10 @@
           "non-nullable"
         ],
         "gen-kernel-options": [
-          "--null-safety"
+          "--sound-null-safety"
         ],
         "vm-options": [
-          "--null-safety"
+          "--sound-null-safety"
         ],
         "builder-tag": "vm_nnbd"
       }
@@ -1120,18 +1122,10 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--mode=${mode}",
-            "--arch=${arch}",
-            "--bytecode"
-          ]
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
+            "--bytecode",
             "runtime"
           ]
         },
@@ -1274,16 +1268,10 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--use-qemu"
-          ]
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
+            "--use-qemu",
             "dart_precompiled_runtime",
             "runtime_kernel"
           ]
@@ -1527,11 +1515,6 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": []
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
@@ -1555,11 +1538,6 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": []
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
@@ -1587,11 +1565,6 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": []
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
@@ -1618,11 +1591,6 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": []
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
@@ -1648,21 +1616,13 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--mode=all",
-            "--arch=all",
-            "--no-clang",
-            "--no-goma"
-          ]
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
             "--mode=all",
             "--arch=all",
+            "--no-clang",
+            "--no-goma",
             "runtime"
           ]
         }
@@ -2714,7 +2674,10 @@
             "--arch=x64",
             "--mode=release",
             "create_sdk"
-          ]
+          ],
+          "environment": {
+            "DART_GN_ARGS": "mac_use_goma_rbe=true"
+          }
         },
         {
           "name": "upload sdk",
@@ -3323,7 +3286,8 @@
             "--mode=release",
             "--arch=ia32",
             "create_sdk",
-            "runtime"
+            "runtime",
+            "kernel-service.dart.snapshot"
           ]
         },
         {
@@ -3356,7 +3320,8 @@
             "create_sdk",
             "runtime",
             "gen_snapshot",
-            "dart_precompiled_runtime"
+            "dart_precompiled_runtime",
+            "kernel-service.dart.snapshot"
           ]
         },
         {
@@ -3484,20 +3449,10 @@
       },
       "steps": [
         {
-          "name": "configure dart",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--mode=release",
-            "--arch=x64",
-            "--bytecode"
-          ]
-        },
-        {
           "name": "build dart",
           "script": "tools/build.py",
           "arguments": [
-            "--mode=release",
-            "--arch=x64",
+            "--bytecode",
             "create_sdk_with_abi_versions"
           ]
         },
@@ -3519,29 +3474,10 @@
       },
       "steps": [
         {
-          "name": "configure dart for simarm_x64",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--mode=${mode}",
-            "--arch=simarm_x64",
-            "--bytecode"
-          ]
-        },
-        {
-          "name": "configure dart for simarm",
-          "script": "tools/gn.py",
-          "arguments": [
-            "--mode=${mode}",
-            "--arch=simarm",
-            "--bytecode"
-          ]
-        },
-        {
           "name": "build dart for simarm_x64",
           "script": "tools/build.py",
           "arguments": [
-            "--mode=${mode}",
-            "--arch=simarm_x64",
+            "--bytecode",
             "gen_snapshot"
           ]
         },
@@ -3549,8 +3485,8 @@
           "name": "build dart for simarm",
           "script": "tools/build.py",
           "arguments": [
-            "--mode=${mode}",
             "--arch=simarm",
+            "--bytecode",
             "dart_precompiled_runtime",
             "vm_platform"
           ]
diff --git a/tools/bots/try_benchmarks.sh b/tools/bots/try_benchmarks.sh
index aaf6d55..09d4229 100755
--- a/tools/bots/try_benchmarks.sh
+++ b/tools/bots/try_benchmarks.sh
@@ -77,6 +77,7 @@
     # NOTE: These are duplicated in tools/bots/test_matrix.json, keep in sync.
     ./tools/build.py --mode=release --arch=ia32 create_sdk
     ./tools/build.py --mode=release --arch=ia32 runtime
+    ./tools/build.py --mode=release --arch=ia32 kernel-service.dart.snapshot
   elif [ "$command" = linux-ia32-archive ]; then
     strip -w \
       -K 'kDartVmSnapshotData' \
@@ -151,6 +152,7 @@
       out/ReleaseIA32/dart \
       out/ReleaseIA32/gen_snapshot \
       out/ReleaseIA32/gen_kernel_bytecode.dill \
+      out/ReleaseIA32/kernel-service.dart.snapshot \
       out/ReleaseIA32/run_vm_tests \
       sdk \
       samples-dev/swarm \
@@ -174,28 +176,30 @@
 }
 EOF
     out/ReleaseIA32/dart --profile-period=10000 --packages=.packages hello.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages hello.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages hello.dart
     out/ReleaseIA32/dart pkg/front_end/tool/perf.dart parse hello.dart
     out/ReleaseIA32/dart pkg/front_end/tool/perf.dart scan hello.dart
     out/ReleaseIA32/dart pkg/front_end/tool/fasta_perf.dart kernel_gen_e2e hello.dart
     out/ReleaseIA32/dart pkg/front_end/tool/fasta_perf.dart scan hello.dart
-    out/ReleaseIA32/dart --print_metrics pkg/analyzer_cli/bin/analyzer.dart --dart-sdk=sdk hello.dart
-    out/ReleaseIA32/run_vm_tests InitialRSS
-    out/ReleaseIA32/run_vm_tests --null-safety --enable-experiment=non-nullable InitialRSS
-    out/ReleaseIA32/run_vm_tests GenKernelKernelLoadKernel
-    out/ReleaseIA32/run_vm_tests --null-safety --enable-experiment=non-nullable GenKernelKernelLoadKernel
-    out/ReleaseIA32/run_vm_tests KernelServiceCompileAll
-    out/ReleaseIA32/run_vm_tests --null-safety --enable-experiment=non-nullable KernelServiceCompileAll
+    out/ReleaseIA32/dart-sdk/bin/dart --print_metrics pkg/analyzer_cli/bin/analyzer.dart --dart-sdk=sdk hello.dart
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot InitialRSS
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable InitialRSS
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot GenKernelKernelLoadKernel
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable GenKernelKernelLoadKernel
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot KernelServiceCompileAll
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable KernelServiceCompileAll
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot UseDartApi
+    out/ReleaseIA32/run_vm_tests --dfe=out/ReleaseIA32/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable UseDartApi
     out/ReleaseIA32/dart --profile-period=10000 --packages=.packages benchmarks/Example/dart2/Example.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages benchmarks/Example/dart/Example.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages benchmarks/Example/dart/Example.dart
     out/ReleaseIA32/dart benchmarks/FfiBoringssl/dart2/FfiBoringssl.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable benchmarks/FfiBoringssl/dart/FfiBoringssl.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable benchmarks/FfiBoringssl/dart/FfiBoringssl.dart
     out/ReleaseIA32/dart benchmarks/FfiCall/dart2/FfiCall.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable benchmarks/FfiCall/dart/FfiCall.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable benchmarks/FfiCall/dart/FfiCall.dart
     out/ReleaseIA32/dart benchmarks/FfiMemory/dart2/FfiMemory.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable benchmarks/FfiMemory/dart/FfiMemory.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable benchmarks/FfiMemory/dart/FfiMemory.dart
     out/ReleaseIA32/dart benchmarks/FfiStruct/dart2/FfiStruct.dart
-    out/ReleaseIA32/dart --null-safety --enable-experiment=non-nullable benchmarks/FfiStruct/dart/FfiStruct.dart
+    out/ReleaseIA32/dart --sound-null-safety --enable-experiment=non-nullable benchmarks/FfiStruct/dart/FfiStruct.dart
     cd ..
     rm -rf tmp
   elif [ "$command" = linux-x64-build ]; then
@@ -204,6 +208,7 @@
     ./tools/build.py --mode=release --arch=x64 runtime
     ./tools/build.py --mode=release --arch=x64 gen_snapshot
     ./tools/build.py --mode=release --arch=x64 dart_precompiled_runtime
+    ./tools/build.py --mode=release --arch=x64 kernel-service.dart.snapshot
   elif [ "$command" = linux-x64-archive ]; then
     strip -w \
       -K 'kDartVmSnapshotData' \
@@ -296,6 +301,7 @@
       out/ReleaseX64/dart \
       out/ReleaseX64/gen_snapshot \
       out/ReleaseX64/gen_kernel_bytecode.dill \
+      out/ReleaseX64/kernel-service.dart.snapshot \
       out/ReleaseX64/run_vm_tests \
       third_party/d8/linux/x64 \
       third_party/firefox_jsshell/linux/ \
@@ -322,11 +328,11 @@
 }
 EOF
     out/ReleaseX64/dart --profile-period=10000 --packages=.packages hello.dart
-    out/ReleaseX64/dart --null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages hello.dart
+    out/ReleaseX64/dart --sound-null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages hello.dart
     DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/precompiler2 --packages=.packages hello.dart blob.bin
     DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/dart_precompiled_runtime2 --profile-period=10000 blob.bin
-    DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/precompiler2 --null-safety --enable-experiment=non-nullable --packages=.packages hello.dart blob.bin
-    DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/dart_precompiled_runtime2 --null-safety --profile-period=10000 blob.bin
+    DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/precompiler2 --sound-null-safety --enable-experiment=non-nullable --packages=.packages hello.dart blob.bin
+    DART_CONFIGURATION=ReleaseX64 pkg/vm/tool/dart_precompiled_runtime2 --profile-period=10000 blob.bin
     out/ReleaseX64/dart --profile-period=10000 --packages=.packages --optimization-counter-threshold=-1 hello.dart
     out/ReleaseX64/dart-sdk/bin/dart2js --packages=.packages --out=out.js -m hello.dart
     third_party/d8/linux/x64/d8 --stack_size=1024 sdk/lib/_internal/js_runtime/lib/preambles/d8.js out.js
@@ -342,26 +348,28 @@
     third_party/d8/linux/x64/d8 --stack_size=1024 sdk/lib/_internal/js_runtime/lib/preambles/d8.js out.js
     out/ReleaseX64/dart-sdk/bin/dart2js --benchmarking-x --packages=.packages --out=out.js -m hello.dart
     third_party/d8/linux/x64/d8 --stack_size=1024 sdk/lib/_internal/js_runtime/lib/preambles/d8.js out.js
-    out/ReleaseX64/dart-sdk/bin/dart pkg/dev_compiler/tool/ddb -r d8 -b third_party/d8/linux/x64/d8 --kernel hello.dart
-    out/ReleaseX64/dart-sdk/bin/dart pkg/dev_compiler/tool/ddb -r d8 -b third_party/d8/linux/x64/d8 --mode=compile --compile-vm-options=--print-metrics --packages=.packages --out out.js --kernel hello.dart
+    out/ReleaseX64/dart-sdk/bin/dart pkg/dev_compiler/tool/ddb -r d8 -b third_party/d8/linux/x64/d8 hello.dart
+    out/ReleaseX64/dart-sdk/bin/dart pkg/dev_compiler/tool/ddb -r d8 -b third_party/d8/linux/x64/d8 --mode=compile --compile-vm-options=--print-metrics --packages=.packages --out out.js hello.dart
     out/ReleaseX64/dart pkg/front_end/tool/perf.dart parse hello.dart
     out/ReleaseX64/dart pkg/front_end/tool/perf.dart scan hello.dart
     out/ReleaseX64/dart pkg/front_end/tool/fasta_perf.dart kernel_gen_e2e hello.dart
     out/ReleaseX64/dart pkg/front_end/tool/fasta_perf.dart scan hello.dart
-    out/ReleaseX64/dart pkg/analysis_server/benchmark/benchmarks.dart run --quick --repeat 1 analysis-server-cold
-    out/ReleaseX64/dart --print_metrics pkg/analyzer_cli/bin/analyzer.dart --dart-sdk=sdk hello.dart
+    out/ReleaseX64/dart-sdk/bin/dart pkg/analysis_server/benchmark/benchmarks.dart run --quick --repeat 1 analysis-server-cold
+    out/ReleaseX64/dart-sdk/bin/dart --print_metrics pkg/analyzer_cli/bin/analyzer.dart --dart-sdk=sdk hello.dart
     echo '[{"name":"foo","edits":[["pkg/compiler/lib/src/dart2js.dart","2016","2017"],["pkg/compiler/lib/src/options.dart","2016","2017"]]}]' > appjit_train_edits.json
     out/ReleaseX64/dart --background-compilation=false --snapshot-kind=app-jit --snapshot=pkg/front_end/tool/incremental_perf.dart.appjit pkg/front_end/tool/incremental_perf.dart --target=vm --sdk-summary=out/ReleaseX64/vm_platform_strong.dill --sdk-library-specification=sdk/lib/libraries.json pkg/compiler/lib/src/dart2js.dart appjit_train_edits.json
     out/ReleaseX64/dart --background-compilation=false pkg/front_end/tool/incremental_perf.dart.appjit --target=vm --sdk-summary=out/ReleaseX64/vm_platform_strong.dill --sdk-library-specification=sdk/lib/libraries.json pkg/front_end/benchmarks/ikg/hello.dart pkg/front_end/benchmarks/ikg/hello.edits.json
     out/ReleaseX64/dart --packages=.packages pkg/kernel/test/binary_bench.dart --golem AstFromBinaryLazy out/ReleaseX64/vm_platform_strong.dill
-    out/ReleaseX64/run_vm_tests InitialRSS
-    out/ReleaseX64/run_vm_tests --null-safety --enable-experiment=non-nullable InitialRSS
-    out/ReleaseX64/run_vm_tests GenKernelKernelLoadKernel
-    out/ReleaseX64/run_vm_tests --null-safety --enable-experiment=non-nullable GenKernelKernelLoadKernel
-    out/ReleaseX64/run_vm_tests KernelServiceCompileAll
-    out/ReleaseX64/run_vm_tests --null-safety --enable-experiment=non-nullable KernelServiceCompileAll
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot InitialRSS
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable InitialRSS
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot GenKernelKernelLoadKernel
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable GenKernelKernelLoadKernel
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot KernelServiceCompileAll
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable KernelServiceCompileAll
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot UseDartApi
+    out/ReleaseX64/run_vm_tests --dfe=out/ReleaseX64/kernel-service.dart.snapshot --sound-null-safety --enable-experiment=non-nullable UseDartApi
     out/ReleaseX64/dart --profile-period=10000 --packages=.packages benchmarks/Example/dart2/Example.dart
-    out/ReleaseX64/dart --null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages benchmarks/Example/dart/Example.dart
+    out/ReleaseX64/dart --sound-null-safety --enable-experiment=non-nullable --profile-period=10000 --packages=.packages benchmarks/Example/dart/Example.dart
     cd ..
     rm -rf tmp
   else
diff --git a/tools/build.py b/tools/build.py
index 6321be1..6b78ddc 100755
--- a/tools/build.py
+++ b/tools/build.py
@@ -4,16 +4,18 @@
 # 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 argparse
 import io
 import json
 import multiprocessing
-import optparse
 import os
 import subprocess
 import sys
 import time
 import utils
 
+import gn as gn_py
+
 HOST_OS = utils.GuessOS()
 HOST_CPUS = utils.GuessCpus()
 SCRIPT_DIR = os.path.dirname(sys.argv[0])
@@ -26,128 +28,36 @@
 This script invokes ninja to build Dart.
 """
 
-
 def BuildOptions():
-    result = optparse.OptionParser(usage=usage)
-    result.add_option(
-        "-a",
-        "--arch",
-        help='Target architectures (comma-separated).',
-        metavar='[all,' + ','.join(AVAILABLE_ARCHS) + ']',
-        default=utils.GuessArchitecture())
-    result.add_option(
-        "-b",
-        "--bytecode",
-        help='Build with the kernel bytecode interpreter. DEPRECATED.',
-        default=False,
-        action='store_true')
-    result.add_option(
-        "-j", type=int, help='Ninja -j option for Goma builds.', default=1000)
-    result.add_option(
-        "-l", type=int, help='Ninja -l option for Goma builds.', default=64)
-    result.add_option(
-        "-m",
-        "--mode",
-        help='Build variants (comma-separated).',
-        metavar='[all,debug,release,product]',
-        default='debug')
-    result.add_option(
-        "--no-start-goma",
-        help="Don't try to start goma",
-        default=False,
-        action='store_true')
-    result.add_option(
-        "--os",
-        help='Target OSs (comma-separated).',
-        metavar='[all,host,android,fuchsia]',
-        default='host')
-    result.add_option(
-        "--sanitizer",
-        type=str,
-        help='Build variants (comma-separated).',
-        metavar='[all,none,asan,lsan,msan,tsan,ubsan]',
-        default='none')
-    result.add_option(
-        "-v",
-        "--verbose",
-        help='Verbose output.',
-        default=False,
-        action="store_true")
-    return result
+    parser = argparse.ArgumentParser(
+        description='Runs GN (if ncecessary) followed by ninja',
+        formatter_class=argparse.ArgumentDefaultsHelpFormatter)
 
+    config_group = parser.add_argument_group('Configuration Related Arguments')
+    gn_py.AddCommonConfigurationArgs(config_group)
 
-def ProcessOsOption(os_name):
-    if os_name == 'host':
-        return HOST_OS
-    return os_name
+    gn_group = parser.add_argument_group('GN Related Arguments')
+    gn_py.AddCommonGnOptionArgs(gn_group)
 
+    other_group = parser.add_argument_group('Other Arguments')
+    gn_py.AddOtherArgs(other_group)
 
-def ProcessOptions(options, args):
-    if options.arch == 'all':
-        options.arch = 'ia32,x64,simarm,simarm64'
-    if options.mode == 'all':
-        options.mode = 'debug,release,product'
-    if options.os == 'all':
-        options.os = 'host,android,fuchsia'
-    if options.sanitizer == 'all':
-        options.sanitizer = 'none,asan,lsan,msan,tsan,ubsan'
-    options.mode = options.mode.split(',')
-    options.arch = options.arch.split(',')
-    options.os = options.os.split(',')
-    options.sanitizer = options.sanitizer.split(',')
-    for mode in options.mode:
-        if not mode in ['debug', 'release', 'product']:
-            print("Unknown mode %s" % mode)
-            return False
-    for i, arch in enumerate(options.arch):
-        if not arch in AVAILABLE_ARCHS:
-            # Normalise to lower case form to make it less case-picky.
-            arch_lower = arch.lower()
-            if arch_lower in AVAILABLE_ARCHS:
-                options.arch[i] = arch_lower
-                continue
-            print("Unknown arch %s" % arch)
-            return False
-    options.os = [ProcessOsOption(os_name) for os_name in options.os]
-    for os_name in options.os:
-        if not os_name in [
-                'android', 'freebsd', 'linux', 'macos', 'win32', 'fuchsia'
-        ]:
-            print("Unknown os %s" % os_name)
-            return False
-        if os_name == 'android':
-            if not HOST_OS in ['linux', 'macos']:
-                print("Cross-compilation to %s is not supported on host os %s."
-                      % (os_name, HOST_OS))
-                return False
-            if not arch in [
-                    'ia32', 'x64', 'arm', 'arm_x64', 'armv6', 'arm64'
-            ]:
-                print(
-                    "Cross-compilation to %s is not supported for architecture %s."
-                    % (os_name, arch))
-                return False
-            # We have not yet tweaked the v8 dart build to work with the Android
-            # NDK/SDK, so don't try to build it.
-            if not args:
-                print(
-                    "For android builds you must specify a target, such as 'runtime'."
-                )
-                return False
-        elif os_name == 'fuchsia':
-            if HOST_OS != 'linux':
-                print("Cross-compilation to %s is not supported on host os %s."
-                      % (os_name, HOST_OS))
-                return False
-            if arch != 'x64':
-                print(
-                    "Cross-compilation to %s is not supported for architecture %s."
-                    % (os_name, arch))
-                return False
-        elif os_name != HOST_OS:
-            print("Unsupported target os %s" % os_name)
-            return False
-    return True
+    other_group.add_argument("-j",
+                             type=int,
+                             help='Ninja -j option for Goma builds.',
+                             default=1000)
+    other_group.add_argument("-l",
+                             type=int,
+                             help='Ninja -l option for Goma builds.',
+                             default=64)
+    other_group.add_argument("--no-start-goma",
+                             help="Don't try to start goma",
+                             default=False,
+                             action='store_true')
+
+    parser.add_argument('build_targets', nargs='*')
+
+    return parser
 
 
 def NotifyBuildDone(build_config, success, start):
@@ -205,49 +115,6 @@
         # Ignore return code, if this command fails, it doesn't matter.
         os.system(command)
 
-
-def GenerateBuildfilesIfNeeded():
-    if os.path.exists(utils.GetBuildDir(HOST_OS)):
-        return True
-    command = [
-        'python',
-        os.path.join(DART_ROOT, 'tools', 'generate_buildfiles.py')
-    ]
-    print("Running " + ' '.join(command))
-    process = subprocess.Popen(command)
-    process.wait()
-    if process.returncode != 0:
-        print("Tried to generate missing buildfiles, but failed. "
-              "Try running manually:\n\t$ " + ' '.join(command))
-        return False
-    return True
-
-
-def RunGNIfNeeded(out_dir, target_os, mode, arch, sanitizer):
-    if os.path.isfile(os.path.join(out_dir, 'args.gn')):
-        return
-    gn_os = 'host' if target_os == HOST_OS else target_os
-    gn_command = [
-        'python',
-        os.path.join(DART_ROOT, 'tools', 'gn.py'),
-        '--sanitizer',
-        sanitizer,
-        '-m',
-        mode,
-        '-a',
-        arch,
-        '--os',
-        gn_os,
-        '-v',
-    ]
-
-    process = subprocess.Popen(gn_command)
-    process.wait()
-    if process.returncode != 0:
-        print("Tried to run GN, but it failed. Try running it manually: \n\t$ "
-              + ' '.join(gn_command))
-
-
 def UseGoma(out_dir):
     args_gn = os.path.join(out_dir, 'args.gn')
     return 'use_goma = true' in open(args_gn, 'r').read()
@@ -296,9 +163,6 @@
     build_config = utils.GetBuildConf(mode, arch, target_os, sanitizer)
     out_dir = utils.GetBuildRoot(HOST_OS, mode, arch, target_os, sanitizer)
     using_goma = False
-    # TODO(zra): Remove auto-run of gn, replace with prompt for user to run
-    # gn.py manually.
-    RunGNIfNeeded(out_dir, target_os, mode, arch, sanitizer)
     command = ['ninja', '-C', out_dir]
     if options.verbose:
         command += ['-v']
@@ -362,17 +226,14 @@
     starttime = time.time()
     # Parse the options.
     parser = BuildOptions()
-    (options, args) = parser.parse_args()
-    if not ProcessOptions(options, args):
-        parser.print_help()
-        return 1
-    # Determine which targets to build. By default we build the "all" target.
-    if len(args) == 0:
-        targets = ['all']
-    else:
-        targets = args
+    options = parser.parse_args()
 
-    if not GenerateBuildfilesIfNeeded():
+    targets = options.build_targets
+    if len(targets) == 0:
+        targets = ['all']
+
+    if not gn_py.ProcessOptions(options):
+        parser.print_help()
         return 1
 
     # If binaries are built with sanitizers we should use those flags.
@@ -381,6 +242,9 @@
     env = dict(os.environ)
     env.update(SanitizerEnvironmentVariables())
 
+    # Always run GN before building.
+    gn_py.RunGnOnConfiguredConfigurations(options)
+
     # Build all targets for each requested configuration.
     configs = []
     for target_os in options.os:
diff --git a/tools/dom/scripts/css_code_generator.py b/tools/dom/scripts/css_code_generator.py
index 2d7ac7b..9b5ccc5 100644
--- a/tools/dom/scripts/css_code_generator.py
+++ b/tools/dom/scripts/css_code_generator.py
@@ -17,6 +17,7 @@
 
 # These are the properties that are supported on all Dart project supported
 # browsers as camelCased names on the CssStyleDeclaration.
+# Note that we do not use the MDN for compatibility info here.
 BROWSER_PATHS = [
     'cssProperties.CSS21.txt',  # Remove when we have samples from all browsers.
     'cssProperties.ie9.txt',
diff --git a/tools/dom/scripts/htmldartgenerator.py b/tools/dom/scripts/htmldartgenerator.py
index f7797fd..08c65a8 100644
--- a/tools/dom/scripts/htmldartgenerator.py
+++ b/tools/dom/scripts/htmldartgenerator.py
@@ -16,6 +16,7 @@
     removed_html_members
 from generator import TypeOrVar
 import logging
+from mdnreader import MDNReader
 import monitored
 import sys
 
@@ -49,6 +50,7 @@
         self._renamer = options.renamer
         self._metadata = options.metadata
         self._library_name = self._renamer.GetLibraryName(self._interface)
+        self._mdn_reader = MDNReader()
         _logger.setLevel(logger.level)
 
     def EmitSupportCheck(self):
@@ -318,10 +320,7 @@
             attribute.type.nullable = True
 
         if declare_only:
-            self.DeclareAttribute(attribute,
-                                  self.SecureOutputType(attribute.type.id,
-                                    nullable=attribute.type.nullable),
-                                  attr_name, read_only)
+            self.DeclareAttribute(attribute, attr_name, read_only)
         else:
             self.EmitAttribute(attribute, attr_name, read_only)
 
@@ -824,7 +823,7 @@
                 'throw new UnsupportedError("Not supported"); }\n',
                 CLASSNAME=self._interface_type_info.implementation_name())
 
-    def DeclareAttribute(self, attribute, type_name, attr_name, read_only):
+    def DeclareAttribute(self, attribute, attr_name, read_only):
         """ Declares an attribute but does not include the code to invoke it.
     """
         if read_only:
@@ -837,9 +836,16 @@
                 template = '\n  $TYPE get $NAME;\n'
         else:
             template = '\n  $TYPE get $NAME native;\n' \
-                       '\n  void set $NAME native;\n'
+                       '\n  set $NAME($TYPE value) native;\n'
 
-        self._members_emitter.Emit(template, NAME=attr_name, TYPE=type_name)
+        # Nullability is determined by attribute compatibility.
+        is_compat = self._mdn_reader.is_compatible(attribute)
+        nullable = attribute.type.nullable or not is_compat
+
+        self._members_emitter.Emit(template,
+                                   NAME=attr_name,
+                                   TYPE=self.SecureOutputType(
+                                       attribute.type.id, nullable=nullable))
 
     def DeclareOperation(self, operation, return_type_name, method_name):
         """ Declares an operation but does not include the code to invoke it.
diff --git a/tools/dom/scripts/htmlrenamer.py b/tools/dom/scripts/htmlrenamer.py
index 623f5e9..014e811 100644
--- a/tools/dom/scripts/htmlrenamer.py
+++ b/tools/dom/scripts/htmlrenamer.py
@@ -387,7 +387,6 @@
         # Not prefixed but requires custom implementation for cross-browser compatibility.
         'Document.visibilityState',
         'Element.animate',
-        'Element.children',
         'Element.childElementCount',
         'Element.firstElementChild',
         'Element.getClientRects',
@@ -791,6 +790,7 @@
         'DOMException.WRONG_DOCUMENT_ERR',
         'Element.accessKey',
         'Element.append',
+        'Element.children',
         'Element.dataset',
         'Element.get:classList',
         'Element.getAttributeNode',
diff --git a/tools/dom/scripts/idlnode.py b/tools/dom/scripts/idlnode.py
index 6ce89a5..475b759 100644
--- a/tools/dom/scripts/idlnode.py
+++ b/tools/dom/scripts/idlnode.py
@@ -55,7 +55,6 @@
     '__delete__': "Deleter",
 }
 
-
 class IDLNode(object):
     """Base class for all IDL elements.
   IDLNode may contain various child nodes, and have properties. Examples
@@ -825,7 +824,7 @@
        void forEach(any callback, optional any thisArg);
        boolean has(FontFace fontFace);
        boolean has(FontFace fontFace);
-  
+
   if setlike is not read-only these operations are generated:
 
            FontFaceSet add(FontFace value);
@@ -837,10 +836,10 @@
   Need to create a typedef for a function callback e.g.,
   a setlike will need a callback that has the proper args in FontFaceSet that is
   three arguments, etc.
-  
+
       typedef void FontFaceSetForEachCallback(
         FontFace fontFace, FontFace fontFaceAgain, FontFaceSet set);
-    
+
       void forEach(FontFaceSetForEachCallback callback, [Object thisArg]);
   """
     callback_name = '%sForEachCallback' % interface.id
@@ -1046,7 +1045,6 @@
             a.type for a in operation.arguments
         ]
 
-
 class IDLAttribute(IDLMember):
     """IDLNode specialization for 'attribute type name' declarations."""
 
diff --git a/tools/dom/scripts/mdnreader.py b/tools/dom/scripts/mdnreader.py
new file mode 100644
index 0000000..b748d1f
--- /dev/null
+++ b/tools/dom/scripts/mdnreader.py
@@ -0,0 +1,189 @@
+#!/usr/bin/python
+# 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 json
+import os.path
+import sys
+
+
+def _get_browser_compat_data():
+    current_dir = os.path.dirname(__file__)
+
+    browser_compat_folder = os.path.abspath(
+        os.path.join(current_dir, '..', '..', '..', 'third_party', 'mdn',
+                     'browser-compat-data', 'src'))
+
+    if not os.path.exists(browser_compat_folder):
+        raise RuntimeError('Browser compatibility data not found at %s' %
+                           browser_compat_folder)
+
+    browser_compat_data = {}
+
+    INCLUDE_DIRS = [
+        'api',
+        'html',
+        'svg',
+        # TODO(srujzs): add more if needed
+    ]
+
+    # Transform to absolute paths
+    INCLUDE_DIRS = [
+        os.path.join(browser_compat_folder, dir) for dir in INCLUDE_DIRS
+    ]
+
+    def process_json_dict(json_dict):
+        # Returns a tuple of the interface name and the metadata corresponding
+        # to it.
+        if 'api' in json_dict:
+            # Get the interface name
+            api_dict = json_dict['api']
+            interface_name = api_dict.keys()[0]
+            return (interface_name, api_dict[interface_name])
+        elif 'html' in json_dict:
+            html_dict = json_dict['html']
+            if 'elements' in html_dict:
+                elements_dict = html_dict['elements']
+                element_name = elements_dict.keys()[0]
+                # Convert to WebCore name
+                interface = str('HTML' + element_name + 'Element')
+                return (interface, elements_dict[element_name])
+        elif 'svg' in json_dict:
+            svg_dict = json_dict['svg']
+            if 'elements' in svg_dict:
+                elements_dict = svg_dict['elements']
+                element_name = elements_dict.keys()[0]
+                # Convert to WebCore name
+                interface = str('SVG' + element_name + 'Element')
+                return (interface, elements_dict[element_name])
+        return (None, None)
+
+    def visitor(arg, dir_path, names):
+
+        def should_process_dir(dir_path):
+            if os.path.abspath(dir_path) == browser_compat_folder:
+                return True
+            for dir in INCLUDE_DIRS:
+                if dir_path.startswith(dir):
+                    return True
+            return False
+
+        if should_process_dir(dir_path):
+            for name in names:
+                file_name = os.path.join(dir_path, name)
+                (interface_path, ext) = os.path.splitext(file_name)
+                if ext == '.json':
+                    with open(file_name) as src:
+                        json_dict = json.load(src)
+                        interface, metadata = process_json_dict(json_dict)
+                        if not interface is None:
+                            # Note: interface and member names do not
+                            # necessarily have the same capitalization as
+                            # WebCore, so we keep them all lowercase for easier
+                            # matching later.
+                            interface = interface.lower()
+                            metadata = {
+                                member.lower(): info
+                                for member, info in metadata.items()
+                            }
+
+                            if interface in browser_compat_data:
+                                browser_compat_data[interface].update(metadata)
+                            else:
+                                browser_compat_data[interface] = metadata
+        else:
+            names[:] = []  # Do not go underneath
+
+    os.path.walk(browser_compat_folder, visitor, browser_compat_folder)
+
+    return browser_compat_data
+
+
+class MDNReader(object):
+    # Statically initialize and treat as constant.
+    _BROWSER_COMPAT_DATA = _get_browser_compat_data()
+
+    def __init__(self):
+        self._compat_overrides = {}
+
+    def _get_attr_compatibility(self, compat_data):
+        # Parse schema syntax of MDN data:
+        # https://github.com/mdn/browser-compat-data/blob/master/schemas/compat-data.schema.json
+
+        # For now, we will require support for browsers since the last IDL roll.
+        # TODO(srujzs): Determine if this is too conservative.
+        browser_version_map = {
+            'chrome': 63,
+            'firefox': 57,
+            'safari': 11,
+            # We still support the latest version of IE.
+            'ie': 11,
+            'opera': 50,
+        }
+        version_key = 'version_added'
+        for browser in browser_version_map.keys():
+            support_data = compat_data['support']
+            if browser not in support_data:
+                return False
+            support_statement = support_data[browser]
+            if isinstance(support_statement, list):  # array_support_statement
+                # TODO(srujzs): Parse this list to determine compatibility. Will
+                # likely require parsing for 'version_removed' keys. Notes about
+                # which browser version enabled this attribute for which
+                # platform also complicates things. For now, we assume it's not
+                # compatible.
+                return False
+            if len(support_statement.keys()) > 1:
+                # If it's anything more complicated than 'version_added', like
+                # 'notes' that specify platform versions, we assume it's not
+                # compatible.
+                return False
+            version = support_statement[version_key]
+            if not version or browser_version_map[browser] < float(version):
+                # simple_support_statement
+                return False
+            # If the attribute is experimental, we assume it's not compatible.
+            status_data = compat_data['status']
+            experimental_key = 'experimental'
+            if experimental_key in status_data and \
+                status_data[experimental_key]:
+                return False
+        return True
+
+    def is_compatible(self, attribute):
+        # Since capitalization isn't consistent across MDN and WebCore, we
+        # compare lowercase equivalents for interface and attribute names.
+        interface = attribute.doc_js_interface_name.lower()
+        if interface in self._BROWSER_COMPAT_DATA and attribute.id and len(
+                attribute.id) > 0:
+            interface_dict = self._BROWSER_COMPAT_DATA[interface]
+            id_name = attribute.id.lower()
+            secure_context_key = 'isSecureContext'
+            if interface in self._compat_overrides and id_name in self._compat_overrides[
+                    interface]:
+                return self._compat_overrides[interface][id_name]
+            elif secure_context_key in interface_dict:
+                # If the interface requires a secure context, all attributes are
+                # implicitly incompatible.
+                return False
+            elif id_name in interface_dict:
+                id_data = interface_dict[id_name]
+                return self._get_attr_compatibility(id_data['__compat'])
+            else:
+                # Might be an attribute that is defined in a parent interface.
+                # We defer until attribute emitting to determine if this is the
+                # case. Otherwise, return None.
+                pass
+        return None
+
+    def set_compatible(self, attribute, compatible):
+        # Override value in the MDN browser compatibility data.
+        if not compatible in [True, False, None]:
+            raise ValueError('Cannot set a non-boolean object for compatible')
+        interface = attribute.doc_js_interface_name.lower()
+        if not interface in self._compat_overrides:
+            self._compat_overrides[interface] = {}
+        if attribute.id and len(attribute.id) > 0:
+            id_name = attribute.id.lower()
+            self._compat_overrides[interface][id_name] = compatible
diff --git a/tools/dom/scripts/systemhtml.py b/tools/dom/scripts/systemhtml.py
index 5948de3..0761fe6 100644
--- a/tools/dom/scripts/systemhtml.py
+++ b/tools/dom/scripts/systemhtml.py
@@ -1141,6 +1141,22 @@
         return promise_attributes[interface_operation]
     return None
 
+# Compatibility is used to help determine attribute nullability i.e. if the
+# attribute is not compatible across all browsers, the getter/setter is marked
+# as nullable. There are cases where the attribute belongs to a class that
+# implements an interface whose methods are not in the IDL, however.
+# Since attribute getters need to match their overridden method declaration,
+# there are conflicts when the overriding method is not compatible, the
+# overriding method is, and they're not already nullable. This dict marks the
+# attributes where there is a conflict that cannot be resolved with code
+# generation or within src/template files.
+compat_conflicts = {
+    # These interfaces implement Rectangle, which is a Dart interface. In order
+    # to match the interface of Rectangle, they must be marked as non-nullable.
+    'DOMRectReadOnly': ['bottom', 'height', 'left', 'right', 'top', 'width'],
+    'DOMRect': ['height', 'width'],
+}
+
 
 class Dart2JSBackend(HtmlDartGenerator):
     """Generates a dart2js class for the dart:html library from a DOM IDL
@@ -1394,6 +1410,8 @@
         metadata = self._Metadata(attribute.type.id, attribute.id, output_type,
             attribute.type.nullable)
 
+        is_compat = self._mdn_reader.is_compatible(attribute)
+
         # If the attribute is shadowing, we can't generate a shadowing
         # getter or setter (Issue 1633).
         # TODO(sra): _FindShadowedAttribute does not take into account the html
@@ -1406,10 +1424,18 @@
          super_attribute_interface) = self._FindShadowedAttribute(attribute)
 
         if super_attribute:
+            if is_compat is None:
+                # If there is no compatibility info on this attribute, we use
+                # the parent attribute's compatibility info.
+                is_compat = self._mdn_reader.is_compatible(super_attribute)
+                self._mdn_reader.set_compatible(attribute, is_compat)
             if read_only or self._SafeToIgnoreShadowingMember(html_name):
                 if attribute.type.id == super_attribute.type.id:
                     # Compatible attribute, use the superclass property.  This
                     # works because JavaScript will do its own dynamic dispatch.
+
+                    # Nullability is determined by attribute compatibility.
+                    nullable = not is_compat or attribute.type.nullable
                     self._members_emitter.Emit(
                         '\n'
                         '  // Use implementation from $SUPER.\n'
@@ -1419,10 +1445,10 @@
                         NAME=html_name,
                         GET_TYPE=self.SecureOutputType(attribute.type.id,
                             can_narrow_type=read_only,
-                            nullable=attribute.type.nullable),
+                            nullable=nullable),
                         SET_TYPE=self.SecureOutputType(attribute.type.id,
                             can_narrow_type=read_only,
-                            nullable=attribute.type.nullable or \
+                            nullable=nullable or \
                                 'TreatNullAs' in attribute.ext_attrs))
                     return
             self._members_emitter.Emit('\n  // Shadowing definition.')
@@ -1452,7 +1478,7 @@
             return
 
         input_type = self._NarrowInputType(attribute.type.id)
-        if attribute.type.nullable:
+        if attribute.type.nullable or not is_compat:
             input_type += '?'
         if not read_only:
             if attribute.type.id == 'Promise':
@@ -1519,6 +1545,20 @@
                     self._AddAttributeUsingProperties(attribute, html_name,
                         read_only, rename, metadata)
 
+    def _IsACompatibilityConflict(self, interface, attr):
+        if interface in compat_conflicts and attr.id in compat_conflicts[
+                interface]:
+            is_compat = self._mdn_reader.is_compatible(attr)
+            if is_compat or attr.type.nullable:
+                # Only attributes that are not compatible and not nullable
+                # belong in this list.
+                raise ValueError(
+                    interface + '.' + attr.id +
+                    ' has no conflict between compatibility and nullability.')
+            else:
+                return True
+        return False
+
     def _AddAttributeUsingProperties(self, attribute, html_name, read_only,
                                      rename=None, metadata=None):
         self._AddRenamingGetter(attribute, html_name, rename, metadata)
@@ -1530,18 +1570,38 @@
         conversion = self._OutputConversion(attr.type.id, attr.id)
         if conversion:
             return self._AddConvertingGetter(attr, html_name, conversion)
+        # If the attribute is incompatible, it must be marked nullable.
+        is_compat = self._mdn_reader.is_compatible(attr)
         return_type = self.SecureOutputType(attr.type.id,
-            nullable=attr.type.nullable)
-        self._members_emitter.Emit(
-            '\n  $RENAME'
-            '\n  $METADATA'
-            '\n  $STATIC $TYPE get $HTML_NAME native;'
-            '\n',
-            RENAME=rename if rename else '',
-            METADATA=metadata if metadata else '',
-            HTML_NAME=html_name,
-            STATIC='static' if attr.is_static else '',
-            TYPE=return_type)
+                                            nullable=(not is_compat) or
+                                            attr.type.nullable)
+        native_type = self._NarrowToImplementationType(attr.type.id)
+        non_null_return_type = self.SecureOutputType(attr.type.id,
+                                                     nullable=False)
+        if self._IsACompatibilityConflict(self._interface.id, attr):
+            if not rename:
+                rename = '@JSName(\'%s\')' % html_name
+            template = """\n
+                // The following getter is incompatible with some browsers but
+                // must be made non-nullable to match the overridden method.
+                \n  $RENAME
+                \n  $METADATA
+                \n  $STATIC $TYPE get _$HTML_NAME native;
+                \n
+                \n  $STATIC $NONNULLTYPE get $HTML_NAME => _$HTML_NAME$NULLASSERT;"""
+        else:
+            template = """\n  $RENAME
+                \n  $METADATA
+                \n  $STATIC $TYPE get $HTML_NAME native;
+                \n"""
+        self._members_emitter.Emit(template,
+                                   RENAME=rename if rename else '',
+                                   METADATA=metadata if metadata else '',
+                                   HTML_NAME=html_name,
+                                   STATIC='static' if attr.is_static else '',
+                                   TYPE=return_type,
+                                   NULLASSERT='!',
+                                   NONNULLTYPE=non_null_return_type)
 
     def _AddRenamingSetter(self, attr, html_name, rename):
         conversion = self._InputConversion(attr.type.id, attr.id)
@@ -1552,8 +1612,13 @@
         # converting getter. We need to make sure the setter type matches the
         # getter type.
         conversion = self._OutputConversion(attr.type.id, attr.id)
-        if conversion and conversion.nullable_output:
+        # If the attribute is incompatible, it must be marked nullable.
+        is_compat = self._mdn_reader.is_compatible(attr)
+        if (conversion and conversion.nullable_output) or not is_compat:
             nullable_type = True
+        if self._IsACompatibilityConflict(self._interface.id, attr):
+            # Force non-nullable if it's a manual conflict.
+            nullable_type = False
         self._members_emitter.Emit(
             '\n  $RENAME'
             '\n  $STATIC set $HTML_NAME($TYPE value) native;'
@@ -1564,10 +1629,12 @@
             TYPE=self.SecureOutputType(attr.type.id, nullable=nullable_type))
 
     def _AddConvertingGetter(self, attr, html_name, conversion):
+        # dynamic should not be marked with ?
         nullable_out = conversion.nullable_output and \
             not conversion.output_type == 'dynamic'
-        # If the attribute is nullable, the getter should be nullable.
-        nullable_in = attr.type.nullable and \
+        # Nullability is determined by attribute compatibility.
+        is_compat = self._mdn_reader.is_compatible(attr)
+        nullable_in = (not is_compat or attr.type.nullable) and \
             not conversion.input_type == 'dynamic'
         self._members_emitter.Emit(
             '\n  $(METADATA)$RETURN_TYPE$NULLABLE_OUT get $HTML_NAME => '
@@ -1591,9 +1658,11 @@
                 not conversion.nullable_input else '')
 
     def _AddConvertingSetter(self, attr, html_name, conversion):
+        # If the attribute is incompatible, it must be marked nullable.
+        is_compat = self._mdn_reader.is_compatible(attr)
         # If the attribute is nullable, the setter should be nullable.
-        nullable_in = (attr.type.nullable or 'TreatNullAs' in attr.ext_attrs) \
-            and not conversion.input_type == 'dynamic'
+        nullable_in = ((attr.type.nullable or 'TreatNullAs' in attr.ext_attrs) \
+            and not conversion.input_type == 'dynamic') or not is_compat
         nullable_out = conversion.nullable_output and \
             not conversion.output_type == 'dynamic'
         self._members_emitter.Emit(
diff --git a/tools/dom/src/AttributeMap.dart b/tools/dom/src/AttributeMap.dart
index 88f3bd4..2dfccca 100644
--- a/tools/dom/src/AttributeMap.dart
+++ b/tools/dom/src/AttributeMap.dart
@@ -47,12 +47,12 @@
 
   Iterable<String> get keys {
     // TODO: generate a lazy collection instead.
-    var attributes = _element._attributes;
+    var attributes = _element._attributes!;
     var keys = <String>[];
     for (int i = 0, len = attributes.length; i < len; i++) {
       _Attr attr = attributes[i] as _Attr;
       if (_matches(attr)) {
-        keys.add(attr.name);
+        keys.add(attr.name!);
       }
     }
     return keys;
@@ -60,12 +60,12 @@
 
   Iterable<String> get values {
     // TODO: generate a lazy collection instead.
-    var attributes = _element._attributes;
+    var attributes = _element._attributes!;
     var values = <String>[];
     for (int i = 0, len = attributes.length; i < len; i++) {
       _Attr attr = attributes[i] as _Attr;
       if (_matches(attr)) {
-        values.add(attr.value);
+        values.add(attr.value!);
       }
     }
     return values;
diff --git a/tools/dom/src/CrossFrameTypes.dart b/tools/dom/src/CrossFrameTypes.dart
index 7d210a3..72113cf 100644
--- a/tools/dom/src/CrossFrameTypes.dart
+++ b/tools/dom/src/CrossFrameTypes.dart
@@ -51,8 +51,11 @@
    *     print(window.closed); // 'false'
    *     window.close();
    *     print(window.closed); // 'true'
+   *
+   * MDN does not have compatibility info on this attribute, and therefore is
+   * marked nullable.
    */
-  bool get closed;
+  bool? get closed;
 
   /**
    * A reference to the window that opened this one.
diff --git a/tools/dom/src/Validators.dart b/tools/dom/src/Validators.dart
index a498da9..0c45b8c 100644
--- a/tools/dom/src/Validators.dart
+++ b/tools/dom/src/Validators.dart
@@ -299,7 +299,7 @@
 
     if (element is TemplateElement) {
       TemplateElement template = element;
-      sanitizeTree(template.content);
+      sanitizeTree(template.content!);
     }
   }
 
diff --git a/tools/dom/src/dart2js_KeyEvent.dart b/tools/dom/src/dart2js_KeyEvent.dart
index 422c7ad..368ebf0 100644
--- a/tools/dom/src/dart2js_KeyEvent.dart
+++ b/tools/dom/src/dart2js_KeyEvent.dart
@@ -188,12 +188,12 @@
   static EventStreamProvider<KeyEvent> keyPressEvent =
       new _KeyboardEventHandler('keypress');
 
-  String get code => _parent.code;
+  String get code => _parent.code!;
   /** True if the ctrl key is pressed during this event. */
   bool get ctrlKey => _parent.ctrlKey;
-  int get detail => _parent.detail;
-  bool get isComposing => _parent.isComposing;
-  String get key => _parent.key;
+  int get detail => _parent.detail!;
+  bool get isComposing => _parent.isComposing!;
+  String get key => _parent.key!;
   /**
    * Accessor to the part of the keyboard that the key was pressed from (one of
    * KeyLocation.STANDARD, KeyLocation.RIGHT, KeyLocation.LEFT,
diff --git a/tools/dom/src/dart2js_WrappedEvent.dart b/tools/dom/src/dart2js_WrappedEvent.dart
index dff9e38..e9fb697 100644
--- a/tools/dom/src/dart2js_WrappedEvent.dart
+++ b/tools/dom/src/dart2js_WrappedEvent.dart
@@ -15,11 +15,11 @@
 
   _WrappedEvent(this.wrapped);
 
-  bool get bubbles => wrapped.bubbles;
+  bool get bubbles => wrapped.bubbles!;
 
-  bool get cancelable => wrapped.cancelable;
+  bool get cancelable => wrapped.cancelable!;
 
-  bool get composed => wrapped.composed;
+  bool get composed => wrapped.composed!;
 
   EventTarget? get currentTarget => wrapped.currentTarget;
 
@@ -27,7 +27,7 @@
 
   int get eventPhase => wrapped.eventPhase;
 
-  bool get isTrusted => wrapped.isTrusted;
+  bool get isTrusted => wrapped.isTrusted!;
 
   EventTarget? get target => wrapped.target;
 
diff --git a/tools/dom/templates/html/dart2js/impl_KeyboardEvent.darttemplate b/tools/dom/templates/html/dart2js/impl_KeyboardEvent.darttemplate
index aa5f3e1..db348f6 100644
--- a/tools/dom/templates/html/dart2js/impl_KeyboardEvent.darttemplate
+++ b/tools/dom/templates/html/dart2js/impl_KeyboardEvent.darttemplate
@@ -67,6 +67,6 @@
 
   int get charCode native;
 
-  int get which => _which;
+  int$NULLABLE get which => _which;
 $!MEMBERS
 }
diff --git a/tools/dom/templates/html/dart2js/impl_MouseEvent.darttemplate b/tools/dom/templates/html/dart2js/impl_MouseEvent.darttemplate
index d847db4..921abae 100644
--- a/tools/dom/templates/html/dart2js/impl_MouseEvent.darttemplate
+++ b/tools/dom/templates/html/dart2js/impl_MouseEvent.darttemplate
@@ -27,7 +27,7 @@
 
   @SupportedBrowser(SupportedBrowser.CHROME)
   @SupportedBrowser(SupportedBrowser.FIREFOX)
-  Point get movement => new Point(_movementX, _movementY);
+  Point get movement => new Point(_movementX$NULLASSERT, _movementY$NULLASSERT);
 
   /**
    * The coordinates of the mouse pointer in target node coordinates.
@@ -55,9 +55,9 @@
 
   Point get screen => new Point(_screenX, _screenY);
 
-  Point get layer => new Point(_layerX, _layerY);
+  Point get layer => new Point(_layerX$NULLASSERT, _layerY$NULLASSERT);
 
-  Point get page => new Point(_pageX, _pageY);
+  Point get page => new Point(_pageX$NULLASSERT, _pageY$NULLASSERT);
 
   DataTransfer get dataTransfer => JS('DataTransfer', "#['dataTransfer']", this);
 
diff --git a/tools/dom/templates/html/impl/impl_DataTransferItem.darttemplate b/tools/dom/templates/html/impl/impl_DataTransferItem.darttemplate
index a74989b..ca64994 100644
--- a/tools/dom/templates/html/impl/impl_DataTransferItem.darttemplate
+++ b/tools/dom/templates/html/impl/impl_DataTransferItem.darttemplate
@@ -9,9 +9,9 @@
   Entry getAsEntry() {
     Entry entry = _webkitGetAsEntry() $#NULLSAFECAST(as Entry);
 
-    if (entry.isFile)
+    if (entry.isFile$NULLASSERT)
       applyExtension('FileEntry', entry);
-    else if (entry.isDirectory)
+    else if (entry.isDirectory$NULLASSERT)
       applyExtension('DirectoryEntry', entry);
     else
       applyExtension('Entry', entry);
diff --git a/tools/dom/templates/html/impl/impl_DirectoryReader.darttemplate b/tools/dom/templates/html/impl/impl_DirectoryReader.darttemplate
index 06eba12..b643159 100644
--- a/tools/dom/templates/html/impl/impl_DirectoryReader.darttemplate
+++ b/tools/dom/templates/html/impl/impl_DirectoryReader.darttemplate
@@ -12,10 +12,10 @@
     _readEntries((values) {
       values.forEach((value) {
         applyExtension('Entry', value);
-        Entry entry = value as Entry;  
-        if (entry.isFile)
+        Entry entry = value as Entry;
+        if (entry.isFile$NULLASSERT)
           applyExtension('FileEntry', entry);
-        else if (entry.isDirectory)
+        else if (entry.isDirectory$NULLASSERT)
           applyExtension('DirectoryEntry', entry);
       });
       completer.complete(new List<Entry>.from(values));
diff --git a/tools/dom/templates/html/impl/impl_DocumentFragment.darttemplate b/tools/dom/templates/html/impl/impl_DocumentFragment.darttemplate
index 22b74d9..6a219f3 100644
--- a/tools/dom/templates/html/impl/impl_DocumentFragment.darttemplate
+++ b/tools/dom/templates/html/impl/impl_DocumentFragment.darttemplate
@@ -60,7 +60,12 @@
   ElementList<T> querySelectorAll<T extends Element>(String selectors) =>
     new _FrozenElementList<T>._wrap(_querySelectorAll(selectors));
 
-  String get innerHtml {
+$if NNBD
+  // innerHtml is marked as nullable, even though it is guaranteed to return a
+  // non-nullable, because ShadowRoot.innerHtml overrides it and can be
+  // incompatible.
+$endif
+  String$NULLABLE get innerHtml {
     final e = new DivElement();
     e.append(this.clone(true));
     return e.innerHtml;
diff --git a/tools/dom/templates/html/impl/impl_Element.darttemplate b/tools/dom/templates/html/impl/impl_Element.darttemplate
index bdca7ed..935f5d8 100644
--- a/tools/dom/templates/html/impl/impl_Element.darttemplate
+++ b/tools/dom/templates/html/impl/impl_Element.darttemplate
@@ -46,6 +46,10 @@
   Iterator<Element> get iterator => toList().iterator;
 
   void addAll(Iterable<Element> iterable) {
+    _addAll(_element, iterable);
+  }
+
+  static void _addAll(Element _element, Iterable<Element> iterable) {
     if (iterable is _ChildNodeListLazy) {
       iterable = new List.from(iterable);
     }
@@ -99,6 +103,10 @@
   }
 
   bool remove(Object$NULLABLE object) {
+    return _remove(_element, object);
+  }
+
+  static bool _remove(Element _element, Object$NULLABLE object) {
     if (object is Element) {
       Element element = object;
       if (identical(element.parentNode, _element)) {
@@ -149,7 +157,10 @@
     return result;
   }
 
-  Element get first {
+  Element get first => _first(_element);
+
+  @pragma('dart2js:noInline')
+  static Element _first(Element _element) {
     Element$NULLABLE result = _element._firstElementChild;
     if (result == null) throw new StateError("No elements");
     return result;
@@ -667,6 +678,15 @@
    */
   List<Element> get children => new _ChildrenElementList._wrap(this);
 
+  List<Node> get _children =>
+      // Element.children always returns the same list-like object which is a
+      // live view on the underlying DOM tree. So we can GVN it and remove it if
+      // unused.
+      JS('returns:HtmlCollection;creates:HtmlCollection;'
+             'depends:none;effects:none;gvn:true',
+         '#.children',
+         this);
+
   set children(List<Element> value) {
     // Copy list first since we don't want liveness during iteration.
     var copy = value.toList();
@@ -805,8 +825,8 @@
   /**
    * Gets the position of this element relative to the client area of the page.
    */
-  Rectangle get client => new Rectangle(clientLeft, clientTop, clientWidth,
-      clientHeight);
+  Rectangle get client => new Rectangle(clientLeft$NULLASSERT,
+      clientTop$NULLASSERT, clientWidth, clientHeight);
 
   /**
    * Gets the offset of this element relative to its offsetParent.
@@ -1346,14 +1366,14 @@
     }
 
     if (_parseDocument == null) {
-      _parseDocument = document.implementation.createHtmlDocument('');
+      _parseDocument = document.implementation$NULLASSERT.createHtmlDocument('');
       _parseRange = _parseDocument$NULLASSERT.createRange();
 
       // Workaround for Safari bug. Was also previously Chrome bug 229142
       // - URIs are not resolved in new doc.
       BaseElement base =
           _parseDocument$NULLASSERT.createElement('base') $#NULLSAFECAST(as BaseElement);
-      base.href = document.baseUri;
+      base.href = document.baseUri$NULLASSERT;
       _parseDocument$NULLASSERT.head$NULLASSERT.append(base);
     }
 
@@ -1456,7 +1476,7 @@
           treeSanitizer: treeSanitizer));
     }
   }
-  String get innerHtml => _innerHtml;
+  String$NULLABLE get innerHtml => _innerHtml;
 
   @JSName('innerText')
   String get innerText native;
diff --git a/tools/dom/templates/html/impl/impl_HTMLDocument.darttemplate b/tools/dom/templates/html/impl/impl_HTMLDocument.darttemplate
index 5da7c9b..4f2bd81 100644
--- a/tools/dom/templates/html/impl/impl_HTMLDocument.darttemplate
+++ b/tools/dom/templates/html/impl/impl_HTMLDocument.darttemplate
@@ -24,7 +24,7 @@
 
   HeadElement$NULLABLE get head => _head;
 
-  String get lastModified => _lastModified;
+  String$NULLABLE get lastModified => _lastModified;
 
   String$NULLABLE get preferredStylesheetSet => _preferredStylesheetSet;
 
@@ -35,7 +35,7 @@
     _selectedStylesheetSet = value;
   }
 
-  List<StyleSheet> get styleSheets => _styleSheets;
+  List<StyleSheet>$NULLABLE get styleSheets => _styleSheets;
 
   String get title => _title;
 
diff --git a/tools/dom/templates/html/impl/impl_HTMLInputElement.darttemplate b/tools/dom/templates/html/impl/impl_HTMLInputElement.darttemplate
index f2005af..19aa838 100644
--- a/tools/dom/templates/html/impl/impl_HTMLInputElement.darttemplate
+++ b/tools/dom/templates/html/impl/impl_HTMLInputElement.darttemplate
@@ -53,22 +53,22 @@
   bool get autofocus;
   set autofocus(bool value);
 
-  bool get disabled;
-  set disabled(bool value);
+  bool$NULLABLE get disabled;
+  set disabled(bool$NULLABLE value);
 
-  bool get incremental;
-  set incremental(bool value);
+  bool$NULLABLE get incremental;
+  set incremental(bool$NULLABLE value);
 
-  bool get indeterminate;
-  set indeterminate(bool value);
+  bool$NULLABLE get indeterminate;
+  set indeterminate(bool$NULLABLE value);
 
-  String get name;
-  set name(String value);
+  String$NULLABLE get name;
+  set name(String$NULLABLE value);
 
-  String get value;
+  String$NULLABLE get value;
   set value(String$NULLABLE value);
 
-  List<Node> get labels;
+  List<Node>$NULLABLE get labels;
 
   String get validationMessage;
 
@@ -96,8 +96,8 @@
   String get autocomplete;
   set autocomplete(String value);
 
-  int get maxLength;
-  set maxLength(int value);
+  int$NULLABLE get maxLength;
+  set maxLength(int$NULLABLE value);
 
   String get pattern;
   set pattern(String value);
@@ -105,14 +105,14 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
 
-  int get size;
-  set size(int value);
+  int$NULLABLE get size;
+  set size(int$NULLABLE value);
 
   void select();
 
@@ -141,8 +141,8 @@
 abstract class SearchInputElement implements TextInputElementBase {
   factory SearchInputElement() => new InputElement(type: 'search');
 
-  String get dirName;
-  set dirName(String value);
+  String$NULLABLE get dirName;
+  set dirName(String$NULLABLE value);
 
   Element$NULLABLE get list;
 
@@ -158,8 +158,8 @@
 abstract class TextInputElement implements TextInputElementBase {
   factory TextInputElement() => new InputElement(type: 'text');
 
-  String get dirName;
-  set dirName(String value);
+  String$NULLABLE get dirName;
+  set dirName(String$NULLABLE value);
 
   Element$NULLABLE get list;
 }
@@ -227,11 +227,11 @@
 
   Element$NULLABLE get list;
 
-  int get maxLength;
-  set maxLength(int value);
+  int$NULLABLE get maxLength;
+  set maxLength(int$NULLABLE value);
 
-  bool get multiple;
-  set multiple(bool value);
+  bool$NULLABLE get multiple;
+  set multiple(bool$NULLABLE value);
 
   String get pattern;
   set pattern(String value);
@@ -239,14 +239,14 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
 
-  int get size;
-  set size(int value);
+  int$NULLABLE get size;
+  set size(int$NULLABLE value);
 
   /// Returns true if this input type is supported on the current platform.
   static bool get supported {
@@ -268,17 +268,17 @@
 
   Element$NULLABLE get list;
 
-  String get max;
-  set max(String value);
+  String$NULLABLE get max;
+  set max(String$NULLABLE value);
 
-  String get min;
-  set min(String value);
+  String$NULLABLE get min;
+  set min(String$NULLABLE value);
 
-  String get step;
-  set step(String value);
+  String$NULLABLE get step;
+  set step(String$NULLABLE value);
 
-  num get valueAsNumber;
-  set valueAsNumber(num value);
+  num$NULLABLE get valueAsNumber;
+  set valueAsNumber(num$NULLABLE value);
 
   void stepDown([int$NULLABLE n]);
 
@@ -297,8 +297,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -321,8 +321,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -345,8 +345,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -369,8 +369,8 @@
   DateTime get valueAsDate;
   set valueAsDate(DateTime value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -392,8 +392,8 @@
   factory LocalDateTimeInputElement() =>
       new InputElement(type: 'datetime-local');
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -416,8 +416,8 @@
   String get placeholder;
   set placeholder(String value);
 
-  bool get readOnly;
-  set readOnly(bool value);
+  bool$NULLABLE get readOnly;
+  set readOnly(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -454,8 +454,8 @@
 abstract class CheckboxInputElement implements InputElementBase {
   factory CheckboxInputElement() => new InputElement(type: 'checkbox');
 
-  bool get checked;
-  set checked(bool value);
+  bool$NULLABLE get checked;
+  set checked(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -476,8 +476,8 @@
 abstract class RadioButtonInputElement implements InputElementBase {
   factory RadioButtonInputElement() => new InputElement(type: 'radio');
 
-  bool get checked;
-  set checked(bool value);
+  bool$NULLABLE get checked;
+  set checked(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -489,11 +489,11 @@
 abstract class FileUploadInputElement implements InputElementBase {
   factory FileUploadInputElement() => new InputElement(type: 'file');
 
-  String get accept;
-  set accept(String value);
+  String$NULLABLE get accept;
+  set accept(String$NULLABLE value);
 
-  bool get multiple;
-  set multiple(bool value);
+  bool$NULLABLE get multiple;
+  set multiple(bool$NULLABLE value);
 
   bool get required;
   set required(bool value);
@@ -530,8 +530,8 @@
 abstract class ImageButtonInputElement implements InputElementBase {
   factory ImageButtonInputElement() => new InputElement(type: 'image');
 
-  String get alt;
-  set alt(String value);
+  String$NULLABLE get alt;
+  set alt(String$NULLABLE value);
 
   String get formAction;
   set formAction(String value);
@@ -548,14 +548,14 @@
   String get formTarget;
   set formTarget(String value);
 
-  int get height;
-  set height(int value);
+  int$NULLABLE get height;
+  set height(int$NULLABLE value);
 
-  String get src;
-  set src(String value);
+  String$NULLABLE get src;
+  set src(String$NULLABLE value);
 
-  int get width;
-  set width(int value);
+  int$NULLABLE get width;
+  set width(int$NULLABLE value);
 }
 
 /**
diff --git a/tools/dom/templates/html/impl/impl_HTMLSelectElement.darttemplate b/tools/dom/templates/html/impl/impl_HTMLSelectElement.darttemplate
index 0cb5c45..59cedcb 100644
--- a/tools/dom/templates/html/impl/impl_HTMLSelectElement.darttemplate
+++ b/tools/dom/templates/html/impl/impl_HTMLSelectElement.darttemplate
@@ -16,11 +16,11 @@
 
   List<OptionElement> get selectedOptions {
     // IE does not change the selected flag for single-selection items.
-    if (this.multiple) {
+    if (this.multiple$NULLASSERT) {
       var options = this.options.where((o) => o.selected).toList();
       return new UnmodifiableListView(options);
     } else {
-      return [this.options[this.selectedIndex]];
+      return [this.options[this.selectedIndex$NULLASSERT]];
     }
   }
 }
diff --git a/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate b/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate
index d030d27..3d9b2af 100644
--- a/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate
+++ b/tools/dom/templates/html/impl/impl_HTMLTemplateElement.darttemplate
@@ -20,10 +20,10 @@
     {NodeValidator$NULLABLE validator,
      NodeTreeSanitizer$NULLABLE treeSanitizer}) {
     text = null;
-    content.nodes.clear();
+    content$NULLASSERT.nodes.clear();
     var fragment = createFragment(html, validator: validator,
         treeSanitizer: treeSanitizer);
 
-    content.append(fragment);
+    content$NULLASSERT.append(fragment);
   }
 }
diff --git a/tools/dom/templates/html/impl/impl_SVGElement.darttemplate b/tools/dom/templates/html/impl/impl_SVGElement.darttemplate
index ca93287..7445a9b 100644
--- a/tools/dom/templates/html/impl/impl_SVGElement.darttemplate
+++ b/tools/dom/templates/html/impl/impl_SVGElement.darttemplate
@@ -68,14 +68,14 @@
     children.addAll(value);
   }
 
-  String get outerHtml {
+  String$NULLABLE get outerHtml {
     final container = new DivElement();
     final SvgElement cloned = this.clone(true) $#NULLSAFECAST(as SvgElement);
     container.children.add(cloned);
     return container.innerHtml;
   }
 
-  String get innerHtml {
+  String$NULLABLE get innerHtml {
     final container = new DivElement();
     final SvgElement cloned = this.clone(true) $#NULLSAFECAST(as SvgElement);
     container.children.addAll(cloned.children);
diff --git a/tools/dom/templates/html/impl/impl_Screen.darttemplate b/tools/dom/templates/html/impl/impl_Screen.darttemplate
index e31aed5..3cf35ae 100644
--- a/tools/dom/templates/html/impl/impl_Screen.darttemplate
+++ b/tools/dom/templates/html/impl/impl_Screen.darttemplate
@@ -6,6 +6,6 @@
 
 $(ANNOTATIONS)$(NATIVESPEC)$(CLASS_MODIFIERS)class $CLASSNAME$EXTENDS$IMPLEMENTS {
 
-  Rectangle get available => new Rectangle(_availLeft, _availTop, _availWidth,
-      _availHeight);
+  Rectangle get available => new Rectangle(_availLeft$NULLASSERT,
+	_availTop$NULLASSERT, _availWidth$NULLASSERT, _availHeight$NULLASSERT);
 $!MEMBERS}
diff --git a/tools/dom/templates/html/impl/impl_WebGLCanvas.darttemplate b/tools/dom/templates/html/impl/impl_WebGLCanvas.darttemplate
index 2909b4d..272f693 100644
--- a/tools/dom/templates/html/impl/impl_WebGLCanvas.darttemplate
+++ b/tools/dom/templates/html/impl/impl_WebGLCanvas.darttemplate
@@ -11,6 +11,6 @@
   CanvasElement get canvas native;
 
   @JSName('canvas')
-  OffscreenCanvas get offscreenCanvas native;
+  OffscreenCanvas$NULLABLE get offscreenCanvas native;
 }
 
diff --git a/tools/dom/templates/html/impl/impl_WheelEvent.darttemplate b/tools/dom/templates/html/impl/impl_WheelEvent.darttemplate
index 43b0062..01d0da5 100644
--- a/tools/dom/templates/html/impl/impl_WheelEvent.darttemplate
+++ b/tools/dom/templates/html/impl/impl_WheelEvent.darttemplate
@@ -56,12 +56,10 @@
    * * [WheelEvent.deltaY](http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#events-WheelEvent-deltaY) from the W3C.
    */
   num get deltaY {
-    if (JS('bool', '#.deltaY !== undefined', this)) {
-      // W3C WheelEvent
-      return this._deltaY;
-    }
-    throw new UnsupportedError(
-        'deltaY is not supported');
+    // deltaY may be missing or undefined.
+    num? value = JS('', '#.deltaY', this);
+    if (value != null) return value;
+    throw new UnsupportedError('deltaY is not supported');
   }
 
   /**
@@ -73,12 +71,10 @@
    * * [WheelEvent.deltaX](http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#events-WheelEvent-deltaX) from the W3C.
    */
   num get deltaX {
-    if (JS('bool', '#.deltaX !== undefined', this)) {
-      // W3C WheelEvent
-      return this._deltaX;
-    }
-    throw new UnsupportedError(
-        'deltaX is not supported');
+    // deltaX may be missing or undefined.
+    num? value = JS('', '#.deltaX', this);
+    if (value != null) return value;
+    throw new UnsupportedError('deltaX is not supported');
   }
 
   int get deltaMode {
diff --git a/tools/dom/templates/html/impl/impl_Window.darttemplate b/tools/dom/templates/html/impl/impl_Window.darttemplate
index bfd09a4..0c35a8b 100644
--- a/tools/dom/templates/html/impl/impl_Window.darttemplate
+++ b/tools/dom/templates/html/impl/impl_Window.darttemplate
@@ -287,8 +287,9 @@
 
   String get returnValue => _returnValue;
 
-  set returnValue(String value) {
-    _returnValue = value;
+  set returnValue(String$NULLABLE value) {
+    // Typed as nullable only to be compatible with the overriden method.
+    _returnValue = value$NULLASSERT;
     // FF and IE use the value as the return value, Chrome will return this from
     // the event callback function.
     if (JS<bool>('bool', '("returnValue" in #)', wrapped)) {
diff --git a/tools/dom/templates/html/impl/impl_XMLHttpRequest.darttemplate b/tools/dom/templates/html/impl/impl_XMLHttpRequest.darttemplate
index eab360a..f61c75d 100644
--- a/tools/dom/templates/html/impl/impl_XMLHttpRequest.darttemplate
+++ b/tools/dom/templates/html/impl/impl_XMLHttpRequest.darttemplate
@@ -75,7 +75,8 @@
   static Future<String> getString(String url,
       {bool$NULLABLE withCredentials, void onProgress(ProgressEvent e)$NULLABLE}) {
     return request(url, withCredentials: withCredentials,
-        onProgress: onProgress).then((HttpRequest xhr) => xhr.responseText);
+        onProgress: onProgress).then(
+            (HttpRequest xhr) => xhr.responseText$NULLASSERT);
   }
 
   /**
@@ -217,15 +218,16 @@
     }
 
     xhr.onLoad.listen((e) {
-      var accepted = xhr.status >= 200 && xhr.status < 300;
-      var fileUri = xhr.status == 0; // file:// URIs have status of 0.
-      var notModified = xhr.status == 304;
+      var status = xhr.status$NULLASSERT;
+      var accepted = status >= 200 && status < 300;
+      var fileUri = status == 0; // file:// URIs have status of 0.
+      var notModified = status == 304;
       // Redirect status is specified up to 307, but others have been used in
       // practice. Notably Google Drive uses 308 Resume Incomplete for
       // resumable uploads, and it's also been used as a redirect. The
       // redirect case will be handled by the browser before it gets to us,
       // so if we see it we should pass it through to the user.
-      var unknownRedirect = xhr.status > 307 && xhr.status < 400;
+      var unknownRedirect = status > 307 && status < 400;
 
       if (accepted || fileUri || notModified || unknownRedirect) {
         completer.complete(xhr);
@@ -292,7 +294,7 @@
       {String$NULLABLE method, String$NULLABLE sendData}) {
     if (supportsCrossOrigin) {
       return request(url, method: method, sendData: sendData).then((xhr) {
-        return xhr.responseText;
+        return xhr.responseText$NULLASSERT;
       });
     }
     var completer = new Completer<String>();
diff --git a/tools/experimental_features.yaml b/tools/experimental_features.yaml
index a680662..7a9a03f 100644
--- a/tools/experimental_features.yaml
+++ b/tools/experimental_features.yaml
@@ -85,7 +85,7 @@
 # default 'language' "category" with code generated for both CFE and Analyzer,
 # while other categories can be tailored more specifically.
 
-current-version: 2.9
+current-version: '2.10.0'
 
 features:
   non-nullable:
diff --git a/tools/fuchsia/find_resources.py b/tools/fuchsia/find_resources.py
new file mode 100755
index 0000000..9d38053
--- /dev/null
+++ b/tools/fuchsia/find_resources.py
@@ -0,0 +1,57 @@
+#!/usr/bin/env python
+#
+# 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.
+#
+
+# Finds files in the given directories and their subdirectories, and prints them
+# in the json format expected by GN fuchsia_component's resources arg:
+# [
+#   {
+#     "path": "path/to/file.dart",
+#     "dest": "data/path/to/file.dart"
+#   },
+#   ...
+# ]
+
+import sys
+import os
+
+from os.path import join, abspath, relpath
+
+DART_DIR = abspath(join(__file__, '..', '..', '..'))
+
+
+def listFiles(path):
+  allFiles = []
+  for dirpath, dirs, files in os.walk(join(DART_DIR, path)):
+    allFiles += [relpath(abspath(join(dirpath, p)), DART_DIR) for p in files]
+  return allFiles
+
+
+def printOutput(files):
+  print('[')
+  print(',\n'.join([
+    '  {\n    "path": "%s",\n    "dest": "data/%s"\n  }' % (f, f) for f in files
+  ]))
+  print(']')
+
+
+def main():
+  if len(sys.argv) < 2:
+    print('Expected at least 1 arg, the paths to search.')
+    return 1
+  allFiles = []
+  for directory in sys.argv[1:]:
+    files = listFiles(directory)
+    if len(files) == 0:
+      print('Did not find any files in the directory: ' + directory)
+      return 2
+    allFiles += files
+  printOutput(sorted(allFiles))
+  return 0
+
+
+if __name__ == '__main__':
+  sys.exit(main())
diff --git a/tools/git_cl_try.sh b/tools/git_cl_try.sh
new file mode 100644
index 0000000..573465d
--- /dev/null
+++ b/tools/git_cl_try.sh
@@ -0,0 +1,94 @@
+
+function git-cl-try-vm-jit-app {
+  echo "git-cl-try-vm-jit-app"
+  git cl try -B dart/try                                     \
+     -b app-kernel-linux-debug-x64-try                       \
+     -b app-kernel-linux-product-x64-try                     \
+     -b app-kernel-linux-release-x64-try
+}
+function git-cl-try-vm-jit-dartkb {
+  echo "git-cl-try-vm-jit-dartkb"
+  git cl try -B dart/try                                     \
+     -b vm-dartkb-linux-release-simarm64-try                 \
+     -b vm-dartkb-linux-release-x64-abi-try                  \
+     -b vm-dartkb-linux-release-x64-try
+}
+function git-cl-try-vm-jit-reload {
+  echo "git-cl-try-vm-jit-reload"
+  git cl try -B dart/try                                     \
+   -b vm-kernel-reload-linux-debug-x64-try                   \
+   -b vm-kernel-reload-linux-release-x64-try                 \
+   -b vm-kernel-reload-rollback-linux-debug-x64-try          \
+   -b vm-kernel-reload-rollback-linux-release-x64-try
+}
+function git-cl-try-vm-jit-rest {
+  echo "git-cl-try-vm-jit-rest"
+  git cl try -B dart/try                                     \
+   -b vm-kernel-checked-linux-release-x64-try                \
+   -b vm-kernel-linux-debug-ia32-try                         \
+   -b vm-kernel-linux-debug-x64-try                          \
+   -b vm-kernel-linux-product-x64-try                        \
+   -b vm-kernel-linux-release-ia32-try                       \
+   -b vm-kernel-linux-release-simarm-try                     \
+   -b vm-kernel-linux-release-simarm64-try                   \
+   -b vm-kernel-linux-release-x64-try                        \
+   -b vm-kernel-mac-debug-x64-try                            \
+   -b vm-kernel-mac-product-x64-try                          \
+   -b vm-kernel-mac-release-x64-try                          \
+   -b vm-kernel-nnbd-linux-debug-x64-try                     \
+   -b vm-kernel-nnbd-linux-release-x64-try                   \
+   -b vm-kernel-optcounter-threshold-linux-release-ia32-try  \
+   -b vm-kernel-optcounter-threshold-linux-release-x64-try   \
+   -b vm-kernel-win-debug-ia32-try                           \
+   -b vm-kernel-win-debug-x64-try                            \
+   -b vm-kernel-win-product-x64-try                          \
+   -b vm-kernel-win-release-ia32-try                         \
+   -b vm-kernel-win-release-x64-try
+}
+function git-cl-try-vm-ffi {
+  echo "git-cl-try-vm-ffi"
+  git cl try -B dart/try                                     \
+     -b vm-ffi-android-debug-arm-try                         \
+     -b vm-ffi-android-debug-arm64-try                       \
+     -b vm-ffi-android-product-arm-try                       \
+     -b vm-ffi-android-product-arm64-try                     \
+     -b vm-ffi-android-release-arm-try                       \
+     -b vm-ffi-android-release-arm64-try
+}
+function git-cl-try-vm-precomp {
+  echo "git-cl-try-vm-precomp"
+  git cl try -B dart/try                                     \
+     -b vm-kernel-precomp-android-release-arm64-try          \
+     -b vm-kernel-precomp-android-release-arm_x64-try        \
+     -b vm-kernel-precomp-linux-debug-simarm_x64-try         \
+     -b vm-kernel-precomp-linux-debug-x64-try                \
+     -b vm-kernel-precomp-linux-product-x64-try              \
+     -b vm-kernel-precomp-linux-release-simarm-try           \
+     -b vm-kernel-precomp-linux-release-simarm64-try         \
+     -b vm-kernel-precomp-linux-release-simarm_x64-try       \
+     -b vm-kernel-precomp-linux-release-x64-try              \
+     -b vm-kernel-precomp-mac-release-simarm64-try           \
+     -b vm-kernel-precomp-obfuscate-linux-release-x64-try    \
+     -b vm-kernel-precomp-win-release-x64-try                \
+     -b vm-precomp-ffi-qemu-linux-release-arm-try
+}
+function git-cl-try-vm-san {
+  echo "git-cl-try-vm-jit-san"
+  git cl try -B dart/try                                     \
+   -b vm-kernel-asan-linux-release-x64-try                   \
+   -b vm-kernel-msan-linux-release-x64-try                   \
+   -b vm-kernel-tsan-linux-release-x64-try                   \
+   -b vm-kernel-precomp-asan-linux-release-x64-try           \
+   -b vm-kernel-precomp-msan-linux-release-x64-try           \
+   -b vm-kernel-precomp-tsan-linux-release-x64-try           \
+}
+function git-cl-try-vm-all {
+  echo "git-cl-try-vm-all"
+  git-cl-try-vm-jit-app
+  git-cl-try-vm-jit-dartkb
+  git-cl-try-vm-jit-reload
+  git-cl-try-vm-jit-rest
+  git-cl-try-vm-ffi
+  git-cl-try-vm-precomp
+  git-cl-try-vm-san
+}
diff --git a/tools/gn.py b/tools/gn.py
index 4bd29b4..14929d6 100755
--- a/tools/gn.py
+++ b/tools/gn.py
@@ -16,6 +16,7 @@
 HOST_ARCH = utils.GuessArchitecture()
 SCRIPT_DIR = os.path.dirname(sys.argv[0])
 DART_ROOT = os.path.realpath(os.path.join(SCRIPT_DIR, '..'))
+AVAILABLE_ARCHS = utils.ARCH_FAMILY.keys()
 GN = os.path.join(DART_ROOT, 'buildtools', 'gn')
 
 # Environment variables for default settings.
@@ -286,12 +287,13 @@
         if not mode in ['debug', 'release', 'product']:
             print("Unknown mode %s" % mode)
             return False
-    for arch in args.arch:
-        archs = [
-            'ia32', 'x64', 'simarm', 'arm', 'arm_x64', 'simarmv6', 'armv6',
-            'simarm64', 'arm64', 'simarm_x64'
-        ]
-        if not arch in archs:
+    for i, arch in enumerate(args.arch):
+        if not arch in AVAILABLE_ARCHS:
+            # Normalise to lower case form to make it less case-picky.
+            arch_lower = arch.lower()
+            if arch_lower in AVAILABLE_ARCHS:
+                args.arch[i] = arch_lower
+                continue
             print("Unknown arch %s" % arch)
             return False
     oses = [ProcessOsOption(os_name) for os_name in args.os]
@@ -345,133 +347,153 @@
         return '--ide=json'
 
 
+def AddCommonGnOptionArgs(parser):
+    """Adds arguments that will change the default GN arguments."""
+
+    parser.add_argument('--goma', help='Use goma', action='store_true')
+    parser.add_argument('--no-goma',
+                        help='Disable goma',
+                        dest='goma',
+                        action='store_false')
+    parser.set_defaults(goma=True)
+
+    parser.add_argument('--verify-sdk-hash',
+                        help='Enable SDK hash checks (default)',
+                        dest='verify_sdk_hash',
+                        action='store_true')
+    parser.add_argument('-nvh',
+                        '--no-verify-sdk-hash',
+                        help='Disable SDK hash checks',
+                        dest='verify_sdk_hash',
+                        action='store_false')
+    parser.set_defaults(verify_sdk_hash=True)
+
+    parser.add_argument('--bytecode',
+                        '-b',
+                        help='Use bytecode in Dart VM',
+                        dest='bytecode',
+                        action="store_true")
+    parser.add_argument('--no-bytecode',
+                        help='Disable bytecode in Dart VM',
+                        dest='bytecode',
+                        action="store_false")
+    parser.set_defaults(bytecode=False)
+
+    parser.add_argument('--clang', help='Use Clang', action='store_true')
+    parser.add_argument('--no-clang',
+                        help='Disable Clang',
+                        dest='clang',
+                        action='store_false')
+    parser.set_defaults(clang=True)
+
+    parser.add_argument(
+        '--platform-sdk',
+        help='Directs the create_sdk target to create a smaller "Platform" SDK',
+        default=MakePlatformSDK(),
+        action='store_true')
+    parser.add_argument('--use-crashpad',
+                        default=False,
+                        dest='use_crashpad',
+                        action='store_true')
+    parser.add_argument('--use-qemu',
+                        default=False,
+                        dest='use_qemu',
+                        action='store_true')
+    parser.add_argument('--exclude-kernel-service',
+                        help='Exclude the kernel service.',
+                        default=False,
+                        dest='exclude_kernel_service',
+                        action='store_true')
+    parser.add_argument('--arm-float-abi',
+                        type=str,
+                        help='The ARM float ABI (soft, softfp, hard)',
+                        metavar='[soft,softfp,hard]',
+                        default='')
+
+    parser.add_argument('--code-coverage',
+                        help='Enable code coverage for the standalone VM',
+                        default=False,
+                        dest="code_coverage",
+                        action='store_true')
+    parser.add_argument('--debug-opt-level',
+                        '-d',
+                        help='The optimization level to use for debug builds',
+                        type=str)
+    parser.add_argument('--gn-args',
+                        help='Set extra GN args',
+                        dest='gn_args',
+                        action='append')
+    parser.add_argument(
+        '--toolchain-prefix',
+        '-t',
+        type=str,
+        help='Comma-separated list of arch=/path/to/toolchain-prefix mappings')
+    parser.add_argument('--ide',
+                        help='Generate an IDE file.',
+                        default=os_has_ide(HOST_OS),
+                        action='store_true')
+    parser.add_argument(
+        '--target-sysroot',
+        '-s',
+        type=str,
+        help='Comma-separated list of arch=/path/to/sysroot mappings')
+
+
+def AddCommonConfigurationArgs(parser):
+    """Adds arguments that influence which configuration will be built."""
+    parser.add_argument("-a",
+                        "--arch",
+                        type=str,
+                        help='Target architectures (comma-separated).',
+                        metavar='[all,' + ','.join(AVAILABLE_ARCHS) + ']',
+                        default=utils.GuessArchitecture())
+    parser.add_argument('--mode',
+                        '-m',
+                        type=str,
+                        help='Build variants (comma-separated).',
+                        metavar='[all,debug,release,product]',
+                        default='debug')
+    parser.add_argument('--os',
+                        type=str,
+                        help='Target OSs (comma-separated).',
+                        metavar='[all,host,android,fuchsia]',
+                        default='host')
+    parser.add_argument('--sanitizer',
+                        type=str,
+                        help='Build variants (comma-separated).',
+                        metavar='[all,none,asan,lsan,msan,tsan,ubsan]',
+                        default='none')
+
+
+def AddOtherArgs(parser):
+    """Adds miscellaneous arguments to the parser."""
+    parser.add_argument('--workers',
+                        '-w',
+                        type=int,
+                        help='Number of simultaneous GN invocations',
+                        dest='workers',
+                        default=multiprocessing.cpu_count())
+    parser.add_argument("-v",
+                        "--verbose",
+                        help='Verbose output.',
+                        default=False,
+                        action="store_true")
+
+
 def parse_args(args):
     args = args[1:]
     parser = argparse.ArgumentParser(
         description='A script to run `gn gen`.',
         formatter_class=argparse.ArgumentDefaultsHelpFormatter)
-    common_group = parser.add_argument_group('Common Arguments')
+
+    config_group = parser.add_argument_group('Configuration Related Arguments')
+    AddCommonConfigurationArgs(config_group)
+
+    gn_group = parser.add_argument_group('GN Related Arguments')
+    AddCommonGnOptionArgs(gn_group)
+
     other_group = parser.add_argument_group('Other Arguments')
-
-    common_group.add_argument(
-        '--arch',
-        '-a',
-        type=str,
-        help='Target architectures (comma-separated).',
-        metavar='[all,ia32,x64,simarm,arm,arm_x64,simarmv6,armv6,'
-        'simarm64,arm64,simarm_x64]',
-        default='x64')
-    common_group.add_argument(
-        '--mode',
-        '-m',
-        type=str,
-        help='Build variants (comma-separated).',
-        metavar='[all,debug,release,product]',
-        default='debug')
-    common_group.add_argument(
-        '--os',
-        type=str,
-        help='Target OSs (comma-separated).',
-        metavar='[all,host,android,fuchsia]',
-        default='host')
-    common_group.add_argument(
-        '--sanitizer',
-        type=str,
-        help='Build variants (comma-separated).',
-        metavar='[all,none,asan,lsan,msan,tsan,ubsan]',
-        default='none')
-    common_group.add_argument(
-        "-v",
-        "--verbose",
-        help='Verbose output.',
-        default=False,
-        action="store_true")
-
-    other_group.add_argument(
-        '--arm-float-abi',
-        type=str,
-        help='The ARM float ABI (soft, softfp, hard)',
-        metavar='[soft,softfp,hard]',
-        default='')
-    other_group.add_argument(
-        '--bytecode',
-        '-b',
-        help='Use bytecode in Dart VM',
-        default=False,
-        action="store_true")
-    other_group.add_argument(
-        '--no-bytecode',
-        help='Disable bytecode in Dart VM',
-        dest='bytecode',
-        action="store_false")
-    other_group.add_argument(
-        '--clang', help='Use Clang', default=True, action='store_true')
-    other_group.add_argument(
-        '--no-clang', help='Disable Clang', dest='clang', action='store_false')
-    other_group.add_argument(
-        '--code-coverage',
-        help='Enable code coverage for the standalone VM',
-        default=False,
-        dest="code_coverage",
-        action='store_true')
-    other_group.add_argument(
-        '--debug-opt-level',
-        '-d',
-        help='The optimization level to use for debug builds',
-        type=str)
-    other_group.add_argument(
-        '--goma', help='Use goma', default=True, action='store_true')
-    other_group.add_argument(
-        '--no-goma', help='Disable goma', dest='goma', action='store_false')
-    other_group.add_argument(
-        '--ide',
-        help='Generate an IDE file.',
-        default=os_has_ide(HOST_OS),
-        action='store_true')
-    other_group.add_argument(
-        '--exclude-kernel-service',
-        help='Exclude the kernel service.',
-        default=False,
-        dest='exclude_kernel_service',
-        action='store_true')
-    other_group.add_argument(
-        '--gn-args', help='Set extra GN args', dest='gn_args', action='append')
-    other_group.add_argument(
-        '--platform-sdk',
-        help='Directs the create_sdk target to create a smaller "Platform" SDK',
-        default=MakePlatformSDK(),
-        action='store_true')
-    other_group.add_argument(
-        '--target-sysroot',
-        '-s',
-        type=str,
-        help='Comma-separated list of arch=/path/to/sysroot mappings')
-    other_group.add_argument(
-        '--toolchain-prefix',
-        '-t',
-        type=str,
-        help='Comma-separated list of arch=/path/to/toolchain-prefix mappings')
-    other_group.add_argument(
-        '--workers',
-        '-w',
-        type=int,
-        help='Number of simultaneous GN invocations',
-        dest='workers',
-        default=multiprocessing.cpu_count())
-    other_group.add_argument(
-        '--use-crashpad',
-        default=False,
-        dest='use_crashpad',
-        action='store_true')
-    other_group.add_argument(
-        '--use-qemu',
-        default=False,
-        dest='use_qemu',
-        action='store_true')
-    other_group.add_argument('--no-verify-sdk-hash',
-                             help='Disable SDK hash checks.',
-                             default=False,
-                             action='store_true')
+    AddOtherArgs(other_group)
 
     options = parser.parse_args(args)
     if not ProcessOptions(options):
@@ -491,36 +513,39 @@
         return ("Command failed: " + ' '.join(command) + "\n" + "output: " +
                 e.output)
 
-def Main(argv):
-    starttime = time.time()
-    args = parse_args(argv)
 
+def BuildGnCommand(args, mode, arch, target_os, sanitizer, out_dir):
     gn = os.path.join(DART_ROOT, 'buildtools',
                       'gn.exe' if utils.IsWindows() else 'gn')
     if not os.path.isfile(gn):
-        print("Couldn't find the gn binary at path: " + gn)
-        return 1
+        raise Exception("Couldn't find the gn binary at path: " + gn)
 
+    # TODO(infra): Re-enable --check. Many targets fail to use
+    # public_deps to re-expose header files to their dependents.
+    # See dartbug.com/32364
+    command = [gn, 'gen', out_dir]
+    gn_args = ToCommandLine(
+        ToGnArgs(args, mode, arch, target_os, sanitizer, args.verify_sdk_hash))
+    gn_args += GetGNArgs(args)
+    if args.ide:
+        command.append(ide_switch(HOST_OS))
+    command.append('--args=%s' % ' '.join(gn_args))
+
+    return command
+
+
+def RunGnOnConfiguredConfigurations(args):
     commands = []
     for target_os in args.os:
         for mode in args.mode:
             for arch in args.arch:
                 for sanitizer in args.sanitizer:
                     out_dir = GetOutDir(mode, arch, target_os, sanitizer)
-                    # TODO(infra): Re-enable --check. Many targets fail to use
-                    # public_deps to re-expose header files to their dependents.
-                    # See dartbug.com/32364
-                    command = [gn, 'gen', out_dir]
-                    gn_args = ToCommandLine(
-                        ToGnArgs(args, mode, arch, target_os, sanitizer,
-                                 not args.no_verify_sdk_hash))
-                    gn_args += GetGNArgs(args)
+                    commands.append(
+                        BuildGnCommand(args, mode, arch, target_os, sanitizer,
+                                       out_dir))
                     if args.verbose:
                         print("gn gen --check in %s" % out_dir)
-                    if args.ide:
-                        command.append(ide_switch(HOST_OS))
-                    command.append('--args=%s' % ' '.join(gn_args))
-                    commands.append(command)
 
     pool = multiprocessing.Pool(args.workers)
     results = pool.map(RunCommand, commands, chunksize=1)
@@ -529,6 +554,13 @@
             print(r.strip())
             return 1
 
+
+def Main(argv):
+    starttime = time.time()
+    args = parse_args(argv)
+
+    RunGnOnConfiguredConfigurations(args)
+
     endtime = time.time()
     if args.verbose:
         print("GN Time: %.3f seconds" % (endtime - starttime))
diff --git a/tools/patches/flutter-engine/a3815b659047cfc6b63d41d180aa1ca1b781ee68.patch b/tools/patches/flutter-engine/a3815b659047cfc6b63d41d180aa1ca1b781ee68.patch
new file mode 100644
index 0000000..94120c0
--- /dev/null
+++ b/tools/patches/flutter-engine/a3815b659047cfc6b63d41d180aa1ca1b781ee68.patch
@@ -0,0 +1,596 @@
+diff --git a/DEPS b/DEPS
+index 01113f340..e55da1cff 100644
+--- a/DEPS
++++ b/DEPS
+@@ -34,14 +34,14 @@ vars = {
+   # Dart is: https://github.com/dart-lang/sdk/blob/master/DEPS.
+   # You can use //tools/dart/create_updated_flutter_deps.py to produce
+   # updated revision list of existing dependencies.
+   'dart_revision': 'a3815b659047cfc6b63d41d180aa1ca1b781ee68',
+ 
+   # WARNING: DO NOT EDIT MANUALLY
+   # The lines between blank lines above and below are generated by a script. See create_updated_flutter_deps.py
+   'dart_args_tag': '1.6.0',
+   'dart_boringssl_gen_rev': '429ccb1877f7987a6f3988228bc2440e61293499',
+   'dart_boringssl_rev': '4dfd5af70191b068aebe567b8e29ce108cee85ce',
+-  'dart_collection_rev': '80f5b6de8a8d8d584732a71bb59912da3e44883b',
++  'dart_collection_rev': '583693680fc067e34ca5b72503df25e8b80579f9',
+   'dart_dart2js_info_tag': '0.6.0',
+   'dart_dart_style_tag': '1.3.6',
+   'dart_http_retry_tag': '0.1.1',
+@@ -49,7 +49,6 @@ vars = {
+   'dart_intl_tag': '0.16.1',
+   'dart_linter_tag': '0.1.117',
+   'dart_oauth2_tag': '1.6.0',
+-  'dart_pedantic_tag': 'v1.9.0',
+   'dart_protobuf_rev': '3746c8fd3f2b0147623a8e3db89c3ff4330de760',
+   'dart_pub_rev': '04b054b62cc437cf23451785fdc50e49cd9de139',
+   'dart_pub_semver_tag': 'v1.4.4',
+@@ -61,15 +60,13 @@ vars = {
+   'dart_shelf_static_rev': 'v0.2.8',
+   'dart_shelf_tag': '0.7.3+3',
+   'dart_shelf_web_socket_tag': '0.2.2+3',
+-  'dart_source_map_stack_trace_tag': '2.0.0',
+-  'dart_source_span_tag': '1.7.0',
+   'dart_sse_tag': 'e5cf68975e8e87171a3dc297577aa073454a91dc',
+-  'dart_stack_trace_tag': '56811dbb2530d823b764fe167ec335879a4adb32',
++  'dart_stack_trace_tag': 'd3813ca0a77348e0faf0d6af0cc17913e36afa39',
+   'dart_stagehand_tag': 'v3.3.9',
+-  'dart_stream_channel_tag': '70433d577be02c48cb16d72d65654f3b4d82c6ed',
++  'dart_stream_channel_tag': 'c446774fd077c9bdbd6235a7aadc661ef60a9727',
+   'dart_test_reflective_loader_tag': '0.1.9',
+   'dart_tflite_native_rev': '3c777c40608a2a9f1427bfe0028ab48e7116b4c1',
+-  'dart_typed_data_tag': '0c369b73a9b7ebf042c06512951bfe5b52b84a5f',
++  'dart_typed_data_tag': 'f94fc57b8e8c0e4fe4ff6cfd8290b94af52d3719',
+   'dart_usage_tag': '3.4.0',
+   'dart_watcher_rev': 'fc3c9aae5d31d707b3013b42634dde8d8a1161b4',
+ 
+@@ -171,13 +168,13 @@ deps = {
+    Var('dart_git') + '/args.git' + '@' + Var('dart_args_tag'),
+ 
+   'src/third_party/dart/third_party/pkg/async':
+-   Var('dart_git') + '/async.git@6b90f4557f330e1ead021f501ee7f1d8b0e77815',
++   Var('dart_git') + '/async.git@128c461a97dbdbd9336ba000ba5a5c02e79b8651',
+ 
+   'src/third_party/dart/third_party/pkg/bazel_worker':
+    Var('dart_git') + '/bazel_worker.git@26680d5e249b249c7216ab2fed0ac8ed4ee285c5',
+ 
+   'src/third_party/dart/third_party/pkg/boolean_selector':
+-   Var('dart_git') + '/boolean_selector.git@1309eabed510cc3b7536fd4367d39b97ebee3d69',
++   Var('dart_git') + '/boolean_selector.git@665e6921ab246569420376f827bff4585dff0b14',
+ 
+   'src/third_party/dart/third_party/pkg/charcode':
+    Var('dart_git') + '/charcode.git@af1e2d59a9c383da94f99ea51dac4b93fb0626c4',
+@@ -207,7 +204,7 @@ deps = {
+    Var('dart_git') + '/ffi.git@454ab0f9ea6bd06942a983238d8a6818b1357edb',
+ 
+   'src/third_party/dart/third_party/pkg/fixnum':
+-   Var('dart_git') + '/fixnum.git@9b38f49f6679654d66a363e69e48173cca07e882',
++   Var('dart_git') + '/fixnum.git@300c3f025e94a72b7b6770e15f76a4de15f77668',
+ 
+   'src/third_party/dart/third_party/pkg/glob':
+    Var('dart_git') + '/glob.git@e9f4e6b7ae8abe5071461cf8f47191bb19cf7ef6',
+@@ -246,7 +243,7 @@ deps = {
+    Var('dart_git') + '/markdown.git@dd150bb64c5f3b41d31f20f399ae2a855f7f8c00',
+ 
+   'src/third_party/dart/third_party/pkg/matcher':
+-   Var('dart_git') + '/matcher.git@8f8d965933c94a489b1a39e20d558a32841bfa5b',
++   Var('dart_git') + '/matcher.git@9cae8faa7868bf3a88a7ba45eb0bd128e66ac515',
+ 
+   'src/third_party/dart/third_party/pkg/mime':
+    Var('dart_git') + '/mime.git@179b5e6a88f4b63f36dc1b8fcbc1e83e5e0cd3a7',
+@@ -261,13 +258,13 @@ deps = {
+    Var('dart_git') + '/oauth2.git' + '@' + Var('dart_oauth2_tag'),
+ 
+   'src/third_party/dart/third_party/pkg/path':
+-   Var('dart_git') + '/path.git@4f3bb71843fe5493ba490828a1721821d7b33746',
++   Var('dart_git') + '/path.git@62ecd5a78ffe5734d14ed0df76d20309084cd04a',
+ 
+   'src/third_party/dart/third_party/pkg/pedantic':
+-   Var('dart_git') + '/pedantic.git' + '@' + Var('dart_pedantic_tag'),
++   Var('dart_git') + '/pedantic.git@24b38df72430d7e21cb4257828580becb9a39c72',
+ 
+   'src/third_party/dart/third_party/pkg/pool':
+-   Var('dart_git') + '/pool.git@86fbb2cde9bbc66c8d159909d2f65a5981ea5b50',
++   Var('dart_git') + '/pool.git@eedbd5fde84f9a1a8da643b475305a81841da599',
+ 
+   'src/third_party/dart/third_party/pkg/protobuf':
+    Var('dart_git') + '/protobuf.git' + '@' + Var('dart_protobuf_rev'),
+@@ -300,13 +297,13 @@ deps = {
+    Var('dart_git') + '/shelf_web_socket.git' + '@' + Var('dart_shelf_web_socket_tag'),
+ 
+   'src/third_party/dart/third_party/pkg/source_map_stack_trace':
+-   Var('dart_git') + '/source_map_stack_trace.git' + '@' + Var('dart_source_map_stack_trace_tag'),
++   Var('dart_git') + '/source_map_stack_trace.git@1c3026f69d9771acf2f8c176a1ab750463309cce',
+ 
+   'src/third_party/dart/third_party/pkg/source_maps':
+-   Var('dart_git') + '/source_maps.git@87b4fd9027378bbd51b02e9d7df794eee8a82b7a',
++   Var('dart_git') + '/source_maps.git@53eb92ccfe6e64924054f83038a534b959b12b3e',
+ 
+   'src/third_party/dart/third_party/pkg/source_span':
+-   Var('dart_git') + '/source_span.git' + '@' + Var('dart_source_span_tag'),
++   Var('dart_git') + '/source_span.git@94833d6cbf4552ebe5d2aa6714acecd93834e53a',
+ 
+   'src/third_party/dart/third_party/pkg/sse':
+    Var('dart_git') + '/sse.git' + '@' + Var('dart_sse_tag'),
+@@ -321,13 +318,13 @@ deps = {
+    Var('dart_git') + '/stream_channel.git' + '@' + Var('dart_stream_channel_tag'),
+ 
+   'src/third_party/dart/third_party/pkg/string_scanner':
+-   Var('dart_git') + '/string_scanner.git@a918e7371af6b6e73bfd534ff9da6084741c1f99',
++   Var('dart_git') + '/string_scanner.git@1b63e6e5db5933d7be0a45da6e1129fe00262734',
+ 
+   'src/third_party/dart/third_party/pkg/term_glyph':
+-   Var('dart_git') + '/term_glyph.git@b3da31e9684a99cfe5f192b89914492018b44da7',
++   Var('dart_git') + '/term_glyph.git@6a0f9b6fb645ba75e7a00a4e20072678327a0347',
+ 
+   'src/third_party/dart/third_party/pkg/test':
+-   Var('dart_git') + '/test.git@718fe6f93c4655208460f28e89d887c5ef4144c5',
++   Var('dart_git') + '/test.git@c6b3fe63eda87da1687580071cad1eefd575f851',
+ 
+   'src/third_party/dart/third_party/pkg/test_reflective_loader':
+    Var('dart_git') + '/test_reflective_loader.git' + '@' + Var('dart_test_reflective_loader_tag'),
+@@ -357,7 +354,7 @@ deps = {
+    Var('dart_git') + '/package_config.git@9c586d04bd26fef01215fd10e7ab96a3050cfa64',
+ 
+   'src/third_party/dart/tools/sdks':
+-   {'packages': [{'version': 'version:2.9.0-21.0.dev', 'package': 'dart/dart-sdk/${{platform}}'}], 'dep_type': 'cipd'},
++   {'packages': [{'version': 'version:2.10.0-0.2-preview', 'package': 'dart/dart-sdk/${{platform}}'}], 'dep_type': 'cipd'},
+ 
+   # WARNING: end of dart dependencies list that is cleaned up automatically - see create_updated_flutter_deps.py.
+ 
+diff --git a/lib/ui/annotations.dart b/lib/ui/annotations.dart
+index 45d8ca6cc..b300af073 100644
+--- a/lib/ui/annotations.dart
++++ b/lib/ui/annotations.dart
+@@ -4,7 +4,7 @@
+ 
+ // TODO(dnfield): Remove unused_import ignores when https://github.com/dart-lang/sdk/issues/35164 is resolved.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/channel_buffers.dart b/lib/ui/channel_buffers.dart
+index cb32c4581..39d31d271 100644
+--- a/lib/ui/channel_buffers.dart
++++ b/lib/ui/channel_buffers.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/compositing.dart b/lib/ui/compositing.dart
+index ea3c0b714..4e0553936 100644
+--- a/lib/ui/compositing.dart
++++ b/lib/ui/compositing.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/geometry.dart b/lib/ui/geometry.dart
+index 2739048e7..a7404996c 100644
+--- a/lib/ui/geometry.dart
++++ b/lib/ui/geometry.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/hash_codes.dart b/lib/ui/hash_codes.dart
+index a6ede7849..7da175a27 100644
+--- a/lib/ui/hash_codes.dart
++++ b/lib/ui/hash_codes.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/hooks.dart b/lib/ui/hooks.dart
+index ff2dcaa12..39bab1240 100644
+--- a/lib/ui/hooks.dart
++++ b/lib/ui/hooks.dart
+@@ -4,7 +4,7 @@
+ 
+ // TODO(dnfield): Remove unused_import ignores when https://github.com/dart-lang/sdk/issues/35164 is resolved.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/isolate_name_server.dart b/lib/ui/isolate_name_server.dart
+index d976e0ac2..4b5c2c84d 100644
+--- a/lib/ui/isolate_name_server.dart
++++ b/lib/ui/isolate_name_server.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/lerp.dart b/lib/ui/lerp.dart
+index db9f7b2ec..0bb0a08b7 100644
+--- a/lib/ui/lerp.dart
++++ b/lib/ui/lerp.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/natives.dart b/lib/ui/natives.dart
+index ce29fe15c..0f2939592 100644
+--- a/lib/ui/natives.dart
++++ b/lib/ui/natives.dart
+@@ -4,7 +4,7 @@
+ 
+ // TODO(dnfield): remove unused_element ignores when https://github.com/dart-lang/sdk/issues/35164 is resolved.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/painting.dart b/lib/ui/painting.dart
+index 992db71cf..2599f90e2 100644
+--- a/lib/ui/painting.dart
++++ b/lib/ui/painting.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/plugins.dart b/lib/ui/plugins.dart
+index 64eca6e04..9622852fd 100644
+--- a/lib/ui/plugins.dart
++++ b/lib/ui/plugins.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/pointer.dart b/lib/ui/pointer.dart
+index 3c12cb971..3c8ffefaf 100644
+--- a/lib/ui/pointer.dart
++++ b/lib/ui/pointer.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/semantics.dart b/lib/ui/semantics.dart
+index bee542328..518a69412 100644
+--- a/lib/ui/semantics.dart
++++ b/lib/ui/semantics.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/text.dart b/lib/ui/text.dart
+index 8bdc0f05d..c246731d8 100644
+--- a/lib/ui/text.dart
++++ b/lib/ui/text.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ 
+ part of dart.ui;
+ 
+diff --git a/lib/ui/ui.dart b/lib/ui/ui.dart
+index 7612cf509..fe0e4fa16 100644
+--- a/lib/ui/ui.dart
++++ b/lib/ui/ui.dart
+@@ -9,7 +9,7 @@
+ /// This library exposes the lowest-level services that Flutter frameworks use
+ /// to bootstrap applications, such as classes for driving the input, graphics
+ /// text, layout, and rendering subsystems.
+-// @dart = 2.9
++// @dart = 2.10
+ library dart.ui;
+ 
+ import 'dart:_internal' hide Symbol; // ignore: unused_import
+diff --git a/lib/ui/window.dart b/lib/ui/window.dart
+index 815bee5a1..22f9ed0c3 100644
+--- a/lib/ui/window.dart
++++ b/lib/ui/window.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of dart.ui;
+ 
+ /// Signature of callbacks that have no arguments and return no data.
+diff --git a/lib/web_ui/lib/src/ui/annotations.dart b/lib/web_ui/lib/src/ui/annotations.dart
+index 977ca70ca..7dac0c567 100644
+--- a/lib/web_ui/lib/src/ui/annotations.dart
++++ b/lib/web_ui/lib/src/ui/annotations.dart
+@@ -4,7 +4,7 @@
+ 
+ // TODO(dnfield): Remove unused_import ignores when https://github.com/dart-lang/sdk/issues/35164 is resolved.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ // TODO(dnfield): Update this if/when we default this to on in the tool,
+diff --git a/lib/web_ui/lib/src/ui/canvas.dart b/lib/web_ui/lib/src/ui/canvas.dart
+index 1061ab718..ee185ef29 100644
+--- a/lib/web_ui/lib/src/ui/canvas.dart
++++ b/lib/web_ui/lib/src/ui/canvas.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Defines how a list of points is interpreted when drawing a set of points.
+diff --git a/lib/web_ui/lib/src/ui/channel_buffers.dart b/lib/web_ui/lib/src/ui/channel_buffers.dart
+index 5d3db5da5..6ce0bc962 100644
+--- a/lib/web_ui/lib/src/ui/channel_buffers.dart
++++ b/lib/web_ui/lib/src/ui/channel_buffers.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// A saved platform message for a channel with its callback.
+diff --git a/lib/web_ui/lib/src/ui/compositing.dart b/lib/web_ui/lib/src/ui/compositing.dart
+index 635dd7261..11a0e1199 100644
+--- a/lib/web_ui/lib/src/ui/compositing.dart
++++ b/lib/web_ui/lib/src/ui/compositing.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// An opaque object representing a composited scene.
+diff --git a/lib/web_ui/lib/src/ui/geometry.dart b/lib/web_ui/lib/src/ui/geometry.dart
+index 904cec065..c528c8c73 100644
+--- a/lib/web_ui/lib/src/ui/geometry.dart
++++ b/lib/web_ui/lib/src/ui/geometry.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Base class for [Size] and [Offset], which are both ways to describe
+diff --git a/lib/web_ui/lib/src/ui/hash_codes.dart b/lib/web_ui/lib/src/ui/hash_codes.dart
+index 69aeb33bb..e91fb1cc5 100644
+--- a/lib/web_ui/lib/src/ui/hash_codes.dart
++++ b/lib/web_ui/lib/src/ui/hash_codes.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ class _HashEnd { const _HashEnd(); }
+diff --git a/lib/web_ui/lib/src/ui/initialization.dart b/lib/web_ui/lib/src/ui/initialization.dart
+index 2749fa9e5..6865da812 100644
+--- a/lib/web_ui/lib/src/ui/initialization.dart
++++ b/lib/web_ui/lib/src/ui/initialization.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Initializes the platform.
+diff --git a/lib/web_ui/lib/src/ui/lerp.dart b/lib/web_ui/lib/src/ui/lerp.dart
+index bcc278f8a..5cd4c8ac1 100644
+--- a/lib/web_ui/lib/src/ui/lerp.dart
++++ b/lib/web_ui/lib/src/ui/lerp.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Linearly interpolate between two numbers.
+diff --git a/lib/web_ui/lib/src/ui/natives.dart b/lib/web_ui/lib/src/ui/natives.dart
+index e4bf1a2f5..4763db34e 100644
+--- a/lib/web_ui/lib/src/ui/natives.dart
++++ b/lib/web_ui/lib/src/ui/natives.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ // Corelib 'print' implementation.
+diff --git a/lib/web_ui/lib/src/ui/painting.dart b/lib/web_ui/lib/src/ui/painting.dart
+index a9bd10662..67da1842f 100644
+--- a/lib/web_ui/lib/src/ui/painting.dart
++++ b/lib/web_ui/lib/src/ui/painting.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ // ignore: unused_element, Used in Shader assert.
+diff --git a/lib/web_ui/lib/src/ui/path.dart b/lib/web_ui/lib/src/ui/path.dart
+index 18e351f53..1514d2432 100644
+--- a/lib/web_ui/lib/src/ui/path.dart
++++ b/lib/web_ui/lib/src/ui/path.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// A complex, one-dimensional subset of a plane.
+diff --git a/lib/web_ui/lib/src/ui/path_metrics.dart b/lib/web_ui/lib/src/ui/path_metrics.dart
+index 6d54888c2..b65e2b928 100644
+--- a/lib/web_ui/lib/src/ui/path_metrics.dart
++++ b/lib/web_ui/lib/src/ui/path_metrics.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// An iterable collection of [PathMetric] objects describing a [Path].
+diff --git a/lib/web_ui/lib/src/ui/pointer.dart b/lib/web_ui/lib/src/ui/pointer.dart
+index 698badcc4..e2f351caf 100644
+--- a/lib/web_ui/lib/src/ui/pointer.dart
++++ b/lib/web_ui/lib/src/ui/pointer.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// How the pointer has changed since the last report.
+diff --git a/lib/web_ui/lib/src/ui/semantics.dart b/lib/web_ui/lib/src/ui/semantics.dart
+index c6dffe2fc..a0fde9a5b 100644
+--- a/lib/web_ui/lib/src/ui/semantics.dart
++++ b/lib/web_ui/lib/src/ui/semantics.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// The possible actions that can be conveyed from the operating system
+diff --git a/lib/web_ui/lib/src/ui/test_embedding.dart b/lib/web_ui/lib/src/ui/test_embedding.dart
+index f72a5c75e..955dbfe53 100644
+--- a/lib/web_ui/lib/src/ui/test_embedding.dart
++++ b/lib/web_ui/lib/src/ui/test_embedding.dart
+@@ -4,7 +4,7 @@
+ 
+ // TODO(flutter_web): the Web-only API below need to be cleaned up.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Used to track when the platform is initialized. This ensures the test fonts
+diff --git a/lib/web_ui/lib/src/ui/text.dart b/lib/web_ui/lib/src/ui/text.dart
+index ec9a45943..58698d862 100644
+--- a/lib/web_ui/lib/src/ui/text.dart
++++ b/lib/web_ui/lib/src/ui/text.dart
+@@ -3,7 +3,7 @@
+ // found in the LICENSE file.
+ // Synced 2019-05-30T14:20:57.833907.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Whether to slant the glyphs in the font
+diff --git a/lib/web_ui/lib/src/ui/tile_mode.dart b/lib/web_ui/lib/src/ui/tile_mode.dart
+index 8fd24ae58..9ce9ddf3c 100644
+--- a/lib/web_ui/lib/src/ui/tile_mode.dart
++++ b/lib/web_ui/lib/src/ui/tile_mode.dart
+@@ -2,7 +2,7 @@
+ // Use of this source code is governed by a BSD-style license that can be
+ // found in the LICENSE file.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Defines what happens at the edge of the gradient.
+diff --git a/lib/web_ui/lib/src/ui/window.dart b/lib/web_ui/lib/src/ui/window.dart
+index 557e6aa84..fd9e66740 100644
+--- a/lib/web_ui/lib/src/ui/window.dart
++++ b/lib/web_ui/lib/src/ui/window.dart
+@@ -3,7 +3,7 @@
+ // found in the LICENSE file.
+ // Synced 2019-05-30T14:20:57.841444.
+ 
+-// @dart = 2.9
++// @dart = 2.10
+ part of ui;
+ 
+ /// Signature of callbacks that have no arguments and return no data.
+diff --git a/lib/web_ui/lib/ui.dart b/lib/web_ui/lib/ui.dart
+index 49217e14a..13d5ee281 100644
+--- a/lib/web_ui/lib/ui.dart
++++ b/lib/web_ui/lib/ui.dart
+@@ -5,7 +5,7 @@
+ /// This library defines the web equivalent of the native dart:ui.
+ ///
+ /// All types in this library are public.
+-// @dart = 2.9
++// @dart = 2.10
+ library ui;
+ 
+ import 'dart:async';
diff --git a/tools/run_abi_tests.py b/tools/run_abi_tests.py
index 1810df8..47566f6 100644
--- a/tools/run_abi_tests.py
+++ b/tools/run_abi_tests.py
@@ -195,7 +195,7 @@
                                                flags.configuration_name)
                 resultFile.write(json.dumps(outResult) + '\n')
                 if diffs:
-                    logRecords = allLogs[name] if name in allLogs else []
+                    logRecords = allLogs.get(name, {})
                     logFile.write(
                         json.dumps(
                             makeLog(diffs, results, logRecords, flags.
diff --git a/tools/run_offsets_extractor.sh b/tools/run_offsets_extractor.sh
index c55cc24..8675fea 100755
--- a/tools/run_offsets_extractor.sh
+++ b/tools/run_offsets_extractor.sh
@@ -25,7 +25,6 @@
 
 # Run offsets_extractor for every architecture and append the results.
 run() {
-  tools/gn.py --mode=$1 --arch=$2
   tools/build.py --mode=$1 --arch=$2 offsets_extractor offsets_extractor_precompiled_runtime
   echo "" >>"$TEMP_JIT"
   out/$3/offsets_extractor >>"$TEMP_JIT"
diff --git a/tools/utils.py b/tools/utils.py
index 42a7db4..23c8812 100644
--- a/tools/utils.py
+++ b/tools/utils.py
@@ -503,7 +503,7 @@
 
 
 def GetShortGitHash(repo_path=DART_DIR):
-    p = subprocess.Popen(['git', 'rev-parse', '--short', 'HEAD'],
+    p = subprocess.Popen(['git', 'rev-parse', '--short=10', 'HEAD'],
                          stdout=subprocess.PIPE,
                          stderr=subprocess.STDOUT,
                          shell=IsWindows(),
diff --git a/utils/application_snapshot.gni b/utils/application_snapshot.gni
index 8f3f882..7d981bd 100644
--- a/utils/application_snapshot.gni
+++ b/utils/application_snapshot.gni
@@ -102,6 +102,8 @@
     vm_args = [
       "--depfile=$abs_depfile",
       "--depfile_output_filename=$rebased_output",
+
+      # Ensure gen_kernel.dart will use this SDK hash when consuming/producing kernel.
       "-Dsdk_hash=$sdk_hash",
     ]
 
@@ -114,6 +116,13 @@
       "--no-embed-sources",
       "--no-link-platform",
       "--output=" + rebase_path(output),
+
+      # Ensure the compiled appliation (e.g. kernel-service, frontend-server,
+      # ...) will use this SDK hash when consuming/producing kernel.
+      #
+      # (Instead of ensuring every user of the "application_snapshot" /
+      # "kernel_snapshot" passes this if needed, we always pass it)
+      "-Dsdk_hash=$sdk_hash",
     ]
     if (dart_platform_bytecode) {
       args += [
diff --git a/utils/dartdev/BUILD.gn b/utils/dartdev/BUILD.gn
index 45a52ca..68a779e 100644
--- a/utils/dartdev/BUILD.gn
+++ b/utils/dartdev/BUILD.gn
@@ -17,14 +17,6 @@
                               rebase_path("../../pkg/dartfix"),
                             ],
                             "list lines")
-
-dds_files = exec_script("../../tools/list_dart_files.py",
-                        [
-                          "absolute",
-                          rebase_path("../../pkg/dds"),
-                        ],
-                        "list lines")
-
 group("dartdev") {
   deps = [ ":copy_dartdev_snapshot" ]
 }
@@ -39,6 +31,6 @@
 application_snapshot("generate_dartdev_snapshot") {
   main_dart = "../../pkg/dartdev/bin/dartdev.dart"
   training_args = [ "--help" ]
-  inputs = dartdev_files + dartfix_files + dds_files
+  inputs = dartdev_files + dartfix_files
   output = "$root_gen_dir/dartdev.dart.snapshot"
 }
diff --git a/utils/dartdevc/BUILD.gn b/utils/dartdevc/BUILD.gn
index c9ff655..6116446f 100644
--- a/utils/dartdevc/BUILD.gn
+++ b/utils/dartdevc/BUILD.gn
@@ -141,10 +141,6 @@
     ":dartdevc_test_kernel_pkg",
     "../..:create_sdk",
   ]
-
-  # TODO(nshahan) Temporarily here until we decide if we are going to include
-  # in the create_sdk target.
-  deps += [ "../../sdk:copy_dev_compiler_outline_sound" ]
 }
 
 # Builds everything needed to run dartdevc tests locally using test.dart without
diff --git a/utils/dds/BUILD.gn b/utils/dds/BUILD.gn
new file mode 100644
index 0000000..001e710
--- /dev/null
+++ b/utils/dds/BUILD.gn
@@ -0,0 +1,30 @@
+# 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("../application_snapshot.gni")
+
+dds_files = exec_script("../../tools/list_dart_files.py",
+                        [
+                          "absolute",
+                          rebase_path("../../pkg/dds"),
+                        ],
+                        "list lines")
+
+group("dds") {
+  deps = [ ":copy_dds_snapshot" ]
+}
+
+copy("copy_dds_snapshot") {
+  visibility = [ ":dds" ]
+  deps = [ ":generate_dds_snapshot" ]
+  sources = [ "$root_gen_dir/dds.dart.snapshot" ]
+  outputs = [ "$root_out_dir/dds.dart.snapshot" ]
+}
+
+application_snapshot("generate_dds_snapshot") {
+  main_dart = "../../pkg/dds/bin/dds.dart"
+  training_args = []
+  inputs = dds_files
+  output = "$root_gen_dir/dds.dart.snapshot"
+}
diff --git a/utils/kernel-service/BUILD.gn b/utils/kernel-service/BUILD.gn
index a01bb1b..150d229 100644
--- a/utils/kernel-service/BUILD.gn
+++ b/utils/kernel-service/BUILD.gn
@@ -89,6 +89,9 @@
     vm_args = [
       "--depfile=$abs_depfile",
       "--depfile_output_filename=$rebased_output",
+
+      # Ensure gen_kernel.dart will use this SDK hash when consuming/producing
+      # kernel.
       "-Dsdk_hash=$sdk_hash",
     ]
 
@@ -97,6 +100,10 @@
 
     args =
         invoker.extra_args + [
+          # Ensure the compiled kernel-service will use this SDK hash when
+          # consuming/producing kernel.
+          "-Dsdk_hash=$sdk_hash",
+
           "--packages=" + scheme + ":///.packages",
           "--platform=" + rebase_path("$root_out_dir/vm_platform_strong.dill"),
           "--filesystem-root=" + rebase_path("../../"),